On 08/03/2021 14:29, Toni Cebrián wrote:
They don't have an inference layer because they do all the inference off
the triple store using https://github.com/NatLibFi/Skosify . I didn't know
that and I tried first with inference because I thought that Jena would be
able to provide inferred types for SKOS.
Used SKOS owl was the one from the standard
https://www.w3.org/2004/02/skos/vocabs
Uses to to define SKOS, not require it to use SKOS.
The problem is that I cannot share my SKOS vocabulary but I guess the
problem should be reproducible by:
- loading skos.rdf
- loading a big SKOS taxonomy
- running the CONSTRUCT query above in a server with the following
config.ttl
My guess is that work is done by the OWL reasoner - e.g. the axiomatic
rules that that you don't need these at all. (i.e. Osma's reply)
Andy
@prefix tdb2: <http://jena.apache.org/2016/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#> .
:service_tdb_all a fuseki:Service ;
rdfs:label "TDB2 example-inf" ;
fuseki:dataset :dataset ;
fuseki:name "example" ;
fuseki:serviceQuery "query" , "" , "sparql" ;
fuseki:serviceReadGraphStore "get" ;
fuseki:serviceReadQuads "" ;
fuseki:serviceReadWriteGraphStore "data" ;
fuseki:serviceReadWriteQuads "" ;
fuseki:serviceUpdate "" , "update" ;
fuseki:serviceUpload "upload" .
:tdb_dataset_readwrite
a tdb2:DatasetTDB2 ;
tdb2:location "example" ;
.
:dataset a ja:RDFDataset ;
ja:defaultGraph :model_inf .
:model_inf a ja:InfModel ;
ja:baseModel :graph .
ja:reasoner [
ja:reasonerURL <http://jena.hpl.hp.com/2003/OWLMicroFBRuleReasoner
] .
:graph rdf:type tdb2:GraphTDB ;
tdb2:dataset :tdb_dataset_readwrite ;
On Thu, 4 Mar 2021 at 12:33, Andy Seaborne <a...@apache.org> wrote:
Osma's tutorial
https://github.com/NatLibFi/Skosmos/wiki/InstallTutorial
doesn't have an inference layer.
Looks like the fact its skosmos is not a factor and it is the rest of
the setup.
Andy
On 04/03/2021 11:22, Andy Seaborne wrote:
On 04/03/2021 11:10, Toni Cebrián wrote:
Hi Andy,
Fuseki server was 3.14.0. I didn't include the full stack trace
because
it was clear that it is just a timeout.
It would help me to know what part of the Fuseki engine this is
happening in.
There was a change for better diagnostics for
org.eclipse.jetty.io.EofException but I can't tell if this is on that
path or another.
This timeout happens because the
reasoner hogs the server without completing the query. I asked in the
Skosmos user group
(https://groups.google.com/g/skosmos-users/c/bSzpAhdprvY)
and the solution was to materialise all relationships before hand and
remove reasoning from Jena.
But to me, performing inference on the skos ontology should be pretty
straightforward even for online querying, shouldn't it? What am I doing
wrong so a simple query works in milliseconds when I materialise all
relations myself but cannot be handled by the most lightweight OWL
reasoner?
It is only the first query. That's when initialization happens.
4597 sounds very small but I don't know skosmos.
What does the OWL look like?
And the data - because there may be a lot of other inference because
OWLMicro is general and not specific to SKOS. Some rules are expensive.
And if it large and cold off disk, then, something else is involved.
Maybe you want a SKOS specific rule set?
What is in the Fuseki configuration file?
Andy
Toni
On Tue, 2 Mar 2021 at 15:49, Andy Seaborne <a...@apache.org> wrote:
Hi Toni,
Which version of Fuseki is this?
What's the full stacktrace? (the operation isn't showing below)
The exception usually means client has gone away before the request
response is finished. (Sometimes, that's an intermediate like a
proxy/reverse proxy.)
Maybe the first query is expensive because it is doing all the rules
setup. More a Skosmos question.
Andy
On 02/03/2021 09:07, Toni Cebrián wrote:
Hi,
I'm trying to setup Fuseki with the Skosmos frontend (
https://skosmos.org/) using docker images for both servers.
In Fuseki I've uploaded to the default graph the skos.rdf file
plus
the
.ttl with my vocabulary comprising around 4597 concepts. Fuseki is
also
setup with MicroOWL reasoner:
ja:reasonerURL <http://jena.hpl.hp.com/2003/OWLMicroFBRuleReasoner>
so I can navigate the SKOS taxonomy back and forth.
The problem is that the first query that Skosmos sends to Jena
never
returns:
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
CONSTRUCT { <http://example.org/MyScheme> ?property ?value . }
WHERE {
<http://example.org/MyScheme> ?property ?value .
FILTER (?property != skos:hasTopConcept) }
After sending the query, one CPU goes 100% and after a while before
getting
any results I can see this exception in fuseki:
skosmos-fuseki | [2021-03-02 08:19:04] Fuseki INFO Exception
while
writing the response model: org.eclipse.jetty.io.EofException
skosmos-fuseki | org.apache.jena.atlas.RuntimeIOException:
org.eclipse.jetty.io.EofException
skosmos-fuseki | at
org.apache.jena.atlas.io.IO.exception(IO.java:261)
skosmos-fuseki | at
org.apache.jena.atlas.io
.BufferingWriter.flushBuffer(BufferingWriter.java:136)
skosmos-fuseki | at
org.apache.jena.atlas.io.BufferingWriter.output(BufferingWriter.java:86)
skosmos-fuseki | at
org.apache.jena.atlas.io.BufferingWriter.write(BufferingWriter.java:173)
skosmos-fuseki | at
org.apache.jena.atlas.io.Writer2.print(Writer2.java:55)
skosmos-fuseki | at
org.apache.jena.riot.out.quoted.QuotedURI.writeURI(QuotedURI.java:46)
skosmos-fuseki | at
org.apache.jena.riot.out.NodeFormatterNT.formatURI(NodeFormatterNT.java:46)
to me it doesn't look like a very complex query, so my questions are:
- Is Jena able to handle SKOS vocabularies in the range of thousand
terms
when inference is on?
- If so, how should I configure Fuseki to work with that dataset?
- Maybe related, but does anyone have a similar Skosmos setup where I
could
borrow the Jena config files?
Thanks