Re: SKOS query in SPARQL 1.1

Hi,

Le 16 oct. 2010 à 12:03, Dan Brickley a écrit :
> since we often have hierarchies of skos:broader to traverse. If anyone
> experiments with this, I'm sure everyone here would be happy to see

I have some working examples using Jena property path to emulate skos:broaderTransitive and narrowerTransitive in SPARQL queries here:
http://www.semanlink.net/sl/sparql

This is the sparql endpoint associated to a tool that I use for tagging, the tags being given an URI and organized in a SKOS like graph (it uses its own properties internally, but can be queried using the SKOS ones)

So you can search for "Archeology" and "Africa", and find documents tagged with "Tutankhamun", or documents tagged with "Rockart" and "Niger".

Note that, in this implementation,
:TagX skos:broaderTransitive :TagX.
This allows for SPARQL queries that are easier to write when searching documents

Best regards,

fps





Le 16 oct. 2010 à 12:03, Dan Brickley a écrit :

> Hello SKOS people,
> 
> http://www.snee.com/bobdc.blog/2010/10/playing-more-with-sparql-11-pr.html
> from Bob DuCharme might be of interest.
> 
> "Playing more with SPARQL 1.1 property paths"
> 
> It describes some new language features in SPARQL (along with their
> implementation in ARQ, Jena's query engine; Java software).
> 
> The new SPARQL draft includes a 'property paths' feature,
> http://www.w3.org/TR/2010/WD-sparql11-query-20101014/#propertypaths
> 
> "A property path is a possible route through a graph between two graph
> nodes. A trivial case is a property path of length exactly 1, which is
> a triple pattern. Property paths allow for more concise expression of
> some SPARQL basic graph patterns and also add the ability to match
> arbitrary length paths. The ends of the path may be RDF terms or
> variables. Variables can not be used as part of the path itself, only
> the ends. Query evaluation determines all matches of a path expression
> and binds subject or object as appropriate."
> 
> This should lend itself to SKOS (and Bob reports some success there),
> since we often have hierarchies of skos:broader to traverse. If anyone
> experiments with this, I'm sure everyone here would be happy to see
> some summary and sample queries. The SPARQL Working Group might
> appreciate feedback too.
> 
> cheers,
> 
> Dan
> 

Received on Tuesday, 4 January 2011 02:14:59 UTC