JSON-LD Spec updated

I  updated the JSON-LD spec [1] with fairly significant reorganization and a re-implementation of the processing algorithm [2], based on my Ruby implementation [3]. I also began changing some of the early examples to use more terms than CURIEs, based on some of Brian Peterson's comments.

Some things I've started, but I'm sure need some more elaboration; please comment if you have an opinion:


 *   It's perfectly valid to parse JSON-LD to get a representation other than RDF, or to just use it as basic JSON. This could be made clearer, with the generation of RDF triples being an 'advanced' function.
 *   IRI Processing merges together the "term" and "CURIE" concepts. basically, both are defined the same way in @context. In use, if a mapping is found for a property key, it is a term. If the key is of the form "prefix:suffix", and "prefix" is mapped within a context, it is treated as a CURIE. Note that a prefix may be empty, so that ":foo" is a reasonable CURIE value for expansion to an IRI. This might do away with the need for @vocab.
 *   There's enough commonality between JSON-LD contexts and RDFa profiles that I wonder if they can't be combined in some way. The RDFa profile syntax is quite a bit different, but I can see that it might be useful to have a single vocabulary document used by both JSON-LD and RDFa, which could align better with MicroFormats 2.
 *   We could add an @language property to set the default language to apply to untyped property values.
 *   I saw some confusion about using "@" or "@subject". Perhaps @subject can be an alias for @.
 *   There was a suggestion to change "a" to "@type". Note that both are really just semantic sugar for "rdf:type". Personally, I think that "@type" is better than "a", which really comes from N3/Turtle.

There's a diff from the previous here [4], but due to reorganization, it might not be too useful.

Gregg

[1] http://json-ld.org/spec/latest/
[2] http://json-ld.org/spec/latest/#sequence
[3] https://github.com/gkellogg/json-ld
[4] http://json-ld.org/spec/ED/20110615/diff-20110507.html

Received on Thursday, 16 June 2011 05:30:38 UTC