Mneme Decision MCP 标志

Mneme Decision MCP

组织
MnemeHQ

Open-source architectural drift prevention for the agentic AI SDLC. Deterministic guardrails keep AI coding agents aligned with repository architecture.

发布者MnemeHQ
代码仓库mneme
语言Python
复刻数
2
星标数
21
可用工具
0
传输类型stdio
分类
许可协议MIT
链接
  • 将工具接入 AI 工作流

    Mneme Decision MCP 提供 MCP 功能,可供兼容的 AI 客户端和智能体使用。

  • 0 个可用工具

    浏览下方可调用的操作;如果服务器提供了名称和描述,也会一并显示。

  • 可直接复制的配置

    使用安装配置片段,在您首选的 MCP 客户端中配置此服务器。

  • 开源社区热度

    关联的代码仓库有 21 个 Star 和 2 个 Fork。

Mneme HQ

Architectural drift prevention for the agentic AI SDLC.

Mneme turns architectural decisions and ADRs into deterministic guardrails for the agentic AI SDLC — across coding agents, repository mutations, generated rules, and CI gates.

Tests PyPI Python License: MIT

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 architectural governance 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.

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+.

bash
pip install mneme-hq

Verify the CLI:

bash
mneme --help

For repository development:

bash
git clone https://github.com/MnemeHQ/mneme.git
cd mneme
pip install -e ".[dev]"

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:

bash
pip install "mneme-hq[mcp]"

Start the local stdio server with the proposal store enabled:

bash
mneme decision-mcp

Optionally add a canonical ADR corpus. Mneme validates and precedence-resolves the corpus before the server starts; invalid or ambiguous ADR state fails closed rather than serving a degraded authority view.

bash
mneme decision-mcp --adr-dir path/to/adrs

The MCP surface is intentionally frozen to six tools:

  • decision.propose
  • decision.propose_batch
  • decision.get
  • decision.search
  • decision.applicable_to
  • decision.trace

Proposal tools create non-authoritative proposals only. Read tools query proposal and canonical decision state. MCP deliberately exposes no accept, reject, activate, supersede, exception, bypass, or trusted-evidence authority.

Human authority remains explicit through mneme decision proposals | show | accept | reject. Accepting a proposal materializes a canonical decision; it does not activate protection or run the Architecture Audit.

See ADR-027 and the v0.9.0 release notes for the authority boundary and release contract.

Architecture Audit

See where your architecture is actually protected — and where it still depends on people remembering the rules.

Mneme audits your repository and shows which architectural decisions are:

  • Protected — already enforced mechanically
  • Mneme-ready — can be turned into a deterministic guardrail
  • Requires modelling — important, but not yet safe to automate
  • Guidance — useful context, but not something that should be enforced

Run an audit:

bash
mneme audit --memory .mneme/project_memory.json --repo-root .

For a Mneme-ready decision, validate the proposed protection before enabling it:

bash
mneme protect validate <decision-id> --memory .mneme/project_memory.json

Then explicitly activate it:

bash
mneme protect activate <decision-id> --memory .mneme/project_memory.json

Mneme only reports a decision as Protected after it can verify that real enforcement is in place. The full activation contract is documented in Protection Activation.

Try the Architecture Audit →

60-second enforcement example

Initialize a project-local decision corpus:

bash
mneme init

Record one architectural decision:

bash
mneme add_decision \
  --memory .mneme/project_memory.json \
  --id config-format \
  --decision "Use JSON for configuration files" \
  --scope config \
  --constraint "Use JSON only" \
  --anti-pattern "Do not use YAML"

Create a proposed input that violates it:

bash
python -c "import pathlib; pathlib.Path('prompt.txt').write_text('Set up a new YAML config file', encoding='utf-8')"

Run the deterministic check:

bash
mneme check \
  --memory .mneme/project_memory.json \
  --input prompt.txt \
  --query configuration

In strict mode, the prohibited YAML proposal returns a FAIL verdict and exit code 2. A compliant JSON proposal returns PASS and exit code 0.

The CLI is the common enforcement surface. Agent integrations translate their native events into the same Mneme decision and enforcement model.

Setup mode (no enforcement)

mneme setup initializes Mneme in a repository without changing how the team works: it creates or detects project memory, detects supported agent environments, and reports protection readiness — all without enabling any blocking enforcement. Setup never turns warn/observe behavior into blocking behavior; activation of preventive enforcement is always a separate, explicit decision.

