@christianmaf80/agentic-workflow 1.10.0-beta.1 → 1.12.0-beta.1

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 (360) hide show
  1. package/bin/cli.js +2 -1
  2. package/dist/artifacts/1-mcp-server-extensio-cli/analysis.md +480 -0
  3. package/dist/artifacts/1-mcp-server-extensio-cli/architect/review.md +285 -0
  4. package/dist/artifacts/1-mcp-server-extensio-cli/changelog.md +29 -0
  5. package/dist/artifacts/1-mcp-server-extensio-cli/implementer-agent/subtask-implementation.md +321 -0
  6. package/dist/artifacts/1-mcp-server-extensio-cli/plan.md +522 -0
  7. package/dist/artifacts/1-mcp-server-extensio-cli/researcher/research.md +270 -0
  8. package/dist/artifacts/1-mcp-server-extensio-cli/results.md +143 -0
  9. package/dist/artifacts/1-mcp-server-extensio-cli/task-metrics.md +33 -0
  10. package/dist/artifacts/1-mcp-server-extensio-cli/task.md +178 -0
  11. package/dist/artifacts/1-mcp-server-extensio-cli/walkthrough.md +69 -0
  12. package/dist/artifacts/10-shard-build-plugin/analysis.md +290 -0
  13. package/dist/artifacts/10-shard-build-plugin/architect/subtask-implementation.md +105 -0
  14. package/dist/artifacts/10-shard-build-plugin/plan.md +409 -0
  15. package/dist/artifacts/10-shard-build-plugin/researcher/research.md +109 -0
  16. package/dist/artifacts/10-shard-build-plugin/task.md +124 -0
  17. package/dist/artifacts/11-revision-sistema-agentic/analysis.md +43 -0
  18. package/dist/artifacts/11-revision-sistema-agentic/cli-mcp-impact.md +186 -0
  19. package/dist/artifacts/11-revision-sistema-agentic/core-impact.md +162 -0
  20. package/dist/artifacts/11-revision-sistema-agentic/metrics.md +82 -0
  21. package/dist/artifacts/11-revision-sistema-agentic/modules-create-v2.md +126 -0
  22. package/dist/artifacts/11-revision-sistema-agentic/modules-v2.md +250 -0
  23. package/dist/artifacts/11-revision-sistema-agentic/pages-v2.md +366 -0
  24. package/dist/artifacts/11-revision-sistema-agentic/researcher/research.md +131 -0
  25. package/dist/artifacts/11-revision-sistema-agentic/results.md +116 -0
  26. package/dist/artifacts/11-revision-sistema-agentic/shards-v2.md +424 -0
  27. package/dist/artifacts/11-revision-sistema-agentic/task.md +145 -0
  28. package/dist/artifacts/11-revision-sistema-agentic/verification.md +119 -0
  29. package/dist/artifacts/12-adaptacion-core-cli-surfaces/analysis-architecture-change.md +305 -0
  30. package/dist/artifacts/12-adaptacion-core-cli-surfaces/analysis.md +301 -0
  31. package/dist/artifacts/12-adaptacion-core-cli-surfaces/error-analysis.md +93 -0
  32. package/dist/artifacts/12-adaptacion-core-cli-surfaces/implementation-summary.md +111 -0
  33. package/dist/artifacts/12-adaptacion-core-cli-surfaces/plan.md +387 -0
  34. package/dist/artifacts/12-adaptacion-core-cli-surfaces/researcher/research.md +266 -0
  35. package/dist/artifacts/12-adaptacion-core-cli-surfaces/task.md +167 -0
  36. package/dist/artifacts/13-dual-lifecycle-system/analysis.md +173 -0
  37. package/dist/artifacts/13-dual-lifecycle-system/architect/review.md +67 -0
  38. package/dist/artifacts/13-dual-lifecycle-system/plan.md +230 -0
  39. package/dist/artifacts/13-dual-lifecycle-system/researcher/research.md +243 -0
  40. package/dist/artifacts/13-dual-lifecycle-system/task.md +130 -0
  41. package/dist/artifacts/13-dual-lifecycle-system/verification.md +84 -0
  42. package/dist/artifacts/14-core-tests-refactor/analysis.md +240 -0
  43. package/dist/artifacts/14-core-tests-refactor/architect/review.md +33 -0
  44. package/dist/artifacts/14-core-tests-refactor/evaluation.md +40 -0
  45. package/dist/artifacts/14-core-tests-refactor/plan.md +344 -0
  46. package/dist/artifacts/14-core-tests-refactor/researcher/research.md +258 -0
  47. package/dist/artifacts/14-core-tests-refactor/results.md +117 -0
  48. package/dist/artifacts/14-core-tests-refactor/task.md +163 -0
  49. package/dist/artifacts/14-core-tests-refactor/verification.md +87 -0
  50. package/dist/artifacts/15-sistema-evaluacion-agentes/architect/implementation.md +47 -0
  51. package/dist/artifacts/15-sistema-evaluacion-agentes/brief.md +100 -0
  52. package/dist/artifacts/15-sistema-evaluacion-agentes/closure.md +81 -0
  53. package/dist/artifacts/15-sistema-evaluacion-agentes/task.md +83 -0
  54. package/dist/artifacts/16-refactorizacion-demo-core/analysis.md +160 -0
  55. package/dist/artifacts/16-refactorizacion-demo-core/architect/implementation.md +180 -0
  56. package/dist/artifacts/16-refactorizacion-demo-core/changelog.md +15 -0
  57. package/dist/artifacts/16-refactorizacion-demo-core/metrics.md +17 -0
  58. package/dist/artifacts/16-refactorizacion-demo-core/plan.md +270 -0
  59. package/dist/artifacts/16-refactorizacion-demo-core/researcher/research.md +190 -0
  60. package/dist/artifacts/16-refactorizacion-demo-core/task.md +124 -0
  61. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/analysis.md +108 -0
  62. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/architect/review-subtask-1.md +98 -0
  63. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/architect/review.md +192 -0
  64. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/architect/step-4-postponed.md +41 -0
  65. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/module-agent/activation-fix-demo.md +73 -0
  66. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/module-agent/activation-subtask-2.md +80 -0
  67. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/module-agent/fix-demo-implementation.md +113 -0
  68. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/module-agent/subtask-2-implementation.md +133 -0
  69. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/module-agent/subtask-implementation.md +130 -0
  70. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/plan.md +188 -0
  71. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/qa-agent/activation-demo-build.md +80 -0
  72. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/qa-agent/activation-phase-5.md +73 -0
  73. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/qa-agent/activation-subtask-5-7.md +97 -0
  74. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/qa-agent/issue-demo-integrity.md +39 -0
  75. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/qa-agent/subtask-5-7-implementation.md +188 -0
  76. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/qa-agent/verification.md +207 -0
  77. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/researcher/research.md +103 -0
  78. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/subtask-1-engine-refactor.md +64 -0
  79. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/surface-agent/activation-subtask-3.md +81 -0
  80. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/surface-agent/subtask-3-implementation.md +148 -0
  81. package/dist/artifacts/17-implementacion-loadshard-external-agnostic--esm/task.md +146 -0
  82. package/dist/artifacts/18-refactor-phase-4-implementation/task.md +140 -0
  83. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/agent-scores.md +58 -0
  84. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/agent-tasks/1-architect-refactor-research-template.md +78 -0
  85. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/agent-tasks/2-architect-refactor-analysis-template.md +76 -0
  86. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/agent-tasks/3-architect-update-phase1-workflow.md +77 -0
  87. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/agent-tasks/4-architect-update-phase2-workflow.md +76 -0
  88. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/agent-tasks/5-architect-create-todo-structure.md +77 -0
  89. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/agent-tasks/6-qa-validation.md +95 -0
  90. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/analysis.md +190 -0
  91. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/architect/review.md +68 -0
  92. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/plan.md +203 -0
  93. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/researcher/research.md +296 -0
  94. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/task.md +132 -0
  95. package/dist/artifacts/19-refinar-sistema-agentes-ciclo-vida/verification.md +104 -0
  96. package/dist/artifacts/2-review-mcp-agent-system/analysis.md +133 -0
  97. package/dist/artifacts/2-review-mcp-agent-system/architect/infrastructure-migration.md +58 -0
  98. package/dist/artifacts/2-review-mcp-agent-system/architect/mcp-server-refactor.md +57 -0
  99. package/dist/artifacts/2-review-mcp-agent-system/architect/review.md +83 -0
  100. package/dist/artifacts/2-review-mcp-agent-system/changelog.md +22 -0
  101. package/dist/artifacts/2-review-mcp-agent-system/metrics.md +33 -0
  102. package/dist/artifacts/2-review-mcp-agent-system/plan.md +141 -0
  103. package/dist/artifacts/2-review-mcp-agent-system/qa/mcp-test-validation.md +60 -0
  104. package/dist/artifacts/2-review-mcp-agent-system/researcher/research.md +77 -0
  105. package/dist/artifacts/2-review-mcp-agent-system/results-acceptance.md +115 -0
  106. package/dist/artifacts/2-review-mcp-agent-system/task.md +127 -0
  107. package/dist/artifacts/2-review-mcp-agent-system/verification.md +72 -0
  108. package/dist/artifacts/20-anadir-seccion-reasoning-agent-task/analysis.md +139 -0
  109. package/dist/artifacts/20-anadir-seccion-reasoning-agent-task/plan.md +146 -0
  110. package/dist/artifacts/20-anadir-seccion-reasoning-agent-task/researcher/research.md +142 -0
  111. package/dist/artifacts/20-anadir-seccion-reasoning-agent-task/task.md +143 -0
  112. package/dist/artifacts/20-anadir-seccion-reasoning-agent-task/verification.md +53 -0
  113. package/dist/artifacts/2026-01-19-orchestration-init/brief.md +88 -0
  114. package/dist/artifacts/2026-01-19-orchestration-init/closure.md +80 -0
  115. package/dist/artifacts/2026-01-19-orchestration-init/implementation.md +20 -0
  116. package/dist/artifacts/21-portable-agentic-system/researcher/research.md +121 -0
  117. package/dist/artifacts/21-portable-agentic-system/task.md +115 -0
  118. package/dist/artifacts/22-standardize-phase-0-artifact/architect/analysis.md +113 -0
  119. package/dist/artifacts/22-standardize-phase-0-artifact/architect/plan.md +124 -0
  120. package/dist/artifacts/22-standardize-phase-0-artifact/researcher/research.md +76 -0
  121. package/dist/artifacts/22-standardize-phase-0-artifact/results.md +36 -0
  122. package/dist/artifacts/22-standardize-phase-0-artifact/task.md +115 -0
  123. package/dist/artifacts/22-standardize-phase-0-artifact/verification.md +41 -0
  124. package/dist/artifacts/23-auditoria-de-indexes-y-alias/acceptance.md +62 -0
  125. package/dist/artifacts/23-auditoria-de-indexes-y-alias/architect/analysis.md +90 -0
  126. package/dist/artifacts/23-auditoria-de-indexes-y-alias/architect/plan.md +85 -0
  127. package/dist/artifacts/23-auditoria-de-indexes-y-alias/audit-report.md +52 -0
  128. package/dist/artifacts/23-auditoria-de-indexes-y-alias/researcher/research.md +52 -0
  129. package/dist/artifacts/23-auditoria-de-indexes-y-alias/results.md +31 -0
  130. package/dist/artifacts/23-auditoria-de-indexes-y-alias/task.md +90 -0
  131. package/dist/artifacts/23-auditoria-de-indexes-y-alias/verification.md +42 -0
  132. package/dist/artifacts/24-revision-priorizacion-todo-backlog/analysis.md +64 -0
  133. package/dist/artifacts/24-revision-priorizacion-todo-backlog/candidate/acceptance.md +68 -0
  134. package/dist/artifacts/24-revision-priorizacion-todo-backlog/planning.md +79 -0
  135. package/dist/artifacts/24-revision-priorizacion-todo-backlog/portable-roadmap.md +25 -0
  136. package/dist/artifacts/24-revision-priorizacion-todo-backlog/researcher/research.md +91 -0
  137. package/dist/artifacts/24-revision-priorizacion-todo-backlog/task.md +89 -0
  138. package/dist/artifacts/24-revision-priorizacion-todo-backlog/verification.md +59 -0
  139. package/dist/artifacts/25-auditoria-omision-gates/acceptance.md +57 -0
  140. package/dist/artifacts/25-auditoria-omision-gates/brief.md +89 -0
  141. package/dist/artifacts/25-auditoria-omision-gates/closure.md +88 -0
  142. package/dist/artifacts/25-auditoria-omision-gates/rca.md +49 -0
  143. package/dist/artifacts/25-auditoria-omision-gates/task.md +64 -0
  144. package/dist/artifacts/26-portable-agentic-system/acceptance.md +41 -0
  145. package/dist/artifacts/26-portable-agentic-system/agent-tasks/1-architect-scaffolding.md +113 -0
  146. package/dist/artifacts/26-portable-agentic-system/agent-tasks/2-architect-core-migration.md +117 -0
  147. package/dist/artifacts/26-portable-agentic-system/agent-tasks/3-architect-cli-implementation.md +109 -0
  148. package/dist/artifacts/26-portable-agentic-system/agent-tasks/4-architect-linking-and-verification.md +104 -0
  149. package/dist/artifacts/26-portable-agentic-system/analysis.md +117 -0
  150. package/dist/artifacts/26-portable-agentic-system/architect/review.md +41 -0
  151. package/dist/artifacts/26-portable-agentic-system/plan.md +146 -0
  152. package/dist/artifacts/26-portable-agentic-system/researcher/research.md +96 -0
  153. package/dist/artifacts/26-portable-agentic-system/task.md +50 -0
  154. package/dist/artifacts/26-portable-agentic-system/verification.md +67 -0
  155. package/dist/artifacts/27-update-portable-module-agent-identity/acceptance.md +74 -0
  156. package/dist/artifacts/27-update-portable-module-agent-identity/agent-tasks/1-module-agent-update-templates.md +86 -0
  157. package/dist/artifacts/27-update-portable-module-agent-identity/agent-tasks/2-module-agent-update-workflows-long.md +88 -0
  158. package/dist/artifacts/27-update-portable-module-agent-identity/agent-tasks/3-module-agent-update-workflows-short-init.md +89 -0
  159. package/dist/artifacts/27-update-portable-module-agent-identity/agent-tasks/4-module-agent-update-roles.md +85 -0
  160. package/dist/artifacts/27-update-portable-module-agent-identity/agent-tasks/5-module-agent-update-version-manifests.md +84 -0
  161. package/dist/artifacts/27-update-portable-module-agent-identity/analysis.md +90 -0
  162. package/dist/artifacts/27-update-portable-module-agent-identity/architect/review.md +44 -0
  163. package/dist/artifacts/27-update-portable-module-agent-identity/changelog.md +17 -0
  164. package/dist/artifacts/27-update-portable-module-agent-identity/metrics.md +52 -0
  165. package/dist/artifacts/27-update-portable-module-agent-identity/plan.md +122 -0
  166. package/dist/artifacts/27-update-portable-module-agent-identity/researcher/research.md +73 -0
  167. package/dist/artifacts/27-update-portable-module-agent-identity/results-acceptance.md +51 -0
  168. package/dist/artifacts/27-update-portable-module-agent-identity/task.md +115 -0
  169. package/dist/artifacts/27-update-portable-module-agent-identity/verification.md +66 -0
  170. package/dist/artifacts/28-agent-system-update-conversion/acceptance.md +67 -0
  171. package/dist/artifacts/28-agent-system-update-conversion/agent-tasks/1-tooling-agent-migration-infrastructure.md +88 -0
  172. package/dist/artifacts/28-agent-system-update-conversion/agent-tasks/2-tooling-agent-content-transformer.md +87 -0
  173. package/dist/artifacts/28-agent-system-update-conversion/agent-tasks/3-tooling-agent-cli-wizard-integration.md +86 -0
  174. package/dist/artifacts/28-agent-system-update-conversion/analysis.md +153 -0
  175. package/dist/artifacts/28-agent-system-update-conversion/architect/review.md +93 -0
  176. package/dist/artifacts/28-agent-system-update-conversion/metrics.md +43 -0
  177. package/dist/artifacts/28-agent-system-update-conversion/plan.md +153 -0
  178. package/dist/artifacts/28-agent-system-update-conversion/researcher/research.md +66 -0
  179. package/dist/artifacts/28-agent-system-update-conversion/results-acceptance.md +125 -0
  180. package/dist/artifacts/28-agent-system-update-conversion/task.md +103 -0
  181. package/dist/artifacts/28-agent-system-update-conversion/verification.md +60 -0
  182. package/dist/artifacts/29-agentic-framework-core-reference-refactor/acceptance.md +38 -0
  183. package/dist/artifacts/29-agentic-framework-core-reference-refactor/agent-tasks/1-tooling-agent-core-resolver.md +85 -0
  184. package/dist/artifacts/29-agentic-framework-core-reference-refactor/agent-tasks/2-tooling-agent-init-refactor.md +90 -0
  185. package/dist/artifacts/29-agentic-framework-core-reference-refactor/agent-tasks/3-tooling-agent-scaffolding-system.md +92 -0
  186. package/dist/artifacts/29-agentic-framework-core-reference-refactor/agent-tasks/4-architect-agents-md-trail.md +84 -0
  187. package/dist/artifacts/29-agentic-framework-core-reference-refactor/agent-tasks/5-tooling-agent-mcp-server.md +92 -0
  188. package/dist/artifacts/29-agentic-framework-core-reference-refactor/agent-tasks/6-architect-neo-agent-birth.md +85 -0
  189. package/dist/artifacts/29-agentic-framework-core-reference-refactor/analysis.md +119 -0
  190. package/dist/artifacts/29-agentic-framework-core-reference-refactor/architect/review.md +46 -0
  191. package/dist/artifacts/29-agentic-framework-core-reference-refactor/plan.md +95 -0
  192. package/dist/artifacts/29-agentic-framework-core-reference-refactor/researcher/research.md +68 -0
  193. package/dist/artifacts/29-agentic-framework-core-reference-refactor/results-acceptance.md +59 -0
  194. package/dist/artifacts/29-agentic-framework-core-reference-refactor/task.md +99 -0
  195. package/dist/artifacts/29-agentic-framework-core-reference-refactor/verification.md +54 -0
  196. package/dist/artifacts/3-developer-feedback-gate/acceptance-criteria.md +18 -0
  197. package/dist/artifacts/3-developer-feedback-gate/analysis.md +27 -0
  198. package/dist/artifacts/3-developer-feedback-gate/changelog.md +10 -0
  199. package/dist/artifacts/3-developer-feedback-gate/implementation_plan.md +32 -0
  200. package/dist/artifacts/3-developer-feedback-gate/init.md +13 -0
  201. package/dist/artifacts/3-developer-feedback-gate/metrics.md +34 -0
  202. package/dist/artifacts/3-developer-feedback-gate/research.md +28 -0
  203. package/dist/artifacts/3-developer-feedback-gate/results-acceptance.md +17 -0
  204. package/dist/artifacts/3-developer-feedback-gate/task.md +17 -0
  205. package/dist/artifacts/3-developer-feedback-gate/verification.md +35 -0
  206. package/dist/artifacts/30-task-execution-protocol-gates/acceptance.md +46 -0
  207. package/dist/artifacts/30-task-execution-protocol-gates/researcher/research.md +34 -0
  208. package/dist/artifacts/30-task-execution-protocol-gates/task.md +77 -0
  209. package/dist/artifacts/4-adr-workflows-modulos/adr.md +380 -0
  210. package/dist/artifacts/4-adr-workflows-modulos/analysis.md +353 -0
  211. package/dist/artifacts/4-adr-workflows-modulos/plan.md +301 -0
  212. package/dist/artifacts/4-adr-workflows-modulos/researcher/research.md +253 -0
  213. package/dist/artifacts/4-adr-workflows-modulos/results.md +202 -0
  214. package/dist/artifacts/4-adr-workflows-modulos/task.md +143 -0
  215. package/dist/artifacts/4-adr-workflows-modulos/verification.md +123 -0
  216. package/dist/artifacts/5-implementar-adr-crear-modulo/analysis.md +169 -0
  217. package/dist/artifacts/5-implementar-adr-crear-modulo/architect/review.md +105 -0
  218. package/dist/artifacts/5-implementar-adr-crear-modulo/architect/subtask-implementation.md +90 -0
  219. package/dist/artifacts/5-implementar-adr-crear-modulo/changelog.md +7 -0
  220. package/dist/artifacts/5-implementar-adr-crear-modulo/metrics.md +34 -0
  221. package/dist/artifacts/5-implementar-adr-crear-modulo/plan.md +163 -0
  222. package/dist/artifacts/5-implementar-adr-crear-modulo/researcher/research.md +105 -0
  223. package/dist/artifacts/5-implementar-adr-crear-modulo/results-acceptance.md +153 -0
  224. package/dist/artifacts/5-implementar-adr-crear-modulo/task.md +147 -0
  225. package/dist/artifacts/5-implementar-adr-crear-modulo/verification.md +79 -0
  226. package/dist/artifacts/6-exportar-ciclo-agent-zip/analysis.md +153 -0
  227. package/dist/artifacts/6-exportar-ciclo-agent-zip/architect/review.md +103 -0
  228. package/dist/artifacts/6-exportar-ciclo-agent-zip/architect/subtask-implementation.md +79 -0
  229. package/dist/artifacts/6-exportar-ciclo-agent-zip/changelog.md +8 -0
  230. package/dist/artifacts/6-exportar-ciclo-agent-zip/metrics.md +34 -0
  231. package/dist/artifacts/6-exportar-ciclo-agent-zip/plan.md +131 -0
  232. package/dist/artifacts/6-exportar-ciclo-agent-zip/researcher/research.md +86 -0
  233. package/dist/artifacts/6-exportar-ciclo-agent-zip/results-acceptance.md +108 -0
  234. package/dist/artifacts/6-exportar-ciclo-agent-zip/task.md +147 -0
  235. package/dist/artifacts/6-exportar-ciclo-agent-zip/verification.md +74 -0
  236. package/dist/artifacts/6-exportar-ciclo-agent-zip/whitelist.txt +33 -0
  237. package/dist/artifacts/7-modules-globals-constants/analysis.md +205 -0
  238. package/dist/artifacts/7-modules-globals-constants/architect/review.md +110 -0
  239. package/dist/artifacts/7-modules-globals-constants/metrics.md +45 -0
  240. package/dist/artifacts/7-modules-globals-constants/plan.md +276 -0
  241. package/dist/artifacts/7-modules-globals-constants/researcher/research.md +247 -0
  242. package/dist/artifacts/7-modules-globals-constants/task.md +112 -0
  243. package/dist/artifacts/7-modules-globals-constants/verification.md +76 -0
  244. package/dist/artifacts/8-module-workflow-refactor/analysis.md +131 -0
  245. package/dist/artifacts/8-module-workflow-refactor/changelog.md +24 -0
  246. package/dist/artifacts/8-module-workflow-refactor/metrics.md +37 -0
  247. package/dist/artifacts/8-module-workflow-refactor/plan.md +193 -0
  248. package/dist/artifacts/8-module-workflow-refactor/researcher/research.md +222 -0
  249. package/dist/artifacts/8-module-workflow-refactor/results.md +112 -0
  250. package/dist/artifacts/8-module-workflow-refactor/review.md +76 -0
  251. package/dist/artifacts/8-module-workflow-refactor/task.md +154 -0
  252. package/dist/artifacts/8-module-workflow-refactor/verification.md +76 -0
  253. package/dist/artifacts/8-module-workflow-refactor/walkthrough.md +64 -0
  254. package/dist/artifacts/9-build-stabilization/analysis.md +62 -0
  255. package/dist/artifacts/9-build-stabilization/metrics.md +11 -0
  256. package/dist/artifacts/9-build-stabilization/plan.md +82 -0
  257. package/dist/artifacts/9-build-stabilization/researcher/research.md +102 -0
  258. package/dist/artifacts/9-build-stabilization/task.md +23 -0
  259. package/dist/artifacts/9-build-stabilization/walkthrough.md +56 -0
  260. package/dist/artifacts/candidate/init.md +34 -0
  261. package/dist/artifacts/candidate/task.md +24 -0
  262. package/dist/artifacts/index.md +31 -10
  263. package/dist/cli/commands/init.js +43 -144
  264. package/dist/cli/commands/restore.js +4 -11
  265. package/dist/core/migration/backup.js +2 -3
  266. package/dist/core/utils/backup.js +3 -24
  267. package/dist/index.md +57 -0
  268. package/dist/metrics/agent-scores.md +30 -0
  269. package/dist/metrics/agents.json +106 -0
  270. package/dist/metrics/index.md +23 -0
  271. package/dist/rules/constitution/GEMINI.location.md +17 -14
  272. package/dist/rules/constitution/agents-behavior.md +111 -107
  273. package/dist/rules/constitution/clean-code.md +65 -13
  274. package/dist/rules/constitution/drivers.md +294 -0
  275. package/dist/rules/constitution/extensio-architecture.md +131 -0
  276. package/dist/rules/constitution/index.md +15 -13
  277. package/dist/rules/constitution/modules.md +280 -0
  278. package/dist/rules/constitution/pages.md +454 -0
  279. package/dist/rules/constitution/shards.md +484 -0
  280. package/dist/rules/index.md +57 -12
  281. package/dist/rules/roles/architect.md +128 -28
  282. package/dist/rules/roles/driver.md +172 -0
  283. package/dist/rules/roles/index.md +20 -18
  284. package/dist/rules/roles/module.md +175 -0
  285. package/dist/rules/roles/neo.md +6 -18
  286. package/dist/rules/roles/qa.md +195 -8
  287. package/dist/rules/roles/researcher.md +75 -10
  288. package/dist/rules/roles/surface.md +60 -0
  289. package/dist/rules/roles/tooling.md +55 -9
  290. package/dist/skills/extensio-build/SKILL.md +161 -0
  291. package/dist/skills/extensio-create-driver/SKILL.md +89 -0
  292. package/dist/skills/extensio-create-module/SKILL.md +91 -0
  293. package/dist/skills/extensio-demo/SKILL.md +84 -0
  294. package/dist/skills/extensio-test/SKILL.md +96 -0
  295. package/dist/skills/extensio-validate-code/SKILL.md +262 -0
  296. package/dist/skills/index.md +79 -0
  297. package/dist/templates/acceptance.md +20 -20
  298. package/dist/templates/agent-scores.md +7 -11
  299. package/dist/templates/agent-task.md +60 -63
  300. package/dist/templates/analysis.md +92 -92
  301. package/dist/templates/brief.md +49 -49
  302. package/dist/templates/changelog.md +8 -12
  303. package/dist/templates/closure.md +28 -28
  304. package/dist/templates/driver-create.md +116 -0
  305. package/dist/templates/driver-delete.md +84 -0
  306. package/dist/templates/driver-refactor.md +94 -0
  307. package/dist/templates/index.md +14 -11
  308. package/dist/templates/init.md +0 -12
  309. package/dist/templates/module-create.md +117 -0
  310. package/dist/templates/module-delete.md +79 -0
  311. package/dist/templates/module-refactor.md +87 -0
  312. package/dist/templates/planning.md +76 -78
  313. package/dist/templates/research.md +44 -56
  314. package/dist/templates/results-acceptance.md +94 -106
  315. package/dist/templates/review.md +61 -62
  316. package/dist/templates/subtask-implementation.md +30 -35
  317. package/dist/templates/supplemental-report.md +8 -12
  318. package/dist/templates/task-metrics.md +14 -15
  319. package/dist/templates/task.md +15 -19
  320. package/dist/templates/todo-item.md +23 -27
  321. package/dist/templates/verification.md +33 -33
  322. package/dist/todo/001-anadir-seccion-reasoning.md +42 -0
  323. package/dist/todo/002-anadir-ejemplos-few-shot.md +46 -0
  324. package/dist/todo/003-explorar-paralelizacion-phase4.md +46 -0
  325. package/dist/todo/004-portable-agentic-system.md +44 -0
  326. package/dist/todo/README.md +58 -0
  327. package/dist/todo/index.md +27 -0
  328. package/dist/tools/extensio-cli.md +76 -0
  329. package/dist/tools/index.md +14 -0
  330. package/dist/tools/run-command.md +42 -0
  331. package/dist/workflows/drivers/create.md +139 -0
  332. package/dist/workflows/drivers/delete.md +124 -0
  333. package/dist/workflows/drivers/index.md +25 -0
  334. package/dist/workflows/drivers/refactor.md +125 -0
  335. package/dist/workflows/index.md +17 -29
  336. package/dist/workflows/init.md +36 -36
  337. package/dist/workflows/modules/create.md +160 -0
  338. package/dist/workflows/modules/delete.md +121 -0
  339. package/dist/workflows/modules/index.md +27 -0
  340. package/dist/workflows/modules/pages.create.md +234 -0
  341. package/dist/workflows/modules/refactor.md +122 -0
  342. package/dist/workflows/modules/shards.create.md +215 -0
  343. package/dist/workflows/tasklifecycle-long/index.md +86 -90
  344. package/dist/workflows/tasklifecycle-long/phase-0-acceptance-criteria.md +130 -118
  345. package/dist/workflows/tasklifecycle-long/phase-1-research.md +104 -105
  346. package/dist/workflows/tasklifecycle-long/phase-2-analysis.md +120 -97
  347. package/dist/workflows/tasklifecycle-long/phase-3-planning.md +136 -75
  348. package/dist/workflows/tasklifecycle-long/phase-4-implementation.md +163 -73
  349. package/dist/workflows/tasklifecycle-long/phase-5-verification.md +136 -45
  350. package/dist/workflows/tasklifecycle-long/phase-6-results-acceptance.md +106 -46
  351. package/dist/workflows/tasklifecycle-long/phase-7-evaluation.md +96 -51
  352. package/dist/workflows/tasklifecycle-long/phase-8-commit-push.md +108 -51
  353. package/dist/workflows/tasklifecycle-short/index.md +30 -27
  354. package/dist/workflows/tasklifecycle-short/short-phase-1-brief.md +80 -39
  355. package/dist/workflows/tasklifecycle-short/short-phase-2-implementation.md +78 -44
  356. package/dist/workflows/tasklifecycle-short/short-phase-3-closure.md +81 -44
  357. package/package.json +3 -3
  358. package/dist/bootstrap.md +0 -591
  359. package/dist/rules/constitution/agent-system.md +0 -77
  360. package/dist/rules/constitution/project-architecture.md +0 -57
