pcb-lens

v1.6.1
@intelligentelectron/pcb-lens Checked 8 hours ago Published 12 days ago

MCP server for IPC-2581 PCB layout analysis and review

The PCB Lens MCP Server gives AI agents the tools to understand and review your PCB layouts, for physical design reviews through natural conversations. It reads IPC-2581 layouts from any EDA tool, and Cadence Allegro boards and constraint files directly on macOS, Linux, and Windows, with no Cadence installation and no EDA license required. Installing takes two steps: the pcb-lens binary, then the plugin for your agent. The plugin connects the MCP server to the agent, so there is no configuration to write.

Summary extracted from the README.

PCB Lens MCP Server

The PCB Lens MCP Server gives AI agents the tools to understand and review your PCB layouts, for physical design reviews through natural conversations.

It reads IPC-2581 layouts from any EDA tool, and Cadence Allegro boards and constraint files directly on macOS, Linux, and Windows, with no Cadence installation and no EDA license required.

Supported Formats

Format Input Files
Cadence Allegro .brd
Cadence Constraint Manager .dcf
Cadence TCFX .tcfx
IPC-2581 .xml

Install

Installing takes two steps: the pcb-lens binary, then the plugin for your agent. The plugin connects the MCP server to the agent, so there is no configuration to write.

1. Install the binary

macOS / Linux:

curl -fsSL https://raw.githubusercontent.com/IntelligentElectron/pcb-lens/main/install.sh | bash

Windows (PowerShell):

irm https://raw.githubusercontent.com/IntelligentElectron/pcb-lens/main/install.ps1 | iex

The installer provides:

  • No dependencies: a standalone binary, with no Node.js required
  • Auto-updates: the binary checks for updates on startup; pcb-lens update updates it on demand
  • Signed binaries: macOS binaries are notarized by Apple

It places the binary in the bin/ folder of ~/Library/Application Support/pcb-lens/ (macOS), ~/.local/share/pcb-lens/ (Linux) or %LOCALAPPDATA%\pcb-lens\ (Windows), and adds that folder to your PATH in both your shell's startup file and its login profile, so apps started outside a terminal, such as the Claude desktop app, find it too. Restart your agent afterwards.

npm install -g @intelligentelectron/pcb-lens

Requires Node.js 24+. Update with npm update -g @intelligentelectron/pcb-lens.

Install the binary one way only: the plugin runs the first pcb-lens on your PATH.

2. Install the plugin

Claude Code

/plugin marketplace add IntelligentElectron/pcb-lens
/plugin install pcb-lens@pcb-lens

Local sessions in the Code tab of the Claude desktop app use Claude Code's plugins, so the server is available there too.

OpenAI Codex

codex plugin marketplace add IntelligentElectron/pcb-lens --sparse .agents/plugins --sparse plugins
codex plugin add pcb-lens@pcb-lens

The --sparse paths fetch only the plugin; Codex otherwise clones the whole repository, test fixtures included. The plugin works in the Codex CLI and the Codex app.

Then ask the agent to review a layout, trace a net, or read a board's constraints.

Other agents

Open Customize, choose Browse Marketplace, then Add Marketplace → Import from GitHub. Enter IntelligentElectron/pcb-lens and add the pcb-lens plugin.

copilot plugin marketplace add IntelligentElectron/pcb-lens
copilot plugin install pcb-lens@pcb-lens

Add this to the project's .claude/settings.json:

{
  "extraKnownMarketplaces": {
    "pcb-lens": {
      "source": { "source": "github", "repo": "IntelligentElectron/pcb-lens" }
    }
  },
  "enabledPlugins": { "pcb-lens@pcb-lens": true }
}

and this to the project's .codex/config.toml:

[marketplaces.pcb-lens]
source_type = "git"
source = "https://github.com/IntelligentElectron/pcb-lens.git"
sparse_paths = [".agents/plugins", "plugins"]

[plugins."pcb-lens@pcb-lens"]
enabled = true

Each person still installs the binary once.

If you registered the server yourself before, remove that registration so the agent does not run two copies:

claude mcp remove --scope user pcb-lens
codex mcp remove pcb-lens

Every MCP tool is also a shell command, for an agent in a sandbox or container that cannot connect an MCP server:

pcb-lens get_pcb_net board.xml --pattern '^DDR_D'
pcb-lens get_constraints board.brd --section BrdStackup

The plugin carries a skill that teaches an agent those commands, their flags and exit codes; the agent uses it only when the MCP server is not connected. Agents that read Agent Skills can install the skill alone through the GitHub CLI:

gh skill install IntelligentElectron/pcb-lens pcb-lens --agent github-copilot --scope user

See docs/cli.md for the command line itself.

Observability (OpenTelemetry)

The server can emit OpenTelemetry traces, metrics, and logs for every tool call, which report what is used, how long it takes, and what fails. Any OTLP-compatible backend receives them (an OpenTelemetry Collector, Jaeger, Tempo, Prometheus, Honeycomb, Datadog, or a managed cloud tracing service).

OpenTelemetry is disabled by default and is enabled and configured through the standard OTEL_* environment variables, with no code changes.

See Observability (OpenTelemetry) for setup, configuration, and the full list of emitted spans, metrics, and logs.

Documentation

See docs/ for API documentation, response schemas and supported platforms and docs/cli.md for the binary's command line.

See CONTRIBUTING.md for development guidelines.

Privacy Policy

The server runs on your machine and sends the author nothing. It keeps a local usage log (telemetry.jsonl) in its install directory, which leaves the machine only if you pack it with pcb-lens export-telemetry and share it. Its only network call is the update check against this repository's GitHub releases.

About

This project is hosted on GitHub under the IntelligentElectron organization.

PCB Lens MCP Server is an original work by Valentino Zegna.

Acknowledgments

The Allegro .brd reader's file header, string table and block framing follow the notes of KiCad's Allegro importer (FORMAT.md). Their work made reading the board database directly possible.

License

Apache License 2.0 - see LICENSE