in reply to Modules of Formats

I have too little experience with formats to answer your question directly, but I wonder if maybe you would like to switch to a tool like Template-Toolkit 2 instead of using formats? Managing a library of templates is pretty trivial, and in my experience you tend to modularize code better when working with a template engine - data gets munged and collected first, then passed to the template, with the two separate steps really separated. On-the-fly generation of output tends to get ugly.

Makeshifts last the longest.