@@ -1,4 +1,4 @@
1
- # Clean Code Rules (Agentic System)
1
+ # Clean Code Rules (Extensio)
2
2
 
3
3
  type: rules
4
4
  version: 2
@@ -10,11 +10,12 @@ scope: global
10
10
  ## Purpose
11
11
 
12
12
  This document defines the **mandatory Clean Code rules** for all source code,
13
- agents, and workflows in the Agentic ecosystem.
13
+ agents, workflows, drivers, and modules in the Extensio ecosystem.
14
14
 
15
15
  These rules are inspired by **Robert C. Martin – Clean Code** and adapted to:
16
16
  - TypeScript + ES Modules
17
- - Modular systems
17
+ - Browser extension architecture
18
+ - Reactive, modular systems
18
19
  - Multi-agent workflows
19
20
 
20
21
  Any code that violates these rules MUST be considered incomplete.
@@ -32,14 +33,23 @@ Any code that violates these rules MUST be considered incomplete.
32
33
  - Use **nouns** for variables.
33
34
  - Avoid generic names: `data`, `info`, `tmp`, `value`.
34
35
 
36
+ ❌ `let data;`
37
+ ✅ `let activeTabId;`
38
+
35
39
  ### 1.3 Functions / Methods
36
40
  - Use **verbs** or verb phrases.
