Ontophora
Typed Pydantic models for the OWL 2 structural specification.
Ontophora represents OWL entities, expressions, axioms, and ontology documents as validated records, so an OWL-aware application gets construct-level data that checks itself and travels as plain JSON — without parsing an OWL surface syntax. Each record has a UID and a fixed construct kind; records refer to one another by UID rather than nesting an object graph.
Scope
Ontophora owns:
- Typed models for the OWL 2 structural construct catalog.
- Construct validation, a registry-derived JSON Schema, and reference shapes.
- JSON envelopes for sets of construct records and content fingerprints.
It does not parse or serialize OWL document formats, store a graph, execute queries, reason over an ontology, or resolve references. Applications that own a complete record set perform those operations.
Relationship to the stack
Ontophora is the typed-model library in the wider ontology tooling family. It is independent of its sister projects:
- Ontoplexis maps OWL/XML to a Cypher-queryable graph and back.
- Ontopoiesis provides operator workflows such as build, lint, test, diff, and render on Ontoplexis projections.
Neither project currently depends on Ontophora at runtime.
Install
pip install ontophora
from ontophora import Klass, SubClassOf, records_to_json
animal = Klass(uid="0x1", iri="https://example.org/animals#Animal")
dog = Klass(uid="0x2", iri="https://example.org/animals#Dog")
axiom = SubClassOf(
uid="0x3",
sub_class_expression=dog.uid,
super_class_expression=animal.uid,
)
print(records_to_json([animal, dog, axiom]))
Documentation
Read the documentation for a tutorial, JSON package guidance, the model rationale, and the API reference.
License
Ontophora is licensed under the Apache License 2.0.
Metadata
Release files for ontophora 2026.7.19
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| ontophora-2026.7.19.tar.gz | 31.0 kB | With provenance | Details for ontophora-2026.7.19.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ontophora-2026.7.19-py3-none-any.whl | Python 3 | none | any | Details for ontophora-2026.7.19-py3-none-any.whl |
Total release size: 90.3 kB
Release files / ontophora-2026.7.19.tar.gz
| Download URL | ontophora-2026.7.19.tar.gz |
|---|---|
| Size | 31.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a0ccc9914e3fcf098df819a4f168aafbd54336ebab408ad054fb217e13d5a74b
|
|
BLAKE2b-256 checksum How to use checksums |
638f97173216103352e0ae609b673ceb977d296fbe37fcc351a722f0a18a2ead
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 19, 2026.
Transparency logRelease files / ontophora-2026.7.19-py3-none-any.whl
| Download URL | ontophora-2026.7.19-py3-none-any.whl |
|---|---|
| Size | 59.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
da04beb806af810b1898f61c6d7722d2b782e4b4397ec232ac70feaaef9dbdea
|
|
BLAKE2b-256 checksum How to use checksums |
d5c22c7dabdc2e8c1c677f533243ce1715dd16f0a0e68bcb55dc73ab42a0854d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 19, 2026.
Transparency logSecurity for ontophora 2026.7.19
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for ontophora-2026.7.19.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 19, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.