Skip to content

hashgraph-online/awesome-codex-plugins / plugins/aklofas/kicad-happy/skills/kicad

Analyze 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.

FileKindSize
SKILL.mdskill md79.1 KB
references/config-reference.mdmarkdown19.1 KB
references/datasheet-verification.mdmarkdown16.5 KB
references/deep-review.mdmarkdown9.7 KB
references/design-intent.mdmarkdown5.6 KB
references/diff-analysis.mdmarkdown17.6 KB
references/file-formats.mdmarkdown15.1 KB
references/gerber-parsing.mdmarkdown33.5 KB
references/manual-gerber-parsing.mdmarkdown24.5 KB
references/manual-pcb-parsing.mdmarkdown17.2 KB
references/manual-schematic-parsing.mdmarkdown12.8 KB
references/net-tracing.mdmarkdown12.0 KB
references/oshwa-certification.mdmarkdown4.5 KB
references/output-schema.mdmarkdown33.4 KB
references/pcb-layout-analysis.mdmarkdown27.3 KB
references/pdf-schematic-extraction.mdmarkdown15.2 KB
references/report-generation.mdmarkdown56.3 KB
references/schematic-analysis.mdmarkdown63.9 KB
references/standards-compliance.mdmarkdown33.5 KB
references/supplementary-data-sources.mdmarkdown12.5 KB
references/what-if.mdmarkdown19.5 KB
review/README.mdmarkdown4.1 KB
review/fixtures/deep_review.example.jsonconfig1.2 KB
review/fixtures/design_context.example.jsonconfig388 B
review/fixtures/review_annotations.example.jsonconfig707 B
review/prompts/design_context.mdmarkdown4.9 KB
review/schemas/deep_review.schema.jsonconfig3.3 KB
review/schemas/design_context.schema.jsonconfig2.2 KB
review/schemas/review_annotations.schema.jsonconfig1.9 KB
review/scripts/_mini_jsonschema.pyscript6.6 KB
review/scripts/build_review_plan.pyscript2.3 KB
review/scripts/deep_review_gate.pyscript27.3 KB
review/scripts/merge_annotations.pyscript7.0 KB
review/scripts/validate_review.pyscript2.6 KB
scripts/.gitignoreother13 B
scripts/README.mdmarkdown23.4 KB
scripts/analysis_cache.pyscript42.1 KB
scripts/analyze_gerbers.pyscript90.9 KB
scripts/analyze_pcb.pyscript7.4 KB
scripts/analyze_schematic.pyscript6.7 KB
scripts/analyze_thermal.pyscript48.5 KB
scripts/analyzer_envelope.pyscript15.5 KB
scripts/capability_mode.pyscript10.2 KB
scripts/check_report_sections.pyscript10.6 KB
scripts/cross_analysis.pyscript69.4 KB
scripts/cross_verify.pyscript23.1 KB
scripts/design_intent.pyscript13.5 KB
scripts/detection_schema.pyscript26.0 KB
scripts/detector_helpers.pyscript15.2 KB
scripts/diff_analysis.pyscript23.5 KB
scripts/diff_engine.pyscript47.2 KB
scripts/domain_detectors.pyscript260.5 KB
scripts/envelopes/__init__.pyscript0 B
scripts/envelopes/cross_analysis.pyscript5.9 KB
scripts/envelopes/gerber.pyscript16.1 KB
scripts/envelopes/pcb.pyscript25.9 KB
scripts/envelopes/schematic.pyscript23.1 KB
scripts/envelopes/thermal.pyscript7.4 KB
scripts/export_issues.pyscript27.6 KB
scripts/fab_release_gate.pyscript29.8 KB
scripts/finding_schema.pyscript25.7 KB
scripts/gen_output_schema_md.pyscript9.2 KB
scripts/inputs_builder.pyscript4.0 KB
scripts/kicad_core/__init__.pyscript0 B
scripts/kicad_core/classify.pyscript32.5 KB
scripts/kicad_core/cli.pyscript4.2 KB
scripts/kicad_core/coords.pyscript2.0 KB
scripts/kicad_core/diagnostics.pyscript1.9 KB
scripts/kicad_core/executables.pyscript1.0 KB
scripts/kicad_core/fields.pyscript5.9 KB
scripts/kicad_core/fileio.pyscript5.4 KB
scripts/kicad_core/hotloop.pyscript3.1 KB
scripts/kicad_core/instances.pyscript5.7 KB
scripts/kicad_core/model.pyscript4.8 KB
scripts/kicad_core/netnames.pyscript19.1 KB
scripts/kicad_core/netquery.pyscript6.7 KB
scripts/kicad_core/pairing.pyscript1.9 KB
scripts/kicad_core/parts.pyscript28.9 KB
scripts/kicad_core/passives.pyscript10.0 KB
scripts/kicad_core/pdn.pyscript1011 B
scripts/kicad_core/project.pyscript43.2 KB
scripts/kicad_core/render.pyscript2.7 KB
scripts/kicad_core/sexp.pyscript12.6 KB
scripts/kicad_core/textvars.pyscript5.4 KB
scripts/kicad_core/token_cache.pyscript2.2 KB
scripts/kicad_core/values.pyscript14.1 KB
scripts/kicad_types.pyscript15.1 KB
scripts/lifecycle_audit.pyscript6.7 KB
scripts/lifecycle_engine.pyscript52.8 KB
scripts/lookup_detectors.pyscript29.9 KB
scripts/lookup_helpers.pyscript3.0 KB
scripts/methodology_gerbers.mdmarkdown23.1 KB
scripts/methodology_pcb.mdmarkdown22.2 KB
scripts/methodology_schematic.mdmarkdown43.1 KB
scripts/netlist_queries.pyscript4.2 KB
scripts/output_filters.pyscript16.8 KB
scripts/output_io.pyscript5.3 KB
scripts/pcb/__init__.pyscript0 B
scripts/pcb/assembly.pyscript58.3 KB
scripts/pcb/connectivity.pyscript27.7 KB
scripts/pcb/copper.pyscript61.0 KB
scripts/pcb/dfm.pyscript56.9 KB
scripts/pcb/geometry.pyscript59.5 KB
scripts/pcb/pipeline.pyscript30.3 KB
scripts/pcb/presentation.pyscript24.3 KB
scripts/pcb/reader.pyscript87.1 KB
scripts/pcb/routing.pyscript53.5 KB
scripts/project_config.pyscript23.1 KB
scripts/risk_summary.pyscript3.1 KB
scripts/run_id.pyscript1.7 KB
scripts/schema_codec.pyscript5.0 KB
scripts/schematic/__init__.pyscript0 B
scripts/schematic/audits.pyscript56.0 KB
scripts/schematic/bom_stats.pyscript6.1 KB
scripts/schematic/connectivity.pyscript62.9 KB
scripts/schematic/erc_pins.pyscript8.4 KB
scripts/schematic/hierarchy.pyscript21.5 KB
scripts/schematic/ic_analysis.pyscript21.4 KB
scripts/schematic/legacy_reader.pyscript49.4 KB
scripts/schematic/net_analysis.pyscript75.5 KB
scripts/schematic/pipeline.pyscript72.2 KB
scripts/schematic/presentation.pyscript20.9 KB
scripts/schematic/reader.pyscript64.7 KB
scripts/schematic/system_analyses.pyscript126.9 KB
scripts/signal_detectors.pyscript248.0 KB
scripts/summarize_findings.pyexecutablescript17.4 KB
scripts/validation_detectors.pyscript75.3 KB
scripts/what_if.pyscript68.4 KB

