Skip to main content

Pylon

Async PostgreSQL mapper for the JALDIS platform. Provides a schema definition DSL, an PyQL query language, OpenSearch integration, and vector index support.

Requirements

  • Python 3.13+
  • PostgreSQL 18+

Installation

pip install pylon-db

For the native Rust client — PyQL queries from Rust, no Python interpreter involved — add the pylon-db-client crate instead:

[dependencies]
pylon-db-client = "0.4"

It is published as pylon-db-client and imported as pylon_client; see the Rust client reference.

Configuration

Pylon is configured programmatically via Config and its child dataclasses.

import os
from pylon import Client, Config, DatabaseConfig, SearchConfig, ModelConfig

client = Client(
    config=Config(
        database=DatabaseConfig(
            host="localhost",
            port=5432,
            name="mydb",
            user="myuser",
            password=os.environ["PYLON_DB_PASSWORD"],
        ),
        search=SearchConfig(
            host="localhost",
            port=9200,
            password=os.environ["PYLON_SEARCH_PASSWORD"],
        ),
        models=ModelConfig(
            api_style="openai",
            api_url="https://api.openai.com",
            model="text-embedding-3-small",
            secret=os.environ["OPENAI_API_KEY"],
        ),
    )
)

A pylon.toml file can be used instead via load_config():

from pylon import Client
from pylon.config import load_config

client = Client(config=load_config())

See the configuration reference for the full pylon.toml schema.

Development

Pylon is a Rust workspace plus a Python package; the two are joined by a PyO3 extension module (pylon._core) built with maturin.

Building

maturin develop      # builds pylon._core into the active virtualenv
pip install -e ./    # maturin develop alone can leave a stale .so behind

The test suite fails fast with a "rebuild it" message if pylon._core is older than the Python code being tested against it, rather than silently skipping the affected tests.

Testing

python -m pytest                        # Python suite (live-DB tests excluded)
cargo test --workspace --exclude pylon-py   # Rust suite

--exclude pylon-py is required, and is not the same caveat as excluding it from linting. PyO3 extension modules link against the interpreter through build configuration that only maturin supplies, so a plain cargo build or cargo test on that crate fails at the link step with undefined symbols (_PyList_New, _Py_NoneStruct, …). It still type-checks fine, which is why CI runs cargo clippy -p pylon-py --lib separately — that crate is the only consumer of several pylon-core/pylon-pgcon APIs, so skipping it entirely would let a signature change break the extension unnoticed.

Live-Postgres tests are opt-in and need a throwaway database:

export PYLON_PGCON_TEST_DSN=postgresql://postgres:postgres@localhost:5432/pylon_live_test
cargo test --workspace --exclude pylon-py -- --ignored --test-threads=1
python -m pytest -m live_db

These create and drop schemas freely — never point them at a real database.

Linting

cargo clippy --workspace --exclude pylon-py --all-targets -- -D warnings
cargo clippy -p pylon-py --lib -- -D warnings
cargo fmt --check
ruff check pylon tests
ruff format --check pylon tests

Metadata

Release files for pylon-db 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pylon-db 0.4.0
File Size Uploaded
pylon_db-0.4.0.tar.gz 1.0 MB Details

Built distributions (wheels)

Table of built distributions (wheels) for pylon-db 0.4.0
File
pylon_db-0.4.0-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details
pylon_db-0.4.0-cp314-cp314-manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.28+ x86-64 Details
pylon_db-0.4.0-cp314-cp314-manylinux_2_28_aarch64.whl CPython 3.14 CPython 3.14 Linux glibc 2.28+ ARM64 Details
pylon_db-0.4.0-cp314-cp314-macosx_11_0_arm64.whl CPython 3.14 CPython 3.14 macOS 11.0+ ARM64 Details
pylon_db-0.4.0-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
pylon_db-0.4.0-cp313-cp313-manylinux_2_28_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.28+ x86-64 Details
pylon_db-0.4.0-cp313-cp313-manylinux_2_28_aarch64.whl CPython 3.13 CPython 3.13 Linux glibc 2.28+ ARM64 Details
pylon_db-0.4.0-cp313-cp313-macosx_11_0_arm64.whl CPython 3.13 CPython 3.13 macOS 11.0+ ARM64 Details

Total release size: 50.8 MB

Release files / pylon_db-0.4.0.tar.gz

Download URL pylon_db-0.4.0.tar.gz
Size 1.0 MB
Tags Source
SHA-256 checksum
How to use checksums
742a7222ce3fa1d4cb6c1091220fc1beb926285740ff54b3be6f6413f9458d1b
BLAKE2b-256 checksum
How to use checksums
86ad004bbc54d46af1d5c1aba8b65b432c9cce0fd95c6f41014e4c621762e44c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Oct 4, 2026.

