DocBook is an XML vocabulary which enables you to create document content in a presentation-neutral form that captures the logical structure of the content. Using the DocBook Project XSL stylesheets, you can publish DocBook content as HTML pages and PDF files and other formats, including man pages, HTML Help, and JavaHelp.
References for TeX and Friends is an ongoing project which provides a help file for LaTeX (and its friends like ConTeXt, Metapost, Metafont, etc.) using a state-of-the-art source format, DocBook/XML. Various output formats can be generated from the source file. Anyone can write a converter for any desired output format. Because the source file is XML, the easiest way to do this might be to use XSLT.
Zoem is a general-purpose macro/programming language that submits text to a two-stage transformation process. Macro expansion and interpretation is followed by application of customizable character filtering rules. Zoem supports inside-out evaluation, comprehensive IO, control operators, iteration, dictionary stacks, multidimensional data storage, arithmetic expressions, regular expressions, system commands, and more.