root-ext-cad

root-ext-cad

CAD-engineering MCP tool server for parametric modeling, DFM validation, mechanical calculations, and more. Enables code-CAD builds (build123d/CadQuery), model inspection, meshing, and mechanical calculators via MCP stdio.

Category
访问服务器

README

root-ext-cad

CAD-engineering MCP tool server — code-CAD builds (build123d/CadQuery), model inspection, meshing, DFM-lite validation, and mechanical calculators. Built as the mechanical-engineering pack for [ROOT Workspace], but it speaks plain MCP stdio and works with any MCP host.

The workspace client stays domain-free by doctrine; this repo is where the CAD knowledge lives. Tools reach both ROOT runtimes (the brain-governed deployment and the lite Tier-0 harness) through the client's mcp-bridge, and every call is governed — write-class tools gate like any write; network tools park for approval.

The charter (binding)

Source is truth; artifacts are derived. The pack never overwrites a user's file in place: geometry writes land in a caller-named output directory (default derived/ beside the source), and every write tool refuses an output path that collides with its input. tests/test_server.py::test_no_inplace_mutation_tools_exist and the collision-refusal tests enforce this in CI, not just in prose.

Parametric source (a build123d or CadQuery .py script) is the model; STEP/STL/glTF/3MF are exports. model_build executes scripts — it says so plainly, runs them in this pack's own venv as a resource-capped subprocess, and is classed write, never read.

Tools

Tool Class* What it does
model_inspect read STEP/BREP/STL → bounding box, volume/area, mass (given density), topology counts, per-solid summary
model_validate read DFM-lite lint: open (non-watertight) shells, invalid B-rep, tiny edges/faces, pairwise interference & clearance — every finding carries its evidence and threshold
model_build write Run a build123d/CadQuery parametric script (sandboxed subprocess, CPU/memory/wall caps) → STEP/STL/glTF/3MF into the output dir + a build report
model_mesh write STEP/BREP → tessellated STL/glTF/3MF with linear + angular tolerance controls
calc_fits read ISO 286 limits & fits (hole-basis subset), clearance/interference verdicts
calc_fastener read Metric coarse threads: pitch, stress area, tap & clearance drills, preload/torque first-cut
calc_beam read Beam bending first-cut: cantilever / simply-supported, point / UDL, rect / round / tube sections
calc_mass_rollup read Assembly mass + 3D center of gravity from a component list, envelope check
model_diff read Geometric diff of two revisions: volume/area/bbox deltas, bodies unchanged/moved/added/removed by shape signature — geometry, not a feature tree, and the report says so
drawing_project write Named-view (front/top/…/iso) SVG or DXF projection: visible edges + dashed hidden layer — a silhouette for hand-off, not a dimensioned drawing
text_to_cad external Starter model from a text prompt via Zoo's ML-ephant API (+ its editable KCL source when returned); needs ZOO_API_KEY, refuses by name without it

* Classes derive fail-safe from annotations in the ROOT client: read tools declare readOnlyHint: true, openWorldHint: false; write tools declare readOnlyHint: false, openWorldHint: false (the closed-world write class); network tools (Phase CAD-D: text_to_cad) will declare openWorldHint: true and refuse by name without their key.

Connect it to ROOT Workspace

Settings → Connected tools → the connect form:

  • Name: cad-eng
  • Command: uv run --project /path/to/root-ext-cad root-ext-cad (a local checkout), or once published: uvx root-ext-cad

Run the row's Check (doctor) after connecting. Keep model files and build scripts inside granted folders so the agent can cross-read them with fs.*. Builds must finish inside the bridge's call ceiling (120 s; 90 s once promoted) — the default subprocess wall cap is 75 s.

Development

uv venv .venv
uv pip install --python .venv/bin/python -e ".[dev]"
.venv/bin/pytest

Layering rule: server.py is wiring only; every capability lives in a plain-Python module (inspection.py, meshing.py, validate.py, buildrun.py, calc.py, geometry.py) with logic separated from I/O so the rules stay unit-testable on synthetic shapes — no fixture model files required.

Roadmap

  • Later, each behind its own ADR: FreeCAD GUI-bridge companion, Onshape connector, KCL as a second source dialect, FEA hand-off recipes, PMI/GD&T presence reporting

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选