Open alexskr opened 1 month ago
Do you have the error logs?
Some additional detail: https://bioportal.bioontology.org/ontologies/D3O?p=summary
Search entries are below. They DO NOT include the XXX_en
attributes:
When searching for lang=en
, you get no results:
https://data.bioontology.org/search?q=energy&ontologies=D3O&lang=en
However, when using classes endpoints with lang=en
, the prefLabels show up correctly:
https://data.bioontology.org/ontologies/D3O/classes/?lang=en
@syphax-bouazzouni, since the ontology specifically ads "English" as a language, shouldn't we expect to see the "XXX_en" attributes in the index for D3O?
More details:
Here is a sample term declaration in the OWL file (D3O.owl):
<AnnotationAssertion>
<AnnotationProperty abbreviatedIRI="rdfs:comment"/>
<IRI>EnergyMetabolism</IRI>
<Literal xml:lang="en">A set of metabolic pathways that are involved in the generation and use of energy within an organism, typically through processes like cellular respiration and photosynthesis.</Literal>
</AnnotationAssertion>
<AnnotationAssertion>
<AnnotationProperty abbreviatedIRI="rdfs:label"/>
<IRI>EnergyMetabolism</IRI>
<Literal xml:lang="en">Energy Metabolism</Literal>
</AnnotationAssertion>
As seen below, it defines a label (lang=en) and definition (lang=en). But the the prefLabel is defined as:
@prefLabel={:none=>["Energy Metabolism"]},
WHY? I would expect:
@prefLabel={:en=>["Energy Metabolism"]},
Below, is the corresponding Class instance in ontologies_linked_data:
#<LinkedData::Models::Class:0x000000010700e120
@aggregates=[#<struct Goo::Base::AGGREGATE_VALUE attribute=:children, aggregate=:count, value=0>],
@created=nil,
@cui=[],
@definition=
{:en=>
["A set of metabolic pathways that are involved in the generation and use of energy within an organism, typically through processes like cellular respiration and photosynthesis."]},
@id=#<RDF::URI:0x5064(https://purl.dsmz.de/schema/EnergyMetabolism)>,
@label={:en=>["Energy Metabolism"]},
@persistent=true,
@prefLabel={:none=>["Energy Metabolism"]},
@prefixIRI=nil,
@previous_values=nil,
@semanticType=[],
@subClassOf=[#<RDF::URI:0x5014(https://purl.dsmz.de/schema/MetabolicPathway)>],
@synonym=[],
@unmapped=
{#<RDF::URI:0x5078(http://www.w3.org/2000/01/rdf-schema#label)>=>{:en=>[#<RDF::Literal:0x508c("Energy Metabolism"@en)>]},
#<RDF::URI:0x5028(http://www.w3.org/2000/01/rdf-schema#comment)>=>
{:en=>
, typically through processes like cellular respiration and photosynthesis."@en)>]},
thway)>],
#<RDF::URI:0x503c(http://www.w3.org/1999/02/22-rdf-syntax-ns#type)>=>[#<RDF::URI:0x50c8(http://www.w3.org/2002/07/owl#Class)>],
#<RDF::URI:0x5050(http://data.bioontology.org/metadata/def/prefLabel)>=>
{:none=>[#<RDF::Literal:0x50dc("Energy Metabolism"^^<http://www.w3.org/2001/XMLSchema#string>)>]},
rgyMetabolism)>],
#<RDF::URI:0x5118(http://data.bioontology.org/metadata/def/mappingLoom)>=>
{:none=>[#<RDF::Literal:0x512c("energymetabolism"^^<http://www.w3.org/2001/XMLSchema#string>)>]}},
@xref=nil>
Good point. We should have seen this. Our driving use cases were very much "SKOS" so we missed it.
@alexskr - why was this issue closed? It's still broken in our production environment. See the https://bioportal.bioontology.org/ontologies/CMECS ontology as an example. The ontology declares English as the natural language, and the Jump to box doesn't work:
The fix introduced in https://github.com/ncbo/ontologies_linked_data/pull/221 fixed problems with D3O ontology; however, this problem remains unresolved for many ontologies. (AIO, BAO, DTO, CMECS, FYP, OPB, etc)
jump_to search box doesn't show results for single language ontologies which set English as the naturalLanguage. Unsetting English fixes the issue.