FYI & also FWIW Surprisingly the RDF1.1 Turtle spec only talks about parsers, not writers. In section 2.3 the “object lists” are introduced and an example is given. No statement/qualification however is given about the desirability of using the abbreviation over the non-abbreviated form (which is indeed equivalent of course). I will investigate the intended view by the authors of the specs. Pure formally your output is conform Turtle (actually a subset of Turtle: Full Turtle without commas). Still I would find it personally more logical that your parser (that DOES support the object lists) would be on the same level as your writer. But ok, maybe you have good reasons why this is not the case.
Greetings, Michel Ps the actual text: “As with predicates often objects are repeated with the same subject and predicate. The objectList production<https://www.w3.org/TR/turtle/#grammar-production-objectList> matches a series of objects separated by ',' following a predicate. This expresses a series of RDF Triples with the corresponding subject and predicate and each object allocated to one triple. Thus, the ',' symbol is used to repeat the subject and predicate of triples that only differ in the object RDF term.” >From which you COULD derive: better use commas to avoid unnecessary >repetition. (the actual subject/predicate repetition is replaced by the short >comma). Dr. ir. H.M. (Michel) Böhms Senior Data Scientist T +31888663107 M +31630381220 E [email protected]<mailto:[email protected]> Location<https://www.google.com/maps/place/TNO+-+Locatie+Delft+-+Stieltjesweg/@52.000788,4.3745183,17z/data=!3m1!4b1!4m5!3m4!1s0x47c5b58c52869997:0x56681566be3b8c88!8m2!3d52.000788!4d4.376707> [cid:[email protected]]<http://www.tno.nl/> This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. TNO accepts no liability for the content of this e-mail, for the manner in which you use it and for damage of any kind resulting from the risks inherent to the electronic transmission of messages. From: [email protected] [mailto:[email protected]] On Behalf Of David Price Sent: woensdag 12 juli 2017 17:45 To: [email protected] Subject: Re: [topbraid-users] turtle support Hi Michel, FWIW most users who’ve ever expressed any interest wrt Turtle have been concerned more about how github and other diff tools work wrt Turtle files. That means a Turtle writer that, for example, that tries to remove inconsistencies in how the Turtle files are written to enable automated software development tools. Anyway, hope that clarifies what the standard says is required and how Composer works. Cheers, David UK +44 7788 561308 US +1 336 283 0606 On 12 Jul 2017, at 16:29, Bohms, H.M. (Michel) <[email protected]<mailto:[email protected]>> wrote: Hi David, Sorry, fully disagree. I would expect that a full Turtle implementation would implement all features of turtle. The ‘comma’-abbreviation is just a mechanism like the ;-abreviation and the []-abbreviation and saves in general space and time. Maybe not in in this specific example but in general it does (otherwise it wouldn’t have been a turtle design feature after all). The whole idea behind Turtle is providing syntactic sugar for triples. So it’s not about making turtle prettier, it’s about using all available turtle mechanisms…. A turtle implementation should be conform the formal Turtle grammar and since the comma-mechanism is just part of that grammer it should be supported. ( [8] objectList ::= object<https://www.w3.org/TR/turtle/#grammar-production-object> (',' object<https://www.w3.org/TR/turtle/#grammar-production-object>)* ) Anyway, let’s agree to disagree, Greetings Michel Ps a figure I made for explaining Turtle indicating the three main mechanisms (of which 2 are supporting by your implementation): [cid:[email protected]] Transforming (all 3 mechanisms combined): a1 b1 c1. a1 b2 c2. a1 b2 c3. a1 b3 c4. c4 b4 c5. Into: a1 b1 c1; b2 c2,c3; b3 [c4 b4 c5]. Dr. ir. H.M. (Michel) Böhms Senior Data Scientist T +31888663107 M +31630381220 E [email protected]<mailto:[email protected]> Location<https://www.google.com/maps/place/TNO+-+Locatie+Delft+-+Stieltjesweg/@52.000788,4.3745183,17z/data=!3m1!4b1!4m5!3m4!1s0x47c5b58c52869997:0x56681566be3b8c88!8m2!3d52.000788!4d4.376707> [cid:[email protected]]<http://www.tno.nl/> This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. TNO accepts no liability for the content of this e-mail, for the manner in which you use it and for damage of any kind resulting from the risks inherent to the electronic transmission of messages. From: [email protected]<mailto:[email protected]> [mailto:[email protected]] On Behalf Of David Price Sent: woensdag 12 juli 2017 17:07 To: [email protected]<mailto:[email protected]> Subject: Re: [topbraid-users] turtle support Hi Michel, Conforming Turtle implementations are required to read all valid forms of Turtle but are not required to maintain any manual formatting (or syntactic sugar) done in a text editor or by other Turtle writers. It’s a lot of not-very-usefule-coding to worry about trying to maintain that foreign formatting when RDF files have read from Turtle, been edited in Composer and are saved as Turtle. Composer users are not typically down in the weeds editing Turtle manually to try and make them prettier. FWIW in your example, the way Composer wrote the file is actually more efficient if editing/diff’ing files as line deletes/comparisons are quicker to perform - i.e. “efficient” is in the eye of the beholder. Cheers, David UK +44 7788 561308 US +1 336 283 0606 On 12 Jul 2017, at 15:42, Bohms, H.M. (Michel) <[email protected]<mailto:[email protected]>> wrote: Hi Richard, I understand (that they are equivalent) but you would expect full support of Turtle meaning support for all available ttl abbreviations types for the most efficient representation. Otherwise you could also forget all other ttl abbreviations types and be back at sets of triples only… 😊. Hope you agree….Greetings Michel Dr. ir. H.M. (Michel) Böhms Senior Data Scientist T +31888663107 M +31630381220 E [email protected]<mailto:[email protected]> Location<https://www.google.com/maps/place/TNO+-+Locatie+Delft+-+Stieltjesweg/@52.000788,4.3745183,17z/data=!3m1!4b1!4m5!3m4!1s0x47c5b58c52869997:0x56681566be3b8c88!8m2!3d52.000788!4d4.376707> [cid:[email protected]]<http://www.tno.nl/> This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. TNO accepts no liability for the content of this e-mail, for the manner in which you use it and for damage of any kind resulting from the risks inherent to the electronic transmission of messages. From: [email protected]<mailto:[email protected]> [mailto:[email protected]] On Behalf Of Richard Cyganiak Sent: woensdag 12 juli 2017 16:33 To: [email protected]<mailto:[email protected]> Subject: Re: [topbraid-users] turtle support Michel, On 12 Jul 2017, at 14:44, Bohms, H.M. (Michel) <[email protected]<mailto:[email protected]>> wrote: somple:Deck_1 rdf:type somple:Deck ; cmo:hasDirectPart somple:Slab_1, somple:Slab_2, somple:Slab_3 ; . Seems always rewritten after save by tbc into: somple:Deck_1 rdf:type somple:Deck ; cmo:hasDirectPart somple:Slab_1 ; cmo:hasDirectPart somple:Slab_2 ; cmo:hasDirectPart somple:Slab_3 ; . Is there a special reason, or is the turtle-abbreviation (“,”) type just not supported? The two snippets are equivalent. They encode the same RDF triples. The difference is simply that one uses more “syntactic sugar” than the other. When a Turtle file is opened in Composer and saved again, the file will contain the same data, but with different “cosmetics”. Composer generally doesn’t provide user control over these cosmetics like whitespace handling, order, use of abbreviations, etc. Best, Richard Thx Michel Dr. ir. H.M. (Michel) Böhms Senior Data Scientist T +31888663107 M +31630381220 E [email protected]<mailto:[email protected]> Location<https://www.google.com/maps/place/TNO+-+Locatie+Delft+-+Stieltjesweg/@52.000788,4.3745183,17z/data=!3m1!4b1!4m5!3m4!1s0x47c5b58c52869997:0x56681566be3b8c88!8m2!3d52.000788!4d4.376707> <image001.gif><http://www.tno.nl/> This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. TNO accepts no liability for the content of this e-mail, for the manner in which you use it and for damage of any kind resulting from the risks inherent to the electronic transmission of messages. -- You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]<mailto:[email protected]>. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]<mailto:[email protected]>. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]<mailto:[email protected]>. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]<mailto:[email protected]>. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]<mailto:[email protected]>. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]<mailto:[email protected]>. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
