Skip to main content

citadeldb-llamaindex

A LlamaIndex vector store backed by Citadel. Encrypted at rest, embedded in your process, and deletes that destroy the key, not just the row.

pip install citadeldb-llamaindex
from llama_index.core import Document, StorageContext, VectorStoreIndex
from citadeldb_llamaindex import CitadelVectorStore

store = CitadelVectorStore("corpus.cdl", key="your-passphrase", dim=1536)
documents = [Document(text="the deployment failed because the disk was full")]

index = VectorStoreIndex.from_documents(
    documents,
    storage_context=StorageContext.from_defaults(vector_store=store),
)

index.as_query_engine().query("why did the release break?")

dim must match your embedding model: 1536 for OpenAI text-embedding-3-small, 3072 for text-embedding-3-large, 1024 for e5-large.

Deletes destroy the key

Every node is sealed under its own key. Deleting destroys that key and then removes the row, so any ciphertext surviving elsewhere stays unreadable.

index.delete_ref_doc("doc-42")          # every node from that document
store.forget_document("doc-42")         # the same, returning a count for the record
store.clear()                           # the whole corpus

The node's key is gone, not just its entry in an index.

Filters

Filtering matches LlamaIndex's own evaluator, and similarity_top_k is honoured: a filter matching only distant nodes still returns them, however many others outrank them. The same holds for node_ids and doc_ids, which name nodes exactly.

String equality under a top-level AND is pushed into the scan so it narrows candidates before top-k. Everything else is evaluated afterwards, so the two agree: numbers are not pushed, because EQ here is Python's == (1 == 1.0) where the stored comparison is JSON-type exact.

from llama_index.core.vector_stores.types import (
    FilterOperator, MetadataFilter, MetadataFilters,
)

index.as_retriever(
    filters=MetadataFilters(filters=[
        MetadataFilter(key="year", value=2026, operator=FilterOperator.EQ),
    ])
).retrieve("...")

Filter semantics come from LlamaIndex's own evaluator, so every operator behaves exactly as it does with the reference store. Under OR or NOT nothing is pushed, because a pushed leaf would drop rows the filter keeps.

Notes

LlamaIndex embeds before it calls a store, so a node arrives with its vector already computed and that vector is written straight onto the atom. Nothing here re-embeds, so writes and queries stay in one vector space.

The node is stored whole, minus its text, which is kept once as the atom's searchable content and restored on read. Metadata, relationships and node type all round-trip.

Citadel is embedded and one process owns the file. A path already open on this thread, under the same passphrase, is shared, so this can sit on the same database as another Citadel adapter; construct them on the same thread.

License

Apache-2.0

Download files

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

Source Distribution

citadeldb_llamaindex-2.0.0.tar.gz (11.2 kB view details)

Uploaded Source

Built Distribution

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

citadeldb_llamaindex-2.0.0-py3-none-any.whl (7.4 kB view details)

Uploaded Python 3

File details

Details for the file citadeldb_llamaindex-2.0.0.tar.gz.

File metadata

  • Download URL: citadeldb_llamaindex-2.0.0.tar.gz
  • Upload date:
  • Size: 11.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for citadeldb_llamaindex-2.0.0.tar.gz
Algorithm Hash digest
SHA256 59d603cbda1944cab2c99d14e6f46fa7cd4999d31914428214940fb4c12585d0
MD5 adac3943be8f5458c957961f54b1011b
BLAKE2b-256 c15f926701c6f1efd159a311916ed90d5181e8dd8e5a72ee833da5b890b86b2a

See more details on using hashes here.

Provenance

The following attestation bundles were made for citadeldb_llamaindex-2.0.0.tar.gz:

Publisher: release-llamaindex.yml on yp3y5akh0v/citadel

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

File details

Details for the file citadeldb_llamaindex-2.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for citadeldb_llamaindex-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 82e9a1a0ccc99598ee7bc24c55489fa26386531ef60d7dcce2c00c7206b1ff0a
MD5 d40cee4ff0ce7d90f0a39446d0a99e35
BLAKE2b-256 8a141c418da4d661141add8ee4f8e09d2edccbc394c58c0fe0c956dfa68ac019

See more details on using hashes here.

Provenance

The following attestation bundles were made for citadeldb_llamaindex-2.0.0-py3-none-any.whl:

Publisher: release-llamaindex.yml on yp3y5akh0v/citadel

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

Release history Release notifications | RSS feed

This release

2.0.0 This release

2 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