Hi all, I have a question about using SKOS with Jena:  I'm looking
at the section of "Semantic Web for the Working Ontologist", on page
166-167 where it talks about "Special Purpose Inference" and trying
to figure out how (or if) this works with Jena.  I have a sample
little rdf file cooked up that looks like:

(leaving out namespace declarations and such to save space)

        <rdf:Description rdf:about="&example;Milk">
                <rdf:type rdf:resource="&skos;Concept" />
                <skos:narrower rdf:resource="&example;MilkBySourceAnimal" />
        </rdf:Description>      
        
        
        <rdf:Description rdf:about="&example;MilkBySourceAnimal">
                <rdfs:label>Milk by source animal</rdfs:label>
                <rdf:type rdf:resource="&skos;Collection" />
                <skos:member rdf:resource="&example;BuffaloMilk" />
                <skos:member rdf:resource="&example;GoatMilk" />
                <skos:member rdf:resource="&example;CowMilk" />
                <skos:member rdf:resource="&example;SheepMilk" />               
        </rdf:Description>
        
        
        <rdf:Description rdf:about="&example;BuffaloMilk">
                <rdf:type rdf:resource="&skos;Concept" />
                <skos:prefLabel>Buffalo Milk</skos:prefLabel>
        </rdf:Description>

        <rdf:Description rdf:about="&example;CowMilk">
                <rdf:type rdf:resource="&skos;Concept" />
                <skos:prefLabel>Cow Milk</skos:prefLabel>
        </rdf:Description>

        <rdf:Description rdf:about="&example;GoatMilk">
                <rdf:type rdf:resource="&skos;Concept" />
                <skos:prefLabel>Goat Milk</skos:prefLabel>
        </rdf:Description>
        
        <rdf:Description rdf:about="&example;SheepMilk">
                <rdf:type rdf:resource="&skos;Concept" />
                <skos:prefLabel>Sheep Milk</skos:prefLabel>
        </rdf:Description>

And I'm loading this into Jena, along with the skos vocabulary, like so:

                // load some data that uses RDFS
                Model data = 
FileManager.get().loadModel("file:data/skos/ex33/data.rdf");
                
                Model skosData = 
FileManager.get().loadModel("file:data/skos/skos.rdf");
                data.add(skosData);
                
                
                Reasoner reasoner = ReasonerRegistry.getOWLReasoner();
                InfModel infmodel = ModelFactory.createInfModel(reasoner, data 
);

Now if I'm understanding what this book is telling me, SKOS inference rule say
that I should see triples in the form of:

example:Milk  skos:narrower  example:GoatMilk
example:Milk skos:narrower example:SheepMilk

etc.  But I don't see these.  Is there something extra I need to do to
enable this particular bit
of inference, or is my understanding here simply wrong, or what?  I
note that the book says
that "SKOS does not model the answer to this question in RDFS-Plus,
but instead specifies a
special purpose rule as part of the SKOS specification,"  so I'm
guessing there's some extra
"magic" missing, but if anyone can shed any light on this it would be
much appreciated.


Thanks,


Phil

Reply via email to