Alethea
A local stdio MCP server that gives coding agents persistent, ADR-style decision and constraint memory stored as git-friendly markdown in .decisions/.
Record decisions or constraints with context, alternatives, consequences, status, file scopes, rules, tests, commits, requirements and supersession links.
Search records with BM25, returning active decisions/constraints by default and optionally including inactive or filtered statuses.
Get task context before starting work: in-scope active constraints plus the most relevant decisions for task text and/or file paths.
Supersede an existing decision/constraint, marking the old record
supersededand cross-linking both records.List active constraints, optionally filtered to those whose scope covers a given path.
Check a proposed change/diff/plan against constraint rules (
forbid, regex,require,forbid-path) and warn when it picks a rejected alternative.Link decisions to SpecGate requirement ids, test files and commit SHAs, with optional validation.
Expose resources for active constraints and individual decisions (
adm://constraints/active,adm://decisions/{id}).
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Alethea what decisions and constraints should I know before editing src/auth.ts?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Alethea of Agents (alethea)
Formerly agent-decision-memory (adm). The npm package is now @kurtfrancisco/alethea with commands alethea and alethea-mcp. The adm / adm-mcp commands, the MCP tool names, ADM_ROOT and the .decisions/ folder keep working.
Persistent decision and constraint memory for coding agents: a local stdio MCP server and CLI that store ADR-style decisions as git-friendly markdown, linked to Janus of Agents (formerly SpecGate) requirement ids, tests and commits.
Quickstart
Install (Node.js β₯ 20):
npm install -g @kurtfrancisco/alethea # provides `alethea` and `alethea-mcp` (plus legacy `adm` / `adm-mcp`)Claude Code
claude mcp add decision-memory -- npx -y -p @kurtfrancisco/alethea@0.2.1 alethea-mcpCursor β add to ~/.cursor/mcp.json (global) or .cursor/mcp.json (project). The same snippet works for Claude Desktop, VS Code and Windsurf:
{ "mcpServers": { "decision-memory": { "command": "npx", "args": ["-y", "-p", "@kurtfrancisco/alethea@0.2.1", "alethea-mcp"] } } }Restart the client and the tools appear. Full details below.
Coding agents forget what was decided between sessions. They bring back the library you removed last month, undo a trade-off nobody wrote down, and edit generated code. adm gives them a decision memory: a local stdio MCP server and a CLI that store ADR-style decisions and machine-checkable constraints as plain markdown in your repo's .decisions/ folder. Each record can be linked to SpecGate requirement ids, test files and commits.
Git-friendly storage. One markdown file per record, with JSON-valued frontmatter (valid YAML). Review it in PRs and edit it by hand.
No native dependencies. Search uses a pure-JS BM25 index, cached in
.decisions/.index.json(gitignored). The only runtime deps are@modelcontextprotocol/sdkandzod.Cross-platform. Node β₯ 20 on Windows, macOS and Linux. Paths are normalized, so
src\db\x.tsandsrc/db/x.tsmatch the same globs. No symlinks.
Related MCP server: Zenrei
Install (Windows PowerShell)
cd C:\path\to\agent-decision-memory
npm ci # uses the committed package-lock.json
npm run build # syntax check + import check
npm test
npm link # optional: puts `adm` and `adm-mcp` on PATHmacOS/Linux: run the same commands.
Register with Claude Code
claude mcp add decision-memory -- node C:\path\to\agent-decision-memory\bin\adm-mcp.jsThe server uses the current directory to find the repo: the nearest ancestor that has .decisions/ or .git/. To pin a repo, pass --root C:\repo or set $env:ALETHEA_ROOT = "C:\repo" (ADM_ROOT also works). A generic MCP client config looks like this:
{ "mcpServers": { "decision-memory": { "command": "node", "args": ["C:/path/to/agent-decision-memory/bin/adm-mcp.js", "--root", "C:/repo"] } } }Install the skill
Copy the skill folder into your project (or into $HOME\.claude\skills to use it everywhere):
New-Item -ItemType Directory -Force .claude\skills | Out-Null
Copy-Item -Recurse C:\path\to\agent-decision-memory\skills\agent-decision-memory .claude\skills\The skill tells the agent to call get_context_for_task before it starts, check_conflicts before it commits, and record_decision, supersede_decision or link_requirement after the work. See the Claude Code skills docs: https://code.claude.com/docs/en/skills.
MCP surface
Tool | Purpose |
| Record a decision (or |
| BM25 search. Returns active records only unless |
| For task text and/or file paths: in-scope active constraints, the top decisions (file-scope matches boosted) and their requirement ids |
| Write a replacement record. The old one becomes |
| Active constraints, optionally filtered to those whose scope covers a path |
| Check a proposed change (text or diff plus files) against constraint rules. |
| Attach SpecGate ids, test files and commit SHAs. Ids are checked against |
Resources: adm://constraints/active (markdown) and adm://decisions/{id} (JSON).
Constraint rules
forbid: axios (whole word, case-insensitive), forbid: /eval\(/ (regex), require: @req (the change text must contain it), and forbid-path: src/generated/** (glob on the touched files). A constraint applies only to its files scope; with no scope it covers the whole repo. A proposed constraint produces warnings. An accepted one produces errors.
CLI
adm init
adm record --title "Use date-fns" --decision "parseISO/format, ISO strings" --alternative "Moment.js: deprecated" --file "src/todos/**" --req todos/due-date
adm record --type constraint --title "No moment.js" --decision "bundle size" --rule "forbid: moment" --file "src/**"
adm context --task "validate due date" --file src/todos/create.ts
adm check --change-file .\my.diff --file src/todos/create.ts # exit code 1 on a violation (CI-friendly)
adm supersede D-0001 --title "Use Fastify" --decision "..."
adm link D-0002 --req todos/due-date#invalid-date-rejected --commit 1a2b3c4 --test test/todos.test.ts
adm search "http server" --all
adm import --dir docs/adr # Nygard (adr-tools) and MADR formats; idempotent
adm export --format json --out decisions.json # or markdown
adm serve # same as adm-mcpEvery command also takes --json and --root <dir>. Run npm run demo to see an end-to-end run: it records with the CLI and queries through a real MCP client over stdio.
Record format
---
id: "D-0002"
type: "decision"
title: "Use date-fns for dates"
status: "accepted"
date: "2026-10-15"
tags: ["dates"]
requirements: ["todos/due-date"]
files: ["src/todos/**"]
tests: []
commits: []
---
# D-0002: Use date-fns for dates
## Context
## Decision
## Alternatives
## ConsequencesStatuses: proposed, accepted, superseded, deprecated and rejected. Only proposed and accepted count as active. Supersession adds supersedes and superseded_by links.
SpecGate links
Requirement ids use the SpecGate 0.3 format: ### Requirement: Due date in openspec/specs/todos/spec.md becomes todos/due-date, and scenarios become todos/due-date#invalid-date-rejected. link_requirement reads openspec/specs/*/spec.md and openspec/changes/*/specs/*/spec.md. An unknown id is still linked, but you get a warning.
How it compares
Project | What it stores | Difference |
Knowledge graph of code structure | Indexes code, not the reasons behind it | |
Issue/task graph for agents | Tracks work items, not decisions or constraints | |
General AI memory (graph + vectors) | General-purpose, and needs a heavier stack | |
Temporal knowledge graphs | Needs a graph DB. Raw facts, no ADR structure | |
Entity/relation notes in a JSON file | Unstructured notes, no rules or conflict checks | |
User/agent memories | Personalization memory, not repo decisions | |
ADR markdown | Human-facing. No agent API, search or rule checks. |
Limitations
Conflict detection uses keyword, regex and glob rules. It does not understand meaning, so a rule like
forbid: momentwill not catch a paraphrase, and the rejected-alternative warning is a heuristic based on the alternative's name.BM25 is lexical (with light stemming). There are no embeddings, so synonyms are not matched.
IDs are allocated per machine (
max + 1). If two branches each record a decision, both can get the same number. Rename one by hand when you merge.The index is rebuilt in memory whenever any file's size or mtime changes. That is fine for hundreds of records but not tuned for tens of thousands.
License
MIT Β© 2026 Kurt Francisco
Contributing
Issues and pull requests are welcome at https://github.com/fpavia111-creator/alethea. See CONTRIBUTING.md.
Need an AI agent built for your business instead of tools to build your own? See G6daddy: AI agents for any industry.
Available Tools
7 toolscheck_conflictsCheck conflictsA
Check a proposed change (diff, plan or description, plus touched files) against active constraint rules. ok=false means an accepted constraint is violated.
Inputs: change (required), files.
get_context_for_taskGet context for taskA
Call BEFORE starting work. Returns active constraints in scope and the most relevant decisions for a task description and/or file paths.
Inputs: path, task, limit, paths.
link_requirementLink requirement/tests/commitsC
Link a decision to SpecGate requirement ids (capability/requirement[#scenario]), test files and/or commits.
Inputs: id (required), files, tests, commits, +2 more.
list_constraintsList constraintsC
List active constraints, optionally only those whose scope covers a path.
Inputs: path, include_inactive.
record_decisionRecord decision or constraintB
Record an ADR-style decision (or a constraint with type="constraint") into .decisions/. Call after making a non-obvious choice.
Inputs: title (required), tags, type, files, +10 more.
search_decisionsSearch decisionsA
BM25 search across decisions and constraints. Active (accepted/proposed) only unless include_inactive or status is set.
Inputs: query (required), type, limit, status, +1 more.
supersede_decisionSupersede decisionB
Replace an existing decision/constraint with a new one. The old record is marked superseded and both are cross-linked.
Inputs: id (required), title (required), tags, files, +9 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogβ¦
TDQS
Scored across 7 tools
Each tool has a distinct operation: record (write), supersede (replace), link (associate), check_conflicts (validate), plus several read paths. The read tools (search_decisions, list_constraints, get_context_for_task) overlap somewhat in retrieval purpose, but descriptions clarify their distinct scopes (BM25 search vs. constraint listing vs. task-oriented context assembly).
Every tool follows a consistent snake_case verb_noun pattern (record_decision, search_decisions, get_context_for_task, list_constraints, check_conflicts, supersede_decision, link_requirement). No mixing of conventions or vague verbless names.
Seven tools is well-scoped for an ADR/constraint management server, with each tool covering a genuine part of the decision lifecycle (capture, retrieve, validate, supersede, link). No redundant or filler tools.
Core lifecycle is well covered: record, search, list, supersede, conflict-check, and requirement linking. Minor gaps exist β there is no tool to change a decision's status (accept/reject/deprecate) without superseding it, and no delete/archive path β but supersede and record largely cover practical workflows.
Related MCP Connectors
Versioned memory for agents: markdown docs with history, safe concurrent commits, human claim links.
One memory for every AI you work with: your rules, notes and decisions in your own Git repo.
Project memory for software teams: decisions, root causes, fixes, failed approaches and conventions that Claude, Claude Code, Codex, Grok and other MCP clients can search and save, shared across your agents. Memroot receives only what the agent sends in a search or a save, never your conversations; for the full experience in coding agents (automatic memory checks and session capture), run npx memroot setup.
Give your AI agent persistent, governed memory for every project. At task start it recalls the approved decisions, conventions, risks and architecture (semantic search, ranked by importance); at close it proposes what was learned as typed memories that you review and approve β governance, not a notes dump. Agents propose, humans govern: edits go back to pending and deletion is human-only by design. Connect Claude Code, Cursor, Claude Desktop or any MCP client in two minutes with just your API key β hosted (nothing to install) or locally via `uvx solucortex-mcp`. Built by SoluAI and dogfooded daily: SoluCortex is developed using its own living memory.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceThe decision system for agentic engineering: keeps your project's decisions, rationale, and rejected paths in plain files and surfaces them to AI coding agents before they plan or change code.10Apache 2.0
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to store and retrieve design decisions as Markdown in git repositories, and check new proposals against historical decisions via MCP.MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI coding agents to read and manage a Git-native decision ledger, providing tools for querying decisions, evidence, cross-repository workspaces, validation, and commit tracing, all operating locally and without a cloud service.MIT
- AlicenseBqualityCmaintenanceEnables coding agents to record, search, and supersede ADR-style decisions and machine-checkable constraints stored as git-friendly markdown in a repository, linked to SpecGate requirement ids, tests and commits. It also surfaces the relevant constraints and decisions for a task and checks a proposed change or diff for conflicts before it is committed.75 npmMIT