W3C home > Mailing lists > Public > public-openannotation@w3.org > February 2013

Re: JSON-LD Context URI

From: Ivan Herman <ivan@w3.org>
Date: Wed, 27 Feb 2013 12:01:39 +0100
Cc: Robert Sanderson <azaroth42@gmail.com>, public-openannotation <public-openannotation@w3.org>
Message-Id: <215B6B4D-5E62-4720-BC7B-D6E2DA825E1A@w3.org>
To: Stian Soiland-Reyes <soiland-reyes@cs.manchester.ac.uk>

On Feb 27, 2013, at 11:56 , Stian Soiland-Reyes <soiland-reyes@cs.manchester.ac.uk> wrote:
> The site could also do RDFa which I just pasted into the oa.html -
> thus Ivan should now be happy.

You see how easy it is to make me happy? :-)


> I had to do some manual search-replace
> of " to &quot; here and there - the conversion tool is not perfect.
> Obviously this is not a very reproduceable setup, but we can try to
> script something. (There's a REST interface to the converter) --- and
> we should also give some PROVenance of how this was made! ;-)
> On Wed, Feb 27, 2013 at 10:11 AM, Stian Soiland-Reyes
> <soiland-reyes@cs.manchester.ac.uk> wrote:
>> That sounds like a good workaround! OWL ontologies in JSON-LD is a bit
>> unusual; but I guess it would work.
>> I'll have a look if we can do some kind of conversion (given an
>> OWL/RDFS context); then we can just semi-concatenate in the @context.
>> Maintaining the ontology in JSON-LD as the raw format might or might
>> not work well.
>> One issue is that JSON clients might not be good at content
>> negotiations; so the official @context should probably include the
>> .json extension (or equivalent) - I guess this is OK - just like we
>> have http://www.w3.org/ns/oa.ttl and http://www.w3.org/ns/oa.rdf
>> already.
>> On Tue, Feb 26, 2013 at 10:42 PM, Robert Sanderson <azaroth42@gmail.com> wrote:
>>> Dear all,
>>> A slight hiccup... the location that we specified in the most recent
>>> version of the spec for the default JSON-LD context document isn't
>>> actually available to use.  The W3C uses the /ns/ directory
>>> exclusively for namespace documents, and the context document doesn't
>>> count.  W3C doesn't have a /contexts/ yet (and may never have one), we
>>> don't have a /TR/ space as a community group, so we'd be back to
>>> putting it in openannotation.org.  This is undesirable for when we
>>> move further into the standards process, of course.
>>> We could have a PURL redirect and swap it from one to the other, but
>>> then we would lose the versioning information and just adds an
>>> additional hop for processors to follow.
>>> We're discussing the issue on the JSON-LD list, please feel free to
>>> join in if it's of interest to you, but one interesting proposal is as
>>> below.
>>> The original thread is here:
>>> http://lists.w3.org/Archives/Public/public-linked-json/2013Feb/0152.html
>>> -----
>>>> As the W3C (thank you Ivan) lets us
>>>> publish our namespace documents, we figured that they'd also let us
>>>> publish the JSON-LD context file, but they don't have anything in
>>>> place for doing that yet.
>>> I didn't know that. If that's the case, why don't combine your namespace
>>> document with your external context? The external context would end up being
>>> slightly bigger, but that shouldn't really matter. That even has the
>>> advantage that your namespace document is available as JSON-LD and there
>>> won't be an additional round-trip to fetch its definitions.
>>> So, what I mean is this. You upload a JSON-LD document describing your
>>> vocabulary. In that document you also include an @context element at the
>>> top-level JSON object. You can even use that local context when describing
>>> your vocab.
>>> {
>>>  "@context": {
>>>    ...
>>>  },
>>>  ... your vocabulary ...
>>> }
>>> When retrieving an external context, a JSON-LD will ignore everything but
>>> the context. Et voila, everything works as expected. You have your context
>>> at a stable location and even reduced the number of necessary roundtrips if
>>> you need, e.g., the labels for some properties.
>>> -----
>>> This seems extremely attractive to me, at least.  We wouldn't have to
>>> maintain two separate files (ontology in JSON-LD and context would be
>>> the same document) and processors would still do the right thing.
>>> Rob
>> --
>> Stian Soiland-Reyes, myGrid team
>> School of Computer Science
>> The University of Manchester
> -- 
> Stian Soiland-Reyes, myGrid team
> School of Computer Science
> The University of Manchester

Ivan Herman, W3C Semantic Web Activity Lead
Home: http://www.w3.org/People/Ivan/
mobile: +31-641044153
FOAF: http://www.ivan-herman.net/foaf.rdf
Received on Wednesday, 27 February 2013 11:02:12 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:38:22 UTC