- From: Daniel Hernandez <daniel@degu.cl>
- Date: Fri, 21 Jan 2022 12:13:03 +0100
- To: Gregg Kellogg <gregg@greggkellogg.net>
- Cc: Public Rdf Ruby <public-rdf-ruby@w3.org>
Hi all, Gregg Kellogg writes: > Of course, there is no real standard for expressing queries as > s-expressions, but Ruby RDF generally follows Jena. (Creating a > normative S-Expression representation would be interesting, though). I agree on that a normative for S-Expressions would help for interoperability. > I’m not sure if this is intentional on Andy’s part, as `triple << ?bob > foaf:age ?age >> ex:certainty ?c)` doesn’t really look like an > S-Expression to my eyes, and the “triple” expression has already been > established, but using that embedded triple expression made the most > sense to me. It does lead to some complications in re-serializing, as > SPARQL-star does have a TRIPLE function, which gets the same > representation in Ruby RDF, and distinguishing between their use took > some doing, but internally, it’s never been an issue. Gregg, I agree with you on that the notation <<...>> doesn't look as look as an S-Expression. Hence, this notation requires implementing an additional type of parenthesis. Indeed, if S-Expressions allow for the notation <<...>>, then it is also needed to support nested triple expressions, for example << << ?s ?p ?o >> ?q ?r >> ?s ?v. > I wasn’t able to get qparse to parse either form of S-Expression, but > that’s likely an operator error. I have tested how Jena parse both forms, and seems that Jena support both forms. It translates << ?s ?p ?o >> as an embedded triple expression << ?s ?p ?o >>, whereas (triple ?s ?p ?o) is translated as the triple function triple(?s, ?p, ?o). Daniel
Received on Friday, 21 January 2022 11:13:24 UTC