Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mark blank node property labels as obsolete #90

Merged
merged 3 commits into from
Nov 1, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion common/terms.html
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,9 @@
Every <a>edge</a> has a direction associated with it
and is labeled with an <a>IRI</a> or a <a>blank node identifier</a>.
Within the JSON-LD syntax these edge labels are called <a>properties</a>.
Whenever possible, an <a>edge</a> should be labeled with an <a>IRI</a>.</dd>
Whenever possible, an <a>edge</a> should be labeled with an <a>IRI</a>.
<div class="issue atrisk">The use of <a>blank node identifiers</a> to label properties is obsolete,
and may be removed in a future version of JSON-LD.</div></dd>
<dt><dfn>expanded term definition</dfn></dt><dd>
An expanded term definition is a <a>term definition</a>
where the value is a <a>dictionary</a>
Expand Down
48 changes: 20 additions & 28 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4956,7 +4956,6 @@ <h3>Using the Document Base as the Default Vocabulary</h3>
href="#type-coercion">type coercion</a> of the <code>knows</code> property
is not required, as the value is not a string.</p>


<p>While it is considered a best practice to identify nodes in a graph,
at times this is impractical. In the data model, nodes without an explicit
identifier are called <a>blank nodes</a>, which can be represented in a
Expand Down Expand Up @@ -8381,10 +8380,11 @@ <h1>Data Model</h1>

<ul>
<li>A <a>JSON-LD document</a> serializes a
<a>generalized RDF Dataset</a>
<a>RDF Dataset</a>
[[RDF11-CONCEPTS]], which is a collection of <a>graphs</a>
that comprises exactly one <a>default graph</a>
and zero or more <a>named graphs</a>.</li>
and zero or more <a>named graphs</a>.
</li>
<li>The <a>default graph</a> does not have a name and MAY be empty.</li>
<li>Each <a>named graph</a> is a pair consisting of an <a>IRI</a> or
<a>blank node identifier</a> (the
Expand All @@ -8396,7 +8396,10 @@ <h1>Data Model</h1>
<li>Every <a>edge</a> has a direction associated with it and is labeled with
an <a>IRI</a> or a <a>blank node identifier</a>. Within the JSON-LD syntax
these edge labels are called <a>properties</a>.
Whenever practical, an <a>edge</a> SHOULD be labeled with an <a>IRI</a>.</li>
Whenever practical, an <a>edge</a> SHOULD be labeled with an <a>IRI</a>.
<div class="issue atrisk">The use of <a>blank node identifiers</a> to label properties is obsolete,
and may be removed in a future version of JSON-LD.</div>
</li>
<li>Every <a>node</a>
is an <a>IRI</a>, a <a>blank node</a>, a <a>JSON-LD value</a>,
or a <a>list</a>.</li>
Expand Down Expand Up @@ -8426,7 +8429,7 @@ <h1>Data Model</h1>
<a>graph</a> SHOULD return a Linked Data document describing
the resource denoted by that <a>IRI</a> when being dereferenced.</li>
<li>A <a>blank node</a> is a <a>node</a> which is neither an <a>IRI</a>,
nor a <a>JSON-LD value</a>, nor a <a>list</a>. A blank node MAY be identified
nor a <a>JSON-LD value</a>, nor a <a>list</a>. A blank node is identified
using a <a>blank node identifier</a>.</li>
<li>A <a>blank node identifier</a>
is a string that can be used as an identifier for a <a>blank node</a> within
Expand Down Expand Up @@ -9183,33 +9186,20 @@ <h2>Relationship to RDF</h2>
between JSON's native data types and RDF's counterparts to allow round-tripping.</li>
</ul>

<p class="issue atrisk">The use of <a>blank node identifiers</a> to label properties is obsolete,
and may be removed in a future version of JSON-LD, as is the support for <a>generalized RDF Datasets</a>.</p>

<p>Summarized, these differences mean that JSON-LD is capable of serializing any RDF
<a>graph</a> or <a>dataset</a> and most, but not all, JSON-LD documents can be directly
interpreted as RDF as described in RDF 1.1 Concepts [[RDF11-CONCEPTS]].</p>

<p>For authors and developers working with <a>blank nodes</a>
as <a>properties</a> when deserializing to RDF,
three potential approaches are suggested:</p>

<p>Authors are strongly encouraged to avoid labeling properties using <a>blank node identifiers</a>,
instead, consider one of the following mechanisms:</p>
<ul>
<li>If the author is not yet ready to commit to a stable IRI, the
property should be mapped to a <a>relative IRI</a>, or an IRI that is documented as unstable.</li>
<li>If the developer wishes to use <a>blank nodes</a>
as <a>properties</a> and also wishes to interpret the
data as a
<a>generalized RDF Dataset</a>,
there is an option, <a data-cite="JSON-LD11-API#dom-jsonldoptions-producegeneralizedrdf"><em>produce generalized RDF</em></a>, in the
<a data-cite="JSON-LD11-API#deserialize-json-ld-to-rdf-algorithm">Deserialize JSON-LD to RDF algorithm</a> [[JSON-LD11-API]] to do so. Note that a
<a>generalized RDF Dataset</a>
is an extension of RDF; it does not conform to the RDF standard.</li>
<li>If the author or developer wishes to use <a>blank nodes</a>
as <a>properties</a> and wishes to interpret the data
as a standard (non-generalized)
<a>RDF Dataset</a>,
it is possible to losslessly interpret JSON-LD as RDF by transforming
<a>blank nodes</a> used as
<a>properties</a> to <a>IRIs</a>,
by minting new "Skolem IRIs" as per
<li>a <a>relative IRI</a>, either relative to the document or the vocabulary
(see <a href="#using-the-document-base-as-the-default-vocabulary" class="sectionRef"></a> for a discussion on using the document base as the <a>vocabulary mapping</a>).</li>
<li>a URN such as <code>urn:example:1</code>, see [[?URN]], or</li>
<li>a "Skolem IRI" as per
<a data-cite="RDF11-CONCEPTS#section-skolemization">Replacing Blank Nodes with IRIs</a>
of [[RDF11-CONCEPTS]].</li>
</ul>
Expand All @@ -9219,7 +9209,7 @@ <h2>Relationship to RDF</h2>
specification [[JSON-LD11-API]].</p>

<p>Even though JSON-LD serializes
<a>generalized RDF Datasets</a>, it can
<a>RDF Datasets</a>, it can
also be used as a <dfn data-cite="RDF11-CONCEPTS#dfn-rdf-source">RDF graph source</dfn>.
In that case, a consumer MUST only use the <a>default graph</a> and ignore all <a>named graphs</a>.
This allows servers to expose data in languages such as Turtle and JSON-LD
Expand Down Expand Up @@ -9895,6 +9885,8 @@ <h2>Changes since JSON-LD Community Group Final Report</h2>
to ensure that <code>@type</code> members are always represented as an array. This
also allows a term to be defined for <code>@type</code>, where the value MUST be a <a>dictionary</a>
with <code>@container</code> set to <code>@set</code>.</li>
<li>The use of <a>blank node identifiers</a> to label properties is obsolete,
and may be removed in a future version of JSON-LD, as is the support for <a>generalized RDF Datasets</a>.</li>
</ul>
</section>

Expand Down