Skip to main content

Oxiland for Python

CI PyPI Python versions Guides License

Oxiland is a typed Python library for working with RDF datasets. It combines an in-memory or persistent model, named graphs, SPARQL 1.1 queries and updates, and streaming RDF input in one dependency-free package.

python -m pip install oxiland
from oxiland import Literal, Model, NamedNode, Triple, query

EX = "https://example.com/"

model = Model()
model.add(
    Triple(
        NamedNode(f"{EX}alice"),
        NamedNode(f"{EX}name"),
        Literal("Alice"),
    )
)

for row in query(
    model,
    f"SELECT ?name WHERE {{ <{EX}alice> <{EX}name> ?name }}",
):
    print(row["name"].value)

What you get

  • native RDF terms with validation, value equality, and hashing;
  • default-graph and named-graph CRUD;
  • in-memory models and local persistent stores;
  • atomic write transactions with rollback on exceptions;
  • ASK, SELECT, CONSTRUCT, DESCRIBE, and SPARQL Update;
  • streaming parse, match, and query-result iterators;
  • Turtle, N-Triples, N-Quads, TriG, and RDF/XML;
  • PEP 561 type information for Pyright, mypy, and IDEs;
  • typed exceptions for RDF, parsing, SPARQL, storage, and I/O failures.

Oxiland has no required Python dependencies. Published wheels contain the native engine and the complete Python API.

Compatibility

Requirement Support
Python CPython 3.10–3.14
Operating systems Linux, macOS, and Windows wheels
Typing PEP 561 marker and bundled stubs
Distribution Binary wheels; no source distribution on PyPI

Installation succeeds only when PyPI has a wheel matching the interpreter and platform. See the installation guide for deployment and source-build guidance.

Persistent datasets and transactions

Use Model.open() when the dataset must survive process restarts. Paths accept str and os.PathLike values.

from pathlib import Path

from oxiland import Literal, Model, NamedNode, Triple

store = Model.open(Path("var/data/catalog"))

with store.transaction() as tx:
    tx.add(
        Triple(
            NamedNode("https://example.com/product/42"),
            NamedNode("https://schema.org/name"),
            Literal("Desk lamp"),
        )
    )

store.sync()

The context commits as one unit when it exits normally. An exception discards all buffered operations. Nested transactions on the same model are rejected with UnsupportedError.

RDF input and output

from oxiland import Model, load_path, serialize_path

model = Model()
loaded = load_path(model, "catalog.ttl", transactional=True)
serialize_path(model, "catalog.nq")
print(f"loaded {loaded} statements")

parse() and parse_path() return lazy quad iterators. load() and load_path() provide progressive, collecting, and transactional import modes so applications can choose memory usage and failure atomicity explicitly. An N-Quads or TriG file containing arbitrary named graphs cannot be imported as one dataset. Load one compatible graph at a time with graph=; dataset-target parsing is not yet exposed in Python.

SPARQL

from oxiland import query, serialize_results, update

exists = query(model, "ASK { ?s ?p ?o }")

rows = query(
    model,
    "SELECT ?s ?p ?o WHERE { ?s ?p ?o } ORDER BY ?s",
    limit=100,
)
for row in rows:
    print(row["s"], row["p"], row["o"])

json_results = serialize_results(
    model,
    "SELECT ?s WHERE { ?s ?p ?o }",
    "json",
)

update(model, 'INSERT DATA { <https://example.com/s> <https://example.com/p> "v" }')

ASK returns bool; SELECT returns a lazy SolutionsIter; CONSTRUCT and DESCRIBE return a lazy TriplesIter. Unbound selected variables have the value None.

Error handling

Catch the narrowest exception that your application can recover from:

from oxiland import OpenStoreError, ParseError, StorageError, load_path

try:
    load_path(model, "incoming.ttl", transactional=True)
except ParseError as error:
    print(error.location, error.message)
