Re: ODRL Version 2.1 Final Draft Specifications – Last Call for Comments (due 16 FEB) [via ODRL Community Group]

Hi!

In general, JSON-LD allows to express RDF triples as JSON strings. So 
e.g. something like:

{
   "@context": "http://schema.org/",
   "@type": "Person",
   "name": "Jane Doe",
   "jobTitle": "Professor",
   "telephone": "(425) 123-4567",
   "url": "http://www.janedoe.com"
}

could be translated into:

_:b0 <http://schema.org/jobTitle> "Professor" .
_:b0 <http://schema.org/name> "Jane Doe" .
_:b0 <http://schema.org/telephone> "(425) 123-4567" .
_:b0 <http://schema.org/url> <http://www.janedoe.com> .
_:b0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> 
<http://schema.org/Person> .

and vice versa..

Since you have the ontology for ODRL 2.1, a JSON-LD representation of an 
ODRL policy like:

@prefix odrl: <http://www.w3.org/ns/odrl/2/> .

<http://example.com/policy:0099>
 a odrl:Set;
 odrl:permission odrl:reproduce ;
 odrl:prohibition odrl:modify .

could be this:

{
   "@context": "http://www.w3.org/ns/odrl/2/",
   "@id": "http://example.com/policy:0099",
   "@type": "Set",
   "permission": "reproduce",
   "prohibition": "modify"
}

For further reading i would suggest [1], which gives you a nice overview 
about JSON-LD and its relations/translations to other serialization 
formats.

[1] http://json-ld.org/

cheers, simon

---
Dipl.-Ing. Simon Steyskal
Institute for Information Business, WU Vienna

www: http://www.steyskal.info/  twitter: @simonsteys



Am 2015-01-20 06:42, schrieb Steven Rowat:
> On 1/19/15 9:03 AM, Mo McRoberts wrote:
>> I’m open to the idea of trying to come up with a workflow which
>> adds JSON-LD generation to the existing tooling (which generates
>> RDF/XML and N-Triples serialisations of the ontology and examples
>> from the source Turtle), although the biggest constraint is, as
>> ever, time.
>> 
>> M.
> 
> Hi Mo,
> 
> Thank you for your explanation; unfortunately I'm out of my depth in
> attempting to understand all parts of it. I could research each of the
> individual components and terms that you've used, but, as you mention,
> there is the question of time -- my own projects are time-consuming
> and largely tangential or orthogonal to this question. So perhaps I'm
> doomed to not understand how JSON-LD and ODRL can work together (or
> can't) until some future implementation occurs that makes this clear.
> 
> Or, perhaps it's still possible to clarify (for myself) the potential
> cross-over point of JSON-LD and ODRL, without learning other
> languages; maybe with an example?
> 
> So I'll try this:...
> 
>      1. Suppose I have a an HTML page, on which is listed a digital
> work: 'Book A'.
> 
>      2. Suppose that I have inserted, into the HTML page, a JSON-LD
> implementation of schema.org terms  to describe that HTML page,
> including Book A's title, author, size and type of file, etc.
> 
>      3. Suppose I also want ODRL terms to be available from the page,
> concerning Book A -- various rights and permissions.
> 
>      4. Suppose I want these ODRL terms to be searchable logically, by
> machine, via the search engines, as part of JSON-LD (ie, as linked
> data).
> 
> Then:
> What is going to be required to be able to write the JSON-LD code in
> such a way that it contains ODRL terms that can be part of a search
> engine's reading of the JSON-LD?
> 
> My apologies, Mo, if the answer to this question is contained in what
> you already said. If so, then I suppose my only option is to read more
> about ontologies, serializations, RDF, XML, N-triples, tooling, and
> Turtle. :-)
> 
> Steven Rowat
> 
> 
> 
> 
> 
> 
> 
> 
>> 
>> On  2015-Jan-19, at 16:52, Steven Rowat <steven_rowat@sunshine.net>
>> wrote:
>> 
>>> On 1/19/15 3:32 AM, W3C Community Development Team wrote:
>>>> The W3C ODRL Community Group seeks feedback from the community
>>>> on the Version 2.1 Final Draft specifications of the ODRL
>>>> Policy Language:
>>> 
>>>> ODRL Version 2.1 JSON Encoding
>>> 
>>> Short form: Is JSON-LD also supported? (It's not mentioned on
>>> that page ODRL 2.1 JSON Encoding page.)
>>> 
>>> Background: Google and other search engines read JSON-LD, and
>>> it's listed at schema.org alongside Microdata and RDF as a
>>> tagging system for the general web. When I looked at the example
>>> for tagging a 'Book' at schema.org, JSON-LD seemed to me to have
>>> several advantages over Microdata and RDFa. Plus, the Credentials
>>> Community group and the Web Payments Community group are basing
>>> at least some of their work on JSON-LD.
>>> 
>>> Google says here:
>>> https://developers.google.com/webmasters/structured-data/schema-org
>>> 
>>> 
>>> 
> "JSON-LD is the newest and simplest markup format: it lets you embed a
> block of JSON data inside a script tag anywhere in the HTML. Since the
> data does not have to be interleaved with the user-visible text, it's
> much easier to express nested data items [snip]...Google is in the
> process of adding JSON-LD support to more markup-powered features."
>>> 
>>> Specifically in the ODRL context, my (non-expert) belief is that
>>> JSON-LD is merely an extension of JSON, and so in theory one
>>> might be able to use the ODRL JSON Encoding directly with
>>> JSON-LD. Is this true?
>>> 
>>> If so, it might be nice to make a mention of JSON-LD on the ODRL
>>> JSON page, or even give an example,.
>>> 
>>> If not -- and some different ODRL Encoding needs to be done to
>>> get ODRL to work with JSON-LD -- is there something in the works
>>> for this?
>>> 
>>> 
>>> 
>>> 
>>> Steven Rowat
>>> 
>> 
>> 

Received on Tuesday, 20 January 2015 08:06:24 UTC