bio-ontology-research-group / aberowl-orepo

AberOWL Ontology Repository
7 stars 1 forks source link

Fix labels in ChEBI #55

Closed leechuck closed 9 years ago

leechuck commented 9 years ago

OWLAPI produces weird labels from xrefs in ChEBI.

Reproduce with the following code:

OWLOntologyManager oManager; OWLDataFactory df = OWLManager.getOWLDataFactory() ; OWLOntologyManager lManager = OWLManager.createOWLOntologyManager() OWLOntologyLoaderConfiguration config = new OWLOntologyLoaderConfiguration() config.setFollowRedirects(true) config = config.setMissingImportHandlingStrategy(MissingImportHandlingStrategy.SILENT) def fSource = new FileDocumentSource(new File('chebi.obo')) def ontology = lManager.loadOntologyFromOntologyDocument(fSource, config)

def cl = df.getOWLClass(IRI.create("http://purl.obolibrary.org/obo/CHEBI_82978")) EntitySearcher.getAnnotations(cl, ontology, df.getRDFSLabel()).each { annotation -> // OWLAnnotation println annotation }

reality commented 9 years ago

XRefs are now parsed out of the labels using annotation assertion axioms of http://www.geneontology.org/formats/oboInOwl#hasDbXref

reality commented 9 years ago

https://github.com/bio-ontology-research-group/AberOWL/commit/2e78b827d77309ee0970c1d8d824c79a9df3e41e

reality commented 9 years ago

@leechuck Are there any other IRIs you know of used to indicate XRefs?