RDF or Resource Description Framework is a generic model for describing objects and data. The basic unit of RDF is the triple, which consists of a subject, predicate, and object.


RDF/XML is a common representation, and unfortunately is intimidating, miserable to work with by hand, and just barely gets by as human unreadable (it's designed for machine consumption).

RDF/N-triples (aka RDF/N3) is a quick-and-easy representation by Tim-Berners Lee. He has a beginner's N3 primer.

Turtle is another natural language-looking, N3-like syntax by Dave Beckett.

RDF/JSON is a description for RDF in JSON, perfect for use in browser-based web applications. Freebase also uses some kind of RDF-in-JSON representation, though different.

JSON-LD (JSON for Linked Data) is another RDF-in-JSON format which appears to be easier to integrate into existing JSON documents (à la adds namespacing to JSON).

Dave Beckett has a summary on various RDF representations in 2010.


RDFa is a mechanism for embedding RDF triples in HTML attributes.


Representing dates

Since HTML5's <time> element is dead, something like:

   1 <span property="dc:date">2011-11-03</span>


   1 <span prefix="dc: http://purl.org/dc/elements/1.1/ xsd: http://www.w3.org/2001/XMLSchema" property="dc:date" content="2011-11-03T03:00Z" datatype="xsd:datetime">
   2 Nov 03, 2011
   3 </span>

where the date is represented in W3CDTF (a variant of ISO 8601).

Competing formats

Microformats are oriented around special attribute values that go into elements' class= attributes. It has no support for namesspaces. It is not compatible with RDF.

Microdata is a section of the draft HTML5 specification that adds a set of new attributes (itemprop, etc) to better expose data than microformats. Has some kind of support for namespaces. It can be made compatible with RDF.


SamatsWiki: RDF (last edited 2011-11-15 06:48:47 by SamatJain)