except (OpenStoreError, StorageError) as error:
    raise RuntimeError("RDF store unavailable") from error

All package exceptions inherit from OxilandError. Parse failures expose message and location; store-open failures expose path and message.

Documentation

Oxiland is powered by a native implementation for predictable performance, but its public Python API, typing contract, errors, documentation, and release artifacts are maintained as a first-class package. It is not an rdflib compatibility layer; integrations should use the documented Oxiland types.

License

Apache-2.0 OR MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

oxiland-0.10.0-cp314-cp314-win_amd64.whl (3.3 MB view details)

Uploaded CPython 3.14Windows x86-64

oxiland-0.10.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.17+ x86-64

oxiland-0.10.0-cp314-cp314-macosx_11_0_arm64.whl (3.4 MB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

oxiland-0.10.0-cp313-cp313-win_amd64.whl (3.3 MB view details)

Uploaded CPython 3.13Windows x86-64

oxiland-0.10.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

oxiland-0.10.0-cp313-cp313-macosx_11_0_arm64.whl (3.4 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

oxiland-0.10.0-cp312-cp312-win_amd64.whl (3.3 MB view details)

Uploaded CPython 3.12Windows x86-64

oxiland-0.10.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

oxiland-0.10.0-cp312-cp312-macosx_11_0_arm64.whl (3.4 MB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

oxiland-0.10.0-cp311-cp311-win_amd64.whl (3.3 MB view details)

Uploaded CPython 3.11Windows x86-64

oxiland-0.10.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

oxiland-0.10.0-cp311-cp311-macosx_11_0_arm64.whl (3.5 MB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

oxiland-0.10.0-cp310-cp310-win_amd64.whl (3.3 MB view details)

Uploaded CPython 3.10Windows x86-64

oxiland-0.10.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

oxiland-0.10.0-cp310-cp310-macosx_11_0_arm64.whl (3.5 MB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

Details for the file oxiland-0.10.0-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: oxiland-0.10.0-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 3.3 MB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for oxiland-0.10.0-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 19c560aaeda329fe6bdcd029c592f5ac65f4d85865dde2d3fde3eebea54cd154
MD5 b41e825451b42f53c8d74ea98efbe522
BLAKE2b-256 71abbbaf889b44723a39bbfd177c9a9da79d914b9b969afb581540d4697cb676

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp314-cp314-win_amd64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 5eb68a748867c0f74a781d68e9ddcc9db3d519e7ff6a9e9c75bb549fe7822a31
MD5 c1c25b4292611a258dcc36f856034bc1
BLAKE2b-256 4bb3a89cfba62d013822dad4eb9b01d56d1782b9c570bad7b061ee0aaf4453e0

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 705d22da3874d17ae99e8f46d9f1ee4dd12e7693d6563c5e0f5d8480fb2b0593
MD5 bcd7126f238c9f09c7a582195dffe2d4
BLAKE2b-256 0f1e2ca2eec16e1b23b8dc55a45209099088e7fccef790430d4e57e47166004f

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp314-cp314-macosx_11_0_arm64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: oxiland-0.10.0-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 3.3 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for oxiland-0.10.0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 0514a0bf3463084e28b6bd39d358655dd1237e3fd30c0e9de7f6498789bf4424
MD5 dcc6a3e8b41726984c67736352d393c9
BLAKE2b-256 8d755a294ec4937a194098a78ae2820eac78755a95f9c4b19f14ec0c0f56d027

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp313-cp313-win_amd64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b8e85ca8347f7122c948d30c7e79067d0b9ad0279ff529440616ae66ca080fdf
MD5 0043040c3284a1258f69003fc41c8996
BLAKE2b-256 60d6e44418a73fda9ba82d9e942a79051cfeb4d1021ed2be3a15992e7ce7ce18

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c8ae12a857e673d442dda90415bd19202726f4408b0c370af78bb937bb81e9a8
MD5 8bd6d793d8c6d9153a4f1719cea6af36
BLAKE2b-256 44e3f7bfaee9db7a4b06b209ef69b5e65a943e445d4d17cab3f91d88b4e88882

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp313-cp313-macosx_11_0_arm64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: oxiland-0.10.0-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 3.3 MB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for oxiland-0.10.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 99d0685e1ad10e0f6497724d8c6037ae3ca9682312a76a3a7d766074e8a5b65d
MD5 f3143d1d22b7b98910bd149f0caf8392
BLAKE2b-256 d2ccd09dc75642d69b93b44bc25e00ba1b75f0a95572dfe82f5257d8ae417918

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp312-cp312-win_amd64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 9e979c299d0e557b4e799778eae14649d30c951a6da557d5b9f88a8bc13347fe
MD5 dbcb8655f95f880b78e4714cb4552488
BLAKE2b-256 847032f9e66e3862f2fd30097d9e1331b4e8fbea3ddfe8b484d453d5a177e3ee

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ecc0c08c6b4154c770e510d294fc27dd1cb221fd4e2ca7f2df618da83a7bb088
MD5 747367754f0b20c326015bcc9b7dc389
BLAKE2b-256 126caa5813e9913eb405a07dbeefde6a6652f1f223a3c4cab4dd957446e9dcd3

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp312-cp312-macosx_11_0_arm64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: oxiland-0.10.0-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 3.3 MB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for oxiland-0.10.0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 cd48d8c76a8f0a6343b2d1b3f0950a9cea2bd70c4a3798a304bf17527f680d14
MD5 031acc56e73b46ef92fea8da42bb9a6b
BLAKE2b-256 b190bb29a7f2c1df605333df320c2410e75ddb98f7049bc6a1cb1e95c05e750f

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp311-cp311-win_amd64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 51086d1a72062bee837c141ab9812965e3b031254783761405b2f51b54686ab8
MD5 4b88c1230663f8645bfb7072bff10f24
BLAKE2b-256 b552c2c85c07cfff2d41c30ca967f52e82d4e1eb42d7c09214cd8d5647655508

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 a3093640ef8215fbfc93a65f794ac0149bf6901d99ea2cbb9f612162f2ef2f55
MD5 704613aad6071f31aeb8fa23184006e6
BLAKE2b-256 b8e582bd1d503b67c38d1b93140a2a00017b1dee4e0f2ac83da8156b8ddcf6d7

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp311-cp311-macosx_11_0_arm64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: oxiland-0.10.0-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 3.3 MB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for oxiland-0.10.0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 cfdc149f63dd8cdb920963ffca288dcbb7116015ce87dd064982374f96df7f06
MD5 3e5e6bfdbf3aa8993f52ab406be1fa4d
BLAKE2b-256 3bade0a9ce8317d9eaf68628b89b9ba33ee0e44a6c39e44be21be0cf8b2874a3

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp310-cp310-win_amd64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 d1daa2981f1096a4f7db3f9f61cb594bcd6db50a6c052ac8cad702caa8b09df5
MD5 3fb642b97f1680d27658c60d985232e4
BLAKE2b-256 4f1104f3ca272e8080da0318307457032008acdd5b1631e473f28b8f88544862

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oxiland-0.10.0-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for oxiland-0.10.0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 4b42cef8829ab2be67084e52709f5209e1773cd3843695767812401caa1c0b59
MD5 b2430a2855563f370a7f14796079ca09
BLAKE2b-256 99585b322f6d94e3d441049c709c4a65de086269dc83f54d8fa539f8a39ef5c6

See more details on using hashes here.

Provenance

The following attestation bundles were made for oxiland-0.10.0-cp310-cp310-macosx_11_0_arm64.whl:

Publisher: release.yml on eddiethedean/oxiland

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.13.0

15 files

0.12.0

15 files

0.11.0

15 files

This release

0.10.0 This release

15 files

0.9.0

15 files

0.8.0

15 files

0.7.0

15 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page