bash
mneme setup

Optionally record an opaque Architecture Audit reference so the setup can be attributed back to a saved Audit baseline:

bash
mneme setup --audit-ref <reference>

Setup is idempotent: rerunning it against an existing Mneme project leaves valid configuration untouched.

How it works

text
Architectural decisions / ADRs
            |
            v
   structured decision corpus
            |
      +-----+--------------------+
      |                          |
      v                          v
relevant guidance       deterministic enforcement
   retrieval             + applicability checks
      |                          |
      +------------+-------------+
                   |
                   v
       workflow-specific boundary
                   |
      +------------+-------------+
      |            |             |
 pre-change     post-change      CI
   hooks          audit          gate

Mneme applies governance at the earliest reliable boundary a workflow exposes:

  1. Before generation when architectural context can be injected into the model call.
  2. Before supported file mutations when an agent exposes a blocking pre-tool hook.
  3. After bypassable mutations through bounded working-tree audits where shell/script writes cannot be inspected safely before execution.
  4. Before merge through CLI-based CI gates.

These boundaries are complementary. An integration only claims the surfaces that have been implemented and validated for that harness.

Retrieval is not enforcement

Decision retrieval answers: which architectural decisions are useful as guidance for this task?

Enforcement answers: does the proposed change violate a governed rule that applies here?

Those concerns are intentionally separated. See ADR-017, ADR-019, and ADR-020.

Supported surfaces

The authoritative support matrix lives in docs/integrations/README.md. The labels below are evidence levels, not interchangeable marketing terms.

Support levelSurface
Native integrationClaude Code
Native integrationClaude Agent SDK
Native integrationGoogle Antigravity
Native integrationCodex CLI
Native integrationKiro CLI 3.0 / v3
Validated compatibilityPaperclip — CLI and ACP transports, no adapter required
Rules exportCursor
CLI-based CI gateGitHub Actions, GitLab CI
ExperimentalOpenCode
PlannedDeep Agents middleware POC

Each integration documents its actual blocking boundary, bypass paths, degraded behavior, and validation evidence. Start with the integration matrix, not assumptions based on another harness.

ADRs and project memory

Mneme can compile architecture decisions into structured governance records rather than treating ADRs as passive prose.

The repository governance source of truth is .mneme/project_memory.json. The ADR import path preserves explicit source provenance where available so typed rules can be inspected and enforced consistently.

See:

Architecture guarantees

Three principles govern the current mechanism:

  • Deterministic > clever. Enforcement behavior must be reproducible.
  • Auditable > autonomous. A verdict should be traceable to the decision, rule, applicability state, and evidence that produced it.
  • Prevention before review. When a reliable pre-change boundary exists, use it; when it does not, surface the limitation and audit later rather than pretending the path is blocked.

The current Layer 1 scope, frozen surfaces, accepted amendments, experimental work, and deferred Layer 2 work are maintained in docs/architecture/current-phase.md.

Do not infer architecture from this README when a linked ADR or architecture document is more specific.

Benchmark and validation

Mneme's benchmark is a regression and integrity instrument for retrieval and enforcement behavior. It is not a general model-quality benchmark.

The benchmark keeps retrieval and enforcement scoring distinct so changes cannot silently improve one surface while regressing another.

See:

Demos

More examples: mnemehq.com/demo

Contributing

Before changing retrieval, enforcement, applicability, conflict handling, or benchmark semantics, read the architecture and ADRs that govern that surface.

Core behavioral changes may require the repository's charter-amendment procedure. Documentation, tooling, integrations, and examples do not automatically authorize changes to frozen behavior.

License

MIT. See LICENSE.

将 Mneme Decision MCP MCP 与多个 AI 模型配合使用

TypingMind 在工作区级别连接 MCP 工具,因此连接 Mneme Decision MCP 后,您就可以在 TypingMind 中搭配不同的 AI 模型使用,无需为每个模型单独设置。 此 MCP 通过您设备上的 TypingMind MCP 连接器在本地运行。

本地连接器设置指南

如果 MCP 服务器需要访问您电脑上的本地文件、应用或私有资源,请选择此方式。

1

打开 MCP 设置

在 TypingMind 中,依次前往“设置”、“高级设置”和“模型上下文协议”,然后选择“设置连接器”。

  1. 在您的浏览器中打开 TypingMind。
  2. 点击“设置”图标。
  3. 进入“高级设置”。
  4. 打开“模型上下文协议”部分。
  5. 点击“设置连接器”,然后选择“此设备”。
