Skip to main content

MemoryMaster

CI PyPI Python 3.10+ License: MIT

MemoryMaster is persistent memory for coding agents where every durable fact is a governed claim—not an opaque chunk that silently lives forever.

It captures evidence, extracts candidate claims, preserves citations, detects conflicts, promotes trustworthy claims through a steward, and retires facts when their support stops being current. Claude Code, Codex, Gemini-powered workers, Hermes, and any MCP client can share the same local memory without surrendering authority to a vector database or generated summary.

evidence -> candidate claim -> steward -> confirmed claim -> governed recall
                                      \-> supported graph
                                           \-> candidate observation
                                                \-> steward -> opt-in recall

What shipped in 4.7

Capability What it does Default
Governed graph observations Derives supported dependencies, constraints, recurring patterns and root causes from confirmed evidence Off by default (MEMORYMASTER_GRAPH_OBSERVATIONS=1); recall opt-in
Compiled user profile Builds a disposable, cited projection from multiple independent sessions Off by default (MEMORYMASTER_COMPILED_PROFILE=1); never an instruction source
Fast conversational recall Finds relevant claims on the local lexical path without an embedding, Qdrant or provider call On
Private-context intake guard Redacts RFC1918 topology and absolute Windows/UNC paths from durable claim fields while preserving useful prose On
Governed skills Stores reviewed reusable procedures separately from ordinary facts Recall opt-in
Hermes integration Provides exact session/project scoping, local HTTP/stdio compatibility and replay-safe outbox behavior Optional integration
Operational review Performs a read-only six-hour integrity, queue, profile, intake and retrieval review Optional Windows task

MemoryMaster 4.8 uses the configured Gemini extraction + Gemini consolidation path for this installation; consolidation moved off GLM on 2026-08-20 when that plan was retired, and now runs through the Antigravity (agy) CLI over OAuth. OpenAI and Anthropic remain optional provider adapters; neither is required for graph-observation discovery or ordinary recall.

Why MemoryMaster exists

Typical memory stacks optimize retrieval while leaving correctness and retirement to the caller. MemoryMaster makes those properties explicit:

  • Every claim has lifecycle state, scope, provenance, confidence and validity.
  • Trusted recall returns confirmed, authorized, non-sensitive claims only.
  • Contradictions become visible conflicts instead of silently coexisting.
  • Citations and support tables make derived output traceable back to evidence.
  • forget previews logical retirement; it never implies an unsafe hard delete.
  • SQLite is authoritative. Qdrant is optional and may only propose IDs that are rehydrated and re-authorized from SQLite.
  • Generated observations, profiles, skills and wiki pages never recursively reinforce the claims that produced them.

Quick start

Install the private local MCP profile:

python -m pip install "memorymaster[mcp,capture,security]"
memorymaster-setup --yes --profile minimal --no-full-stack --json

Restart the agent session once so its long-lived MCP process loads the installed package, then verify:

query_memory("What decisions have we made about storage?")

Try the complete lifecycle in a disposable database:

memorymaster --json demo

Four public operations

The stable Python, CLI and MCP interface is intentionally small:

memorymaster --workspace . remember --text "Atlas uses SQLite WAL."
memorymaster --workspace . recall "What does Atlas use?"
memorymaster --workspace . forget --source-item-id 1
memorymaster --workspace . improve --scope project:atlas
from memorymaster import forget, improve, recall, remember

receipt = remember(text="Atlas uses SQLite WAL.", scope="project:atlas")
context = recall("What does Atlas use?", scope_allowlist=["project:atlas"])
preview = forget(source_item_id=receipt.source_item["id"])
queued = improve(scope="project:atlas")
  • remember stores source/evidence lineage and queues governed extraction.
  • recall is confirmed-only in trusted mode.
  • forget previews by default; --apply performs lifecycle retirement.
  • improve queues bounded work. It does not confirm or rewrite claims inside the request.

See Public v1 for receipts and full parameter contracts.

Graph observations (PPR-7)

Off by default. Enable with MEMORYMASTER_GRAPH_OBSERVATIONS=1. The claims database works fully without it; this is an optional layer on top.

