Skip to main content

PRTS MCP Server — Python 实现

明日方舟同人创作辅助 MCP Server,Python 版本。通过 stdio 传输接入 MCP 客户端(Claude Desktop、Claude Code、Chatbox 等),支持 Docker 部署。

提供 32 个 MCP 工具:PRTS 词条检索与页面结构、干员档案/语音/基础信息、剧情活动与台词、角色出场追踪、全文搜索、敌人图鉴、关卡查询、关卡敌人融合,以及物品/材料查询。完整清单见仓库根目录 README.md。


快速开始(Docker)

# 从仓库根目录构建(可选预置 bundled 数据,详见下方)
docker build -f python/Dockerfile -t prts-mcp .

# 运行(named volume 持久化游戏数据,推荐)
docker run -i --rm -v prts-mcp-data:/data/gamedata -v prts-mcp-levels:/data/gamedata-levels -v prts-mcp-storyjson:/data/storyjson prts-mcp

接入 MCP 客户端

{
  "mcpServers": {
    "prts_wiki": {
      "command": "docker",
      "args": ["run", "-i", "--rm", "-v", "prts-mcp-data:/data/gamedata", "-v", "prts-mcp-levels:/data/gamedata-levels", "-v", "prts-mcp-storyjson:/data/storyjson", "prts-mcp"]
    }
  }
}

请使用 docker run 而非 docker compose run。后者会向 stdio 流写入进度信息,污染 JSON-RPC 通道。


不使用 Docker(pip install)

pip install -e .

# 需指定游戏数据目录(GAMEDATA_PATH 设置后禁用 auto-sync)
GAMEDATA_PATH=/path/to/ArknightsGameData prts-mcp

数据机制

服务器启动时自动同步三类数据:

  • 游戏表格数据(gamedata volume):从 3aKHP/ArknightsGameData Release 下载 zh_CN-excel.zip,其内容同步自 Kengxxiao/ArknightsGameData
  • 关卡战斗数据(gamedata-levels volume):从同一 Release 下载 zh_CN-levels.zip,用于关卡实际出怪和关卡级敌人数值
  • 剧情数据(storyjson volume):从 ArknightsStoryJson Releases 下载 zh_CN.zip

镜像内置 bundled 数据作为网络不可用时的离线保底。

PyPI 包本身不内置 bundled 数据;直接 pip install prts-mcp 时会在启动时自动同步,或使用 GAMEDATA_PATH / STORYJSON_PATH 指向你自己的本地数据。若 GAMEDATA_PATH 指向完整 ArknightsGameData 仓库根目录,内含的 zh_CN/gamedata/levels 会直接用于关卡战斗数据;否则默认在其相邻目录维护 gamedata-levels。正式 Docker 镜像会由 CI 预置兜底数据。


详细文档

→ docs/deployment.md:完整部署方式、MCP 客户端配置、环境变量参考

Metadata

Release files for prts-mcp 1.7.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for prts-mcp 1.7.3
File Size Uploaded Provenance
prts_mcp-1.7.3.tar.gz 100.1 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for prts-mcp 1.7.3
File Interpreter ABI Platform
prts_mcp-1.7.3-py3-none-any.whl Python 3 none any Details

Total release size: 169.6 kB

Release files / prts_mcp-1.7.3.tar.gz

Download URL prts_mcp-1.7.3.tar.gz
Size 100.1 kB
Tags Source
SHA-256 checksum
How to use checksums
c1cc306d50ba5d172a23dcf9bd39116ad5a1adae592f71ab6bbd033d24530c01
BLAKE2b-256 checksum
How to use checksums
95709ab0b8922bcbdb0c2ef3da34cf683cc706acd50ebc9e51a37ede61bbce13
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 21, 2026.

Transparency log

Release files / prts_mcp-1.7.3-py3-none-any.whl

Download URL prts_mcp-1.7.3-py3-none-any.whl
Size 69.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a936b3fa7649d77e65d9ebdcb54cb393358e30fb0765b44d79c745142b39a2b0
BLAKE2b-256 checksum
How to use checksums
42936601da502063e387a13251f712bcb13b102608a2fcc8c87c41adc554b7e1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 21, 2026.

Transparency log

Security for prts-mcp 1.7.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.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for prts_mcp-1.7.3.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 21, 2026.

Transparency log

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.

Release history Release notifications | RSS feed

This release

1.7.3 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page