For everybody who is confused about the various RDF serializations/syntaxes
A nice Venn diagram can be found in Tim BL's spec of Notation3 at http://www.w3.org/DesignIssues/Notation3 (Appendix).
Here is also a short overview:
- RDF/XML was the original serialization developed by the RDF Core Working Group (at the time when XML took off). A RELAX-NG Schema was defined for validation.
MIME Type: application/rdf+xml
Character encoding can be set by the XML encoding attribute
Usual file extension: .rdf - N3 is an alternative compact textual syntax with various add-ons introduced by Tim BL already in 1998. It has a greater expressivity of standard RDF/XML. A subset with equal expressivity of RDF/XML was defined later by Dave Backett as Turtle (see below).
MIME Type: text/rdf+n3
Character encoding is always UTF-8
Usual file extension: .n3 - N Triples is (only) used for the RDF Test Cases (it's unambiguous which is required for correct matching of testcases)
MIME Type: text/plain
Character encoding is limitted to 7-bit US-ASCII
Usual file extension: .nt - Turtle was introducd by Dave Beckett. By contrast to N Triples it supports abbreviations, @prefix, and grouping of multiple S-P pairs and objects which is also supported by N3, but it does not add features which cannot be expressed in RDF/XML.
MIME Type: application/turtle and application/x-turtle
Character encoding is always UTF-8
Usual file extension: .ttl
The SPARQL graph patterns are similar to Turtle with additional variable tokens and literals allowed for subjects.
- Login to post comments