One Turtle graph supplies both the directory and its schema.
people-owl2rl.ttl · output · proof · check · playground
The question
Alice is a researcher and Bob is her colleague. Researchers are employees, employees are people, and the colleague property has employee domain and person range. Every colleague relation is also a knows relation.
What types and relations follow from this directory?
Historical background
OWL became a W3C Recommendation in 2004. OWL 2 introduced profiles, including RL for rule-based reasoning over RDF. The directory example shows a small part of that profile, where class and property rules add standard consequences to ordinary person records. W3C, 2004 RDF and OWL announcement · OWL 2 Profiles
What we tell eyemind
The Turtle file contains the data and the schema. --owl2rl adds the inference
rules, including RDFS; the vocabulary by itself does not enable reasoning.
The class and property rules follow
W3C RDF Schema.
What eyemind concludes
Alice is an employee and a person, Bob is a person, and Alice knows Bob:
:Alice a :Employee, :Person ; :knows :Bob .
:Bob a :Person .
One of the conclusions in the JavaScript check report is:
result_rdf(iri('https://example.org/people#Alice'), iri('http://www.w3.org/1999/02/22-rdf-syntax-ns#type'), iri('https://example.org/people#Person'), 'default_graph')
The output also contains the class, property and resource consequences of
the RDFS rules, together with OWL 2 RL equality and schema conclusions. By default it omits triples already present in the input;
--all includes them.
What the proof establishes
The saved proof is checked against the compiled LS program. It establishes the new triples from the directory and the supplied rules. RDFS domain and range infer types; they do not reject a directory entry whose type was not stated beforehand. Missing information is not a contradiction.
Try it
node bin/eyemind.js --owl2rl examples/people-owl2rl.ttl
node bin/eyemind.js --owl2rl --program examples/people-owl2rl.ttl > /tmp/people-owl2rl.js
node bin/eyemind.js --to turtle /tmp/people-owl2rl.js
node bin/eyemind.js --owl2rl --proof examples/people-owl2rl.ttl
node bin/eyemind.js --owl2rl --check-proof examples/proof/people-owl2rl.js examples/people-owl2rl.ttl
Remove Alice’s explicit researcher type: the colleague property’s domain still establishes that she is an employee and a person.
