pvsld 0.6.0__tar.gz

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 (205) hide show
  1. pvsld-0.6.0/.gitignore +109 -0
  2. pvsld-0.6.0/CHANGELOG.md +230 -0
  3. pvsld-0.6.0/LICENSE +21 -0
  4. pvsld-0.6.0/PKG-INFO +76 -0
  5. pvsld-0.6.0/README.md +368 -0
  6. pvsld-0.6.0/datasheets/records/.gitkeep +0 -0
  7. pvsld-0.6.0/datasheets/records/conductors/.gitkeep +0 -0
  8. pvsld-0.6.0/datasheets/records/conductors/viakon-pv-wire-2000v.yaml +41 -0
  9. pvsld-0.6.0/datasheets/records/inverters/.gitkeep +0 -0
  10. pvsld-0.6.0/datasheets/records/inverters/growatt-min-tl-x2.yaml +47 -0
  11. pvsld-0.6.0/datasheets/records/inverters/huawei-sun2000-ktl-l1.yaml +51 -0
  12. pvsld-0.6.0/datasheets/records/modules/.gitkeep +0 -0
  13. pvsld-0.6.0/datasheets/records/modules/etsolar-et-m672bh.yaml +39 -0
  14. pvsld-0.6.0/datasheets/records/modules/jinko-jkm-60hl4.yaml +39 -0
  15. pvsld-0.6.0/datasheets/records/modules/jinko-jkm-66hl4m-bdv.yaml +39 -0
  16. pvsld-0.6.0/datasheets/records/protection/.gitkeep +0 -0
  17. pvsld-0.6.0/datasheets/records/protection/eaton-bussmann-pv-10x38.yaml +47 -0
  18. pvsld-0.6.0/datasheets/records/protection/littelfuse-spf.yaml +44 -0
  19. pvsld-0.6.0/datasheets/records/protection/schneider-acti9-c60pv-dc.yaml +40 -0
  20. pvsld-0.6.0/datasheets/records/protection/squared-qo-2p.yaml +50 -0
  21. pvsld-0.6.0/datasheets/records/protection/suntree-siso-40.yaml +43 -0
  22. pvsld-0.6.0/datasheets/records/protection/suntree-sl7n-63.yaml +61 -0
  23. pvsld-0.6.0/docs/pypi.md +40 -0
  24. pvsld-0.6.0/examples/quick_request.yaml +7 -0
  25. pvsld-0.6.0/examples/residential_7p7kwp.yaml +127 -0
  26. pvsld-0.6.0/examples/sizing_jinko_growatt.yaml +35 -0
  27. pvsld-0.6.0/plugins/pv-unifilar/skills/catalogo/SKILL.md +30 -0
  28. pvsld-0.6.0/plugins/pv-unifilar/skills/diagrama/SKILL.md +39 -0
  29. pvsld-0.6.0/plugins/pv-unifilar/skills/pro/SKILL.md +35 -0
  30. pvsld-0.6.0/pyproject.toml +144 -0
  31. pvsld-0.6.0/sheet_templates/a3_plantilla_v1.dxf +9544 -0
  32. pvsld-0.6.0/src/pvsld/__init__.py +21 -0
  33. pvsld-0.6.0/src/pvsld/backends/__init__.py +9 -0
  34. pvsld-0.6.0/src/pvsld/backends/base.py +40 -0
  35. pvsld-0.6.0/src/pvsld/backends/dxf.py +377 -0
  36. pvsld-0.6.0/src/pvsld/backends/preview.py +147 -0
  37. pvsld-0.6.0/src/pvsld/backends/readback.py +369 -0
  38. pvsld-0.6.0/src/pvsld/catalogue/__init__.py +91 -0
  39. pvsld-0.6.0/src/pvsld/catalogue/cli.py +259 -0
  40. pvsld-0.6.0/src/pvsld/catalogue/common.py +90 -0
  41. pvsld-0.6.0/src/pvsld/catalogue/conductors.py +119 -0
  42. pvsld-0.6.0/src/pvsld/catalogue/errors.py +37 -0
  43. pvsld-0.6.0/src/pvsld/catalogue/inverters.py +368 -0
  44. pvsld-0.6.0/src/pvsld/catalogue/local.py +199 -0
  45. pvsld-0.6.0/src/pvsld/catalogue/modules.py +242 -0
  46. pvsld-0.6.0/src/pvsld/catalogue/protection.py +563 -0
  47. pvsld-0.6.0/src/pvsld/catalogue/registry.py +302 -0
  48. pvsld-0.6.0/src/pvsld/cli.py +678 -0
  49. pvsld-0.6.0/src/pvsld/core/__init__.py +15 -0
  50. pvsld-0.6.0/src/pvsld/core/calc.py +495 -0
  51. pvsld-0.6.0/src/pvsld/core/diagram.py +532 -0
  52. pvsld-0.6.0/src/pvsld/core/layers.py +69 -0
  53. pvsld-0.6.0/src/pvsld/core/layout.py +1662 -0
  54. pvsld-0.6.0/src/pvsld/core/layout_sheet.py +684 -0
  55. pvsld-0.6.0/src/pvsld/core/model.py +556 -0
  56. pvsld-0.6.0/src/pvsld/core/policy.py +62 -0
  57. pvsld-0.6.0/src/pvsld/core/rules.py +585 -0
  58. pvsld-0.6.0/src/pvsld/core/severity.py +13 -0
  59. pvsld-0.6.0/src/pvsld/core/sheet.py +39 -0
  60. pvsld-0.6.0/src/pvsld/core/tables.py +255 -0
  61. pvsld-0.6.0/src/pvsld/core/validation.py +109 -0
  62. pvsld-0.6.0/src/pvsld/design/__init__.py +17 -0
  63. pvsld-0.6.0/src/pvsld/design/pipeline.py +296 -0
  64. pvsld-0.6.0/src/pvsld/design/pro.py +743 -0
  65. pvsld-0.6.0/src/pvsld/design/quick_template.yaml +72 -0
  66. pvsld-0.6.0/src/pvsld/finishers/__init__.py +32 -0
  67. pvsld-0.6.0/src/pvsld/finishers/console_log.py +189 -0
  68. pvsld-0.6.0/src/pvsld/finishers/core_console.py +613 -0
  69. pvsld-0.6.0/src/pvsld/finishers/fake.py +119 -0
  70. pvsld-0.6.0/src/pvsld/finishers/outputs.py +266 -0
  71. pvsld-0.6.0/src/pvsld/mcp/__init__.py +18 -0
  72. pvsld-0.6.0/src/pvsld/mcp/__main__.py +8 -0
  73. pvsld-0.6.0/src/pvsld/mcp/catalogue_tool.py +114 -0
  74. pvsld-0.6.0/src/pvsld/mcp/design_tool.py +369 -0
  75. pvsld-0.6.0/src/pvsld/mcp/handshake.py +84 -0
  76. pvsld-0.6.0/src/pvsld/mcp/models.py +219 -0
  77. pvsld-0.6.0/src/pvsld/mcp/preview.py +87 -0
  78. pvsld-0.6.0/src/pvsld/mcp/prompts.py +66 -0
  79. pvsld-0.6.0/src/pvsld/mcp/sandbox.py +162 -0
  80. pvsld-0.6.0/src/pvsld/mcp/server.py +1067 -0
  81. pvsld-0.6.0/src/pvsld/mcp/sizing_tools.py +273 -0
  82. pvsld-0.6.0/src/pvsld/py.typed +0 -0
  83. pvsld-0.6.0/src/pvsld/report/__init__.py +27 -0
  84. pvsld-0.6.0/src/pvsld/report/bom.py +267 -0
  85. pvsld-0.6.0/src/pvsld/report/memoria.py +1193 -0
  86. pvsld-0.6.0/src/pvsld/report/project_sheet.py +546 -0
  87. pvsld-0.6.0/src/pvsld/resources.py +34 -0
  88. pvsld-0.6.0/src/pvsld/service.py +196 -0
  89. pvsld-0.6.0/src/pvsld/sheets/__init__.py +5 -0
  90. pvsld-0.6.0/src/pvsld/sheets/a3_plantilla_v1.py +103 -0
  91. pvsld-0.6.0/src/pvsld/sheets/cli.py +74 -0
  92. pvsld-0.6.0/src/pvsld/sheets/importer.py +94 -0
  93. pvsld-0.6.0/src/pvsld/sheets/loader.py +252 -0
  94. pvsld-0.6.0/src/pvsld/sizing/__init__.py +59 -0
  95. pvsld-0.6.0/src/pvsld/sizing/adapters.py +147 -0
  96. pvsld-0.6.0/src/pvsld/sizing/bos.py +570 -0
  97. pvsld-0.6.0/src/pvsld/sizing/engine.py +806 -0
  98. pvsld-0.6.0/src/pvsld/sizing/io.py +68 -0
  99. pvsld-0.6.0/src/pvsld/sizing/models.py +461 -0
  100. pvsld-0.6.0/src/pvsld/sizing/report.py +118 -0
  101. pvsld-0.6.0/src/pvsld/sizing/strings.py +328 -0
  102. pvsld-0.6.0/src/pvsld/symbols/__init__.py +37 -0
  103. pvsld-0.6.0/src/pvsld/symbols/cfe/__init__.py +35 -0
  104. pvsld-0.6.0/src/pvsld/symbols/cfe/build.py +422 -0
  105. pvsld-0.6.0/src/pvsld/symbols/cfe/cli.py +184 -0
  106. pvsld-0.6.0/src/pvsld/symbols/cfe/definitions.py +2373 -0
  107. pvsld-0.6.0/src/pvsld/symbols/cfe/dwg.py +122 -0
  108. pvsld-0.6.0/src/pvsld/symbols/cfe/loader.py +132 -0
  109. pvsld-0.6.0/src/pvsld/symbols/cfe/model.py +323 -0
  110. pvsld-0.6.0/src/pvsld/symbols/cfe/validate.py +185 -0
  111. pvsld-0.6.0/src/pvsld/transports/__init__.py +15 -0
  112. pvsld-0.6.0/src/pvsld/transports/com.py +754 -0
  113. pvsld-0.6.0/src/pvsld/transports/fake.py +646 -0
  114. pvsld-0.6.0/src/pvsld/transports/pipe.py +336 -0
  115. pvsld-0.6.0/src/pvsld/transports/protocol.py +175 -0
  116. pvsld-0.6.0/src/pvsld/transports/streams.py +213 -0
  117. pvsld-0.6.0/symbols/pvsld-symbols.dxf +62244 -0
  118. pvsld-0.6.0/tests/autocad/conftest.py +141 -0
  119. pvsld-0.6.0/tests/autocad/s2_support.py +139 -0
  120. pvsld-0.6.0/tests/autocad/test_s2_1_com_baseline.py +84 -0
  121. pvsld-0.6.0/tests/autocad/test_s2_2_plugin_performance.py +81 -0
  122. pvsld-0.6.0/tests/autocad/test_s2_3_plugin_reliability.py +54 -0
  123. pvsld-0.6.0/tests/autocad/test_s2_4_plugin_safety.py +182 -0
  124. pvsld-0.6.0/tests/autocad/test_s2_5_busy.py +177 -0
  125. pvsld-0.6.0/tests/catalogue_helpers.py +66 -0
  126. pvsld-0.6.0/tests/conftest.py +55 -0
  127. pvsld-0.6.0/tests/finishers/test_core_console_live.py +98 -0
  128. pvsld-0.6.0/tests/fixtures/catalogue/inverters/growatt-min-tl-x2.yaml +47 -0
  129. pvsld-0.6.0/tests/fixtures/catalogue/inverters/huawei-sun2000-ktl-l1.yaml +51 -0
  130. pvsld-0.6.0/tests/fixtures/catalogue/modules/etsolar-et-m672bh.yaml +39 -0
  131. pvsld-0.6.0/tests/fixtures/catalogue/modules/jinko-jkm-66hl4m-bdv.yaml +39 -0
  132. pvsld-0.6.0/tests/fixtures/catalogue/protection/schneider-acti9-c60pv-dc.yaml +40 -0
  133. pvsld-0.6.0/tests/fixtures/catalogue/protection/suntree-sl7n-63.yaml +61 -0
  134. pvsld-0.6.0/tests/fixtures/sizing/records/conductors/viakon-pv-wire-2000v.yaml +42 -0
  135. pvsld-0.6.0/tests/fixtures/sizing/records/inverters/growatt-min-tl-x2.yaml +49 -0
  136. pvsld-0.6.0/tests/fixtures/sizing/records/inverters/huawei-sun2000-ktl-l1.yaml +53 -0
  137. pvsld-0.6.0/tests/fixtures/sizing/records/inverters/yi-6000.yaml +32 -0
  138. pvsld-0.6.0/tests/fixtures/sizing/records/modules/etsolar-et-m672bh.yaml +41 -0
  139. pvsld-0.6.0/tests/fixtures/sizing/records/modules/jinko-jkm-66hl4m-bdv.yaml +41 -0
  140. pvsld-0.6.0/tests/fixtures/sizing/records/modules/xm-550.yaml +29 -0
  141. pvsld-0.6.0/tests/fixtures/sizing/records/protection/littelfuse-spf.yaml +45 -0
  142. pvsld-0.6.0/tests/fixtures/sizing/records/protection/schneider-acti9-c60pv-dc.yaml +42 -0
  143. pvsld-0.6.0/tests/fixtures/sizing/records/protection/squared-qo-2p.yaml +51 -0
  144. pvsld-0.6.0/tests/fixtures/sizing/records/protection/suntree-siso-40.yaml +44 -0
  145. pvsld-0.6.0/tests/fixtures/sizing/records/protection/suntree-sl7n-63.yaml +63 -0
  146. pvsld-0.6.0/tests/golden/residential_7p7kwp.dxf +26650 -0
  147. pvsld-0.6.0/tests/s1_helpers.py +32 -0
  148. pvsld-0.6.0/tests/sizing_helpers.py +58 -0
  149. pvsld-0.6.0/tests/test_autocad_marker.py +71 -0
  150. pvsld-0.6.0/tests/test_backend_dxf.py +582 -0
  151. pvsld-0.6.0/tests/test_backend_dxf_golden.py +105 -0
  152. pvsld-0.6.0/tests/test_backend_preview.py +112 -0
  153. pvsld-0.6.0/tests/test_catalogue_cli.py +181 -0
  154. pvsld-0.6.0/tests/test_catalogue_extensions.py +243 -0
  155. pvsld-0.6.0/tests/test_catalogue_local.py +256 -0
  156. pvsld-0.6.0/tests/test_catalogue_real_records.py +54 -0
  157. pvsld-0.6.0/tests/test_catalogue_records.py +144 -0
  158. pvsld-0.6.0/tests/test_catalogue_registry.py +153 -0
  159. pvsld-0.6.0/tests/test_catalogue_review_gate.py +25 -0
  160. pvsld-0.6.0/tests/test_catalogue_validation.py +270 -0
  161. pvsld-0.6.0/tests/test_cfe_definitions.py +476 -0
  162. pvsld-0.6.0/tests/test_cfe_library.py +500 -0
  163. pvsld-0.6.0/tests/test_cfe_model.py +101 -0
  164. pvsld-0.6.0/tests/test_claude_plugin.py +233 -0
  165. pvsld-0.6.0/tests/test_cli.py +245 -0
  166. pvsld-0.6.0/tests/test_conduit_fill.py +164 -0
  167. pvsld-0.6.0/tests/test_core_calc.py +237 -0
  168. pvsld-0.6.0/tests/test_core_diagram.py +481 -0
  169. pvsld-0.6.0/tests/test_core_model.py +129 -0
  170. pvsld-0.6.0/tests/test_core_rules.py +312 -0
  171. pvsld-0.6.0/tests/test_core_str007.py +139 -0
  172. pvsld-0.6.0/tests/test_design.py +358 -0
  173. pvsld-0.6.0/tests/test_design_pro.py +315 -0
  174. pvsld-0.6.0/tests/test_example.py +98 -0
  175. pvsld-0.6.0/tests/test_finisher_cli.py +123 -0
  176. pvsld-0.6.0/tests/test_finisher_console_log.py +269 -0
  177. pvsld-0.6.0/tests/test_finisher_core_console.py +438 -0
  178. pvsld-0.6.0/tests/test_finisher_outputs.py +115 -0
  179. pvsld-0.6.0/tests/test_layout_sheet.py +607 -0
  180. pvsld-0.6.0/tests/test_library_dwg.py +148 -0
  181. pvsld-0.6.0/tests/test_mcp_handshake.py +154 -0
  182. pvsld-0.6.0/tests/test_mcp_preview.py +114 -0
  183. pvsld-0.6.0/tests/test_mcp_prompts.py +82 -0
  184. pvsld-0.6.0/tests/test_mcp_sandbox.py +211 -0
  185. pvsld-0.6.0/tests/test_mcp_server.py +729 -0
  186. pvsld-0.6.0/tests/test_mcp_sizing.py +171 -0
  187. pvsld-0.6.0/tests/test_mcp_stdio.py +240 -0
  188. pvsld-0.6.0/tests/test_package.py +47 -0
  189. pvsld-0.6.0/tests/test_project_metadata.py +90 -0
  190. pvsld-0.6.0/tests/test_report.py +191 -0
  191. pvsld-0.6.0/tests/test_resources.py +42 -0
  192. pvsld-0.6.0/tests/test_sizing_bos.py +314 -0
  193. pvsld-0.6.0/tests/test_sizing_cli.py +189 -0
  194. pvsld-0.6.0/tests/test_sizing_diagram.py +148 -0
  195. pvsld-0.6.0/tests/test_sizing_engine.py +522 -0
  196. pvsld-0.6.0/tests/test_sizing_overrides.py +89 -0
  197. pvsld-0.6.0/tests/test_sizing_ranking.py +34 -0
  198. pvsld-0.6.0/tests/test_sizing_strings.py +232 -0
  199. pvsld-0.6.0/tests/test_sizing_switchgear.py +104 -0
  200. pvsld-0.6.0/tests/test_symbols.py +98 -0
  201. pvsld-0.6.0/tests/test_transport_com_baseline.py +468 -0
  202. pvsld-0.6.0/tests/test_transport_pipe_client.py +412 -0
  203. pvsld-0.6.0/tests/test_transport_pipe_discovery.py +128 -0
  204. pvsld-0.6.0/tests/test_transport_pipe_protocol.py +123 -0
  205. pvsld-0.6.0/tests/test_transport_pipe_windows.py +117 -0
