[plt-scheme] first request

From: Christopher Coleman (mellowfish at gmail.com)
Date: Thu Jun 4 00:04:02 EDT 2009

Hey all, I've been dabbling in scheme for a while now and have decided
to start a bigger project now that I am comfortable with the basics.
As part of a natural language processing AI I am working on, I'd like
to have the AI edit its own code on the fly as needed.  (yes I know
this is not a very good idea, but it fits with what I am trying to
accomplish with this iteration).  While the program is running, this
is easy: just set! the new definitions over the old ones, but how
would I go about saving all these new definitions into a new module
file for a subsequent run to use?  Is there an easier way to export a
loaded module than just writing the definition expressions as strings
to a file?  It seems like I would need to know at least all the
definition labels, which is going to be problematic if the program
makes new ones that it names itself.

Sorry if this has an obvious solution, I have been searching help
files across the net for a few days and cant seem to come up with a
good idea myself.

Posted on the users mailing list.