owlcollab / oboformat

Automatically exported from code.google.com/p/oboformat
5 stars 2 forks source link

1.6: Clarify use of idspace as a mechanism for controlling CURIE expansion and persist these as shacl triples #132

Open cmungall opened 1 year ago

cmungall commented 1 year ago

Easily allow use of non-OBO CURIEs in OBO files (e.g., xref values which are meant to expand to IRIs)

PRO currently tries to use the idspace tag, but the existing OBO parser doesn’t implement this e.g.,

idspace: Alzforum_mut http://www.alzforum.org/mutations/

the OWLAPI may be strictly correct here as the rule of idspaces is accidentally embedded in the section on relations/Typedefs, rather than being a standalone subsection

https://owlcollab.github.io/oboformat/doc/obo-syntax.html#5.9.3

Proposals:

  1. the spec clarifies that idspace is used universally as a means of CURIE expansion: Term, Typedef, subsetdef, synonymtypedef
  2. idspace is persisted in the OWL using shacl:Namespace objects
  3. if the range of a hasDbXref or consider or replaced_by then instead of treating as a string literal, it is treated as an OWLEntity with the expanded URI
  4. If an ID that does not contain a ‘:’ is looked up in idspaces, and if found the expansion is used as the full URI. If not found, it falls back to the rules specified in 1.4. This would allow more flexibility in URIs for synonymtypes, subsets, annotation and object properties while retaining traditional shorthand forms

The SHACL triple expansion would look like this:

idspace P NS
==>
sh:declare [
        sh:prefix "P" ;
        sh:namespace "NS" ;
    ] ;