Minecraft Document MCP
一个基于 FastMCP 框架的 Minecraft 文档 MCP 服务器,为 AI 助手提供中文 Minecraft Wiki 文档查询功能。
功能特性
- Wiki 在线查询 - 从中文 Minecraft Wiki 获取词条内容
- 分类浏览 - 获取 Wiki 首页主要分类列表
- 简介/完整内容 - 支持获取词条简介或完整内容
- Markdown 输出 - 所有查询结果以 Markdown 格式返回
- MCP 协议支持 - 兼容 Model Context Protocol,可集成到 Claude Desktop 等客户端
MCP 工具
| 工具名称 | 功能描述 |
|---|---|
search_wiki_intro |
从 Wiki 搜索词条简介 |
search_wiki_full |
从 Wiki 搜索词条完整内容 |
get_wiki_categories |
获取 Wiki 首页主要分类列表 |
安装
环境要求
- Python 3.12+
- uv 包管理器(推荐)
使用 uv 安装
# 克隆仓库
git clone https://github.com/PYmili/minecraft-document-mcp.git
cd minecraft-document-mcp
# 安装依赖
uv sync
使用 pip 安装
# 克隆仓库
git clone https://github.com/PYmili/minecraft-document-mcp.git
cd minecraft-document-mcp
# 创建虚拟环境
python -m venv .venv
source .venv/bin/activate # Linux/macOS
# .venv\Scripts\activate # Windows
# 安装依赖
pip install -e .
使用方法
启动服务器
# 推荐:使用 fastmcp 运行
fastmcp run server.py
# 开发模式(支持热重载)
fastmcp dev server.py
# 或使用安装后的命令行工具
minedoc
配置 Claude Desktop
在 Claude Desktop 配置文件中添加:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"minecraft-document": {
"command": "minedoc"
}
}
}
项目结构
minecraft-document-mcp/
├── pyproject.toml # 项目配置
└── minecraft_document_mcp/ # 主包
├── __init__.py
├── cli.py # MCP 服务器入口
└── src/
└── api/
├── __init__.py
├── WikiApi.py # Wiki API 请求工具
└── WikiItems.py # 数据项定义
依赖
- fastmcp - MCP 框架
- requests - HTTP 请求库
- beautifulsoup4 - HTML 解析
- markdownify - HTML 转 Markdown
- lxml - XML/HTML 解析后端
- dataclasses-json - 数据类序列化
许可证
相关链接
- Minecraft Wiki - 中文 Minecraft Wiki
- Model Context Protocol - MCP 协议文档
- FastMCP - FastMCP 框架
Metadata
Release files for minecraft-document-mcp 0.1.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| minecraft_document_mcp-0.1.5.tar.gz | 8.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| minecraft_document_mcp-0.1.5-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 16.8 kB
Release files / minecraft_document_mcp-0.1.5.tar.gz
| Download URL | minecraft_document_mcp-0.1.5.tar.gz |
|---|---|
| Size | 8.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8e4fa04e9b4478f7406f308e3cf30a0aa47c8b5715b1580c70e432f9a740ab3d
|
|
BLAKE2b-256 checksum How to use checksums |
8966a1010c18ca50895a981996d372def391a1b24ab149499945775ffa27720f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.10 {"installer":{"name":"uv","version":"0.10.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / minecraft_document_mcp-0.1.5-py3-none-any.whl
| Download URL | minecraft_document_mcp-0.1.5-py3-none-any.whl |
|---|---|
| Size | 8.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e0afa81c0ba4f685d4b5254bab8191e2c83719780fedbf2639e003f99b95db54
|
|
BLAKE2b-256 checksum How to use checksums |
2b44c3966d1a5d3094d4a908a00445fb846201c8467098497d63ace75fab3f1b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.10 {"installer":{"name":"uv","version":"0.10.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|