37
41
  - Names MUST describe exactly **one responsibility**.
38
42
 
43
+ ❌ `handleStuff()`
44
+ ✅ `persistSessionState()`
45
+
39
46
  ### 1.4 Classes
40
47
  - Use **nouns**.
41
48
  - One clear domain responsibility per class.
42
49
 
50
+ ❌ `Manager`, `Processor`, `Helper`
51
+ ✅ `StorageDriver`, `TabsEngine`
52
+
43
53
  ---
44
54
 
45
55
  ## 2. Functions & Methods (Small and Focused)
@@ -56,6 +66,9 @@ If it exceeds this, it MUST be split.
56
66
  - Prefer **objects** over multiple parameters.
57
67
  - Avoid boolean flags (they hide responsibility branches).
58
68
 
69
+ ❌ `loadTab(id, true)`
70
+ ✅ `loadTab({ id, forceReload })`
71
+
59
72
  ---
60
73
 
61
74
  ## 3. Single Responsibility Principle (Strict)
@@ -63,6 +76,11 @@ If it exceeds this, it MUST be split.
63
76
  - Every function, class, and file MUST have **one reason to change**.
64
77
  - Mixing concerns is forbidden.
65
78
 
79
+ Examples of forbidden mixes:
80
+ - UI logic + storage logic
81
+ - Browser API calls + business rules
82
+ - Validation + mutation
83
+
66
84
  ---
