kicad-bom-basic-optimizer
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@kicad-bom-basic-optimizer Analyze hardware/bom.csv for JLCPCB Basic swaps and give me a Markdown report"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
kicad-bom-basic-optimizer
Stop paying $3 × N in avoidable JLCPCB Extended-part feeder fees on every prototype PCBA spin.
kicad-bom-basic-optimizer is a zero-dependency Python 3 CLI, stdio MCP server, and AI Coding Agent Skill that parses KiCad, Altium, and EasyEDA BOM CSVs, runs pre-assembly BOM health checks, normalizes Yageo/Murata/Samsung/TDK/Vishay/UniOhm SMD passives and common semiconductors to JLCPCB Basic equivalents, and grades every swap transparently (A↑ / A± / A↓ / B) so you never accidentally downgrade a precision divider or high-voltage bypass cap.
Prefer a zero-upload browser UI or need the full cross-reference catalog?
Try PartCrossLab — 100% client-side interactive BOM optimizer & parametric part cross-reference (your BOM never leaves your browser tab).
Why This Exists: The $3/Part JLCPCB Feeder-Fee Tax
On JLCPCB PCBA assembly, every unique Extended reel costs $3.00 in feeder-loading setup fees — even if you only place a single 10kΩ 0603 resistor on 5 prototype boards.
Most KiCad schematics pick generic DigiKey/Mouser MPNs (RC0603FR-075K1L, GRM188R71C104KA01D, LM1117IMPX-3.3, SI2302CDS) that are electrically identical to $0 JLCPCB Basic parts. On a typical 20-line ESP32/STM32 dev board, that single oversight adds $30–$51 in pure feeder fees per order.
Real Before / After on samples/sample_kicad_bom.csv
Running the CLI on our 22-line USB-C + ESP32-S3 CAN logger demo BOM:
python3 -m bom_basic_optimizer analyze samples/sample_kicad_bom.csv --format mdMetric | Before | After (Auto-Safe | After (All Suggested) |
Active BOM Lines (excl. 1 DNP) | 21 | 21 | 21 |
JLCPCB Basic Lines ( | 1 | 15 | 18 |
Extended Lines ( | 20 | 6 | 3 |
Estimated Feeder Fees | $60.00 | $18.00 | $9.00 |
Feeder Fees Saved | — | $42.00 (zero risk) | $51.00 (review |
Notice why transparent grading matters:
R7(4.7k 0.1%0402 ADC divider) is flaggedA↓because the Basic resistor is1%— the report explicitly warns you to keep it Extended for precision sensing.C9(100nF 50V X7R0402 bypass) is flaggedA↓because the 0402 Basic part (C1525) is only rated16V.D4(SMBJ5.0A600W SMB TVS) is flaggedBbecause the Basic option (SMAJ5.0A) is a smallerSMA400W footprint.C7, C8(10uF 10V X5R0603) triggers aNARROW_VOLTAGE_MARGINhealth warning reminding you to check MLCC DC-bias derating.
Related MCP server: mcp-server-kicad-tools
Grading Legend
Grade | Meaning | Action |
| Same footprint, higher margin (e.g., | Safe drop-in swap |
| Same footprint and equivalent nominal electrical spec | Safe drop-in swap |
| Same footprint, tighter/lower margin (e.g., | Verify rail voltage / tolerance before swapping |
| Footprint, pinout, polarity, or surge-power difference (e.g., | Requires schematic or layout review |
Quick Start (Zero Dependencies)
Requires Python 3.9+. No pip packages needed to run directly from source.
git clone https://github.com/banxia0222/kicad-bom-basic-optimizer.git
cd kicad-bom-basic-optimizer
# 1. Analyze a KiCad, Altium, or EasyEDA BOM CSV -> Markdown report
python3 -m bom_basic_optimizer analyze samples/sample_kicad_bom.csv --format md
# 2. Export an enriched CSV for spreadsheet review / re-import
python3 -m bom_basic_optimizer analyze samples/sample_kicad_bom.csv --format csv -o optimized_bom.csv
# 3. Run in CI / pre-fab check (exits with code 2 on duplicate refdes or TBD placeholders)
python3 -m bom_basic_optimizer analyze samples/sample_kicad_bom.csv --strict
# 4. Look up a single MPN or passive spec
python3 -m bom_basic_optimizer lookup "GRM188R71C104KA01D"
python3 -m bom_basic_optimizer lookup "LM1117IMPX-3.3" --package SOT-223Optional editable install to register the bom-basic-optimizer and bom-basic-optimizer-mcp entry points:
pip install -e .
bom-basic-optimizer analyze samples/sample_kicad_bom.csv --format mdWhat It Checks & Normalizes
Multi-EDA CSV / TSV Auto-Detection: KiCad (
Reference,Footprint), Altium (Designator,Comment), EasyEDA (LCSC Part #), refdes ranges (R1-R4), and DNP columns.Pre-Assembly BOM Health Checks:
DUPLICATE_REFDES(error): RefDes repeated across rows or within a row.PLACEHOLDER_VALUE(error):TBD,TBC,XXX,???, or blank Value + MPN.QTY_REFDES_MISMATCH(warning):Qtycolumn disagrees with the expanded designator count.MISSING_PACKAGE(warning): Active part lacks a recognizable SMD/IC footprint.NARROW_VOLTAGE_MARGIN&NARROW_TEMP_DIELECTRIC(warning): Low-voltage bulk MLCC DC-bias derating (<= 10Vfor>= 4.7uF, or<= 6.3V), unstableY5V/Z5Udielectrics, or0..70°Ccommercial-only specs.SINGLE_SOURCE_PART(info): Active Extended ICs/modules/connectors with no bundled Basic alternate.
SMD Passive Normalization (
0402/0603/0805/1206):Decodes Yageo (
RC,AC,RT,CC), Samsung (CL05/10/21/31), Murata (GRM15/18/21/31), TDK (C1005/1608/2012/3216), UniOhm (0402W/0603W/0805W/1206W), and Vishay (CRCW) MPNs.
Curated Popular Components:
AMS1117/LM1117,XC6206,ME6211/AP2112K,AO3400A/SI2302,AO3401A,2N7002/BSS138,MMBT3904,1N4148WS,BAT54/BAT54C/BAT54S,SS34,SS14,1N5819WS,SMBJ5.0A/SMAJ5.0A,USBLC6-2SC6,TJA1051T/3,CH340C/CH340G,NE555/LM555,LM358,74HC595,EL817/PC817,MP1584EN, and standard0603indicator LEDs.
MCP Server Setup (Claude Code / Cursor / Codex)
bom_basic_optimizer.server is a zero-dependency stdio JSON-RPC 2.0 MCP server exposing two tools:
analyze_kicad_bom— acceptsfile_pathor inlinecsv_content, returns Markdown, CSV, or JSON report.find_jlcpcb_basic_alternative— looks up any MPN or passive spec and returns a graded Basic equivalent.
Claude Code (~/.claude.json or project .mcp.json)
{
"mcpServers": {
"kicad-bom-basic-optimizer": {
"command": "python3",
"args": ["-m", "bom_basic_optimizer.server"],
"cwd": "/absolute/path/to/kicad-bom-basic-optimizer"
}
}
}Cursor (.cursor/mcp.json)
{
"mcpServers": {
"kicad-bom-basic-optimizer": {
"command": "python3",
"args": ["-m", "bom_basic_optimizer.server"],
"cwd": "/absolute/path/to/kicad-bom-basic-optimizer"
}
}
}Codex (~/.codex/config.toml)
[mcp_servers.kicad_bom_basic_optimizer]
command = "python3"
args = ["-m", "bom_basic_optimizer.server"]
cwd = "/absolute/path/to/kicad-bom-basic-optimizer"AI Coding Agent Skill (SKILL.md)
Drop SKILL.md into your repository's .agents/skills/kicad-bom-basic-optimizer/ or .claude/skills/kicad-bom-basic-optimizer/ folder so coding agents automatically run BOM hygiene checks and protect A↓/B precision/power components before suggesting swaps.
Running Tests
python3 -m unittest discover -s tests -vFull Web App & Cross-Reference Catalog
This open-source MIT CLI ships with a curated offline snapshot of the most common JLCPCB Basic passives and semiconductors. When you need:
An instant zero-upload browser tool (drag-and-drop KiCad/Altium/EasyEDA BOMs with strict local execution),
Broader parametric cross-reference tables (voltage regulators, MOSFETs, ESD/TVS diodes, CAN transceivers, op-amps, and SMD passives),
Side-by-side spec comparison and printable review sheets,
visit https://partcrosslab.pages.dev.
Disclaimer: JLCPCB Basic vs. Extended catalog status and LCSC stock levels can change over time. Always confirm live tier & stock in the JLCPCB PCBA viewer before placing an assembly order.
License
MIT — see LICENSE.
Available Tools
2 toolsanalyze_kicad_bomA
Parse a KiCad, Altium, or EasyEDA BOM CSV (via file_path or inline csv_content), run manufacturing health checks, map Extended SMD passives and popular semiconductors to JLCPCB Basic equivalents with A↑/A±/A↓/B grading, and compute $3/part feeder-fee savings.
Inputs: file_path, csv_content, source_name, output_format, +1 more.
find_jlcpcb_basic_alternativeB
Look up a single component MPN or SMD passive specification (e.g. 'RC0603FR-0710KL', '100nF 16V X7R', 'LM1117IMPX-3.3', 'USBLC6-2SC6', 'CH340G') and return a graded (A↑ / A± / A↓ / B) JLCPCB Basic equivalent with engineering cautions.
Inputs: query (required), lcsc, value, package.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 2 tools
The two tools target clearly different scopes: analyze_kicad_bom handles full BOM files/inline CSVs, while find_jlcpcb_basic_alternative handles a single MPN or passive specification. There is conceptual overlap in JLCPCB Basic mapping, but the input granularity makes selection unambiguous.
Both names use snake_case with a leading verb and descriptive object: analyze_kicad_bom and find_jlcpcb_basic_alternative. The convention is predictable and readable despite the differing verbs.
Two tools are minimal but fit the focused purpose: one batch BOM analysis and one single-component lookup. It is slightly thin compared with typical 3-15 tool servers, but each tool has a clear role.
The surface covers the core lifecycle of parsing a BOM, running health checks, mapping to JLCPCB Basic, grading, and estimating feeder-fee savings, plus a single-part lookup path. Minor gaps exist around exporting or applying an optimized BOM, but agents can work with the returned analysis.
Related MCP Connectors
Run ERC, DRC, parity, BOM and export checks on KiCad 9 boards before manufacturing.
Search real parts with datasheet-provenance specs, check compatibility and compose priced BOMs.
Find electronic parts with live Mouser, DigiKey and JLCPCB stock and prices, check BOMs, order.
Design, route, check, review and export manufacturable PCBs from plain language; KiCad import.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables KiCad CLI automation via MCP, providing tools for ERC, DRC, BOM export, netlist export, Gerbers, drill files, STEP, IPC-2581, and GLB output.10Apache 2.0
- AlicenseAqualityCmaintenanceEnables automated KiCad-adjacent workflows by parsing and round-tripping S-expression files, classifying DRC/ERC reports, and generating pin-header footprints without a running KiCad instance.4MIT
- AlicenseNot gradedqualityCmaintenanceProvides read-only MCP tools for parsing KiCad netlists and schematics, running evidence-based audits, and generating deterministic sizing and BOMs.MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI assistants to design and edit PCBs through natural language, including project setup, schematic editing, component placement, custom symbol and footprint generation, routing, DRC/ERC checks, and production file export. It also integrates JLCPCB parts catalog data, Freerouting automation, and visual snapshots for cross-platform Windows, Linux, and macOS workflows.61 npmMIT