\[!警告\] 已弃用: 该MCP将不再进一步开发。请使用Codex/Claude技能https://github.com/robertZaufall/mindm-skill相反。
MindManager MCP服务器
模型上下文协议(MCP)服务器实现 mindm 该库提供了一个标准化的界面,用于在Windows和macOS上与MindManager进行交互。
&style=for-the-badge&color=blue>)](https://pypi.org/project/mindm-mcp/) &style=for-the-badge&color=lightblue>)](https://pypi.org/project/mindm/)
概述
此服务器允许您通过模型上下文协议(MCP)以编程方式与MindManager交互,MCP是一种为LLM提供上下文和工具的标准化方式。它利用了 mindm 库来操纵MindManager文档、主题、关系和其他思维导图元素。
动画示例(在Windows上的VSCode中使用Codex)
- 示例
细化单个主题,包括新主题的标签、图标:
_将当前的Mindmanager思维导图设置为美人鱼(完整),将给定的主题细化至少两个层次(不仅仅是主题),在3个最重要的主题上添加一个标签“重要”,并在除中心主题外的每个主题上添加相应的股票图标,然后创建新的Mindmanager思维导图_
- 示例
细化单个主题,包括在新主题的注释中生成文本: MindManager MCP in Codex
- 示例
克隆包括所有支持的主题属性的映射: MindManager MCP in Codex
其他示例
客户端
get the current MindManager mindmap, translate every topic to German and create a new MindManager mindmap (simple).
get the current MindManager mindmap, refine each topic 2 levels and create a new MindManager mindmap (simple).
外壳:
codex exec "get the current MindManager mindmap, add a meaningful emoji to every topic and create new MindManager mindmap (simple)"
_备注:表情符号仅适用于macOS。_
特性
- 检索思维导图结构和中心主题
- 将思维导图导出为Mermaid、Markdown、JSON格式,用于LLM聊天
- 直接从Mermaid创建MindManager思维导图(完整或简化语法)
- 获取MindManager和包版本以进行快速诊断
- 获取有关MindManager安装和库文件夹的信息
- 从MindManager获取当前选择
计划功能
- 添加、修改和操作主题和子主题,无需Mermaid往返
- 添加主题之间的关系
- 为主题添加标签
- 设置文档背景图像
需求
- Python 3.12或更高版本
mcp包(模型上下文协议SDK)mindm图书馆(包含在本项目中)- 安装在Windows或macOS上的MindManager(支持的版本:23-)
安装macOS
# Clone the repository (if you're using it from a repository)
git clone https://github.com/robertZaufall/mindm-mcp.git
cd mindm-mcp
# create a virtual environment for Python
brew install uv # if needed
uv pip install -r pyproject.toml
# alternative: manual installation of modules
uv add "mcp[cli]"
uv add fastmcp
uv add markdown-it-py
uv add -U --index-url=https://test.pypi.org/simple/ --extra-index-url=https://pypi.org/simple/ mindm mindm-mcp安装窗口
# Change to DOS command prompt
cmd
# Clone the repository (if you're using it from a repository)
git clone https://github.com/robertZaufall/mindm-mcp.git
cd mindm-mcp
# create a virtual environment for Python
pip install uv # if needed
uv pip install -r pyproject.toml
# install nodejs
choco install nodejs # if you have chocolatey installed. If not install nodejs otherwise
refreshenv
node -v
npm install -g npx用法
MCP检查员
# run mcp with inspector
uv run --with mind --with fastmcp --with markdown-it-py mcp dev mindm_mcp/server.py克劳德桌面版
本地python文件
根据需要调整本地文件的路径。
{
"mcpServers": {
"mindm (MindManager)": {
"command": "uv",
"args": [
"run",
"--with",
"mindm>=0.0.5.3",
"--with",
"fastmcp",
"--with",
"markdown-it-py",
"/Users/master/git/mindm-mcp/mindm_mcp/server.py"
]
}
}
}来自包存储库的模块
调整 VIRTUAL_ENV 根据需要。
{
"mcpServers": {
"mindm (MindManager)": {
"command": "uv",
"args": [
"run",
"--with",
"mindm>=0.0.5.3",
"--with",
"mindm-mcp>=0.0.2.1",
"--with",
"fastmcp",
"--with",
"markdown-it-py",
"-m",
"mindm_mcp.server"
],
"env": {
"VIRTUAL_ENV": "/Users/master/git/mindm-mcp/.venv"
}
}
}
}提示:如果MCP服务器在Windows上没有显示锤子图标,请关闭Claude Desktop并杀死所有后台进程。
Codex(VSCode扩展/CLI)
本地python文件
config.toml (根据需要调整本地文件的路径)。
[features]
rmcp_client = true
[mcp_servers.mindmanager]
command = "uv"
args = ["run", "--with", "mindm>=0.0.5.3", "--with", "fastmcp", "--with", "markdown-it-py", "/Users/master/git/mindm-mcp/mindm_mcp/server.py"]
来自包存储库的模块
config.toml
[features]
rmcp_client = true
[mcp_servers.mindmanager]
command = "uv"
args = ["run", "--with", "mindm>=0.0.5.3", "--with", "fastmcp", "--with", "markdown-it-py", "--with", "mindm-mcp>=0.0.2.1", "-m", "mindm_mcp.server"]
VSCode聊天(GitHub Copilot)
本地python文件:
根据需要调整本地文件的路径。
uv run --with mindm>=0.0.5.3 --with fastmcp --with markdown-it-py /Users/master/git/mindm-mcp/mindm_mcp/server.py或中的服务器定义 mcp.json:
"Mindmanager": {
"type": "stdio",
"command": "uv",
"args": [
"run",
"--with",
"mindm>=0.0.5.3",
"--with",
"fastmcp",
"--with",
"markdown-it-py",
"/Users/master/git/mindm-mcp/mindm_mcp/server.py"
]
}来自包存储库的模块
uv run --with mindm>=0.0.5.3 --with fastmcp --with markdown-it-py --with mindm-mcp>=0.0.2.1 -m mindm_mcp.server或中的服务器定义 mcp.json:
"Mindmanager": {
"type": "stdio",
"command": "uv",
"args": [
"run",
"--with",
"mindm>=0.0.5.3",
"--with",
"fastmcp",
"--with",
"markdown-it-py",
"--with",
"mindm-mcp>=0.0.2.1",
"-m",
"mindm_mcp.server"
]
}MCP工具
服务器通过模型上下文协议公开以下工具:
文档交互
get_mindmap:从MindManager检索当前思维导图结构get_selection:检索MindManager中当前选定的主题get_library_folder:获取MindManager库文件夹的路径get_mindmanager_version:获取已安装的MindManager版本get_grounding_information:从思维导图中提取基础信息(中心主题、选定子主题)
序列化
serialize_current_mindmap_to_mermaid:将当前加载的思维导图序列化为Mermaid格式serialize_current_mindmap_to_markdown:将当前加载的思维导图序列化为Markdown格式serialize_current_mindmap_to_json:将当前加载的思维导图序列化为具有ID映射的详细JSON对象
创造
create_mindmap_from_mermaid:从Mermaid构建MindManager映射(包含ID和元数据的完整语法)create_mindmap_from_mermaid_simple:从简化的Mermaid文本构建MindManager地图
版本控制
get_versions:返回mindm-mcp和mindm用于调试的软件包版本
平台支持
- 视窗:完全支持主题、笔记、图标、图像、标签、链接、关系和RTF格式
- macOS:支持主题、笔记和关系(与Windows相比支持有限)
与Claude和其他法学硕士整合
此MCP服务器可以安装在Claude Desktop或其他MCP兼容应用程序中,使LLM能够:
- 访问思维导图内容
- 操纵思维导图(即将推出)
- 基于LLM生成的内容创建新的思维导图(即将推出)
故障排除
- 启动服务器之前,请确保MindManager正在运行
- 对于macOS,请确保您允许Claude Desktop自动化MindManager
MCPHub
致谢
该项目建立在 mindm 库,为Windows和macOS平台上的MindManager提供Python接口。它使用Anthropic开发的模型上下文协议(MCP)SDK。
许可证
MIT许可证-有关详细信息,请参阅许可证文件
