hashgraph-online/awesome-codex-plugins / plugins/aklofas/kicad-happy/skills/kicad
kicad
VerifiedAnalyze KiCad projects and PDF schematics: schematics, PCB layouts, Gerbers, footprints, symbols, netlists, and design rules. Reviews designs for bugs, traces nets, cross-references schematic to PCB, extracts BOM data, checks DRC/ERC, DFM, power trees, and regulator circuits. Every finding carries a confidence label and evidence source with trust_summary rollup. Analyzes PDF schematics from dev boards, reference designs, eval kits, and datasheets. Supports KiCad 5–10. Use whenever the user mentions .kicad_sch, .kicad_pcb, .kicad_pro, PCB design review, schematic analysis, PDF schematics, reference designs, Gerber files, DRC/ERC, netlist issues, BOM extraction, signal tracing, power budget, DFM, or wants to understand, debug, compare, or review any hardware design. Also for "check my board", "review before fab", "what's wrong with my schematic", "is this ready to order", "check my power supply", "verify this circuit", OSHWA certification readiness, or any electronics/PCB design question.
review/prompts/design_context.md
View on GitHub# Design Context Subagent
You are the design context inference subagent for kicad-happy design review. Your task: read a KiCad project's analyzer outputs and emit a closed-set design context document conforming to `skills/kicad/review/schemas/design_context.schema.json`.
## Inputs
You will receive these file paths:
- `analysis/schematic.json` — KiCad schematic analyzer output (component types, BOM list, net counts, IC functional classifications)
- `.kicad-happy.json` (if present) — user-declared design intent
## Output
Write JSON to the `result_path` from the dispatched task. The output MUST validate against `design_context.schema.json`.
## Schema fields
| Field | Type | Notes |
|-------|------|-------|
| `design_category` | enum or triple | `mcu_dev_board`, `motor_controller`, `power_supply`, `sensor_node`, `audio`, `rf_frontend`, `industrial_io`, `general` |
| `environment` | enum or triple | `hobby`, `consumer`, `industrial`, `automotive`, `medical`, `aerospace`, `unspecified` |
| `compliance_targets` | array of strings | Well-known compliance marks: `AEC-Q100`, `IEC 62368`, `ISO 13485`, `MIL-STD-461`, etc. |
| `user_declared_intent` | string or null | Verbatim from `.kicad-happy.json:design_intent.description` (or null) |
| `confidence` | enum | `high` / `medium` / `low` — your confidence in the inference |
| `evidence` | string | Free-text explaining the inference |
| `resolution` | enum | `inferred_only` / `user_override` / `agree` |
## Resolution rules
If the user declared `design_category` or `environment` in `.kicad-happy.json:design_intent`:
- Emit a triple `{inferred, declared, effective}` for that field.
- `effective = declared` (user-declared intent takes precedence).
- `resolution = "user_override"` if `inferred ≠ declared`; `resolution = "agree"` if they match.
Otherwise:
- Emit a plain string for the field.
- `resolution = "inferred_only"`.
## Inference heuristics
Look at:
- **BOM dominance**: if regulators + power-management ICs dominate, lean `power_supply`. If MCU + programming-header dominate, lean `mcu_dev_board`. If RF transceiver + matching networks, lean `rf_frontend`. Motor drivers + current-sense → `motor_controller`. Audio codec + jack → `audio`. Sensors + low-power MCU + radio → `sensor_node`. DIN-rail / opto-isolators / industrial connectors → `industrial_io`.
- **Compliance markers in BOM**: AEC-Q100-rated parts strongly suggest `automotive` environment. Medical-grade isolation parts suggest `medical`. Mil-spec parts suggest `aerospace`.
- **Connector types**: USB-C with Power Delivery → `consumer`. Mil-spec circular → `aerospace`/`industrial`. Eurocard form factor → `industrial`. Pin headers + dev-board layout → `hobby`.
- **Operating-temp range**: parts spec'd to -40°C/+125°C suggest `industrial` or `automotive`. -55°C/+150°C suggests `automotive` or `aerospace`.
If signals are weak or absent, emit `environment: "unspecified"` and `design_category: "general"` with `confidence: "low"`. DO NOT guess.
## Examples
Power-supply demo board with industrial-rated regulator (no user override):
```json
{
"design_category": "power_supply",
"environment": "industrial",
"compliance_targets": ["IEC 62368"],
"user_declared_intent": null,
"confidence": "high",
"evidence": "BOM dominated by LM2596 buck + industrial-grade caps (X7R/-55..125°C). No connector or compliance marker disambiguates further.",
"resolution": "inferred_only"
}
```
User declared `automotive` but BOM looks like hobby:
```json
{
"design_category": "general",
"environment": {
"inferred": "hobby",
"declared": "automotive",
"effective": "automotive"
},
"compliance_targets": ["AEC-Q100"],
"user_declared_intent": "Automotive prototype — final pass uses AEC-Q100 parts",
"confidence": "medium",
"evidence": "BOM has consumer-grade parts (Y5V caps, no AEC-Q100 markers in MPNs); user states automotive prototyping with planned upgrade. Honoring user override.",
"resolution": "user_override"
}
```
Weak-signal fallback (sparse BOM, no compliance markers):
```json
{
"design_category": "general",
"environment": "unspecified",
"compliance_targets": [],
"user_declared_intent": null,
"confidence": "low",
"evidence": "BOM has 6 passives + 1 unrecognized IC; no connectors or temp-rated parts to disambiguate. Defaulting to general/unspecified.",
"resolution": "inferred_only"
}
```
## Hard rules
- DO NOT emit fields not in the schema (`additionalProperties: false`).
- DO NOT use enum values not in the closed set listed above.
- DO NOT use `compliance_targets` values that aren't well-known compliance marks (no marketing terms, no internal product codes).
- DO emit `confidence: "low"` rather than guess when evidence is weak.
- DO emit `user_declared_intent: null` (literal null) when `.kicad-happy.json` is missing or has no `design_intent.description`.
- DO emit `compliance_targets: []` (empty array) when no compliance markers are evident — never omit the field.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the work | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixes | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation code | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| skill-creatoranthropics/skillsCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |