> On 7 Apr 2020, at 22:29, Andy Seaborne <[email protected]> wrote:
> 
> Benjamin,
> 
> What complexity of reasoning are you doing?

Hi Andy,

Thanks for asking, and sorry I didn’t see your reply sooner.

Basically I would just like a subset of RDFS along with owl:TransitiveProperty. 
I was going to try this custom rule set:

# OWL axioms
[owlClass: (?a rdf:type owl:Class) -> (?a rdf:type rdfs:Class)]
[owlObjectProp: (?a rdf:type owl:ObjectProperty) -> (?a rdf:type rdf:Property)]
[owlDatatypeProp: (?a rdf:type owl:DatatypeProperty) -> (?a rdf:type 
rdf:Property)]
[owlAnnotationProp: (?a rdf:type owl:AnnotationProperty) -> (?a rdf:type 
rdf:Property)]

# rdfs:subPropertyOf
[rdfs5: (?a rdfs:subPropertyOf ?b), (?b rdfs:subPropertyOf ?c) -> (?a 
rdfs:subPropertyOf ?c)]
[rdfs6: (?a rdf:type rdf:Property) -> (?a rdfs:subPropertyOf ?a)]
[rdfs7: (?x ?a ?y), (?a rdfs:subPropertyOf ?b) -> (?x  ?b  ?y)]

# rdfs:subClassOf
[rdfs9: (?a rdf:type ?x), (?x rdfs:subClassOf ?y) -> (?a rdf:type ?y)]
[rdfs10: (?x rdf:type rdfs:Class) -> (?x rdfs:subClassOf ?x)]
[rdfs11: (?x rdfs:subClassOf ?y), (?y rdfs:subClassOf ?z) -> (?x 
rdfs:subClassOf ?z)]

# owl:TransitiveProperty
[prp_trp: (?p rdf:type owl:TransitiveProperty), (?x ?p ?y), (?y ?p ?z) -> (?x 
?p ?z)]

Currently I’m using SPARQL property path syntax instead of inference, like this:

?resource rdf:type ?resourceType .
?resourceType rdfs:subClassOf* example:SomeClass .

Better performance would be the only reason for me to use inference. I’ve been 
assuming (perhaps incorrectly?) that backward chaining inference wouldn't be 
more efficient than just using property path syntax in the query. Is that a 
reasonable assumption?

> But RDFS+ level of complixity could take a different approach to the current 
> rules. Essentially, be backwards chaining (sees updates) with materialized 
> transitive properties.

Could you explain what you mean by materialized transitive properties?

> It's might be possible to go a fit further that that. Rules that generate a 
> single triple from a BGP+FILTER(+BIND), together with transitive properties 
> (not written as rules) might be possible.

Do you mean using the TransitiveReasoner to handle rdfs:subPropertyOf and 
rdfs:subClassOf, and the GenericRuleReasoner for anything else?

Ben

Reply via email to