Covers all upgrade paths: v2.7 → latest, source installs, PyPI installs,
and systems with Python's externally-managed-environment (PEP 668).
If you want the latest (v4.0.0), jump to Upgrading to v4.0.0. It is a major release and contains one breaking change; read that section before upgrading. Already on v3.8.0? See Upgrading to v3.8.0.
Already on v3.0.0? See Upgrading to v3.0.0.
| What changed | User action |
|---|---|
| New PyPI release | pip install --upgrade mnemosyne-memory + restart Hermes |
| Source-only fix | git pull + restart Hermes |
| New dependency / entry point | git pull + pip install -e . + restart Hermes |
externally-managed-environment (Debian/Ubuntu) |
Use a venv or pip install --break-system-packages — see PEP 668 section |
| SQLite schema changed (wondering?) | See How to confirm schema changes |
| E6 TripleStore split (v2.8) | Auto-migrates on first init. Backup at {db}.pre_e6_backup |
| MEMORIA architecture (v3.0) | Auto-creates 5 new tables on first init. No manual action needed |
plugin.yaml / tool schema |
Restart Hermes only |
A major release. Most installations can upgrade without doing anything; one group must set an environment variable first. Full detail in docs/migration-4.0.md.
This release also changes Hermes wrapper install behavior. See Hermes wrapper install safety below.
- Multimodal memory.
BeamMemory.remember_media(ref)registers a piece of media, describes it through a configured provider, and writes the description back as an ordinary memory that hybrid recall already understands. Text recall is unchanged. - MCP Streamable HTTP transport.
mnemosyne mcpgains--transport streamable-http(aliashttp). The MCP extras now requiremcp>=2.0.0; the lockfile previously resolved 1.28.1. If your environment pins the MCP SDK transitively, relax amcp<2constraint or move to 2.0.0 or newer before upgrading. - Unknown embedding models now fail loud instead of silently resolving to 384 dimensions. This is the breaking change.
Only if both of these are true: you point MNEMOSYNE_EMBEDDING_API_URL at
a custom endpoint, and your model is not in the built-in model table and you
have not set MNEMOSYNE_EMBEDDING_DIM.
If that is you, startup now exits at import with an actionable error. Set the dimension your model actually produces:
mnemosyne config set embedding_dim 1024 # your model's real dimensionIf your store was created under the old silent-384 fallback, setting the true dimension will trip the existing dimension-mismatch guard. That guard is not a corruption report; your memories are intact and recall falls back to keyword search until the index is rebuilt. Either keep the existing vectors by running with the dimension already in the database, or re-embed:
MNEMOSYNE_EMBEDDING_DIM=<N> mnemosyne reindex # backs up first
mnemosyne doctor # confirm embeddings_dimEveryone else: no action. Default model users, anyone already setting
MNEMOSYNE_EMBEDDING_DIM, and embeddings-disabled installs are unaffected.
All multimodal, all opt-in, all defaulting to off or empty. Nothing dials out
until modality_enabled is true.
| Variable | Default | Purpose |
|---|---|---|
MNEMOSYNE_MODALITY_ENABLED |
false |
Master switch |
MNEMOSYNE_MODALITY_BASE_URL |
(unset) | OpenAI-compatible endpoint |
MNEMOSYNE_MODALITY_API_KEY |
(unset) | Bearer token |
MNEMOSYNE_MODALITY_VISION_MODEL |
(unset) | Images and documents |
MNEMOSYNE_MODALITY_VIDEO_MODEL |
(unset) | Video |
MNEMOSYNE_MODALITY_AUDIO_MODEL |
(unset) | Audio |
MNEMOSYNE_MODALITY_TIMEOUT |
60 |
Per-call timeout, seconds |
Setting these as environment variables may not work. config.yaml takes
precedence over the environment, and presence in the file decides it rather
than the value. A config seeded on first run already contains these keys, so
an export afterwards is ignored. Use mnemosyne config set modality_enabled true and the matching modality_* keys, or mnemosyne config migrate to
import your current variables.
Two new tables, media_assets and media_moments, created IF NOT EXISTS
when a bank is opened. No migration step, no existing table altered, no action
required. Databases that never use multimodal simply carry two empty tables.
pip install 'mnemosyne-memory==3.15.1'The new tables are additive and are ignored by older versions, so no schema
rollback is needed. If you set MNEMOSYNE_EMBEDDING_DIM to satisfy the new
guard, leaving it set is harmless on the older version.
A persistent wrapper (the Docker/read-only deployment path) must select a side
venv with the same Python major/minor as the Hermes gateway. Do not use an
unqualified python3: a wrapper whose selected venv has mismatched or
unreadable version metadata now fails loudly during gateway activation, before
that venv is added to sys.path.
For a launcher-based Hermes installation, derive the gateway interpreter from
the resolved hermes launcher before creating or selecting a side venv. This
bounded launcher-sibling probe covers only that installation shape: it checks
the launcher's sibling python, then python3. It is not a reproduction of
the installer's broader internal discovery. If it cannot find a sibling,
stop and determine the real gateway interpreter from the deployment; do not
substitute the current-shell Python or guess another environment.
HERMES_BIN="$(command -v hermes)" || {
printf 'Could not find the Hermes launcher on PATH\n' >&2
exit 1
}
HERMES_BIN="$(readlink -f "$HERMES_BIN")" || {
printf 'Could not resolve the Hermes launcher\n' >&2
exit 1
}
if [ ! -f "$HERMES_BIN" ] || [ ! -x "$HERMES_BIN" ]; then
printf 'Resolved Hermes launcher is not a regular executable file: %s\n' "$HERMES_BIN" >&2
exit 1
fi
HERMES_BIN_DIR="$(dirname "$HERMES_BIN")"
if [ -f "$HERMES_BIN_DIR/python" ]; then
HERMES_PYTHON="$HERMES_BIN_DIR/python"
elif [ -f "$HERMES_BIN_DIR/python3" ]; then
HERMES_PYTHON="$HERMES_BIN_DIR/python3"
else
printf 'Could not find Hermes Python beside %s\n' "$HERMES_BIN" >&2
exit 1
fi
if [ ! -x "$HERMES_PYTHON" ]; then
printf 'Hermes Python is not executable: %s\n' "$HERMES_PYTHON" >&2
exit 1
fi
"$HERMES_PYTHON" --version || {
printf 'Hermes Python failed its version probe: %s\n' "$HERMES_PYTHON" >&2
exit 1
}For a healthy existing side venv, force-refresh the wrapper using its explicit
interpreter (set HERMES_HOME first when the deployment does not use the
default Hermes home):
set -e
VENV=/path/to/venv
"$VENV/bin/mnemosyne-hermes" install --mode wrapper --python "$VENV/bin/python" --force
"$VENV/bin/mnemosyne-hermes" status--force refreshes a wrapper only after the selected Python can resolve its
site-packages and import mnemosyne_hermes; an invalid --python leaves the
existing wrapper and opted-in profile links in place. Editable installs in the
selected environment are supported. Use --force only after confirming that
the existing plugin target is the Mnemosyne wrapper or link you intend to
replace.
Do not try to activate the old selected venv. Before running the recovery
commands, including in a fresh shell, rerun the launcher-based discovery block
above in that same shell. It sets and version-probes HERMES_PYTHON; do not
substitute the current-shell Python. Then create a new, dedicated side venv with
"$HERMES_PYTHON" -m venv, then install mnemosyne-hermes and the selected
wrapper requirement. Before recovery, explicitly set MNEMOSYNE_PROFILE to
the value used by the existing wrapper: embeddings for the standard provider
or all when its local-LLM extras are needed. This is a documentation-local
selector, not a runtime setting the recovery commands can infer. Wrapper mode
cannot use core: mnemosyne-hermes itself requires
mnemosyne-memory[embeddings]. The following sequence uses a new path rather
than overwriting an unconfirmed environment:
set -e
if [ -z "${HERMES_PYTHON:-}" ] || [ ! -f "$HERMES_PYTHON" ] || [ ! -x "$HERMES_PYTHON" ]; then
printf 'HERMES_PYTHON is unset or not an executable file; rerun the launcher-based discovery block in this shell before recovery.\n' >&2
exit 1
fi
# For a non-default deployment/profile, replace both placeholders with its
# existing paths. At the defaults, omit these two exports.
export HERMES_HOME="<existing-Hermes-home>"
export MNEMOSYNE_DATA_DIR="<existing-Mnemosyne-data-directory>"
VENV=/path/to/new-mnemosyne-compatible-venv
if [ -e "$VENV" ] || [ -L "$VENV" ]; then
printf 'Refusing to create recovery venv at existing path: %s\n' "$VENV" >&2
exit 1
fi
if [ -z "${MNEMOSYNE_PROFILE:-}" ]; then
printf 'MNEMOSYNE_PROFILE is required for recovery. Set it to the existing wrapper profile: embeddings or all.\n' >&2
exit 1
fi
case "$MNEMOSYNE_PROFILE" in
embeddings) MNEMOSYNE_REQUIREMENT="mnemosyne-memory[embeddings]" ;;
all) MNEMOSYNE_REQUIREMENT="mnemosyne-memory[all]" ;;
core)
printf 'MNEMOSYNE_PROFILE=core is unavailable for mnemosyne-hermes wrapper installs: mnemosyne-hermes requires mnemosyne-memory[embeddings]. Use embeddings or all.\n' >&2
exit 1
;;
*)
printf 'Unsupported MNEMOSYNE_PROFILE: %s (expected embeddings or all)\n' "$MNEMOSYNE_PROFILE" >&2
exit 1
;;
esac
"$HERMES_PYTHON" -m venv "$VENV"
"$VENV/bin/python" -m pip install --upgrade "$MNEMOSYNE_REQUIREMENT" mnemosyne-hermes
"$VENV/bin/mnemosyne-hermes" install --mode wrapper --python "$VENV/bin/python" --force
"$VENV/bin/mnemosyne-hermes" statusRestart and validate on the same deployment/profile scope as the wrapper:
-
Docker or Compose: use the deployment tooling to restart the actual Hermes container or Compose service. Do not substitute
hermes gateway restartfor this deployment restart. After it is running, executehermes memory statusinside that service for the default profile, orhermes --profile <name> memory statusfor a named profile. -
Local installed gateway only: use
hermes gateway restart, thenhermes memory statusfor the default profile. For a named profile, use exactly:hermes --profile <name> gateway restart hermes --profile <name> memory status
For a profile-local wrapper, set HERMES_HOME to that profile's home for both
the force-refresh and wrapper status commands, then use that same profile
name for the gateway/service status command above. Do not use the historical
symlink migration as a compatibility repair; it stops using the wrapper's
selected Python.
To intentionally replace a wrapper with the historical symlink install, acknowledge the mode change:
mnemosyne-hermes install --mode symlink --force --migrate-wrapper-to-symlinkThat migration stops using the wrapper's selected Python. The installer warns before making the change; without the explicit flag it refuses the replacement.
Debian 13 (and Ubuntu 24.04+) ship Python with PEP 668 protection.
pip install outside a virtualenv fails with:
error: externally-managed-environment
× This environment is externally managed
Solution 1: Use a virtualenv (recommended)
python3 -m venv ~/mnemosyne-venv
source ~/mnemosyne-venv/bin/activate
pip install --upgrade mnemosyne-memoryMake sure Hermes is configured to use this venv's Python.
Solution 2: pipx (for CLI tools)
pip install pipx
pipx install mnemosyne-memorySolution 3: Override (quick fix, use with caution)
pip install --upgrade mnemosyne-memory --break-system-packagesThis bypasses the guard. Fine for personal machines or containers. Not recommended for shared/multi-app systems.
Solution 4: Source install with editable mode
git clone https://github.com/AxDSan/mnemosyne.git
cd mnemosyne
pip install -e . --break-system-packagesEditable mode means future git pull is all you need — no re-install
for most updates.
Released 2026-06-13. Minor release with working memory decay, temporal-triple lifecycle fix, and several packaging improvements.
- Working memory decay — default TTL bumped from 24h to 168h (7 days).
get_context()now bumpsrecall_countandlast_recalledon returned items, and each bump extends the item's lifetime by up toMNEMOSYNE_WM_BUMP_CAP_HOURS(default 24h). Pinned items (MNEMOSYNE_WM_PINNED_IDS) are excluded from consolidation entirely. - Sleep consolidation skips pinned items — a new
pinnedcolumn onworking_memorytellssleep()to leave those memories untouched. - Temporal-triple lifecycle restored —
supersede,valid_until, andendoperations on triples are now functional (were absent in v3.5.0/v3.6.0 despite appearing merged). Newend_triple()module function andmnemosyne_triple_endtool. HERMES_HOMEresolution fixed — env var now checked beforePath.home()fallback across beam, banks, memory, and integration files.- Packaging cleanup —
openclawremoved from[all]extra. Python 3.9 support dropped (3.10+).
pip install --upgrade mnemosyne-memoryNo migration steps needed. New columns (pinned, recall_count, last_recalled)
are created lazily if absent. Your upto_24_hours MNEMOSYNE_WM_TTL_HOURS
overrides are still honoured — the default just changed.
pip install 'mnemosyne-memory==3.6.0'The working-memory schema additions are additive (ALTER TABLE ... ADD COLUMN).
Downgrading Python code to 3.6.0 while the schema has pinned/recall_count/
last_recalled columns is harmless — 3.6.0 ignores unknown columns. To fully
reverse the schema change (not necessary, but available):
echo "ALTER TABLE working_memory DROP COLUMN pinned;" | sqlite3 path/to/mnemosyne.db
echo "ALTER TABLE working_memory DROP COLUMN recall_count;" | sqlite3 path/to/mnemosyne.db
echo "ALTER TABLE working_memory DROP COLUMN last_recalled;" | sqlite3 path/to/mnemosyne.dbReleased 2026-06-15. Minor release with bidirectional memory sync, dedicated vec_working table, reindex command, fact_recall ranking fix, and smart plugin upgrade tooling.
- Bidirectional memory sync with optional client-side encryption. Event-log-
based delta protocol with conflict detection via causal version chains.
Uses a stdlib-only HTTP server (no FastAPI). New CLI:
mnemosyne sync,sync-serve,sync-status,sync-generate-key. - vec_working dedicated table — working-memory vectors now live in their own
sqlite-vec table with memory_embeddings as the compatibility fallback.
diagnose --repair-vec-workingreports coverage and backfills missing rows. - Synchronous reindex —
mnemosyne reindexrebuilds all vectors (working, episodic, facts) after embedding model or dimension change. Auto-backup. - fact_recall ranking now scores by query relevance (not stored confidence),
returning full triples as content. Opt-in via
MNEMOSYNE_FACT_RECALL_ENABLED. - Smart plugin upgrade —
mnemosyne-hermes upgradeauto-detects install method (pipx / uv-tool / pip), shows version comparison, upgrades, and re-registers the plugin. - Plugin cleanup —
mnemosyne-hermes cleanupremoves plugin, old dirs, and resets config.--dry-runsafe. - CLI version no longer depends on
__author__(removed in v3.7.0).
pip install --upgrade mnemosyne-memoryFor the new plugin features:
pipx install "mnemosyne-hermes[all]"For existing symlink installs only:
mnemosyne-hermes install --force| Variable | Default | What it does |
|---|---|---|
MNEMOSYNE_FACT_RECALL_ENABLED |
not set | Enables query-relevance-scored fact recall |
MNEMOSYNE_SYNC_SERVER_PORT |
8765 | Sync server listening port |
MNEMOSYNE_SYNC_SERVER_KEY |
(none) | Encryption key for sync payloads |
Adds memory_events table (sync event log) and sync_meta table (device
identity, cursors). Both created lazily. No destructive migrations.
pip install 'mnemosyne-memory==3.7.0'The sync tables persist but are ignored by v3.7.0 code. vec_working table persists but v3.7.0 memory_embeddings fallback reads it as a normal table — no collision.
Released 2026-06-18. Adds mnemosyne reindex for rebuilding vectors after
a model or dimension change, and mnemosyne diagnose for deployment health
checks.
- New
mnemosyne reindexcommand — synchronous vector rebuild across all memory tables (working, episodic, facts). Replaces the old incremental approach that could leave stale vectors. mnemosyne diagnosenow reportsvec_workingmigration coverage so you can confirm working-memory vector search is active.
pip install --upgrade mnemosyne-memory==3.9.0No manual migration needed. The upgrade adds memoria_ tables on first init.
Released 2026-06-18. Adds always-on behavioral rule layer that survives past
the working-memory TTL. New memoria_persona table with four tiers:
permanent, long-term, working, ephemeral.
- L3 persona facts (
memoria_personatable) — behavioral rules extracted from conversation, persisted across sessions, injected into system prompt. Four confidence tiers with automatic reinforcement and decay. - 5 new Hermes tools:
mnemosyne_persona_list,mnemosyne_persona_add,mnemosyne_persona_reinforce,mnemosyne_persona_demote,mnemosyne_persona_remove. - Auto-injection: persona.md is appended to the system prompt when triggered by session-start, tool-call, recall, or periodic refresh.
pip install --upgrade mnemosyne-memory==3.10.0No manual migration. Persona extraction starts automatically. To disable
persona auto-injection, set memory.mnemosyne.persona_inject: false in
config.yaml.
Released 2026-06-22. Security release — fixes CVE GHSA-xcw4-53cc-hv32 (CVSS 9.1). The sync server's JWT verification was missing signature validation.
- HMAC-SHA256 signature verification added to sync server auth
- Strict
alg: HS256allowlist (rejectsnone, RS256, etc.) - Constant-time signature comparison via
hmac.compare_digest
pip install --upgrade mnemosyne-memory==3.10.1If you operate a sync server with network exposure, upgrade immediately. If you cannot upgrade, restrict network access to the sync endpoint.
Released 2026-06-30. Adds LLM-assisted canonical model refresh during sleep, recall diagnostics + task progress tools, tool whitelist, wrapper install mode, and several fixes.
- Automated sleep model refresh — during
sleep(), Mnemosyne asks the LLM for structured candidate updates to canonical model slots (user model, workflow model, project model). Validated candidates are auto-applied or auto-rejected by policy. Newmnemosyne_model_refreshdiagnostic tool. - Recall diagnostics —
mnemosyne_recall_diagnosticsexposes per-row scoring breakdowns (weights, scores, signal contributions). - Task progress —
mnemosyne_task_progresstracks multi-step task state across sessions. - Tool whitelist — restrict exposed tools via
memory.mnemosyne.toolsconfig key. Unknown names raise a clear error. - Wrapper install mode —
mnemosyne-hermes install --mode wrapperfor read-only / Docker deployments. MNEMOSYNE_LLM_TIMEOUT— configurable HTTP timeout for remote LLM calls (default 60s).mnemosyne backupnow works with sqlite-vec databases.- CLI bank-aware under
profile_isolation— CLI commands now read the correct profile bank.
pip install --upgrade mnemosyne-memory==3.11.0No manual migration. Sync role default changed to ["user"] — if you
want assistant-turn autosave, set memory.mnemosyne.sync_roles: ["user", "assistant"] in config.yaml.
Released 2026-06-10. Minor release with canonical facts, holographic importer, API embedding fallback chain, host LLM registration in CLI, and several fixes.
- CanonicalStore — new
canonical_factstable (lazy-created, no new dependency) giving long-running personas an identity layer where each(owner_id, category, name)slot holds exactly one current value. Two new tools:mnemosyne_remember_canonicalandmnemosyne_recall_canonical. Total tool count: 23 → 25. - Holographic Memory importer —
hermes mnemosyne import --from holographicnow operational. Reads Hermes' SQLite-based holographic memory plugin. No API key needed. - API embedding fallback —
embed()now falls through to local fastembed when the API call fails. SetMNEMOSYNE_EMBEDDING_FALLBACK_MODELto choose your fallback (default: bge-small-en-v1.5). No configuration needed for the default. - Embeddings now unconditional —
fastembed+sqlite-vecare hard dependencies (previously opt-in via[embeddings]extra). If your environment blockspip install --upgrade mnemosyne-memory, check system packages. - Hermes host LLM in CLI —
hermes mnemosyne sleepnow properly respectsMNEMOSYNE_HOST_LLM_ENABLED=true. - Per-entity identity in prefetch — the agent always gets your stable self-descriptors without explicit identity search.
pip install --upgrade mnemosyne-memoryThat's it. The canonical_facts table is created lazily on first init — no migration script needed. The holographic importer works out of the box after upgrade.
pip install mnemosyne-memory==3.4.0Note: the canonical_facts table persists across downgrades (it's just a SQLite table; old code ignores it). Re-pip install --upgrade when ready.
Released 2026-05-28. Pure bug fix release — no schema changes, no new features.
-
Multi-token relevance scoring fixed. Pre-v3.1.2...
-
Strict fact matching is now the default. The old permissive path matched any query word against any stored fact, pulling in unrelated memories with a false +20% score boost. Set
MNEMOSYNE_LENIENT_FACT_MATCH=1to opt back in. -
Entity prefix guard added. The prefix match in entity similarity now requires a minimum 30% length ratio. Short query prefixes like "her" no longer match "Hermes" at 0.828.
-
Single-token strict matching fixed. Queries like "hermes", "python", "react" (single 5+ char tokens) now pass the strict fact matcher. Previously required 8+ chars with structural characters.
pip install --upgrade mnemosyne-memory
hermes gateway restartZero manual migration needed. If you relied on the lenient fact matching, set:
export MNEMOSYNE_LENIENT_FACT_MATCH=1Non-strict recall is still the default for entity and fact paths (MNEMOSYNE_ENHANCED_RECALL=0). Strict mode only applies to the built-in fact matcher (_find_memories_by_fact). The entity/fact recall paths also don't propagate from_date/to_date/veracity filters — tracked as a low-priority follow-up.
This is the most common jump for existing users. It covers 3 releases worth of changes. Read the relevant sections in order:
- v2.7 → v2.8 — E6 TripleStore split (schema migration)
- v2.8 → v2.9 — MCP SDK 1.x compatibility (code only)
- v2.9 → v3.0 — MEMORIA architecture (new tables)
# 1. Update the package
pip install --upgrade mnemosyne-memory
# (If PEP 668 blocks you, use --break-system-packages)
# pip install --upgrade mnemosyne-memory --break-system-packages
# 2. Restart Hermes to load the new plugin/tools
hermes gateway restart
# 3. Verify
hermes mnemosyne version
# Should show: 3.0.0
hermes mnemosyne stats --global
# Check memory count is preserved
hermes tools list | grep mnemosyne
# Should show 17+ toolsWhat happens to your data on first run:
- v2.7 databases get auto-migrated by E6 on first BeamMemory init.
Backup written to
{db}.pre_e6_backup. - v3.0 creates 5 new MEMORIA tables (
memoria_facts,memoria_timelines,memoria_instructions,memoria_preferences,memoria_kg) viaCREATE TABLE IF NOT EXISTS. Existing tables are untouched. - All existing memories, triples, embeddings remain intact.
If anything goes wrong:
# Restore pre-E6 backup
cp ~/.hermes/mnemosyne/data/mnemosyne.db.pre_e6_backup \
~/.hermes/mnemosyne/data/mnemosyne.db
# Roll back to v2.7
pip install 'mnemosyne-memory==2.7.0'
hermes gateway restartThe MEMORIA release introduces structured fact extraction and retrieval.
Schema changes (all auto-created):
5 new tables: memoria_facts, memoria_timelines,
memoria_instructions, memoria_preferences, memoria_kg.
All use CREATE TABLE IF NOT EXISTS — zero risk to existing data.
New environment variables:
| Variable | Default | What it does |
|---|---|---|
MNEMOSYNE_STRICT_FACT_MATCH |
not set | Enables token-based conservative fact matching |
MNEMOSYNE_PROACTIVE_LINKING |
not set | Enables zero-LLM graph edge creation at ingest |
MNEMOSYNE_MEMORIA_MODEL |
gemini-2.0-flash-lite |
LLM model used for MEMORIA extraction |
What to verify after update:
# Check MEMORIA tables exist
python3 -c "
import sqlite3, pathlib
db = pathlib.Path.home() / '.hermes' / 'mnemosyne' / 'data' / 'mnemosyne.db'
conn = sqlite3.connect(str(db))
tables = conn.execute(\"SELECT name FROM sqlite_master WHERE type='table' AND name LIKE 'memoria_%'\").fetchall()
print('MEMORIA tables:', [t[0] for t in tables])
conn.close()
"
# Expected output:
# MEMORIA tables: ['memoria_facts', 'memoria_timelines',
# 'memoria_instructions', 'memoria_preferences',
# 'memoria_kg']Rollback:
pip install 'mnemosyne-memory==2.9.0'
hermes gateway restartThe MEMORIA tables remain in the database but are ignored by older code. They are harmless. If you want them gone, export, delete DB, re-import.
The v3.1.0 release adds shared surface memory, multilingual MEMORIA, custom embedding endpoints, and many fixes.
New capabilities:
- Shared surface memory. Cross-agent shared persistence via
mnemosyne_shared_*tools. Each agent gets an isolated shared surface. Activate withhermes memorysurface commands. - Multilingual MEMORIA. Language auto-detection for German, Russian, and Chinese. Extraction now applies language-specific patterns based on detected input language.
- Custom embedding endpoints. Configure any OpenAI-compatible embedding provider via
OPENROUTER_BASE_URL(set to your own server URL). Jina model dimensions auto-detected. SetMNEMOSYNE_EMBEDDINGS_VIA_API=trueif you want to use OpenRouter-hosted embedding models specifically. - Deterministic
get(id). Direct memory retrieval by ID — no vector search, no ranking. Callmnemosyne.get(memory_id)for exact lookup.
New environment variables:
| Variable | Default | What it does |
|---|---|---|
OPENROUTER_BASE_URL |
https://openrouter.ai/api/v1 |
Override the embedding API provider URL |
MNEMOSYNE_EMBEDDINGS_VIA_API |
not set | Set to true to route all embedding models through the API |
Fixes included:
- sqlite-vec int8 search now uses
AND k=Nsyntax (was silently wrong withLIMIT) - Hermes plugin: all 6 tool schemas now include
bankparameter for multi-bank operation - sqlite-vec extension loaded before vector operations (fixes
vec_distance_cosinecrashes) - Timezone normalization in temporal recall (fixes off-by-hour windowing)
- Working memory vectors generated and persisted on every
remember()call - MEMORIA regex dedup and language pattern fixes across German, Russian, Chinese
- Config string booleans properly coerced from YAML
What to verify after update:
pip install --upgrade mnemosyne-memory
hermes gateway restart
# Verify version
python3 -c "from mnemosyne import __version__; print(__version__)"
# Expected: 3.1.0Rollback:
pip install 'mnemosyne-memory==3.0.0'
hermes gateway restartShared surface tables remain in the database but are ignored by v3.0.0.
MCP server transport updated for SDK v1.x. Code-only change — no schema migration needed.
pip install --upgrade mnemosyne-memory
hermes gateway restartOnly affects you if you use the MCP server directly (not via Hermes).
This release splits the triples table into two purpose-specific tables
and introduces optional content compression.
Critical schema change: E6 TripleStore Split
Before v2.8, all triples lived in one triples table with auto-invalidation
semantics. This silently destroyed multi-valued annotations (entities,
facts) whenever a memory had more than one.
After v2.8:
triples— retains current-truth facts (superseding behavior)annotations— append-only, hostsmentions,fact,occurred_on,has_source(multi-valued by design)
Auto-migration (default):
On first BeamMemory init, annotation-flavored rows are moved from
triples to annotations. A backup is created at {db}.pre_e6_backup.
pip install --upgrade mnemosyne-memory
hermes gateway restart
# Check logs for:
# "E6: auto-migrated N annotation rows from triples -> annotations."Manual migration (explicit control):
export MNEMOSYNE_AUTO_MIGRATE=0
hermes gateway restart
# BeamMemory logs a WARNING with pending row count
# Preview
python scripts/migrate_triplestore_split.py --dry-run
# Apply
python scripts/migrate_triplestore_split.pyNew optional feature: CompressionPlugin
Disabled by default. Enable via config or env var:
export MNEMOSYNE_USE_CAVEMAN=1Or in code:
from mnemosyne.core.config import MnemosyneConfig
MnemosyneConfig.compression.enabled = TrueWhat to verify after update:
# Check annotations table exists
python3 -c "
import sqlite3, pathlib
db = pathlib.Path.home() / '.hermes' / 'mnemosyne' / 'data' / 'mnemosyne.db'
conn = sqlite3.connect(str(db))
count = conn.execute('SELECT COUNT(*) FROM annotations').fetchone()[0]
print(f'Annotations table has {count} rows')
conn.close()
"Wondering if an update changed the SQLite schema? Here's how to check:
# Dump the current schema
python3 -c "
import sqlite3, pathlib
db = pathlib.Path.home() / '.hermes' / 'mnemosyne' / 'data' / 'mnemosyne.db'
conn = sqlite3.connect(str(db))
schema = conn.execute(\"SELECT sql FROM sqlite_master WHERE type='table' ORDER BY name\").fetchall()
for row in schema:
print(row[0] + ';')
conn.close()
" > ~/mnemosyne_schema_baseline.txt# Dump the new schema
python3 -c "
import sqlite3, pathlib
db = pathlib.Path.home() / '.hermes' / 'mnemosyne' / 'data' / 'mnemosyne.db'
conn = sqlite3.connect(str(db))
schema = conn.execute(\"SELECT sql FROM sqlite_master WHERE type='table' ORDER BY name\").fetchall()
for row in schema:
print(row[0] + ';')
conn.close()
" > ~/mnemosyne_schema_new.txt
# Compare
diff ~/mnemosyne_schema_baseline.txt ~/mnemosyne_schema_new.txtNew tables and columns appear as additions. Missing tables would appear
as removals. Mnemosyne uses CREATE TABLE IF NOT EXISTS and
ALTER TABLE ADD COLUMN with existence checks, so schema changes are
additive — no destructive migrations.
python3 -c "
import sqlite3, pathlib
db = pathlib.Path.home() / '.hermes' / 'mnemosyne' / 'data' / 'mnemosyne.db'
conn = sqlite3.connect(str(db))
tables = conn.execute(\"SELECT name FROM sqlite_master WHERE type='table' ORDER BY name\").fetchall()
names = [t[0] for t in tables]
if 'memoria_facts' in names:
print('DB schema: v3.0+ (MEMORIA)')
elif 'annotations' in names:
print('DB schema: v2.8+ (E6 TripleStore split)')
elif 'episodic_memory' in names:
print('DB schema: v2.0+ (BEAM)')
else:
print('DB schema: v1.x (legacy)')
conn.close()
"pip install --upgrade mnemosyne-memory
hermes gateway restartTo verify the new version:
hermes mnemosyne version
hermes mnemosyne stats --global
hermes memory statusNote: UPDATING.md is included in the sdist and wheel package, but PyPI does not serve individual files at browsable URLs. The file is available at the GitHub repo:
https://github.com/AxDSan/mnemosyne/blob/main/UPDATING.md
For most updates, only git pull is required:
cd mnemosyne
git pull
hermes gateway restartRe-run pip install -e . only when:
setup.pyorpyproject.tomladded new dependencies- New
entry_pointsor console scripts were added - Package metadata changed
git pull
pip install -e ".[all,dev]"
hermes gateway restartRe-run the installer only when mnemosyne/install.py or the symlink
logic changed:
git pull
python -m mnemosyne.install
hermes gateway restartThis path symlinks ~/.hermes/plugins/mnemosyne directly into the repo:
cd mnemosyne
git pull
hermes gateway restartNo pip install needed — nothing is installed into a Python environment.
Mnemosyne uses CREATE TABLE IF NOT EXISTS and CREATE INDEX IF NOT EXISTS, so most schema changes upgrade automatically.
Run a migration script only when:
- The CHANGELOG explicitly mentions a database schema change
- You are upgrading from a pre-2.0 version
- You see errors about missing columns or tables
| Script | What it does |
|---|---|
scripts/migrate_from_legacy.py |
Migrates from v1.x ephemeral databases to the canonical v2+ path. Idempotent. |
scripts/migrate_triplestore_split.py |
Manual E6 migration (v2.8). Only needed if you set MNEMOSYNE_AUTO_MIGRATE=0. Idempotent. |
# Preview first
python scripts/migrate_triplestore_split.py --dry-run
# Apply
python scripts/migrate_triplestore_split.pyAll migration scripts are idempotent — safe to run multiple times.
# Pin to a known good version
pip install 'mnemosyne-memory==2.7.0'
# Or from source
cd mnemosyne
git checkout v2.7.0
pip install -e .
# Restart Hermes
hermes gateway restartIf you have a DB backup from before the update:
# E6 auto-backup
cp ~/.hermes/mnemosyne/data/mnemosyne.db.pre_e6_backup \
~/.hermes/mnemosyne/data/mnemosyne.db
# Or any custom backup
cp ~/backups/mnemosyne_20260101.db \
~/.hermes/mnemosyne/data/mnemosyne.db# Export current data
hermes mnemosyne export --output ~/backup.json
# Delete the database entirely
rm ~/.hermes/mnemosyne/data/mnemosyne.db
# Start fresh with old version
pip install 'mnemosyne-memory==2.7.0'
hermes gateway restart
# Re-import
hermes mnemosyne import --input ~/backup.json# Version check
hermes mnemosyne version
# Stats (memories preserved?)
hermes mnemosyne stats --global
# Tools registered?
hermes tools list | grep mnemosyne
# Memory available?
hermes memory status
# Schema version (for the curious)
python3 -c "
import sqlite3, pathlib
db = pathlib.Path.home() / '.hermes' / 'mnemosyne' / 'data' / 'mnemosyne.db'
conn = sqlite3.connect(str(db))
tables = conn.execute(\"SELECT name FROM sqlite_master WHERE type='table' ORDER BY name\").fetchall()
print(f'{len(tables)} tables: {[t[0] for t in tables]}')
conn.close()
"Entry points are registered at install time, not at runtime. Re-run the install:
pip install -e .Your virtual environment may have been deactivated or the editable install broke. Re-install:
pip install -e .Hermes caches plugins at startup. You must restart:
hermes gateway restartYou're on Debian 13+ / Ubuntu 24.04+ (PEP 668). See the PEP 668 section.
If you see errors about missing columns or tables, run a migration:
# Try auto-repair by restarting
hermes gateway restart
# If that fails, run the legacy migration
python scripts/migrate_from_legacy.py
# If errors persist, export, delete, re-import
hermes mnemosyne export --output ~/backup.json
rm ~/.hermes/mnemosyne/data/mnemosyne.db
hermes mnemosyne import --input ~/backup.jsonPyPI does not serve individual package files at browsable URLs. The correct URL for the latest version is:
https://github.com/AxDSan/mnemosyne/blob/main/UPDATING.md
The file IS included in the sdist and wheel — pip show -f mnemosyne-memory will confirm it ships.
The E6 migration moves annotation rows from triples to a new
annotations table. This does not delete memories. Check:
hermes mnemosyne stats --globalIf counts look wrong, check the E6 migration log:
grep -i "auto-migrated\|E6" ~/.hermes/logs/gateway.log