Context7
Up-to-date docs for AI agents
作者提供的说明(英文原文)
Read and write Claude Code auto memory from Codex, Cursor or any MCP client. Zero dependencies.
这三项永远不会合并成一个分数:意见、测量和人气是不同的东西。
我们还没有为它写通俗的介绍。下面是我们从注册中心读取到的事实。
选择你使用的 AI 应用,然后复制设置。
RECALL_READ_ONLY你需要
你用的是哪个应用?
在上方选择你的应用。我们会记住它,下次按钮会显示“安装到 …”。
打开 Claude Desktop → Settings → Developer → Edit Config,把下面的内容粘贴到 claude_desktop_config.json
{
"mcpServers": {
"recall": {
"command": "npx",
"args": [
"-y",
"@fainir/recall",
"--claude-code",
"{repo_path}"
],
"env": {
"RECALL_READ_ONLY": "your-value"
}
}
}
}在终端中运行这条命令
claude mcp add recall --env RECALL_READ_ONLY=your-value -- npx -y @fainir/recall --claude-code '{repo_path}'运行前请先填写空着的值。
粘贴到项目中的 .cursor/mcp.json,或 ~/.cursor/mcp.json
{
"mcpServers": {
"recall": {
"command": "npx",
"args": [
"-y",
"@fainir/recall",
"--claude-code",
"{repo_path}"
],
"env": {
"RECALL_READ_ONLY": "your-value"
}
}
}
}浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。
粘贴到项目中的 .vscode/mcp.json
{
"servers": {
"recall": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@fainir/recall",
"--claude-code",
"{repo_path}"
],
"env": {
"RECALL_READ_ONLY": "your-value"
}
}
}
}浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。
这个服务器在你的电脑上运行,而 ChatGPT 只能连接互联网上的服务器。请选择其他应用。
你的选择通过 Cookie 保存在这台设备上,无需账户。
RECALL_READ_ONLY env这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。
它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。
我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月7日
注册名称已通过 GitHub 账户 fainir 验证,该账户拥有此仓库
我们还没有从 GitHub 读取这个仓库
我们还没有从 GitHub 读取这个仓库
它在你的电脑上运行,没有互联网端点
在你的电脑上运行,改用本地设置
它在你的电脑上运行;我们只能读取互联网端点的工具列表
与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。
它在 1 项适用的基础检查中通过了 1 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。
注册中心没有列出必需的密钥,不过有些服务器会在首次使用时要求你登录。
它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。
GitHub 仓库最后更新于–,最新版本(0.3.0)于6天前进入注册中心。
支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Node.js。
同一分类中有:Context7, Codebase Memory, Exa
同一分类中其他作者的服务器,按星标数排序。
如何看卡片:★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i
Up-to-date docs for AI agents
Codebase knowledge graph for AI agents — 162 languages, sub-ms queries, 99% fewer tokens.
Connect AI agents to Exa for web search, content fetching, and multi-step research.
按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。
Your Claude Code memory, in every agent. recall reads and writes the memory Claude Code keeps for each project, so Codex, Cursor or an agent you build yourself can use the same memories, over MCP or from code. Zero dependencies, no vectors, no database: the memories stay plain Markdown files.
Claude Code now remembers things on its own: your corrections, how you like to work, project decisions, where things live. It saves them as Markdown files with [[wiki-links]] under ~/.claude/projects/ /memory/. That is a good format, but only Claude Code reads it. Switch to another agent and it starts from zero.
recall makes that memory portable. It finds the same directory Claude Code uses (same rules, down to its folder-naming hash), reads every file Claude Code writes, and writes files Claude Code reads back.
Point any MCP client at recall and the project's repository. --read-only lets the other agent read what Claude Code remembers without changing it; leave it off to let both write.
Codex
codex mcp add recall -- npx -y @fainir/recall --claude-code /path/to/your/repo --read-only
Cursor (.cursor/mcp.json in the project, or ~/.cursor/mcp.json)
{
"mcpServers": { "recall": { "type": "stdio", "command": "npx", "args": ["-y", "@fainir/recall", "--claude-code", "/path/to/your/repo", "--read-only"] } } }
Cline: in the MCP Servers panel choose Configure, and add the same recall entry as for Cursor to cline_mcp_settings.json. Or ask Cline to "set up the MCP server from https://github.com/fainir/recall": in a test on 2026-11-01 it read this README, added the entry, started the server and listed its tools.
Gemini CLI: gemini extensions install https://github.com/fainir/recall (it serves the memory of the folder you start Gemini in).
Any other MCP client: run npx -y @fainir/recall with the same arguments as a stdio server. Needs Node.js 18+.
The agent then has these tools. Here is a real run against a repository with three memories Claude Code wrote:
> memory_list
3 memories in /Users/you/.claude/projects/-Users-you-code-acme-api/memory:
memory_recall {"requires": ["feedback_testing"]}
Run npm run test:int (needs the local Postgres from docker compose), not just npm test. Why: the unit tests mock the database; two "done" changes broke prod queries. How to apply: any change under src/db/ or src/queries/. CI details in [[reference_ci]].
CI is GitHub Actions, workflow ci.yml. Rerun a flaky job with gh run rerun --failed.
tokens_used: 180
memory_recall followed the [[reference_ci]] link on its own. In testing, a Codex agent given only this server answered a question by calling memory_list and then memory_get.
| Tool | What it does |
|---|---|
memory_list | Every memory with its type and one-line description. Optional type filter. |
memory_get | One memory in full. feedback-testing and feedback_testing both work. |
memory_recall | The named memories plus the ones they [[link]] to, trimmed to a token budget. Unknown names come back as missing. |
memory_due | Memories old enough to re-confirm before relying on them. |
memory_write | Save or replace a memory in Claude Code's format, and add it to the MEMORY.md index. Not offered with --read-only. |
memory_delete | Delete a memory and its index line. Not offered with --read-only. |
recall-mcp options: --claude-code [repo] (the default, using the current directory), --dir for any other memory directory (add --format claude-code to write Claude Code's file format there), --read-only, and --allow-secrets. RECALL_DIR, RECALL_READ_ONLY=1 and RECALL_ALLOW_SECRETS=1 work as environment variables.
npm install @fainir/recall
import { Recall } from '@fainir/recall';
const memory = Recall.forClaudeCode('/Users/you/code/acme-api'); console.log(memory.dir);
for (const m of await memory.list()) console.log(m.name, '|', m.type, '|', m.description);
const slice = await memory.recall({ requires: ['feedback-testing'] }); console.log(slice.memories.map(m => m.name), slice.tokens_used);
// Save something Claude Code will see in its next session. await memory.write({ name: 'project_freeze', type: 'project', description: 'merge freeze until the 3rd for the mobile release', body: 'No merges to main until Nov 3. Why: mobile release cut.', });
Output (before the write):
/Users/you/.claude/projects/-Users-you-code-acme-api/memory
feedback_testing | feedback | run the integration suite before saying a change works reference_ci | reference | where CI runs and how to rerun a flaky job user_role | user | backend lead, prefers short answers with the command to run [ 'feedback_testing', 'reference_ci' ] 180
write() produces the file Claude Code itself writes:
---
name: project_freeze description: merge freeze until the 3rd for the mobile release metadata: node_type: memory type: project modified: 2026-10-27T17:51:14.486Z
No merges to main until Nov 3. Why: mobile release cut.
and adds a line to MEMORY.md, the index Claude Code loads at the start of every session, leaving the existing lines alone:
- [Testing](feedback_testing.md) - run the integration suite before saying a change works
Rewriting an existing memory keeps the fields recall does not own, such as Claude Code's originSessionId.
claudeCodeMemoryDir(repo) returns the directory, using Claude Code's rules:
a-z, A-Z and 0-9 turned into -. Paths longer than 200 characters are cut and given the same hash suffix Claude Code adds.CLAUDE_CONFIG_DIR replaces ~/.claude. CLAUDE_CODE_PROJECT_DIR_NAME (next to CLAUDE_CONFIG_DIR) names the folder. An autoMemoryDirectory setting in the project's .claude/settings.local.json or your ~/.claude/settings.json wins over both.This was checked against a real ~/.claude/projects folder: the rule reproduced 40 of 41 project folder names, including all three long, hashed ones (the other one belonged to a session that was moved after it started). recall listed and parsed all 194 memory files in it.
The package exports the Recall class and claudeCodeMemoryDir(). Every method is async.
| Call | Arguments | Returns | ||||||
|---|---|---|---|---|---|---|---|---|
Recall.forClaudeCode(repo) | path inside a project; default the current directory | a Recall on Claude Code's memory directory, in claude-code format | ||||||
new Recall({ dir, format }) | dir: memory directory. format: recall (default) or claude-code | a Recall instance | ||||||
write({ name, type, description, decay_class, body, extra }) | name: slug (required). type: user \ | feedback \ | project \ | reference (required). description: one line, default ''. decay_class: permanent \ | slow \ | fast \ | ephemeral, default slow. body: Markdown, default ''. extra: more frontmatter fields | { name, type, decay_class, updated_at }. Creates or replaces / .md; in claude-code format also updates MEMORY.md |
get(name) | a memory name; - and _ are interchangeable, and a frontmatter name also matches | a Memory, or null | ||||||
list({ type }) | optional type filter | Memory[], sorted by name | ||||||
recall({ requires, link_depth, budget_tokens }) | requires: names. link_depth: [[link]] hops to follow, default 1. budget_tokens: default 2000 | { memories: Memory[], tokens_used, missing: string[], dropped: string[] } | ||||||
dueForReview(asOf) | Date or date string, default now | Memory[] past their review window, each with age_days | ||||||
delete(name) | exact memory name | true if a file was removed, false if it did not exist | ||||||
claudeCodeMemoryDir(repo) | path inside a project | the directory path (it may not exist yet) |
A Memory is { name, type, description, updated_at, frontmatter, body, links }. type and updated_at come from the flat fields or from Claude Code's metadata: block, whichever the file has. links lists the memory names the body links to, deduplicated and in order.
write, get and delete throw on an unsafe name; write also throws on an invalid type or decay_class, a non-string body or description, or a reserved extra key. recall never throws on unknown names; it lists them in missing.
One file per memory, .md, with frontmatter and a Markdown body. recall reads both shapes, whichever format you pick for writing.
Claude Code's format (format: 'claude-code'; older Claude Code files have a flat type: instead of metadata:, and recall reads those too):
---
name: feedback_testing description: run the integration suite before saying a change works metadata: node_type: memory type: feedback modified: 2026-10-20T09:12:44.120Z
Run npm run test:int first. CI details in [[reference_ci]].
recall's own format (format: 'recall', the default, which earlier versions wrote):
---
name: top-customers type: project description: paying customers above $10K ACV decay_class: slow updated_at: 2026-05-25
a-z, 0-9, - and _, starting with a letter or digit, up to 128 characters. That keeps file names safe on every OS.[[name]], [[name|label]] and [[name#heading]] all point at name. They are case-insensitive, - and _ match each other, and links inside code are ignored.key: value lines, quoted strings, # comments, and one level of nesting (Claude Code's metadata: block).MEMORY.md, README.md, My Notes.md, folders) are not memories and are skipped.recall() picks the slicerequires. No embeddings, no fuzzy search.[[wiki-links]] from those, breadth-first, up to link_depth hops.budget_tokens (estimated as characters / 4), memories are dropped until只显示了开头部分;其余内容请在仓库中阅读