Re: Basic machinery for annotations

Hi Thomas,

On Thu, Aug 15, 2024 at 5:50 PM Niklas Lindström <lindstream@gmail.com> wrote:
>
> Hi Thomas,
>
> This is where I think we see things quite differently:
>
> > Also the annotation syntax doesn’t roundtrip reliably
> >
> >     IN
> >     << :s :p :o >> :src :A .
> >     :s :p :o {| :src :B |} .
> >
> >     OUT
> >     :s :p :o {| :src :A |} .
> >     :s :p :o {| :src :B |} .
> >
> > There goes support for unasserted statements.
>
> I see no problem with the data here, apart from redundancy in the
> representations making them appear rather odd. But those two forms
> mean the same.
>
> The most terse form would be:
>
>     :s :p :o {| :src :A |} {| :src :B |} .
>
> And all forms mean:
>
>     :s :p :o .
>
>     _:r1 rdf:reifies <<( :s :p :o )>> .
>     _:r1 :src :A .
>
>     _:r2 rdf:reifies <<( :s :p :o )>> .
>     _:r2 :src :B .
>
> A very basic (or streaming "best-effort") Turtle serializer may very
> well end up with:
>
>     << :s :p :o ~ _:r1 >> .
>     :s :p :o .
>     _:r2 :src :B .
>     << :s :p :o ~ _:r2 >> .
>      _:r1 :src :A .
>
> Or some permutation thereof. That is perfectly valid and well-formed.
> Not *pretty*, of course, and a pretty-printer requires some more
> resources (memory/indexing).

I've understood you are worried about the annotation syntax somehow
not being roundtrippable. I wrote the above some weeks ago to shed
some more light on what the issue is. Do you have any questions or
disagreements with the above?

Best regards,
Niklas

> Best regards,
> Niklas

Received on Friday, 30 August 2024 13:40:17 UTC