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), andresource_links to each hitmem_fetch- deterministic listing of a kind (no embedding)mem_edges- typed graph introspectionmem_profile- what the memory knows about a query: recall plus its graph neighborhoodmem_summarize- per-kind digest of a regionmem_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, immutabilitymem_update- replace a stored atom's payload in place (preserves id, edges, and embedding)mem_link- connect atoms with a typed edgemem_evolve- recompute an atom's neighbor links and scoremem_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
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
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
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f4b5a9b5b6044d3b24c601646bb1c4b8ad040398913e0188da66511062164091
|
|
| MD5 |
a1ef2a8b28641500e103795ef6b64004
|
|
| BLAKE2b-256 |
8969718c5057c0a71cdd62dd8c0aa92210f680063469169062a6a181551f0885
|
Provenance
The following attestation bundles were made for citadeldb_mcp-1.11.0.tar.gz:
Publisher:
release-mcp.yml on yp3y5akh0v/citadel
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
citadeldb_mcp-1.11.0.tar.gz -
Subject digest:
f4b5a9b5b6044d3b24c601646bb1c4b8ad040398913e0188da66511062164091 - Sigstore transparency entry: 2061385502
- Sigstore integration time:
-
Permalink:
yp3y5akh0v/citadel@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Branch / Tag:
refs/tags/v1.11.0 - Owner: https://github.com/yp3y5akh0v
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-mcp.yml@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Trigger Event:
push
-
Statement type:
File details
Details for the file citadeldb_mcp-1.11.0-py3-none-win_amd64.whl.
File metadata
- Download URL: citadeldb_mcp-1.11.0-py3-none-win_amd64.whl
- Upload date:
- Size: 7.8 MB
- Tags: Python 3, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5b51f4fd3e8ab6f9f17789f62e9669c87647937eef820cdbf0790da71a6fdf33
|
|
| MD5 |
7525efdcc67472a6da8db18991561416
|
|
| BLAKE2b-256 |
9782cf69a191e6da2d94b2119cf6fc130b9267d08b69f81b4c2bc49437fca507
|
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
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
citadeldb_mcp-1.11.0-py3-none-win_amd64.whl -
Subject digest:
5b51f4fd3e8ab6f9f17789f62e9669c87647937eef820cdbf0790da71a6fdf33 - Sigstore transparency entry: 2061385784
- Sigstore integration time:
-
Permalink:
yp3y5akh0v/citadel@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Branch / Tag:
refs/tags/v1.11.0 - Owner: https://github.com/yp3y5akh0v
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-mcp.yml@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Trigger Event:
push
-
Statement type:
File details
Details for the file citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 7.5 MB
- Tags: Python 3, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dcf7d1e5147ca8e6fafa8fea6f1539764314f34242915b671a60eabe3e258255
|
|
| MD5 |
82b12e6cdbd0d13dcca38830d80abcc2
|
|
| BLAKE2b-256 |
310d7368c7bcbe797c6977c1be0d2511a60a1d0ca8922a8dfc323d6dbd7bc674
|
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
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl -
Subject digest:
dcf7d1e5147ca8e6fafa8fea6f1539764314f34242915b671a60eabe3e258255 - Sigstore transparency entry: 2061386381
- Sigstore integration time:
-
Permalink:
yp3y5akh0v/citadel@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Branch / Tag:
refs/tags/v1.11.0 - Owner: https://github.com/yp3y5akh0v
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-mcp.yml@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Trigger Event:
push
-
Statement type:
File details
Details for the file citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.
File metadata
- Download URL: citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
- Upload date:
- Size: 7.0 MB
- Tags: Python 3, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
86633bacc81ed74d8536cb6b2e3ec81a2361318751a6b5eaf187a81b8fd6acc3
|
|
| MD5 |
4a21bace775c01b071b8063530fde6ee
|
|
| BLAKE2b-256 |
fd4b830bc702ef6ca5141ed4e48c4b15fd3080254b441d1cf1c4a7acc58d5dd6
|
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
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
citadeldb_mcp-1.11.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl -
Subject digest:
86633bacc81ed74d8536cb6b2e3ec81a2361318751a6b5eaf187a81b8fd6acc3 - Sigstore transparency entry: 2061386024
- Sigstore integration time:
-
Permalink:
yp3y5akh0v/citadel@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Branch / Tag:
refs/tags/v1.11.0 - Owner: https://github.com/yp3y5akh0v
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-mcp.yml@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Trigger Event:
push
-
Statement type:
File details
Details for the file citadeldb_mcp-1.11.0-py3-none-macosx_11_0_arm64.whl.
File metadata
- Download URL: citadeldb_mcp-1.11.0-py3-none-macosx_11_0_arm64.whl
- Upload date:
- Size: 6.7 MB
- Tags: Python 3, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5c1121c2d1649b1959af70aecbe89433f255bfce71f870c9467145ceaeb53520
|
|
| MD5 |
f462b4da14ccc5ef14519781b944f45b
|
|
| BLAKE2b-256 |
37fdbf3cb12a36c3d2626dafe8b48b9b81c6d9d32d25ef10f0f4247f67367e53
|
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
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
citadeldb_mcp-1.11.0-py3-none-macosx_11_0_arm64.whl -
Subject digest:
5c1121c2d1649b1959af70aecbe89433f255bfce71f870c9467145ceaeb53520 - Sigstore transparency entry: 2061386548
- Sigstore integration time:
-
Permalink:
yp3y5akh0v/citadel@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Branch / Tag:
refs/tags/v1.11.0 - Owner: https://github.com/yp3y5akh0v
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-mcp.yml@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Trigger Event:
push
-
Statement type:
File details
Details for the file citadeldb_mcp-1.11.0-py3-none-macosx_10_12_x86_64.whl.
File metadata
- Download URL: citadeldb_mcp-1.11.0-py3-none-macosx_10_12_x86_64.whl
- Upload date:
- Size: 7.3 MB
- Tags: Python 3, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fed22750cc881af9fc3f32852cf19df85b6b5305557f2d3236d4fe7f0c956860
|
|
| MD5 |
b626c5711ecb828406932187bcdbae41
|
|
| BLAKE2b-256 |
4f996ada4aa7b66e51c2c82ba1c055417ea8b72a915e42215d027c3e6731d9e9
|
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
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
citadeldb_mcp-1.11.0-py3-none-macosx_10_12_x86_64.whl -
Subject digest:
fed22750cc881af9fc3f32852cf19df85b6b5305557f2d3236d4fe7f0c956860 - Sigstore transparency entry: 2061386677
- Sigstore integration time:
-
Permalink:
yp3y5akh0v/citadel@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Branch / Tag:
refs/tags/v1.11.0 - Owner: https://github.com/yp3y5akh0v
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-mcp.yml@550a65edf8d7bfe5bb5b6d7eb4b795b9ae1a943b -
Trigger Event:
push
-
Statement type: