Skip to main content

piramid

Python client for Piramid, an inference engine for retrieval systems.

pip install piramid
from piramid import Piramid

with Piramid("http://127.0.0.1:6333") as db:   # key from api_key= or PIRAMID_API_KEY
    db.embed("docs", ["Compaction rewrites the record store without deleted documents."])

    answer = db.generate(
        messages=[{"role": "user", "content": "What happens to deleted documents?"}],
        collection="docs",
        k=2,
    )
    print(answer["text"], answer["retrieval"]["passages"])

    for event in db.stream(prompt="Piramid is", max_new_tokens=32):
        if event["event"] == "token":
            print(event["data"]["text"], end="")

Collections: collections, create_collection, collection, delete_collection, count, compact. Documents: embed, insert, upsert, get, list, delete. Search: search (by vectors), search_text (embedded by the server), both with a metadata filter such as {"topic": {"eq": "storage"}}. Server: health, version, model.

A refused request raises PiramidError with the server's message and HTTP status. /v1/chat/completions is OpenAI-compatible, so the openai package works against it directly.

Server docs: https://piramiddb.com/docs. MIT licensed.

Metadata

Release files for piramid 0.2.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 piramid 0.2.0
File Size Uploaded
piramid-0.2.0.tar.gz 7.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for piramid 0.2.0
File Interpreter ABI Platform
piramid-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 14.7 kB

Release files / piramid-0.2.0.tar.gz

Download URL piramid-0.2.0.tar.gz
Size 7.3 kB
Tags Source
SHA-256 checksum
How to use checksums
2998bf5e692ed4aa01cae9df580aae48498251ac3ccb9530147ddbb608e5e3b9
BLAKE2b-256 checksum
How to use checksums
496255504c781c0f65341457d2114c2cf520ede9bd75e170254dd6703d632d82
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 / piramid-0.2.0-py3-none-any.whl

Download URL piramid-0.2.0-py3-none-any.whl
Size 7.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
50d4cf4a21ca413e7478c37b9f706e928c42e8864f430bc3d59eb06c7f47da6e
BLAKE2b-256 checksum
How to use checksums
1c73faecbe19b86301760a3c6dcc7d4f6c127e340339b54586ea3180466e2283
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

This release

0.2.0 This release

2 release files

0.1.0

2 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