67
85
 
68
86
  ## 4. Comments (Last Resort)
@@ -85,6 +103,19 @@ If a comment is needed to explain *what*, the code is wrong.
85
103
  - Do NOT silently ignore errors.
86
104
  - Do NOT use generic `catch (e) {}` blocks.
87
105
 
106
+
107
+ ```ts
108
+ try { doSomething(); } catch {}
109
+ ```
110
+
111
+
112
+ ```ts
113
+ try { doSomething(); }
114
+ catch (error) {
115
+ throw new StorageInitializationError(error);
116
+ }
117
+ ```
118
+
88
119
  ---
89
120
 
90
121
  ## 6. Formatting & Structure
@@ -95,13 +126,13 @@ If a comment is needed to explain *what*, the code is wrong.
95
126
 
96
127
  ### 6.2 Class Member Order (MANDATORY)
97
128
 
98
- 1. Static properties
99
- 2. Static methods
100
- 3. Instance properties
101
- 4. Constructor
102
- 5. Event handlers / listeners
103
- 6. Private methods
104
- 7. Public methods
129
+ 1. Static properties
130
+ 2. Static methods
131
+ 3. Instance properties
132
+ 4. constructor
133
+ 5. Event handlers / listeners
134
+ 6. Private methods
135
+ 7. Public methods
105
136
 