Graph observations answer questions that individual facts cannot, such as:

  • Which three blockers form one dependency chain?
  • What recurring pattern is supported by several independent episodes?
  • Which root cause is cited by multiple confirmed claims?
  • Which observation became stale when its supporting evidence was retired?

Component membership is deterministic. Exact canonical graph signatures and union-find decide which evidence belongs together; an LLM may summarize an eligible component but cannot choose membership, invent support, promote its own output, or feed the result back into graph extraction.

Recall remains explicit:

memorymaster --workspace . recall "What dependencies keep recurring?" --include-observations
result = recall(
    "What dependencies keep recurring?",
    include_observations=True,
    observation_limit=2,
)

Trusted mode revalidates support at read time and returns confirmed observations only. Exploratory mode can label candidates or stale observations. Ordinary recall remains unchanged while include_observations is off.

Evidence-bound compiled profile

Off by default. Enable with MEMORYMASTER_COMPILED_PROFILE=1. Recall does not depend on it; when disabled, nothing is injected at session start.

The compiled profile turns repeated, independently supported transcript facts into a bounded session-start briefing. It is a disposable projection:

  • SQLite transcript/support rows remain authoritative.
  • New or replacement facts need at least two independent sessions.
  • Unknown support IDs, sensitive output, instructions and malformed provider output fail closed.
  • The injected profile is context about the user—not permission and not an instruction hierarchy.

Enable both 4.7 features for new processes:

[Environment]::SetEnvironmentVariable("MEMORYMASTER_GRAPH_OBSERVATIONS", "1", "User")
[Environment]::SetEnvironmentVariable("MEMORYMASTER_COMPILED_PROFILE", "1", "User")

Hooks are re-read on every event and update immediately. MCP servers and other long-lived daemons must be restarted to load newly installed package code or new environment variables.

Scheduled operation—release first, review afterward

There is no 24-hour implementation or release prerequisite. A long observation window is useful only as later evidence about queue health, cost and lifecycle. It must never keep working code out of main merely because the clock has not elapsed.

On Windows, install the bounded read-only review task after installing the release:

powershell -NoProfile -ExecutionPolicy Bypass -File scripts/install-windows-operational-review.ps1 `
  -PythonExe "<runtime-python.exe>" `
  -Database "<memorymaster.db>" `
  -ExpectedVersion "4.7.2" `
  -EveryHours 6

MemoryMaster-Operational-Review then checks:

  • installed version, schema, SQLite quick_check and foreign keys;
  • observation backlog, blocked jobs and expired leases;
  • compiled-profile runs, facts and exact support counts;
  • recent claim fields for private topology or absolute-path residue;
  • the configured natural-language retrieval canary.

It writes latest.json and append-only execution history under the user's local application-data directory. The review opens SQLite read-only, performs no claim or job mutation, and never turns task transport into a false success receipt. Exit codes are 0=PASS, 1=FAIL, and 3=WARN.

Architecture and governance

producer
  -> source_items
  -> evidence_items
  -> candidate claims
  -> steward proposals / lifecycle events
  -> confirmed claims
  -> FTS5 recall + supported entity graph
  -> optional observations / skills / compiled profile

The default product is one private local SQLite database in WAL mode plus a stdio MCP server. No new database, cloud service or vector server is required. PostgreSQL team operation remains explicitly deferred; Qdrant remains an optional semantic accelerator rather than a source of truth.

Important boundaries:

  • Claim fields pass through the shared sensitivity filter on every ingest path.
  • Raw user-selected source/evidence remains governed by the separate preservation boundary described in ADR-0006.
  • Generated observations cannot support future observations.
  • Trusted graph traversal requires active, authorized support in the same scope and tenant.
  • Schema changes use immutable checksum-verified migrations.
  • The Obsidian wiki is an opt-in human view, not the read layer.

See Architecture, Operations, and the Graph Observations ledger.

MCP configuration

{
  "mcpServers": {
    "memorymaster": {
      "command": "memorymaster-mcp",
      "env": {
        "MEMORYMASTER_DEFAULT_DB": "<path-to-memorymaster.db>",
        "MEMORYMASTER_WORKSPACE": "<project-root>",
        "MEMORYMASTER_MCP_AUTH_MODE": "local-trusted"
      }
    }
  }
}

