I've created an example schema for modelling chains of objects. The example is analogous to something I'm aiming to produce but doesn't demonstrate that
:l1 might have multiple
chain:nextLink links, for example, or that any
chain:Link might have multiple
chain:prevLink predicates. Here is the ontology in turtle, including definitions of
:c,
:l1,
:l2,
:l3:
chain:Chain a owl:Class .
chain:Link a owl:Class .
chain:inChain a owl:Property ;
owl:inverseOf chain:hasLink ;
rdfs:range chain:Chain ;
rdfs:domain chain:Link ;
owl:propertyChainAxiom ( chain:linksWith chain:inChain ) .
chain:linksWith a owl:TransitiveProperty , owl:SymmetricProperty ;
rdfs:range chain:Link ;
rdfs:domain chain:Link .
chain:nextLink a owl:Property ;
rdfs:subPropertyOf chain:linksWith ;
owl:inverseOf chain:prevLink .
:l1 chain:inChain :c ;
chain:nextLink :l2 .
:l2 chain:nextLink :l3 .
and I can query for the relationships between all-of-the-things:
$ stardog query execute chain -r SL "SELECT * { ?s chain:linksWith ?o } ORDER BY ?s ?o"
+-------+-------+
| s | o |
+-------+-------+
| :l1 | :l1 |
| :l1 | :l2 |
| :l1 | :l3 |
| :l2 | :l1 |
| :l2 | :l2 |
| :l2 | :l3 |
| :l3 | :l1 |
| :l3 | :l2 |
| :l3 | :l3 |
+-------+-------+
$ stardog query execute chain -r SL "SELECT * { ?s chain:hasLink ?o } ORDER BY ?s ?o"
+-------+-------+
| s | o |
+-------+-------+
| :c | :l1 |
| :c | :l2 |
| :c | :l3 |
+-------+-------+
The problem appears then when we try to explain why these assertions are coming out of the system. There appears to be a point of complexity past which the reasoner says the inference is impossible.
$ stardog reasoning explain chain -r SL ":l1 chain:linksWith :l2"
INFERRED
INFERRED :l1 chain:linksWith :l2
ASSERTED chain:linksWith a owl:SymmetricProperty
INFERRED :l2 chain:linksWith :l1
ASSERTED chain:linksWith a owl:SymmetricProperty
INFERRED :l1 chain:linksWith :l2
ASSERTED chain:nextLink rdfs:subPropertyOf chain:linksWith
ASSERTED :l1 chain:nextLink :l2
INFERRED :l2 chain:prevLink :l1
ASSERTED chain:nextLink owl:inverseOf chain:prevLink
$ stardog reasoning explain chain -r SL ":l1 chain:linksWith :l1"
Input axiom is not a valid inference; no explanation generated.
$ stardog reasoning explain chain -r SL ":l1 chain:linksWith :l3"
Input axiom is not a valid inference; no explanation generated.
Is there a means of configuring the reasoner to go beyond a certain point of explanation, if indeed that is the problem? Otherwise, what else might it be?
Any insight you can provide would be greatly appreciated.
Paul