copper-mcp

copper-mcp

Enables secure, read-only inspection and validation of KiCad PCB boards through MCP, with deterministic routing and optional AI policy plugins.

Category
访问服务器

README

CopperMCP

CI CodeQL Release License Python Status

CopperMCP is a local-first, open-source PCB automation platform designed for deterministic routing, MCP-based tools, and optional AI policy plugins.

[!IMPORTANT] CopperMCP is pre-alpha. The current 0.1.x foundation provides secure board inspection, authoritative read-only KiCad DRC summaries, stable manifests, candidate validation, MCP contracts, and a narrow candidate-only two-pin A* reference. It does not route or modify production boards.

Why this project exists

Existing open autorouters provide useful geometry and negotiated-congestion baselines, but there is no broadly adopted open platform that combines reproducible routing, safe agent tools, learned policy hooks, KiCad-native workflows, and transparent benchmarks. CopperMCP is building that layer without putting an LLM in charge of electrical correctness.

The non-negotiable boundary is simple:

  • AI may interpret constraints and propose net ordering, corridors, cost weights, and repairs.
  • Deterministic code owns geometry, connectivity, DRC, provenance, and file mutation.
  • Generated work remains an immutable candidate until a user validates and explicitly applies it.

Current capabilities

  • Read-only, bounded inspection of documented .kicad_pcb files.
  • Workspace confinement, including protection against parent-path and symlink escapes.
  • SHA-256 board revisions and versioned JSON schemas.
  • Immutable Board IR 0.1.0 with exact integer units, typed constraints, canonical digests, and a bounded fail-closed converter for a documented KiCad subset.
  • Fixed-argument KiCad CLI DRC with source, time, size, schema, and stale-context guards.
  • Candidate-manifest validation and correctness-first comparison.
  • Bounded integer A* candidates for one two-pad net on a documented rectangular Board IR subset, with independent lattice, search, and obstacle-work ceilings, plus replay-bound serialization to new disposable KiCad bytes when every modeled source geometry object has a native UUID/tstamp. This synthetic-domain reference has no durable export, authoritative candidate-bound DRC evidence, preview, MCP route tool, source mutation, or apply path.
  • MCP tools and a stable CLI over the same application services.
  • Professional CI, CodeQL, dependency auditing, release automation, issue forms, and project ledgers.

See the roadmap for routing and KiCad IPC milestones.

Audio Board Lab

CopperTone stereo line-buffer engineering preview

The Audio Board Lab publishes open KiCad designs that exercise CopperMCP against real audio-PCB workflows. Lab #001 — CopperTone is a 52 mm × 30 mm, two-layer OPA1656 stereo line-buffer preview with checked-in board source, BOM, Gerbers, drill files, STEP assembly, renders, constraints, provenance, and a one-command KiCad 10 validation gate. The recorded KiCad 10.0.5 run reports 0 DRC violations, 0 unconnected items, and 0 unrouted items.

CopperTone is a board-first engineering preview, not a fabrication-approved or electrically validated product. It has no source schematic, ERC, assembled prototype, or audio measurements yet; its hardware sources are separately licensed under CERN-OHL-S-2.0. CopperMCP inspected and validated the artifact but did not autoroute or apply its copper.

Research direction

The open autorouter research package compares current open routing tools and records the evidence behind CopperMCP's CPU-first roadmap: exact integer geometry, A*/maze search, PathFinder-style negotiated congestion, conflict-aware parallelism, bounded exact repair, profiled GPU kernels, and optional typed ML policy hooks. Deterministic code and KiCad validation remain the authority for every copper result.

Quick start

Prerequisites: Python 3.11 or newer.

python3 -m venv .venv
source .venv/bin/activate
python -m pip install -e ".[dev,security]"
make check

Inspect a board without modifying it:

copper-mcp --workspace /absolute/path/to/boards inspect example.kicad_pcb

Run authoritative KiCad DRC and return only bounded aggregate evidence:

export COPPER_MCP_KICAD_CLI=/absolute/path/to/kicad-cli  # optional when discoverable
copper-mcp --workspace /absolute/path/to/boards drc example.kicad_pcb

The DRC adapter never accepts arbitrary KiCad flags and never requests zone refill or board save. It mirrors the board, matching project/rule files, and workspace-local KiCad library assets into a private snapshot; bounds that snapshot cumulatively; limits report growth in the child process; and rejects results when any captured context changes during execution. Context discovery also has file count and wall-clock ceilings, and the pre-run byte snapshot is released before KiCad starts. Keep KiCad projects and their project-relative libraries self-contained below the configured workspace. DRC-clean is not a substitute for electrical, signal-integrity, manufacturability, or hardware review.

Start the local MCP server over standard input/output:

export COPPER_MCP_WORKSPACE=/absolute/path/to/boards
copper-mcp-server

Example MCP client configuration:

{
  "mcpServers": {
    "copper-mcp": {
      "command": "copper-mcp-server",
      "env": {
        "COPPER_MCP_WORKSPACE": "/absolute/path/to/boards",
        "COPPER_MCP_TRANSPORT": "stdio"
      }
    }
  }
}

Never place provider keys or proprietary board contents in committed MCP configuration. See .env.example and the security policy.

Architecture

KiCad IPC / board files        MCP clients / CLI
           \                       /
            \                     /
             Board IR + services
                      |
           deterministic router contract
                      |
          immutable candidate + provenance
                      |
        internal checks + authoritative KiCad DRC
                      |
               explicit user apply

MCP is an external adapter, not an internal dependency of the routing engine. The reference core is currently Python so it is executable and reviewable everywhere; performance-critical Rust or GPU backends will implement the same stable routing contract. Read the architecture overview and ADRs before changing this boundary.

Documentation

Contributing

Contributions are welcome, particularly reproducible boards, geometry tests, routing algorithms, KiCad integration, benchmark infrastructure, and documentation. Please read CONTRIBUTING.md, the Code of Conduct, and existing ADRs first.

Private or customer PCB designs must not be attached to public issues. Use minimal synthetic reproductions or sanitized open designs.

Versioning and status

CopperMCP follows Semantic Versioning and Keep a Changelog. Before 1.0.0, minor releases may intentionally change experimental contracts with migration notes. See CHANGELOG.md and the release ledger.

License

Except where a directory says otherwise, CopperMCP software and documentation are licensed under the Apache License 2.0. Audio Board Lab hardware sources carry their own clearly identified open-hardware license; CopperTone uses CERN-OHL-S-2.0. Test fixtures and contributed datasets must include compatible provenance and licensing metadata.

推荐服务器

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

官方
精选