local-trusted is only for a private SQLite stdio process controlled by one OS user. Regenerate old brownfield entries that do not declare an authorization mode. The full tool inventory is generated from code in release truth; operational examples are in MCP tools.

Providers

Provider calls are for extraction, consolidation and selected steward phases— not for ordinary local recall.

Provider Configuration Typical use
Gemini MEMORYMASTER_LLM_PROVIDER=google plus configured Google credentials Activated extraction path
Gemini through the Antigravity agy CLI OAuth session cached by a prior interactive agy run Activated Dreaming/profile consolidation path
GLM through authenticated OpenCode MEMORYMASTER_DREAM_CONSOLIDATE_PROVIDER=glm Retired 2026-08-20; deselected, not deleted
Claude CLI OAuth MEMORYMASTER_LLM_PROVIDER=claude_cli Optional batch/steward path
Ollama MEMORYMASTER_LLM_PROVIDER=ollama Optional local provider
OpenAI / Anthropic APIs corresponding provider and environment credential Supported optional adapters

Never put credentials in claims, repository files, task arguments, logs or generated profiles.

Useful commands

# Trusted recall with score explanation
memorymaster query "topic" --explain

# One bounded steward cycle
python -m memorymaster --db memorymaster.db run-cycle

# Database checks
memorymaster --db memorymaster.db --json integrity --quick-check --fk-check

# Dashboard
memorymaster-dashboard --db memorymaster.db

# Validate generated release inventory
python scripts/generate_release_truth.py --check

Upgrade and rollback

Upgrade the package, then restart long-lived MCP/daemon processes:

python -m pip install --upgrade "memorymaster[mcp,capture,security]"

Feature rollback does not delete history:

[Environment]::SetEnvironmentVariable("MEMORYMASTER_GRAPH_OBSERVATIONS", "0", "User")
[Environment]::SetEnvironmentVariable("MEMORYMASTER_COMPILED_PROFILE", "0", "User")

Disabling generation/recall leaves additive tables and audit history intact. Candidates can be archived and confirmed generated observations made stale only through the governed lifecycle—not by deleting database rows.

Project status and documentation

MemoryMaster is MIT licensed. Contributions should preserve SQLite authority, claim governance, exact support lineage, privacy boundaries and opt-in derived recall.

Metadata

Release files for memorymaster 4.8.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for memorymaster 4.8.5
File Size Uploaded Provenance Actions
memorymaster-4.8.5.tar.gz 1.7 MB With provenance Details for memorymaster-4.8.5.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for memorymaster 4.8.5
File Interpreter ABI Platform Actions
memorymaster-4.8.5-py3-none-any.whl Python 3 none any Details for memorymaster-4.8.5-py3-none-any.whl

Total release size: 2.8 MB

Release files / memorymaster-4.8.5.tar.gz

Download URL memorymaster-4.8.5.tar.gz
Size 1.7 MB
Tags Source
SHA-256 checksum
How to use checksums
1055d9f2b272028f2d4674519e6f9f9c9813cb15fe31d42e6933ff7aea946d51
BLAKE2b-256 checksum
How to use checksums
be49b838c57e382ce95d55269329ab400aafa8832b5cea46f564d3a2e9af95de
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Aug 29, 2026.

Transparency log

Release files / memorymaster-4.8.5-py3-none-any.whl

Download URL memorymaster-4.8.5-py3-none-any.whl
Size 1.1 MB
Tags Python 3
SHA-256 checksum
How to use checksums
4a0e4767a09cba0f334d86714d0d9c6939fba9e838b430ecb488a26562a91f4c
BLAKE2b-256 checksum
How to use checksums
3bf58482a246df800729b62d54e2c55a24b12a60ccfc2cdd8cbc073781c1dfe6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Aug 29, 2026.

Transparency log

Security for memorymaster 4.8.5

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 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for memorymaster-4.8.5.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 Aug 29, 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.

Release history Release notifications | RSS feed

This release

4.8.5 This release

2 release files Full provenance

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