Change: RDF Representation

created on Feb. 17, 2013, 10:12 p.m. by Hevok & updated on March 29, 2013, 9:45 a.m. by Hevok

There are several different Representations of RDF.

  1. Node-Edge-Node Triple (=Graph Representation)

    Subject -Predicate-> Object

  2. N3 Notation

    • Simple listing of Triples

      {,, }

    An alternative representation is the N3 Notation in which the for instance the three URI, i.e. for the resources, for Subject, Predicate and Object are separated by a comma and enclosed in curly braces. However, this gets for longer and more complicated knowledge pretty expensive.

  3. Turtle (Terse RDF Triple Language)

    • Extension of N3
    • URIs in angle brackets
    • Literals in quotation marks
    • Whitespace will be ignored

    The turtle language is a simplification of the N3 language. It uses URIs in angle brackets, Literals are given in quotation mark and every Triple ends with a period, while whitespaces within the Triple will be ignored.

    <Subject><Property><Object> .
    <Subject><Property>"Object" .

    In Turtle simple Triples/Statements look like that:


    In order to avoid long URIs there are shortcuts. For prefixes that are used rather often one has some ways to define certain prefixes via declaring a namespace:

    @prefix xsd: <>] .
    @prefix dc: <>] .
    @prefix ex: <>] .
        dc:title "RDF/XML Syntax Specification (Revised)"@en ;
        ex: editor [
            ex:fullname "Dave Beckett"^^xsd:string ;
            ex:homePage <>]

    So prefixes will be substituted in the statements. Here editor defines a blank node with Value and a resources associated to it.

  4. RDF XML-Serialization*

    • RDF can be written in XML but it is less readable and becomes more. RDF XML-Serialization is the standard for each Web document, therefore it can be embedded very simple into the web, because XML can be read by most text processors and parsers. RDF can be read from and written in XML.


<xml version="1.0" encoding="utf-8">
<rdf:RDF xmlns:rdf=""

    <rdf:Description rdf:about=">]

    <rdf:Description rdf:about="">]
        <prof:hasBlog rdf:resource="" />]

Shortcut version with base Definition:

<xml version="1.0" encoding="utf-8">
<rdf:RDF xmlns:rdf=""

    <rdf:Description rdf:about="Hevok
        <prof:hasBlog rdf:resource="blog" />

If there is not base URI, relatives paths refer to the URI where the Document itself is located.



Comment: Updated entry

See entry | Admin

Comment on This Data Unit