Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ontology-level annotation axioms and version info #18

Open
syphax-bouazzouni opened this issue Jul 29, 2022 · 4 comments · May be fixed by #20
Open

Ontology-level annotation axioms and version info #18

syphax-bouazzouni opened this issue Jul 29, 2022 · 4 comments · May be fixed by #20
Assignees

Comments

@syphax-bouazzouni
Copy link

syphax-bouazzouni commented Jul 29, 2022

Hello,

When the parser builds the owl ontology he calls a function called addGroundMetadata which copies ontology-level annotation axioms from the source ontology to the target ontology.
And also checks for the owl#versionInfo property. If found, adds a BioPortal-specific "versionSubject (http://bioportal.bioontology.org/ontologies/versionSubject)" annotation axiom to the target ontology.

But I don't know if it is wanted but the generated ow:Ontology will contain and mix all the annotations of all the imported ontologies.

Example

If we take the example of cnov0_5.owl (one of the ontologies used in the tests)

In the original file, we have

    <owl:Ontology rdf:about="http://purl.org/incf/ontology/Computational_Neurosciences/cno_alpha.owl">
        <dc:date rdf:datatype="&xsd;string">13/03/2012</dc:date>
        <dc:subject rdf:datatype="&xsd;string">An ontology to describe the field of Computational Neurosciences</dc:subject>
        <dc:contributor rdf:datatype="&xsd;string">Birgit Kriener</dc:contributor>
        <dc:title rdf:datatype="&xsd;string">Computational Neuroscience Ontology</dc:title>
        <dc:contributor rdf:datatype="&xsd;string">Erik De Schutter</dc:contributor>
        <dc:contributor rdf:datatype="&xsd;string">Fahim T. Imam</dc:contributor>
        <dc:contributor rdf:datatype="&xsd;string">INCF MultiScale Modeling Task Force</dc:contributor>
        <dc:contributor rdf:datatype="&xsd;string">Lars Schwabe</dc:contributor>
        <dc:contributor rdf:datatype="&xsd;string">Padraig Gleeson</dc:contributor>
        <dc:contributor rdf:datatype="&xsd;string">Sean Hill</dc:contributor>
        <dc:contributor rdf:datatype="&xsd;string">Stephen D. Larson</dc:contributor>
        <dc:contributor rdf:datatype="&xsd;string">Subhasis Ray</dc:contributor>
        <rdfs:comment rdf:datatype="&xsd;string">This ontology is used to add the Definition class of annotation as in NIF.
The source of the definition can be defined with class from OBO-annotation</rdfs:comment>
        <rdfs:comment rdf:datatype="&xsd;string">This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 444 Castro Street, Suite 900, Mountain View, California, 94041, USA.</rdfs:comment>
        <dc:creator rdf:datatype="&xsd;string">Yann Le Franc</dc:creator>
        <owl:versionInfo rdf:datatype="&xsd;string">version 0.5</owl:versionInfo>
        <owl:imports rdf:resource="http://ontology.neuinfo.org/NIF/Backend/OBO_annotation_properties.owl"/>
        <owl:imports rdf:resource="http://ontology.neuinfo.org/NIF/Backend/ro_bfo1-1_bridge.owl"/>
        -<owl:imports rdf:resource="http://protege.stanford.edu/plugins/owl/dc/protege-dc.owl"/>
        -<owl:imports rdf:resource="http://purl.org/incf/ontology/Computational_Neurosciences/external_import/external.owl"/>
        <owl:imports rdf:resource="http://purl.org/obo/owl/ro"/>
        -<owl:imports rdf:resource="http://www.ifomis.org/bfo/1.1"/>
        -<owl:imports rdf:resource="http://www.w3.org/2004/02/skos/core"/>
    </owl:Ontology>

