Skip to main content

citadeldb-mcp

mcp-name: dev.citadeldb/mcp

Model Context Protocol (MCP) server for the Citadel encrypted memory engine. Gives any MCP client (Claude Desktop, an IDE, an agent) persistent, encrypted memory.

Memory lives in a local citadeldb-mem region: AES-256 encrypted at rest, per-atom sealed and HMAC-authenticated, recalled through a hybrid vector + keyword + recency + importance fusion over a PRISM approximate nearest-neighbor index, connected by a typed edge graph, and forgotten by destroying keys (cryptographic erasure).

Install

Run it with no install. For semantic recall, pull the recommended embedder and cross-encoder reranker once, then enable both:

uvx citadeldb-mcp pull e5-large
uvx citadeldb-mcp pull ms-marco-minilm

The pull commands do not open a vault. Before serving, set CITADEL_KEY to the vault passphrase (export CITADEL_KEY="your-passphrase" on macOS/Linux or $env:CITADEL_KEY = "your-passphrase" in PowerShell), then run:

uvx citadeldb-mcp --db memory.cdl --embedder e5-large --reranker ms-marco-minilm

e5-large + ms-marco-minilm is the recommended semantic-recall setup. See the memory benchmarks for measured configurations. Models are never downloaded automatically.

Built-in pulls use release-pinned Hugging Face revisions. Each complete snapshot is verified against compiled sizes and SHA-256 digests, then stored with a BLAKE3 manifest under <models-dir>/<name>/<revision>/. A flat cache created by an earlier CitadelDB release is not trusted; run pull again to create the pinned snapshot. --model-dir and --reranker-dir remain explicit bring-your-own-artifact paths and bypass the managed-cache manifest. Citadel treats those directories as user-trusted and does not attest their contents.

Or install the command with pip install citadeldb-mcp or cargo install citadeldb-mcp, then wire it into Claude Desktop (claude_desktop_config.json):

{
  "mcpServers": {
    "citadel": {
      "command": "citadeldb-mcp",
      "args": ["--db", "/absolute/path/to/memory.cdl", "--embedder", "e5-large", "--reranker", "ms-marco-minilm"],
      "env": { "CITADEL_KEY": "your-passphrase" }
    }
  }
}

The server supports stateless MCP 2026-07-28 discovery and per-request metadata, plus the initialize-based 2025-11-25 and 2025-06-18 revisions for existing clients.

Tools (over a bounded, cancellable JSON-RPC 2.0 stdio transport):

  • mem_recall - hybrid retrieval (vector + keyword + recency + importance); filter by kind/payload, expand along the memory graph, override fusion weights, and optionally attach provenance (derived_from), per-hit integrity verdicts (attest), and resource_links to each hit
  • mem_fetch - deterministic cursor-based listing of a kind (no embedding)
  • mem_get - bounded exact-id batch retrieval in request order, with missing atoms marked explicitly
  • mem_edges - cursor-based typed graph introspection
  • mem_profile - what the memory knows about a query: recall plus its graph neighborhood
  • mem_summarize - per-kind digest of a region
  • mem_verify - re-authenticate atoms off disk: per-atom integrity verdict (authentic / tampered / key_erased / missing / plaintext_unattested)
  • mem_remember - store one atom with optional provenance and retry-safe idempotency
  • mem_remember_batch - atomically store an ordered batch; every entry carries a distinct idempotency key, and a changed reuse rejects the whole batch
  • mem_update - replace a stored atom's payload in place (preserves id, edges, and embedding)
  • mem_link / mem_unlink - add or remove one exact typed edge
  • mem_evolve - recompute an atom's neighbor links and stored importance
  • mem_evict - selective forgetting by policy (cryptographic erasure on encrypted regions)
  • mem_forget - forget atoms by id and return a verifiable erasure receipt; optionally erase their region-local derived_from closure atomically (cryptographic erasure on encrypted regions; immutable atoms require the protected-erasure opt-in)

The citadeldb-mcp binary reads the passphrase from CITADEL_KEY and serves one region (encrypted by default); only protocol messages go to stdout, diagnostics to stderr. --region-mode plaintext disables per-atom encryption and cryptographic erasure for that region; the database remains encrypted at rest. Erasure does not revoke plaintext exports or keys retained in pre-erasure backups or snapshots.

Every server invocation must select an embedder. The KodamaEmbed embedder and reranker are compiled into the standalone server's default build, the citadeldb-mcp Python package and the citadeldb library wheel. Models are fetched only on explicit pull.

Embedder pull names: e5-large (recommended), e5-large-v2, bge-small, bge-base, bge-large, minilm. Reranker: ms-marco-minilm. Or point --model-dir at a compatible local checkpoint for the selected catalog pipeline.

Models run on the processor unless --device names another device. --device auto takes an NVIDIA GPU of compute capability 8.0 or newer through CUDA, else a discrete Vulkan GPU, else the processor. --device cuda[:N] and --device vulkan[:N] name one GPU and fail when it cannot load the model. The server reports each model's device on stderr.

--precision quantized runs the INT8 preset of e5-large, with the same vectors on the processor and on CUDA. A region keeps the precision it was embedded with; switching requires reembed_region. KodamaEmbed's precision selection lists the preset's hardware requirements and calibration cache.

