Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[bioontology-support] Error in JSON-LD links context?

Emonet vincent.emonet at lirmm.fr
Mon Mar 21 08:53:43 PDT 2016


Hi,

It seems like there is an error in the JSON-LD @context for Links

The context should provide the properties URI. e.g.: " name": 
"http://data.bioontology.org/metadata/omvname","
But instead it is providing the object type: " children": 
"http://www.w3.org/2002/07/owl#Class","


@context should be "traducing" the property terms used in the JSON as an 
IRI. For instance in
http://data.bioontology.org/ontologies/STY/classes/http%3A%2F%2Fpurl.bioontology.org%2Fontology%2FSTY%2FT057

The @context defines that the predicate "obsolete" has 
http://data.bioontology.org/metadata/owlobsolete as property
So it is representing the following triple: < 
<http://purl.bioontology.org/ontology/STY/T057>http://purl.bioontology.org/ontology/STY/T057"> 
<<http://data.bioontology.org/metadata/owlobsolete>http://data.bioontology.org/metadata/owlobsolete> 
false .


But the @context generated for "links" is it:

> *@context**"*: {
>
> ·*"**self**"*: "http://www.w3.org/2002/07/owl#Class",
>
> ·*"**ontology**"*: "http://data.bioontology.org/metadata/Ontology",
>
> ·*"**children**"*: "http://www.w3.org/2002/07/owl#Class",
>
> ·*"**parents**"*: "http://www.w3.org/2002/07/owl#Class",
>
> ·*"**descendants**"*: "http://www.w3.org/2002/07/owl#Class",
>
> ·*"**ancestors**"*: "http://www.w3.org/2002/07/owl#Class",
>
> ·*"**tree**"*: "http://www.w3.org/2002/07/owl#Class",
>
> ·*"**notes**"*: "http://data.bioontology.org/metadata/Note",
>
> ·*"**mappings**"*: "http://data.bioontology.org/metadata/Mapping",
>
> ·*"**ui**"*: "http://www.w3.org/2002/07/owl#Class"
>
> }


These are not the properties that are defined here, but the types of the 
objects

This JSON is defining the following triple:
<node "links" of http://purl.bioontology.org/ontology/STY/T057> 
<http://www.w3.org/2002/07/owl#Class> 
<http://data.bioontology.org/ontologies/STY/classes/http%3A%2F%2Fpurl.bioontology.org%2Fontology%2FSTY%2FT057/parents> 
.

When it should define the following one:
<node "links" of http://purl.bioontology.org/ontology/STY/T057> 
<http://data.bioontology.org/metadata/parents 
<http://data.bioontology.org/metadata/Mapping>> 
<http://data.bioontology.org/ontologies/STY/classes/http%3A%2F%2Fpurl.bioontology.org%2Fontology%2FSTY%2FT057/parents> 
.

If we want to define types we would have to do the following:

> *@context**"*: {
>
> ·*"**parents**"*: {@type: "http://www.w3.org/2002/07/owl#Class"},
>
> }

This error is only in @context of link. If we look at how you define the 
context for the class, we have the following (that respects the w3c 
recommendation):

> "@context": {
>
>   * "@vocab": "http://data.bioontology.org/metadata/",
>   * "prefLabel": "http://data.bioontology.org/metadata/skosprefLabel",
>   * "synonym": "http://data.bioontology.org/metadata/skossynonym",
>   * "definition": "http://data.bioontology.org/metadata/skosdefinition",
>   * "obsolete": "http://data.bioontology.org/metadata/owlobsolete",
>   * "semanticType":
>     "http://data.bioontology.org/metadata/umlssemanticType",
>   * "cui": "http://data.bioontology.org/metadata/umlscui"
>
> }

It seems the Links context are generated here : 
https://github.com/ncbo/ontologies_linked_data/blob/master/lib/ontologies_linked_data/serializers/json.rb#L71


Note that to understand the use of @context I used the w3c 
recommendation : http://www.w3.org/TR/json-ld/#base-iri


Is it an expected behavior? Or is there a problem when generating the 
links context?


Have a good day,

Vincent Emonet




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.stanford.edu/pipermail/bioontology-support/attachments/20160321/f3aece98/attachment-0001.html>


More information about the bioontology-support mailing list