Re: [xml-dev] XML Schema generation by machine learning from a corpusof XML instance documents?
We had a program to generate every absolute XPath found in a corpus, then complain (Schematron) if any Xpath was found that was not in that corpus. It did not test for required elements.
That kind of thing is only as good as the corpus, and for any decent schema for literature-type of XML, your sample set may have to be very large. I worked for a company where, after 100,000 docment instances we were still getting new XPaths. Because things like tables appearing in new contexts.
So for an schema imferencing system, it really needs to have some idea of what can be in mixed content, to allow that everywhere, or what kinds of blocks there can be.
But simple structures, no worries.
Rick