MuninnDB-backed memory provider plugin for Hermes Agent
Project description
MuninnDB memory provider for Hermes Agent
Bottom line:
- This is a standalone Hermes memory-provider plugin backed by MuninnDB.
- It uses MuninnDB's MCP endpoint for recall, explicit writes, and health/status checks.
- It adds deliberate memory tools plus automatic recall/capture hooks.
Quick install for Hermes users
- PyPI project: https://pypi.org/project/hermes-muninndb-plugin/
- Working install path today is the plugin directory layout Hermes expects, not just
site-packages. - Fastest working install:
git clone https://github.com/aditzel/hermes-muninndb-plugin.git ~/.hermes/plugins/muninndb
git -C ~/.hermes/plugins/muninndb checkout <release-tag> # for example: v0.2.1
mkdir -p ~/.hermes/hermes-agent/plugins/memory
ln -sfn ~/.hermes/plugins/muninndb ~/.hermes/hermes-agent/plugins/memory/muninndb
hermes config set memory.provider muninndb
hermes memory setup
- Updating an existing install:
git -C ~/.hermes/plugins/muninndb fetch --tags
git -C ~/.hermes/plugins/muninndb checkout <release-tag> # or: git -C ~/.hermes/plugins/muninndb pull --ff-only
hermes config set memory.provider muninndb
pip install hermes-muninndb-pluginpublishes the Python package successfully, but Hermes still needs the plugin files in~/.hermes/plugins/muninndbuntil external memory-provider discovery is fully landed upstream.
What it does
- Automatic recall before turns via
muninn_recall - Durable SQLite write-behind turn capture via
muninn_remember - Replays pending writes after crashes or restarts
- Mirrors built-in Hermes memory writes into MuninnDB
- Reuses the existing Muninn MCP server config from
config.yamlwhen available, including its bearer token - Exposes namespaced tools to the model:
muninndb_recallmuninndb_remembermuninndb_forgetmuninndb_entitymuninndb_status
- Adds CLI helpers:
hermes muninndb statushermes muninndb ping
Files
__init__.py— Hermes plugin entrypoint wrappercli.py— Hermes CLI wrappersrc/hermes_muninndb_plugin/__init__.py— actual provider implementationsrc/hermes_muninndb_plugin/cli.py— actual CLI implementationplugin.yaml— Hermes plugin manifestpyproject.toml— packaging and test metadata.github/workflows/ci.yml— CI for tests/buildtests/test_muninndb_plugin.py— unit tests
Installation
- Put the plugin where Hermes can discover it.
Preferred layout when your Hermes version supports user-installed memory providers:
mkdir -p ~/.hermes/plugins/muninndb
rsync -a --delete /path/to/hermes-muninndb-plugin/ ~/.hermes/plugins/muninndb/
If your Hermes build still only scans bundled plugins/memory/ directories, symlink it into the Hermes source tree instead:
ln -s /path/to/hermes-muninndb-plugin ~/.hermes/hermes-agent/plugins/memory/muninndb
- Configure Hermes to use the provider.
hermes config set memory.provider muninndb
hermes memory setup
- Or write the config directly.
$HERMES_HOME/muninndb.json
{
"endpoint": "http://127.0.0.1:8750/mcp",
"vault": "default",
"auto_recall": true,
"auto_capture": true,
"mirror_builtin_memory": true,
"capture_assistant_turns": true,
"recall_mode": "balanced",
"recall_limit": 6,
"recall_threshold": 0.45,
"timeout": 10.0,
"flush_timeout": 5.0,
"max_turn_chars": 4000
}
Optional secret in $HERMES_HOME/.env:
MUNINN_MCP_TOKEN=your-token-here
You can also avoid duplicating the token entirely if Hermes already has a Muninn MCP server configured in config.yaml; the plugin will reuse that Authorization: Bearer ... header automatically.
You can also override config with env vars:
MUNINN_MCP_URLMUNINN_ENDPOINTMUNINN_MCP_TOKENMUNINN_VAULT
Behaviour mapping
Hermes lifecycle -> MuninnDB action
prefetch(query)->muninn_recallqueue_prefetch(query)-> backgroundmuninn_recallsync_turn(user, assistant)-> backgroundmuninn_rememberon_memory_write(add|replace, target, content)-> backgroundmuninn_rememberon_session_end(messages)-> drain queued writes
Tool behaviour
muninndb_recall
- Purpose: deliberate recall when automatic injection is not enough
- Input:
query, optionallimit,mode,threshold - Backend call:
muninn_recall
muninndb_remember
- Purpose: explicit durable write
- Input:
content, optionalconcept,type,summary,confidence,tags - Backend call:
muninn_remember
muninndb_forget
- Purpose: explicit cleanup/delete by memory id
- Input:
id - Backend call:
muninn_forget
muninndb_entity
- Purpose: inspect an entity and its connected memories
- Input:
name, optionallimit - Backend call:
muninn_entity
muninndb_status
- Purpose: health/capacity snapshot
- Backend call:
muninn_status
CLI
hermes muninndb status
hermes muninndb ping
Testing
make test
make smoke
make build
Equivalent direct commands:
python3 -m pytest tests/test_muninndb_plugin.py -q
python3 -m py_compile __init__.py cli.py src/hermes_muninndb_plugin/__init__.py src/hermes_muninndb_plugin/cli.py
python3 -m build
Design notes
- Uses stdlib HTTP (
urllib) rather than third-party dependencies. - Uses a durable SQLite async queue for write-behind persistence and crash recovery.
- Scopes recall and writes with platform, identity, session, and user tags.
- Falls back to the existing Hermes Muninn MCP server config in
config.yamlso one source of truth can supply the token. - For subagents/cron/flush contexts, write-back is disabled; recall still works.
Caveats
- Recall is semantic, so immediate exact-string lookups are not guaranteed to rank first without enough signal. Use
muninndb_entityor Muninn's directmuninn_read/muninn_recalltools when you need forensic precision. - This plugin talks to MuninnDB's MCP endpoint. If you prefer REST for some operations, that is a sensible follow-up, but MCP keeps the surface aligned with Muninn's richest toolset.
- The Hermes IDE plugin registry at
hermes-hq/pluginsis a different plugin system. Useful reference for packaging style, not the runtime contract used here.
Why this shape
- Minimal moving parts
- Good enough defaults
- No dependence on Muninn-specific Python SDKs that may shift underfoot
- Easy to inspect, patch, and extend without ritual sacrifice
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 Distribution
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 hermes_muninndb_plugin-0.2.1.tar.gz.
File metadata
- Download URL: hermes_muninndb_plugin-0.2.1.tar.gz
- Upload date:
- Size: 24.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1390aeff8e3bac89d2ce1ee7b2f2dce21d1ba3d436b7a5f27a3d90f6b6f46f1d
|
|
| MD5 |
706f375f38e3831bfdf5071096fe8fc8
|
|
| BLAKE2b-256 |
a8bbf0701e0cc8d738f97bf342484e45a0b2bd937a602b0b129f550391dfc682
|
Provenance
The following attestation bundles were made for hermes_muninndb_plugin-0.2.1.tar.gz:
Publisher:
publish.yml on aditzel/hermes-muninndb-plugin
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
hermes_muninndb_plugin-0.2.1.tar.gz -
Subject digest:
1390aeff8e3bac89d2ce1ee7b2f2dce21d1ba3d436b7a5f27a3d90f6b6f46f1d - Sigstore transparency entry: 1301947836
- Sigstore integration time:
-
Permalink:
aditzel/hermes-muninndb-plugin@54acdf94dee7484b2617c06ce7d933e62d7a79ce -
Branch / Tag:
refs/tags/v0.2.1 - Owner: https://github.com/aditzel
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@54acdf94dee7484b2617c06ce7d933e62d7a79ce -
Trigger Event:
release
-
Statement type:
File details
Details for the file hermes_muninndb_plugin-0.2.1-py3-none-any.whl.
File metadata
- Download URL: hermes_muninndb_plugin-0.2.1-py3-none-any.whl
- Upload date:
- Size: 17.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cbb99547e67c6c8a189c49b3ba5bff54d8eab142d48626be9d009e5a36c64159
|
|
| MD5 |
ab20eceda9d2f3346348ffbe452f1a8e
|
|
| BLAKE2b-256 |
2d8ad876f45415807bf5ad653576b48743743be37fe8f72e43f990847a3f4dfd
|
Provenance
The following attestation bundles were made for hermes_muninndb_plugin-0.2.1-py3-none-any.whl:
Publisher:
publish.yml on aditzel/hermes-muninndb-plugin
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
hermes_muninndb_plugin-0.2.1-py3-none-any.whl -
Subject digest:
cbb99547e67c6c8a189c49b3ba5bff54d8eab142d48626be9d009e5a36c64159 - Sigstore transparency entry: 1301947949
- Sigstore integration time:
-
Permalink:
aditzel/hermes-muninndb-plugin@54acdf94dee7484b2617c06ce7d933e62d7a79ce -
Branch / Tag:
refs/tags/v0.2.1 - Owner: https://github.com/aditzel
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@54acdf94dee7484b2617c06ce7d933e62d7a79ce -
Trigger Event:
release
-
Statement type: