Open serjoshua opened 11 months ago
(1) The OLS4 dataloader is an RDF tool and therefore only supports loading RDF files. This means that other non-RDF OWL serialisations such as OBO format and OWL XML are never going to be supported (though of course they can be converted prior to loading). For these (very few) cases we can either ask the upstream ontology vendors to provide an RDF/XML file, or possibly outsource conversion to Robot.
(2) Though we support all the different RDF serializations, the majority of the ontologies are provided without any
content-type
or any useful file extension to indicate which serialization format they contain. For example, this ontology from the OLS config is Turtle, but the file extension isowl
and thecontent-type
istext/plain
. No suggestion of Turtle encoding anywhere.Even the OBO foundry ontologies do this. If we resolve for example
http://purl.obolibrary.org/obo/ro.owl
it redirects to https://raw.githubusercontent.com/oborel/obo-relations/master/ro.owl. File extension:.owl
,content-type
istext/plain
. While the file content is RDF/XML, there is nothing to suggest that it isn't, for example, OWL XML, or Turtle, or JSON-LD. We only know how to load it in OLS4 because RDF/XML is the hardcoded default.Why does this work in Protegé and OLS3? Because OWLAPI literally bruteforce loads ontology files by trying every loader until it finds one which works.
While we could probably do something similar in OLS4, I think ultimately it is up to the ontology developers to provide correct metadata, if not by
content-type
then at least by file extension. The whole.owl
thing is a mess. If it's RDF/XML it should be.xml
and if it's Turtle it should be.ttl
. OR if it really wants to be.owl
it should be served up with acontent-type
.So TL;DR I think we should continue to default to trying to read
.owl
files as whatevercontent-type
is provided and falling back on RDF/XML.
I would recommend for the OBO ones:
@serjoshua What do you recommend the failed ontologies that are .OWL to do? Resave things as .rdf file?
Yes or use robot to convert them on the command line http://robot.obolibrary.org/
OBO
EBI OLS Ontologies
Original spreadsheet