Long long ago ... there was discussion about a scripting language for LyX. TeXmacs and Siag both use or can use guile. I'm thinking along the lines of interactive textbooks or just a way to provide sample solutions to equations in a graphics format. These are just thoughts that I pass on. Garst