The generated file contains

 <owl:Ontology>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Alan Ruttenberg</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Andrew Spear</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Birgit Kriener</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Erik De Schutter</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Fahim T. Imam</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">INCF MultiScale Modeling Task Force</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Lars Schwabe</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Padraig Gleeson</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Pierre Grenon</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Sean Hill</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Stephen D. Larson</dc:contributor>
        <dc:contributor rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Subhasis Ray</dc:contributor>
        <dc:creator rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Holger Stenzhorn</dc:creator>
        <dc:creator rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Yann Le Franc</dc:creator>
        <dc:date rdf:datatype="http://www.w3.org/2001/XMLSchema#string">13/03/2012</dc:date>
        <dc:format rdf:datatype="http://www.w3.org/2001/XMLSchema#string">application/rdf+xml</dc:format>
        <dc:identifier rdf:datatype="http://www.w3.org/2001/XMLSchema#string">http://www.ifomis.org/bfo/1.1</dc:identifier>
        <dc:language rdf:datatype="http://www.w3.org/2001/XMLSchema#string">en</dc:language>
        <dc:publisher rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Institute for Formal Ontology and Medical Information Science (IFOMIS)</dc:publisher>
        <dc:rights>http://creativecommons.org/licenses/by/3.0</dc:rights>
        <dc:source rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Barry Smith and Pierre Grenon: &quot;The Cornucopia of Formal Ontological Relations&quot;</dc:source>
        <dc:source rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Barry Smith: &quot;Against Fantology&quot;</dc:source>
        <dc:source rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Barry Smith: &quot;Basic Tools of Formal Ontology&quot;</dc:source>
        <dc:source rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Barry Smith: &quot;Beyond Concepts: Ontology as Reality Representation&quot;</dc:source>
        <dc:source rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Pierre Grenon and Barry Smith: &quot;SNAP and SPAN: Towards Geospatial Dynamics&quot;</dc:source>
        <dc:source rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Pierre Grenon, Barry Smith and Louis Goldberg: &quot;Biodynamic Ontology: Applying BFO in the Biomedical Domain&quot;</dc:source>
        <dc:source rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Pierre Grenon: &quot;BFO in a Nutshell: A Bi-categorial Axiomatization of BFO and Comparison with DOLCE&quot;</dc:source>
        <dc:source rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Pierre Grenon: &quot;Nuts in BFO&apos;s Nutshell: Revisions to the Bi-categorial Axiomatization of BFO&quot;</dc:source>
        <dc:source rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Pierre Grenon: &quot;Spatio-temporality in Basic Formal Ontology: SNAP and SPAN, Upper-Level Ontology, and Framework for Formalization&quot;</dc:source>
        <dc:subject rdf:datatype="http://www.w3.org/2001/XMLSchema#string">An ontology to describe the field of Computational Neurosciences</dc:subject>
        <dc:title rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Basic Formal Ontology (BFO)</dc:title>
        <dc:title rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Computational Neuroscience Ontology</dc:title>
        <terms:contributor>Dave Beckett</terms:contributor>
        <terms:contributor>Nikki Rogers</terms:contributor>
        <terms:contributor>Participants in W3C&apos;s Semantic Web Deployment Working Group.</terms:contributor>
        <terms:creator>Alistair Miles</terms:creator>
        <terms:creator>Sean Bechhofer</terms:creator>
        <terms:description xml:lang="en">An RDF vocabulary for describing the basic structure and content of concept schemes such as thesauri, classification schemes, subject heading lists, taxonomies, &apos;folksonomies&apos;, other types of controlled vocabulary, and also concept schemes embedded in glossaries and terminologies.</terms:description>
        <terms:title xml:lang="en">SKOS Vocabulary</terms:title>
        <rdfs:comment rdf:datatype="http://www.w3.org/2001/XMLSchema#string">This ontology is used to add the Definition class of annotation as in NIF.
The source of the definition can be defined with class from OBO-annotation</rdfs:comment>
        <rdfs:comment rdf:datatype="http://www.w3.org/2001/XMLSchema#string">This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 444 Castro Street, Suite 900, Mountain View, California, 94041, USA.</rdfs:comment>
        <rdfs:seeAlso rdf:resource="http://www.w3.org/TR/skos-reference/"/>
        <owl:versionInfo rdf:datatype="http://www.w3.org/2001/XMLSchema#string">1.1.1</owl:versionInfo>
        <owl:versionInfo rdf:datatype="http://www.w3.org/2001/XMLSchema#string">version 0.5</owl:versionInfo>
    </owl:Ontology>

For example the <owl:versionInfo rdf:datatype="http://www.w3.org/2001/XMLSchema#string">1.1.1</owl:versionInfo> and <dc:title rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Basic Formal Ontology (BFO)</dc:title> comes from the imported ontology http://www.ifomis.org/bfo/1.1

@jvendetti
Copy link
Member

Theoretically, I agree that pulling in ontology-level annotations from imported ontologies doesn't seem correct. Since the original developer of this project is no longer at Stanford, I don't know if there was a historical reason for doing this, or if it's just an oversight.

Interestingly, despite what's pointed out above, the REST API appears to return the correct ontology metadata for CNO. The following call:

https://data.bioontology.org/ontologies/CNO/latest_submission?display_links=false&display_context=false&display=ontology,name,version

... returns:

{
  -"ontology": {
    -"administeredBy": [
      "https://data.bioontology.org/users/ylefranc"
    ],
    "acronym": "CNO",
    "name": "Computational Neuroscience Ontology",
    "@id": "https://data.bioontology.org/ontologies/CNO",
    "@type": "http://data.bioontology.org/metadata/Ontology"
  },
  "version": "version 0.5",
  "@id": "https://data.bioontology.org/ontologies/CNO/submissions/8",
  "@type": "http://data.bioontology.org/metadata/OntologySubmission"
}

This could simply be a product of the end user manually entering the metadata when they submitted their ontology through the Rails application, which would initialize these values from the form data.

@ncbo-deployer
Copy link

ncbo-deployer commented Aug 4, 2022 via email

@syphax-bouazzouni
Copy link
Author

Hi @jvendetti , @stdotjohn

Do you have any restrictions, if I remove this behavior (or at least make it optional)

If you want the detailed reason for the "why", you can see this agroportal/project-management#340

@jvendetti
Copy link
Member

Merging in the ontology-level annotations from imported ontologies doesn't seem correct. I guess I would lean toward removing this behavior instead of making it optional. If that change is made and all of the unit tests for ontologies_linked_data and ontologies_api pass, then I think we'd be OK.

@syphax-bouazzouni syphax-bouazzouni linked a pull request Dec 21, 2022 that will close this issue
@alexskr alexskr assigned mdorf and unassigned stdotjohn May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants