W3C home > Mailing lists > Public > public-rdf-dawg-comments@w3.org > September 2005

Re: Comments on SPARQL Query Language for RDF (21 July 2005 version)

From: Ora Lassila <ora.lassila@nokia.com>
Date: Tue, 06 Sep 2005 11:00:03 -0400
To: Dan Connolly <connolly@w3.org>, <Art.Barstow@nokia.com>
CC: <public-rdf-dawg-comments@w3.org>
Message-ID: <BF432733.EC7C%ora.lassila@nokia.com>

Dan et al,

> From: ext Dan Connolly <connolly@w3.org>
> Date: Thu, 01 Sep 2005 13:01:57 -0500
> On Thu, 2005-09-01 at 13:12 -0400, Art.Barstow@nokia.com wrote:
>> Regarding the 2005-07-21 version of the SPARQL Query
>> Language for RDF document, we have the following comments:
>> 
>> 1) This document does not discuss in any way the
>> *semantics* of the query language. We would like to see
>> a more formal definition of queries (and their results)
>> in terms of RDF semantics (right now, the query language
>> seems to treat RDF graphs as merely data structures from
>> which something can be extracted). Why would SPARQL now
>> ignore RDF's model theory when one was created through
>> a sizeable effort?
> 
> Could you be more specific about what's lacking? What
> questions should be answered that are not currently
> answered?
> 
> I suppose we could make explicit that for a query pattern P,
> if S is a solution w.r.t. an input graph G,
> then S(P) is entailed by G. Is that what you have in mind?

That would be a good start I guess although the "solution" being a set of
bindings I would like to see a formal treatment of things like *a* solution
vs. *all* solutions, etc. Mind you, I am not qualified to write such a
thing. ;-)
> 
> I think the idea can be expanded to cover UNION straightforwardly,
> and perhaps OPTIONAL with some effort, but I don't know how this
> applies to queries that use the GRAPH keyword.
> 
> RDF's model theory was not ignored. There is a normative dependency
> from SPARQL to the RDF model theory in section 7.1.
> 
> The link was not as clear as it could be in the 2005-07-21 version;
> In response to comments from other reviewers, we have clarified
> the references section. In the current editor's draft, you
> may want to look at...
>   http://www.w3.org/2001/sw/DataAccess/rq23/#RDF-MT

I will obviously have to read the most recent version first to see what you
have done. It does seem, though, that since queries are (potentially) run
against the deductive closure of a graph, the query language does not extend
easily to representations which do not have a single unique deductive
closure (which as far as I understand happens as soon as you have mutually
exclusive entailments as in OWL).

>> 2) Given that RDF representations -- effectively -- are
>> graphs, why would the W3C present a query language based
>> on relational algebra? It is well known [1] that relational
>> algebra is insufficient for querying graphs (generally,
>> data structures that exhibit repetitive or recursive patterns).
>> In order to query, say, hierarchies of arbitrary depth, the
>> query language should have some means of expressing
>> a transitive closure.
> 
> The WG began its design discussion by surveying
> known technologies:
>  http://www.w3.org/2001/sw/DataAccess/DesignEvaluations
> 
> Versa was among the designs we considered, and it's fairly strongly
> path-based. It got some support, but not a critical mass.
> 
> The level of support for various designs was discussed at
> the 2nd ftf meeting a few times before we eventually
> chose BRQL, which is largely relational.
>   http://www.w3.org/2001/sw/DataAccess/ftf2#initdn
>   http://www.w3.org/2001/sw/DataAccess/ftf2#initdn2
>   http://www.w3.org/2001/sw/DataAccess/ftf2#initdn3
> 
> In the use cases we have explored, where transitive closure
> is needed, the query is run over a notional background
> graph that includes the inferred transitive closure.
> By charter, this sort of inference is orthogonal to
> query. More on that below.

Understood, but as far as I can understand, any such inference may only be
desirable in the context of a single query, so the notion of querying
against a stored data structure may not work too well (say, from memory
usage etc. viewpoints). Also, it is my experience that such inferences are
not easy to express whereas graph traversal is easily understandable to most
people.

> 
> 
>> 
>> 3) It does not seem possible to extend SPARQL to be
>> used with OWL (primarily, perhaps, because of comment
>> #1 above).
> 
> A number of WG members (UMD, Agfa) are succesfully using SPARQL
> with OWL.
> 
> By charter, OWL inference is orthogonal to query:
> 
> [[
> 2.1 Specification of RDF Schema/OWL semantics
> 
> The protocol will allow access to a notional RDF graph. This may in
> practice be the virtual graph which would follow from some form of
> inference from a stored graph. This does not affect the data access
> protocol, but may affect the description of the data access service. For
> example, if OWL DL semantics are supported by a service, that may be
> evident in the description of the service or the virtual graph which is
> queried, but it will not affect the protocol designed under this
> charter.
> ]]
> http://www.w3.org/2003/12/swa/dawg-charter#rdfs-owl-queries
> 

I guess I don't really understand how such an approach would work. I can see
that you could query a graph that *syntactically* represents your OWL but
not more. The beauty of RDF is that we have a uniquely defined deductive
closure, but this is not the case for OWL. Of course, the "neats" do not
like this approach even with RDF, but myself, being a "scruffy", can live
with it. ;-)

I will have to take a look what exactly the UMD and Agfa folks have done.

    - Ora

-- 
Ora Lassila  mailto:ora.lassila@nokia.com  http://www.lassila.org/
Research Fellow & Head of Competence Area (Data Modeling and Management)
Nokia Research Center / Boston
Received on Tuesday, 6 September 2005 18:34:59 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:14:49 GMT