XMind to Markdown MCP Server
将 XMind 思维导图文件转换为 Markdown 格式的 MCP (Model Context Protocol) 服务。
✨ 特性
- 🚀 快速转换:将 XMind 文件转换为结构化的 Markdown 文档
- 📊 保留层级:完整保留思维导图的层级结构
- 🏷️ 支持元数据:可选包含文件元信息(大小、时间等)
- 🔧 双工具支持:提供转换和结构查看两种工具
- 🌐 MCP 协议:标准化的 AI 工具接口,易于集成
📦 安装
使用 uvx(推荐)
uvx xmind-to-markdown-mcp
使用 pip
pip install xmind-to-markdown-mcp
🚀 快速开始
作为 MCP Server 使用
在支持 MCP 的客户端(如 Claude Desktop、Cursor、Cline)中配置:
{
"mcpServers": {
"xmind-to-markdown": {
"command": "uvx",
"args": ["xmind-to-markdown-mcp"]
}
}
}
可用工具
1. convert_xmind_to_markdown
将 XMind 文件转换为 Markdown 格式。
参数:
xmind_path(必需): XMind 文件路径output_path(可选): 输出 Markdown 文件路径,不提供则自动保存到output/目录include_metadata(可选): 是否包含文件元信息,默认true
示例:
{
"xmind_path": "/path/to/file.xmind",
"output_path": "/path/to/output.md",
"include_metadata": true
}
2. read_xmind_structure
读取并返回 XMind 文件的结构化数据(JSON 格式)。
参数:
xmind_path(必需): XMind 文件路径
示例:
{
"xmind_path": "/path/to/file.xmind"
}
📝 Markdown 转换格式
转换后的 Markdown 采用以下层级结构:
# [中心主题]
## [一级分支1]
- 子主题1.1
- 详细内容1.1.1
- 详细内容1.1.2
- 子主题1.2
## [一级分支2]
- 子主题2.1
> 备注:这里是XMind中的备注内容
- 子主题2.2
---
**文件元信息**
- 文件名: example.xmind
- 文件大小: 15.32 KB
- 创建时间: 2025-01-01 10:00:00
- 修改时间: 2025-01-02 15:30:00
🔧 客户端配置示例
Claude Desktop (macOS)
编辑 ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"xmind-to-markdown": {
"command": "uvx",
"args": ["xmind-to-markdown-mcp"]
}
}
}
Cursor IDE
在项目的 .vscode/settings.json 中添加:
{
"mcp.servers": {
"xmind-to-markdown": {
"command": "uvx",
"args": ["xmind-to-markdown-mcp"]
}
}
}
Cline (VS Code Extension)
在 Cline 的 MCP 设置中添加:
{
"xmind-to-markdown": {
"command": "uvx",
"args": ["xmind-to-markdown-mcp"]
}
}
🛠️ 开发
克隆仓库
git clone https://github.com/yourusername/xmind-to-markdown-mcp.git
cd xmind-to-markdown-mcp
安装开发依赖
pip install -e ".[dev]"
运行测试
pytest
📄 许可证
本项目采用 MIT 许可证 - 详见 LICENSE 文件
🤝 贡献
欢迎贡献!请随时提交 Pull Request。
📮 联系方式
- GitHub Issues: 提交问题
- Email: your.email@example.com
🙏 致谢
- FastMCP - MCP 服务框架
- xmindparser - XMind 文件解析库
- Model Context Protocol - MCP 协议规范
Metadata
Release files for xmind-to-markdown-mcp 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| xmind_to_markdown_mcp-0.1.3.tar.gz | 7.7 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| xmind_to_markdown_mcp-0.1.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 17.5 kB
Release files / xmind_to_markdown_mcp-0.1.3.tar.gz
| Download URL | xmind_to_markdown_mcp-0.1.3.tar.gz |
|---|---|
| Size | 7.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
09525d1a893fd958c5160d1f55abc97a69f64ac75dc47f362f82b017bc9b9b96
|
|
BLAKE2b-256 checksum How to use checksums |
b364f82bc935f0c682e3b862f9990384246b725462d8bd63ff05e57afe551f6f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.7
|
Release files / xmind_to_markdown_mcp-0.1.3-py3-none-any.whl
| Download URL | xmind_to_markdown_mcp-0.1.3-py3-none-any.whl |
|---|---|
| Size | 9.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
de18158ddcd78c4723ae292a575831e5ac8a4c0bfe977a7d264eda5f4e9655de
|
|
BLAKE2b-256 checksum How to use checksums |
a727634cd27a7784226403d13c34604c7b7ea186f467d13f3df42bc54a5653cc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.7
|
Security for xmind-to-markdown-mcp 0.1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.