references/deep-review.md

View on GitHub
# Deep Review Pass — Methodology

The Deep Review pass is a per-IC comparison of actual usage against
datasheet requirements, with findings recorded durably in
`analysis/deep_review.json` and checked by the evidence gate: cited
components, nets and pins must exist in the run's analyzer JSON, and each
datasheet quote must appear on its page. A finding the gate could not check in
full is kept with `evidence_checked: partial`; treat that part of its evidence
as unverified. This guide holds the depth the SKILL.md loop points to:
comparison heuristics per part class, interacting-pair patterns,
helper-script conventions, evidence quality, and fan-out for big
BOMs. Checks are DERIVED from each part's datasheet — the lists
below are starting points, not ceilings.

`<skill-path>` is the installed kicad skill directory. Run the
commands below from the hardware project directory.

## Comparison heuristics by part class

**Regulators (LDO / buck / boost / SMPS controllers)**
- Vin range vs the actual input rail (worst case, not nominal —
  include supply tolerance and transients).
- Vout set point: recompute the FB divider (target = Vref × (1 +
  Rtop/Rbot)); compare against the rail name and downstream parts.
- Required externals vs datasheet minimums: inductance floor,
  input/output capacitance (and its effective value after DC bias
  derating), bootstrap caps, feed-forward caps.
