On 21/02/12 21:37, Bethea, Wayne L. wrote:
In my code I attempt to do OWL subclass inference by creating a Jena OntModel 
using  the code:

   - OntModel hModel = 
ModelFactory.creatOntologyModel(OntModelSpec.OWL_DL_MEM_TRANS_INF);

And checking for subclass existence using the code:

   - Boolean pd = 
propDomain.asClass().hasSubClass(domainTypeStatement.getObject().asResource());

OWL_DL_MEM_TRANS_INF - is a specification for OWL DL models that are stored in memory and 
use the transitive inference for additional entailments. This is sufficient for subclass 
inference of simple classes 
(Entity<-AbstractEntity<-Account<-FinancialAccount<-BankAccount), but is not 
sufficient for subclass inference of more complex classes:

Correct, it only implements rdfs:subClassOf and rdfs:subPropertyOf.

             <owl:Class>
                 <owl:unionOf rdf:parseType="Collection">
                     <rdf:Description rdf:about="#Device"/>
                     <rdf:Description rdf:about="#FacilityRegion"/>
                 </owl:unionOf>
             </owl:Class>

and CommunicationDevice.

I don't follow that example, too many bits missing.

I've tried to use different OntModelSpecs to get the subclass inference that I 
am looking for but I haven't been able to identify the correct one. I've tried:

   - OntModel hModel = 
ModelFactory.creatOntologyModel(OntModelSpec.OWL_DL_MEM_RULE_INF);

but it seems to have the opposite effect where it can capture the subclass 
inference involving more complex classes but not the simple class subclass 
inference.

It certainly should be a superset of the simple cases.

Do you have a specific, minimal example of an entailment RULE_INF misses but which is handled by one of the simpler configurations?

Any advice on the correct Jena OntModelSpec to use to capture relatively easy 
subclass inference would be appreciated.

My general advice is to use OWL_MICRO (which in OntModel terms is OWL_MEM_MICRO_RULE_INF) as the best trade-off for power and efficiency. I seem to remember that it handles unionOf. Otherwise go for OWL_MINI.

Dave

Reply via email to