pvsld-0.6.0/.gitignore ADDED
@@ -0,0 +1,109 @@
1
+ # Python
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+ *.so
6
+ .Python
7
+ env/
8
+ venv/
9
+ .venv/
10
+ ENV/
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ pip-wheel-metadata/
24
+ share/python-wheels/
25
+ *.egg-info/
26
+ .installed.cfg
27
+ *.egg
28
+ MANIFEST
29
+ .pytest_cache/
30
+ .ruff_cache/
31
+ .coverage
32
+ htmlcov/
33
+ .tox/
34
+ .hypothesis/
35
+ *.log
36
+
37
+ # Node.js
38
+ node_modules/
39
+ npm-debug.log
40
+ yarn-error.log
41
+ package-lock.json
42
+ yarn.lock
43
+ dist/
44
+ .next/
45
+ out/
46
+
47
+ # IDE
48
+ .vscode/
49
+ .idea/
50
+ *.swp
51
+ *.swo
52
+ *~
53
+ .DS_Store
54
+ .project
55
+ .pydevproject
56
+ .settings/
57
+ *.sublime-project
58
+ *.sublime-workspace
59
+
60
+ # OS
61
+ Thumbs.db
62
+ .DS_Store
63
+
64
+ # AutoCAD / DWG
65
+ *.bak
66
+ *.dwl
67
+ *.dwl2
68
+ *.sv$
69
+ *.ac$
70
+ plot.log
71
+ *.log
72
+ acad.err
73
+ *.plt
74
+
75
+ # .NET plug-in build output (Autodesk assemblies are never committed: AutoCAD supplies them)
76
+ bin/
77
+ obj/
78
+ *.user
79
+ .vs/
80
+ TestResults/
81
+
82
+ # Temporary files
83
+ *.tmp
84
+ *.temp
85
+ *.TMP
86
+
87
+ # Obsidian vault (workspace state only, keep vault content)
88
+ .obsidian/workspace*.json
89
+
90
+ # Local environment
91
+ .env
92
+ .env.local
93
+ .env.*.local
94
+ secrets.json
95
+ credentials.json
96
+
97
+ # Generated files from research (transient)
98
+ /downloads/
99
+ /cache/
100
+
101
+ # Component datasheets and extraction cache (copyrighted PDFs, token cache)
102
+ # Raw PDFs: never commit (copyright)
103
+ datasheets/inbox/
104
+ # Markitdown markdown cache: never commit (derived, token-heavy)
105
+ datasheets/cache/
106
+ # Committed component records: stored in datasheets/records/ (extracted facts only, no full text)
107
+
108
+ # The owner's source templates stay local; the neutral DXF of `pvsld sheet import` is committed
109
+ sheet_templates/*.dwg
@@ -0,0 +1,230 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
+
8
+ ## [Unreleased]
9
+
10
+ ## [0.6.0] - 2026-10-13
11
+
12
+ PvUnifilar in other agent CLIs (Stage 3.7). The server is published on PyPI as `pvsld` and the plugin runs it with `uvx --from pvsld==0.6.0 pvsld-mcp`: no git clone, no build on the user's machine. One plugin folder installs in Claude Code, Copilot CLI and Antigravity CLI, and the repository is a Gemini CLI extension. Real prompts were run in Claude Code, Copilot CLI and Antigravity CLI; Gemini CLI (closed to personal accounts) and Codex CLI (paid) were not tested.
13
+
14
+ ### Added
15
+ - The plugin's three workflows are also MCP prompts, `diagrama`, `pro` and `catalogo` (Stage 3.7), for the clients that connect to the server without loading the plugin's skills: Gemini CLI and VS Code list a server's prompts as commands. They are the plugin's own `SKILL.md` files, carried in the wheel (`pvsld.mcp.prompts`), so a prompt cannot differ from its skill. `PVSLD_MCP_PROMPTS=off` leaves them out; the plugin sets it where the client already shows the skills.
16
+ - The plugin folder is also an Agent Plugins 1.0 plugin (root `plugin.json` and `mcp.json` beside Claude Code's files), which Copilot CLI reads first, and the repository is a Gemini CLI extension (`gemini-extension.json` at the root, with a context file). Checked with Copilot CLI 1.0.96 and Gemini CLI 0.63.0: both install it and list the server; Copilot's own model designed an installation from a plain request. The documentation for users waits for Stage 3.7.1, because Copilot CLI gives a server 10 s to answer and `uvx` from a git tag takes longer.
17
+ - CI validates the Gemini extension with `gemini extensions validate`.
18
+ - The plugin folder also installs in Antigravity CLI, Google's successor of Gemini CLI for personal accounts (`agy plugin install <folder>`): it carries `mcp_config.json`, the file that client reads a plugin's servers from. Checked with Antigravity CLI 1.3.4: 3 skills and 1 MCP server.
19
+ - `release.yml` publishes the package on PyPI when a release tag is pushed (Stage 3.7.1), with trusted publishing: no token is stored. It checks that the tag is the package version, checks the description with `twine`, and designs an installation with the built wheel first. `docs/pypi.md` is the Spanish description PyPI shows (the repository README has relative image paths).
20
+
21
+ ### Changed
22
+ - The skills follow the Agent Skills format so that other clients load them: they have `name` (Gemini CLI lists none without it), take the request from the conversation and not from Claude Code's `$ARGUMENTS`, and name Claude Code's commands only as an example. Each also forbids writing a script that draws when the server is not connected.
23
+
24
+ - The repository is now `edu3250/PvUnifilar`, the plugin's name (owner, 2026-10-12; it was `edu3250/Diagrama-unifilarAutoCAD`). The plugin's server, the package metadata, the README, the plugin guide and the user guide use the new address. GitHub redirects the old one, so the published `v0.5.0` plugin and a marketplace added under the old name keep working; checked for `uvx --from git+…`, `claude plugin marketplace add` and `marketplace update`. The Python package (`pvsld`), the plugin (`pv-unifilar`) and the marketplace (`pvsld`) keep their names.
25
+
26
+ ### Fixed
27
+ - In Antigravity CLI the projects were written inside the installed plugin (`~/.gemini/config/plugins/pv-unifilar/out`), because that client starts a plugin's server in the plugin's folder and the server's default is `./out`. The portable manifests (`mcp.json`, `mcp_config.json`) now set the output folder to `~/PvUnifilar`. Found and checked with a real prompt in Antigravity CLI 1.3.4. Claude Code is not affected: it starts the server in the project.
28
+ - Copilot CLI marked the server as failed whenever it took more than about 10 s to start, which `uvx` from a git tag often does and a first start always does. The client sends `server/discover`, gives up and sends `initialize`; the MCP SDK answered the first and refused the second. The server now drops a discovery that is followed at once by the older handshake (`pvsld.mcp.handshake`), so the client connects. Checked with Copilot CLI 1.0.96 and a server started 13 s late.
29
+ - `PVSLD_OUTPUT_DIR` holding a placeholder nobody filled in (`${user_config.output_dir}`, which only Claude Code replaces) made the server write into a folder with that name. It now counts as not set.
30
+
31
+ ## [0.5.0] - 2026-10-12
32
+
33
+ The Claude Code plugin **PvUnifilar** (Stage 3.6): from a plain request, or from a project sheet the user fills in, one tool call sizes, validates and draws the installation and writes the DWG or DXF, the PDF, the calculation report, the project sheet and the bill of materials. With a local catalogue for equipment added from its datasheet, the marketplace `pvsld`, and a Spanish README and user guide. Pre-release `v0.5.0rc1` on 2026-10-09.
34
+
35
+ ### Added
36
+ - Spanish user guide, `docs/guia-de-usuario.md` (Stage 3.6.5): installation and first start, the quick mode and its defaults, the files of a project folder, the professional mode sheet by sheet, the catalogue and how to add equipment, with and without AutoCAD, what the calculation checks, frequent problems, updating and the scope. The README and the plugin guide link to it.
37
+ - Each skill of the plugin says what to do when the `pvsld` server is not connected (first start slower than Claude Code's 30 s wait, or `uv` missing): check `uv --version`, reconnect from `/mcp`, ask again; and not to design by other means.
38
+ - `tests/test_claude_plugin.py` also holds the README and the user guide to the release tag of the plugin's version and to installing from the default branch.
39
+ - README rewritten in Spanish (owner decision 2026-10-10: the system works with Mexican standards, so its front page speaks to Mexican installers; code and technical docs stay in English) around what a user gets, with images produced by the system itself (`docs/images/readme/`, fictitious names). It shows the A3 sheet and its parts, the calculation report in Excel, and the project sheet with a reviewed cell in red. It also covers how to install the plugin, how to run the MCP server from Claude Code, Claude Desktop or VS Code, the nine tools, the environment variables, the CLI and a diagram of the flow.
40
+ - The Spanish plugin guide gains the sheet image and the notes from the owner's install test: reopen Claude Code after installing uv; the 30 s server start-up wait.
41
+ - `examples/quick_request.yaml`: the three-line request of the quick mode.
42
+ - Claude Code plugin **PvUnifilar** (`pv-unifilar`, Stage 3.6.4b) and its marketplace `pvsld`.
43
+ - `plugins/pv-unifilar/`:
44
+ - `.claude-plugin/plugin.json`;
45
+ - `.mcp.json`, which runs the server with `uvx --from git+https://github.com/edu3250/Diagrama-unifilarAutoCAD@v<version> pvsld-mcp` and takes an optional user-configured output folder;
46
+ - a Spanish README.
47
+ - Three skills: `/pv-unifilar:diagrama` (quick mode; a plain request also triggers it), `/pv-unifilar:pro` (the project sheet) and `/pv-unifilar:catalogo` (a datasheet into the local catalogue). Each pre-approves the pvsld tools it calls (`allowed-tools`).
48
+ - `.claude-plugin/marketplace.json` at the repository root. Install with `/plugin install pv-unifilar --marketplace edu3250/Diagrama-unifilarAutoCAD`.
49
+ - The package and the plugin share one version (first `0.5.0rc1`). The server answers a missing project sheet with the full folder path to copy it to.
50
+ - CI job `claude-plugin` runs `claude plugin validate --strict` on the plugin and the marketplace. `tests/test_claude_plugin.py` checks that versions, release tag, tool names and resources agree.
51
+ - The data the code reads at run time travels inside the wheel (Stage 3.6.4a), so the plugin's server, built by `uvx` from a git tag, works without the repository.
52
+ - `pvsld.resources.data_path` serves the catalogue records, the symbol library, the A3 sheet template and the residential example from the installed package (`force-include` under `pvsld/_data`), and falls back to the repository checkout for development installs.
53
+ - The CLI's default catalogue is that bundled copy, not `./datasheets/records` of the current folder.
54
+ - CI job `package` (Linux and Windows) builds the wheel, starts `pvsld-mcp` with `uvx --from .` and designs an installation with the installed wheel outside the checkout (`scripts/smoke_installed.py`).
55
+ - Local catalogue (Stage 3.6.3): equipment the bundled catalogue lacks, added from its datasheet.
56
+ - `pvsld.catalogue.local`:
57
+ - `local_catalogue_dir` locates the folder: `$PVSLD_LOCAL_CATALOGUE_DIR`, else `%APPDATA%\pvsld\catalogo`, or `~/.local/share/pvsld/catalogo` elsewhere. It has the layout of `datasheets/records` plus `hojas_tecnicas/` for the PDFs.
58
+ - `load_catalogue` merges the local records with the bundled ones. A broken local record, or one that repeats a bundled id, is left out and reported (`ComponentRegistry.local_problems`), never fatal. `ComponentRegistry.is_local` tells the local components apart.
59
+ - `add_local_record` validates a record like any bundled one and stamps its provenance: the PDF's name and SHA-256, the user as reviewer and today's dates. It refuses an id already in the catalogue; a local record can be replaced with overwrite.
60
+ - MCP:
61
+ - tool `add_component_to_catalogue` (record, datasheet file name in the local `hojas_tecnicas`, `user_confirmed`);
62
+ - resource `pvsld://catalogue/record-examples`: one reviewed record per type, the local folders, how to add;
63
+ - `list_components` marks local components and filters every type (AC breakers, PV switches, cables too);
64
+ - the instructions tell Claude to offer the datasheet route whenever equipment is missing.
65
+ - Every CLI command that sizes or designs (`size`, `design`, `pro`, `report`) and `catalogue list/show` see the local records. `pvsld catalogue add RECORD.yaml --datasheet PDF` adds one.
66
+ - `registry.validate_family` validates a record given as a mapping.
67
+ - Professional mode (Stage 3.6.2b): design from the project sheet the user fills in.
68
+ - `pvsld.design.pro`:
69
+ - `read_project_sheet` reads the parameter rows by label, so moved or inserted rows still work;
70
+ - `sheet_request` checks every cell and maps it to a sizing request that keeps the fixed values (inverter, strings, modules per string, fuse without breaker fallback, DC breaker, switch, ITM-1, ITM-P, cable, conductor sizes, EMT, lengths, voltage-drop limits, SPDs, bus, grounding), the service and the personal data;
71
+ - `design_from_sheet` runs the one-step design.
72
+ - Personal data is free text: the CP, RPU, cédula, e-mail and coordinates are taken as written, in the sheet and in the spec (owner decision 2026-10-09: its format is the user's business; the spec drops their patterns and the Mexico bounds of lat/lon, and a coordinate may be text).
73
+ - A cell that cannot be used (a voltage CFE does not supply, 3 × 3 strings for 8 modules, a 3F-4H service) or a fixed value the calculation rejects (a fuse below 1.56 × Isc, a conductor too small) becomes an issue on its cell. When the equipment is complete, both kinds are reported in one round.
74
+ - `write_reviewed_sheet` returns the user's own workbook with those cells in red, the reason as a comment and a summary on Instrucciones. A model missing from the catalogue is reported as a missing component (for Stage 3.6.3).
75
+ - The project sheet among the deliverables is the user's workbook with its "Último cálculo" column refreshed (`design_and_draw(project_sheet=...)`).
76
+ - MCP tools:
77
+ - `new_project_sheet` writes a blank sheet into `<output>/<name>/`;
78
+ - `design_from_project_sheet` designs from `<output>/<name>/hoja_de_proyecto.xlsx`, or writes `hoja_de_proyecto_revisar.xlsx` and lists the cells.
79
+ - The server instructions describe both modes.
80
+ - CLI: `pvsld pro new DIR`, `pvsld pro design SHEET -o DIR [--no-autocad]`.
81
+ - Values the user fixes are kept and checked, never replaced (Stage 3.6.2a, for the professional mode). New sizing request fields:
82
+ - `n_strings` and `n_series` pin the string layout; a string count above the inverter's inputs is rejected (REQ-002);
83
+ - `dc_conductor_size` and `ac_conductor_size` are checked for ampacity and protection (CON-002 names the smallest safe size) and for voltage drop (warning);
84
+ - `main_breaker` takes the catalogue device of ITM-P, separate from `ac_breakers`, which restrict ITM-1 only;
85
+ - `dc_fuse_fallback: false` rejects a configuration whose listed fuses do not fit instead of switching to a DC breaker.
86
+ - Personal data reaches the drawing and the calculation report when the spec gives it (Stage 3.6.2a, owner plan 2026-10-09: "si los llena, aparecen en el plano y la memoria; si no, quedan en blanco"):
87
+ - the owner, address, coordinates, RPU, service and meter numbers, the responsible engineer and the reviewer are optional in the spec, and missing ones stay blank lines;
88
+ - on the A3 sheet a given value is cut with "…" to the length of the blank line it replaces;
89
+ - the responsible's company replaces "COMPAÑÍA INSTALADORA";
90
+ - the quick template no longer carries "SIN DATOS" markers.
91
+ - One-step design for the plugin's quick mode (Stage 3.6.1b): `pvsld.design.design_and_draw`, the MCP tool `design_and_draw` and `pvsld design REQUEST -o DIR [--no-autocad]`. From a module and a size it sizes, validates and draws the installation, finishes it with the local AutoCAD (DWG and PDF) or renders the PDF itself, and writes the calculation report (xlsx, pdf), the project sheet, the bill of materials and the spec into one folder per project (`<output>/<name>/`, default `sfv_<kWp>kWp`). Without a template the quick defaults apply (`quick_template.yaml`: CFE BT 2F-3H 220/127 V, 10 kA, 100 A main breaker, a DC SPD in the box, default temperatures, personal fields blank on the sheet). A failed AutoCAD run falls back to the pvsld PDF and says so
92
+ - `render_pdf` / `write_pdf`: the A3 sheet as a one-page vector PDF, black on white like the AutoCAD plot with `monochrome.ctb`, byte-identical for the same drawing (for users without AutoCAD)
93
+ - `detect_autocad` / `AutocadInfo`: whether Core Console is installed and which AutoCAD release holds it
94
+ - `OutputSandbox.project_dir`: a validated project folder inside the output root
95
+ - `pvsld.report` (Stage 3.6.1a, the owner approved the prototypes on 2026-10-09):
96
+ - the calculation report (memoria de cálculo) as an Excel workbook (Datos with sourced blue inputs, Memoria with live formulas and CUMPLE/NO CUMPLE checks with NOM references, Materiales, Validación) and as a letter-size PDF;
97
+ - the professional-mode project sheet (hoja de proyecto) with AUTO defaults, catalogue dropdowns on a hidden sheet, the last calculation's choices and notes;
98
+ - the bill of materials as rows and as the plain-text summary for the user.
99
+ `pvsld report SPEC -o DIR [--explanation TEXT]` writes all four. String protections now record their catalogue reference (`model`). New runtime dependencies: openpyxl and reportlab
100
+ - Sizing ranks the inverters by a DC/AC ratio inside 1.10-1.25, or the closest to it, then less clipping, fewer warnings and the smaller inverter (owner decision 2026-10-09; before, a fixed module count fell to a cold-voltage tie-break that picked an oversized inverter). Each candidate carries `explanation_es`, a short Spanish reason for the choice that the report and the MCP summary show to the user
101
+ - Catalogue switchgear (Stage 3.4b, owner choices 2026-10-09): `ac_breaker` (`AcBreaker`, Square D QO plug-on 2-pole 120/240 Vac, 10-200 A, 10 kA) and `dc_switch` (`DcSwitch`, Suntree SISO-40 PV switch-disconnector, 4 poles, DC-PV2, rated current by wiring and voltage), both pending the owner's review. `pvsld size` takes ITM-1 (the next QO rating up with enough interrupting rating, NOM 110-9), ITM-P (the service main keeps its rating; the catalogue gives the device and its kAIC) and the box disconnect DCD-CD1 (two poles per string, four in series for one string, at the step above Voc(T_min), at least the string's maximum current) from the catalogue; the spec records them in `model`, `MainBreaker.kaic_ka` shows in the protection schedule, and with no fitting device the previous assumptions stay, with a warning. Request fields `ac_breakers` and `dc_switches`. OCP-005 (the inverter's maximum output OCPD) and EGC sizing per Table 250-122 are dropped (owner decision)
102
+ - EMT conduit fill (Stage 3.4b, owner choices 2026-10-09: EMT; PV cable on the DC side, THHW-LS on the AC side). `pvsld size` chooses the smallest EMT of NOM Chapter 10 Table 4 within the Table 1 fill for the string raceway (both conductors of every string) and the inverter output (phases and neutral), each with one bare grounding conductor (Table 8, 250-122(c)); PV cable areas come from the catalogue datasheet diameter (Table 1 note 5), THHW-LS from Table 5 (THHW row; the table's area column has misprints, so areas are computed from its diameters). A given `routing.dc_raceway_trade_size_mm` / `ac_raceway_trade_size_mm` is checked instead. The spec carries `conductors.outer_diameter_mm`; the sheet shows "EMT 27 mm (1\")"
103
+ - Rule CON-006: an EMT raceway filled beyond NOM Chapter 10 Table 1 is an error that names the EMT that fits; a conductor without a known diameter is a warning
104
+ - Cable records in the catalogue (`component_type: conductor`, `Cable`, `registry.cables()`): Viakon PV Wire XLPE 2000 V, 14 AWG to 4/0 AWG (pending the owner's review); request field `dc_cable`
105
+ - gPV fuses in the catalogue (`component_type: dc_fuse`, `DcFuse`, `registry.dc_fuses()`): Littelfuse SPF 10x38 mm 1000 V dc 1-30 A (20 kA to 20 A, 50 kA at 25-30 A) and Eaton Bussmann PV 10x38 mm 1000 Vdc 1-20 A (50 kA); both records await the owner's review. Extraction method `pdf_text_layer`
106
+ - The DC protection box protects each string with a gPV fuse-disconnector by default (owner decision 2026-10-08): `pvsld size` / `size_pv_system` take `dc_ocpd_device: fuse | breaker` (default fuse) and `dc_fuses`; the fuse window is >= 1.56 x Isc and <= the module's maximum series fuse, rated voltage >= Voc(T_min), interrupting rating above the fault current; with no fitting fuse the box keeps a DC breaker and the reason says so. String fuse-disconnectors are `FUS-S<n>` ("Fusible gPV (cadena)" in the schedule); `DcOcpdChoice.breaker_id` is now `device_id` with `device`
107
+ - The sheet draws the box with the library 0.8.0 blocks, both variants kept (fuse-disconnector or breaker): field connector `PVSLD_PV_CONNECTOR` at the end of each string (the string circuit and its marker are the run from it to the box), box terminals `PVSLD_TERMINAL` on the DC layer, `PVSLD_SPD_DC_BOX` below the strings fed by both (junction dots `PVSLD_JUNCTION` where the taps leave the strings; the upper tap crosses the lower string), one ganged `PVSLD_DC_DISCONNECT_<n>S`; the box grows to hold them
108
+ - Symbol library 0.8.0, for the DC protection box of the owner's reference (2026-10-08): `PVSLD_DC_DISCONNECT_2S`, one ganged DC switch-disconnector for every string of the box (a pole pair per string 20 mm apart, the handle on the top pole, a dotted mechanical link; parametric `PVSLD_DC_DISCONNECT_<n>S` for 1 to 12 strings, drawn at the box size); `PVSLD_FUSE_DISC_DC`, the DC fuse-disconnector (gPV fuse holder); `PVSLD_SPD_DC_BOX`, the DC SPD module with two line inputs and the earth lead; `PVSLD_PV_CONNECTOR`, the plug-and-socket (MC4 type) field connector. `PVSLD_TERMINAL` is coloured BYBLOCK, so it takes the colour of the layer it is inserted on (`Circle.color_by_block`)
109
+ - DC protection box on the sheet template (owner decision 2026-10-08): each string runs through its DC breaker (`PVSLD_CB_DC`) and the DC disconnect to the inverter; the DC SPD hangs after the lower breaker (before the disconnect when there is no breaker) and goes to earth; a dashed enclosure "CAJA DE PROTECCIONES CD" of the load centre's size (30 x 35 mm) holds the breakers and the SPD, drawn at 60 % and 50 % with their texts (`SymbolInstance.scale`, read back with the INSERT scale). `pvsld size` (and the MCP tool) now selects a DC breaker per string by default (`dc_ocpd: always`); the protection schedule names them "ITM de CD (cadena)" in "Caja CD"
110
+ - DC protection box after the owner's reference box (2026-10-08): both strings, after their breakers, feed the DC SPD to earth, then the box disconnect `DCD-CD1` (two poles per string, one tag, a dashed mechanical link between the pole pairs) opens them ahead of the inverter, inside the box; junction dots mark where the SPD taps leave the strings, so the SPD's earth line visibly crosses the lower string. The box stays 35 mm tall and grows in width to hold the disconnect. `pvsld size` adds `DCD-CD1` whenever it selects string breakers (assumption noted: ratings of the string breaker; the catalogue has no switch-disconnectors yet). `CircleItem.filled` draws a junction dot as a DONUT.
111
+ - Symbol library 0.7.0: `PVSLD_CB_DC` (the CFE breaker with DC ports); the inverter is 30 x 30 mm and the load centre 30 x 35 mm (owner request: smaller); the DC disconnect shows its tag above and its description below
112
+
113
+ ### Changed
114
+ - The README and the plugin guide install the plugin from the default branch (`/plugin marketplace add edu3250/Diagrama-unifilarAutoCAD`, then `/plugin install pv-unifilar@pvsld`), without `@develop`: `develop` is the repository's default branch since 2026-10-10. They also name Git as a requirement and `/plugin configure pv-unifilar@pvsld` for the output folder.
115
+ - `list_components` and `ComponentRegistry.find` match the manufacturer by a part of its name ("Jinko" finds "Jinko Solar").
116
+ - The bill of materials names every circuit of a shared conduit ("EMT 27 mm para C-S1 y C-S2").
117
+
118
+ ### Fixed
119
+ - (3.6.5 real-prompt tests) AutoCAD could not finish a design whose project folder had a long path (Windows error 206) or a character outside ASCII, and every design it did finish left a `.pvsld-staging-…` folder in the user's output folder, kept open by Autodesk's background services. Core Console now works on a copy of the DXF in a temporary folder; the DWG and the PDF are moved to the project folder, and work folders that could not be removed are swept by a later run.
120
+ - (3.6.5 real-prompt tests) A fuse or DC breaker fixed in the project sheet that does not fit was reported as "Ningún fusible gPV del catálogo cumple", which sent the user after a device the catalogue has. The cell now says "El fusible elegido no cumple (…) Elija otro de la lista o deje AUTO."
121
+ - (3.6.5 real-prompt tests) The project sheet's instructions and the missing-component message named the commands of the first plan (`/unifilar-pro`, `/unifilar-catalogo`) instead of `/pv-unifilar:pro` and `/pv-unifilar:catalogo`.
122
+ - On the A3 sheet, a protection schedule of eight rows (two string fuses) reached the last line of the grounding electrode's label; the earthing bus now rises just enough to clear it
123
+ - With the DC protection box, the protection schedule places the DC SPD in "Caja CD" (it gave the spec location, e.g. INV1.dc)
124
+ - The box disconnect DCD-CD1 records the switch's 4 poles when a single string runs through all of them in series
125
+ - Drawings on the owner's sheet template are editable in one place (owner request): the frame, template boxes, fixed texts, fields, symbology, schematic and protection schedule are all in model space at 1:1, and the file opens on the Model tab. The `A3` layout keeps only the 1:1 viewport, for plotting (`Diagram.sheet_in_model`). Every text, line and block can be edited directly; blocks keep their attributes
126
+ - Drawings and the symbol library open on their sheet (`A3`, `Legend`) in AutoCAD: `$TILEMODE` is 0. With ezdxf's default 1 they opened on the Model tab, where the sheet template, frame and title block (paper space) are not visible. The golden DXF, the library DXF and its DWG were regenerated
127
+
128
+ ### Added
129
+ - Phase 3, Stage 3.5: MCP tools `list_components` and `get_component` (reviewed catalogue, with datasheet provenance) and `size_pv_system` (the sizing engine: the selected design as a complete spec, ranked alternatives and rejections grouped by rule; about 3k tokens per result); resource `pvsld://examples/sizing-template`; `$PVSLD_CATALOGUE_DIR` (default `datasheets/records`). The server instructions now start from the catalogue
130
+
131
+ ## [0.4.0-symbols] - 2026-10-08
132
+
133
+ Symbol library, the generator drawing with it, and the owner's sheet template. Also ships the first part of Phase 3 (component catalogue and the sizing engine v1).
134
+
135
+ ### Added
136
+ - Symbol library (Phase 4, ADR-0005): 57 blocks `PVSLD_<FUNCTION>` (library 0.6.0) redrawn as vector geometry, each with its ports (DC, AC, PE, SIG, ANY) in XDATA, its attributes and the standard it comes from (hidden `SOURCE_STANDARD` and the *Fuente* column of the legend). `symbols/pvsld-symbols.dxf` (R2018, byte-reproducible) holds them with three `Legend` layouts grouped by family; `symbols/pvsld-symbols.dwg` is the same library as a TrustedDWG 2018 (AUDIT 0/0). `pvsld symbols build|list|validate|dwg`, `scripts/build_symbol_library.py`
137
+ - Parametric blocks defined on demand: the combiner box for 1 to 24 strings (`PVSLD_COMBINER_<n>S`) and a PV string with every module drawn (`PVSLD_PV_STRING_<n>M_UP|DN`, up to 30 modules); AC fuse `PVSLD_FUSE_AC`
138
+ - Layout template `a3_plantilla_v1`: the schematic on the owner's A3 sheet. `pvsld sheet import TEMPLATE.dwg|dxf` writes the neutral template `sheet_templates/a3_plantilla_v1.dxf` (published); the layout fills the heading, capacity, service, calculation summary, notes, circuit boxes, module and inverter data, symbology of the blocks drawn, protection schedule, drawing number and date. Personal data stays blank and the title block reads "COMPAÑÍA INSTALADORA". `pvsld size` produces designs on this sheet by default
139
+ - Component catalogue (Phase 3, ADR-0004): reviewed datasheet records under `datasheets/records/`, `pvsld catalogue validate|list|show`, review gate in CI
140
+ - Sizing engine v1 (Phase 3, Stage 3.4): `pvsld size REQUEST.yaml` enumerates string configurations per catalogue inverter, rejects those that break a rule, ranks the rest and writes a full specification; rule STR-007 and the DC/AC ratio policy (Stage 3.3)
141
+ - Diagram model: text styles and centred text, circles, scaled symbol samples; tables with a cell style and a centred title
142
+
143
+ ### Changed
144
+ - The generator imports the blocks a diagram uses from the library DXF (port XDATA included) instead of defining symbols in code; instances carry `SOURCE_STANDARD`, the inverter has no `CERT` attribute (certifications are out of scope); the symbology table cites each symbol's source; the golden DXF was regenerated
145
+ - The thermomagnetic breaker of the diagrams is `PVSLD_CB` (owner decision); `PVSLD_CB_IEC` stays as an alternative
146
+ - `pvsld.core.rules`: `Severity` lives in `pvsld.core.severity`; `calc.max_ocpd_for_ampacity_a` is shared by CON-003 and the conductor sizing
147
+
148
+ ### Removed
149
+ - `pvsld.symbols.catalogue` (the Phase 2 code-defined symbols) and `pvsld.backends.dxf.render_symbol_library`
150
+
151
+ ## [0.2.0-spike] - 2026-10-06
152
+
153
+ Phase 2 (MCP Server Prototype & Connectivity Spike) complete; ADR-0001 confirmed.
154
+
155
+ ### Added
156
+ - Phase 2, Stage 2.5: `docs/spikes/phase-2-review.md`, the spike review. It holds the per-stage results against the criteria, the ADR-0001 exit-gate evaluation (passed), the status of reversal triggers T1–T9 (none fired), the findings, the open items and the proposed (tentative) scope for Phases 3–5
157
+ - Phase 2, Stage 2.4 (S4, PR #6): Core Console finisher `pvsld.finishers.core_console` and `pvsld finish`: DXF → DWG 2018 (TrustedDWG) plus an AutoCAD-plotted A3 PDF through `accoreconsole.exe /isolate`, in 4.2–10.8 s per sheet. A run is ok only on several independent signals (exit code, progress markers, AUDIT summary, output formats), so failures are never silent. It also adds a CI fake runner, live `autocad` tests and the `scripts/s4_measure.py` harness; report `docs/spikes/s4-core-console.md`
158
+ - Phase 2, Stage 2.3 (S3, PR #5): stdio MCP server `pvsld-mcp` (`mcp` 2.3) with `validate_pv_design` and `generate_single_line_diagram`, plus the resources `pvsld://schema/pv-system-spec`, `pvsld://rulepack/mx-gd-2026.10` and `pvsld://symbols`. It writes into an output sandbox and returns a size-bounded PNG preview (`PVSLD_PREVIEW_MAX_BYTES`). The repo `.mcp.json` uses `${PVSLD_MCP_COMMAND:-pvsld-mcp}`. Pillow is a declared dependency, and specs over 256 KiB are refused. Report `docs/spikes/s3-mcp-round-trip.md`
159
+ - Phase 2, Stage 2.1 (S1, PR #3): deterministic core (`pvsld.core`: Pydantic parameter model, calculations, rule-pack subset VOLT-001, STR-001, STR-004, CON-003, PCC-002, MET-001, DIS-003, DIS-004), code-defined symbol catalogue (`pvsld.symbols`), backend-neutral diagram model and ezdxf DXF R2018 backend with PNG preview; `pvsld validate` and `pvsld generate`; byte-identical golden DXF on Windows and Linux
160
+ - Phase 2, Stage 2.2 (S2, PR #2): AutoCAD 2027 .NET 10 plug-in (bridge, Core-safe render assembly, desktop host) on a current-user named pipe with per-start secret; Python pipe client, fake plug-in and COM baseline; CI job building the plug-in and running its bridge tests
161
+ - `docs/decisions/ADR-0003-symbol-library-format.md`: symbol library format and `PVSLD_*` naming (accepted 2026-10-06)
162
+ - Phase 2, Stage 2.0 (Foundation): Python project scaffold for the `pvsld` package
163
+ - `pyproject.toml`: hatchling build, `src/` layout, version `0.2.0.dev0`, Python >= 3.11, MIT; runtime dependencies `ezdxf`, `mcp` 2.x, `pydantic` 2.x and `PyYAML`; extras `dev` (pytest, pytest-cov, ruff) and `autocad` (`pywin32`, Windows only); console script `pvsld`
164
+ - `src/pvsld/`: `__version__` read from package metadata, `py.typed`, and empty `core/`, `backends/`, `transports/` and `finishers/` subpackages whose docstrings state their role in ADR-0001
165
+ - `pvsld --version` (the Stage 2.0 `validate-example` smoke check was replaced by `pvsld validate` in Stage 2.1)
166
+ - `examples/residential_7p7kwp.yaml`: the 7.70 kWp / 6 kW @ 220 V worked example from the vault's PV SLD Parameter Model, marked as an illustrative sample
167
+ - `tests/`: package, CLI, `pyproject.toml` and example tests, and a `--run-autocad` option that skips `autocad`-marked tests (with a reason) unless it is given on Windows
168
+ - Ruff lint and format configuration; pytest with strict markers; coverage floor of 60 % on `pvsld`
169
+ - `.github/workflows/ci.yml`: ruff and pytest on Ubuntu and Windows with Python 3.11 and 3.12 (`contents: read` permissions)
170
+ - "Development setup" sections in `README.md` and `CONTRIBUTING.md` (virtual environment, ruff, pytest, AutoCAD tests)
171
+
172
+ ### Fixed
173
+ - Backend (PR #7): the overall paper-space viewport is on layer `0` and the layout names the canonical `ISO_full_bleed_A3_(420.00_x_297.00_MM)` paper. AutoCAD 2027 AUDIT of the S1 DXF goes from 2 errors to 0 errors, 0 fixed (Core Console). The read-back counts that viewport apart from drawing content; the golden DXF is regenerated, and ADR-0003 states the layer-0 exception
174
+
175
+ ### Changed
176
+ - `docs/decisions/ADR-0001-claude-autocad-integration.md`: "Phase 2 validation (2026-10-06)" section appended. The ADR is confirmed by spikes S1–S4 and its status is unchanged
177
+ - `IMPLEMENTATION_PLAN.md`: Stages 2.3 and 2.4 Complete; Stage 2.5 Complete except the `v0.2.0-spike` tag; Phase 2 Complete pending release; tentative scopes for Phases 3–5 refined from the review
178
+ - `README.md`: status (Phase 2 complete, pending `v0.2.0-spike`), roadmap, and quick-start notes for the MCP server and `PVSLD_MCP_COMMAND`
179
+ - `docs/README.md`: lists `docs/spikes/` and ADR-0003; update notes on the S2, S3 and S4 reports point to the review
180
+ - `IMPLEMENTATION_PLAN.md`: Stage 1.7 records the public GitHub repository and the `v0.1.0-docs` GitHub release
181
+ - `IMPLEMENTATION_PLAN.md`: Stages 2.0–2.2 Complete; the `.mcp.json` placeholder is replaced by creating `.mcp.json` in Stage 2.3 together with a working server
182
+ - `.gitignore`: ignore `.venv/` and `.ruff_cache/`
183
+ - `CONTRIBUTING.md`: the Python checks are now ruff and pytest (previously black and flake8)
184
+
185
+ ## [0.1.0-docs] - 2026-10-05
186
+
187
+ Phase 1 (Documentation & Regulatory Research) complete.
188
+
189
+ ### Added
190
+ - Initial repository scaffold with GitFlow structure (main, develop, feature/* branches)
191
+ - `README.md` with project vision, current status, and roadmap
192
+ - `CONTRIBUTING.md` with detailed GitFlow workflow and Conventional Commits guidelines
193
+ - `LICENSE` (MIT, Copyright 2026 edu3250)
194
+ - `.gitignore` covering Python, Node.js, AutoCAD, IDE, and OS temporary files
195
+ - `CHANGELOG.md` (this file) following Keep a Changelog format
196
+ - `IMPLEMENTATION_PLAN.md` with seven detailed stages for Phase 1 (Documentation & Research)
197
+ - `docs/README.md` explaining technical documentation structure
198
+ - Obsidian research vault scaffold (author's local vault, not part of this repository) with research domains
199
+ - Phase 1 research corpus in the Obsidian vault (Stages 1.2, 1.3, 1.5, 1.6): 252 research notes (129 sources, 78 entities, 37 concepts, 8 comparisons). It covers:
200
+ - Autodesk APIs and MCP servers;
201
+ - MCP and Claude integration;
202
+ - a survey of community AutoCAD MCP servers;
203
+ - programmatic DWG/DXF generation, including a hands-on ezdxf probe;
204
+ - Mexican regulation, including the machine-checkable SLD checklist MX-A01…MX-I07;
205
+ - PV single-line-diagram engineering: parameter model v0.1.0 and validation rules.
206
+ - `docs/decisions/ADR-0001-claude-autocad-integration.md`: ADR-0001 accepted (Stage 1.4). It adopts a layered hybrid: a Python stdio MCP server, a deterministic core (parameter model → calculations → `mx-gd-2026.10` rule pack → diagram model), an ezdxf DXF backend first and an AutoCAD 2027 .NET 10 plug-in backend second. Vault original: `wiki/decisions/ADR-0001 Integration Approach.md`
207
+ - `docs/research/phase-1-summary.md`: condensed English summary of the Phase 1 findings, open questions and a map of the vault
208
+ - `.gitattributes`: LF normalization for text; DXF/DWG/PDF/PNG kept byte-exact for golden-file tests
209
+ - Stage 1.7 vault lint (`Lint Report 2026-10-05` in the vault): 0 dead links, 0 orphans, 0 frontmatter failures; 2 errors and 10 warnings fixed (8 uncovered MX checklist items received rules, rule pack now 98 rules; pre-ADR notes aligned with ADR-0001)
210
+
211
+ ### Changed
212
+ - `IMPLEMENTATION_PLAN.md`: Stages 1.1–1.7 marked Complete. Phase 2 is refined into tentative stages 2.1–2.5 (spikes S1–S4 from ADR-0001 plus a review), still to be confirmed by the owner
213
+ - `README.md`: status, roadmap and documentation links updated
214
+ - `docs/README.md`: directory tree lists `docs/research/`
215
+ - Checklist coverage figures corrected after the vault lint: 77 MX items, 71 machine-checkable (92 %)
216
+
217
+ ---
218
+
219
+ ## Version Numbering Convention
220
+
221
+ - **`v0.1.0-docs`** — Phase 1 complete; documentation and research published
222
+ - **`v0.2.0-spike`** — Phase 2 complete; MCP connectivity prototype validated
223
+ - **`v0.3.0-engine`** — Phase 3 complete; parametric PV sizing engine
224
+ - **`v1.0.0`** — Phase 5 complete; full product release with Mexican regulatory compliance
225
+
226
+ ---
227
+
228
+ **Repository:** https://github.com/edu3250/PvUnifilar
229
+ **Maintainer:** edu3250 (edu3250@gmail.com)
230
+ **Last updated:** 2026-10-13
pvsld-0.6.0/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 edu3250
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
pvsld-0.6.0/PKG-INFO ADDED
@@ -0,0 +1,76 @@
1
+ Metadata-Version: 2.5
2
+ Name: pvsld
3
+ Version: 0.6.0
4
+ Summary: PvUnifilar: MCP server and CLI that design and draw Mexican photovoltaic single-line diagrams.
5
+ Project-URL: Homepage, https://github.com/edu3250/PvUnifilar
6
+ Project-URL: Issues, https://github.com/edu3250/PvUnifilar/issues
7
+ Project-URL: Changelog, https://github.com/edu3250/PvUnifilar/blob/develop/CHANGELOG.md
8
+ Author-email: edu3250 <edu3250@gmail.com>
9
+ License-Expression: MIT
10
+ License-File: LICENSE
11
+ Keywords: autocad,dxf,mcp,nom-001-sede,photovoltaic,single-line-diagram
12
+ Classifier: Development Status :: 3 - Alpha
13
+ Classifier: Intended Audience :: Science/Research
14
+ Classifier: Natural Language :: Spanish
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3.11
17
+ Classifier: Programming Language :: Python :: 3.12
18
+ Classifier: Topic :: Scientific/Engineering
19
+ Classifier: Typing :: Typed
20
+ Requires-Python: >=3.11
21
+ Requires-Dist: ezdxf<1.5,>=1.4.4
22
+ Requires-Dist: matplotlib<4,>=3.9
23
+ Requires-Dist: mcp<3,>=2.3
24
+ Requires-Dist: openpyxl<4,>=3.1
25
+ Requires-Dist: pillow<13,>=10
26
+ Requires-Dist: pydantic<3,>=2.7
27
+ Requires-Dist: pyyaml>=6
28
+ Requires-Dist: reportlab<6,>=4
29
+ Provides-Extra: autocad
30
+ Requires-Dist: pywin32; (sys_platform == 'win32') and extra == 'autocad'
31
+ Provides-Extra: dev
32
+ Requires-Dist: pytest-cov>=5; extra == 'dev'
33
+ Requires-Dist: pytest>=8; extra == 'dev'
34
+ Requires-Dist: ruff<0.17,>=0.16; extra == 'dev'
35
+ Description-Content-Type: text/markdown
36
+
37
+ # pvsld: el servidor de PvUnifilar
38
+
39
+ Servidor MCP y línea de comandos que diseñan y dibujan el **diagrama unifilar de un sistema fotovoltaico interconectado en México** (baja tensión, NOM-001-SEDE-2012) a partir de una petición sencilla.
40
+
41
+ > "Hazme un diagrama unifilar con 12 paneles Jinko de 475 W"
42
+
43
+ ![Plano unifilar A3 de un sistema de 5.70 kWp](https://raw.githubusercontent.com/edu3250/PvUnifilar/develop/docs/images/readme/plano-unifilar.png)
44
+
45
+ Una petición entrega, en una carpeta por proyecto: el plano en DWG (con AutoCAD) o DXF, su PDF en A3, la memoria de cálculo en Excel con fórmulas y en PDF, una hoja de proyecto editable y el resumen de materiales. Un modelo de lenguaje pide y explica; el cálculo y el dibujo los hace código determinista, con equipos tomados de un catálogo de fichas revisadas contra su hoja técnica.
46
+
47
+ ## Uso
48
+
49
+ Con [uv](https://docs.astral.sh/uv/) instalado, cualquier cliente MCP puede ejecutar el servidor:
50
+
51
+ ```json
52
+ {
53
+ "mcpServers": {
54
+ "pvsld": {
55
+ "command": "uvx",
56
+ "args": ["--from", "pvsld", "pvsld-mcp"]
57
+ }
58
+ }
59
+ }
60
+ ```
61
+
62
+ En Claude Code, Copilot CLI y Antigravity CLI se instala como plugin, con sus tres flujos (`diagrama`, `pro`, `catalogo`): las instrucciones están en el [repositorio](https://github.com/edu3250/PvUnifilar) y en la [guía de usuario](https://github.com/edu3250/PvUnifilar/blob/develop/docs/guia-de-usuario.md).
63
+
64
+ Sin un modelo de por medio:
65
+
66
+ ```bash
67
+ uvx --from pvsld pvsld design peticion.yaml -o out/casa
68
+ ```
69
+
70
+ ## Alcance
71
+
72
+ Sistemas residenciales sin baterías, un inversor de cadena, hasta dos cadenas, servicio 1F-2H o 2F-3H. AutoCAD es opcional (Windows).
73
+
74
+ **Los planos son borradores:** un ingeniero responsable debe revisarlos y firmarlos antes de cualquier trámite. Este proyecto no está afiliado a CFE, a Autodesk ni a ningún fabricante.
75
+
76
+ Licencia MIT. Código, cambios y reportes: <https://github.com/edu3250/PvUnifilar>.