easyeda-mcp-pro 1.8.0 → 1.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/README.md +38 -74
  2. package/dist/circuit/circuit-ir.d.ts +6 -6
  3. package/dist/config/profiles.js +6 -6
  4. package/dist/config/profiles.js.map +1 -1
  5. package/dist/config/version.d.ts +1 -1
  6. package/dist/config/version.js +1 -1
  7. package/dist/design-rules/index.d.ts +2 -0
  8. package/dist/design-rules/index.js +1 -0
  9. package/dist/design-rules/index.js.map +1 -1
  10. package/dist/design-rules/isolation-emc-review.d.ts +73 -0
  11. package/dist/design-rules/isolation-emc-review.js +170 -0
  12. package/dist/design-rules/isolation-emc-review.js.map +1 -0
  13. package/dist/design-rules/trace-current-review.d.ts +41 -0
  14. package/dist/design-rules/trace-current-review.js +144 -0
  15. package/dist/design-rules/trace-current-review.js.map +1 -0
  16. package/dist/design-rules/trace-width.d.ts +26 -4
  17. package/dist/design-rules/trace-width.js +46 -18
  18. package/dist/design-rules/trace-width.js.map +1 -1
  19. package/dist/engineering-review/report.d.ts +119 -0
  20. package/dist/engineering-review/report.js +297 -0
  21. package/dist/engineering-review/report.js.map +1 -0
  22. package/dist/live/easyeda-smoke.js +9 -1
  23. package/dist/live/easyeda-smoke.js.map +1 -1
  24. package/dist/net-validation/datasheet-review.d.ts +69 -0
  25. package/dist/net-validation/datasheet-review.js +146 -0
  26. package/dist/net-validation/datasheet-review.js.map +1 -0
  27. package/dist/package-build-manifest.json +218 -68
  28. package/dist/pcb-constraints/manufacturing-profile-review.d.ts +51 -0
  29. package/dist/pcb-constraints/manufacturing-profile-review.js +218 -0
  30. package/dist/pcb-constraints/manufacturing-profile-review.js.map +1 -0
  31. package/dist/pcb-constraints/types.d.ts +8 -2
  32. package/dist/pcb-constraints/validation.js +157 -36
  33. package/dist/pcb-constraints/validation.js.map +1 -1
  34. package/dist/pcb-layout/differential-pair.d.ts +66 -0
  35. package/dist/pcb-layout/differential-pair.js +275 -0
  36. package/dist/pcb-layout/differential-pair.js.map +1 -0
  37. package/dist/pcb-layout/placement-evidence.d.ts +53 -0
  38. package/dist/pcb-layout/placement-evidence.js +134 -0
  39. package/dist/pcb-layout/placement-evidence.js.map +1 -0
  40. package/dist/pcb-layout/planner.js +48 -20
  41. package/dist/pcb-layout/planner.js.map +1 -1
  42. package/dist/pcb-layout/route-review.d.ts +70 -0
  43. package/dist/pcb-layout/route-review.js +182 -0
  44. package/dist/pcb-layout/route-review.js.map +1 -0
  45. package/dist/server/resources-prompts.js +4 -1
  46. package/dist/server/resources-prompts.js.map +1 -1
  47. package/dist/tools/L1_board.js +157 -41
  48. package/dist/tools/L1_board.js.map +1 -1
  49. package/dist/tools/L1_design_rules.js +194 -9
  50. package/dist/tools/L1_design_rules.js.map +1 -1
  51. package/dist/tools/L1_drc_erc.js +109 -10
  52. package/dist/tools/L1_drc_erc.js.map +1 -1
  53. package/dist/tools/L1_engineering_review.d.ts +6 -0
  54. package/dist/tools/L1_engineering_review.js +46 -0
  55. package/dist/tools/L1_engineering_review.js.map +1 -0
  56. package/dist/tools/L1_export.js +83 -1
  57. package/dist/tools/L1_export.js.map +1 -1
  58. package/dist/tools/L1_pcb_constraints.d.ts +6 -0
  59. package/dist/tools/L1_pcb_constraints.js +177 -37
  60. package/dist/tools/L1_pcb_constraints.js.map +1 -1
  61. package/dist/tools/L1_pcb_route_review.d.ts +9 -0
  62. package/dist/tools/L1_pcb_route_review.js +423 -0
  63. package/dist/tools/L1_pcb_route_review.js.map +1 -0
  64. package/dist/tools/L2_schematic_layout.d.ts +2 -2
  65. package/dist/tools/register.js +4 -0
  66. package/dist/tools/register.js.map +1 -1
  67. package/easyeda-bridge-extension.checksums.json +8 -8
  68. package/easyeda-bridge-extension.eext +0 -0
  69. package/package.json +1 -1
  70. package/skills/design-validation/SKILL.md +23 -0
  71. package/skills/design-validation/references/engineering-review.md +116 -0
  72. package/skills/easyeda-component-review/SKILL.md +11 -0
package/README.md CHANGED
@@ -1,69 +1,27 @@
1
1
  <div align="center">
2
2
 
3
- # easyeda-mcp-pro
3
+ # EasyEDA MCP Pro
4
4
 