- Enable pin: threshold vs the driving voltage; strap resistors vs
  leakage.
- Power-good: pull-up present? Voltage domain of the pull-up?
- Thermal: P_diss ≈ (Vin−Vout)×Iout for linears; compare Rθ_JA ×
  P_diss + T_amb against Tj_max (the thermal analyzer's assessment
  is the starting fact).
- Soft-start / sequencing requirements against the power tree.

**MCUs / SoCs**
- Supply range and per-domain decoupling vs datasheet placement
  requirements (per-pin caps, bulk).
- Reset circuit vs required RC / supervisor thresholds.
- Crystal: load capacitance math (CL = (C1×C2)/(C1+C2) + Cstray)
  vs the crystal's spec; drive level.
- USB: series resistors, required external pull-ups per speed, VBUS
  tolerance of the PHY pins.
- Boot straps: pull direction vs the intended boot source.
- 5 V tolerance: any pin fed from a higher domain than its supply.

**Op-amps / comparators**
- Supply vs input common-mode range at the actual input voltages
  (rail-to-rail in? out?).
- Output swing vs load and what the downstream stage needs.
- Stability: capacitive load vs datasheet limit; missing isolation
  resistor or compensation.

**Interface / level shifters / transceivers**
- Direction and voltage of each side vs the connected domains.
- Bus speed vs part rating; termination and idle-state biasing
  (RS-485 fail-safe, CAN split termination).

**MOSFETs / power switches / drivers**
- Vgs(th) and Rds(on)-at-Vgs vs the actual gate drive voltage
  (logic-level gate vs 10 V spec is the classic catch).
- Vds/Id margins vs rail + load, including inductive spikes.
- Gate resistor + driver current vs switching frequency.

**Diodes / LEDs / protection**
- If/Vf at operating current; reverse rating vs the blocked rail.
- TVS working voltage vs the protected rail's normal high; clamping
  voltage vs the protected pin's absolute max.

**Connectors** — current per pin vs load (cross_analysis CC-001 is
the fact source), mating cycles, keying/pinout vs the mating side.

## Interacting-pair checks

After the per-IC loop, look between parts:
- **Shared rails:** sum the worst-case loads vs the regulator's
  rating; check any sequencing requirements one IC imposes on
  another (core-before-IO, PG chaining).
- **Bus partners:** for each bus (I2C/SPI/UART/CAN/USB), check both
  ends' logic thresholds against the shared rail (VIH of the reader
  vs VOH of the driver), pull-up ownership and net value (parallel
  pull-ups!), and speed compatibility.
- **Thermal neighbors:** hot parts adjacent on the board (thermal
  analyzer proximity facts) whose combined dissipation invalidates
  each other's single-part Rθ assumptions.

## Helper-script conventions

Write disposable, design-specific scripts under `analysis/helpers/`:
- Name them `check_<topic>.py`; stdlib-only.
- Read facts from the analyzer JSON (pass paths on argv) — don't
  re-parse KiCad files.
- Print human-readable result lines with the numbers in them; the
  key line goes verbatim into `evidence.computation.result`.
- Keep the scripts (do not delete after use) — they are cited
  evidence and must resolve when the gate re-runs.

## Recording and evidence quality

Record findings in `analysis/deep_review.json` per
`<skill-path>/review/schemas/deep_review.schema.json`:
- `category` is free-form but reuse a small stable vocabulary within
  a project (e.g. `power_input`, `power_sequencing`, `bus_levels`,
  `thermal`, `protection`, `required_externals`) — the diff and the
  summary group by it.
- Datasheet quotes must be verbatim text from the cited page — the
  gate greps the page via pdftotext; paraphrases quarantine. The PDF is the
  one `datasheets/manifest.json` names for the MPN (a download marked as the
  wrong part is not used), else `<MPN>.pdf`, else the one `<MPN>_*.pdf` that
  the manifest does not name for another part. If the PDF is not found,
  `pdftotext` is not installed, cannot run, or exits with an error other
  than a missing page, the quote is not checked and the finding is
  `partial`. A cited page below 1, or past the last page of the PDF,
  quarantines the finding. Mid-quote elision (`...` or `…`) is fine for
  trimming a long quote down to the relevant clauses — each segment on
  either side must still appear on the page, in order.
