- From: Andy Seaborne <andy@apache.org>
- Date: Sun, 14 Apr 2024 21:34:44 +0100
- To: public-rdf-star-wg@w3.org
On 12/04/2024 20:40, Kurt Cagle wrote:
...
> I was at an IA conference yesterday, and the question of reification was
> raised in several different contexts. I think it's important to remember
> that reification is significant primarily because it is accommodating
> (syntactically) parity with a neo4j construct.
>
> That is to say:
>
> :s :p :o .
> :s a rdf:type .
> << :s :p :o >> :p1 :o1; :p2 :o2 .
:s :p :o .
:s a rdf:type .
# syntax expansion.
_:b rdf:reifies <<( :s :p :o )>> .
_:b :p1 :o1.
_:b :p2 :o2 .
>
> is the equivalent of a neo4j assertion with two properties on its "edge".
>
>
> What I see here is that we're also attempting to create an assignment
> statement with reifiers in Turtle:
>
> <<(:r | :s :p :o )>>
Is that proposal to have named triples?
Or was that the syntax
<< :r | :s :p :o >>
?
A second << :r1 | :s :p :o >> "assigns" :r1 as a different name for tjhe
occurrence.
In words, an occurrence (usage) named :r, and one name :r1, of the
triple :s :p :o (there is at most one triple :s :p :o ).
An edge is more like an occurrence - a usage of a triple. Multiple edges
are multiple occurrences each of which can have different annotations.
(The triple occurrence / triple type language has slipped a bit.)
> when this is an operation that is normally done in SPARQL:
>
> bind (<<:s :p :o>> as ?r)
That could be:
bind (<<( :s :p :o )>> as ?tripleTerm)
Binding the triple term -- all <<( :s :p :o )>> are the same RDF term.
From a triple term, you can get the subject.
SUBJECT(?tripleTerm) --> :s
For the forms
bind (<< :s :p :o >> as ?r)
bind (<< :e | :s :p :o >> as ?r)
<<:s :p :o>> isn't an RDF term. This BIND form would have a side effect
of making a blank node or URI :e and assigning it to ?r.
But there is no way to get back from ?r to the parts of ":s :p :o" --
SUBJECT(?r) doesn't work (unless we have "special" bnodes and URIs!).
Having it as a triple
_:b rdf:reifies <<( :s :p :o )>> .
means a SPARQL query can find the subject:
?X rdf:reifies ?T .
bind (SUBJECT(?T) as ?subj)
Andy
Received on Sunday, 14 April 2024 20:34:50 UTC