Skip to main content

Model Context Protocol server for Citadel: encrypted memory as MCP tools

Project description

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:

uvx citadeldb-mcp --db memory.cdl

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", "memory.cdl", "--embedder", "bge-large"],
      "env": { "CITADEL_KEY": "your-passphrase" }
    }
  }
}

Omit --embedder for keyword-only recall, or run citadeldb-mcp pull bge-large first for semantic recall (models are never downloaded automatically; see below).

Tools (over a synchronous, hand-rolled 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 listing of a kind (no embedding)
  • mem_edges - 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 / mem_remember_batch - store atoms with payload, importance, TTL, immutability
  • mem_update - replace a stored atom's payload in place (preserves id, edges, and embedding)
  • mem_link - connect atoms with a typed edge
  • mem_evolve - recompute an atom's neighbor links and score
  • mem_evict - selective forgetting by policy (cryptographic erasure on encrypted regions)
  • mem_forget - forget atoms by id and return a verifiable erasure receipt (cryptographic erasure on encrypted regions; skips immutable atoms unless forced)

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.

Recall is keyword-only (a mock embedder) until you opt into a real semantic model. The (CPU) Candle embedder is compiled into the default build, but models are fetched only on explicit request, never automatically:

citadeldb-mcp pull bge-large                       # one-time download to ~/.citadel/models
citadeldb-mcp --db memory.cdl --embedder bge-large

Pull names: bge-small, bge-base, bge-large, minilm, e5-large. Or point --model-dir at a local model directory for a fully offline setup, and build with --features cuda-embed to run the model on an NVIDIA GPU.

For better recall ordering, add a cross-encoder reranker (off by default, also explicit):

citadeldb-mcp pull ms-marco-minilm
citadeldb-mcp --db memory.cdl --embedder bge-large --reranker ms-marco-minilm

This crate is part of the Citadel workspace.

License

MIT OR Apache-2.0

Project details


Download files

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

Source Distribution

citadeldb_mcp-1.11.0.tar.gz (1.1 MB view details)

Uploaded Source

Built Distributions

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

citadeldb_mcp-1.11.0-py3-none-win_amd64.whl (7.8 MB view details)

Uploaded Python 3Windows x86-64

citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (7.5 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64

citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (7.0 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARM64

citadeldb_mcp-1.11.0-py3-none-macosx_11_0_arm64.whl (6.7 MB view details)

Uploaded Python 3macOS 11.0+ ARM64

citadeldb_mcp-1.11.0-py3-none-macosx_10_12_x86_64.whl (7.3 MB view details)

Uploaded Python 3macOS 10.12+ x86-64

File details

Details for the file citadeldb_mcp-1.11.0.tar.gz.

File metadata

  • Download URL: citadeldb_mcp-1.11.0.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for citadeldb_mcp-1.11.0.tar.gz
Algorithm Hash digest
SHA256 f4b5a9b5b6044d3b24c601646bb1c4b8ad040398913e0188da66511062164091
MD5 a1ef2a8b28641500e103795ef6b64004
BLAKE2b-256 8969718c5057c0a71cdd62dd8c0aa92210f680063469169062a6a181551f0885

See more details on using hashes here.

Provenance

The following attestation bundles were made for citadeldb_mcp-1.11.0.tar.gz:

Publisher: release-mcp.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_mcp-1.11.0-py3-none-win_amd64.whl.

File metadata

File hashes

Hashes for citadeldb_mcp-1.11.0-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 5b51f4fd3e8ab6f9f17789f62e9669c87647937eef820cdbf0790da71a6fdf33
MD5 7525efdcc67472a6da8db18991561416
BLAKE2b-256 9782cf69a191e6da2d94b2119cf6fc130b9267d08b69f81b4c2bc49437fca507

See more details on using hashes here.

Provenance

The following attestation bundles were made for citadeldb_mcp-1.11.0-py3-none-win_amd64.whl:

Publisher: release-mcp.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_mcp-1.11.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 dcf7d1e5147ca8e6fafa8fea6f1539764314f34242915b671a60eabe3e258255
MD5 82b12e6cdbd0d13dcca38830d80abcc2
BLAKE2b-256 310d7368c7bcbe797c6977c1be0d2511a60a1d0ca8922a8dfc323d6dbd7bc674

See more details on using hashes here.

Provenance

The following attestation bundles were made for citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release-mcp.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_mcp-1.11.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 86633bacc81ed74d8536cb6b2e3ec81a2361318751a6b5eaf187a81b8fd6acc3
MD5 4a21bace775c01b071b8063530fde6ee
BLAKE2b-256 fd4b830bc702ef6ca5141ed4e48c4b15fd3080254b441d1cf1c4a7acc58d5dd6

See more details on using hashes here.

Provenance

The following attestation bundles were made for citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: release-mcp.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_mcp-1.11.0-py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for citadeldb_mcp-1.11.0-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 5c1121c2d1649b1959af70aecbe89433f255bfce71f870c9467145ceaeb53520
MD5 f462b4da14ccc5ef14519781b944f45b
BLAKE2b-256 37fdbf3cb12a36c3d2626dafe8b48b9b81c6d9d32d25ef10f0f4247f67367e53

See more details on using hashes here.

Provenance

The following attestation bundles were made for citadeldb_mcp-1.11.0-py3-none-macosx_11_0_arm64.whl:

Publisher: release-mcp.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_mcp-1.11.0-py3-none-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for citadeldb_mcp-1.11.0-py3-none-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 fed22750cc881af9fc3f32852cf19df85b6b5305557f2d3236d4fe7f0c956860
MD5 b626c5711ecb828406932187bcdbae41
BLAKE2b-256 4f996ada4aa7b66e51c2c82ba1c055417ea8b72a915e42215d027c3e6731d9e9

See more details on using hashes here.

Provenance

The following attestation bundles were made for citadeldb_mcp-1.11.0-py3-none-macosx_10_12_x86_64.whl:

Publisher: release-mcp.yml on yp3y5akh0v/citadel

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

Supported by

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