- From: Sandro Hawke <sandro@w3.org>
- Date: Mon, 22 Jul 2013 08:12:48 -0400
- To: Ivan Mikhailov <imikhailov@openlinksw.com>
- CC: W3C RDF WG <public-rdf-wg@w3.org>
On 07/21/2013 05:43 AM, Ivan Mikhailov wrote: > On Tue, 2013-07-16 at 20:53 -0400, Sandro Hawke wrote: >> I know this is going to seem to some people like it's going too far, >> but it seems to me like such a good idea, in good conscience I have to >> at least seriously propose it. If there aren't at least three +1's >> for this email, I wont mention it again. >> >> Right now, in TriG, you can say things like: >> [ a :Patch; >> :deletes _:g1; >> :inserts _:g2 ]. >> GRAPH _:g1 { ... } >> GRAPH _:g2 { ... } >> >> I think it would make a whole lot of sense to allow a little syntactic >> sugar. I'd like to allow this: >> [ a :Patch; >> :delete { ... }; >> :inserts { ... } ]. > I'm sorry, the syntax { triple . triples . triples ... } is in use for > blank node formulas in some dialects. > > SQL> TTLP ('<s> <p> { <s1> <p1> <o1> , <o2> } .', 'http://example.com/', > 'http://example.com/'); > > SQL> sparql define output:format "NICE_TTL" with <http://example.com/> > construct where { ?s ?p ?o }; > fmtaggret-NICE_TTL > LONG VARCHAR > _______________________________________________________________________________ > > > @prefix ns0: <http://example.com/> . > @prefix ns1: <http://www.w3.org/2000/10/swap/reify#> . > @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . > > ns0:s > ns0:p [ ns1:statement [ rdf:type > rdf:Statement ; > rdf:object ns0:o1 ; > rdf:predicate ns0:p1 ; > rdf:subject ns0:s1 > ] , > [ rdf:type > rdf:Statement ; > rdf:object ns0:o2 ; > rdf:predicate ns0:p1 ; > rdf:subject ns0:s1 ] > ] . > ns0:s1 > ns0:p1 ns0:o1 , ns0:o2 . So you like the syntax, you just want to use it for RDF Reification instead of RDF Datasets. If we didn't have datasets, I'd probably like that design a lot. But this is TriG, which is a dataset syntax. If people want to use RDF Reification, then it seems to me TriG is not the right language for them. > > So I'd strongly insist on disambiguation keyword like > > [ a :Patch; > :delete GRAPH { ... }; > :inserts GRAPH { ... } ]. > > or something like that if the feature is ever introduced. Alternatively, OpenLink could use a keyword for this reification extension, like ":delete REIFIED { ... }" or (in keeping with the encoding you're using) ":delete STATEMENTS { ... }". That would have a much better chance of being accepted in SPARQL some day, I think. It seems pretty unlikely to me that a future SPARQL WG would ever endorse this extension, with its use of reification, the way you have it. Of course, what I really wish is that we could really solve the underlying problem by making Datasets and Reification be interoperable. I don't know a way to do that, technically, since reification is referentially transparent and datasets are referentially opaque. Maybe no one cares about that distinction, and we can just by fiat make Reification also opaque, with some magical handwaving. The idea is to somehow end up with: <s> <p> ?x. ?x rdf:subject <s1>; rdf:predicate <p1>; rdf:object <o1>. being somehow equivalent to (and interoperable with): <s> <p> ?x. GRAPH ?x { <s1> <p1> <o1> } (for all ?x). Anyone think that's possible? -- Sandro > Best Regards, > > Ivan Mikhailov > OpenLink Software > http://virtuoso.openlinksw.com > > >
Received on Monday, 22 July 2013 12:12:55 UTC