TypingMind MCP 连接器设置界面,已选择“此设备”
2

运行连接器命令

选择“此设备”,从 TypingMind 复制命令并在终端中运行。使用 MCP 时,请保持该进程运行。

  1. 复制 TypingMind 显示的设置命令。
  2. 在 macOS 上打开“终端”,或在 Windows 上打开 Windows Terminal。
  3. 粘贴并运行命令。
  4. 如果终端询问您是否继续,请确认安装软件包。
  5. 使用 MCP 工具时,请保持终端窗口及其中的进程运行。
3

将 Mneme Decision MCP 添加为服务器

当连接器状态为“就绪”时,点击“编辑服务器”,然后粘贴 MCP 服务器配置。

  1. 等待连接器状态显示为“就绪”。
  2. 点击“编辑服务器”。
  3. 粘贴 Mneme Decision MCP MCP 服务器配置。
  4. 保存服务器列表。
  5. 如需确认连接器是否仍处于就绪状态,请刷新。
TypingMind MCP 设置界面,显示正在运行的服务器和“编辑服务器”按钮
{
  "mcpServers": {
    "mneme": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

在不同模型中使用同一连接

保存服务器列表,打开“插件”,启用 Mneme Decision MCP MCP 工具,然后在 TypingMind 中选择任意受支持的 AI 模型,即可在聊天中使用这些工具,或将其分配给智能体。

  1. 在 TypingMind 中打开“插件”页面。
  2. 启用 Mneme Decision MCP MCP 工具。
  3. 开始聊天并选择您想使用的 AI 模型。
  4. 在聊天中使用 MCP 工具,或将其分配给 AI 智能体。
  5. 根据需要随时切换到其他 AI 模型,无需重新连接 MCP。
在 TypingMind 聊天中使用已启用的 MCP 工具和选定的 AI 模型
您能使用 Mneme Decision MCP 帮我完成这项任务吗?
Mneme Decision MCP
当然。我已阅读。
以下是我使用 Mneme Decision MCP 得到的结果。

常见问题

Mneme Decision MCP MCP 服务器有什么用途?

Mneme Decision MCP 是一个 MCP 服务器,可让兼容的 AI 客户端连接外部工具并获取上下文。在 TypingMind 中,只需添加一次此 MCP 服务器,即可在您的 AI 工作区中使用其工具。

可以在 TypingMind 中让多个 AI 模型使用 Mneme Decision MCP MCP 吗?

可以。TypingMind 在工作区层面连接 MCP 工具,因此您可以让 Claude、ChatGPT、Gemini 等不同 AI 模型,或您在 TypingMind 中配置的其他模型使用 Mneme Decision MCP,而无需为每个模型单独配置 MCP 服务器。

为什么在 TypingMind 中使用 Mneme Decision MCP MCP?

TypingMind 将多个 AI 模型、提示词、插件、AI 智能体、API 密钥和 MCP 工具整合到同一个工作区中,是优秀的大语言模型聊天前端之一。连接 Mneme Decision MCP 后,您可以在偏好的不同模型中使用其 MCP 工具,同时在 TypingMind 中井然有序地管理聊天工作流程。

如何将 Mneme Decision MCP MCP 连接到 TypingMind?

Mneme Decision MCP 通过 TypingMind 本地 MCP 连接器运行。当 MCP 服务器需要访问您计算机上的本地文件、桌面应用、命令行工具或私有资源时,这种方式最合适。

Mneme Decision MCP MCP 在 TypingMind 中提供哪些工具?

Mneme Decision MCP 提供 MCP 功能,您可以在 TypingMind 的插件页面启用这些功能,然后在聊天中使用,或将其分配给 AI 智能体。

使用 Mneme Decision MCP MCP 需要向 TypingMind 提供我的 API 密钥吗?

不需要。TypingMind 采用本地优先的设计,让您自行掌控模型提供商、API 密钥、提示词和 MCP 配置。如果 Mneme Decision MCP 需要身份验证,请在创建连接时,为该 MCP 服务器添加所需的请求头、OAuth 设置或本地配置。

相关 MCP 服务器

查看全部

立即创建您自己的 AI 工作区

订阅我们的电子简报,获取新功能和后续赠奖活动的通知 👇