Borrowing it
Nothing to install: this file belongs to GarryWhite109909/xmind-mcp-server. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/GarryWhite109909/xmind-mcp-server/main/AGENTS.mdgit clone --depth 1 https://github.com/GarryWhite109909/xmind-mcp-serverWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/garrywhite109909/xmind-mcp-server/agents-md)<a href="https://agentmods.dev/instructions/garrywhite109909/xmind-mcp-server/agents-md"><img src="https://agentmods.dev/badge/instructions/garrywhite109909/xmind-mcp-server/agents-md/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/instructions/garrywhite109909/xmind-mcp-server/agents-md"><img src="https://agentmods.dev/badge/instructions/garrywhite109909/xmind-mcp-server/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.01598 | $0.01598 |
| Opus 5.5 | $0.00639 | $0.00639 |
| Sonnet 5.5 | $0.00320 | $0.00320 |
| Haiku 4.5 | $0.00160 | $0.00160 |
Grade A, and why
xmind-mcp-server AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 103 lines — stays where its author put it; the contents beside it link to each section on GitHub.
XMind MCP Server — 项目规则
本地 MCP Server:解析 / 编辑 / 写回 XMind(JSON 格式),把节点图片作为 ImageContent 直接交给多模态模型。不包含 OCR,也不要重新引入 OCR、 模型推理、GPU 检测或启动时 pip 安装。
常用命令
# 创建环境并安装(开发)
python -m venv .venv
.venv/Scripts/python.exe -m pip install -e ".[dev]" # Windows
# .venv/bin/python -m pip install -e ".[dev]" # POSIX
# 跑测试(已有 .venv 时)
.venv/Scripts/python.exe -m pytest -q
# .venv/bin/python -m pytest -q
# 静态检查
.venv/Scripts/ruff.exe check src tests
# ruff check src tests
# 启动(stdio,给 MCP 客户端用)
xmind-mcp
xmind-mcp --info
xmind-mcp --toolset read
# 可选:用 XMind 官方 CLI 校验生成的结构(需要先登录)
xmind validate path/to/file.xmind
发布前至少跑:ruff check src tests 和 pytest -q。测试不允许联网、不允许依赖真实 XMind 安装。
目录地图
| 路径 | 职责 |
|---|---|
src/xmind_mcp/tool_schemas.py |
工具 schema、分组(TOOLSETS)、只读/破坏性标注 |
src/xmind_mcp/tools.py |
工具 handler、文件缓存、树格式化、SVG 导出 |
src/xmind_mcp/markdown_import.py |
Markdown → XMind 大纲解析与公式注入 |
src/xmind_mcp/xmind_parser.py |
解析 zip / content.json,节点树与 ID 索引 |
src/xmind_mcp/xmind_writer.py |
修改 raw_content、保存(备份 / 冲突检测 / 原子写) |
src/xmind_mcp/xmind_props.py |
中文样式名 → XMind 内部值的映射与校验 |
src/xmind_mcp/render.py |
自绘 PNG 预览 |
src/xmind_mcp/formula.py |
Markdown 块级公式 → PNG |
src/xmind_mcp/image_payload.py |
图片缩放 / JPEG / base64 负载 |
src/xmind_mcp/config.py |
~/.xmind-mcp/config.json |
src/xmind_mcp/cli.py |
启动、--info、--uninstall |
src/xmind_mcp/server.py |
MCP stdio 握手与 tools/list、tools/call |
tests/ |
pytest;test_golden.py 守住官方文件结构 |
硬约定
- 所有写操作走
XMindWriter。 不要直接重写 zip;save()负责备份、 跨进程冲突检测、清理过期缩略图、原子替换。 - 改完
raw_content必须调用xm.refresh_from_raw()。 节点树和find_topic的 ID 索引都由它重建;漏调用会让后续查询看到旧树。 - 保存前不要绕过冲突检测。 覆盖原文件时若磁盘摘要与
xm.source_digest不同,必须抛FileChangedError,让调用方另存。 - 工具要在五处登记:
tool_schemas.py的build_tool_list()、TOOLSETS、_READ_ONLY_TOOLS(只读工具)、_DESTRUCTIVE_TOOLS(会删/覆盖的工具), 以及tools.py的XMindTools._handlers。test_every_listed_tool_has_handler会抓漂移;工具总数变化时同步test_server.py和 README。 - 路径参数一律以
_path结尾。_guard_paths只校验这个后缀; 新工具如果叫file/target会绕过allowed_roots。 - 图片只走
types.ImageContent。 统一用prepare_image()缩放、转 JPEG、 控制体积;不要在工具里直接返回原始 base64。 - 版本号两处同步:
pyproject.toml与src/xmind_mcp/__init__.py。 - 配置向后兼容:
Config.load()忽略不认识的字段,旧的image_mode=ocr/both归一化为inline;不要因为旧配置报错。 - 用户数据默认保留: 备份目录
~/.xmind-mcp/backups/不随卸载删除; 删除/覆盖用户文件前先备份,并在返回文案里说明。 - 对外文案用中文,标识符用英文。 工具描述要告诉模型“什么时候用、 参数收什么”,不要写营销句。
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 103 lines · 1,598 tokens per session scan A 8f506cae3a90
xmind-mcp-server AGENTS.md is an instructions file published in the GitHub repository GarryWhite109909/xmind-mcp-server (0 stars, last pushed 2d ago), licensed MIT. It adds 1,598 tokens to every session, about $0.0064 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-09.
xmind-mcp-server AGENTS.md compared with instructions from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| xmind-mcp-server AGENTS.mdGarryWhite109909/xmind-mcp-server | Instructions file | 0 | 2d ago | MIT | A | 1,598 | Codex, OpenCode |
| vscode buildNext.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 9,719 | GitHub Copilot |
| next.js AGENTS.mdvercel/next.js | Instructions file | 143k | today | MIT | A | 7,461 | Codex, OpenCode |
| vscode oss-third-party-notices.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 5,649 | GitHub Copilot |
| langchain AGENTS.mdlangchain-ai/langchain | Instructions file | 149k | today | MIT | A | 4,680 | Codex, OpenCode |
| vscode copilot-instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 3,093 | GitHub Copilot |
| vscode model-prompts.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 2,022 | GitHub Copilot |