<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/xsl" href="xmlspec.xsl"?>
<!DOCTYPE spec PUBLIC "-//W3C//DTD Specification V2.1//EN"
     "http://www.w3.org/XML/1998/06/xmlspec-v21.dtd" [
    <!ENTITY note.name "RDFa Primer">
    <!ENTITY version "">
    <!ENTITY XFormsNS "http://www.w3.org/2002/xforms">
    <!ENTITY prev-dd "10">
    <!ENTITY prev-mm "03">
    <!ENTITY prev-year "2006">
    <!ENTITY dd "01">
    <!ENTITY MM "October">
    <!ENTITY mm "10">
    <!ENTITY year "2006">
    <!ENTITY iso.doc.date "&year;&MMDD;">
    <!ENTITY MMDD "&mm;&dd;">
    <!ENTITY ne "≠">
    <!ENTITY ouml "ö">
    <!ENTITY times "×">
    <!ENTITY order "£">
    <!ENTITY le "≤">
    <!ENTITY cellback "#d0d9fa">
    <!ENTITY eacute "é">
    <!ENTITY copy "©">
    <!ENTITY sect "§">
    <!ENTITY mdash "&#8212;">
]>
<!-- "http://www.w3.org/XML/1998/06/xmlspec-v21.dtd" -->
<spec w3c-doctype="draft">
    <header>
        <title>RDFa Primer</title>
        <subtitle>Bridging the Human and Data Webs</subtitle>
        <version>&version;</version>
        <w3c-designation>Internal Working Draft</w3c-designation>
        <w3c-doctype>Editors' Draft</w3c-doctype>
        <!-- notice>Notice this!!</notice -->
        <publoc>
            $Id: Overview.xml,v 1.60 2008/12/01 20:15:48 adida Exp $
        </publoc>
		<pubdate>
			<day>13</day>
			<month>October</month>
			<year>2008</year>
		</pubdate>
        <prevlocs>
  <loc href="http://www.w3.org/2006/07/SWD/RDFa/primer/20081013/">http://www.w3.org/2006/07/SWD/RDFa/primer/20081013/</loc>
        </prevlocs>
        <latestloc>
    <loc href="http://www.w3.org/2006/07/SWD/RDFa/primer">http://www.w3.org/2006/07/SWD/RDFa/primer</loc>
        </latestloc>
        <authlist>
            <author>
                <name>Ben Adida</name>
                <affiliation>Creative Commons</affiliation>
                <email href="mailto:ben@adida.net">ben@adida.net</email>
            </author>
            <author>
                <name>Mark Birbeck</name>
                <affiliation>webBackplane</affiliation>
                <email href="mailto:mark.birbeck@webBackplane.com">mark.birbeck@webBackplane.com</email>
            </author>
        </authlist>
        <abstract>
            <p>
                Today's web is built predominantly for human consumption. Even as machine-readable data begins to appear on the web, it is typically distributed in a separate file, with a separate format, and very limited correspondence between the human and machine versions. As a result, web browsers can provide only minimal assistance to humans in parsing and processing web data: browsers only see presentation information. We introduce RDFa, which provides a set of XHTML attributes to augment visual data with machine-readable hints. We show how to express simple and more complex datasets using RDFa, and in particular how to turn the existing human-visible text and links into machine-readable data without repeating content.
            </p>
            <p>
            This document provides only a Primer to RDFa. The normative specification of RDFa can be found in <bibref ref="RDFA-SYNTAX" />.
        </p>
        </abstract>
        <status>

          <p> This is an internal draft produced by the Semantic Web
          Deployment Working Group <bibref ref="SWD-WG" />, in cooperation
          with the XHTML2 Working Group <bibref ref="XHTML2-WG" />. Initial
          work on RDFa began with the Semantic Web Best Practices and
          Deployment Working Group <bibref ref="SWBPD-WG" /> and the HTML
          Working Group <bibref ref="HTML-WG" /> as was, now the XHTML2
          Working Group. </p>

      <p>
        This document is for internal review only and is subject
        to change without notice. This document has <em>no formal
        standing within the W3C</em>.
      </p>
            <p>
