OWL2 RL Profile
OWLGraph implements the OWL2 RL (Rule Language) profile — the OWL variant designed for materialization-based reasoning with polynomial-time complexity.
Supported Constructs
Section titled “Supported Constructs”Class Axioms
Section titled “Class Axioms”| Construct | OWL Syntax | Supported |
|---|---|---|
| Named class | a owl:Class | Yes |
| Subclass | rdfs:subClassOf | Yes |
| Equivalent class | owl:equivalentClass | Yes |
| Disjoint classes | owl:disjointWith | Yes |
| Intersection | owl:intersectionOf | Yes |
| Union | owl:unionOf | Yes |
| Complement | owl:complementOf | Yes |
Property Axioms
Section titled “Property Axioms”| Construct | OWL Syntax | Supported |
|---|---|---|
| Object property | a owl:ObjectProperty | Yes |
| Data property | a owl:DatatypeProperty | Yes |
| Domain | rdfs:domain | Yes |
| Range | rdfs:range | Yes |
| Inverse | owl:inverseOf | Yes |
| Sub-property | rdfs:subPropertyOf | Yes |
| Property chain | owl:propertyChainAxiom | Yes |
Property Characteristics
Section titled “Property Characteristics”| Characteristic | Supported | Effect |
|---|---|---|
| Functional | Yes | At most one value per subject |
| Inverse Functional | Yes | At most one subject per value |
| Transitive | Yes | Transitive closure in queries (pred*) |
| Symmetric | Yes | Reverse edge auto-created |
| Asymmetric | Yes | Validated at write time |
| Reflexive | Yes | Self-edge materialized |
| Irreflexive | Yes | Self-edge rejected |
Class Expressions (Restrictions)
Section titled “Class Expressions (Restrictions)”| Expression | OWL Syntax | Supported |
|---|---|---|
| Some values from | owl:someValuesFrom | Yes |
| All values from | owl:allValuesFrom | Yes |
| Has value | owl:hasValue | Yes |
Not Supported (By Design)
Section titled “Not Supported (By Design)”These constructs are outside the OWL2 RL profile or beyond OWLGraph’s current scope:
| Construct | Why Not |
|---|---|
| Full OWL DL tableau reasoning | Computational complexity (exponential worst case) |
| Open-world assumption | Database operates under closed-world assumption |
| Nominals (OneOf) | Enumerated classes not supported |
| Cardinality restrictions | Min/max/exact cardinality not enforced |
| HasSelf | Self-restriction not implemented |
| Datatype restrictions | Facets on datatypes not enforced |
Profile Validation
Section titled “Profile Validation”When you load an ontology, OWLGraph validates it against the RL profile:
- Circular subclass detection —
A subClassOf B subClassOf Ais rejected - Conflicting property characteristics — a property cannot be both symmetric and asymmetric
- Invalid domain/range — references to undeclared classes are flagged
Validation errors are returned in the ontology load response with specific error messages and locations.
Why OWL2 RL?
Section titled “Why OWL2 RL?”The RL profile is the sweet spot for database applications:
- Polynomial-time reasoning — inference is bounded, not exponential
- Materialization-friendly — all inferences can be pre-computed at write time
- Covers 95% of use cases — class hierarchies, property reasoning, and type inference handle most real-world ontologies
- Compatible with graph databases — the closed-world assumption matches how databases operate