I have an ontology where classes may be associated with a UUID, but I'd like to use human readable names for the majority of the work. I'd like to have something like
Declaration( Class( a:C ) )
Declaration( NamedIndividual( a:C ) )
Declaration( NamedIndividual( urn::uuid:00112233-4455-6677-8899-aabbccddeeff ) )
Declaration( NamedIndividual( a:someObject) )
ClassAssertion( a:C a:someObject )
SameIndividual( a:C urn::uuid:00112233-4455-6677-8899-aabbccddeeff )
The intent is to have a specialized processing step which translates from UUIDs to the class, and then do reasoning on an OWL DL ontology from there. To me, it made sense to use the SameIndividual
construct because I think of that UUID as just another name for the class.
What I'm doing is clearly meta-modeling, because I am treating a an entity as both a class and an individual, but I do not expect to actually do any reasoning which leverages that meta-modeling. I'm having trouble telling from the spec whether this is a valid OWL DL document, with a class named a:C
and an individual named a:C
that are treated completely independently, or if I am simply forbidden from having a class and an individual with the same name.
I know I could use EquivalentClasses
, but there are user-experience reasons why I'd like to avoid it. I have a feeling we will be operating on OWL Full documents in the long run, where this question becomes moot, but I'd like to be able to say we're generating valid OWL DL ontologies until we have to make the jump.
Yes, it is allowed to have a class and an individual with the same name, in OWL 2 DL. The document for OWL 2 New Features call this "punning". The result of this is that there are two independent terms, so reasoning about one will not affect reasoning about the other. For instance, the following is consistent (I write it in Turtle syntax, which I'm more familiar with):
ont: a owl:Ontology .
ont:C a owl:Class, ont:C .
ont:D a owl:Thing, owl:Class;
owl:sameAs ont:C;
owl:disjointFrom ont:C .