Re: in...of syntax Re: Turtle Last Call: Request for Review

Andy Seaborne wrote:
> 
> I curious about this proposal and was hoping to see a full design.
> 
> How does this work with object lists "," (easy?) and propertyObject 
> lists ";" (trickier?).
> 
> 
> In SPARQL it's a path connecting two graph nodes with matching reversed. 
>  For syntax, the positional slots are used by object lists and 
> property-object lists.
> 
> Example:
> 
> :x ^:p :z1, :z2 ;
>    :q :z3 ;
>    ^:r :z4 .
> 
> is the same as:
> 
> :x ^:p :z1 .
> :x ^:p :z2 .
> :x  :q :z3 .
> :x  ^:r :z4 .
> 
> and equivalent in matching to:
> 
> :z1 :p :x .
> :z2 :p :x .
> :x  :q :z3 .
> :z4 :r :x .

The above seems perfectly natural and logical imo.

> So while ^:p can be the same as SPARQL it isn't quite for the same 
> reason.  This may make explaining it all tricky.

SPARQL is a different spec, used for different reasons, I can't 
personally see what there is to explain.

If:
   :x :p :z1, :z2 ;
      :q :z3 ;
      :r :z4 .

is the same as:
   :x :p :z1 .
   :x :p :z2 .
   :x :q :z3 .
   :x :r :z4 .

in both languages, then:
   :x ^:p :z1, :z2 ;
     :q :z3 ;
     ^:r :z4 .

should be the same as
   :x ^:p :z1 .
   :x ^:p :z2 .
   :x  :q :z3 .
   :x  ^:r :z4 .

in both languages, and equivalent to
   :z1 :p :x .
   :z2 :p :x .
   :x  :q :z3 .
   :z4 :r :x .

Honestly, what's the tricky difference that needs explained, and why 
would anybody need or want to know it?

Best,

Nathan


> On 30/07/12 10:05, Ivan Herman wrote:
>> (Sorry for the late reaction, I was on vacations...)
>>
>>
>> The ^P formalism and syntax is already part of the SPARQL 1.1 query 
>> language, part of the property path features. Ie, if adopted in 
>> Turtle, it would not create any compatibility problems with SPARQL 1.1 
>> (which would not be the case with the 'is ... of' syntax).
>>
>> RDFa has the @rev attribute that is used for the same purpose. In my 
>> own practice @rev is not used very often; however, when it is, it is 
>> damn useful, that is for sure...
>>
>> _Personally_, I would be in favour adding ^P to Turtle.
>>
>> Caveat: if we do that, Turtle would have to go through a second last 
>> call. Sigh...
>>
>> Ivan
>>
>>
>> On Jul 18, 2012, at 15:02 , Souripriya Das wrote:
>>
>>> I too would prefer the use of ^P (to indicate opposite direction of 
>>> edge) than use of "is P of" for the same reasons that Dan cited.
>>>
>>> Thanks,
>>> - Souri.
>>>
>>> ----- Original Message -----
>>> From: steve.harris@garlik.com
>>> To: danbri@danbri.org
>>> Cc: public-rdf-comments@w3.org
>>> Sent: Wednesday, July 18, 2012 7:44:34 AM GMT -05:00 US/Canada Eastern
>>> Subject: Re: in...of syntax Re: Turtle Last Call: Request for Review
>>>
>>> On 2012-07-18, at 12:27, Dan Brickley wrote:
>>> …snip…
>>>>> A massive +1. Having been burned by that in the past, it is indeed 
>>>>> a very good argument for it.
>>>>>
>>>>> The argument about generating Turtle data from pre-existing hashes 
>>>>> is also a very good one. I've written a few of these 'RDFizers' in 
>>>>> the past, just recursively going through a hash and outputting a 
>>>>> string that happens to be valid Turtle (see 
>>>>> https://github.com/moustaki/bbc-serialiser for example, which is 
>>>>> currently in use on a few BBC websites) - and having a way to write 
>>>>> triples in both directions make that a *lot* easier...
>>>>
>>>> If (a) it could be done identically in SPARQL 1.1 and Turtle (b) it
>>>> was done with punctuation (e.g. ^) rather than pseudo-English, i'd be
>>>> supportive.
>>>>
>>>> (Is 'is isPrimaryTopicOf of' the same as 'primaryTopic'? The existence
>>>> of isPrimaryTopicOf is a good reason for exploring such a design...)
>>>>
>>>> Every difference we create between SPARQL and Turtle diminishes the
>>>> value and teachability of both…
>>>
>>> +1
>>>
>>> - Steve
>>>
>>> -- 
>>> Steve Harris, CTO
>>> Garlik, a part of Experian
>>> +44 7854 417 874  http://www.garlik.com/
>>> Registered in England and Wales 653331 VAT # 887 1335 93
>>> Registered office: Landmark House, Experian Way, Nottingham, Notts, 
>>> NG80 1ZZ
>>>
>>>
>>>
>>
>>
>> ----
>> Ivan Herman, W3C Semantic Web Activity Lead
>> Home: http://www.w3.org/People/Ivan/
>> mobile: +31-641044153
>> FOAF: http://www.ivan-herman.net/foaf.rdf
>>
>>
>>
>>
>>
>>
> 
> 

Received on Monday, 30 July 2012 11:05:05 UTC