Alternative path expression syntax?

On 07/28/2014 04:52 AM, Pierre-Antoine Champin wrote:
>
> - Paths could not be simplified without losing expressivity, I think. 
> Sincerely, I find then significantly simpler than BGPs, so if people 
> find them complicated, I tend to think that it is due to the way we 
> described them more than to the syntax itself.
>

Let me expand on a previous point elsewhere.   I think it would help the 
path syntax were more obvious and didn't feel like some new bit of design.

Hm.  Looking at your example, you're using schema:attendee backwards.   
That was probably one more thing that confused me in looking at the path 
example.   It's { event attendee person } and you're using it as { 
person attendee event }.   I'll call it attendeeOf for now.

I find the path example:

    Bind ?event <#> /schema:attendeeOf[/schema:url =
    <http://conferences.ted.com/TED2009/>] .

maybe more confusing than the BGP:

    <#> schema:attendeeOf ?x.
    ?x schema:url <http://conferences.ted.com/TED2009/>.

But as I think about it, I'm wondering about just using Turtle (extended 
with ^ for inverse arcs, which ALMOST made it into Turtle, but is in 
SPARQL).  Something like:

    BIND ?event [ ^schema:attendeeOf <#>; schema:url
    <http://conferences.ted.com/TED2009/> ]

Semantics are you parse it as Turtle [extended with ^] to get a rooted 
graph, then do a graph match, which must be unitary.

Basically, the "path expression" now it looks like the bit of turtle 
that would have been used to create the blank node you're trying to 
match, with the added inverse arcs if you happen to know them.

       -- Sandro

|
|

Received on Monday, 28 July 2014 19:01:52 UTC