"punning" feature not supported in 0.48?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

"punning" feature not supported in 0.48?

vince
>>> cl = get_ontology("https://purl.obolibrary.org/obo/cl.owl").load()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/vincent/Downloads/vinceowl/lib/python3.12/site-packages/owlready2/namespace.py", line 1046, in load
    if self.world.graph.indexed: self._load_properties()
                                 ^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/vincent/Downloads/vinceowl/lib/python3.12/site-packages/owlready2/namespace.py", line 1083, in _load_properties
    raise TypeError("'%s' belongs to more than one entity types (cannot be both a property and a class/an individual)!" % Prop.iri)
TypeError: 'http://purl.obolibrary.org/obo/STATO_0000416' belongs to more than one entity types (cannot be both a property and a class/an individual)!


see https://github.com/obophenotype/cell-ontology/issues/3237 for more discussion and link relevant to punning concept.

I recognize this is an OWL DL 2 spec concern, but am not sure whether owlready2 cannot cope with this.

a CL maintainer mentioned that protege and OWL api-based tools accommodate punning.
Reply | Threaded
Open this post in threaded view
|

Re: "punning" feature not supported in 0.48?

vince
Still interested in this issue.  If it is out of scope please close.
Reply | Threaded
Open this post in threaded view
|

Re: "punning" feature not supported in 0.48?

Jiba
Administrator
Sorry for the delay :-(

Punning has never been supported by Owlready, and will probably never be. It is too complex to implement in Python as it conflicts with the Python model, and the semantics of punning is not very clear in OWL.

Jiba
Reply | Threaded
Open this post in threaded view
|

Re: "punning" feature not supported in 0.48?

vince
Thanks for clarification.