The actual cleanup and all file level operations could be done with Automator and an extension for string handling. the stripping of the AI specific items might be another story, but I'm sure it can be done with some script. I'm just not familiar with AI scripting (or much Apple scripting, for that matter). Maybe James has an idea or knows some solution....
I haven't had this happen so I'm not sure of the exact nature of the objects that need to be cleaned up. Have you tried using any of the various "select same" or "select object" options available under the Select menu? In some cases this can help a lot in selecting just the items you need to clean out, or at least narrowing things down to make the task easier and quicker.
I've try clean them using the select function (select un-used....etc) but unfortulatelly that dosen't help and will also crash Illustrator.
The Adobe Tech Note also stated this.