you can infer an xml schema from a document but you will only get the data that is in the document of course. the real schema will probably have a lot more information

i use a tool called liquid xml for example that has a function to create a schema from sample files

having said that there should be no need for the schema to read the document. The schema allows you to validate a document