Would it be easier/better to have XML export and then use XSLT for XHTML/HTML/CSS and ePub conversions?
Using XML as a go-between would require doing something about defining a stable schema, explicit or otherwise. I've a Python script to convert .lyx to XML with an implicit schema, but it's no more stable than .lyx itself (which is to say: not at all, but in combination with lyx2lyx it can be made stable enough, though with potential content/styling loss when using lyx2lyx to go backwards). Nico --