
Ctxfile
dev.ctxfile由 ctxfile.dev 發布v0.6.0更新於 Oct 24, 2026
Local-first MCP server that snapshots your project's working state into one context object.
概覽
本地優先的 MCP 伺服器,把專案的工作狀態快照成一個情境物件,讓任何 MCP 代理一次呼叫就能載入。
- 可以做什麼
- 把專案快照成一個結構化情境物件:計畫文件、依 token 預算排序的關鍵檔案、git 狀態,以及選用的 Notion 頁面與本機模型摘要
- 儲存與續接工作階段:保存代理撰寫的摘要,並把附來源標註的合併歷史交給下一個代理
- 管理執行緒:為一項工作提供持久識別,交接模式會強制產生完整的接手包
- 匯入助理記憶到全域或專案範圍,指令與身分資訊需經你核准
- 張貼、列出與更新任務,讓一個代理留給另一個代理,需你核准
- 透過受結構約束的入口接收任何用戶端的情境,並匯出靜態產物供雲端代理與 CI 使用
- 適用情境
- 適合在多個 AI 代理或編輯器之間切換、每次冷啟動都要重新說明計畫、關鍵檔案與 git 狀態的情況。它讓一個代理儲存工作階段、另一個接著做,並為託管或 CI 代理提供可攜的情境產物。
- 執行需求
- 以本機 stdio 程序執行,通常透過 npm 套件 ctxfile 的 npx 啟動;需要 Node 20 以上(Windows 需 22 以上)。Claude Desktop 安裝包目前僅支援 macOS Apple Silicon。選用的 NOTION_TOKEN 可啟用 Notion 連接器,其他連接器需明確設定才會啟用。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Ctxfile,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
ctxfile
One context, every agent, all local.
[CI] [npm] [Apache-2.0] [MCP] [GitHub stars]
Website · Docs · Quickstart · Clients · The .ctxfile convention · Security
You work with more than one AI agent. Claude Code in the terminal, Cursor in the editor, a chat tab for thinking. Each one starts cold, because your working state (the plan, the key files, the git state, what you decided an hour ago) lives in your head and in scrollback.
ctxfile is a local-first MCP server that snapshots your project's working state into one structured context object, and hands it to any MCP agent in a single call. Save a session in one agent, continue it in another. Nothing leaves your machine.
30-second quickstart
Every client on your machine at once
Or tell any coding agent: "Set up ctxfile for me by following https://ctxfile.dev/setup.md".
Claude Code (as a plugin, or one command)
Cursor (.cursor/mcp.json in your project, or ~/.cursor/mcp.json globally)
Codex CLI
Claude Desktop (no terminal needed): download ctxfile-macos-arm64.mcpb and drag it into Settings → Extensions. The bundle carries a compiled native module, so it is macOS (Apple Silicon) only for now; on Windows or an Intel Mac, add the stdio JSON above to claude_desktop_config.json instead.
Every other client: ctxfile is a standard stdio server, so npx -y ctxfile is the whole command. One-click install links and copy-paste setup for VS Code, Windsurf, Zed, Cline, Gemini CLI, OpenCode, Warp, Goose, LM Studio, Kiro, JetBrains, Visual Studio, Amp, OpenClaw, Hermes, and more are on the per-client tabs at ctxfile.dev/docs/clients.
Then, in your agent: "load my context" (or call get_context). Requires Node ≥ 20 (≥ 22 on Windows).
Make it automatic
You stop typing "save this." One command installs a skill that teaches any agent, while doing its normal work, when to checkpoint context and to announce every save (never silent, paused any time, reviewable always):
It renders from one canonical spec into whatever each harness reads: an Agent SKILL.md for Claude Code, OpenCode, OpenClaw, and Hermes (one portable file across all four skill systems), a Cursor rule, and managed GEMINI.md / AGENTS.md blocks. Details at ctxfile.dev/docs/automatic.
It follows you into the chat tabs, too
The same context your CLI and editor agents load over MCP can travel to web chatbots. Connect Grok, ChatGPT, Claude web, or Perplexity to your encrypted Sync vault as a custom MCP connector, or ctxfile export and paste the envelope into any prompt box (Gemini, and anything else). Walkthrough: ctxfile.dev/docs/webchat.
Private by default
This is the part we care about most, so it goes first:
- The default path makes zero network calls. Files and git only.
- Secret-looking content (cloud keys, tokens, private keys, JWTs,
password=assignments) is redacted before it enters the snapshot..env*, key files, and credential files are never read at all. - Core is read-only over your project. It never writes to your repo, your git state, or anything else.
- No telemetry by default. An anonymous weekly install ping exists, and it is opt-in only.
- Network connectors (Notion, local Ollama summarization, Sync) activate only when you explicitly configure them.
The full model, including what Pro and Sync add and what they can never see, is documented at ctxfile.dev/security.
What it does
The monorepo
Open core, honestly
Everything in this repo is Apache-2.0 and works standalone, forever. The paid Pro add-on (a separate, closed package) adds session connectors that read your recent sessions from Claude Code, Cursor, Codex CLI, OpenCode, Gemini CLI, Aider, OpenClaw, and Hermes Agent, encrypted cross-session memory, multi-provider consult (Anthropic, OpenRouter for hundreds of models on one key, any OpenAI-compatible endpoint, or local Ollama), AI-distilled prompt Playbooks, and local voice capture. Licensing is an Ed25519-signed key verified offline. No phone-home, ever. Pro funds the open-source work.
Contributing
We want your issues, your PRs, and your weird harness reports. Start with CONTRIBUTING.md. Every ingested format, every MCP client quirk, every redaction gap you find makes the whole thing better.
- Bugs and features: issues
- Questions and show-and-tell: discussions
- Security reports: SECURITY.md (please do not open public issues for vulnerabilities)
Star history
If ctxfile saves you a cold start, a star is how other people find it.
[Star history chart]License
Apache-2.0. "ctxfile" and the ctxfile logo are trademarks of ctxfile; the license covers the code, not the name.
來源:README.md,提交 fc1dcca
工具
0版本歷史
2- v0.6.0最新Sep 26, 2026
- v0.5.0Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分