With the XTriples webservice you can crawl XML repositories and extract RDF statements using a simple configuration based on XPATH/XQuery expressions. The webservice can be used with direct POST, form-style POST or GET requests.
The extraction of RDF statements from XML data can be a complicated process involving a lot of XSLT magic. Transformations are always specific to the XML data in question and cannot easily be applied to other XML repositories. It gets even more difficult if the markup of the XML data in question cannot be influenced. However, the underlying principle of creating RDF statments out of XML data is simple.
- If we take a XML resource or a value in it as the thing we want to talk about, this is our subject.
- We want to join this subject to "something else" using a predicate from a controlled vocabulary.
- This "something else" is our object, consisting either of the XML resource itself, some value in it or some other resource on the semantic web.
The XTriples webservice makes it possible to create such statements out of any XML data based on a simple XML configuration. The configuration defines the XML resources to crawl, the vocabularies to use and a number of XPATH/XQuery based statement patterns to apply on the data.