ncbo / ontologies_linked_data

Models and serializers for ontologies and related artifacts backed by 4store
Other
17 stars 8 forks source link

Multilingual ont: prefLabel is generated from URI fragment and displayed under 'none:' for terms that do not have English lang tags #209

Open alexskr opened 1 month ago

alexskr commented 1 month ago

Multilingual ontology support:

prefLabel gets generated from URI fragment and displayed under 'none:' for terms that do not have English lang tags

<!-- http://www.semanticweb.org/ontologies/2009/3/ontoDPN.owl#AttributObjetPhysique -->
     <owl:Class rdf:about="&ontoDPN;AttributObjetPhysique">
         <rdfs:subClassOf rdf:resource="&ontoDPN;Attribute"/>
         <DOE:swp rdf:datatype="&xsd;string">internalised point of view on abstract objects</DOE:swp>
         <skos:definition xml:lang="fr">Attributs s&apos;appliquant à des objets physique</skos:definition>
        <skos:prefLabel xml:lang="fr">attribit physique</skos:prefLabel>
     </owl:Class>
image

Is this the expected behavior? If the term is in French or in German, do we really need non-french generated perfLabel?

image
syphax-bouazzouni commented 1 month ago

The question here, is in the UI, what do you want to display as prefLabel if there is no English values:

  1. Arabic, Chineese, French or anything that is provided. (you will be in this situation https://github.com/ncbo/ontologies_linked_data/issues/91)
  2. Or instead using its id (URI fragment) as its prefLabel.

the none here means, that the generated value has no language tag.

jonquet commented 1 month ago

And the "none" is the official syntax that JSON specifies for this.

syphax-bouazzouni commented 1 month ago

And the "none" is the official syntax that JSON specifies for this.

image Source: the JSON-LD 1.1 reference

jonquet commented 1 month ago

This is also related to the "default" language discussion in the other tracker : https://github.com/ncbo/ontologies_api/pull/149

alexskr commented 1 month ago

In many cases, the perfLabel generated from the URI fragment has no inherent meaning; frequently, they are alpha-numeric term ids, which may not add any value and could potentially cause confusion.