--- a/spec/latest/json-ld-api/index.html Fri Feb 22 12:58:40 2013 +0100
+++ b/spec/latest/json-ld-api/index.html Fri Feb 22 13:23:33 2013 +0100
@@ -785,52 +785,48 @@
<section>
<h2>Remote Context Resolution</h2>
-<section>
+<section class="informative">
<h3>Purpose</h3>
-<p>A JSON-LD document may contain remote <tref title="context">contexts</tref>.
-These <tref title="context">contexts</tref> must be dereferenced before they
-can be processed.</p>
-
+ <p>A JSON-LD document may contain remote <tref title="context">contexts</tref>.
+ These <tref title="context">contexts</tref> must be dereferenced before they
+ can be processed.</p>
</section>
-<section>
-<h3>General Solution</h3>
-
-<p>Dereferencing remote <tref title="context">contexts</tref> can be performed
- either inline with the other JSON-LD algorithms or as a separate, prior step.
- This solution opts to dereference them first, in a prior step, to both
- separate concerns and to better enable <tref>active context</tref> caching.
- By separating concerns, the other JSON-LD algorithms can be described more
- simply. Implementations may also be either simplified or made more efficient
- because there is no need to block or respond to events when remote
- <tref title="context">contexts</tref> are dereferenced over the network. This
- is particularly important for simplifying implementations in asynchronous
- programming environments. Of course, choosing this approach is not a
- requirement.</p>
-
-<p>The JSON-LD document is searched for remote <tref title="context">contexts</tref>
- recursively, starting with its root <em>element</em>. If the <em>element</em>
- contains an <code>@context</code> key, its value is searched for
- <tref title="string">strings</tref>. The result represents a remote
- <tref>context</tref>, which we add to a map that will ensure we don't
- dereference an already dereferenced remote <tref>context</tref> for a given
- <tref>IRI</tref>.</p>
-
-<p>When we have finished searching, we dereference each remote
- <tref>context</tref> (or get its already-dereferenced value from our map).
- Each time we dereference a remote <tref>context</tref>, we store its result
- in our map and then recursively search it for more remote
- <tref title="IRI">contexts</tref> as above, checking to ensure there is no
- cyclical reference, which is an error.</p>
-
-<p>
-Once all of the remote <tref title="IRI">contexts</tref> have been
-dereferenced, we replace all of their associated <tref>context</tref>
-<tref title="IRI">IRIs</tref> in the JSON-LD document with the
-results from our map.
-</p>
-
+<section class="informative">
+ <h3>General Solution</h3>
+
+ <p>Dereferencing remote <tref title="context">contexts</tref> can be performed
+ either inline with the other JSON-LD algorithms or as a separate, prior step.
+ This solution opts to dereference them first, in a prior step, to both
+ separate concerns and to better enable <tref>active context</tref> caching.
+ By separating concerns, the other JSON-LD algorithms can be described more
+ simply. Implementations may also be either simplified or made more efficient
+ because there is no need to block or respond to events when remote
+ <tref title="context">contexts</tref> are dereferenced over the network. This
+ is particularly important for simplifying implementations in asynchronous
+ programming environments. Of course, choosing this approach is not a
+ requirement.</p>
+
+ <p>The JSON-LD document is searched for remote <tref title="context">contexts</tref>
+ recursively, starting with its root <em>element</em>. If the <em>element</em>
+ contains an <code>@context</code> key, its value is searched for
+ <tref title="string">strings</tref>. The result represents a remote
+ <tref>context</tref>, which we add to a map that will ensure we don't
+ dereference an already dereferenced remote <tref>context</tref> for a given
+ <tref>IRI</tref>.</p>
+
+ <p>When we have finished searching, we dereference each remote
+ <tref>context</tref> (or get its already-dereferenced value from our map).
+ Each time we dereference a remote <tref>context</tref>, we store its result
+ in our map and then recursively search it for more remote
+ <tref title="IRI">contexts</tref> as above, checking to ensure there is no
+ cyclical reference, which is an error.</p>
+
+ <p>Once all of the remote <tref title="IRI">contexts</tref> have been
+ dereferenced, we replace all of their associated <tref>context</tref>
+ <tref title="IRI">IRIs</tref> in the JSON-LD document with the
+ results from our map.</p>
</section>
<!-- end of Remote Context Resolution -->
@@ -872,7 +868,7 @@
<tref>string</tref>, an <tref>array</tref>, or a <tref>JSON object</tref>.
</p>
-<section>
+<section class="informative">
<h3>Purpose</h3>
<p>
@@ -887,7 +883,7 @@
</section>
-<section>
+<section class="informative">
<h3>General Solution</h3>
<p>
@@ -1034,7 +1030,7 @@
<tref>active context</tref>.
</p>
-<section>
+<section class="informative">
<h3>Purpose</h3>
A <tref>term definition</tref> must be created for the given
@@ -1042,7 +1038,7 @@
</section>
-<section>
+<section class="informative">
<h3>General Solution</h3>
<p>
@@ -1304,7 +1300,7 @@
<section>
<h2>Expansion Algorithm</h2>
-<section>
+<section class="informative">
<h3>Purpose</h3>
<p>
@@ -1318,7 +1314,7 @@
</section>
-<section>
+<section class="informative">
<h3>General Solution</h3>
<p>Starting with its root <em>element</em>, we can process the
@@ -1762,7 +1758,7 @@
<tref title="blank node identifier">blank node identifiers</tref> and
JSON-LD <tref title="keyword">keywords</tref>).</p>
- <section>
+ <section class="informative">
<h3>Purpose</h3>
<p>We have a value that needs to be expanded to an <tref>absolute IRI</tref>
@@ -1771,7 +1767,7 @@
a <tref>relative IRI</tref>, or an <tref>absolute IRI</tref>.</p>
</section>
- <section>
+ <section class="informative">
<h3>General Solution</h3>
<p>In order to expand <em>value</em> to an <tref>absolute IRI</tref>, we must
@@ -1940,7 +1936,7 @@
<tdef>expanded form</tdef> after the application of this algorithm.
</p>
-<section>
+<section class="informative">
<h3>Purpose</h3>
A <em>value</em> associated with an <tref>active property</tref> must
@@ -1948,7 +1944,7 @@
</section>
-<section>
+<section class="informative">
<h3>General Solution</h3>
<p>
@@ -2193,7 +2189,7 @@
<section>
<h2>Compaction Algorithm</h2>
-<section>
+<section class="informative">
<h3>Purpose</h3>
<p>A JSON-LD document needs to be compacted, such that the given
@@ -2208,7 +2204,7 @@
</section>
-<section>
+<section class="informative">
<h3>General Solution</h3>
<p>Starting with its root <em>element</em>, we can process the
@@ -2644,77 +2640,66 @@
<section>
<h2>IRI Compaction Algorithm</h2>
-<p>
-This section defines an algorithm for transforming an <tref>IRI</tref>
-to a <tref>term</tref> or <tref>compact IRI</tref>, or a <tref>keyword</tref>
-alias to a <tref>keyword</tref>. A value that is associated with the
-<tref>IRI</tref> may be passed in order to assist in selecting the most
-context-appropriate <tref>term</tref>.
-</p>
-
-<section>
-<h3>Purpose</h3>
-
-We have an <tref>IRI</tref> (or <tref>keyword</tref>) that we may
-be able to compact to <tref>term</tref>, <tref>compact IRI</tref>, or
-<tref>keyword</tref> alias.
-
+<p>This section defines an algorithm for transforming an <tref>IRI</tref>
+ to a <tref>term</tref> or <tref>compact IRI</tref>, or a <tref>keyword</tref>
+ alias to a <tref>keyword</tref>. A value that is associated with the
+ <tref>IRI</tref> may be passed in order to assist in selecting the most
+ context-appropriate <tref>term</tref>.</p>
+
+<section class="informative">
+ <h3>Purpose</h3>
+
+ <p>We have an <tref>IRI</tref> (or <tref>keyword</tref>) that we may
+ be able to compact to <tref>term</tref>, <tref>compact IRI</tref>, or
+ <tref>keyword</tref> alias.</p>
</section>
-<section>
-<h3>General Solution</h3>
-
-<p>
-First, we handle the simple cases: if the value given as an <tref>IRI</tref>
-is <tref>null</tref>, we simply return <tref>null</tref> and if it is a
-<tref>keyword</tref> we return its associated alias.
-</p>
-
-<p>
-Otherwise, we first try to find a <tref>term</tref> that the
-<tref>IRI</tref> can be <tref title="compaction">compacted</tref> to if
-it is relative to <tref title="active context">active context's</tref>'s
-<tref>vocabulary mapping</tref>. In order to select a <tref>term</tref>, we
-have to collect information about the <tref title="IRI">IRI's</tref>
-associated value. This information includes which
-<tref title="container mapping">container mappings</tref>
-would be preferred for expressing the value, and what its
-<tref>type mapping</tref> or <tref>language mapping</tref> is. For
-JSON-LD lists, the <tref>type mapping</tref> or <tref>language mapping</tref>
-will be chosen based on the most specific values that work for all items in
-the list. Once this information is gathered, it is passed to the
-<a href="#term-selection-subalgorithm">Term Selection</a> subalgorithm, which will
-return the most appropriate <tref>term</tref> to use.</p>
-
-<p>
-If no <tref>term</tref> was found that could be used to compact the
-<tref>IRI</tref>, then an attempt is made to find a <tref>compact IRI</tref>
-to use. If there is no appropriate <tref>compact IRI</tref>, then, if
-the <tref>IRI</tref> is relative to
-<tref title="active context">active context's</tref>
-<tref>vocabulary mapping</tref>, then it is used. Otherwise, transform it to
-a <tref>relative IRI</tref> using the document's base <tref>IRI</tref>.
-Finally, if the <tref>IRI</tref> still could not be compacted, return it
-as is.
-</p>
-
+<section class="informative">
+ <h3>General Solution</h3>
+
+ <p>First, we handle the simple cases: if the value given as an <tref>IRI</tref>
+ is <tref>null</tref>, we simply return <tref>null</tref> and if it is a
+ <tref>keyword</tref> we return its associated alias.</p>
+
+ <p>Otherwise, we first try to find a <tref>term</tref> that the
+ <tref>IRI</tref> can be <tref title="compaction">compacted</tref> to if
+ it is relative to <tref title="active context">active context's</tref>'s
+ <tref>vocabulary mapping</tref>. In order to select a <tref>term</tref>, we
+ have to collect information about the <tref title="IRI">IRI's</tref>
+ associated value. This information includes which
+ <tref title="container mapping">container mappings</tref>
+ would be preferred for expressing the value, and what its
+ <tref>type mapping</tref> or <tref>language mapping</tref> is. For
+ JSON-LD lists, the <tref>type mapping</tref> or <tref>language mapping</tref>
+ will be chosen based on the most specific values that work for all items in
+ the list. Once this information is gathered, it is passed to the
+ <a href="#term-selection-subalgorithm">Term Selection</a> subalgorithm, which will
+ return the most appropriate <tref>term</tref> to use.</p>
+
+ <p>If no <tref>term</tref> was found that could be used to compact the
+ <tref>IRI</tref>, then an attempt is made to find a <tref>compact IRI</tref>
+ to use. If there is no appropriate <tref>compact IRI</tref>, then, if
+ the <tref>IRI</tref> is relative to
+ <tref title="active context">active context's</tref>
+ <tref>vocabulary mapping</tref>, then it is used. Otherwise, transform it to
+ a <tref>relative IRI</tref> using the document's base <tref>IRI</tref>.
+ Finally, if the <tref>IRI</tref> still could not be compacted, return it
+ as is.</p>
</section>
<section>
<h3>Algorithm</h3>
-<p>
-This algorithm takes three required inputs and three optional inputs.
-The required inputs an <tref>active context</tref> and the <em>iri</em> to
-be compacted. The optional inputs are: a <em>value</em> associated with
-the <em>iri</em>, a <em>vocabRelative</em> flag which specifies whether the
-passed <em>iri</em> should be compacted using the
-<tref title="active context">active context's</tref>
-<tref>vocabulary mapping</tref>, and the <em>parent</em> element for
-the <em>value</em>. If not passed, <em>value</em> is set to
-<tref>null</tref>, <em>vocabRelative</em> is set to <code>false</code>, and
-<em>parent</em> is set to <tref>null</tref>.
-</p>
+<p>This algorithm takes three required inputs and three optional inputs.
+ The required inputs an <tref>active context</tref> and the <em>iri</em> to
+ be compacted. The optional inputs are: a <em>value</em> associated with
+ the <em>iri</em>, a <em>vocabRelative</em> flag which specifies whether the
+ passed <em>iri</em> should be compacted using the
+ <tref title="active context">active context's</tref>
+ <tref>vocabulary mapping</tref>, and the <em>parent</em> element for
+ the <em>value</em>. If not passed, <em>value</em> is set to
+ <tref>null</tref>, <em>vocabRelative</em> is set to <code>false</code>, and
+ <em>parent</em> is set to <tref>null</tref>.</p>
<ol class="algorithm">
<li>
@@ -3015,7 +3000,7 @@
matches the value's mappings.
</p>
-<section>
+<section class="informative">
<h3>Purpose</h3>
An <tref>inverse context</tref> must be created for the given
@@ -3023,7 +3008,7 @@
</section>
-<section>
+<section class="informative">
<h3>General Solution</h3>
<p>
@@ -3296,7 +3281,7 @@
be best used to express the value.
</p>
-<section>
+<section class="informative">
<h3>Purpose</h3>
An <tref>IRI</tref> with an associated <em>value</em> should be compacted
@@ -3304,7 +3289,7 @@
</section>
-<section>
+<section class="informative">
<h3>General Solution</h3>
<p>
@@ -3491,7 +3476,7 @@
<tref>active property</tref>.
</p>
-<section>
+<section class="informative">
<h3>Purpose</h3>
A <em>value</em> associated with an <tref>active property</tref> must
@@ -3499,7 +3484,7 @@
</section>
-<section>
+<section class="informative">
<h3>General Solution</h3>
<p>
@@ -3960,7 +3945,7 @@
</section>
<section class="informative">
- <h4>General Solution</h4>
+ <h3>General Solution</h3>
<p>The JSON-LD document is expanded converted to a <em>node map</em> using the
<a href="#node-map-generation">Node Map Generation algorithm</a>.
@@ -3973,7 +3958,7 @@
</section>
<section>
-<h4>Algorithm</h4>
+<h3>Algorithm</h3>
<p>
The algorithm takes a JSON-LD document <em>element</em> and creates an <tref>RDF dataset</tref>.
</p>
@@ -4006,7 +3991,7 @@
and returns a set of <em>RDF triples</em>.</p>
<section class="informative">
- <h4>Purpose</h4>
+ <h3>Purpose</h3>
<p>Given a set of <tref title="node">nodes</tref> associated with a
<tref>JSON-LD graph</tref> as obtained from the <a href="">Node Map Generation</a>
algorithm, transform each <tref>node</tref> into one or more <tref
@@ -4014,7 +3999,7 @@
</section>
<section class="informative">
- <h4>General Solution</h4>
+ <h3>General Solution</h3>
<p>Identify <tref title="RDF subject">RDF subjects</tref> and
<tref title="RDF predicate">RDF predicates</tref> from the
@@ -4030,7 +4015,7 @@
</section>
<section>
-<h4>Algorithm</h4>
+<h3>Algorithm</h3>
<p>The <em>nodeMap</em> is represented as an <tref>JSON object</tref>
having keys which are node identifiers (<tref title="iri">IRIs</tref> or
<tref title="blank node identifier">blank node identifiers</tref>)
@@ -4086,12 +4071,12 @@
to be used as the <tref>object</tref> or an <tref>RDF triple</tref>.</p>
<section class="informative">
- <h4>Purpose</h4>
+ <h3>Purpose</h3>
<p>Create an <tref>RDF resource</tref> from a <tref>node</tref> or <tref>value object</tref>.</p>
</section>
<section class="informative">
- <h4>General Solution</h4>
+ <h3>General Solution</h3>
<p>Transform <tref title="value object">value objects</tref> to their
<tref>RDF literal</tref> form and
@@ -4100,7 +4085,7 @@
</section>
<section>
-<h4>Algorithm</h4>
+<h3>Algorithm</h3>
<p>The algorithm takes as its sole argument <em>item</em> which MUST be either a <tref>value object</tref> or <tref>node object</tref>.</p>
<ol class="algorithm">
<li>If <em>item</em> is a <tref>value object</tref>:
@@ -4152,12 +4137,12 @@
<section class="informative">
- <h4>Purpose</h4>
+ <h3>Purpose</h3>
<p>Transform a sequential set of <tref title="node">nodes</tref> in a <tref>list</tref> into the equivalent <tref>RDF Collection</tref>.</p>
</section>
<section class="informative">
- <h4>General Solution</h4>
+ <h3>General Solution</h3>
<p>Allocate a new <tref>blank node</tref> for each element of the
<tref>list</tref> and generate <code>rdf:first</code> and
@@ -4167,7 +4152,7 @@
</section>
<section>
-<h4>Algorithm</h4>
+<h3>Algorithm</h3>
<p>The algorithm takes two inputs: an <tref>array</tref> of
<tref title="node">nodes</tref> <em>list</em> and an empty <tref>array</tref>
<em>list triples</em> used for returning the generated <tref title="RDF
@@ -4224,7 +4209,7 @@
</section>
<section class="informative">
- <h4>General Solution</h4>
+ <h3>General Solution</h3>
<p>Iterate through each graph in the dataset, converting <tref title="rdf collection">RDF Collections</tref> into a <tref>list</tref> and generating an JSON-LD document in expanded form for all <tref title="RDF literal">RDF literals</tref>, <tref title="IRI">IRIs</tref> and <tref title="blank node identifier">blank node identifiers</tref>.</p>
</section>
@@ -4784,7 +4769,7 @@
</section>
</section>
-<section class="appendix">
+<section class="appendix informative">
<h1>Acknowledgements</h1>
<p>A large amount of thanks goes out to the JSON-LD Community Group