5
- <p>
6
- Production-grade MCP server for EasyEDA Pro: safe PCB design inspection, BOM sourcing, manufacturing export, and AI-assisted hardware review.
7
- </p>
8
-
9
- <p>
10
- <a href="https://www.npmjs.com/package/easyeda-mcp-pro">
11
- <img src="https://img.shields.io/npm/v/easyeda-mcp-pro.svg?logo=npm" alt="npm version" />
12
- </a>
13
- <a href="https://www.npmjs.com/package/easyeda-mcp-pro">
14
- <img src="https://img.shields.io/npm/dt/easyeda-mcp-pro?logo=npm&label=total%20downloads" alt="npm total downloads" />
15
- </a>
16
- <a href="https://www.npmjs.com/package/easyeda-mcp-pro">
17
- <img src="https://img.shields.io/node/v/easyeda-mcp-pro" alt="supported Node.js version" />
18
- </a>
19
- <a href="LICENSE">
20
- <img src="https://img.shields.io/npm/l/easyeda-mcp-pro.svg" alt="license" />
21
- </a>
22
- <a href="https://pnpm.io/">
23
- <img src="https://img.shields.io/badge/pnpm-11.28.8-blue.svg" alt="pnpm" />
24
- </a>
25
- </p>
5
+ **Inspect, review, and safely automate EasyEDA Pro designs from MCP-compatible AI assistants.**
26
6
 
