Later on I plan to make the formula database itself available in some language-agnostic form, with the idea that you could interface it from any programming language or computer algebra system you like. Both Python and Julia are on my radar. And Racket would be quite nice too, since I agree that it's a very nice language for this kind of thing!
Different purposes, with different needs and only a limited technology overlap (the theory of how to maintain program correctness through transformation is related to the theory of how to squash hidden assumptions and subtle type mismatches in algebraic formulas).
There’s no reason why macros need to generate valid code. Though in Lisp, it’s pretty easy to make any code you want valid.
'source code' is slightly misleading, since the s-expressions don't need to be valid source code. What's valid is only limited by what the macro wants do. If a macro accepts the s-expression form, then it is valid.
For example that means that the macro form itself does not need to be parseable to an AST by an existing language grammar. The macro itself can parse the s-expression in arbitrary ways. If data is source for the macro, then it may do something with it...