106
137
  Any deviation is a violation.
107
138
 
@@ -113,9 +144,28 @@ Any deviation is a violation.
113
144
  - File name MUST match the main exported concept.
114
145
  - Avoid “utils” files unless the domain is explicit.
115
146
 
147
+ ❌ `utils.ts`
148
+ ✅ `tab-url-normalizer.ts`
149
+
116
150
  ---
117
151
 
118
- ## 8. Duplication & Abstraction
152
+ ## 8. Drivers (Extensio-Specific)
153
+
154
+ - Drivers MUST be thin facades.
155
+ - NO business logic inside drivers.
156
+ - Browser-specific adaptations ONLY.
157
+
158
+ ---
159
+
160
+ ## 9. Modules (Extensio-Specific)
161
+
162
+ - Modules MUST be domain-focused.
163
+ - Modules MUST communicate ONLY through reactive storage or defined APIs.
164
+ - No direct cross-module imports unless explicitly allowed.
165
+
166
+ ---
167
+
168
+ ## 10. Duplication & Abstraction
119
169
 
120
170
  - Duplication is preferred over **wrong abstraction**.
121
171
  - Abstract ONLY when at least **two concrete implementations exist**.
@@ -124,7 +174,7 @@ Any deviation is a violation.
124
174
 
125
175
  ---
126
176
 
127
- ## 9. Tests & Verifiability (Conceptual)
177
+ ## 11. Tests & Verifiability (Conceptual)
128
178
 
129
179
  - Code MUST be verifiable in isolation.
130
180
  - Hidden side effects are forbidden.
@@ -132,7 +182,7 @@ Any deviation is a violation.
132
182
 
133
183
  ---
134
184
 
135
- ## 10. Clean Code Gate
185
+ ## 12. Clean Code Gate
136
186
 
137
187
  Any agent, workflow, or human contributor MUST ensure:
138
188
 
