Simple example of reification in RDF

Stefano Borini picture Stefano Borini · Aug 21, 2009 · Viewed 11.8k times · Source

Could anybody be so kind to give me a simple example of reification in RDF? I want to see if I understood it correctly.

For example, I propose the following case

Tolkien -> wrote -> Lord of the rings
           /|\
            |
        Wikipedia said that

How would you write it with and without reification (i.e. as a simple RDF statement with no need for reification)?

Answer

Jukka Matilainen picture Jukka Matilainen · Aug 22, 2009

"Tolkien wrote Lord of the Rings" can be expressed as a simple statement (subject, predicate, object) like this:

:Tolkien :wrote :LordOfTheRings .

By the way, this is using the Turtle notation for RDF. There are tools online for converting it to RDF/XML.

Using reification, you can have a separate resource representing a statement so you can state additional things about the statement itself, like "Wikipedia said that":

@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
_:x rdf:type rdf:Statement .
_:x rdf:subject :Tolkien .
_:x rdf:predicate :wrote .
_:x rdf:object :LordOfTheRings .
_:x :said :Wikipedia .

In real life, you would want to use shared vocabularies, so that whoever or whatever is consuming the RDF will know that you are talking about that Tolkien and that LOTR:

http://dbpedia.org/resource/The_Lord_of_the_Rings
http://dbpedia.org/property/author
http://dbpedia.org/resource/dbppedia/J._R._R._Tolkien