27
- <p>
28
- <a href="https://github.com/oaslananka/easyeda-mcp-pro/actions/workflows/ci.yml">
29
- <img src="https://github.com/oaslananka/easyeda-mcp-pro/actions/workflows/ci.yml/badge.svg" alt="CI status" />
30
- </a>
31
- <a href="https://github.com/oaslananka/easyeda-mcp-pro/actions/workflows/deploy-docs.yml">
32
- <img src="https://github.com/oaslananka/easyeda-mcp-pro/actions/workflows/deploy-docs.yml/badge.svg" alt="Docs status" />
33
- </a>
34
- <a href="https://github.com/oaslananka/easyeda-mcp-pro/security/policy">
35
- <img src="https://img.shields.io/badge/security-policy-blue" alt="Security policy" />
36
- </a>
37
- <a href="https://scorecard.dev/viewer/?uri=github.com/oaslananka/easyeda-mcp-pro">
38
- <img src="https://api.scorecard.dev/projects/github.com/oaslananka/easyeda-mcp-pro/badge" alt="OpenSSF Scorecard" />
39
- </a>
40
- </p>
41
-
42
- [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/oaslananka/easyeda-mcp-pro)
7
+ [Documentation](https://oaslananka.github.io/easyeda-mcp-pro/) · [Getting Started](https://oaslananka.github.io/easyeda-mcp-pro/guide/getting-started.html) · [Tool Reference](https://oaslananka.github.io/easyeda-mcp-pro/reference/tools.html) · [Compatibility](https://oaslananka.github.io/easyeda-mcp-pro/reference/easyeda-compatibility.html) · [Roadmap](docs/ROADMAP.md)
43
8
 
44
9
  <p>
45
- <a href="docs/ROADMAP.md">Roadmap</a> ·
46
- <a href="docs/OPENSSF_BEST_PRACTICES.md">OpenSSF evidence</a> ·
47
- <a href="docs/SECURITY_ASSURANCE_CASE.md">Security assurance case</a>
10
+ <a href="https://www.npmjs.com/package/easyeda-mcp-pro"><img src="https://img.shields.io/npm/v/easyeda-mcp-pro.svg?logo=npm" alt="npm version" /></a>
11
+ <a href="https://www.npmjs.com/package/easyeda-mcp-pro"><img src="https://img.shields.io/node/v/easyeda-mcp-pro" alt="supported Node.js version" /></a>
12
+ <a href="LICENSE"><img src="https://img.shields.io/npm/l/easyeda-mcp-pro.svg" alt="MIT license" /></a>
48
13
  </p>
49
14
 
50
15
  <p>
51
- <strong>Compliance docs:</strong>
52
- <a href="THIRD_PARTY_NOTICES.md">Third-Party Notices</a>
53
- ·
54
- <a href="docs/vendor-terms.md">Vendor Terms and Unsupported Workflows</a>
55
- ·
56
- <a href="docs/REMOTE_MCP_MODES.md">Remote MCP Modes</a>
16
+ <a href="https://github.com/oaslananka/easyeda-mcp-pro/actions/workflows/ci.yml"><img src="https://github.com/oaslananka/easyeda-mcp-pro/actions/workflows/ci.yml/badge.svg" alt="CI status" /></a>
17
+ <a href="https://github.com/oaslananka/easyeda-mcp-pro/actions/workflows/deploy-docs.yml"><img src="https://github.com/oaslananka/easyeda-mcp-pro/actions/workflows/deploy-docs.yml/badge.svg" alt="Docs status" /></a>
18
+ <a href="https://github.com/oaslananka/easyeda-mcp-pro/security/policy"><img src="https://img.shields.io/badge/security-policy-blue" alt="Security policy" /></a>
19
+ <a href="https://scorecard.dev/viewer/?uri=github.com/oaslananka/easyeda-mcp-pro"><img src="https://api.scorecard.dev/projects/github.com/oaslananka/easyeda-mcp-pro/badge" alt="OpenSSF Scorecard" /></a>
57
20
  </p>
58
21
 
59
22
  <p>
60
- <a href="https://www.buymeacoffee.com/oaslananka">
61
- <img src="https://img.buymeacoffee.com/button-api/?text=Buy%20me%20a%20coffee&emoji=%E2%98%95&slug=oaslananka&button_colour=FFDD00&font_colour=000000&font_family=Inter&outline_colour=000000&coffee_colour=ffffff" height="28" alt="Buy me a coffee" />
62
- </a>
63
- &nbsp;&nbsp;
64
- <a href="https://github.com/oaslananka/easyeda-mcp-pro">
65
- <img src="https://img.shields.io/github/stars/oaslananka/easyeda-mcp-pro?style=for-the-badge&logo=github&label=Star%20on%20GitHub&color=FFA500&labelColor=181717" alt="Star on GitHub" />
66
- </a>
23
+ <a href="https://deepwiki.com/oaslananka/easyeda-mcp-pro"><img src="https://deepwiki.com/badge.svg" alt="Ask DeepWiki" /></a>
24
+ <a href="https://gitgem.org/github/oaslananka/easyeda-mcp-pro"><img src="https://gitgem.org/api/badge/github/oaslananka/easyeda-mcp-pro.svg" alt="GitGem" /></a>
67
25
  </p>
68
26
 
69
27
  </div>
@@ -76,6 +34,10 @@ easyeda-mcp-pro keeps historical OpenSSF Best Practices evidence in [`docs/OPENS
76
34
 
77
35
  **Licensing note:** current repository source is MIT-licensed. Commercial use is permitted under MIT; historical releases retain the license notices shipped with them.
78
36
 
37
+ **More project references:** [OpenSSF evidence](docs/OPENSSF_BEST_PRACTICES.md) · [Security assurance](docs/SECURITY_ASSURANCE_CASE.md) · [Third-party notices](THIRD_PARTY_NOTICES.md) · [Vendor terms](docs/vendor-terms.md) · [Remote MCP modes](docs/REMOTE_MCP_MODES.md)
38
+
39
+ **Support development:** [Buy me a coffee](https://www.buymeacoffee.com/oaslananka) · [Star on GitHub](https://github.com/oaslananka/easyeda-mcp-pro)
40
+
79
41
  ---
80
42
 
81
43
  ## Quick Start
@@ -109,7 +71,7 @@ For advanced configurations, manual instructions, and specific clients, see [Ins
109
71
 
110
72
  ## Overview
111
73
 
112
- easyeda-mcp-pro is a [Model Context Protocol (MCP)](https://modelcontextprotocol.io) server that bridges AI assistants with hardware design workflows in EasyEDA Pro. It exposes up to 120 profile-gated MCP tools for schematic inspection and editing, controlled EasyEDA Pro API calls, Personal Device metadata, BOM management, design rule checks, PCB board analysis, fabrication exports, diagnostics, and supplier integration.
74
+ easyeda-mcp-pro is a [Model Context Protocol (MCP)](https://modelcontextprotocol.io) server that bridges AI assistants with hardware design workflows in EasyEDA Pro. It exposes 126 profile-gated MCP tools for schematic inspection and editing, controlled EasyEDA Pro API calls, Personal Device metadata, BOM management, design rule checks, PCB board analysis, fabrication exports, diagnostics, and supplier integration.
113
75
 
114
76
  The server connects to EasyEDA Pro via a WebSocket bridge extension, enabling real-time access to open project data. It integrates with JLCPCB, LCSC, Mouser, and DigiKey for BOM sourcing and pricing.
115
77
 
@@ -594,11 +556,11 @@ The server registers profile-gated tools according to the active `TOOL_PROFILE`.
594
556
 
595
557
  | Profile | Registered tools |
596
558
  | -------------- | ---------------: |
597
- | `core` | 74 |
598
- | `pro` | 101 |
599
- | `full` | 117 |
600
- | `dev` | 122 |
601
- | `experimental` | 123 |
559
+ | `core` | 77 |
560
+ | `pro` | 104 |
561
+ | `full` | 120 |
562
+ | `dev` | 125 |
563
+ | `experimental` | 126 |
602
564
 
603
565
  <!-- capability-counts:end -->
604
566
 
@@ -668,6 +630,7 @@ The schematic write APIs use EasyEDA Pro extension APIs that EasyEDA currently m
668
630
  | `easyeda_drc_run` | Design rule check for PCB |
669
631
  | `easyeda_erc_run` | Electrical rule check for schematic |
670
632
  | `easyeda_rule_check_summary` | Combined DRC + ERC summary |
633
+ | `easyeda_engineering_review` | Read-only PCB evidence and coverage |
671
634
 
672
635
  ### L1 — Board (core)
673
636
 
@@ -702,7 +665,7 @@ The schematic write APIs use EasyEDA Pro extension APIs that EasyEDA currently m
702
665
  │ (via Plugin) │ Protocol │ └───────────────┘ │
703
666
  └─────────────────┘ │ ┌───────────────┐ │
704
667
  │ │ ToolRegistry │ │
705
- │ │ (up to 120 tools) │ │
668
+ │ │ (up to 126 tools) │ │
706
669
  │ └───────────────┘ │
707
670
  │ ┌───────────────┐ │
708
671
  │ │ Storage │──┼──► SQLite
@@ -749,19 +712,20 @@ repository should catalog this plugin, but the manifest and workflow instruction
749
712
  here so they stay synchronized with the actual MCP server, bridge extension, tool
750
713
  profiles, and EasyEDA runtime behavior.
751
714
 
752
- | File | Purpose |
753
- | -------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
754
- | [`.claude-plugin/plugin.json`](.claude-plugin/plugin.json) | Claude Code-valid plugin manifest for compatible agent runtimes and marketplace catalogs. |
755
- | [`.mcp.json`](.mcp.json) | Project-local Claude Code MCP server configuration. |
756
- | [`.codex/config.example.toml`](.codex/config.example.toml) | Codex CLI MCP configuration example. |
757
- | [`.vscode/mcp.example.json`](.vscode/mcp.example.json) | VS Code / GitHub Copilot workspace MCP configuration example. |
758
- | [`opencode.example.jsonc`](opencode.example.jsonc) | OpenCode project MCP configuration example. |
759
- | [`.opencode/skills/`](.opencode/skills) | OpenCode-native mirrored skill definitions. |
760
- | [`docs/agent-runtime-config.md`](docs/agent-runtime-config.md) | Agent runtime setup and validation matrix. |
761
- | [`skills/easyeda-workflow/SKILL.md`](skills/easyeda-workflow/SKILL.md) | End-to-end EasyEDA setup, inspection, controlled write, export, and reporting workflow. |
762
- | [`skills/component-search/SKILL.md`](skills/component-search/SKILL.md) | Component search, BOM review, sourcing, pricing, availability, and part-risk workflow. |
763
- | [`skills/design-validation/SKILL.md`](skills/design-validation/SKILL.md) | DRC/ERC, semantic ERC, PCB constraints, production QA, export, and release-validation workflow. |
764
- | [`skills/easyeda-component-review/SKILL.md`](skills/easyeda-component-review/SKILL.md) | Datasheet, actual footprint and bound 3D model review, with structured evidence saved in a Personal Device. |
715
+ | File | Purpose |
716
+ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ |
717
+ | [`.claude-plugin/plugin.json`](.claude-plugin/plugin.json) | Claude Code-valid plugin manifest for compatible agent runtimes and marketplace catalogs. |
718
+ | [`.mcp.json`](.mcp.json) | Project-local Claude Code MCP server configuration. |
719
+ | [`.codex/config.example.toml`](.codex/config.example.toml) | Codex CLI MCP configuration example. |
720
+ | [`.vscode/mcp.example.json`](.vscode/mcp.example.json) | VS Code / GitHub Copilot workspace MCP configuration example. |
721
+ | [`opencode.example.jsonc`](opencode.example.jsonc) | OpenCode project MCP configuration example. |
722
+ | [`.opencode/skills/`](.opencode/skills) | OpenCode-native mirrored skill definitions. |
723
+ | [`docs/agent-runtime-config.md`](docs/agent-runtime-config.md) | Agent runtime setup and validation matrix. |
724
+ | [`skills/easyeda-workflow/SKILL.md`](skills/easyeda-workflow/SKILL.md) | End-to-end EasyEDA setup, inspection, controlled write, export, and reporting workflow. |
725
+ | [`skills/component-search/SKILL.md`](skills/component-search/SKILL.md) | Component search, BOM review, sourcing, pricing, availability, and part-risk workflow. |
726
+ | [`skills/design-validation/SKILL.md`](skills/design-validation/SKILL.md) | DRC/ERC, semantic ERC, PCB constraints, production QA, export, and release-validation workflow. |
727
+ | [`skills/design-validation/references/engineering-review.md`](skills/design-validation/references/engineering-review.md) | Canonical on-demand phase router for source-aware schematic, layout, DRC, DFM/DFT and human evidence review. |
728
+ | [`skills/easyeda-component-review/SKILL.md`](skills/easyeda-component-review/SKILL.md) | Datasheet, actual footprint and bound 3D model review, with structured evidence saved in a Personal Device. |
765
729
 
766
730
  ### Agent setup
767
731
 
@@ -104,9 +104,9 @@ export declare const PowerDomainSchema: z.ZodObject<{
104
104
  maxCurrentAmps: z.ZodOptional<z.ZodNumber>;
105
105
  isolation: z.ZodDefault<z.ZodEnum<{
106
106
  none: "none";
107
- galvanic: "galvanic";
108
107
  functional: "functional";
109
108
  reinforced: "reinforced";
109
+ galvanic: "galvanic";
110
110
  }>>;
111
111
  designIntentRef: z.ZodDefault<z.ZodArray<z.ZodObject<{
112
112
  requirementId: z.ZodString;
@@ -133,8 +133,8 @@ export declare const SignalClassSchema: z.ZodObject<{
133
133
  rf: "rf";
134
134
  digital: "digital";
135
135
  clock: "clock";
136
- can: "can";
137
136
  "high-speed": "high-speed";
137
+ can: "can";
138
138
  differential: "differential";
139
139
  sensitive: "sensitive";
140
140
  }>;
@@ -174,10 +174,10 @@ export declare const PhysicalConstraintSchema: z.ZodObject<{
174
174
  mechanical: "mechanical";
175
175
  thermal: "thermal";
176
176
  keepout: "keepout";
177
+ testability: "testability";
177
178
  height: "height";
178
179
  creepage: "creepage";
179
180
  accessibility: "accessibility";
180
- testability: "testability";
181
181
  }>;
182
182
  severity: z.ZodDefault<z.ZodEnum<typeof ConstraintSeverity>>;
183
183
  targetType: z.ZodEnum<{
@@ -447,9 +447,9 @@ export declare const CircuitIRSchema: z.ZodObject<{
447
447
  maxCurrentAmps: z.ZodOptional<z.ZodNumber>;
448
448
  isolation: z.ZodDefault<z.ZodEnum<{
449
449
  none: "none";
450
- galvanic: "galvanic";
451
450
  functional: "functional";
452
451
  reinforced: "reinforced";
452
+ galvanic: "galvanic";
453
453
  }>>;
454
454
  designIntentRef: z.ZodDefault<z.ZodArray<z.ZodObject<{
455
455
  requirementId: z.ZodString;
@@ -475,8 +475,8 @@ export declare const CircuitIRSchema: z.ZodObject<{
475
475
  rf: "rf";
476
476
  digital: "digital";
477
477
  clock: "clock";
478
- can: "can";
479
478
  "high-speed": "high-speed";
479
+ can: "can";
480
480
  differential: "differential";
481
481
  sensitive: "sensitive";
482
482
  }>;
@@ -515,10 +515,10 @@ export declare const CircuitIRSchema: z.ZodObject<{
515
515
  mechanical: "mechanical";
516
516
  thermal: "thermal";
517
517
  keepout: "keepout";
518
+ testability: "testability";
518
519
  height: "height";
519
520
  creepage: "creepage";
520
521
  accessibility: "accessibility";
521
- testability: "testability";
522
522
  }>;
523
523
  severity: z.ZodDefault<z.ZodEnum<typeof ConstraintSeverity>>;
524
524
  targetType: z.ZodEnum<{
@@ -2,36 +2,36 @@ export const PROFILE_DEFINITIONS = {
2
2
  core: {
3
3
  name: 'core',
4
4
  label: 'Core',
5
- description: 'High-confidence tools: diagnostics, EasyEDA API inventory, schematic, BOM, DRC/ERC, board layers/stackup, Gerber export',
6
- approxToolCount: '74',
5
+ description: 'High-confidence tools: diagnostics, EasyEDA API inventory, schematic, BOM, DRC/ERC, board layers/stackup, drilled-pad inspection, active DRC rules, Gerber export',
6
+ approxToolCount: '77',
7
7
  isDefault: true,
8
8
  },
9
9
  pro: {
10
10
  name: 'pro',
11
11
  label: 'Pro',
12
12
  description: 'Adds pick-and-place, PDF, netlist export, compound transactional workflow tools, autorouting, route-context export, and offline SPICE verification for manufacturing workflows',
13
- approxToolCount: '101',
13
+ approxToolCount: '104',
14
14
  isDefault: false,
15
15
  },
16
16
  full: {
17
17
  name: 'full',
18
18
  label: 'Full',
19
19
  description: 'Adds controlled documented EasyEDA API method calls and CircuitIR-driven floorplanning for full runtime control without raw JavaScript execution',
20
- approxToolCount: '117',
20
+ approxToolCount: '120',
21
21
  isDefault: false,
22
22
  },
23
23
  dev: {
24
24
  name: 'dev',
25
25
  label: 'Dev',
26
26
  description: 'Adds diagnostics probes for bridge methods and live component runtime shape inspection',
27
- approxToolCount: '122',
27
+ approxToolCount: '125',
28
28
  isDefault: false,
29
29
  },
30
30
  experimental: {
31
31
  name: 'experimental',
32
32
  label: 'Experimental',
33
33
  description: 'MCP Apps, Tasks, AI action plans',
34
- approxToolCount: '123',
34
+ approxToolCount: '126',
35
35
  isDefault: false,
36
36
  },
37
37
  };
@@ -1 +1 @@
1
- {"version":3,"file":"profiles.js","sourceRoot":"","sources":["../../src/config/profiles.ts"],"names":[],"mappings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VERSION = '1.8.0'; // x-release-please-version
1
+ export const SERVER_VERSION = '1.9.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.js.map
@@ -9,3 +9,5 @@ export { lookupDecouplingGuidance, listDecouplingCategories, recommendBulkCapaci
9
9
  export type { DecouplingCategory, PerPinDecouplingGuidance, BulkCapacitanceRecommendation, } from './decoupling.js';
10
10
  export { listDfmChecklist, getDfmChecklistItem } from './dfm-checklist.js';
11
11
  export type { DfmCategory, DfmChecklistItem } from './dfm-checklist.js';
12
+ export { reviewTraceCurrent } from './trace-current-review.js';
13
+ export type { TraceCurrentReviewInput, TraceCurrentReview, TraceCurrentFinding, } from './trace-current-review.js';
@@ -4,4 +4,5 @@ export { lookupClearance } from './clearance.js';
4
4
  export { lookupProtocolRouting, listProtocolRoutingKeys } from './protocol-routing.js';
5
5
  export { lookupDecouplingGuidance, listDecouplingCategories, recommendBulkCapacitance, } from './decoupling.js';
6
6
  export { listDfmChecklist, getDfmChecklistItem } from './dfm-checklist.js';
7
+ export { reviewTraceCurrent } from './trace-current-review.js';
7
8
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/design-rules/index.ts"],"names":[],"mappings":"AAAA,6DAA6D;AAE7D,OAAO,EACL,mBAAmB,EACnB,mBAAmB,EACnB,4BAA4B,GAC7B,MAAM,kBAAkB,CAAC;AAS1B,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAGjD,OAAO,EAAE,qBAAqB,EAAE,uBAAuB,EAAE,MAAM,uBAAuB,CAAC;AAGvF,OAAO,EACL,wBAAwB,EACxB,wBAAwB,EACxB,wBAAwB,GACzB,MAAM,iBAAiB,CAAC;AAOzB,OAAO,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/design-rules/index.ts"],"names":[],"mappings":"AAAA,6DAA6D;AAE7D,OAAO,EACL,mBAAmB,EACnB,mBAAmB,EACnB,4BAA4B,GAC7B,MAAM,kBAAkB,CAAC;AAS1B,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAGjD,OAAO,EAAE,qBAAqB,EAAE,uBAAuB,EAAE,MAAM,uBAAuB,CAAC;AAGvF,OAAO,EACL,wBAAwB,EACxB,wBAAwB,EACxB,wBAAwB,GACzB,MAAM,iBAAiB,CAAC;AAOzB,OAAO,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAG3E,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC"}
@@ -0,0 +1,73 @@
1
+ /**
2
+ * Explicitly source-scoped insulation/EMC review. An observed shortfall from a
3
+ * caller-declared requirement is a warning, not independent IEC/IPC proof.
4
+ * No protected standard tables or default spacing thresholds are embedded.
5
+ */
6
+ export type InsulationPurpose = 'functional' | 'basic' | 'supplementary' | 'reinforced' | 'unspecified';
7
+ export type Environment = 'controlled-indoor' | 'industrial' | 'outdoor' | 'condensing' | 'unspecified';
8
+ export interface StandardReference {
9
+ identifier: string;
10
+ edition: string;
11
+ clause: string;
12
+ source: string;
13
+ }
14
+ export interface SpacingRequirement {
15
+ minimumMm: number;
16
+ reference: StandardReference;
17
+ }
18
+ export interface GeometryObservation {
19
+ distanceMm: number;
20
+ evidenceRef: string;
21
+ evidenceKind: 'measured_air_gap' | 'measured_surface_path' | 'estimated';
22
+ }
23
+ export interface IsolationEmcInput {
24
+ purpose?: InsulationPurpose;
25
+ workingVoltageV?: number;
26
+ transientVoltageV?: number;
27
+ environment?: Environment;
28
+ pollutionDegree?: 1 | 2 | 3 | 4;
29
+ overvoltageCategory?: 'I' | 'II' | 'III' | 'IV';
30
+ materialGroup?: 'I' | 'II' | 'IIIa' | 'IIIb';
31
+ altitudeM?: number;
32
+ safetyStandard?: StandardReference;
33
+ clearanceRequirement?: SpacingRequirement;
34
+ creepageRequirement?: SpacingRequirement;
35
+ airClearance?: GeometryObservation;
36
+ surfaceCreepage?: GeometryObservation;
37
+ boardSlotEvidence?: string;
38
+ coatingEvidence?: string;
39
+ esdEntry?: {
40
+ connectorRef: string;
41
+ protectorRef?: string;
42
+ entryNet?: string;
43
+ returnPathEvidence?: string;
44
+ testStandard?: StandardReference;
45
+ };
46
+ emcReturn?: {
47
+ fastLoopRef?: string;
48
+ returnPlaneEvidence?: string;
49
+ sensitiveCircuitRef?: string;
50
+ };
51
+ }
52
+ export interface IsolationEmcFinding {
53
+ id: 'AIR_CLEARANCE' | 'SURFACE_CREEPAGE' | 'INSULATION_CONTEXT' | 'ESD_ENTRY' | 'EMC_RETURN';
54
+ status: 'WARNING' | 'UNKNOWN';
55
+ message: string;
56
+ reported_mm?: number;
57
+ declared_min_mm?: number;
58
+ reference?: StandardReference;
59
+ evidence_refs: string[];
60
+ missing: string[];
61
+ }
62
+ export interface IsolationEmcReview {
63
+ status: 'WARNING' | 'UNKNOWN';
64
+ evidence: 'caller_supplied_unverified';
65
+ safety_certification: false;
66
+ qualified_review_required: boolean;
67
+ context_missing: string[];
68
+ findings: IsolationEmcFinding[];
69
+ limitations: string[];
70
+ source_references: StandardReference[];
71
+ engineering_sign_off: false;
72
+ }
73
+ export declare function reviewIsolationEmc(input: IsolationEmcInput): IsolationEmcReview;
@@ -0,0 +1,170 @@
1
+ /**
2
+ * Explicitly source-scoped insulation/EMC review. An observed shortfall from a
3
+ * caller-declared requirement is a warning, not independent IEC/IPC proof.
4
+ * No protected standard tables or default spacing thresholds are embedded.
5
+ */
6
+ function spacingEvidenceState(id, requirement, observation) {
7
+ const validMinimum = requirement !== undefined &&
8
+ Number.isFinite(requirement.minimumMm) &&
9
+ requirement.minimumMm >= 0;
10
+ const validDistance = observation !== undefined &&
11
+ Number.isFinite(observation.distanceMm) &&
12
+ observation.distanceMm >= 0;
13
+ const missing = [
14
+ ...(requirement === undefined ? ['source-declared minimum distance'] : []),
15
+ ...(requirement !== undefined && !validMinimum
16
+ ? ['finite nonnegative source-declared minimum']
17
+ : []),
18
+ ...(observation === undefined ? ['geometry measurement'] : []),
19
+ ...(observation !== undefined && !validDistance
20
+ ? ['finite nonnegative geometry measurement']
21
+ : []),
22
+ ];
23
+ const expectedKind = id === 'AIR_CLEARANCE' ? 'measured_air_gap' : 'measured_surface_path';
24
+ if (observation !== undefined && observation.evidenceKind !== expectedKind) {
25
+ missing.push(id === 'AIR_CLEARANCE'
26
+ ? 'measured through-air clearance between actual conductors'
27
+ : 'measured along-surface creepage path accounting for geometry and slots');
28
+ }
29
+ return { validMinimum, validDistance, missing };
30
+ }
31
+ function reviewSpacing(id, requirement, observation) {
32
+ const { validMinimum, validDistance, missing } = spacingEvidenceState(id, requirement, observation);
33
+ const base = {
34
+ id,
35
+ status: 'UNKNOWN',
36
+ message: 'Only explicit, source-declared dimensions are compared; independent safety compliance is not verified.',
37
+ evidence_refs: observation ? [observation.evidenceRef] : [],
38
+ missing,
39
+ ...(requirement
40
+ ? {
41
+ ...(validMinimum ? { declared_min_mm: requirement.minimumMm } : {}),
42
+ reference: requirement.reference,
43
+ }
44
+ : {}),
45
+ ...(validDistance && observation ? { reported_mm: observation.distanceMm } : {}),
46
+ };
47
+ if (missing.length > 0 || !requirement || !observation)
48
+ return base;
49
+ const violated = observation.distanceMm < requirement.minimumMm;
50
+ return {
51
+ ...base,
52
+ status: violated ? 'WARNING' : 'UNKNOWN',
53
+ message: violated
54
+ ? 'Caller-reported geometry is below its caller-declared, edition-linked minimum; verify the source and board physically.'
55
+ : 'Caller-reported geometry meets its declared minimum, but the source applicability and measurement are unverified.',
56
+ };
57
+ }
58
+ function validContextVoltage(value) {
59
+ return value !== undefined && Number.isFinite(value) && value >= 0;
60
+ }
61
+ function validPollutionDegree(value) {
62
+ return value !== undefined && Number.isInteger(value) && value >= 1 && value <= 4;
63
+ }
64
+ function missingContext(input) {
65
+ const missing = [];
66
+ if (input.purpose === undefined || input.purpose === 'unspecified') {
67
+ missing.push('insulation purpose (functional/basic/supplementary/reinforced)');
68
+ }
69
+ if (!validContextVoltage(input.workingVoltageV))
70
+ missing.push('working voltage');
71
+ if (!validContextVoltage(input.transientVoltageV))
72
+ missing.push('transient/impulse voltage');
73
+ if (input.environment === undefined || input.environment === 'unspecified') {
74
+ missing.push('environment and condensation exposure');
75
+ }
76
+ if (!validPollutionDegree(input.pollutionDegree))
77
+ missing.push('pollution degree');
78
+ if (input.overvoltageCategory === undefined)
79
+ missing.push('overvoltage category');
80
+ if (input.materialGroup === undefined)
81
+ missing.push('insulating material group / CTI');
82
+ if (!Number.isFinite(input.altitudeM))
83
+ missing.push('installation altitude');
84
+ if (input.safetyStandard === undefined)
85
+ missing.push('applicable safety standard, edition and clause');
86
+ return missing;
87
+ }
88
+ function reviewEsd(input) {
89
+ const missing = [
90
+ ...(input.protectorRef ? [] : ['declared ESD protection component']),
91
+ ...(input.entryNet ? [] : ['connector entry net']),
92
+ ...(input.returnPathEvidence
93
+ ? []
94
+ : ['verified short ESD return path and actual copper geometry']),
95
+ ];
96
+ return {
97
+ id: 'ESD_ENTRY',
98
+ status: 'UNKNOWN',
99
+ message: 'Connector/TVS designators are not proof of placement, discharge routing or IEC 61000-4-2 immunity performance.',
100
+ ...(input.testStandard ? { reference: input.testStandard } : {}),
101
+ evidence_refs: input.returnPathEvidence ? [input.returnPathEvidence] : [],
102
+ missing,
103
+ };
104
+ }
105
+ function reviewEmc(input) {
106
+ return {
107
+ id: 'EMC_RETURN',
108
+ status: 'UNKNOWN',
109
+ message: 'Names of loops, planes and sensitive parts do not establish measured EMI or continuous high-frequency return paths.',
110
+ evidence_refs: input.returnPlaneEvidence ? [input.returnPlaneEvidence] : [],
111
+ missing: [
112
+ ...(input.fastLoopRef ? [] : ['fast-current loop identity']),
113
+ ...(input.returnPlaneEvidence ? [] : ['verified reference-plane/return-current geometry']),
114
+ ...(input.sensitiveCircuitRef ? [] : ['sensitive circuit identity']),
115
+ ],
116
+ };
117
+ }
118
+ function uniqueReferences(input) {
119
+ const sources = [
120
+ input.safetyStandard,
121
+ input.clearanceRequirement?.reference,
122
+ input.creepageRequirement?.reference,
123
+ input.esdEntry?.testStandard,
124
+ ].filter((source) => source !== undefined);
125
+ return sources.filter((source, i) => sources.findIndex((other) => other.identifier === source.identifier &&
126
+ other.edition === source.edition &&
127
+ other.clause === source.clause &&
128
+ other.source === source.source) === i);
129
+ }
130
+ export function reviewIsolationEmc(input) {
131
+ const context_missing = missingContext(input);
132
+ const findings = [
133
+ reviewSpacing('AIR_CLEARANCE', input.clearanceRequirement, input.airClearance),
134
+ reviewSpacing('SURFACE_CREEPAGE', input.creepageRequirement, input.surfaceCreepage),
135
+ {
136
+ id: 'INSULATION_CONTEXT',
137
+ status: 'UNKNOWN',
138
+ message: 'Voltage, material, environment and standard applicability must be checked by a qualified design reviewer; no insulation classification is certified.',
139
+ evidence_refs: [
140
+ ...(input.boardSlotEvidence ? [input.boardSlotEvidence] : []),
141
+ ...(input.coatingEvidence ? [input.coatingEvidence] : []),
142
+ ],
143
+ missing: context_missing,
144
+ },
145
+ ];
146
+ if (input.esdEntry)
147
+ findings.push(reviewEsd(input.esdEntry));
148
+ if (input.emcReturn)
149
+ findings.push(reviewEmc(input.emcReturn));
150
+ const qualified = ['basic', 'supplementary', 'reinforced'].includes(input.purpose ?? '');
151
+ return {
152
+ status: findings.some((finding) => finding.status === 'WARNING') ? 'WARNING' : 'UNKNOWN',
153
+ evidence: 'caller_supplied_unverified',
154
+ safety_certification: false,
155
+ qualified_review_required: qualified || context_missing.length > 0,
156
+ context_missing,
157
+ findings,
158
+ limitations: [
159
+ 'IEC/IPC numeric tables are not embedded; requirement, edition, applicability and geometry are independently caller-declared, not checked against licensed standards.',
160
+ 'Air clearance is the shortest through-air route; creepage is the shortest distance along the insulation surface. A direct PCB XY gap is not automatically a creepage path.',
161
+ 'Slots, cutouts, conformal coating, encapsulation and barriers change geometry and applicability but cannot be inferred or certified from provided names or descriptions.',
162
+ 'Environmental conditions, pollution degree, overvoltage, material group/CTI, altitude, insulation class and equipment safety context require qualified human verification.',
163
+ 'ESD advice does not establish IEC 61000-4-2 test results; EMC/EMI compliance requires appropriate measurement or laboratory evidence.',
164
+ 'No PCB primitives were read and no DRC, field solver, safety inspection, EMC measurement or physical acceptance was performed.',
165
+ ],
166
+ source_references: uniqueReferences(input),
167
+ engineering_sign_off: false,
168
+ };
169
+ }
170
+ //# sourceMappingURL=isolation-emc-review.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isolation-emc-review.js","sourceRoot":"","sources":["../../src/design-rules/isolation-emc-review.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AA8EH,SAAS,oBAAoB,CAC3B,EAAwC,EACxC,WAA2C,EAC3C,WAA4C;IAE5C,MAAM,YAAY,GAChB,WAAW,KAAK,SAAS;QACzB,MAAM,CAAC,QAAQ,CAAC,WAAW,CAAC,SAAS,CAAC;QACtC,WAAW,CAAC,SAAS,IAAI,CAAC,CAAC;IAC7B,MAAM,aAAa,GACjB,WAAW,KAAK,SAAS;QACzB,MAAM,CAAC,QAAQ,CAAC,WAAW,CAAC,UAAU,CAAC;QACvC,WAAW,CAAC,UAAU,IAAI,CAAC,CAAC;IAC9B,MAAM,OAAO,GAAG;QACd,GAAG,CAAC,WAAW,KAAK,SAAS,CAAC,CAAC,CAAC,CAAC,kCAAkC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;QAC1E,GAAG,CAAC,WAAW,KAAK,SAAS,IAAI,CAAC,YAAY;YAC5C,CAAC,CAAC,CAAC,4CAA4C,CAAC;YAChD,CAAC,CAAC,EAAE,CAAC;QACP,GAAG,CAAC,WAAW,KAAK,SAAS,CAAC,CAAC,CAAC,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;QAC9D,GAAG,CAAC,WAAW,KAAK,SAAS,IAAI,CAAC,aAAa;YAC7C,CAAC,CAAC,CAAC,yCAAyC,CAAC;YAC7C,CAAC,CAAC,EAAE,CAAC;KACR,CAAC;IACF,MAAM,YAAY,GAAG,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IAAI,eAAe,CAAC,MAAM,GAAG,CAAC;QAClE,eAAe;QACf,QAAQ;QACR,WAAW,EAAE;YACX,sKAAsK;YACtK,4KAA4K;YAC5K,0KAA0K;YAC1K,4KAA4K;YAC5K,uIAAuI;YACvI,gIAAgI;SACjI;QACD,iBAAiB,EAAE,gBAAgB,CAAC,KAAK,CAAC;QAC1C,oBAAoB,EAAE,KAAK;KAC5B,CAAC;AACJ,CAAC"}
@@ -0,0 +1,41 @@
1
+ import { type ConductorLayer } from './trace-width.js';
2
+ /**
3
+ * An auditable reference estimate, not a verification of an EasyEDA route.
4
+ * All geometry and material inputs are caller supplied; no native readings
5
+ * or vendor thermal validation are implied.
6
+ */
7
+ export interface TraceCurrentReviewInput {
8
+ currentA?: number;
9
+ temperatureRiseC?: number;
10
+ layer?: ConductorLayer;
11
+ copperWeightOz?: number;
12
+ traceWidthMm?: number;
13
+ neckDownWidthMm?: number;
14
+ manufacturerMinWidthMm?: number;
15
+ environment?: 'still-air' | 'forced-air' | 'vacuum' | 'unspecified';
16
+ }
17
+ export interface TraceCurrentFinding {
18
+ id: 'THERMAL_ESTIMATE' | 'FABRICATION_WIDTH' | 'ROUTE_GEOMETRY' | 'VIA_BOTTLENECK';
19
+ status: 'WARNING' | 'UNKNOWN';
20
+ message: string;
21
+ }
22
+ export interface TraceCurrentReview {
23
+ status: 'WARNING' | 'UNKNOWN';
24
+ method: 'IPC2221_EMPIRICAL_REFERENCE';
25
+ evidence: 'caller_supplied_unverified';
26
+ source: string;
27
+ inputs: TraceCurrentReviewInput;
28
+ inputUnits: {
29
+ currentA: 'A';
30
+ temperatureRiseC: '°C';
31
+ copperWeightOz: 'oz/ft²';
32
+ traceWidthMm: 'mm';
33
+ neckDownWidthMm: 'mm';
34
+ manufacturerMinWidthMm: 'mm';
35
+ };
36
+ estimatedMinimumWidthMm?: number;
37
+ suppliedNarrowestWidthMm?: number;
38
+ findings: TraceCurrentFinding[];
39
+ limitations: string[];
40
+ }
41
+ export declare function reviewTraceCurrent(input: TraceCurrentReviewInput): TraceCurrentReview;