RE: deciding on rdf:PlainLiteral this week



> -----Original Message-----
> From: Sandro Hawke [mailto:sandro@w3.org]
> Sent: 1 June 2009 17:23
> To: Seaborne, Andy
> Cc: public-rdf-text@w3.org
> Subject: Re: deciding on rdf:PlainLiteral this week
> 
> 
> 
> > > > http://lists.w3.org/Archives/Public/public-owl-

> comments/2009May/0009
> > > >
> > > > The issue about the results of FILTER functions, all algebra
> operators
> > > > and how to pass constraints into a matching as some engines might
> (and
> > > > do).
> > > >
> > > > Just saying "results" does not work.  That only applies to what
> comes
> > > > out in SPARQL results.
> > > >
> > > > We have three layers:
> > > >
> > > > 1 - Results formats (SPARQL XML Results or RDF graphs)
> > > > 2 - Algebra and FILTER functions
> > > > 3 - BGP matching.
> > > >
> > > > And also the query syntax (4).
> > > >
> > > > The text only covers (1) and (4).  Change the matching and the
> correct
> > > > behaviour at level 2 is undefined.
> > >
> > > It sounds like the solution is to extend the wording about syntaxes
> to
> > > also cover interfaces between software sub-systems, and then perhaps
> > > give one of these as an example.   Would that do it?
> >
> > The reason this case is special is that it is an interaction with the
> > SPARQL spec - it's not a private API matter.
> >
> > Therefore, I am suggesting explicit mention of extend BGP matching.
> 
> I've been staring at this, and I still don't get it.  Can you put it in
> programming terms for me?  Maybe tell me what decisions you, as an
> implementor of SPARQL system, expect to face because of this draft?
> What is it that you think this draft is telling to do or not do to your
> code, in order to remain conformant with all relevant W3C specs?
> 
>     -- Sandro


Data:

:x :p "foo" .

Case 1:

Read into RDF simple entailment; binding ?v to "foo"@en and DATATYPE(?v) is xsd:string.

Case 2:

Read into OWL2 processor, which applies the translation internally to "foo@"^^rdf:PlainLiteral.  Now query with SPARQL Basic Graph Matching.  This defines a framework, amongst other things, for new datatypes.  But this datatype spans plain literals as well in a way that was not described before.

Inside the SPARQL engine, does DATATYPE(?v) now give "rdf:PlainLiteral"?  At one time, the answer from an editor was "yes".  

Is that still the case?  If so, there is a change and so results of a query can change visibly (e.g. number of results) from the outside of the SPARQL processor.

Example: 
... FILTER (DATATYPE(?v) = xsd:string) ...
Or 
... FILTER (DATATYPE(?v) = rdf:PlainLiteral) ...

----

Text that does not cover it in my understanding:
Sec 1:
"""
rdf:PlainLiteral literals are written as RDF plain literals in RDF and SPARQL syntaxes.
"""
Not about SPARQL syntax.

Sec 4:
"""
the form of rdf:PlainLiteral literals in syntaxes for RDF graphs and for SPARQL is the already existing syntax for the corresponding plain literal, not the syntax for a typed literal.
"""
Not about SPARQL syntax.

Sec 4:
"""
this datatype MUST use plain literals (instead of rdf:PlainLiteral typed literals) whenever a syntax for plain literals is provided, such as in existing syntaxes for RDF graphs and SPARQL results.
"""
Not about results but close - no "syntax for a plain literal" is being provided - that would happen in the "SPARQL results" which are RDF graphs or SPARQL Query Results XML Format.  


I suggested explicit mention of SPARQL extended BGP matching.  Either that is necessary or if it is already covered, and does not no harm so I don't see the problem of including it.  But I'm met with strong pushback on that.



Please quote text from the rdf:PlainLiteral draft that is supposed to cover this.  There was a proposal using "binding" but I don’t see this in the draft.  It may be covered in some other way.  Or maybe it's impossible to define a SPARQL extended matching that is preserves compatibility of results across an RDF view and an OWL view.
 
Now I may well have missed the text in the doc, or a subsequent discussion in the many emails.  Just point me at the text - isn't that a reasonable request as a response to a comment?

 Andy

Received on Monday, 1 June 2009 17:06:39 UTC