- From: Thomas Lörtsch <tl@rat.io>
- Date: Thu, 19 Sep 2024 17:57:02 +0200
- To: RDF-star Working Group <public-rdf-star-wg@w3.org>
Hi all, I know it’s not the right time to discuss syntax, but I’d like to throw this in just so that it has been mentioned, for consideration at a later and more appropriate time. Best, Thomas ISSUES with the current syntax, and proposals: 1) Not everybody is happy with the new tilde '~' character used to demarcate an explicitly provided reification identifier. Why not stick to the pipe '|' character which is used in a few places already? Uniformity helps recognition. 2) We recently discussed a syntactic mechanism to constrain acceptable reifications to instances of many-to-one relations. Why not go the full way and provide syntaxes for both many-to-one and many-to-many reifications? 3) The shorthand annotation syntax uses curly brackets, although those are commonly reserved for graphs (an informal agreement for sure, but sensible). Why not demarcate annotations with square brackets, as is customary for attribution? 4) The different syntactic devices - (abstract) triple terms, (unasserted) reified terms, (shorthand) annotation syntax - diverge a lot from each other syntactically, using all sorts of brackets and other special characters. Why not try to always use the pipe '|' character, uniformly hinting at an RDF-star related construct? TRIPLE PROPOSAL, covering the many-to-one related issues: Triple term: :r rdf:reifies <<| :s :p :o |>> ; :a :b . Reified triple term: <| :s :p :o |> :a :b . <| :s :p :o | :r |> :a :b . Annotation syntax for triples: :s :p :o [| :a :b |] . :s :p :o | :r1 [| :a :b |] . GRAPH PROPOSAL to cover many-to-many applications: Graph term: :r rdf:reifies {{| :s1 :p :o . :s2 :p :o |}} ; :a :b . Reified graph term: {| :s1 :p :o . :s2 :p :o |} [| :a :b |] . {| :s1 :p :o . :s2 :p :o | :r2 |} [| :a :b |] . Annotation syntax for graphs: { :s1 :p :o . :s2 :p :o } [| :a :b |] . { :s1 :p :o . :s2 :p :o | :r2 } [| :a :b |] . - Note that there is logic to this. One doesn’t have to remeber every detail, but can deduce some variants from others. - Replacing the ~ by the | is not overly convincing visually, but at least it helps uniformity. - The [| … |] combination might not always be as readable as {| … |}, depending on font, but it aligns with other uses of square brackets in Turtle, and follows standard practice of encoding graphs and property lists. Imagine an annotation syntax for graphs that uses { … } for the graph and {| … |} for the annotation part - that might be quite irritating. - So it’s not all rosy, but IMHO it’s still an improvement. Remark: the following two ways to define :r would be completely equivalent: :r rdf:reifies {{| :s1 :p :o . :s2 :p :o |}} . :r rdf:reifies <<| :s1 :p :o |>>, <<| :s2 :p :o |>> .
Received on Thursday, 19 September 2024 15:57:10 UTC