Transparency log

Release files / pylon_db-0.4.0-cp314-cp314-win_amd64.whl

Download URL pylon_db-0.4.0-cp314-cp314-win_amd64.whl
Size 5.8 MB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
9aaf3a7bcd667f9a6642d20d0325baacc96d16b8f8bfb6811bcbc63ebd763163
BLAKE2b-256 checksum
How to use checksums
286be41f7be36962c6402885cb0b65c9b5320c4566c28c22d8ad9400727ad92f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Oct 4, 2026.

Transparency log

Release files / pylon_db-0.4.0-cp314-cp314-manylinux_2_28_x86_64.whl

Download URL pylon_db-0.4.0-cp314-cp314-manylinux_2_28_x86_64.whl
Size 6.5 MB
Tags CPython 3.14 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
4cbb2702cf2c450157023b587cdb624b1f81ba9e65d039286926e4c19ecc45b3
BLAKE2b-256 checksum
How to use checksums
0ca776ad8b430c541c621e0162426c80f9773b21af2b420900cd1304a7f345e5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Oct 4, 2026.

Transparency log

Release files / pylon_db-0.4.0-cp314-cp314-manylinux_2_28_aarch64.whl

Download URL pylon_db-0.4.0-cp314-cp314-manylinux_2_28_aarch64.whl
Size 6.6 MB
Tags CPython 3.14 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
68326391172d27a36baef436fa027d2b7543d3fa8aeeb81d1fa28831eba01fb0
BLAKE2b-256 checksum
How to use checksums
92114b0e4e7d696bb9a1e06e8a59e59df7dc7667be23a4a0926903d768638ba2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Oct 4, 2026.

Transparency log

Release files / pylon_db-0.4.0-cp314-cp314-macosx_11_0_arm64.whl

Download URL pylon_db-0.4.0-cp314-cp314-macosx_11_0_arm64.whl
Size 6.0 MB
Tags CPython 3.14 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
97c86165d5b23777423dca4547d232076c38b10e7a805ebea54cd73da9c1d3e6
BLAKE2b-256 checksum
How to use checksums
054ab9523bad4586f5a5d58be61ea080d1ef3d959d5605a4edb4089d2820744e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Oct 4, 2026.

Transparency log

Release files / pylon_db-0.4.0-cp313-cp313-win_amd64.whl

Download URL pylon_db-0.4.0-cp313-cp313-win_amd64.whl
Size 5.9 MB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
91304239c2f4619cca751c37ad16e98dc2dac4e986f0ca5e2b3e3eb2e0a3a80e
BLAKE2b-256 checksum
How to use checksums
5dbdfdfee6d308a3482ac3deb7baebb6da17fb9f65b75f4f5e2c019ffe289d5f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Oct 4, 2026.

Transparency log

Release files / pylon_db-0.4.0-cp313-cp313-manylinux_2_28_x86_64.whl

Download URL pylon_db-0.4.0-cp313-cp313-manylinux_2_28_x86_64.whl
Size 6.5 MB
Tags CPython 3.13 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
436ea28440504eda8df44d0da04296615713d13ecbb6cc664857a082efdc6f56
BLAKE2b-256 checksum
How to use checksums
4c8a9e8f6af608fb7577f4662a00dd5fb1591e9f8d279383f8b026792c1aad50
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Oct 4, 2026.

Transparency log

Release files / pylon_db-0.4.0-cp313-cp313-manylinux_2_28_aarch64.whl

Download URL pylon_db-0.4.0-cp313-cp313-manylinux_2_28_aarch64.whl
Size 6.6 MB
Tags CPython 3.13 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
0c450224e218aa8385ad0a4635fcf24ee72927d97272b9e6337e16382042390a
BLAKE2b-256 checksum
How to use checksums
ec052521ca407cd4a12e056f88f1caee23b34cea8858b1fbaf399663eeea7b6f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Oct 4, 2026.

Transparency log

Release files / pylon_db-0.4.0-cp313-cp313-macosx_11_0_arm64.whl

Download URL pylon_db-0.4.0-cp313-cp313-macosx_11_0_arm64.whl
Size 6.0 MB
Tags CPython 3.13 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
8af7b1e8747bc79ce391d26068f86f4a4007eaf777dd5ae83662d4cc54c17f52
BLAKE2b-256 checksum
How to use checksums
1684296184d80bf0eccb1e333a622b31e20906a031b7e4a1db5ede4e1eb2b666
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Oct 4, 2026.

Transparency log

Release history Release notifications | RSS feed

0.7.0

13 release files

0.6.0

13 release files

0.5.0

9 release files

This release

0.4.0 This release

9 release files

0.3.0

9 release files

0.2.0

9 release files

0.1.0

9 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page