Mneme HQ
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
**Mneme is an open decision and control layer for agentic software development.**
It turns durable engineering decisions into agent context, deterministic enforcement, and inspectable enforcement results across AI coding agents, repositories, and CI workflows. Architecture is the first supported decision domain: **Mneme prevents architectural drift** by turning architectural decisions and ADRs into deterministic guardrails across coding agents, repository mutations, generated rules, and CI gates.
> **Where is your architecture actually enforced?** Run the Architecture Audit to see which decisions are protected, which can become deterministic guardrails, and which still depend on someone remembering the rules. Try it →
Mneme is the decision layer behind that drift-prevention mechanism. It keeps recorded engineering decisions active as AI coding systems propose and modify code, instead of leaving ADRs as passive documentation.
Solid surfaces ship today; dashed surfaces are planned. Support levels per integration: integrations matrix.
> **Current phase:** Layer 1 validation. Retrieval, enforcement, and benchmark semantics are governed by the accepted architecture and freeze record. See Current Phase before changing core behavior.
What Mneme does
Mneme separates architectural guidance from deterministic enforcement:
- **Records architectural decisions** in a structured, auditable decision corpus.
- **Retrieves relevant decisions** when an agent or model needs architectural guidance.
- **Enforces governed rules deterministically** under explicit applicability semantics.
- **Integrates at the earliest reliable boundary** exposed by each coding workflow.
- **Audits bypassable mutation paths** where pre-change blocking is not technically available.
- **Runs in CI** as a final deterministic gate before incompatible changes are accepted.
The same input and governed decision state produce the same enforcement result. Mneme does not depend on an LLM judge for its core allow/warn/fail decisions.
Mneme is not a general-purpose vector store, conversational memory system, autonomous coding agent, or deployment observability platform.
Install
Requires Python 3.11+.
Verify the CLI:
For repository development:
Decision MCP
Mneme exposes the Decision Index over a local MCP server so MCP-capable clients can propose candidate architectural decisions and query decision state without gaining authority to change that state.
Install the optional MCP dependency:
Start the local stdio server. Canonical reads come from the persisted Decision Index in .mneme/project_memory.json by default; the proposal store remains separate.
Use --memory to select another project memory file. The file must contain a valid authoritative decision_index section; MCP fails closed rather than reconstructing authority from the compatibility decisions[] snapshot.
Memory created by mneme init or mneme setup already carries an empty decision_index section and needs no migration. An older file with no decision_index section yet makes MCP stop with an error that tells you to migrate. Preview the migration first. It writes nothing and lists the visible effects: non-active decisions leave Layer 1, and legacy rule/anti_pattern items are migrated once.
Then apply exactly that migration:
Migration is lossless or it refuses. There is no force or repair mode. Memory containing legacy decision metadata that the canonical index cannot represent, such as EventCatalog-imported decisions, stays on the section-less path and is not migrated.
--adr-dir is now optional validation input only. Mneme still validates and precedence-resolves that corpus before startup, but ADRs do not become a second MCP authority source.
The MCP surface is intentionally frozen to six tools: