|
I'm using FuXi.Syntax.InfixOWL in Python to generate an OWL ontology. I want to make all subclasses of a class mutually disjoint, and to do that I'm using the cumbersome owl:disjointWith, specifying it for every subclass. The resulting .owl file is huge and takes forever to load into Protege. Is there any way to do this more concisely? Thanks. |
|
OWL 2 introduces the
Thanks, but I'm actually looking to figure out how to do this in Python, for instance using rdflib or InfixOWL, in an example similar to this one: http://python-dlp.googlecode.com/files/pomr.py Suppose I have So I want a constructor that does something like this:
and then I can get output like yours above when I serialize the graph. I'd like to know if something like this exists in rdflib, or how to implement it. BTW, here is what I've tried:
When I try to serialize I get this error: I've figured it out now. Here's what I did:
The only problem I have with this, though, is that in the serialized XML file, I end up with a lot of descriptions of list configurations with rdf:first and rdf:rest, for every possible configuration of first and rest. This stuff is unnecessary. All I needed was the AllDisjointClasses part. Why is it there? |

