yesterday i was trying to get Pellet and/or Openllet to run on my Fuseki Server.
Im am doing Requests over the Web-Interface. Without reasoners its working fine.
This is my configuration:
@prefix : <http://base/#> .
@prefix tdb: <http://jena.hpl.hp.com/2008/tdb#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix ja: <http://jena.hpl.hp.com/2005/11/Assembler#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix fuseki: <http://jena.apache.org/fuseki#> .
<http://jena.apache.org/2016/tdb#DatasetTDB>
rdfs:subClassOf ja:RDFDataset .
ja:DatasetTxnMem rdfs:subClassOf ja:RDFDataset .
tdb:DatasetTDB rdfs:subClassOf ja:RDFDataset .
tdb:GraphTDB rdfs:subClassOf ja:Model .
<http://jena.apache.org/2016/tdb#GraphTDB2>
rdfs:subClassOf ja:Model .
ja:MemoryDataset rdfs:subClassOf ja:RDFDataset .
ja:RDFDatasetZero rdfs:subClassOf ja:RDFDataset .
<http://jena.apache.org/text#TextDataset>
rdfs:subClassOf ja:RDFDataset .
:service_tdb_all a fuseki:Service ;
rdfs:label "TDB FOOT" ;
fuseki:dataset :tdb_dataset_readwrite ;
fuseki:name "FOOT" ;
fuseki:serviceQuery "query" , "" , "sparql" ;
fuseki:serviceReadGraphStore "get" ;
fuseki:serviceReadQuads "" ;
fuseki:serviceReadWriteGraphStore
"data" ;
fuseki:serviceReadWriteQuads "" ;
fuseki:serviceUpdate "" , "update" ;
fuseki:serviceUpload "upload" .
:tdb_dataset_readwrite
a ja:RDFDataset;
ja:defaultGraph <#model_inf> ;
tdb:location "C:\\etc\\fuseki/databases/FOOT" .
<#model_inf> a ja:InfModel ;
ja:baseModel <#graph> ;
ja:reasoner [
ja:reasonerClass "openllet.jena.PelletReasonerFactory";
] .
<#graph> rdf:type tdb:GraphTDB ;
tdb:dataset :tdb_dataset_readwrite .
Error-Log in the Tomcat Directory:
ERROR Exception in initialization: the class 'openllet.jena.PelletReasonerFactory' required by the object 7c374328cddba9fa8091dcebd77a7598 [ja:reasoner of file:///C:/etc/fuseki/configuration/FOOT.ttl#model_inf] could not be loaded
I had been copying the Openllet Jar-Files (openllet-query-2.6.5.jar and things) everywhere, but no chance. Btw is this the right action anyway?!
In my Apache Jena project (and Snarp Sparql Protege Plugin) i got Openllet to run and it gets me the right results.
I got a few rules that are all of this type
[ rdf:type owl:Class ;
owl:unionOf ( [ owl:intersectionOf ( [ rdf:type owl:Restriction ;
owl:onProperty food:hasIngredient ;
owl:someValuesFrom food:Dairy
]
[ rdf:type owl:Restriction ;
owl:onProperty food:hasIngredient ;
owl:someValuesFrom [ rdf:type owl:Restriction ;
owl:onProperty food:hasFood ;
owl:someValuesFrom food:Meat
]
]
) ;
rdf:type owl:Class
]
[ rdf:type owl:Restriction ;
owl:onProperty food:hasIngredient ;
owl:someValuesFrom [ rdf:type owl:Restriction ;
owl:onProperty food:hasFood ;
owl:someValuesFrom food:Pork
]
]
)
]
) ;
rdf:type owl:Class ;
rdfs:subClassOf [ rdf:type owl:Restriction ;
owl:onProperty food:violatesRestriction ;
owl:hasValue food:kosherReligious
]
] .
"Not kosher if there is pork in a recipe or meat in combination with a dairy product."
The reasoning is horrible slow (8 seconds on a 25000 triple database). If i extract the model before it runs fast but the extraction of the model takes 3 minutes.
I just want to have a way where the user can query recipes with the inferences of a reasoner in a reasonable time (< 2 seconds) :(
Are there any more (better?) reasoners who can work with blank nodes (Hermit cant...) ??
My questions are:
Best regards ;)
Instead of Openllet i tried the OWLMicroFBRuleReasoner, it worked! And its fast!
<#model_inf> a ja:InfModel ;
ja:baseModel <#graph> ;
ja:reasoner [
ja:reasonerURL <http://jena.hpl.hp.com/2003/OWLMicroFBRuleReasoner>
] .