Dataset semantics, was Re: First meeting of our group

On 12/16/18 5:43 PM, Ruben Verborgh (UGent-imec) wrote:
> On 12 Dec 2018, at 00:34, Sandro Hawke <sandro@w3.org> wrote:
>>> _:g1 { _:x :wrote _:y.  _:y log:includes _:g2 . _:x :livesIn _:z}
>>> _:g2 {_:z :weather _:w}
>>> _:g3 {<Boston> :weather _:y}
>>> _:g1 log:implies _:g3 .
>>>
>> Yes, I'm still quite grumpy we didn't include this.  It's trivial syntactic sugar, and would have made generalized Trig a superset of N3 at the syntactic level, or very close to it.
> The above is how I represent parsed N3 graphs in my N3.js library.
>
> There’s one very awkward detail to it though:
> in TriG, there is no guarantee that _:g1 as a graph label
> and _:g1 as the label of a subject are pointing to the same thing.
>
> I know you explicitly wrote “syntactic level”,
> but the lack of such semantics is a problem,
> because there is no way that I can state
>     “the graph _:g1 and the subject _:g1 are the same thing”,
> since I cannot refer to "the graph _:g1” in subject position.
>
> The only way I can think of to fix this,
> is to start a document with a triple such as
>      <> ex:graphLabelsSameAsEntityLabels true.
> but that is not very convenient either.
>

Right.  To be clear, this isn't about TriG, it's about RDF Datasets, aka 
Named Graphs, which are also used in SPARQL, JSON-LD, and N-Quads.

I've now written this up as an issue on the new repo: 
https://github.com/w3c/N3/issues/1

In writing it up, I thought through the issue some more and changed my 
mind several times, but I came to a fairly firm conclusion, for myself.  
I'll be interested to hear where other people land.

       -- Sandro

Received on Monday, 17 December 2018 15:30:31 UTC