Skip to main content
Glama
gto-recipe-mcp
by Huoyuuu

gto-recipe-mcp

GregTech Odyssey 的只读配方查询 MCP,可以查谁产 X、谁吃 X、这条配方在哪台机器上跑、跑 N 次的净进出是多少,还能按进料自动配平整条产线。数据来自游戏运行时导出,包含材料分解、矿石处理这类自动生成的配方。

内置数据为普通难度(Normal)。 难度会改写配方和数值。简单或专家难度的玩家,需要在自己的实例里运行一次 exporter/run_export.py(见「更新数据」)。导出器会按该实例 config/gtocore.yaml 中的难度重新导出,并记录到 data/runtime/meta.json。

pi 对话 工具输出

数据版本

项

值

整合包

GregTech Odyssey 0.5.6-beta · 普通难度(Normal)

模组

gtocore 0.5.6-beta · GTCEu 26.7.3 (GTO fork) · GTOLib 26.7.4

游戏

Minecraft 1.20.1 · Forge 47.4.20

内容

51714 条配方 / 183 类 · 2321 台机器与部件 · 1900 种材料

Related MCP server: poi-plugin-nanodesu-mcp

快速开始

git clone https://github.com/Huoyuuu/gto-recipe-mcp && cd gto-recipe-mcp
uv sync && uv run pytest -q

在 MCP 客户端的配置里加入下面这段。pi 的配置文件是 ~/.pi/agent/mcp-adapter.json,Claude Desktop 等客户端格式相同:

"gto-recipes": { "command": "uv", "args": ["--directory", "<仓库路径>", "run", "gto-mcp"] }

重开会话后,直接用中文提问即可,例如:

  • 「谁消耗萤石粉?」

  • 「溶解罐和溶解核心能跑哪些配方?」

  • 「煮解氟碳铈矿跑 10 次要补多少硝酸?」

工具

search recipe producers consumers machines_for machine material trace balance me_parts,v2 新增 plan(自动配平产线)和 balance_v(按电压超频)。

物品可以用 registry id、dust:Bastnasite、Java 字段名(dust:TerbiumNitratePowder)、中文名或模糊词来指定。每次返回约 4 KB,超出部分用 offset 翻页。producers 和 trace 默认隐藏打包、宇宙模拟这类噪音配方,传 include_all=True 可以显示。

# plan:给进料速率和步骤,算出每步 runs/s、所需台数和净缺口;make 步骤按缺口补料
plan({"dust:Bastnasite": 1}, ["fluoro_carbon_lanthanide_cerium_solution47",
     {"id": "hydrofluoric_acid_from_elements", "mode": "make"}], voltage="IV")

# 在 Python 里直接调用:uv run python
from gto_mcp import server as s
print(s.consumers("萤石粉")); print(s.D().resolve("硝酸"))

更新数据

powershell -File exporter/build.ps1
uv run python exporter/run_export.py --instance "<实例目录>"

运行时会用离线账号启动实例,约 70 秒,导出后自动退出并移除导出模组。

已知限制

  • 概率 boost 按 GTCEu 默认公式计算,未核实 GTO 是否改写。

  • 超频按 GTCEu 标准公式计算(plan / balance_v)。GTOLib 的专有并行没有复现,需要时在步骤里传 parallel。

  • 210 台 GTO 多方块的仓室信息来自静态源码。

MIT License

Available Tools

12 tools
balanceC

物料平衡。runs=[{recipe_id, runs}] 或 [{"": runs}];tier(数字或 EV/IV…) 叠加概率 boost(GTCEu 默认公式,未核实 GTO)。

Inputs: runs (required), tier, format.

balance_vC

balance 加电压:三栏同 balance(概率 boost 按该电压),并给每条配方超频后 EU/t、时长与机器秒。runs 同 balance,条目可加 machine/parallel/perfect。

Inputs: runs (required), format, voltage.

consumersB

消耗该物品/流体的配方,按 EU/t 升序(不含不可消耗输入);降噪规则同 producers。

Inputs: item (required), limit, format, offset, +1 more.

machineC

机器定义:配方类型、仓室能力(PartAbility)、tooltip。

Inputs: id (required), format.

machines_forB

能跑该配方类型(或该配方所属类型)的全部机器,多方块优先。

Inputs: recipe_type_or_id (required), format.

materialC

材料:化学式、组分、flags、形态,以及会不会被自动分解(及对应分解配方)。

Inputs: name (required), format.

me_partsA

ME 相关机器部件清单(id、中文名、是否可放进多方块)。

Inputs: no named parameters.

planB

自动配平产线(全部为每秒速率)。feed={物品: 每秒数量};steps=[配方id 或 {id, mode=use|make, share, drive, target, machine, parallel, voltage, runs, perfect}]。 use(默认):按驱动输入可用量定次数,驱动缺省=第一个属于进料或 use 产物、且不是 make 目标的输入;make:按 target 净缺口补料(如氢+氟→氢氟酸);runs:固定次数/秒。 输出净外部需求/净产出/进料剩余/内部循环、总 EU/t,以及每步 runs/s、机器、超频、所需台数。

Inputs: feed (required), steps (required), format, voltage.

producersB

产出该物品/流体的配方,按 EU/t 升序;默认隐藏打包/解包/宇宙模拟/回收类,产物>8 种的排后(include_all=True 关闭)。

Inputs: item (required), limit, format, offset, +2 more.

recipeC

单条配方全文。id 可为完整 id、type/tail 或唯一的 tail。

Inputs: id (required), format.

traceB

文本树展开上游(up=谁产它、它要什么)/下游(down=谁吃它、产出什么),每层取 EU/t 最低的 per_level 条。

Inputs: item (required), depth, direction, per_level, +2 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.2/5.0

    Scored across 12 tools

    Disambiguation4/5

    Most tools target distinct queries (recipe, producers, consumers, machine, material, me_parts). Some conceptual overlap exists: trace (upstream/downstream tree) relates to producers/consumers (flat lists), and balance vs balance_v differ only by added voltage, though detailed descriptions clearly delineate them.

    Naming Consistency4/5

    All names use consistent lowercase snake_case, which is readable and predictable. Minor deviations exist: singular/plural mix (machine vs machines_for), a _for suffix, and the balance/balance_v abbreviation, but no chaotic mixing of conventions.

    Tool Count5/5

    12 tools sit comfortably in the ideal 3-15 range. Each tool exposes a distinct capability (search, lookup, relationship tracing, balancing, planning) that earns its place for a complex recipe-mod domain.

    Completeness4/5

    The surface covers the recipe lifecycle well: search, recipe detail, producers/consumers, machine and material definitions, tracing, material balancing, production-line planning, and ME parts. Coverage is broad for the domain; only niche gaps (e.g. dedicated item/ore lookups) remain, which search can partially handle.

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables MCP clients to query a running KanColle game client's live state and integrated resources—fleets, quests, battle history, and id lookups—through read-only tools.
      MIT
    • F
      license
      Not graded
      quality
      B
      maintenance
      Provides MCP tools to query Factorio recipes, technologies, and save progress, including search, production chain analysis, and plan validation against a specific save's research and enabled recipes.
      -
    • A
      license
      B
      quality
      C
      maintenance
      Enables MCP clients to answer Star Citizen crafting, mining and trading questions from public game data: product recipes with quality effects, mining locations, scan signatures and refinery yields, plus terminal prices and UEX player marketplace listings. It is read-only and requires no account.
      14
      MIT