IRI mappings and catalog file

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

IRI mappings and catalog file

jesper-friis
Many ontologies developed with Protege relies on catalog files to map the IRI of an imported ontology to a local file name or a resolvable URL.

To support that, would it make sense to add an optional dict as argument `irimaps` to Ontology.load()? If given, it would be used to map `base_iri` to a resolvable file name or web location. Most importantly, it should be passed on to recursive calls to Ontology.load() when loading imported ontologies.

EMMO-python has a read_catalog() utility function (see https://github.com/emmo-repo/EMMO-python/blob/f5a3046/emmo/utils.py#L127) that could be copied/adapted to initialise `irimaps` from a Protege catalog file.