This could be accomplished using the native JSON methods, although I'm not sure if there's a particular structure that would be the most efficient.
For serialization, a toJSON method could be added to Anchor (and Illustration?). For deserialization, a method could be exposed (Zdog.parse?) which extends JSON.parse by using a custom reviver parameter.
It would also be super cool if there was a way to generate an STL file from a Zdog illustration (imagine 3D printing your Zdog creations!) or other formats (USDZ for ARKit fun!). I wouldn't imagine that kind of specialized output being a Zdog feature per se, but I'm adding this note here in case smart people can figure out how to harvest the 3D data from Zdog illustrations (or from the proposed JSON export, if that's added). ❤️