TripleModel roadmap
Roadmap for the triplemodel package on PyPI (base class TripleModel). This document tracks planned releases from the current 0.12.0 beta through a stable 1.0.0. Versions follow Semantic Versioning: breaking API changes only on major releases; minors add features; patches fix bugs.
Engine reference: pyoxigraph 0.5.x documentation (model, I/O, store, SPARQL results, migration guide).
Vision: Make RDF a natural persistence and interchange layer for Pydantic-shaped domain models — typed in Python, portable as triples, without bespoke mapping code per project.
Ecosystem: TripleModel is the stateless mapping layer (file parse/serialize from 0.4). SparqlModel (sparqlmodel) is the session, query, and ORM layer and already depends on triplemodel>=0.9,<2. SM-6 tracks SparqlModel 0.4 unified model (SPARQLModel subclasses TripleModel). TripleModel must never depend on SparqlModel.
Document |
Purpose |
|---|---|
Release history |
|
0.11.0 breaking changes (rdflib/SHACL removal) |
|
PyPI publish checklist |
|
Strategy, principles, priorities |
|
TripleModel and SparqlModel — separation of responsibilities |
Boundary contract (both packages) |
SparqlModel maintainer guide (copy to SparqlModel repo) |
Pre-1.0 commitment: Every 0.x release adds capability until TripleModel exposes all pyoxigraph / Oxigraph features that sensibly map to typed Pydantic models. We orchestrate pyoxigraph; we do not reimplement parsers, stores, or SPARQL engines. We do not build sessions, query compilers, or cascade put semantics — that stays in SparqlModel. 1.0.0 is API stability and production hardening — not further engine churn.
Matrix legend: SM in release sections = required for SparqlModel’s planned triplemodel dependency (see integration milestones).
SparqlModel integration milestones
SparqlModel 0.3 uses an interim _triple.py adapter; 0.4 (Option A) makes SPARQLModel a TripleModel subclass and removes the adapter. TripleModel keeps mapping; SparqlModel keeps session, compiler, and cascade policy.
Milestone |
triplemodel deliverable |
SparqlModel outcome |
|---|---|---|
SM-0 |
0.1.x mapping, subject IRI fixes |
Historical optional dev pin |
SM-1 |
0.2 — sync/remove, nested models, multi-value, |
Interim adapter wiring |
SM-2 |
0.3 — blanks, RDF lists |
Hydration via TripleModel loaders |
SM-3 |
0.4 — |
Retire duplicate serializers (SparqlModel 0.6) |
SM-4 |
0.5 — |
Store uses TripleModel dataset helpers |
SM-5 |
0.9–1.0 — API freeze, |
|
SM-6 |
Subclass-safe mapping API (no SparqlModel code change required) |
SparqlModel 0.4 — |
See SparqlModel ROADMAP — 0.4 unified model.
TripleModel will not implement: SPARQLSession, Python where(Model.field == x), SPARQL expression compiler, identity map, FastAPI, or HTTP store — see ECOSYSTEM.md.
0.6 SPARQL helpers (select_models, etc.) are optional conveniences for TripleModel-only users; SparqlModel keeps its own compiler and may use raw graph.query internally.
Oxigraph / pyoxigraph coverage matrix
Status key: done · partial · TBD · out of scope (—)
Oxigraph area |
Capability |
TripleModel surface |
Ver |
|---|---|---|---|
Terms |
|
|
0.1 done |
|
|
0.3 done |
|
Language tags ( |
|
0.3 done |
|
|
preserve via |
0.3 partial |
|
Custom / unknown datatypes |
pluggable |
0.2 done |
|
|
shared registry with rdflib |
0.2 done |
|
|
SPARQL result binding only (not model fields) |
0.6 done |
|
RDF-star / quoted triples |
pyoxigraph 0.5 dropped RDF-star; RDF 1.2 |
TBD |
|
|
extend |
0.11 done |
|
Multiple |
|
0.12 done |
|
Per-object XSD datatypes on one predicate |
|
0.12 done |
|
Multi-valued URI refs |
|
0.12 done |
|
OWL/RDFS ontology hints |
|
0.12 done |
|
Paired inverse field metadata |
|
0.12 done |
|
RDF Containers ( |
out of scope (prefer |
— |
|
Graph API |
|
|
0.1 done |
|
sync cleared fields; functional-property |
0.2 done |
|
|
read single object for 0..1 cardinality fields |
0.2 done |
|
|
|
0.2 done |
|
set ops |
|
0.2 done |
|
slice / |
out of scope (rdflib convenience sugar) |
— |
|
|
|
0.2 done |
|
|
passthrough when creating |
0.2 done |
|
|
|
0.4 done |
|
parse base URI ( |
|
0.4 done |
|
|
first-class kwargs on parse helpers |
0.11 done |
|
|
strengthen |
0.11 done |
|
canonical N-Triples serialize |
document / expose via |
0.11 done |
|
|
|
0.6 done |
|
|
|
0.11 done |
|
SPARQL result files ( |
load/serialize SELECT/ASK/CONSTRUCT result docs |
0.11 done |
|
|
|
0.11 done |
|
SPARQL |
|
0.6 done |
|
SPARQL UPDATE |
|
0.6 done |
|
|
|
0.6 done |
|
|
|
0.7 done |
|
|
export/import options on |
0.3 done |
|
|
|
0.7 done |
|
|
|
0.7 done |
|
|
|
0.3 done |
|
|
|
0.3 done |
|
Property-based typing ( |
|
0.4.1 done |
|
XSD |
literal registry + field import for partial dates |
0.4.1 done |
|
Multi-class document load (one parse) |
|
0.4.1 done |
|
Mapping validation (predicate vs prefix) |
model |
0.4.1 done |
|
URI foreign-key hydration |
|
0.4.1 done |
|
|
|
0.5 done |
|
|
named-graph read/write in dataset helpers |
0.5 done |
|
|
use |
0.5 done |
|
Formats |
Turtle, Trig, N-Triples, N-Quads |
|
0.4 done |
RDF/XML, N3 |
same |
0.4 done |
|
JSON-LD |
same; optional |
0.4 done |
|
TriG, N-Quads, Turtle, RDF/XML, N3, JSON-LD |
done (pyoxigraph) |
0.10 done |
|
TriX, HexTuples, longTurtle |
out of scope in 0.10 (pyoxigraph; were rdflib-era formats) |
0.10 out of scope |
|
Microdata, RDFa |
out of scope (HTML scraping, not domain modeling) |
— |
|
Stores |
Memory ( |
default |
0.1 done |
Remote SPARQL read ( |
removed in 0.10; use SparqlModel or load into |
0.10 out of scope |
|
Remote SPARQL read-write ( |
same |
0.10 out of scope |
|
BerkeleyDB, SQLAlchemy (rdflib stores) |
removed; use |
0.10 out of scope |
|
LevelDB, Kyoto Cabinet (rdflib plugins) |
out of scope for core; link in cookbook |
— |
|
|
|
0.8 done |
|
Store transactions ( |
|
0.8 done |
|
|
fast ingest into disk |
0.11 done |
|
|
snapshot export/import of on-disk store |
0.11 done |
|
|
on-disk store backup helper |
0.11 done |
|
|
compact on-disk store after bulk edits |
0.11 done |
|
|
explicit flush before |
0.11 done |
|
Named-graph lifecycle ( |
|
0.11 done |
|
|
low-level quad pattern iterator (integrators) |
0.11 done |
|
In-memory |
out of scope — use |
— |
|
|
|
0.11 done |
|
Import |
Chunked / streaming model load |
|
0.8 done |
Import |
Strict / warn on unmapped predicates |
|
0.8 done |
Performance |
Predicate-map cache per class |
|
0.8 done |
Tools |
OWL/RDFS stub codegen (experimental) |
|
0.8 done |
Namespace |
|
|
0.2 done |
Security |
untrusted parse URLs / files |
safe defaults on |
1.0 |
Plugins |
Register custom Parser/Serializer/Store |
removed in 0.10; literals/resolvers only |
0.10 out of scope |
SHACL |
Validation (pyshacl) |
removed in 0.11.0 — use pyshacl directly |
0.11 out of scope |
Interop |
oxrdflib rdflib store |
out of scope — no rdflib dependency |
— |
contrib |
GraphDB, RDF4J clients |
out of scope for core; link in cookbook only |
— |
Tools |
|
out of scope (use rdflib directly) |
— |
Paths |
Path algebra |
out of scope (graph traversal, not ORM) |
— |
Before 1.0.0, the matrix above must be done or explicitly out of scope with rationale in this file — no silent gaps.
0.1.0 — Foundation
Status: Released (historical alpha classifier) — on PyPI as triplemodel==0.1.0
Area |
Delivered |
|---|---|
Core |
|
Graph I/O |
|
Terms |
XSD scalars; IRI-like |
Identity |
Subject IRI from |
Store |
In-memory |
rdflib parity: minimal Graph.add path via serialization; most of the matrix still open.
0.1.x hardening (done): Safe subject-id extraction (subject_base / id_from_subject_uri); percent-encoding on export; BNode rejected for str fields; contextual import errors; xsd:string for plain literals; str_strip_whitespace=False on TripleModel; CI + py.typed + 100% coverage; MRO-inherited Rdf config; validate_type on import; duplicate-predicate warning (on_duplicate); unified validation error messages; Annotated import coercion; RFC 3986 IRI schemes on export; OnDuplicate public export.
SparqlModel (SM-0): Optional local/dev pin on triplemodel==0.1.* for experiments; no required triplemodel dependency in sparqlmodel until 0.2 (SM-1).
0.2.0 — Terms, fields, and namespaces
Status: Released (historical alpha classifier) — on PyPI as triplemodel==0.2.0
Theme: Everything needed for ordinary RDF-shaped Pydantic models on a single default graph.
Multi-valued fields —
list[T],set[T]↔ multiple objects per predicate (0.3+:set[T]only;list[T]isrdf:List)Nested
TripleModel— blank node or named IRI embedding (configurable)Optional & null semantics — omit vs explicit empty; remove prior triples when a field is cleared on re-export
Custom
Literaldatatypes — register converters (Decimal,UUID,Enum, …); wire rdflibterm.bind()Namespace helpers — CURIE expansion,
Rdf.prefixes→Graph.bindDefinedNamespacevocabs — re-export common rdflib namespaces fromtriplemodel.vocabbind_namespacesstrategies — passthroughcore/rdflib/nonewhen constructing graphsGraph merge policies — replace / patch / add when writing into existing
GraphGraph set operations —
merge_graphs()helper; BNode identity documented in docstringsGraph.set/Graph.value—graph_set/graph_valuehelpersGraph iterator helpers —
objects_for_fieldDuplicate predicate warning — scalars use
on_duplicate; collections import all values
Exit criteria: FOAF Person with multiple nick values and embedded mbox round-trips; prefixes appear in serialized Turtle; clearing age=None removes foaf:age triples on re-export.
SparqlModel (SM-1): Ship sync_to_graph / model_to_graph(..., mode="replace"|"patch") (or equivalent) for owned-predicate replacement; Rdf.prefixes + CURIE expansion aligned with SparqlModel __prefixes__; optional explicit IRI id field alongside id_field + namespace; document triple-ownership boundaries for cascade layers.
0.3.0 — Literals, blanks, lists, and identity
Status: Released (historical alpha classifier) — on PyPI as triplemodel==0.3.0
Theme: Full rdflib term expressiveness for model fields.
LangString/ per-language fields —Literal.langround-tripTyped XML/HTML literals —
rdf:XMLLiteral,rdf:HTMLasstr; unknown datatypes viaOpaqueLiteralArbitrary datatype literals — preserve unknown datatype URIs via
OpaqueLiteralBlank nodes — import/export;
skolemize/de_skolemizeonto_graph/from_graphRDF collections —
list[T]↔rdf:List;set[T]= multiple objects (breaking vs 0.2)ResourceRef— validated IRI resource fieldsBNode stability —
Rdf.blank_node_policy(fresh|stable)
Exit criteria: Dublin Core title with language tags; blank-node Address; RDF list of nick values all round-trip (examples/exit_criteria_03.py).
SparqlModel (SM-2): Hydration can delegate single-resource load to TripleModel before relationship expansion; blank-node strategy documented for embedded SPARQLModel values.
0.4.0 — Parsing, serialization, and validation
Status: Released (beta) — on PyPI as triplemodel==0.4.0
Theme: All rdflib syntaxes that make sense for documents (not HTML).
TripleModel.parse/.serialize— delegate toGraph.parse/Graph.serializeFormat support — Turtle, Trig, N-Triples, N-Quads, RDF/XML, N3, JSON-LD, TriX, HexTuples, longTurtle (rdflib-era; TriX/HexTuples/longTurtle removed in 0.10 — see Migrating to TripleModel 0.10.0 (pyoxigraph))
Format autodetection — filename suffix and
format=/ media type passthroughBase URI on parse — rdflib 7
publicIDsemantics:Rdf.base_urifor resolving relative IRIs (not named-graph id)parse_file/parse_url— parse RDF from path or URL intolist[TripleModel]parse(data=...)— load from string (Turtle/JSON-LD snippets in apps and tests)JSON-LD context — optional
@contextonRdfclass for compaction; passthrough compact/expand kwargsSHACL (optional extra) — validate before
to_graph()via pyshacl or equivalentInverse predicates — import via inverse predicate; export and sync clear forward links;
replace/patchremove stale inverse triples on other subjectsSubclass dispatch — multiple
type_uri; import picks most specific registered model
Exit criteria: Same Person instance equivalent from Turtle file, JSON-LD string, and in-memory Graph; invalid data fails SHACL when extra installed (examples/exit_criteria_04.py).
SparqlModel (SM-3): export_model / file load paths call TripleModel; remove parallel format registry from SparqlModel.
Real-world validation (2026): examples/realworld exercises Nobel linked data, DCAT catalogs, Wikidata excerpts, and Schema.org NGO records. The examples run offline in CI and surfaced gaps between “RDF works” and “feels Pythonic in application code.” See Real-world ergonomics (0.4.1+) below.
0.4.1 — Real-world ergonomics
Status: Released (beta) — on PyPI as triplemodel==0.4.1
Theme: Close the gap between typed records and linked-data workflows—without waiting for Dataset (0.5) or full SPARQL helpers (0.6). Informed by examples/realworld.
Priority |
Feature |
Status |
|---|---|---|
P0 |
Single-pass multi-class load ( |
Done |
P0 |
Mapping validation (predicate local name; prefix namespace warning) |
Done |
P0 |
XSD partial dates ( |
Done |
P1 |
Property-based typing ( |
Done |
P1 |
URI FK hydration ( |
Done |
P1 |
Linked object graphs in examples (cookbook / nested embed patterns) |
Docs (optional nested links in examples) |
P1 |
Refactor in-repo examples |
Done |
P2 |
Lang-tagged label defaults |
|
P2 |
QID / slug conventions |
Wikidata IDs ( |
P2 |
Optional inverse export |
Import reads inverse; export is forward-only (by design) but some portals expect bidirectional edges |
P3 |
Refresh-from-endpoint recipe |
Wikidata excerpt maintenance via SPARQL CONSTRUCT |
Exit criteria: Nobel + DCAT examples use one parse/load_models call per file; Wikidata capitals use instance_of or documented discovery without hard-coded QID loops; Schema.org NGOs import foundingDate without manual str workaround; invalid rdf_predicate in rdf_field fails at class definition with a clear error.
Example updates (ship with 0.4.1): Each feature lands with corresponding example refactors—no “API only” release.
Example |
After 0.4.1 |
|---|---|
|
|
|
One parse/load for catalog, dataset, distribution; nested catalog → dataset where data allows |
|
|
|
Typed |
|
Touch only where a 0.4.1 API is demonstrated (mapping validation demo, |
|
Runnable commands match refactored scripts |
CI: tests/test_realworld_examples.py must exercise the new APIs (not only stdout smoke tests).
Not in 0.4.1 (later releases): SPARQL SELECT/CONSTRUCT loaders (0.6), CBD for subgraph extract (0.7), named graphs (0.5), inverse export default-on (stay forward-only unless opted in).
0.5.0 — Datasets and named graphs
Status: Released (beta) — on PyPI as triplemodel==0.5.0
Theme: rdflib Dataset (replacing deprecated ConjunctiveGraph).
Rdf.graph_iri/@graph— map model class or instance to a named graph IRIto_dataset/from_dataset— serialize models into correct named graphsDataset.get_context()/quads()— read and write via named-graph helpersall_from_dataset— load byrdf:typewithin a graph contextDefault graph vs union — document query/import behavior (union default in rdflib)
Trig / N-Quads round-trip — named graph boundaries preserved
Migrate from
ConjunctiveGraph— document rdflib 6→7 /publicIDchanges for dataset users
Exit criteria: Two model types in different named graphs round-trip through Trig without collision.
SparqlModel (SM-4): Only if SparqlModel models gain named-graph context; otherwise defer.
0.6.0 — SPARQL and remote graphs
Status: Released (beta) — on PyPI as triplemodel==0.6.0 (see 0.8.0 for latest)
Theme: rdflib query and SPARQL store integration (TripleModel passthrough — not a Python query DSL).
select_models— SPARQL SELECT →list[TripleModel]with variable→field mappingconstruct_models— CONSTRUCT/DESCRIBE → target model classask— thin wrapper returningboolSPARQL UPDATE —
apply_update(graph, query)with documented interaction with modelsload_sparql—SPARQLStore/ read-only endpoint into models (historical, rdflib 0.6; removed in 0.10 — raisesNotImplementedError)SPARQLUpdateStore— read-write remote graph pattern (optional extra if needed)Federated
SERVICE— document querying remote endpoints inside SPARQLPrepared queries —
prepareQuery()+initNsfrom modelRdf.prefixesinitBindings— pre-bind subject URI or field values in prepared model queriesResult types — handle all rdflib result kinds (bindings, boolean, graph, JSON)
Exit criteria: Load Person rows from a public SPARQL endpoint in ≤10 lines; UPDATE example in docs.
SparqlModel: Not required for integration gate — SparqlModel owns app-side SPARQL ergonomics. TripleModel may expose thin helpers; SparqlModel keeps compiler + HttpStore roadmap.
0.7.0 — Graph algorithms and RDFS ✅
Status: Released (beta) — on PyPI as triplemodel==0.7.0
Theme: rdflib graph operations that help modeling, not replace reasoners.
cbdwrapper —cbd_graph,cbd_model,TripleModel.cbdTransitive helpers —
transitive_objects/transitive_subjects;Transitive/rdf_field(..., transitive=True)on importgraphs_equal—isomorphic+ optional BNode normalization for testsmodel_diff/ graph diff —graph_diff,model_diff,GraphDiffSafe graph merge — documented in Graph algorithms and RDFS and Working with graphs
RDFS subclass import —
resolve_model_class_with_rdfs;Rdf.resolve_subclass(default true)Vocabulary registry —
VocabularyRegistryCodegen (experimental) — deferred from 0.7; shipped in 0.8 as
triplemodel-codegenhydrate_refs/model_join— batch-load shared ref URIs; Wikidata capitals example updatedCatalog & registry patterns — doc pointers in guide 14 to
examples/realworld/
Exit criteria: ✅ examples/exit_criteria_07.py (subclass dispatch + CBD); Wikidata capitals uses hydrate_refs.
0.8.0 — Stores, scale, and ergonomics ✅
Status: Released (beta) — on PyPI as triplemodel==0.8.0
Theme: rdflib stores and production-sized graphs.
SPARQL store adapter — documented pattern in guide 15 + guide 13 (persistent remote graphs)
Optional extras —
sqlalchemy,berkeleydbstore backends with examples (removed in 0.10; useopen_graph("disk", path))Store lifecycle —
open_graph,graph_store_session,destroy_storeStore transactions —
store_commit/store_rollbackpassthroughBatch import —
iter_graph_to_models,load_models_streaming,parse_into_store_graphCaching — predicate maps per model class (
metadata/predicate_map.py)Strict mode —
Rdf.strict_import,warn_unmapped_fieldsPlugin hooks —
triplemodel.plugins(pre-0.9 full registry)Codegen (experimental) —
triplemodel-codegenCLI
Exit criteria: ✅ examples/exit_criteria_08.py (chunked/streaming benchmark); disk store via open_graph("disk", ...).
0.10.0 — pyoxigraph engine
Theme: Replace rdflib with pyoxigraph as the runtime RDF store; keep mapping API stable.
Engine swap —
pyoxigraph.Storeviatriplemodel.Store/RdfGraphTerms —
NamedNode,Literal,BlankNode; manualrdf:List; skolemize/CBD helpersFile I/O — parse/serialize through pyoxigraph (
Turtle,TriG,N-Triples,N-Quads,RDF/XML,N3,JSON-LD)Dataset — named graphs on one store (
RdfDataset)SPARQL —
Store.query/updatepassthrough; remoteSPARQLStoreout of scopeStores —
memoryanddisk(open_graph); droprdflib-sqlalchemyextraPlugins — remove rdflib
register_parser/register_serializer/register_storeSHACL — optional bridge in
[shacl]extra (removed in 0.11.0)Migration guide — Migrating to TripleModel 0.10.0 (pyoxigraph)
API stability exception — graph type break documented in API stability (0.9+)
Exit criteria: Core quickstart round-trip; pytest green; docs and compat CI updated.
SparqlModel (SM-7): Downstream pin triplemodel>=0.10,<2 when SparqlModel adopts Store (see SparqlModel ecosystem guide (for SparqlModel development)).
0.11.0 — rdflib removal ✅
Status: Released (beta) — on PyPI as triplemodel==0.11.0
Theme: Remove the last rdflib integration; align naming with pyoxigraph.
SHACL removed —
triplemodel[shacl]extra,validate_graph,shacl_shapes=API renames —
**rdflib_kwargs→**format_kwargs;publicID→base_irionStore.parsebind_namespaces— dropstrategy="rdflib"(use"core")Migration — Migrating to TripleModel 0.11.0
Exit criteria: No import rdflib in package source; make ci green.
0.11.0 — pyoxigraph surface completion ✅
Status: Shipped in 0.11.0 (additive APIs on the same release line as rdflib removal)
Theme: Expose remaining pyoxigraph 0.5.x store, I/O, and SPARQL-result APIs that help typed-model workflows — without reintroducing sessions, remote SPARQL graphs, or rdflib.
Reference sections: RDF Model · Parsing and Serialization · RDF Store · SPARQL utility objects.
Store operations (disk / scale)
bulk_load—bulk_load_into_graph(graph, path, format=, base_iri=, to_graph=)wrappingStore.bulk_loaddump/load—dump_store/load_storefor on-disk store snapshotsbackup—backup_store(target_directory, graph=)for RocksDB-backed storesoptimize—optimize_store(graph=)after bulk import or heavysync_to_graphworkloadsflush—store_flush(graph);Graph.closeflushes when supportedNamed-graph lifecycle —
list_named_graphs,ensure_named_graph,clear_named_graph,remove_named_graphquads_for_pattern—iter_quads_for_patternoverStore.quads_for_pattern
Parse / serialize (I/O)
Parse flags —
lenient=,without_named_graphs=,rename_blank_nodes=onparse_into_graph, dataset/model parse helpersRdfFormatdiscovery —infer_formatfalls back toRdfFormat.from_extension/from_media_type;format_supports_datasets/format_supports_rdf_starSerialize prefixes —
Graph.serializepasses bound prefixes (regression-tested for Turtle/TriG)Canonical N-Triples — pyoxigraph canonical NT for stable graph comparison (see guide 10)
SPARQL results
parse_query_results— load saved SPARQL result files (JSON/XML/CSV/TSV) intoSparqlResultResult serialization —
SparqlResult.serialize(format=)for SELECT/ASK resultsAdvanced
Store.query—use_default_graph_as_union,default_graph,named_graphs,base_irionrun_sparql/PreparedModelQuery.execute
Terms / RDF 1.2
Literal.direction— optionaldirectiononLangStringandLangmetadata (pyoxigraphltr/rtl/auto)RDF 1.2 triple terms — out of scope for 0.11.0 — use raw
pyoxigraph.Triple; TripleModel fields stay resource-oriented (see TripleModel project plan)
Explicitly deferred in 0.11.x
pyoxigraph API |
TripleModel stance |
|---|---|
|
Expert SPARQL extension — use raw |
In-memory |
Use |
No rdflib dependency |
|
Remote SPARQL endpoint store |
out of scope (0.10); SparqlModel or load-then-query |
SHACL / pyshacl |
out of scope (0.11.0); external validation |
Exit criteria: Matrix rows marked 0.11 are done or out of scope; guide 15 documents disk bulk_load / backup / optimize; one example script under examples/stores/.
SparqlModel: Disk-store helpers are optional for SM-7; session-level remote graphs remain in SparqlModel.
0.9.0 — rdflib parity audit and API freeze (historical)
Theme: Close the matrix; stabilize public API.
Coverage audit — every row in the matrix done, partial, TBD, or out of scope (see matrix above)
Plugin passthrough —
register_parser/register_serializer/register_storeintriplemodel.pluginsAPI audit —
__all__freeze documented indocs/API_STABILITY.mdMigration guide — N/A (no production adopters; CHANGELOG is historical record)
Full API reference — Sphinx
docs/api/+ autodoc ontriplemodeland submodulesCookbook —
docs/cookbook/(formats, SPARQL/Fuseki, Dataset, SHACL, stores, real-world)Typing —
py.typed+ty checkin CI (canonical checker; not mypy)Compatibility matrix — pinned pydantic / pyoxigraph ranges in CI
compatjob
Exit criteria: No open matrix gaps except TBD / out of scope; beta on PyPI. (examples/exit_criteria_09.py is now 0.10 Store + disk smoke — not 0.9 plugin registry.)
SparqlModel (SM-5): Compatibility range in ECOSYSTEM_SPARQLMODEL.md; SparqlModel-side migration when pinning triplemodel (optional cross-package CI deferred).
1.0.0 — Stable release
Theme: Trustworthy default for Pydantic ↔ RDF in production. No new engine surface — only fixes, docs, and governance.
Requirement |
Detail |
|---|---|
pyoxigraph coverage |
Matrix complete per 0.9/0.10 audit (see matrix above) |
API stability |
Semver commitment; deprecations required ≥1 minor earlier |
Security |
Safe parser defaults; document XML/URL fetch risks |
Quality |
≥90% coverage on core; integration tests per supported format and SPARQL |
Packaging |
PyPI wheels; extras: |
Governance |
|
Celebration criteria: A downstream app can depend on triplemodel~=1.0 knowing pyoxigraph store/I/O/SPARQL features needed for typed models are exposed (per matrix), SparqlModel can pin this release for mapping, and patch releases are safe.
Explicitly out of scope (even pre-1.0)
rdflib areas TripleModel does not wrap
Use rdflib directly, SparqlModel, or another integration package:
Item |
Rationale |
|---|---|
HTML Microdata / RDFa parsers |
Scraping workflow, not domain model I/O |
RDF Containers ( |
Legacy container model; use |
Graph slice / |
rdflib REPL sugar; use explicit |
|
Graph traversal DSL, not Pydantic ORM |
|
Vendor-specific; belongs in integrations |
LevelDB / Kyoto Cabinet store plugins |
Third-party rdflib extensions; cookbook only |
|
CLI is rdflib’s job |
Custom SPARQL algebra ( |
Expert extension point; use rdflib directly |
Full OWL reasoning |
Use dedicated reasoners |
Replacing rdflib parsers, stores, or SPARQL engine |
TripleModel orchestrates, never forks |
Application features owned by SparqlModel (not TripleModel)
Item |
Package |
|---|---|
|
SparqlModel |
Python query DSL ( |
SparqlModel |
SPARQL WHERE compiler |
SparqlModel |
|
SparqlModel |
HTTP SPARQL store ( |
SparqlModel |
FastAPI integration |
SparqlModel optional extra |
Ecosystem summary
triplemodel |
sparqlmodel |
|
|---|---|---|
Role |
Mapping + files |
Session + queries |
State |
Stateless |
Stateful |
Base class |
|
|
Depends on |
pyoxigraph, pydantic |
pydantic; triplemodel (from 0.2) |
Full boundaries: ECOSYSTEM.md · Strategy: PLAN.md · SparqlModel dev copy: ECOSYSTEM_SPARQLMODEL.md
How to influence the roadmap
Open an issue with the label
roadmapdescribing your use case.If requesting a new pyoxigraph feature, name the API (
Store.method,parseflag,RdfFormat, etc.) and link to the pyoxigraph docs.For SparqlModel integration needs, reference milestone SM-* and whether the feature belongs in TripleModel or SparqlModel per ECOSYSTEM.md.
Link vocabularies, sample data, or validation shapes when possible.
Version summary
Version |
Focus |
rdflib layers |
SparqlModel |
|---|---|---|---|
0.1.0 |
Flat models, in-memory graph round-trip |
|
SM-0 (optional dev pin) |
0.2.0 |
Fields, namespaces, merge, remove/set |
|
SM-1 (dependency gate) |
0.3.0 |
Literals, blanks, lists, skolemize |
|
SM-2 |
0.4.0 |
All document formats, base URI, SHACL |
|
SM-3 |
0.4.1 |
Real-world ergonomics (multi-class load, Wikidata typing, XSD dates) |
property typing, |
— |
0.5.0 |
Named graphs |
|
SM-4 (if needed) |
0.6.0 |
SPARQL passthrough + remote store |
|
— |
0.7.0 |
CBD, isomorphism, RDFS, safe merge |
graph algorithms |
✅ |
0.8.0 |
Persistent stores, scale |
|
✅ |
0.9.0 |
Matrix audit, API freeze (rdflib) |
|
SM-5 prep |
0.10.0 |
pyoxigraph engine |
|
SM-7 |
0.11.0 |
rdflib/SHACL removed |
API rename ( |
— |
0.11.0 |
pyoxigraph surface + rdflib removal |
|
RDF 1.2 |
0.12.0 |
SparqlModel 0.13 mapping parity (additive) |
|
No migration file (see |
1.0.0 |
Stable, documented, governed |
oxigraph matrix frozen |
SM-5 pin |