@@ -150,4 +200,6 @@ Inspired by:
150
200
  - Robert C. Martin – *Clean Code*
151
201
  - Robert C. Martin – *Clean Architecture*
152
202
 
203
+ Adapted for Extensio.
204
+
153
205
  This rule set is **binding** when referenced as `INJECTED`.
@@ -0,0 +1,294 @@
1
+ ---
2
+ trigger: model_decision
3
+ description: Se aplica cuando se crean, modifican o auditan drivers, o cuando un agente toma decisiones sobre ellos, garantizando estructura contractual, aislamiento, compatibilidad multi-browser y ausencia de lógica de negocio
4
+ ---
5
+
6
+ ---
7
+ id: constitution.drivers
8
+ type: rule
9
+ owner: architect-agent
10
+ version: 1.0.0
11
+ severity: PERMANENT
12
+ scope: global
13
+ ---
14
+
15
+ # CONSTITUTION: Drivers (Extensio)
16
+
17
+ ## Objetivo
18
+ Este documento define **reglas obligatorias** y contractuales para los drivers de Extensio.
19
+ Todo driver **DEBE** cumplir estas reglas.
20
+ El `role.driver-agent` **DEBE** auditar y hacer cumplir este contrato.
21
+
22
+ ---
23
+
24
+ ## 1. Definición (qué es un driver)
25
+ Un driver es una **fachada** (facade) que abstrae APIs del navegador (WebExtensions) o Web APIs
26
+ para que el resto del framework sea **browser-agnóstico**.
27
+
28
+ Un driver:
29
+ - adapta APIs (shape, compat, eventos, tipos)
30
+ - expone una API estable y documentada
31
+ - encapsula diferencias entre navegadores
32
+
33
+ Un driver:
34
+ - NO contiene lógica de negocio
35
+ - NO conoce módulos de negocio
36
+ - NO decide flujos o workflows
37
+ - NO persiste estado de negocio (solo adapta storage si es driver de storage)
38
+
39
+ ---
40
+
41
+ ## 2. Estructura obligatoria por driver
42
+ Cada driver **DEBE** seguir esta estructura mínima:
43
+
44
+ - `src/index.mts` → **wrapper público** (API estable + JSDoc)
45
+ - `src/__BROWSER__/index.mts` → implementación por navegador (chrome/firefox/safari)
46
+ - `src/types.d.mts` → tipos locales del driver
47
+ - `src/constants.mts` → constantes tipadas (`Record<string, string>`)
48
+ - `src/common/index.mts` → implementación compartida (si aplica)
49
+ - Integración de tipos en `globals.d.mts` (root) y de constantes en `constants.mts` (root)
50
+ como parte obligatoria de la estructura del driver.
51
+
52
+ ### 2.1 Wrapper (src/index.mts)
53
+ Reglas:
54
+ - `src/index.mts` **NO puede** ser un simple re-export.
55
+ - Debe exponer una clase o funciones wrapper que:
56
+ - deleguen en la implementación específica (`__BROWSER__`)
57
+ - añadan JSDoc
58
+ - mantengan API estable
59
+ - Debe importar `__BROWSER__/index.mts` usando el patrón del build (ej. `__BROWSER__`).
60
+
61
+ ### 2.2 Implementación por navegador (src/__BROWSER__/index.mts)
62
+ Reglas:
63
+ - Debe mapear a las APIs reales del navegador.
64
+ - Debe mantener el contrato de tipos definido por `types.d.mts`.
65
+ - Debe aislar diferencias específicas del navegador sin filtrar detalles al wrapper.
66
+
67
+ ### 2.3 Types (src/types.d.mts)
68
+ Reglas:
69
+ - El driver **DEBE** definir sus tipos localmente.
70
+ - Import interno de tipos del mismo driver:
71
+ - `import type { X } from '../types.d.mts'`
72
+ - Los drivers **NO** consumen tipos de otros drivers:
73
+ - cada driver define sus propios tipos para mantener independencia y portabilidad
74
+ - Interfaces genéricas comunes (p.ej. `BrowserEvent`) **se duplican** localmente
75
+ para evitar dependencias cruzadas indeseadas.
76
+ - La integracion de tipos **DEBE** reflejarse correctamente en `globals.d.mts`
77
+ (imports/exports sin duplicados ni nombres corruptos).
78
+ - Todo driver **DEBE** registrar sus tipos en `globals.d.mts` dentro del
79
+ namespace global `Extensio.<NamespaceDelDriver>`.
80
+
81
+ Ejemplo (globals.d.mts):
82
+ ```ts
83
+ declare global {
84
+ namespace Extensio {
85
+ namespace Tabs {
86
+ type TabStatusType = typeof TabStatus[keyof typeof TabStatus];
87
+ }
88
+ }
89
+ }
90
+ ```
91
+
92
+ ### 2.4 Constants (src/constants.mts)
93
+ Reglas:
94
+ - Todo string repetido o enumeración string-based debe centralizarse aquí.
95
+ - Toda enumeración **DEBE** definirse en `constants.mts` y usarse para crear tipos.
96
+ - Objetivo: reutilizar los valores como objetos en runtime y como tipos en compile-time.
97
+ - Debe tiparse como `Record<string, string>`.
98
+ - Los drivers **NO** consumen constantes de otros drivers:
99
+ - cada driver define sus propias constantes para mantener independencia y portabilidad
100
+ - Las constantes del driver **DEBEN** extender las constantes globales del proyecto
101
+ para que puedan ser usadas por los módulos.
102
+ - La integracion de constantes **DEBE** reflejarse correctamente en el `constants.mts`
103
+ del root (exports sin duplicados ni nombres corruptos).
104
+ - Todo driver **DEBE** exportar sus constantes en el `constants.mts` del root.
105
+
106
+ Ejemplo (constants.mts root):
107
+ ```ts
108
+ export { TabStatus, WindowType } from '@extensio/driver-tabs/src/constants.mts';
109
+ ```
110
+ - Prohibido hardcodear “magic strings” repetidos en el código del driver.
111
+
112
+ ### 2.5 Common (src/common/index.mts)
113
+ Reglas:
114
+ - Solo si existe lógica compartible entre navegadores.
115
+ - No debe incluir lógica de negocio.
116
+ - Debe ser consumida por los `__BROWSER__/index.mts`, no por módulos.
117
+
118
+ ### 2.6 Demo (demo/)
119
+ Reglas:
120
+ - Si un driver tiene carpeta `demo`, cualquier import hacia `src` **DEBE** usar
121
+ el alias `__PARENT_SRC__` (nunca rutas relativas al `src`).
122
+ - Ejemplo: `import { Tabs } from '__PARENT_SRC__/index.mts';`
123
+ - La demo **DEBE** mantener la estructura de Extensio y cumplir `constitution.extensio_architecture`.
124
+ - La demo **DEBE** generarse con `mcp_extensio-cli tools` cuando exista soporte aplicable.
125
+
126
+ ---
127
+
128
+ ## 3. Events (contrato obligatorio)
129
+ Los eventos **DEBEN** exponerse como wrappers que implementen una interfaz local `BrowserEvent`.
130
+
131
+ Ejemplo de forma:
132
+ - En `types.d.mts`:
133
+ - `export interface BrowserEvent<T extends (...args: any) => void> { addListener(cb: T): void; removeListener(cb: T): void; hasListener(cb: T): boolean; }`
134
+ - En `src/__BROWSER__/index.mts`:
135
+ - `static onCreated: BrowserEvent<(arg: X) => void> = { addListener: ..., removeListener: ..., hasListener: ... }`
136
+
137
+ Regla:
138
+ - Prohibido exponer directamente eventos crudos del navegador (ej. `chrome.tabs.onUpdated`).
139
+
140
+ ---
141
+
142
+ ## 4. Scoping y dependencias (aislamiento)
143
+ - Un driver no debe depender de otro driver por imports directos.
144
+ - Si necesita tipos externos, usar `Extension.*`.
145
+ - Un driver **NUNCA** debe usar otro driver; deben ser agnósticos e independientes.
146
+ - Los drivers **DEBEN** definir sus propios tipos; **NO** deben usar `@types` de otras librerías.
147
+ - Si necesita interactuar con otros drivers, hacerlo a través del dominio superior (módulo/core),
148
+ nunca creando dependencia de paquete circular.
149
+
150
+ ---
151
+
152
+ ## 5. Clean Code (en drivers)
153
+ - Se aplica `clean-code.md` como contrato obligatorio para drivers.
154
+
155
+ ---
156
+
157
+ ## 6. Compatibilidad multi-browser
158
+ - La API del wrapper debe ser **estable** entre navegadores.
159
+ - Las divergencias deben resolverse en `__BROWSER__`.
160
+ - Si una API no existe en un navegador:
161
+ - se define comportamiento fallback (documentado)
162
+ - o se lanza error controlado (documentado)
163
+ - Debe evitarse divergencia silenciosa.
164
+
165
+ ---
166
+
167
+ ## 7. Tooling recomendado (scaffolding)
168
+ Cuando exista comando disponible, los drivers **DEBEN** generarse con `mcp_extensio-cli tools`.
169
+
170
+ Principio:
171
+ - Preferir generación por CLI para consistencia.
172
+ - Si el CLI no soporta una operación, la modificación manual es válida solo si:
173
+ - cumple este contrato
174
+ - queda registrada como “lección aprendida” por el `driver-agent`.
175
+
176
+ ---
177
+
178
+ ## 8. Auditoría de cumplimiento
179
+ Criterios mínimos de auditoría:
180
+ - estructura de carpetas correcta (Sección 2)
181
+ - wrapper no es re-export (2.1)
182
+ - types aislados (2.3)
183
+ - events como wrappers (3)
184
+ - constants centralizadas (2.4)
185
+ - no lógica de negocio (1)
186
+ - compatibilidad documentada (6)
187
+
188
+ ---
189
+
190
+ ## 9. Severidad
191
+ Cualquier violación de:
192
+ - estructura (Sección 2)
193
+ - types isolation (2.3)
194
+ - events wrappers (3)
195
+ - lógica de negocio en drivers (1)
196
+
197
+ se considera **SEVERITY: HIGH** y debe corregirse antes de integrar cambios.
198
+
199
+ ---
200
+
201
+ ## 10. Ejemplos (drivers reales)
202
+ Los ejemplos respetan la independencia entre drivers: no hay consumo de tipos ni
203
+ constantes de otros drivers dentro de un driver.
204
+
205
+ ### 10.1 Enumeraciones en `constants.mts` (Tabs driver)
206
+ Fuente: `packages/drivers/tabs/src/constants.mts`
207
+ ```ts
208
+ export const TabStatus: Record<string, string> = {
209
+ Loading: 'loading',
210
+ Complete: 'complete',
211
+ };
212
+
213
+ export const WindowType: Record<string, string> = {
214
+ Normal: 'normal',
215
+ Popup: 'popup',
216
+ Panel: 'panel',
217
+ App: 'app',
218
+ Devtools: 'devtools',
219
+ };
220
+ ```
221
+
222
+ ### 10.2 Tipos derivados de constantes (Tabs driver)
223
+ Fuente: `packages/drivers/tabs/src/types.d.mts`
224
+ ```ts
225
+ import { TabStatus, WindowType } from './constants.mts';
226
+
227
+ export type TabStatusType = typeof TabStatus[keyof typeof TabStatus];
228
+ export type WindowTypeType = typeof WindowType[keyof typeof WindowType];
229
+ ```
230
+
231
+ ### 10.3 Re-export de constantes (Tabs driver)
232
+ Fuente: `packages/drivers/tabs/src/types.d.mts`
233
+ ```ts
234
+ export { TabStatus, WindowType };
235
+ ```
236
+
237
+ ---
238
+
239
+ ### 10.4 Clase wrapper en `src/index.mts` (Tabs driver)
240
+ Fuente: `packages/drivers/tabs/src/index.mts`
241
+ ```ts
242
+ import { Tabs as CommonTabs } from '__BROWSER__/index.mts';
243
+ import type { Tab, BrowserEvent } from './types.d.mts';
244
+
245
+ export class Tabs extends CommonTabs {
246
+ static override get(tabId: number): Promise<Tab> {
247
+ return CommonTabs.get(tabId);
248
+ }
249
+
250
+ static override onCreated: BrowserEvent<(tab: Tab) => void> = {
251
+ addListener: (cb) => CommonTabs.onCreated.addListener(cb),
252
+ removeListener: (cb) => CommonTabs.onCreated.removeListener(cb),
253
+ hasListener: (cb) => CommonTabs.onCreated.hasListener(cb),
254
+ };
255
+ }
256
+ ```
257
+
258
+ ---
259
+
260
+ ### 10.5 Consumo desde Core/Modules (Navigation)
261
+ Fuente: `packages/core/src/engine/navigation/index.mts`
262
+ ```ts
263
+ import { Tabs } from '@extensio/driver-tabs';
264
+ import { Windows } from '@extensio/driver-windows';
265
+
266
+ await Tabs.create({ url, active: true });
267
+ await Windows.create({ url, type: 'popup', focused: true });
268
+ ```
269
+
270
+ ---
271
+
272
+ ### 10.6 Demo usando `__PARENT_SRC__`
273
+ Ejemplo (alias definido en `tsconfig.json` de drivers):
274
+ ```ts
275
+ import { Tabs } from '__PARENT_SRC__/index.mts';
276
+ ```
277
+
278
+ ---
279
+
280
+ ### 10.7 Extensión de globals (Prompt AI driver)
281
+ Fuente: `packages/drivers/prompt-ai/src/types.d.mts`
282
+ ```ts
283
+ declare global {
284
+ interface WindowOrWorkerGlobalScope {
285
+ ai?: {
286
+ languageModel: AILanguageModelFactory;
287
+ };
288
+ }
289
+ }
290
+ ```
291
+
292
+ ---
293
+
294
+ Fin de la constitución de drivers.
@@ -0,0 +1,131 @@
1
+ ---
2
+ trigger: always_on
3
+ ---
4
+
5
+ # EXTENSIO ARCHITECTURE - FRAMEWORK RULES
6
+
7
+ Este documento define los **principios arquitectónicos fundamentales** del framework Extensio.
8
+ Para reglas contractuales detalladas de cada componente, consultar su constitución específica.
9
+
10
+ ---
11
+
12
+ ## 1. PRINCIPIOS ARQUITECTÓNICOS (PERMANENT)
13
+
14
+ ### 1.1 Filosofía Base
15
+ Extensio es un framework para construir extensiones de navegador complejas
16
+ de forma modular, reactiva y predecible.
17
+
18
+ Su filosofía se basa en los siguientes principios:
19
+
20
+ - Separar estrictamente la lógica de negocio de las APIs del navegador (Drivers) y de la UI (Surfaces).
21
+ - Aislar cada dominio funcional en paquetes independientes del monorepo, sin dependencias cruzadas.
22
+ - Utilizar un modelo reactivo como único mecanismo de comunicación entre los módulos.
23
+ - Priorizar la predecibilidad del comportamiento frente a la flexibilidad implícita.
24
+ - Diseñar el sistema para escalar en complejidad sin degradar mantenibilidad.
25
+ - Mantener el código agnóstico del navegador y del entorno de ejecución.
26
+
27
+ ### 1.2 Independencia y Dirección de Dependencias
28
+ - Todos los paquetes DEBEN ser independientes y versionables.
29
+ - El acoplamiento directo entre paquetes del mismo tipo está PROHIBIDO.
30
+ - El uso de capacidades externas DEBE realizarse exclusivamente mediante Drivers.
31
+ - Core NO DEBE conocer ni depender de ningún paquete del proyecto.
32
+
33
+ ### 1.3 Prohibición de Dependencias Cruzadas
34
+ - Un módulo NO DEBE depender de otro módulo.
35
+ - Un driver NO DEBE depender de otro driver.
36
+ - El uso de drivers por parte de los módulos NO constituye una dependencia conceptual.
37
+ - Ningún paquete DEBE introducir ciclos de dependencias, directos o indirectos.
38
+
39
+ ### 1.4 Separación de Responsabilidades
40
+ - El principio SRP (Single Responsibility Principle) DEBE aplicarse estrictamente.
41
+ - Está PROHIBIDO mezclar UI con lógica de negocio dentro de módulos.
42
+ - Los drivers NO DEBEN contener lógica de negocio.
43
+ - Los bucles reactivos están PROHIBIDOS.
44
+
45
+ ---
46
+
47
+ ## 2. SCOPES DEL FRAMEWORK (PERMANENT)
48
+
49
+ El framework define tres scopes principales. Cada uno tiene su propia constitución con reglas detalladas.
50
+
51
+ ### 2.1 Engine
52
+ - El Engine es el componente central y obligatorio de todo módulo.
53
+ - Se ejecuta en el entorno de Service Worker.
54
+ - Es responsable del estado reactivo y persistente del módulo.
55
+ - **NO DEBE** renderizar UI ni acceder al DOM.
56
+ - **Constitución detallada**: `constitution.modules`
57
+
58
+ ### 2.2 Context
59
+ - Un Context es una extensión opcional del Engine.
60
+ - Encapsula lógica que requiere acceso al DOM o APIs no disponibles en el Service Worker.
61
+ - El Engine controla completamente el ciclo de vida del Context.
62
+ - **NO DEBE** contener lógica de negocio ni renderizar UI.
63
+ - **Constitución detallada**: `constitution.modules`
64
+
65
+ ### 2.3 Surfaces
66
+ Las Surfaces representan la capa visual del framework. Se dividen en:
67
+
68
+ #### Pages
69
+ - Documentos completos que se renderizan en un tab del navegador.
70
+ - Representan vistas de alto nivel (opciones, dashboards).
71
+ - **Constitución detallada**: `constitution.pages`
72
+
73
+ #### Shards
74
+ - Componentes visuales reutilizables (WebComponents).
75
+ - Componentes de UI puros, sin estado persistente propio.
76
+ - **Constitución detallada**: `constitution.shards`
77
+
78
+ ---
79
+
80
+ ## 3. DRIVERS (PERMANENT)
81
+
82
+ Los Drivers son adaptadores que envuelven APIs del navegador.
83
+ Representan la frontera de efectos laterales del sistema.
84
+
85
+ **Constitución detallada**: `constitution.drivers`
86
+
87
+ ---
88
+
89
+ ## 4. CORE PACKAGE (PERMANENT)
90
+
91
+ - Core DEBE exponer Engine, Context y Surfaces.
92
+ - Core DEBE proveer el sistema reactivo (@property, @onChanged).
93
+ - Core NO DEBE depender de ningún paquete del proyecto.
94
+ - Core NO DEBE contener lógica de negocio de ningún módulo.
95
+
96
+ ---
97
+
98
+ ## 5. EXTENSIO CLI (PERMANENT)
99
+
100
+ El tool `mcp_extensio-cli` es el ÚNICO punto de entrada para build y test.
101
+ - Unit e Integration **DEBEN** ejecutarse con **Vitest**.
102
+ - E2E **DEBE** ejecutarse con **Playwright**.
103
+ - Scaffolding de módulos, drivers y surfaces **DEBE** usar `mcp_extensio-cli`.
104
+
105
+ ---
106
+
107
+ ## 6. ORDEN DE COMPOSICIÓN DE CLASES (PERMANENT)
108
+
109
+ 1. Propiedades estáticas
110
+ 2. Métodos estáticos
111
+ 3. Propiedades de instancia
112
+ 4. Constructor
113
+ 5. Event handlers
114
+ 6. Métodos privados
115
+ 7. Métodos públicos
116
+
117
+ ---
118
+
119
+ ## 7. CONSTITUCIONES ESPECÍFICAS
120
+
121
+ Para reglas contractuales detalladas, consultar:
122
+
123
+ | Componente | Constitución |
124
+ |------------|--------------|
125
+ | Módulos | `constitution.modules` |
126
+ | Drivers | `constitution.drivers` |
127
+ | Pages | `constitution.pages` |
128
+ | Shards | `constitution.shards` |
129
+ | Clean Code | `constitution.clean_code` |
130
+
131
+ ---
@@ -1,29 +1,31 @@
1
1
  ---