<!--                <emph>Last Modified: &year;-&mm;-&dd;</emph>-->
            </p>
        </status>
        <languages>
            <language>en</language>
        </languages>
        <revisiondesc>
            <p>
                <emph>Last Modified: $Id: Overview.xml,v 1.60 2008/12/01 20:15:48 adida Exp $</emph>
            </p>
        </revisiondesc>
    </header>
    <body>
  	<div1>
		<head>Introduction</head>
		
		<p>
			The web is a rich, distributed repository of interconnected information organized primarily for human consumption. On a typical web page, an XHTML author might specify a headline, then a smaller sub-headline, a block of italicized text, a few paragraphs of average-size text, and, finally, a few single-word links. Web browsers will follow these presentation instructions faithfully. However, only the human mind understands that the headline is, in fact, the blog post title, the sub-headline indicates the author, the italicized text is the article's publication date, and the single-word links are categorization labels. The gap between what programs and humans understand is large.
		</p>
		
		<graphic source="diagrams/presentation-vs-semantics.png" caption="On the left, what browsers see. On the right, what humans see. Can we bridge the gap so browsers see more of what we see?"/>
		
		<p>
			What if the browser received information on the meaning of a web page's visual elements? A dinner party announced on a blog could be easily copied to the user's calendar, an author's complete contact information to the user's address book. Users could automatically recall previously browsed articles according to categorization labels (often called tags). A photo copied and pasted from a web site to a school report would carry with it a link back to the photographer, giving her proper credit. When web data meant for humans is augmented with hints meant for computer programs, these programs become significantly more helpful, because they begin to understand the data's structure.
		</p>
		
		<p>
			RDFa allows XHTML authors to do just that. Using a few simple XHTML attributes, authors can mark up human-readable data with machine-readable indicators for browsers and other programs to interpret. A web page can include markup for items as simple as the title of an article, or as complex as a user's complete social network.
		</p>
			
		<p> RDFa benefits from the extensive power of RDF <bibref ref="RDF" />, the W3C's standard for interoperable machine-readable data. However, readers of this document are not expected to understand RDF. Readers <em>are</em> expected to understand at least a basic level of XHTML.
		</p>
			
        <div2>
            <head>HTML vs. XHTML</head>
            
            <p>
                To date, because XHTML is extensible while HTML is not, RDFa has only been specified for XHTML 1.1. Web publishers are welcome to use RDFa markup inside HTML4: the design of RDFa anticipates this use case, and most RDFa parsers will recognize RDFa attributes in any version of HTML. The authors know of no deployed Web browser that will fail to present an HTML document as intended after adding RDFa markup to the document. However, publishers should be aware that RDFa will not validate in HTML4 at this time. RDFa attributes validate in XHTML, using the XHTML1.1+RDFa DTD.
            </p>
        </div2>
	</div1>
    <div1>
		<head>Adding Flavor to XHTML</head>
		
		<p>
			Consider Alice, a blogger who publishes a mix of professional and personal articles at <code>http://example.com/alice</code>. We will construct markup examples to illustrate how Alice can use RDFa. The complete markup of these examples can <a href="alice-example.html">be viewed independently</a>.
		</p>
		
		<div2>
			<head>Licensing your Work</head>
			
			<p>
				In her blog's footer, Alice declares her content to be freely reusable, as long as she receives due credit when her articles are cited. The XHTML includes a link to a Creative Commons <bibref ref="CC" /> license:
			</p>
			
    <eg><![CDATA[...
All content on this site is licensed under
<a href="http://creativecommons.org/licenses/by/3.0/">
    a Creative Commons License
</a>.
]]></eg>

			<p>
				A human clearly understands this sentence, in particular the <em>meaning</em> of the link with respect to the current document: it indicates the document's license, the conditions under which the page's contents are distributed. Unfortunately, when Bob visits Alice's blog, his browser sees only a plain link that could just as well point to one of Alice's friends or to her resume. For Bob's browser to understand that this link actually points to the document's licensing terms, Alice needs to add some <em>flavor</em>, some indication of what <em>kind</em> of link this is.
		    </p>
		
			<p>
				She can add this flavor using the <att>rel</att> attribute (which we'll write as <att>@rel</att> so as not to repeat the word "attribute" too often), which defines the <em>relationship</em> between the current page and the linked page. The value of the attribute is <code>license</code>, an XHTML keyword reserved for just this purpose:
			</p>

    <eg><![CDATA[...
All content on this site is licensed under
<a ]]><highlight>rel="license"</highlight><![CDATA[ href="http://creativecommons.org/licenses/by/3.0/">
    a Creative Commons License
</a>.
]]></eg>

			<p>
				With this small update, Bob's browser will now understand that this link has a flavor: it indicates the blog's license.
			</p>
			
			<graphic source="diagrams/license.png" caption="A link with flavor: the link indicates the web page's license. We can represent web pages as nodes, the link as an arrow connecting those nodes, and the link's flavor as the label on that arrow." />
		</div2>
		
		<div2>
			<head>Labeling the Title and Author</head>
			
			<p>
				Alice is happy that adding XHTML flavor lets Bob find the copyright license on her work quite easily. But what about the article title and author name? Here, instead of marking up a link, Alice wants to augment existing text within the page. The title is a headline, and her name a sub-headline:
			</p>

		    <eg><![CDATA[<div>
   <h2>The trouble with Bob</h2>
   <h3>Alice</h3>
   ...
</div>]]></eg>

			<p>
				To indicate that <el>h2</el> represents the title of the page, and <el>h3</el> the author, Alice uses <att>@property</att>, an attribute introduced by RDFa for the specific purpose of marking up existing text in an XHTML page.
			</p>

		    <eg><![CDATA[<div ]]><highlight>xmlns:dc="http://purl.org/dc/elements/1.1/"</highlight><![CDATA[>
   <h2 ]]><highlight>property="dc:title"</highlight><![CDATA[>The trouble with Bob</h2>
   <h3 ]]><highlight>property="dc:creator"</highlight><![CDATA[>Alice</h3>
   ...
</div>]]></eg>

			<p>
				Why use <code>dc:creator</code> and <code>dc:title</code>, instead of simply <code>creator</code> and <code>title</code>? As it turns out, XHTML does not have reserved keywords for those two concepts. Alice could boldly choose to write <code>property="title"</code>, but how does a program reading this know whether "title" here refers to the title of a work, a job title, or the deed for some real-estate property? And, if every web publisher laid claim to their own short keywords, the world of available properties would become quite messy, a bit like saving every file on a computer's desktop without any directory structure to organize them.
			</p>
			
			<p>
				To enforce a modicum of organization, RDFa does not recognize <code>property="title"</code>. Instead, Alice must indicate a directory somewhere on the web, using simply a URL, from where to import the specific <code>creator</code> and <code>title</code> concepts she means to express. Fortunately, the Dublin Core <bibref ref="DC" /> community has already defined a vocabulary of useful concepts for describing documents, including both <code>creator</code> and <code>title</code>, where <code>title</code> indeed means the title of a work. So, Alice:</p>
			<ol>
				<li> imports the Dublin Core vocabulary using <code>xmlns:dc="http://purl.org/dc/elements/1.1/"</code>, which associates the prefix <code>dc</code> with the URL <code>http://purl.org/dc/elements/1.1/</code>, and</li>
			 	<li> uses <code>dc:creator</code> and <code>dc:title</code>. These are short-hands for the full URLs <code>http://purl.org/dc/elements/1.1/creator</code>, and <code>http://purl.org/dc/elements/1.1/title</code>.
			</li>
			</ol>
			
			<p>In RDFa, all property names are, in fact, URLs.
			</p>
			
			<graphic source="diagrams/title-and-author.png" caption="Literal Properties: RDFa lets Alice connect not just one URL to another&mdash;for example to connect her blog entry URL to the Creative Commons license URL&mdash; but also to connect one URL to a string such as &quot;The Trouble with Bob&quot;. All arrows are labeled with the corresponding property name, which is also a URL." />
			
		</div2>

		<div2>
			<head>Multiple Items per Page</head>
			
			<p>
				Alice's blog contains, of course, multiple entries. Sometimes, Alice's sister Eve guest blogs, too. The front page of the blog lists the 10 most recent entries, each with its own title, author, and introductory paragraph. How, then, should Alice mark up the title of each of these entries individually even though they all appear within the same web page? RDFa provides <att>@about</att>, an attribute for specifying the exact URL to which the contained RDFa markup applies:
			</p>

		    <eg><![CDATA[<div xmlns:dc="http://purl.org/dc/elements/1.1/">
			
   <div ]]><highlight>about="/alice/posts/trouble_with_bob"</highlight><![CDATA[>
      <h2 property="dc:title">The trouble with Bob</h2>
      <h3 property="dc:creator">Alice</h3>
      ...
   </div>

   <div ]]><highlight>about="/alice/posts/jos_barbecue"</highlight><![CDATA[>
      <h2 property="dc:title">Jo's Barbecue</h2>
      <h3 property="dc:creator">Eve</h3>
      ...
   </div>

   ...

</div>]]></eg>

			<p>
				We can represent this, once again, as a diagram connecting URLs to properties:
			</p>
			
			<graphic source="diagrams/multiple-blog-entries.png" caption="Multiple Items per Page: each blog entry is represented by its own node, with properties attached to each. Here we've used the short-hands to label the arrows, in order to save space and clarify the diagram. The actual labels are always the full URLs." />

			<p>
				Alice can use the same technique to give her friend Bob proper credit when she posts one of his photos:
			</p>
			
		    <eg><![CDATA[   <div about="/alice/posts/trouble_with_bob">
      <h2 property="dc:title">The trouble with Bob</h2>
      
      The trouble with Bob is that he takes much better photos than I do:
	
      <div ]]><highlight>about="http://example.com/bob/photos/sunset.jpg"</highlight><![CDATA[>
        <img src="http://example.com/bob/photos/sunset.jpg" />
        <span ]]><highlight>property="dc:title"</highlight><![CDATA[>Beautiful Sunset</span>
        by <span ]]><highlight>property="dc:creator"</highlight><![CDATA[>Bob</span>.
      </div>
   </div>]]></eg>

			<p>
				Notice how the innermost <att>@about</att> value, <code>http://example.com/bob/photos/sunset.jpg</code>, "overrides" the outer value <code>/alice/posts/trouble_with_bob</code> for all markup inside the innermost <el>div</el>. And, once again, as a diagram that abstractly represents the underlying data of this new portion of markup:
			</p>
			
			<graphic source="diagrams/image-about.png" caption="Describing a Photo" />

		</div2>

	</div1>
    <div1>
		<head>Going Deeper</head>
		
		<p>
			In addition, Alice wants to make information about herself (email address, phone number, etc.) easily available to her friends' contact management software. This time, instead of describing the properties of a web page, she's going to describe the properties of a person: herself. To do this, she adds deeper structure, so that she can connect multiple items that themselves have properties.
		</p>
		
		<div2>
			<head>Contact Information</head>
			
			<p>
				Alice already has contact information displayed on her blog.
			</p>

		    <eg><![CDATA[<div>
   <p>
     Alice Birpemswick
   </p>

   <p>
     Email: <a href="mailto:alice@example.com">alice@example.com</a>
   </p>
   
   <p>
     Phone: <a href="tel:+1-617-555-7332">+1 617.555.7332</a>
   </p>

</div>]]></eg>

			<p>
				The Dublin Core vocabulary does not provide property names for describing contact information, but the Friend-of-a-Friend <bibref ref="FOAF" /> vocabulary does. In RDFa, it is common and easy to combine different vocabularies in a single page. Alice imports the FOAF vocabulary and declares a <code>foaf:Person</code>. For this purpose, Alice uses <att>@typeof</att>, an RDFa attribute that is specifically meant to declare a new data item with a certain type:
			</p>

			<eg><![CDATA[<div ]]><highlight>typeof="foaf:Person" xmlns:foaf="http://xmlns.com/foaf/0.1/"</highlight><![CDATA[>
...]]></eg>

			<p>
				Then, Alice can indicate which content on the page represents her full name, email address, and phone number:
			</p>

			<eg><![CDATA[<div typeof="foaf:Person" xmlns:foaf="http://xmlns.com/foaf/0.1/">
   <p ]]><highlight>property="foaf:name"</highlight><![CDATA[>
     Alice Birpemswick
   </p>

   <p>
     Email: <a ]]><highlight>rel="foaf:mbox"</highlight><![CDATA[ href="mailto:alice@example.com">alice@example.com</a>
   </p>
   
   <p>
     Phone: <a ]]><highlight>rel="foaf:phone"</highlight><![CDATA[ href="tel:+1-617-555-7332">+1 617.555.7332</a>
   </p>
</div>]]></eg>
			<p>
				Note how Alice didn't specify <att>@about</att> like she did when adding blog entry metadata. What is she associating these properties with, then? In fact, the <att>@typeof</att> on the enclosing <el>div</el> implicitly sets the subject of the properties marked up within that <el>div</el>. The name, email address, and phone number are associated with a new node of type <code>foaf:Person</code>. This node has no URL to identify it, so it is called a <em>blank node</em>. 
			</p>

			<graphic source="diagrams/contact-info.png" caption="A Blank Node: blank nodes are not identified by URL. Instead, many of them have a @typeof attribute that identifies the type of data they represent. This approach&mdash;providing no name but adding a type&mdash; is particularly useful when listing a number of items on a page, e.g. calendar events, authors on an article, friends on a social network, etc."/>

		</div2>	
		
		<div2>
			<head>Social Network</head>
			<p>
				Next, Alice wants to add information about her friends, including at least their names and homepages. Her plain XHTML is:
			</p>
			
		    <eg><![CDATA[<div>
   <ul>
      <li>
        <a href="http://example.com/bob/">Bob</a>
      </li>
      <li>
        <a href="http://example.com/eve/">Eve</a>
      </li>
      <li>
        <a href="http://example.com/manu/">Manu</a>
      </li>
   </ul>
</div>]]></eg>

			<p>
				First, Alice indicates that all of these friends are of type <code>foaf:Person</code>. 
			</p> 

		    <eg><![CDATA[<div ]]><highlight>xmlns:foaf="http://xmlns.com/foaf/0.1/"</highlight><![CDATA[>
   <ul>
      <li ]]><highlight>typeof="foaf:Person"</highlight><![CDATA[>
        <a href="http://example.com/bob/">Bob</a>
      </li>
      <li ]]><highlight>typeof="foaf:Person"</highlight><![CDATA[>
        <a href="http://example.com/eve/">Eve</a>
      </li>
      <li ]]><highlight>typeof="foaf:Person"</highlight><![CDATA[>
        <a href="http://example.com/manu/">Manu</a>
      </li>
   </ul>
</div>]]></eg>

			<p>
				 Beyond declaring the type of data we're dealing with, each <att>@typeof</att> creates a new blank node with its own distinct properties, all without having to provide URL identifiers. Thus, Alice can easily indicate each friend's homepage:
			</p>

		    <eg><![CDATA[<div xmlns:foaf="http://xmlns.com/foaf/0.1/">
   <ul>
      <li typeof="foaf:Person">
        <a ]]><highlight>rel="foaf:homepage"</highlight><![CDATA[ href="http://example.com/bob/">Bob</a>
      </li>
      <li typeof="foaf:Person">
        <a ]]><highlight>rel="foaf:homepage"</highlight><![CDATA[ href="http://example.com/eve/">Eve</a>
      </li>
      <li typeof="foaf:Person">
        <a ]]><highlight>rel="foaf:homepage"</highlight><![CDATA[ href="http://example.com/manu/">Manu</a>
      </li>
   </ul>
</div>]]></eg>

			<p>
				And, of course, each friend's name:
			</p>

		    <eg><![CDATA[<div xmlns:foaf="http://xmlns.com/foaf/0.1/">
   <ul>
      <li typeof="foaf:Person">
        <a ]]><highlight>property="foaf:name"</highlight><![CDATA[ rel="foaf:homepage" href="http://example.com/bob/">Bob</a>
      </li>
      <li typeof="foaf:Person">
        <a ]]><highlight>property="foaf:name"</highlight><![CDATA[ rel="foaf:homepage" href="http://example.com/eve/">Eve</a>
      </li>
      <li typeof="foaf:Person">
        <a ]]><highlight>property="foaf:name"</highlight><![CDATA[ rel="foaf:homepage" href="http://example.com/manu/">Manu</a>
      </li>
   </ul>
</div>]]></eg>

			<p>
				Using <att>@property</att>, Alice specifies that the linked text ("Bob", "Eve", and "Manu") are, in fact, her friends' names. With <att>@rel</att>, she indicates that the clickable links are her friends' homepages. Alice is ecstatic that, with so little additional markup, she's able to fully express both a pleasant human-readable page and a machine-readable dataset.
			</p>
			
			<p>
				Alice is tired of repeatedly entering information about her friends in each new social networking sites. With RDFa, she can indicate her friendships on her own web page, and let social networking applications read it automatically. So far, Alice has listed three individuals but has not specified her relationship with them; they might be her friends, or they might be her favorite 17th century poets. To indicate that she, in fact, knows them, she uses the FOAF property <code>foaf:knows</code>:
			</p>
			
		    <eg><![CDATA[<div xmlns:foaf="http://xmlns.com/foaf/0.1/" ]]><highlight>about="#me" rel="foaf:knows"</highlight><![CDATA[>
   <ul>
      <li typeof="foaf:Person">
        <a property="foaf:name" rel="foaf:homepage" href="http://example.com/bob">Bob</a>
      </li>
      <li typeof="foaf:Person">
        <a property="foaf:name" rel="foaf:homepage" href="http://example.com/eve">Eve</a>
      </li>
      <li typeof="foaf:Person">
        <a property="foaf:name" rel="foaf:homepage" href="http://example.com/manu">Manu</a>
      </li>
   </ul>
</div>]]></eg>

			<p>
				Using <code>rel="foaf:knows"</code> <em>once</em> is enough to connect Bob, Eve, and Manu to Alice. This is achieved thanks to the RDFa concept of <em>chaining</em>: because the top-level <att>@rel</att> is without a corresponding <att>@href</att>, it connects to any contained node, in this case the three nodes defined by <att>@typeof</att>. (The <att>@about="#me"</att> is a FOAF/RDF convention: the URL that represents the <em>person</em> Alice is <code>http://example.com/alice#me</code>. It should not be confused with Alice's homepage, <code>http://example.com/alice</code>. You are what you eat, but you are far more than just your homepage.)
			</p>

			<graphic source="diagrams/social-network.png" caption="Alice's Social Network" />

		</div2>
	</div1>
	
	<div1>
		<head>You Said Something about RDF?</head>
		
		<p>
			RDF, the Resource Description Framework, is exactly the abstract data representation we've drawn out as graphs in the above examples. Each arrow in the graph is represented as a subject-predicate-object triple: the subject is the node at the start of the arrow, the predicate is the arrow itself, and the object is the node or literal at the end of the arrow. An RDF dataset is often called an "RDF graph", and it is typically stored in what is often called a "Triple Store."
		</p>
		
		<p>
		  Consider the first example graph:
	  </p>
	  
		<graphic source="diagrams/title-and-author.png" />
	  
	  <p>
	    The two RDF triples for this graph are written, using the Notation3 syntax <bibref ref="N3" />, as follows:
    </p>
    
    <eg><![CDATA[<http://www.example.com/alice/posts/trouble_with_bob>
    <http://purl.org/dc/elements/1.1/title> "The Trouble with Bob";
    <http://purl.org/dc/elements/1.1/creator> "Alice" .      
]]></eg>

    <p>
      Also, the <code>TYPE</code> arrows we drew are no different from other arrows, only their label is actually a core RDF property, <code>rdf:type</code>, where the <code>rdf</code> namespace is <code>&lt;http://www.w3.org/1999/02/22-rdf-syntax-ns#&gt;</code>. The contact information example from above should thus be diagrammed as:
    </p>
    
    <graphic source="diagrams/type.png" />
		
		<p>
		  The point of RDF is to provide a universal language for expressing data. A unit of data can have any number of fields, and field names are URLs which can be reused by any publisher, much like any web publisher can link to any web page, even ones they did not create themselves. Given data, in the form of RDF triples, collected from various locations, and using the RDF query language SPARQL <bibref ref="SPARQL" />, one can search for "friends of Alice's who created items whose title contains the word 'Bob'," whether those items are blog posts, videos, calendar events, or other data types we haven't thought of yet.
	  </p>
	  
	  <p>
	    RDF is an abstract, machine-readable data representation meant to maximize the reuse of vocabularies. RDFa is a way to express RDF data within XHTML, by reusing the existing human-readable data.
    </p>
    
    <div2>
        <head>Custom Vocabularies</head>
        
        <p>
            As Alice marks up her page with RDFa, she may discover the need to express data, e.g. her favorite photos, that is not covered by existing vocabularies like Dublin Core or FOAF. Since RDFa is simply a representation of RDF, the RDF schema mechanism that enables RDF extensibility is the same that enables RDFa extensibility. Once an RDF vocabulary created, it can be used in RDFa markup just like existing vocabularies. 
        </p>
        
        <p> The instructions on how to create an RDF schema are available in Section 5 of the RDF Primer <bibref ref="RDF-SCHEMA-PRIMER" />. At a high level, the creation of an RDF schema for RDFa involves:
    </p>
    <ol>
        <li> Selecting a URL where the vocabulary will reside, e.g. <att>http://example.com/photos/vocab#</att>.</li>
        <li> Distributing an RDF document, at that URL, which defines the classes and properties that make up the vocabulary. For example, Alice may want to define classes <att>Photo</att> and <att>Camera</att>, as well as the property <att>takenWith</att> that relates a photo to the camera with which it was taken.</li>
        <li> Using the vocabulary in XHTML+RDFa with the usual prefix declaration mechanism, e.g. <att>xmlns:photo="http://example.com/photos/vocab#"</att>, and <att>typeof="photo:Camera"</att>.</li>
    </ol>
    
    <p>
        It is worth noting that anyone who can publish a document on the Web can publish an RDF vocabulary and thus define new data fields they may wish to express. RDF and RDFa allow fully distributed extensibility of vocabularies.
    </p>
    </div2>
	</div1>
	
	<div1>
		<head>Find Out More</head>
		
		<p>
			More examples, links to tools, and information on how to get involved can be found on the <a href="http://rdfa.info/wiki">the RDFa Wiki</a>.
		</p>
	</div1>
  <div1>
      <head>Acknowledgments</head>
    <p>
      This document is the work of the RDF-in-HTML Task Force, including (in alphabetical order) Ben Adida, Mark Birbeck, Jeremy Carroll, Michael Hausenblas, Shane McCarron, Steven Pemberton, Manu Sporny, Ralph Swick, and Elias Torres. This work would not have been possible without the help of the Semantic Deployment Working Group and its previous incarnation, the Semantic Web Deployment and Best Practices Working Group, in particular chairs Tom Baker and Guus Schreiber (and prior chair David Wood), the XHTML2 Working Group, Eric Miller, previous head of the Semantic Web Activity, and Ivan Herman, current head of the Semantic Web Activity.  Earlier versions of this document were officially reviewed by Gary Ng and David Booth, and more recent versions by Diego Berrueta and Ed Summers, all of whom provided insightful comments that significantly improved the work. Bob DuCharme also reviewed the work and provided useful commentary.
    </p>
  </div1>
  <div1>
    <head>Bibliography</head>
        <blist>
    <bibl id="RDFA-SYNTAX" href="http://www.w3.org/TR/xhtml-rdfa-syntax">RDFa in XHTML: Syntax and Processing</bibl>
    <bibl id="CC" href="http://creativecommons.org">Creative Commons</bibl>
    <bibl id="DC" href="http://dublincore.org">Dublin Core Metadata Initiative</bibl>
    <bibl id="FOAF" href="http://www.foaf-project.org/">The Friend of a Friend (FOAF) Project</bibl>
    <bibl id="N3" href="http://www.w3.org/TeamSubmission/n3/">Notation 3</bibl>
    <bibl id="RDF" href="http://www.w3.org/RDF/">Resource Description Framework</bibl>
    <bibl id="RDFHTML" href="http://www.w3.org/2001/sw/BestPractices/HTML/">RDF-in-HTML Task Force</bibl>
    <bibl id="RDF-SCHEMA-PRIMER" href="http://www.w3.org/TR/2004/REC-rdf-primer-20040210/#rdfschema">RDF Primer - Section 5 on RDF Schema</bibl>
    <bibl id="SWD-WG" href="http://www.w3.org/2006/07/SWD/">Semantic Web Best Deployment Working Group</bibl>
    <bibl id="SWBPD-WG" href="http://www.w3.org/2001/sw/BestPractices/">Semantic Web Best Practices and Deployment Working Group</bibl>
    <bibl id="XHTML2-WG" href="http://www.w3.org/MarkUp/">XHTML2 Working Group</bibl>
        </blist>
      </div1>
      
    	<changes>
	<p>
	    The previous version of this document was a significant rewrite for clarity and simplicity. This version includes only a small handful of updates:
	</p>
	<ul>
	    <li> some typos fixed.</li>
	    <li> changed "HTML" to "XHTML" and added Section 1.1 explaining the situation.</li>
	    <li> added section 4.1 on custom vocabularies.</li>
    </ul>
    	</changes>
    </body>
</spec>
