monarch-initiative / mondo

Mondo Disease Ontology
http://obofoundry.org/ontology/mondo
Creative Commons Attribution 4.0 International
234 stars 53 forks source link

Remove ICD10EXP prefixes from Mondo prior to release #5791

Open matentzn opened 1 year ago

matentzn commented 1 year ago

Context

cthoyt commented 1 year ago

can we more generally engineer in some tests for compliance with Bioregistry (or a potential future monarch context in Bioregistry)?

matentzn commented 1 year ago

If we had a method:

bioregistry.isCompliant(ontology, context=null) I would prioritise this, else we have a QC check that manually enumerates the permitted prefixes.

cthoyt commented 1 year ago

I can prepare such a function. Are the QC checks for MONDO easy to add arbitrary python to?

matentzn commented 1 year ago

I wonder if it would be better to have this logic in OAK rather than bioregistry, because of separation of concerns?

In either case, its not as easy as you might think, as you have annotations both as values of properties MONDO:123 oio:hasDbXref "FOO:BAR" but also as values of annotation properties, i.e.

MONDO:123 IAO:115 "some definition" { oio:source "FOO:BAR" }

You can just add a QC check by simply adding it to the make pipeline: arbitrary python. There is already some of that, but I guess we should think about how we extend oak validate to allow such checks as a way to standardise them a bit better.

matentzn commented 1 year ago

This should already work, here is the query: https://github.com/monarch-initiative/mondo/blob/master/src/sparql/update/delete-axiom-annotations-by-prefix.ru

Investigate why id does not.

matentzn commented 1 year ago

I know why, because of the axiom annotations, they need to be deleted as well.. this is more complex, and requires adding 4-5 Optional clauses to capture all possible axiom annotations, and delete these as well.