2
2
  id: rules.constitution.index
3
3
  owner: architect-agent
4
- version: 1.0.0
4
+ version: 2.0.0
5
5
  severity: PERMANENT
6
- scope: global
6
+ trigger: always_on
7
7
  ---
8
8
 
9
- # INDEX — Constitution
9
+ # INDEX — Rules / Constitution
10
10
 
11
- ## Agent identification (MANDATORY)
12
- First line of the document:
13
- `<icon> **<agent-name>**: <message>`
14
-
15
- ## Objective
16
- List constitution rules and their paths.
11
+ ## Objetivo
12
+ Este fichero enumera todas las rules del dominio `constitution`.
13
+ Los workflows y agentes **DEBEN** referenciar estas reglas
14
+ por alias en lugar de rutas directas.
17
15
 
18
16
  ## Aliases (YAML)
19
17
  ```yaml
20
18
  constitution:
21
- agent_system: .agent/rules/constitution/agent-system.md
22
19
  GEMINI_location: .agent/rules/constitution/GEMINI.location.md
23
- project_architecture: .agent/rules/constitution/project-architecture.md
20
+ extensio_architecture: .agent/rules/constitution/extensio-architecture.md
24
21
  clean_code: .agent/rules/constitution/clean-code.md
22
+ drivers: .agent/rules/constitution/drivers.md
23
+ modules: .agent/rules/constitution/modules.md
24
+ shards: .agent/rules/constitution/shards.md
25
+ pages: .agent/rules/constitution/pages.md
25
26
  agents_behavior: .agent/rules/constitution/agents-behavior.md
26
27
  ```
27
28
 
28
- ## Rules
29
- - Any new constitution MUST be added here.
29
+ ## Reglas
30
+ - Este índice **solo** declara reglas del dominio `constitution`.
31
+ - Cualquier nueva regla del dominio **DEBE** añadirse aquí.