
Minnimemory
io.github.MinniAI-com由 GitHub 账号 MinniAI-com 发布v1.4.2更新于 Nov 7, 2026
Curated, on-demand memory for AI coding agents. Cuts Claude Code token cost per session.
概览
本地 MCP 服务器,审计 Claude Code 项目的记忆文件,并编译成精简的常驻记忆与按需加载的记忆片段。
- 可以做什么
- 审计并列出 Claude Code 在项目中加载的记忆文件
- 预览编译方案并执行,返回需用户批准的命令
- 检查上次执行后的漂移并生成重新执行方案
- 用 undo 按字节还原原始记忆文件
- 通过钩子在提示中附加匹配的记忆片段,跳过疑似凭据的行
- 适用场景
- 当 Claude Code 项目的 CLAUDE.md、AGENTS.md 或记忆文件夹变得臃肿,想降低每轮会话的 token 成本又保留可还原的原文件时适用。也适合定期检查记忆文件是否发生漂移。
- 运行要求
- 以 Claude Code 插件(或 npm 包 minnimemory)形式通过 stdio 在本机运行。需要 Claude Code 可见的 PATH 中有 Node.js 18.3 或更高版本,一键安装插件还需 Claude Code 2.1.275 或更高版本。仅限桌面端,在 claude.ai 网页对话中不生效。未声明任何 API 密钥或环境变量。
安装
在 SourceWeft 中
- 打开 控制台中的 Minnimemory,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
MinniMemoryMCP for Claude Code
MinniMemoryMCP 1.4.2 as a Claude Code plugin. It audits the memory files Claude Code loads
(CLAUDE.md, AGENTS.md, your memory folder) and compiles them into a small AlwaysOnMemory
body that loads every turn, plus OnDemandMemory files that load only when a task needs them.
Every change is lossless and undoable: the originals are backed up first and undo puts them
back byte for byte. Everything runs on your machine, on your own files, only when you ask.
Built by MinniAI.
Requirements
- Node.js 18.3 or later on your PATH. The server and the hooks run with
node. Claude Code's own installer does not need Node, so check withnode --versionfirst. - Claude Code 2.1.275 or later for the one-line install below; older versions add the marketplace first (the shell form under it).
Install
Or from your shell: claude plugin marketplace add MinniAI-com/minnimemory-plugin, then
claude plugin install minnimemory@minniai.
The plugin loads in Claude Code, and in Cowork when the session runs on your computer. In claude.ai chat it is ignored: a local MCP server and hooks do not run there.
Pick one route per machine. If you ran npx minnimemory install before, run
npx -y minnimemory uninstall first: otherwise the server is registered twice and every prompt
starts two copies of each hook (the second copy stays silent, but you pay its start).
Use
Three prompts cover the whole loop, in your project in Claude Code:
- "Clean up my memory with minnimemory." Claude calls
init, which shows the map of what Claude Code loads here, the audit and the changeapplywould make. It writes nothing but a small record of where your memory loads from. - "Apply it." Claude calls
apply, which hands back one command and the list of file operations; the command runs only through your approval prompt. - A week later, "check my memory." Claude calls
doctor, which shows what drifted and the re-apply plan; "undo the memory compile" restores the originals.
The same four steps are slash commands: /mcp__minnimemory__init, doctor, apply, undo.
What it runs, reads, writes and sends
- An MCP server (
node server/cli.mjs mcp) with four tools:init,doctor,apply,undo. It reads only the folder a tool call names and the files you or Claude tell it Claude Code loads; nothing is searched for.applyandundoreturn a command and the list of file operations, and Claude runs that command only with your approval. The command isnode "<plugin folder>/server/cli.mjs" apply --plan <hash> <folder>: the plugin's own file, never a download. - Three hooks. Before each prompt,
driftchecks whether your memory changed since the last apply and prints one line when it did;hookadds the one short section of memory that matches the prompt, inside a block marked as data, once per session, and never a section that holds a credential-shaped line (it says so instead). The prompt hook's saving was measured in live Claude Code sessions on our own memory folder (the number is on the docs page); on other folders it is unmeasured. When Claude Code loads its instructions,loadedrecords which file it loaded in a local log thatinitcan read later. - Also in the bundle, never run by the plugin.
server/cli.mjsis the npm package's command line, so it also contains theinstallanduninstallcommands of the npx route, which runclaude mcp addandclaude mcp removeand write the npx form of the hooks into your settings, and amcp --profile fullmaintainer mode with six more tools (recall, outline, list, audit, plan, compile). The plugin starts the server withmcpalone, the four-tool profile above; nothing in the plugin calls the rest. They are there for someone who runs the file by hand. - What "memory" means here. Your own files on disk:
CLAUDE.md, the files it imports, and the memory folder Claude Code keeps for a project, read only when you point a tool at them. The plugin never reads chat history, conversation summaries or uploaded files.
Try it on a sample first
examples/CLAUDE.md in this folder is a fictional project's memory file. Copy it into an empty
folder, open Claude Code there and say "Clean up my memory with minnimemory", then "Apply it",
then "undo the memory compile". That is the whole loop on a file you cannot break.
Security reports
Report a vulnerability to [email protected] or as a GitHub issue on this repository; both are read by the maintainer. The plugin makes no network calls, so most reports will be about what it reads or writes on disk.
- What it writes, and where. Under your Claude config folder (
~/.claudeunlessCLAUDE_CONFIG_DIRsays otherwise):minnimemory/discovery.json(where your memory loads from, written byinit),minnimemory/loads/<project>.jsonl(the load log),minnimemory/hook-sessions/<session>.json(which sections the prompt hook already placed), andminnimemory/undo-backups/(a copy of what a forced undo discards). In a compiled project or memory folder:.minnimemory/holds the backups the apply command makes and a small drift stamp. No memory file is ever written by the server itself. - Nothing is sent anywhere. The plugin makes no network requests, calls no model and collects no data. The only data it reads from your session is the prompt text the hook matches against your memory, and that is not stored.
Troubleshooting
- "hook failed to start" on every prompt, or the server does not connect. Node is missing or not on the PATH Claude Code sees. Install Node 18.3 or later; a Claude Code started from a desktop launcher may need a restart after the install so it picks up the new PATH.
- The prompt hook never adds anything. It places a section only when it clearly matches the
prompt, is small enough to be cheaper placed than read, and is not already in the always-loaded
body. A tiny or uncompiled memory gives it nothing to place; run
initandapplyfirst. - Two servers named minnimemory. You have both the npx install and the plugin. Run
npx -y minnimemory uninstalland restart Claude Code. applysays the plan hash does not match. A memory file changed since the preview. Rundoctorfor a fresh plan, thenapplyagain.
Issues: https://github.com/MinniAI-com/minnimemory-plugin/issues. Documentation: https://minniai.com/minnimemorymcp/docs.
Updates
Turn on auto-update for the minniai marketplace in /plugin, or run
claude plugin update minnimemory@minniai. A new version loads on the next launch
or after /reload-plugins.
Company admins: keep auto-update off and pin the version in managed settings when every machine must run the same release.
Remove
claude plugin uninstall minnimemory@minniai. Compiled memory stays compiled;
run undo first if you want the originals back. The small records under
<config>/minnimemory/ stay too; delete that folder if you want nothing left.
Licence
See LICENSE. Third-party code bundled in server/ is listed with its licences in
THIRD_PARTY_NOTICES.md.
来源:README.md,提交 5f248ef
工具
0版本历史
3- v1.4.2最新Nov 7, 2026
- v1.4.1Oct 29, 2026
- v1.3.7Oct 22, 2026
评分
已满足适用检查项的 40%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分
请在仓库或注册中心条目中声明许可证。