- Page numbers are PDF page indexes (what pdftotext counts), not the
  printed page footer.
- Computations cite the helper script path and paste its result line. The
  gate checks that the script exists but does not run it, so a finding with a
  computation is recorded as `evidence_checked: partial`. `full` means every
  cited datasheet quote was found on its page and nothing else was cited
  unchecked.
- A cited net passes the gate if it exists anywhere in the run's analyzer
  JSON under any of its identities: schematic name, `display_name`, or
  PCB net name (case-insensitive).
- A cited pin is `REF.PIN` by pin number or pin name (`U3.7`, `U3.VIN`,
  case-insensitive). It passes if that component has that pin in the run's
  analyzer JSON; a floating pin counts. Names match case-insensitively, and
  `RESET` matches a pin named `~{RESET}` (KiCad's active-low markup). When an
  alternate pin function is selected the analyzer lists the alternate's name,
  so cite such pins by number.
  A pin of a component whose pins the analyzer JSON does not list (a part
  listed without pins, a PCB-only footprint with a pad on no net), or a pin
  name on a part listed by number only or on a part some of whose pins carry
  no name, is not checked and makes the finding `partial`.
- The gate finds the run folder from `analysis/manifest.json` and the
  run id inside `--analysis-dir` (`--run` picks another), so a moved or
  copied analysis folder still gates; no absolute path is stored.
- Severity and confidence are yours to assign — the trust story is
  the evidence, not a cap.

Gate, then deal with the fallout:

    python3 <skill-path>/review/scripts/deep_review_gate.py \
        analysis/deep_review.json --analysis-dir analysis/

`--project-dir` (for resolving `evidence.computation.script` paths)
defaults to `--analysis-dir`'s parent, and `--datasheets-dir` defaults to
`<project-dir>/datasheets` — pass `--project-dir` explicitly only when
the gate runs from outside the normal `<project>/analysis/` layout:

    python3 <skill-path>/review/scripts/deep_review_gate.py \
        /path/to/project/analysis/deep_review.json \
        --analysis-dir /path/to/project/analysis/ \
        --project-dir /path/to/project/

Quarantined entries are visible in the file with reasons. Fix the
citation (or drop the claim) and re-run — the gate re-evaluates
quarantined entries and promotes corrected ones. Anything left
quarantined renders in the report as an unverified claim.

## Re-review protocol

1. `cp analysis/deep_review.json analysis/deep_review.prev.json`
2. Run the pass fresh; gate it.
3. `python3 <skill-path>/scripts/diff_analysis.py analysis/deep_review.prev.json analysis/deep_review.json --text`
4. Report fixed / still-open / new. Treat `reworded_candidates` as
   advisory — confirm by reading, then report as still-open.

## Fan-out for big BOMs

Main-loop is the default. When the design is too big to hold (rough
threshold: >20 review-worthy ICs, or context pressure mid-pass):
- Chunk by subsystem (power tree, then digital core, then I/O) and
  run the loop per chunk yourself; or
- Dispatch one subagent per IC-group. Each subagent gets: the
  analyzer JSON paths, its IC list, the datasheet locations, and
  this guide; it returns a JSON array of findings (schema shape,
  no finding_id — the gate stamps ids). Concatenate the arrays into
  `findings[]`, then gate once, centrally.
- `analysis/design_context.json` (optional input) steers priorities:
  automotive → derating and temperature attention up; battery →
  quiescent current; RF → supply noise on analog rails.

## Degradation (never silent)

| Situation | Do this |
|---|---|
| No datasheets at all | Topology-only pass; per-IC "not verified against datasheet" gap lines in the report |
| Cache miss, PDF on disk | Read the PDF directly |
| No PDF, no API | Write "X unverified — no datasheet available" in the review text; it is not a `deep_review.json` finding |
| Extraction exists, low quality | It comes back with `quality.trusted: false` — decide: trust, or re-read the PDF |
| Gate failure | Finding sits in `quarantined[]` with a reason; report as unverified claim |
| Prior deep_review.json missing/old schema | Fresh review; say why in the delta section |
finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the workStars: 322kUpdated Claude CodeCodexVerifiedInstall
systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixesStars: 322kUpdated Claude CodeCodexVerifiedInstall
test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation codeStars: 322kUpdated Claude CodeCodexVerifiedInstall
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: 198kUpdated Claude CodeCodexVerifiedInstall