ShapeItUp

ShapeItUp

Enables AI agents to write TypeScript to create, render, verify, and export parametric 3D models using Replicad/OpenCascade CAD kernel, headlessly from terminal or MCP clients.

Category
访问服务器

README

<p align="center"> <img src="logo.png" alt="ShapeItUp" width="400"> </p>

<p align="center"> <strong>Scripted CAD for AI agents and humans</strong> — write TypeScript, get CAD. </p>

<p align="center"> <a href="https://github.com/asbis/ShapeItUp/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-blue.svg" alt="License: MIT"></a> <a href="https://www.npmjs.com/package/@shapeitup/mcp-server"><img src="https://img.shields.io/npm/v/@shapeitup/mcp-server.svg" alt="npm: @shapeitup/mcp-server"></a> </p>


ShapeItUp is an MCP server that turns Replicad / OpenCascade into AI-agent-grade CAD tooling. It writes, renders, verifies, and exports parametric 3D models from TypeScript .shape.ts files, headlessly — from the terminal, from Claude Code / Cursor / Claude Desktop, or from CI. A VSCode extension is available as an optional interactive viewer for humans who want to watch the renders happen live.

Install for Claude Code

claude mcp add shapeitup -- npx -y @shapeitup/mcp-server

That's it. claude mcp add registers the server in your Claude Code config so agent sessions pick it up automatically. See the Claude Code MCP docs for scoping options (-s user for all projects, -s project for just this repo).

Install for Cursor / Claude Desktop / other MCP clients

The generic MCP-config snippet:

{
  "mcpServers": {
    "shapeitup": {
      "command": "npx",
      "args": ["-y", "@shapeitup/mcp-server"]
    }
  }
}

Where to put it:

  • Cursor~/.cursor/mcp.json, or Settings → MCP → Add new server to drop it in through the UI.
  • Claude Desktop~/Library/Application Support/Claude/claude_desktop_config.json on macOS, %APPDATA%\Claude\claude_desktop_config.json on Windows. Restart the app after editing.
  • Any stdio MCP client — hand it npx -y @shapeitup/mcp-server as the server command.

Node 20+ required. No native build step; everything ships as WASM.

What you get

A CAD toolkit agents can drive end to end:

  • Authoringcreate_shape, modify_shape, read_shape, list_shapes, setup_shape_project
  • Renderingrender_preview, preview_shape, get_preview (SVG-first, resvg-backed PNGs)
  • Verificationverify_shape, check_collisions, sweep_check, describe_geometry, validate_joints
  • Iterationtune_params (slider overrides), set_render_mode, toggle_dimensions
  • Exportexport_shape (STEP / STL / OBJ / 3MF)
  • stdlibholes, screws / bolts / washers / inserts, bearings, extrusions, patterns, threads, joints + assemble, printHints, and more — all importable from "shapeitup" inside any .shape.ts

Full tool list: 25 MCP tools covering the create → preview → verify → tune → export loop.

Quick example

Prompt to the agent: "I want a mounting bracket, 60×40×4 mm, four M3 through-holes in the corners." The agent calls create_shape and writes:

// bracket.shape.ts
import { drawRoundedRectangle } from "replicad";
import { holes } from "shapeitup";

export const params = { width: 60, depth: 40, thickness: 4, holeInset: 6 };

export default function main({ width, depth, thickness, holeInset }: typeof params) {
  const plate = drawRoundedRectangle(width, depth, 3)
    .sketchOnPlane("XY")
    .extrude(thickness);

  return holes.through(plate, "M3", [
    [-width/2 + holeInset, -depth/2 + holeInset, 0],
    [ width/2 - holeInset, -depth/2 + holeInset, 0],
    [-width/2 + holeInset,  depth/2 - holeInset, 0],
    [ width/2 - holeInset,  depth/2 - holeInset, 0],
  ]);
}

Then it calls render_preview and gets back a PNG it can inspect, plus bounding-box + volume metadata to sanity-check against the spec. If the user wants the holes bigger, the agent calls tune_params — no file rewrite needed.

Running in CI / containers

npx -y @shapeitup/mcp-server works anywhere Node 20 runs — Docker, GitHub Actions, GitLab CI. Renders go through @resvg/resvg-wasm; no GPU, no headless Chromium, no native graphics stack required. A cold boot on a stock Node image typically takes ~3 s for the first render (OCCT WASM compile) and < 200 ms thereafter.

VSCode extension (optional)

There is a VSCode extension that subscribes to the MCP server's event bus and shows a live Three.js viewer in the side panel — useful when you want to watch an agent work, or to drive ShapeItUp interactively. Install it from the VS Code marketplace (search for "ShapeItUp") or build from source (see Development).

The extension is entirely optional: the MCP server is headless on its own, does not require VSCode to be running, and produces the same renders whether or not a viewer is attached.

Development

git clone https://github.com/asbis/ShapeItUp.git
cd ShapeItUp
pnpm install
pnpm build          # builds extension, viewer, worker, and mcp-server
pnpm dev            # watch mode
pnpm lint           # tsc -b across packages

Then press F5 in VS Code to launch the Extension Development Host if you want to iterate on the viewer.

Project layout:

packages/
  mcp-server/   -- standalone MCP server (this is the npm package)
  core/         -- Replicad wrappers, stdlib, execution engine (bundled into mcp-server)
  shared/       -- cross-package types (bundled into mcp-server)
  extension/    -- VSCode extension (optional viewer)
  viewer/       -- Three.js viewer surface for the extension
  worker/       -- OCCT WASM web-worker for the extension viewer

See CONTRIBUTING.md for contribution guidelines.

License

MIT

推荐服务器

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 模型以安全和受控的方式获取实时的网络信息。

官方
精选