This crate is part of the Citadel workspace.

License

Apache-2.0

Metadata

Release files for citadeldb-mcp 3.0.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 citadeldb-mcp 3.0.0
File Size Uploaded Provenance Actions
citadeldb_mcp-3.0.0.tar.gz 2.3 MB With provenance Details for citadeldb_mcp-3.0.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for citadeldb-mcp 3.0.0
File Actions
citadeldb_mcp-3.0.0-py3-none-win_amd64.whl Python 3 none Windows x86-64 Details for citadeldb_mcp-3.0.0-py3-none-win_amd64.whl
citadeldb_mcp-3.0.0-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl Python 3 none Linux glibc 2.17+ x86-64 Details for citadeldb_mcp-3.0.0-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
citadeldb_mcp-3.0.0-py3-none-manylinux2014_aarch64.manylinux_2_17_aarch64.whl Python 3 none Linux glibc 2.17+ ARM64 Details for citadeldb_mcp-3.0.0-py3-none-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
citadeldb_mcp-3.0.0-py3-none-macosx_11_0_arm64.whl Python 3 none macOS 11.0+ ARM64 Details for citadeldb_mcp-3.0.0-py3-none-macosx_11_0_arm64.whl
citadeldb_mcp-3.0.0-py3-none-macosx_10_12_x86_64.whl Python 3 none macOS 10.12+ x86-64 Details for citadeldb_mcp-3.0.0-py3-none-macosx_10_12_x86_64.whl

Total release size: 58.7 MB

Release files / citadeldb_mcp-3.0.0.tar.gz

Download URL citadeldb_mcp-3.0.0.tar.gz
Size 2.3 MB
Tags Source
SHA-256 checksum
How to use checksums
38420fbd9231ed75e12b736a5b0e0482620d98bd53900ce8d6dd8d639cc73c3c
BLAKE2b-256 checksum
How to use checksums
cbc43fec030d1ab3442c0642fff7d3dfbb844ebd72e369f52180bdc345b1e6b0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 28, 2026.

Transparency log

Release files / citadeldb_mcp-3.0.0-py3-none-win_amd64.whl

Download URL citadeldb_mcp-3.0.0-py3-none-win_amd64.whl
Size 12.6 MB
Tags Python 3 Windows x86-64
SHA-256 checksum
How to use checksums
8dbb3b74ec6dcfe51376f597edfc1f2dde83e00029d85523374417df65e88295
BLAKE2b-256 checksum
How to use checksums
fbe9fa2b32ca2a7ee294a818352c7fabfc0688b1a6cb422b9ae2213c29b7dc1f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 28, 2026.

Transparency log

Release files / citadeldb_mcp-3.0.0-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL citadeldb_mcp-3.0.0-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 12.1 MB
Tags Linux glibc 2.17+ x86-64 Python 3
SHA-256 checksum
How to use checksums
4a0a8c4a878083dc54fca32d6c7624d99f0614bff757b5cebb071023df086dfa
BLAKE2b-256 checksum
How to use checksums
06f1ed0298e48f734a1e434052267c31d0de0c74eaa985ad8278937bd82a885b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 28, 2026.

Transparency log

Release files / citadeldb_mcp-3.0.0-py3-none-manylinux2014_aarch64.manylinux_2_17_aarch64.whl

Download URL citadeldb_mcp-3.0.0-py3-none-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
Size 10.0 MB
Tags Linux glibc 2.17+ ARM64 Python 3
SHA-256 checksum
How to use checksums
3001c9139cc4a00f5fe6bdfc0ecb273c7493c7b010488627fc49363dbebc7577
BLAKE2b-256 checksum
How to use checksums
65654baf2056da97680525c01a7b9ea676571e8b27f684a9c50dad038a3e7484
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 28, 2026.

Transparency log

Release files / citadeldb_mcp-3.0.0-py3-none-macosx_11_0_arm64.whl

Download URL citadeldb_mcp-3.0.0-py3-none-macosx_11_0_arm64.whl
Size 9.8 MB
Tags Python 3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
111909648fa6c7c802a9416c19de28d2dce678fe1c54960754eb136cfe255be9
BLAKE2b-256 checksum
How to use checksums
dacbbb8e52e00df47279ab4c21e3315f92d2f3842b265b37037499f257458e20
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 28, 2026.

Transparency log

Release files / citadeldb_mcp-3.0.0-py3-none-macosx_10_12_x86_64.whl

Download URL citadeldb_mcp-3.0.0-py3-none-macosx_10_12_x86_64.whl
Size 12.0 MB
Tags Python 3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
9306cdf46a74f683a86b74d17954c2d5bfea145ca6524667fc539330ca87632e
BLAKE2b-256 checksum
How to use checksums
7a8705690a84a259a82a16d3266ed981825f40330c830702000268ca20e6253a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 28, 2026.

Transparency log

Security for citadeldb-mcp 3.0.0

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.

Full provenance

All 6 files in this release have been uploaded with provenance metadata.

Select from 6 files

Attestation for citadeldb_mcp-3.0.0.tar.gz

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 Nov 28, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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