#1161: WG New Spec: RDF 1.2 N-Triples
Discussions
Log in to see TAG-private discussions.
Discussed
Oct 27, 2025 (See Github)
Sarven isn't here.
Discussed
Dec 1, 2025 (See Github)
(Sarven isn't here today)
Discussed
Dec 8, 2025 (See Github)
Skipped
Comment by @csarven Dec 18, 2025 (See Github)
The TAG thanks the RDF & SPARQL WG for requesting this review and for the detailed discussion.
The TAG recommends the following:
The line based plain text format of RDF 1.1 N-Triples made it possible to concatenate multiple files using simple tools. Aside from encoding N-Triples data in Turtle documents, as indicated by file extension or media type, the line based characteristic, which is the defining feature of N-Triples, appears to be weakened by the introduction of version declarations in the content. If concatenation of multiple N-Triples documents remains an important affordance of the format, the specification should note this change more clearly and define the expected parsing behaviour. The N-Triples specification, and potentially other concrete RDF syntaxes that introduce in content version declarations, should also clarify how multiple version declarations within a single document are to be interpreted.
We suggest clarifying the behaviour when mixing N-Triples data that declares different versions, e.g., 1.2, 1.2-basic, and 1.1.
As currently specified, these changes appear to add complexity to the format. We encourage addressing concerns around version announcement at a higher level, such as in RDF 1.2 Concepts and Abstract Data Model. A related TAG review can be found at https://github.com/w3ctag/design-reviews/issues/1159#issuecomment-3671161845
The IANA version parameter registration for the N-Triples media type should avoid normative language that uses requirement levels (as the ones defined in RFC 2119, RFC 8174), as noted in https://github.com/w3c/rdf-n-triples/issues/84 . This concern similarly applies to other parameters and to updates to media types of other concrete RDF syntaxes.
This review reflects the TAG's current assessment and is intended to support the Working Group's next steps. We are happy to discuss further if clarification is needed.
Comment by @pchampin Dec 19, 2025 (See Github)
Thanks for this review.
Re. concatenation: concatenating two N-Triples files results in a compliant N-Triples file. This was the case in RDF 1.1 and is still the case in RDF 1.2. Note however that such concatenation was never without risk: identical blank node labels in the files being concatenated will result in (possibly) unintended merging of blank nodes. So yes, concatenating an N-Triples 1.1 file with an N-Triples 1.2 file "contaminates" the first one with 1.2 features, and this should only be done after careful consideration. But careful consideration was already required before concatenating N-Triples 1.1 files with each other (because of blank nodes).
We suggest clarifying the behaviour when mixing N-Triples data that declares different versions, e.g., 1.2, 1.2-basic, and 1.1.
Good point, see w3c/rdf-turtle#118
We will also address https://github.com/w3ctag/design-reviews/issues/1159#issuecomment-3671161845 and w3c/rdf-n-triples#84 .
Comment by @csarven Dec 19, 2025 (See Github)
Thanks for following up.
The specific concatenation scenario about when multiple version declarations are included was about the grammar rather than contamination, noting (with fresh eyes) that https://www.w3.org/TR/rdf12-n-triples/#sec-grammar-grammar indeed permits multiple directives in a given document. The referenced issues will help clarify. I mentioned one additional case to consider at https://github.com/w3c/rdf-turtle/issues/118#issuecomment-3674111046 - when a triple does not precede with a version directive.
OpenedOct 21, 2025
Specification
https://www.w3.org/TR/rdf12-n-triples/
Explainer
https://www.w3.org/TR/rdf12-primer/
Links
The specification
Where and by whom is the work is being done?
Feedback so far
You should also know that...
No response
<!-- Content below this is maintained by @w3c-tag-bot -->Track conversations at https://tag-github-bot.w3.org/gh/w3ctag/design-reviews/1161