@bonesofspring/ai-rules 0.2.31 → 0.2.33

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 (1278) hide show
  1. package/CHANGELOG.md +42 -0
  2. package/README.md +1 -1
  3. package/docs/LOCAL-OVERLAY.md +30 -1
  4. package/docs/PRESET-CONTRIBUTION.md +13 -4
  5. package/docs/PRESET-ENGLISH-STYLE.md +23 -1
  6. package/package.json +2 -1
  7. package/presets/_shared/README.md +10 -4
  8. package/presets/_shared/core/agent-team/agent-artifact-contracts.md +39 -0
  9. package/presets/_shared/core/agent-team/agent-team-intake.md +3 -0
  10. package/presets/_shared/core/agent-team/agent-team-orchestrator.md +22 -2
  11. package/presets/_shared/core/agent-team/language-policy.md +41 -0
  12. package/presets/_shared/core/agent-team/plan-graph.md +35 -0
  13. package/presets/_shared/core/agent-team/task-classification.md +2 -0
  14. package/presets/_shared/core/agent-team/task-framing.md +45 -0
  15. package/presets/_shared/core/architecture/feature-delivery-workflow.md +11 -1
  16. package/presets/_shared/core/meta/preset-goals.md +29 -0
  17. package/presets/_shared/core/meta/preset-layering.md +1 -1
  18. package/presets/_shared/core/meta/preset-pr-checklist.md +4 -0
  19. package/presets/_shared/core/meta/preset-twin-sync.md +19 -77
  20. package/presets/_shared/core/meta/preset-writing-style.md +40 -0
  21. package/presets/_shared/core/quality/code-quality-and-refactoring.md +20 -1
  22. package/presets/_shared/core/quality/context-and-iteration.md +29 -0
  23. package/presets/_shared/core/quality/self-review-and-context-hygiene.md +51 -0
  24. package/presets/_shared/core/quality/verification-before-completion.md +4 -0
  25. package/presets/_shared/core/review/mockup-review.md +56 -1
  26. package/presets/claude/android-kotlin/REPO_AGENTS.md +3 -0
  27. package/presets/claude/android-kotlin/agents/README.md +6 -0
  28. package/presets/claude/android-kotlin/agents/build-verifier.md +12 -0
  29. package/presets/claude/android-kotlin/agents/code-reviewer.md +12 -0
  30. package/presets/claude/android-kotlin/agents/debugger.md +12 -0
  31. package/presets/claude/android-kotlin/agents/feature-developer.md +12 -0
  32. package/presets/claude/android-kotlin/agents/task-analyst.md +30 -0
  33. package/presets/claude/android-kotlin/agents/task-router.md +8 -0
  34. package/presets/claude/android-kotlin/ai-local/conventions.md +8 -0
  35. package/presets/claude/android-kotlin/commands/task-continue.md +8 -0
  36. package/presets/claude/android-kotlin/commands/task.md +14 -1
  37. package/presets/claude/android-kotlin/rules/README.md +5 -0
  38. package/presets/claude/android-kotlin/rules/architecture/feature-delivery.md +4 -0
  39. package/presets/claude/android-kotlin/rules/stack/android-app-core.md +6 -0
  40. package/presets/claude/android-kotlin/rules/tooling-and-review/agent-team-intake.md +3 -0
  41. package/presets/claude/android-kotlin/rules/tooling-and-review/agent-team-orchestrator.md +33 -4
  42. package/presets/claude/android-kotlin/rules/tooling-and-review/ai-local-overlay.md +4 -0
  43. package/presets/claude/android-kotlin/rules/tooling-and-review/code-quality.md +20 -1
  44. package/presets/claude/android-kotlin/rules/tooling-and-review/language-policy.md +52 -0
  45. package/presets/claude/android-kotlin/rules/tooling-and-review/mockup-review.md +56 -1
  46. package/presets/claude/android-kotlin/rules/tooling-and-review/preset-goals.md +40 -0
  47. package/presets/claude/android-kotlin/rules/tooling-and-review/preset-layering.md +1 -1
  48. package/presets/claude/android-kotlin/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  49. package/presets/claude/android-kotlin/rules/tooling-and-review/preset-twin-sync.md +19 -77
  50. package/presets/claude/android-kotlin/rules/tooling-and-review/preset-writing-style.md +51 -0
  51. package/presets/claude/android-kotlin/team/README.md +17 -0
  52. package/presets/claude/go/REPO_AGENTS.md +3 -0
  53. package/presets/claude/go/agents/README.md +6 -0
  54. package/presets/claude/go/agents/build-verifier.md +12 -0
  55. package/presets/claude/go/agents/code-reviewer.md +12 -0
  56. package/presets/claude/go/agents/debugger.md +12 -0
  57. package/presets/claude/go/agents/feature-developer.md +12 -0
  58. package/presets/claude/go/agents/task-analyst.md +30 -0
  59. package/presets/claude/go/agents/task-router.md +8 -0
  60. package/presets/claude/go/ai-local/conventions.md +8 -0
  61. package/presets/claude/go/commands/task-continue.md +8 -0
  62. package/presets/claude/go/commands/task.md +14 -1
  63. package/presets/claude/go/rules/README.md +5 -0
  64. package/presets/claude/go/rules/architecture/feature-delivery.md +4 -0
  65. package/presets/claude/go/rules/stack/go-app-core.md +6 -0
  66. package/presets/claude/go/rules/tooling-and-review/README.md +1 -0
  67. package/presets/claude/go/rules/tooling-and-review/agent-team-intake.md +3 -0
  68. package/presets/claude/go/rules/tooling-and-review/agent-team-orchestrator.md +32 -3
  69. package/presets/claude/go/rules/tooling-and-review/ai-local-overlay.md +4 -0
  70. package/presets/claude/go/rules/tooling-and-review/code-quality.md +20 -1
  71. package/presets/claude/go/rules/tooling-and-review/language-policy.md +52 -0
  72. package/presets/claude/go/rules/tooling-and-review/preset-goals.md +40 -0
  73. package/presets/claude/go/rules/tooling-and-review/preset-layering.md +1 -1
  74. package/presets/claude/go/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  75. package/presets/claude/go/rules/tooling-and-review/preset-twin-sync.md +19 -77
  76. package/presets/claude/go/rules/tooling-and-review/preset-writing-style.md +51 -0
  77. package/presets/claude/go/team/README.md +17 -0
  78. package/presets/claude/ios-swift/REPO_AGENTS.md +3 -0
  79. package/presets/claude/ios-swift/agents/README.md +6 -0
  80. package/presets/claude/ios-swift/agents/build-verifier.md +12 -0
  81. package/presets/claude/ios-swift/agents/code-reviewer.md +12 -0
  82. package/presets/claude/ios-swift/agents/debugger.md +12 -0
  83. package/presets/claude/ios-swift/agents/feature-developer.md +12 -0
  84. package/presets/claude/ios-swift/agents/task-analyst.md +30 -0
  85. package/presets/claude/ios-swift/agents/task-router.md +8 -0
  86. package/presets/claude/ios-swift/ai-local/conventions.md +8 -0
  87. package/presets/claude/ios-swift/commands/task-continue.md +8 -0
  88. package/presets/claude/ios-swift/commands/task.md +14 -1
  89. package/presets/claude/ios-swift/rules/README.md +4 -0
  90. package/presets/claude/ios-swift/rules/architecture/feature-delivery.md +4 -0
  91. package/presets/claude/ios-swift/rules/stack/ios-app-core.md +6 -0
  92. package/presets/claude/ios-swift/rules/tooling-and-review/agent-team-intake.md +3 -0
  93. package/presets/claude/ios-swift/rules/tooling-and-review/agent-team-orchestrator.md +33 -4
  94. package/presets/claude/ios-swift/rules/tooling-and-review/ai-local-overlay.md +4 -0
  95. package/presets/claude/ios-swift/rules/tooling-and-review/code-quality.md +20 -1
  96. package/presets/claude/ios-swift/rules/tooling-and-review/language-policy.md +52 -0
  97. package/presets/claude/ios-swift/rules/tooling-and-review/mockup-review.md +56 -1
  98. package/presets/claude/ios-swift/rules/tooling-and-review/preset-goals.md +40 -0
  99. package/presets/claude/ios-swift/rules/tooling-and-review/preset-layering.md +1 -1
  100. package/presets/claude/ios-swift/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  101. package/presets/claude/ios-swift/rules/tooling-and-review/preset-twin-sync.md +19 -77
  102. package/presets/claude/ios-swift/rules/tooling-and-review/preset-writing-style.md +51 -0
  103. package/presets/claude/ios-swift/team/README.md +17 -0
  104. package/presets/claude/java/REPO_AGENTS.md +3 -0
  105. package/presets/claude/java/agents/README.md +6 -0
  106. package/presets/claude/java/agents/build-verifier.md +12 -0
  107. package/presets/claude/java/agents/code-reviewer.md +12 -0
  108. package/presets/claude/java/agents/debugger.md +12 -0
  109. package/presets/claude/java/agents/feature-developer.md +12 -0
  110. package/presets/claude/java/agents/task-analyst.md +30 -0
  111. package/presets/claude/java/agents/task-router.md +8 -0
  112. package/presets/claude/java/ai-local/conventions.md +8 -0
  113. package/presets/claude/java/commands/task-continue.md +8 -0
  114. package/presets/claude/java/commands/task.md +14 -1
  115. package/presets/claude/java/rules/README.md +5 -0
  116. package/presets/claude/java/rules/architecture/feature-delivery.md +4 -0
  117. package/presets/claude/java/rules/stack/java-app-core.md +6 -0
  118. package/presets/claude/java/rules/tooling-and-review/README.md +1 -0
  119. package/presets/claude/java/rules/tooling-and-review/agent-team-intake.md +3 -0
  120. package/presets/claude/java/rules/tooling-and-review/agent-team-orchestrator.md +32 -3
  121. package/presets/claude/java/rules/tooling-and-review/ai-local-overlay.md +4 -0
  122. package/presets/claude/java/rules/tooling-and-review/code-quality.md +20 -1
  123. package/presets/claude/java/rules/tooling-and-review/language-policy.md +52 -0
  124. package/presets/claude/java/rules/tooling-and-review/preset-goals.md +40 -0
  125. package/presets/claude/java/rules/tooling-and-review/preset-layering.md +1 -1
  126. package/presets/claude/java/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  127. package/presets/claude/java/rules/tooling-and-review/preset-twin-sync.md +19 -77
  128. package/presets/claude/java/rules/tooling-and-review/preset-writing-style.md +51 -0
  129. package/presets/claude/java/team/README.md +17 -0
  130. package/presets/claude/mcp-ts/REPO_AGENTS.md +3 -0
  131. package/presets/claude/mcp-ts/agents/README.md +6 -0
  132. package/presets/claude/mcp-ts/agents/build-verifier.md +12 -0
  133. package/presets/claude/mcp-ts/agents/feature-developer.md +12 -0
  134. package/presets/claude/mcp-ts/agents/task-analyst.md +30 -0
  135. package/presets/claude/mcp-ts/agents/task-router.md +8 -0
  136. package/presets/claude/mcp-ts/ai-local/conventions.md +8 -0
  137. package/presets/claude/mcp-ts/commands/task-continue.md +8 -0
  138. package/presets/claude/mcp-ts/commands/task.md +14 -1
  139. package/presets/claude/mcp-ts/rules/README.md +5 -0
  140. package/presets/claude/mcp-ts/rules/architecture/feature-delivery.md +4 -0
  141. package/presets/claude/mcp-ts/rules/stack/mcp-ts-app-core.md +6 -0
  142. package/presets/claude/mcp-ts/rules/tooling-and-review/agent-team-intake.md +3 -0
  143. package/presets/claude/mcp-ts/rules/tooling-and-review/agent-team-orchestrator.md +32 -3
  144. package/presets/claude/mcp-ts/rules/tooling-and-review/ai-local-overlay.md +4 -0
  145. package/presets/claude/mcp-ts/rules/tooling-and-review/code-quality.md +20 -1
  146. package/presets/claude/mcp-ts/rules/tooling-and-review/language-policy.md +52 -0
  147. package/presets/claude/mcp-ts/rules/tooling-and-review/preset-goals.md +40 -0
  148. package/presets/claude/mcp-ts/rules/tooling-and-review/preset-layering.md +1 -1
  149. package/presets/claude/mcp-ts/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  150. package/presets/claude/mcp-ts/rules/tooling-and-review/preset-twin-sync.md +19 -77
  151. package/presets/claude/mcp-ts/rules/tooling-and-review/preset-writing-style.md +51 -0
  152. package/presets/claude/mcp-ts/team/README.md +17 -0
  153. package/presets/claude/next/REPO_AGENTS.md +14 -1
  154. package/presets/claude/next/agents/README.md +6 -0
  155. package/presets/claude/next/agents/build-verifier.md +13 -0
  156. package/presets/claude/next/agents/code-reviewer.md +24 -0
  157. package/presets/claude/next/agents/debugger.md +12 -0
  158. package/presets/claude/next/agents/feature-developer.md +21 -2
  159. package/presets/claude/next/agents/mockup-reviewer.md +25 -4
  160. package/presets/claude/next/agents/openspec-author.md +2 -0
  161. package/presets/claude/next/agents/task-analyst.md +37 -0
  162. package/presets/claude/next/agents/task-router.md +9 -0
  163. package/presets/claude/next/ai-local/conventions.md +8 -0
  164. package/presets/claude/next/commands/task-continue.md +8 -0
  165. package/presets/claude/next/commands/task.md +14 -1
  166. package/presets/claude/next/rules/README.md +7 -0
  167. package/presets/claude/next/rules/anti-hallucination/react-next-anti-hallucination.md +10 -0
  168. package/presets/claude/next/rules/api-and-data/store-rtk.md +6 -0
  169. package/presets/claude/next/rules/architecture/feature-delivery-workflow.md +13 -1
  170. package/presets/claude/next/rules/architecture/product-specs-authoring.md +1 -0
  171. package/presets/claude/next/rules/architecture/product-specs.md +1 -0
  172. package/presets/claude/next/rules/architecture/reference-features.md +5 -0
  173. package/presets/claude/next/rules/stack/next-app-core.md +9 -0
  174. package/presets/claude/next/rules/stack/next-static-export.md +36 -0
  175. package/presets/claude/next/rules/testing/tests-e2e-structure.md +1 -0
  176. package/presets/claude/next/rules/testing/tests-unit.md +1 -0
  177. package/presets/claude/next/rules/tooling-and-review/agent-team-intake.md +3 -0
  178. package/presets/claude/next/rules/tooling-and-review/agent-team-orchestrator.md +33 -4
  179. package/presets/claude/next/rules/tooling-and-review/ai-local-overlay.md +20 -2
  180. package/presets/claude/next/rules/tooling-and-review/code-quality.md +20 -1
  181. package/presets/claude/next/rules/tooling-and-review/code-review-mr.md +14 -0
  182. package/presets/claude/next/rules/tooling-and-review/language-policy.md +52 -0
  183. package/presets/claude/next/rules/tooling-and-review/mcp-usage.md +1 -0
  184. package/presets/claude/next/rules/tooling-and-review/mockup-review.md +77 -1
  185. package/presets/claude/next/rules/tooling-and-review/post-change-lint.md +4 -0
  186. package/presets/claude/next/rules/tooling-and-review/preset-goals.md +40 -0
  187. package/presets/claude/next/rules/tooling-and-review/preset-layering.md +1 -1
  188. package/presets/claude/next/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  189. package/presets/claude/next/rules/tooling-and-review/preset-twin-sync.md +19 -77
  190. package/presets/claude/next/rules/tooling-and-review/preset-writing-style.md +51 -0
  191. package/presets/claude/next/rules/tooling-and-review/security-next.md +13 -0
  192. package/presets/claude/next/rules/ui-and-accessibility/component-catalog-gate.md +39 -0
  193. package/presets/claude/next/rules/ui-and-accessibility/design-tokens-binding.md +24 -2
  194. package/presets/claude/next/rules/ui-and-accessibility/forms-validation.md +35 -0
  195. package/presets/claude/next/rules/ui-and-accessibility/react-ui.md +19 -1
  196. package/presets/claude/next/skills/README.md +1 -0
  197. package/presets/claude/next/skills/code-review/SKILL.md +1 -1
  198. package/presets/claude/next/skills/figma-fidelity/SKILL.md +96 -0
  199. package/presets/claude/next/skills/mockup-review/SKILL.md +5 -1
  200. package/presets/claude/next/team/README.md +18 -0
  201. package/presets/claude/next/team/fixtures/artifact-manifest.example.json +1 -1
  202. package/presets/claude/next/team/fixtures/feature-with-ux-no-figma.json +3 -4
  203. package/presets/claude/nuxt/REPO_AGENTS.md +3 -0
  204. package/presets/claude/nuxt/agents/README.md +6 -0
  205. package/presets/claude/nuxt/agents/build-verifier.md +12 -0
  206. package/presets/claude/nuxt/agents/code-reviewer.md +12 -0
  207. package/presets/claude/nuxt/agents/debugger.md +12 -0
  208. package/presets/claude/nuxt/agents/feature-developer.md +12 -0
  209. package/presets/claude/nuxt/agents/task-analyst.md +30 -0
  210. package/presets/claude/nuxt/agents/task-router.md +8 -0
  211. package/presets/claude/nuxt/ai-local/conventions.md +8 -0
  212. package/presets/claude/nuxt/commands/task-continue.md +8 -0
  213. package/presets/claude/nuxt/commands/task.md +14 -1
  214. package/presets/claude/nuxt/rules/README.md +4 -0
  215. package/presets/claude/nuxt/rules/architecture/feature-delivery-workflow.md +4 -0
  216. package/presets/claude/nuxt/rules/stack/nuxt-app-core.md +6 -0
  217. package/presets/claude/nuxt/rules/tooling-and-review/agent-team-intake.md +3 -0
  218. package/presets/claude/nuxt/rules/tooling-and-review/agent-team-orchestrator.md +33 -4
  219. package/presets/claude/nuxt/rules/tooling-and-review/ai-local-overlay.md +4 -0
  220. package/presets/claude/nuxt/rules/tooling-and-review/code-quality.md +20 -1
  221. package/presets/claude/nuxt/rules/tooling-and-review/language-policy.md +52 -0
  222. package/presets/claude/nuxt/rules/tooling-and-review/mockup-review.md +56 -1
  223. package/presets/claude/nuxt/rules/tooling-and-review/preset-goals.md +40 -0
  224. package/presets/claude/nuxt/rules/tooling-and-review/preset-layering.md +1 -1
  225. package/presets/claude/nuxt/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  226. package/presets/claude/nuxt/rules/tooling-and-review/preset-twin-sync.md +19 -77
  227. package/presets/claude/nuxt/rules/tooling-and-review/preset-writing-style.md +51 -0
  228. package/presets/claude/nuxt/team/README.md +17 -0
  229. package/presets/claude/nuxt/team/fixtures/artifact-manifest.example.json +1 -1
  230. package/presets/claude/php-hexagonal/REPO_AGENTS.md +3 -0
  231. package/presets/claude/php-hexagonal/agents/README.md +6 -0
  232. package/presets/claude/php-hexagonal/agents/build-verifier.md +12 -0
  233. package/presets/claude/php-hexagonal/agents/code-reviewer.md +12 -0
  234. package/presets/claude/php-hexagonal/agents/debugger.md +12 -0
  235. package/presets/claude/php-hexagonal/agents/feature-developer.md +12 -0
  236. package/presets/claude/php-hexagonal/agents/task-analyst.md +30 -0
  237. package/presets/claude/php-hexagonal/agents/task-router.md +8 -0
  238. package/presets/claude/php-hexagonal/ai-local/conventions.md +8 -0
  239. package/presets/claude/php-hexagonal/commands/task-continue.md +8 -0
  240. package/presets/claude/php-hexagonal/commands/task.md +14 -1
  241. package/presets/claude/php-hexagonal/rules/README.md +5 -0
  242. package/presets/claude/php-hexagonal/rules/architecture/feature-delivery.md +4 -0
  243. package/presets/claude/php-hexagonal/rules/stack/php-app-core.md +6 -0
  244. package/presets/claude/php-hexagonal/rules/tooling-and-review/README.md +1 -0
  245. package/presets/claude/php-hexagonal/rules/tooling-and-review/agent-team-intake.md +3 -0
  246. package/presets/claude/php-hexagonal/rules/tooling-and-review/agent-team-orchestrator.md +32 -3
  247. package/presets/claude/php-hexagonal/rules/tooling-and-review/ai-local-overlay.md +4 -0
  248. package/presets/claude/php-hexagonal/rules/tooling-and-review/code-quality.md +20 -1
  249. package/presets/claude/php-hexagonal/rules/tooling-and-review/language-policy.md +52 -0
  250. package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-goals.md +40 -0
  251. package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-layering.md +1 -1
  252. package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  253. package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-twin-sync.md +19 -77
  254. package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-writing-style.md +51 -0
  255. package/presets/claude/php-hexagonal/team/README.md +17 -0
  256. package/presets/claude/php-laravel/REPO_AGENTS.md +3 -0
  257. package/presets/claude/php-laravel/agents/README.md +6 -0
  258. package/presets/claude/php-laravel/agents/build-verifier.md +12 -0
  259. package/presets/claude/php-laravel/agents/code-reviewer.md +12 -0
  260. package/presets/claude/php-laravel/agents/debugger.md +12 -0
  261. package/presets/claude/php-laravel/agents/feature-developer.md +12 -0
  262. package/presets/claude/php-laravel/agents/task-analyst.md +30 -0
  263. package/presets/claude/php-laravel/agents/task-router.md +8 -0
  264. package/presets/claude/php-laravel/ai-local/conventions.md +8 -0
  265. package/presets/claude/php-laravel/commands/task-continue.md +8 -0
  266. package/presets/claude/php-laravel/commands/task.md +14 -1
  267. package/presets/claude/php-laravel/rules/README.md +5 -0
  268. package/presets/claude/php-laravel/rules/architecture/feature-delivery.md +4 -0
  269. package/presets/claude/php-laravel/rules/stack/laravel-app-core.md +6 -0
  270. package/presets/claude/php-laravel/rules/tooling-and-review/agent-team-intake.md +3 -0
  271. package/presets/claude/php-laravel/rules/tooling-and-review/agent-team-orchestrator.md +32 -3
  272. package/presets/claude/php-laravel/rules/tooling-and-review/ai-local-overlay.md +4 -0
  273. package/presets/claude/php-laravel/rules/tooling-and-review/code-quality.md +20 -1
  274. package/presets/claude/php-laravel/rules/tooling-and-review/language-policy.md +52 -0
  275. package/presets/claude/php-laravel/rules/tooling-and-review/preset-goals.md +40 -0
  276. package/presets/claude/php-laravel/rules/tooling-and-review/preset-layering.md +1 -1
  277. package/presets/claude/php-laravel/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  278. package/presets/claude/php-laravel/rules/tooling-and-review/preset-twin-sync.md +19 -77
  279. package/presets/claude/php-laravel/rules/tooling-and-review/preset-writing-style.md +51 -0
  280. package/presets/claude/php-laravel/team/README.md +17 -0
  281. package/presets/claude/svelte/REPO_AGENTS.md +3 -0
  282. package/presets/claude/svelte/agents/README.md +6 -0
  283. package/presets/claude/svelte/agents/build-verifier.md +12 -0
  284. package/presets/claude/svelte/agents/code-reviewer.md +12 -0
  285. package/presets/claude/svelte/agents/debugger.md +12 -0
  286. package/presets/claude/svelte/agents/feature-developer.md +12 -0
  287. package/presets/claude/svelte/agents/task-analyst.md +30 -0
  288. package/presets/claude/svelte/agents/task-router.md +8 -0
  289. package/presets/claude/svelte/ai-local/conventions.md +8 -0
  290. package/presets/claude/svelte/commands/task-continue.md +8 -0
  291. package/presets/claude/svelte/commands/task.md +14 -1
  292. package/presets/claude/svelte/rules/README.md +4 -0
  293. package/presets/claude/svelte/rules/architecture/feature-delivery-workflow.md +4 -0
  294. package/presets/claude/svelte/rules/stack/svelte-app-core.md +6 -0
  295. package/presets/claude/svelte/rules/tooling-and-review/agent-team-intake.md +3 -0
  296. package/presets/claude/svelte/rules/tooling-and-review/agent-team-orchestrator.md +33 -4
  297. package/presets/claude/svelte/rules/tooling-and-review/ai-local-overlay.md +4 -0
  298. package/presets/claude/svelte/rules/tooling-and-review/code-quality.md +20 -1
  299. package/presets/claude/svelte/rules/tooling-and-review/language-policy.md +52 -0
  300. package/presets/claude/svelte/rules/tooling-and-review/mockup-review.md +56 -1
  301. package/presets/claude/svelte/rules/tooling-and-review/preset-goals.md +40 -0
  302. package/presets/claude/svelte/rules/tooling-and-review/preset-layering.md +1 -1
  303. package/presets/claude/svelte/rules/tooling-and-review/preset-pr-checklist.md +4 -0
  304. package/presets/claude/svelte/rules/tooling-and-review/preset-twin-sync.md +19 -77
  305. package/presets/claude/svelte/rules/tooling-and-review/preset-writing-style.md +51 -0
  306. package/presets/claude/svelte/team/README.md +17 -0
  307. package/presets/claude/svelte/team/fixtures/artifact-manifest.example.json +1 -1
  308. package/presets/cursor/android-kotlin/REPO_AGENTS.md +3 -0
  309. package/presets/cursor/android-kotlin/agents/README.md +7 -0
  310. package/presets/cursor/android-kotlin/agents/build-verifier.md +12 -0
  311. package/presets/cursor/android-kotlin/agents/code-reviewer.md +12 -0
  312. package/presets/cursor/android-kotlin/agents/debugger.md +12 -0
  313. package/presets/cursor/android-kotlin/agents/feature-developer.md +12 -0
  314. package/presets/cursor/android-kotlin/agents/task-analyst.md +31 -1
  315. package/presets/cursor/android-kotlin/agents/task-router.md +8 -0
  316. package/presets/cursor/android-kotlin/ai-local/conventions.md +8 -0
  317. package/presets/cursor/android-kotlin/commands/task-continue.md +8 -0
  318. package/presets/cursor/android-kotlin/commands/task.md +14 -1
  319. package/presets/cursor/android-kotlin/rules/README.md +3 -1
  320. package/presets/cursor/android-kotlin/rules/agent-team-intake.mdc +3 -0
  321. package/presets/cursor/android-kotlin/rules/agent-team-orchestrator.mdc +33 -3
  322. package/presets/cursor/android-kotlin/rules/ai-local-overlay.mdc +4 -0
  323. package/presets/cursor/android-kotlin/rules/android-app-core.mdc +6 -0
  324. package/presets/cursor/android-kotlin/rules/code-quality-and-refactoring.mdc +20 -1
  325. package/presets/cursor/android-kotlin/rules/feature-delivery-workflow.mdc +4 -0
  326. package/presets/cursor/android-kotlin/rules/language-policy.mdc +52 -0
  327. package/presets/cursor/android-kotlin/rules/mockup-review.mdc +56 -1
  328. package/presets/cursor/android-kotlin/rules/preset-goals.mdc +40 -0
  329. package/presets/cursor/android-kotlin/rules/preset-layering.mdc +1 -1
  330. package/presets/cursor/android-kotlin/rules/preset-pr-checklist.mdc +4 -0
  331. package/presets/cursor/android-kotlin/rules/preset-twin-sync.mdc +19 -77
  332. package/presets/cursor/android-kotlin/rules/preset-writing-style.mdc +51 -0
  333. package/presets/cursor/android-kotlin/team/README.md +11 -0
  334. package/presets/cursor/go/REPO_AGENTS.md +3 -0
  335. package/presets/cursor/go/agents/README.md +7 -0
  336. package/presets/cursor/go/agents/build-verifier.md +12 -0
  337. package/presets/cursor/go/agents/code-reviewer.md +12 -0
  338. package/presets/cursor/go/agents/debugger.md +12 -0
  339. package/presets/cursor/go/agents/feature-developer.md +12 -0
  340. package/presets/cursor/go/agents/task-analyst.md +31 -1
  341. package/presets/cursor/go/agents/task-router.md +8 -0
  342. package/presets/cursor/go/ai-local/conventions.md +8 -0
  343. package/presets/cursor/go/commands/task-continue.md +8 -0
  344. package/presets/cursor/go/commands/task.md +14 -1
  345. package/presets/cursor/go/rules/README.md +5 -3
  346. package/presets/cursor/go/rules/agent-team-intake.mdc +3 -0
  347. package/presets/cursor/go/rules/agent-team-orchestrator.mdc +32 -2
  348. package/presets/cursor/go/rules/ai-local-overlay.mdc +4 -0
  349. package/presets/cursor/go/rules/code-quality-and-refactoring.mdc +20 -1
  350. package/presets/cursor/go/rules/feature-delivery-workflow.mdc +4 -0
  351. package/presets/cursor/go/rules/go-app-core.mdc +6 -0
  352. package/presets/cursor/go/rules/language-policy.mdc +52 -0
  353. package/presets/cursor/go/rules/preset-goals.mdc +40 -0
  354. package/presets/cursor/go/rules/preset-layering.mdc +1 -1
  355. package/presets/cursor/go/rules/preset-pr-checklist.mdc +4 -0
  356. package/presets/cursor/go/rules/preset-twin-sync.mdc +19 -77
  357. package/presets/cursor/go/rules/preset-writing-style.mdc +51 -0
  358. package/presets/cursor/go/team/README.md +11 -0
  359. package/presets/cursor/ios-swift/REPO_AGENTS.md +3 -0
  360. package/presets/cursor/ios-swift/agents/README.md +7 -0
  361. package/presets/cursor/ios-swift/agents/build-verifier.md +12 -0
  362. package/presets/cursor/ios-swift/agents/code-reviewer.md +12 -0
  363. package/presets/cursor/ios-swift/agents/debugger.md +12 -0
  364. package/presets/cursor/ios-swift/agents/feature-developer.md +12 -0
  365. package/presets/cursor/ios-swift/agents/task-analyst.md +31 -1
  366. package/presets/cursor/ios-swift/agents/task-router.md +8 -0
  367. package/presets/cursor/ios-swift/ai-local/conventions.md +8 -0
  368. package/presets/cursor/ios-swift/commands/task-continue.md +8 -0
  369. package/presets/cursor/ios-swift/commands/task.md +14 -1
  370. package/presets/cursor/ios-swift/rules/README.md +4 -2
  371. package/presets/cursor/ios-swift/rules/agent-team-intake.mdc +3 -0
  372. package/presets/cursor/ios-swift/rules/agent-team-orchestrator.mdc +33 -3
  373. package/presets/cursor/ios-swift/rules/ai-local-overlay.mdc +4 -0
  374. package/presets/cursor/ios-swift/rules/code-quality-and-refactoring.mdc +20 -1
  375. package/presets/cursor/ios-swift/rules/feature-delivery-workflow.mdc +4 -0
  376. package/presets/cursor/ios-swift/rules/ios-app-core.mdc +6 -0
  377. package/presets/cursor/ios-swift/rules/language-policy.mdc +52 -0
  378. package/presets/cursor/ios-swift/rules/mockup-review.mdc +56 -1
  379. package/presets/cursor/ios-swift/rules/preset-goals.mdc +40 -0
  380. package/presets/cursor/ios-swift/rules/preset-layering.mdc +1 -1
  381. package/presets/cursor/ios-swift/rules/preset-pr-checklist.mdc +4 -0
  382. package/presets/cursor/ios-swift/rules/preset-twin-sync.mdc +19 -77
  383. package/presets/cursor/ios-swift/rules/preset-writing-style.mdc +51 -0
  384. package/presets/cursor/ios-swift/team/README.md +11 -0
  385. package/presets/cursor/java/REPO_AGENTS.md +3 -0
  386. package/presets/cursor/java/agents/README.md +7 -0
  387. package/presets/cursor/java/agents/build-verifier.md +12 -0
  388. package/presets/cursor/java/agents/code-reviewer.md +12 -0
  389. package/presets/cursor/java/agents/debugger.md +12 -0
  390. package/presets/cursor/java/agents/feature-developer.md +12 -0
  391. package/presets/cursor/java/agents/task-analyst.md +31 -1
  392. package/presets/cursor/java/agents/task-router.md +8 -0
  393. package/presets/cursor/java/ai-local/conventions.md +8 -0
  394. package/presets/cursor/java/commands/task-continue.md +8 -0
  395. package/presets/cursor/java/commands/task.md +14 -1
  396. package/presets/cursor/java/rules/README.md +5 -3
  397. package/presets/cursor/java/rules/agent-team-intake.mdc +3 -0
  398. package/presets/cursor/java/rules/agent-team-orchestrator.mdc +32 -2
  399. package/presets/cursor/java/rules/ai-local-overlay.mdc +4 -0
  400. package/presets/cursor/java/rules/code-quality-and-refactoring.mdc +20 -1
  401. package/presets/cursor/java/rules/feature-delivery-workflow.mdc +4 -0
  402. package/presets/cursor/java/rules/java-app-core.mdc +6 -0
  403. package/presets/cursor/java/rules/language-policy.mdc +52 -0
  404. package/presets/cursor/java/rules/preset-goals.mdc +40 -0
  405. package/presets/cursor/java/rules/preset-layering.mdc +1 -1
  406. package/presets/cursor/java/rules/preset-pr-checklist.mdc +4 -0
  407. package/presets/cursor/java/rules/preset-twin-sync.mdc +19 -77
  408. package/presets/cursor/java/rules/preset-writing-style.mdc +51 -0
  409. package/presets/cursor/java/team/README.md +11 -0
  410. package/presets/cursor/mcp-ts/REPO_AGENTS.md +3 -0
  411. package/presets/cursor/mcp-ts/agents/README.md +7 -0
  412. package/presets/cursor/mcp-ts/agents/build-verifier.md +12 -0
  413. package/presets/cursor/mcp-ts/agents/feature-developer.md +12 -0
  414. package/presets/cursor/mcp-ts/agents/task-analyst.md +31 -1
  415. package/presets/cursor/mcp-ts/agents/task-router.md +8 -0
  416. package/presets/cursor/mcp-ts/ai-local/conventions.md +8 -0
  417. package/presets/cursor/mcp-ts/commands/task-continue.md +8 -0
  418. package/presets/cursor/mcp-ts/commands/task.md +14 -1
  419. package/presets/cursor/mcp-ts/rules/README.md +4 -2
  420. package/presets/cursor/mcp-ts/rules/agent-team-intake.mdc +3 -0
  421. package/presets/cursor/mcp-ts/rules/agent-team-orchestrator.mdc +32 -2
  422. package/presets/cursor/mcp-ts/rules/ai-local-overlay.mdc +4 -0
  423. package/presets/cursor/mcp-ts/rules/code-quality-and-refactoring.mdc +20 -1
  424. package/presets/cursor/mcp-ts/rules/feature-delivery-workflow.mdc +4 -0
  425. package/presets/cursor/mcp-ts/rules/language-policy.mdc +52 -0
  426. package/presets/cursor/mcp-ts/rules/mcp-ts-app-core.mdc +6 -0
  427. package/presets/cursor/mcp-ts/rules/preset-goals.mdc +40 -0
  428. package/presets/cursor/mcp-ts/rules/preset-layering.mdc +1 -1
  429. package/presets/cursor/mcp-ts/rules/preset-pr-checklist.mdc +4 -0
  430. package/presets/cursor/mcp-ts/rules/preset-twin-sync.mdc +19 -77
  431. package/presets/cursor/mcp-ts/rules/preset-writing-style.mdc +51 -0
  432. package/presets/cursor/mcp-ts/team/README.md +11 -0
  433. package/presets/cursor/next/REPO_AGENTS.md +14 -1
  434. package/presets/cursor/next/agents/README.md +7 -1
  435. package/presets/cursor/next/agents/build-verifier.md +13 -0
  436. package/presets/cursor/next/agents/code-reviewer.md +24 -0
  437. package/presets/cursor/next/agents/debugger.md +12 -0
  438. package/presets/cursor/next/agents/feature-developer.md +21 -2
  439. package/presets/cursor/next/agents/mockup-reviewer.md +25 -4
  440. package/presets/cursor/next/agents/openspec-author.md +2 -0
  441. package/presets/cursor/next/agents/task-analyst.md +50 -2
  442. package/presets/cursor/next/agents/task-router.md +9 -0
  443. package/presets/cursor/next/ai-local/conventions.md +8 -0
  444. package/presets/cursor/next/ai-local/rules-library/agent-artifacts-no-local-paths.md +41 -8
  445. package/presets/cursor/next/ai-local/rules-library/agent-pipeline-gates.md +19 -0
  446. package/presets/cursor/next/ai-local/rules-library/analytics-events.md +18 -0
  447. package/presets/cursor/next/ai-local/rules-library/api-contract-source.md +14 -0
  448. package/presets/cursor/next/ai-local/rules-library/artifact-lifecycle.md +17 -0
  449. package/presets/cursor/next/ai-local/rules-library/code-style.md +68 -0
  450. package/presets/cursor/next/ai-local/rules-library/component-child-decomposition.md +81 -0
  451. package/presets/cursor/next/ai-local/rules-library/feature-flags-experiments.md +15 -0
  452. package/presets/cursor/next/ai-local/rules-library/mcp-required-for-ui-layout.md +5 -1
  453. package/presets/cursor/next/ai-local/rules-library/no-react-fc.md +46 -0
  454. package/presets/cursor/next/ai-local/rules-library/no-test-driven-behavior-change.md +1 -1
  455. package/presets/cursor/next/ai-local/rules-library/pwa-service-worker.md +15 -0
  456. package/presets/cursor/next/ai-local/rules-library/qa-test-cases.md +14 -0
  457. package/presets/cursor/next/ai-local/rules-library/router-pages.md +4 -2
  458. package/presets/cursor/next/ai-local/rules-library/single-source-copy-constants.md +3 -1
  459. package/presets/cursor/next/ai-local/rules-library/storybook-catalog-structure.md +62 -0
  460. package/presets/cursor/next/ai-local/rules-library/storybook-cleanup-temp-screenshots.md +40 -0
  461. package/presets/cursor/next/ai-local/rules-library/storybook-csf-authoring.md +100 -0
  462. package/presets/cursor/next/ai-local/rules-library/storybook-dev-compare-figma.md +71 -0
  463. package/presets/cursor/next/ai-local/rules-library/storybook-keep-tests-current.md +75 -0
  464. package/presets/cursor/next/ai-local/rules-library/storybook-modals.md +64 -0
  465. package/presets/cursor/next/ai-local/rules-library/storybook-no-app-node-modules.md +40 -0
  466. package/presets/cursor/next/ai-local/rules-library/storybook-ui-quality-gate.md +38 -0
  467. package/presets/cursor/next/ai-local/rules-library/task-levels.md +28 -0
  468. package/presets/cursor/next/ai-local/rules-library/ui-change-review-gate.md +15 -0
  469. package/presets/cursor/next/commands/task-continue.md +8 -0
  470. package/presets/cursor/next/commands/task.md +14 -1
  471. package/presets/cursor/next/rules/README.md +7 -2
  472. package/presets/cursor/next/rules/agent-team-intake.mdc +3 -0
  473. package/presets/cursor/next/rules/agent-team-orchestrator.mdc +37 -3
  474. package/presets/cursor/next/rules/ai-local-overlay.mdc +20 -2
  475. package/presets/cursor/next/rules/code-quality-and-refactoring.mdc +20 -1
  476. package/presets/cursor/next/rules/code-review-mr.mdc +14 -0
  477. package/presets/cursor/next/rules/component-catalog-gate.mdc +38 -0
  478. package/presets/cursor/next/rules/design-tokens-binding.mdc +24 -2
  479. package/presets/cursor/next/rules/feature-delivery-workflow.mdc +13 -1
  480. package/presets/cursor/next/rules/forms-validation.mdc +33 -0
  481. package/presets/cursor/next/rules/language-policy.mdc +52 -0
  482. package/presets/cursor/next/rules/mcp-usage.mdc +1 -0
  483. package/presets/cursor/next/rules/mockup-review.mdc +77 -1
  484. package/presets/cursor/next/rules/next-app-core.mdc +9 -0
  485. package/presets/cursor/next/rules/next-static-export.mdc +35 -0
  486. package/presets/cursor/next/rules/post-change-lint.mdc +4 -0
  487. package/presets/cursor/next/rules/preset-goals.mdc +40 -0
  488. package/presets/cursor/next/rules/preset-layering.mdc +1 -1
  489. package/presets/cursor/next/rules/preset-pr-checklist.mdc +4 -0
  490. package/presets/cursor/next/rules/preset-twin-sync.mdc +19 -77
  491. package/presets/cursor/next/rules/preset-writing-style.mdc +51 -0
  492. package/presets/cursor/next/rules/product-specs-authoring.mdc +1 -0
  493. package/presets/cursor/next/rules/product-specs.mdc +1 -0
  494. package/presets/cursor/next/rules/react-next-anti-hallucination.mdc +10 -0
  495. package/presets/cursor/next/rules/react-ui.mdc +19 -1
  496. package/presets/cursor/next/rules/reference-features.mdc +5 -0
  497. package/presets/cursor/next/rules/security-next.mdc +12 -0
  498. package/presets/cursor/next/rules/store-rtk.mdc +6 -0
  499. package/presets/cursor/next/rules/tests-e2e-structure.mdc +1 -0
  500. package/presets/cursor/next/rules/tests-unit.mdc +1 -0
  501. package/presets/cursor/next/skills/README.md +1 -0
  502. package/presets/cursor/next/skills/code-review/SKILL.md +1 -1
  503. package/presets/cursor/next/skills/figma-fidelity/SKILL.md +96 -0
  504. package/presets/cursor/next/skills/mockup-review/SKILL.md +5 -1
  505. package/presets/cursor/next/team/README.md +12 -0
  506. package/presets/cursor/next/team/fixtures/artifact-manifest.example.json +1 -1
  507. package/presets/cursor/next/team/fixtures/feature-with-ux-no-figma.json +3 -4
  508. package/presets/cursor/nuxt/REPO_AGENTS.md +3 -0
  509. package/presets/cursor/nuxt/agents/README.md +7 -0
  510. package/presets/cursor/nuxt/agents/build-verifier.md +12 -0
  511. package/presets/cursor/nuxt/agents/code-reviewer.md +12 -0
  512. package/presets/cursor/nuxt/agents/debugger.md +12 -0
  513. package/presets/cursor/nuxt/agents/feature-developer.md +12 -0
  514. package/presets/cursor/nuxt/agents/task-analyst.md +43 -2
  515. package/presets/cursor/nuxt/agents/task-router.md +8 -0
  516. package/presets/cursor/nuxt/ai-local/conventions.md +8 -0
  517. package/presets/cursor/nuxt/commands/task-continue.md +8 -0
  518. package/presets/cursor/nuxt/commands/task.md +14 -1
  519. package/presets/cursor/nuxt/rules/README.md +3 -1
  520. package/presets/cursor/nuxt/rules/agent-team-intake.mdc +3 -0
  521. package/presets/cursor/nuxt/rules/agent-team-orchestrator.mdc +33 -3
  522. package/presets/cursor/nuxt/rules/ai-local-overlay.mdc +4 -0
  523. package/presets/cursor/nuxt/rules/code-quality-and-refactoring.mdc +20 -1
  524. package/presets/cursor/nuxt/rules/feature-delivery-workflow.mdc +4 -0
  525. package/presets/cursor/nuxt/rules/language-policy.mdc +52 -0
  526. package/presets/cursor/nuxt/rules/mockup-review.mdc +56 -1
  527. package/presets/cursor/nuxt/rules/nuxt-app-core.mdc +6 -0
  528. package/presets/cursor/nuxt/rules/preset-goals.mdc +40 -0
  529. package/presets/cursor/nuxt/rules/preset-layering.mdc +1 -1
  530. package/presets/cursor/nuxt/rules/preset-pr-checklist.mdc +4 -0
  531. package/presets/cursor/nuxt/rules/preset-twin-sync.mdc +19 -77
  532. package/presets/cursor/nuxt/rules/preset-writing-style.mdc +51 -0
  533. package/presets/cursor/nuxt/team/README.md +11 -0
  534. package/presets/cursor/nuxt/team/fixtures/artifact-manifest.example.json +1 -1
  535. package/presets/cursor/php-hexagonal/REPO_AGENTS.md +3 -0
  536. package/presets/cursor/php-hexagonal/agents/README.md +7 -0
  537. package/presets/cursor/php-hexagonal/agents/build-verifier.md +12 -0
  538. package/presets/cursor/php-hexagonal/agents/code-reviewer.md +12 -0
  539. package/presets/cursor/php-hexagonal/agents/debugger.md +12 -0
  540. package/presets/cursor/php-hexagonal/agents/feature-developer.md +12 -0
  541. package/presets/cursor/php-hexagonal/agents/task-analyst.md +31 -1
  542. package/presets/cursor/php-hexagonal/agents/task-router.md +8 -0
  543. package/presets/cursor/php-hexagonal/ai-local/conventions.md +8 -0
  544. package/presets/cursor/php-hexagonal/commands/task-continue.md +8 -0
  545. package/presets/cursor/php-hexagonal/commands/task.md +14 -1
  546. package/presets/cursor/php-hexagonal/rules/README.md +5 -3
  547. package/presets/cursor/php-hexagonal/rules/agent-team-intake.mdc +3 -0
  548. package/presets/cursor/php-hexagonal/rules/agent-team-orchestrator.mdc +32 -2
  549. package/presets/cursor/php-hexagonal/rules/ai-local-overlay.mdc +4 -0
  550. package/presets/cursor/php-hexagonal/rules/code-quality-and-refactoring.mdc +20 -1
  551. package/presets/cursor/php-hexagonal/rules/feature-delivery-workflow.mdc +4 -0
  552. package/presets/cursor/php-hexagonal/rules/language-policy.mdc +52 -0
  553. package/presets/cursor/php-hexagonal/rules/php-app-core.mdc +6 -0
  554. package/presets/cursor/php-hexagonal/rules/preset-goals.mdc +40 -0
  555. package/presets/cursor/php-hexagonal/rules/preset-layering.mdc +1 -1
  556. package/presets/cursor/php-hexagonal/rules/preset-pr-checklist.mdc +4 -0
  557. package/presets/cursor/php-hexagonal/rules/preset-twin-sync.mdc +19 -77
  558. package/presets/cursor/php-hexagonal/rules/preset-writing-style.mdc +51 -0
  559. package/presets/cursor/php-hexagonal/team/README.md +11 -0
  560. package/presets/cursor/php-laravel/REPO_AGENTS.md +3 -0
  561. package/presets/cursor/php-laravel/agents/README.md +7 -0
  562. package/presets/cursor/php-laravel/agents/build-verifier.md +12 -0
  563. package/presets/cursor/php-laravel/agents/code-reviewer.md +12 -0
  564. package/presets/cursor/php-laravel/agents/debugger.md +12 -0
  565. package/presets/cursor/php-laravel/agents/feature-developer.md +12 -0
  566. package/presets/cursor/php-laravel/agents/task-analyst.md +31 -1
  567. package/presets/cursor/php-laravel/agents/task-router.md +8 -0
  568. package/presets/cursor/php-laravel/ai-local/conventions.md +8 -0
  569. package/presets/cursor/php-laravel/commands/task-continue.md +8 -0
  570. package/presets/cursor/php-laravel/commands/task.md +14 -1
  571. package/presets/cursor/php-laravel/rules/README.md +5 -3
  572. package/presets/cursor/php-laravel/rules/agent-team-intake.mdc +3 -0
  573. package/presets/cursor/php-laravel/rules/agent-team-orchestrator.mdc +32 -2
  574. package/presets/cursor/php-laravel/rules/ai-local-overlay.mdc +4 -0
  575. package/presets/cursor/php-laravel/rules/code-quality-and-refactoring.mdc +20 -1
  576. package/presets/cursor/php-laravel/rules/feature-delivery-workflow.mdc +4 -0
  577. package/presets/cursor/php-laravel/rules/language-policy.mdc +52 -0
  578. package/presets/cursor/php-laravel/rules/laravel-app-core.mdc +6 -0
  579. package/presets/cursor/php-laravel/rules/preset-goals.mdc +40 -0
  580. package/presets/cursor/php-laravel/rules/preset-layering.mdc +1 -1
  581. package/presets/cursor/php-laravel/rules/preset-pr-checklist.mdc +4 -0
  582. package/presets/cursor/php-laravel/rules/preset-twin-sync.mdc +19 -77
  583. package/presets/cursor/php-laravel/rules/preset-writing-style.mdc +51 -0
  584. package/presets/cursor/php-laravel/team/README.md +11 -0
  585. package/presets/cursor/svelte/REPO_AGENTS.md +3 -0
  586. package/presets/cursor/svelte/agents/README.md +7 -0
  587. package/presets/cursor/svelte/agents/build-verifier.md +12 -0
  588. package/presets/cursor/svelte/agents/code-reviewer.md +12 -0
  589. package/presets/cursor/svelte/agents/debugger.md +12 -0
  590. package/presets/cursor/svelte/agents/feature-developer.md +12 -0
  591. package/presets/cursor/svelte/agents/task-analyst.md +43 -2
  592. package/presets/cursor/svelte/agents/task-router.md +8 -0
  593. package/presets/cursor/svelte/ai-local/conventions.md +8 -0
  594. package/presets/cursor/svelte/commands/task-continue.md +8 -0
  595. package/presets/cursor/svelte/commands/task.md +14 -1
  596. package/presets/cursor/svelte/rules/README.md +3 -1
  597. package/presets/cursor/svelte/rules/agent-team-intake.mdc +3 -0
  598. package/presets/cursor/svelte/rules/agent-team-orchestrator.mdc +33 -3
  599. package/presets/cursor/svelte/rules/ai-local-overlay.mdc +4 -0
  600. package/presets/cursor/svelte/rules/code-quality-and-refactoring.mdc +20 -1
  601. package/presets/cursor/svelte/rules/feature-delivery-workflow.mdc +4 -0
  602. package/presets/cursor/svelte/rules/language-policy.mdc +52 -0
  603. package/presets/cursor/svelte/rules/mockup-review.mdc +56 -1
  604. package/presets/cursor/svelte/rules/preset-goals.mdc +40 -0
  605. package/presets/cursor/svelte/rules/preset-layering.mdc +1 -1
  606. package/presets/cursor/svelte/rules/preset-pr-checklist.mdc +4 -0
  607. package/presets/cursor/svelte/rules/preset-twin-sync.mdc +19 -77
  608. package/presets/cursor/svelte/rules/preset-writing-style.mdc +51 -0
  609. package/presets/cursor/svelte/rules/svelte-app-core.mdc +6 -0
  610. package/presets/cursor/svelte/team/README.md +11 -0
  611. package/presets/cursor/svelte/team/fixtures/artifact-manifest.example.json +1 -1
  612. package/presets/mavis/android-kotlin/REPO_AGENTS.md +3 -0
  613. package/presets/mavis/android-kotlin/adapter-map.json +29 -2
  614. package/presets/mavis/android-kotlin/agents/README.md +7 -0
  615. package/presets/mavis/android-kotlin/agents/build-verifier.md +12 -0
  616. package/presets/mavis/android-kotlin/agents/code-reviewer.md +12 -0
  617. package/presets/mavis/android-kotlin/agents/debugger.md +12 -0
  618. package/presets/mavis/android-kotlin/agents/feature-developer.md +12 -0
  619. package/presets/mavis/android-kotlin/agents/task-analyst.md +31 -1
  620. package/presets/mavis/android-kotlin/agents/task-router.md +8 -0
  621. package/presets/mavis/android-kotlin/ai-local/conventions.md +8 -0
  622. package/presets/mavis/android-kotlin/commands/task-continue.md +8 -0
  623. package/presets/mavis/android-kotlin/commands/task.md +14 -1
  624. package/presets/mavis/android-kotlin/rules/agent-team-intake.md +3 -0
  625. package/presets/mavis/android-kotlin/rules/agent-team-orchestrator.md +23 -4
  626. package/presets/mavis/android-kotlin/rules/ai-local-overlay.md +4 -0
  627. package/presets/mavis/android-kotlin/rules/android-app-core.md +6 -0
  628. package/presets/mavis/android-kotlin/rules/code-quality-and-refactoring.md +20 -1
  629. package/presets/mavis/android-kotlin/rules/code-review-mr.md +6 -6
  630. package/presets/mavis/android-kotlin/rules/feature-delivery-workflow.md +4 -0
  631. package/presets/mavis/android-kotlin/rules/language-policy.md +43 -0
  632. package/presets/mavis/android-kotlin/rules/mockup-review.md +56 -1
  633. package/presets/mavis/android-kotlin/rules/preset-goals.md +31 -0
  634. package/presets/mavis/android-kotlin/rules/preset-layering.md +1 -1
  635. package/presets/mavis/android-kotlin/rules/preset-pr-checklist.md +4 -0
  636. package/presets/mavis/android-kotlin/rules/preset-twin-sync.md +19 -77
  637. package/presets/mavis/android-kotlin/rules/preset-writing-style.md +42 -0
  638. package/presets/mavis/android-kotlin/team/README.md +11 -0
  639. package/presets/mavis/go/REPO_AGENTS.md +3 -0
  640. package/presets/mavis/go/adapter-map.json +30 -3
  641. package/presets/mavis/go/agents/README.md +5 -0
  642. package/presets/mavis/go/agents/build-verifier.md +12 -0
  643. package/presets/mavis/go/agents/code-reviewer.md +12 -0
  644. package/presets/mavis/go/agents/debugger.md +12 -0
  645. package/presets/mavis/go/agents/feature-developer.md +12 -0
  646. package/presets/mavis/go/agents/task-analyst.md +31 -1
  647. package/presets/mavis/go/agents/task-router.md +8 -0
  648. package/presets/mavis/go/ai-local/conventions.md +8 -0
  649. package/presets/mavis/go/commands/task-continue.md +8 -0
  650. package/presets/mavis/go/commands/task.md +14 -1
  651. package/presets/mavis/go/rules/agent-team-intake.md +3 -0
  652. package/presets/mavis/go/rules/agent-team-orchestrator.md +23 -4
  653. package/presets/mavis/go/rules/ai-local-overlay.md +4 -0
  654. package/presets/mavis/go/rules/code-quality-and-refactoring.md +21 -2
  655. package/presets/mavis/go/rules/feature-delivery-workflow.md +11 -1
  656. package/presets/mavis/go/rules/go-app-core.md +6 -0
  657. package/presets/mavis/go/rules/language-policy.md +43 -0
  658. package/presets/mavis/go/rules/preset-goals.md +31 -0
  659. package/presets/mavis/go/rules/preset-layering.md +1 -1
  660. package/presets/mavis/go/rules/preset-pr-checklist.md +4 -0
  661. package/presets/mavis/go/rules/preset-twin-sync.md +19 -77
  662. package/presets/mavis/go/rules/preset-writing-style.md +42 -0
  663. package/presets/mavis/go/team/README.md +11 -0
  664. package/presets/mavis/ios-swift/REPO_AGENTS.md +3 -0
  665. package/presets/mavis/ios-swift/adapter-map.json +29 -2
  666. package/presets/mavis/ios-swift/agents/README.md +7 -0
  667. package/presets/mavis/ios-swift/agents/build-verifier.md +12 -0
  668. package/presets/mavis/ios-swift/agents/code-reviewer.md +12 -0
  669. package/presets/mavis/ios-swift/agents/debugger.md +12 -0
  670. package/presets/mavis/ios-swift/agents/feature-developer.md +12 -0
  671. package/presets/mavis/ios-swift/agents/task-analyst.md +31 -1
  672. package/presets/mavis/ios-swift/agents/task-router.md +8 -0
  673. package/presets/mavis/ios-swift/ai-local/conventions.md +8 -0
  674. package/presets/mavis/ios-swift/commands/task-continue.md +8 -0
  675. package/presets/mavis/ios-swift/commands/task.md +14 -1
  676. package/presets/mavis/ios-swift/rules/agent-team-intake.md +3 -0
  677. package/presets/mavis/ios-swift/rules/agent-team-orchestrator.md +23 -4
  678. package/presets/mavis/ios-swift/rules/ai-local-overlay.md +4 -0
  679. package/presets/mavis/ios-swift/rules/code-quality-and-refactoring.md +21 -2
  680. package/presets/mavis/ios-swift/rules/code-review-mr.md +6 -6
  681. package/presets/mavis/ios-swift/rules/feature-delivery-workflow.md +29 -15
  682. package/presets/mavis/ios-swift/rules/ios-app-core.md +6 -0
  683. package/presets/mavis/ios-swift/rules/language-policy.md +43 -0
  684. package/presets/mavis/ios-swift/rules/mockup-review.md +56 -1
  685. package/presets/mavis/ios-swift/rules/preset-goals.md +31 -0
  686. package/presets/mavis/ios-swift/rules/preset-layering.md +1 -1
  687. package/presets/mavis/ios-swift/rules/preset-pr-checklist.md +4 -0
  688. package/presets/mavis/ios-swift/rules/preset-twin-sync.md +19 -77
  689. package/presets/mavis/ios-swift/rules/preset-writing-style.md +42 -0
  690. package/presets/mavis/ios-swift/rules/reference-features.md +3 -3
  691. package/presets/mavis/ios-swift/team/README.md +11 -0
  692. package/presets/mavis/java/REPO_AGENTS.md +3 -0
  693. package/presets/mavis/java/adapter-map.json +30 -3
  694. package/presets/mavis/java/agents/README.md +5 -0
  695. package/presets/mavis/java/agents/build-verifier.md +12 -0
  696. package/presets/mavis/java/agents/code-reviewer.md +12 -0
  697. package/presets/mavis/java/agents/debugger.md +12 -0
  698. package/presets/mavis/java/agents/feature-developer.md +12 -0
  699. package/presets/mavis/java/agents/task-analyst.md +31 -1
  700. package/presets/mavis/java/agents/task-router.md +8 -0
  701. package/presets/mavis/java/ai-local/conventions.md +8 -0
  702. package/presets/mavis/java/commands/task-continue.md +8 -0
  703. package/presets/mavis/java/commands/task.md +14 -1
  704. package/presets/mavis/java/rules/agent-team-intake.md +3 -0
  705. package/presets/mavis/java/rules/agent-team-orchestrator.md +23 -4
  706. package/presets/mavis/java/rules/ai-local-overlay.md +4 -0
  707. package/presets/mavis/java/rules/code-quality-and-refactoring.md +21 -2
  708. package/presets/mavis/java/rules/feature-delivery-workflow.md +11 -1
  709. package/presets/mavis/java/rules/java-app-core.md +6 -0
  710. package/presets/mavis/java/rules/language-policy.md +43 -0
  711. package/presets/mavis/java/rules/preset-goals.md +31 -0
  712. package/presets/mavis/java/rules/preset-layering.md +1 -1
  713. package/presets/mavis/java/rules/preset-pr-checklist.md +4 -0
  714. package/presets/mavis/java/rules/preset-twin-sync.md +19 -77
  715. package/presets/mavis/java/rules/preset-writing-style.md +42 -0
  716. package/presets/mavis/java/team/README.md +11 -0
  717. package/presets/mavis/mcp-ts/REPO_AGENTS.md +3 -0
  718. package/presets/mavis/mcp-ts/adapter-map.json +28 -1
  719. package/presets/mavis/mcp-ts/agents/README.md +7 -0
  720. package/presets/mavis/mcp-ts/agents/build-verifier.md +12 -0
  721. package/presets/mavis/mcp-ts/agents/feature-developer.md +12 -0
  722. package/presets/mavis/mcp-ts/agents/task-analyst.md +31 -1
  723. package/presets/mavis/mcp-ts/agents/task-router.md +8 -0
  724. package/presets/mavis/mcp-ts/ai-local/conventions.md +8 -0
  725. package/presets/mavis/mcp-ts/commands/task-continue.md +8 -0
  726. package/presets/mavis/mcp-ts/commands/task.md +14 -1
  727. package/presets/mavis/mcp-ts/rules/agent-team-intake.md +3 -0
  728. package/presets/mavis/mcp-ts/rules/agent-team-orchestrator.md +23 -4
  729. package/presets/mavis/mcp-ts/rules/ai-local-overlay.md +4 -0
  730. package/presets/mavis/mcp-ts/rules/code-quality-and-refactoring.md +20 -1
  731. package/presets/mavis/mcp-ts/rules/feature-delivery-workflow.md +11 -1
  732. package/presets/mavis/mcp-ts/rules/language-policy.md +43 -0
  733. package/presets/mavis/mcp-ts/rules/mcp-ts-app-core.md +6 -0
  734. package/presets/mavis/mcp-ts/rules/preset-goals.md +31 -0
  735. package/presets/mavis/mcp-ts/rules/preset-layering.md +1 -1
  736. package/presets/mavis/mcp-ts/rules/preset-pr-checklist.md +4 -0
  737. package/presets/mavis/mcp-ts/rules/preset-twin-sync.md +19 -77
  738. package/presets/mavis/mcp-ts/rules/preset-writing-style.md +42 -0
  739. package/presets/mavis/mcp-ts/team/README.md +11 -0
  740. package/presets/mavis/next/REPO_AGENTS.md +14 -1
  741. package/presets/mavis/next/adapter-map.json +229 -10
  742. package/presets/mavis/next/agents/README.md +6 -0
  743. package/presets/mavis/next/agents/build-verifier.md +13 -0
  744. package/presets/mavis/next/agents/code-reviewer.md +24 -0
  745. package/presets/mavis/next/agents/debugger.md +12 -0
  746. package/presets/mavis/next/agents/feature-developer.md +21 -2
  747. package/presets/mavis/next/agents/mockup-reviewer.md +25 -4
  748. package/presets/mavis/next/agents/openspec-author.md +2 -0
  749. package/presets/mavis/next/agents/task-analyst.md +50 -2
  750. package/presets/mavis/next/agents/task-router.md +9 -0
  751. package/presets/mavis/next/ai-local/conventions.md +8 -0
  752. package/presets/mavis/next/ai-local/rules-library/agent-artifacts-no-local-paths.md +41 -8
  753. package/presets/mavis/next/ai-local/rules-library/agent-pipeline-gates.md +19 -0
  754. package/presets/mavis/next/ai-local/rules-library/analytics-events.md +18 -0
  755. package/presets/mavis/next/ai-local/rules-library/api-contract-source.md +14 -0
  756. package/presets/mavis/next/ai-local/rules-library/artifact-lifecycle.md +17 -0
  757. package/presets/mavis/next/ai-local/rules-library/code-style.md +68 -0
  758. package/presets/mavis/next/ai-local/rules-library/component-child-decomposition.md +81 -0
  759. package/presets/mavis/next/ai-local/rules-library/feature-flags-experiments.md +15 -0
  760. package/presets/mavis/next/ai-local/rules-library/mcp-required-for-ui-layout.md +5 -1
  761. package/presets/mavis/next/ai-local/rules-library/no-react-fc.md +46 -0
  762. package/presets/mavis/next/ai-local/rules-library/no-test-driven-behavior-change.md +1 -1
  763. package/presets/mavis/next/ai-local/rules-library/pwa-service-worker.md +15 -0
  764. package/presets/mavis/next/ai-local/rules-library/qa-test-cases.md +14 -0
  765. package/presets/mavis/next/ai-local/rules-library/router-pages.md +4 -2
  766. package/presets/mavis/next/ai-local/rules-library/single-source-copy-constants.md +3 -1
  767. package/presets/mavis/next/ai-local/rules-library/storybook-catalog-structure.md +62 -0
  768. package/presets/mavis/next/ai-local/rules-library/storybook-cleanup-temp-screenshots.md +40 -0
  769. package/presets/mavis/next/ai-local/rules-library/storybook-csf-authoring.md +100 -0
  770. package/presets/mavis/next/ai-local/rules-library/storybook-dev-compare-figma.md +71 -0
  771. package/presets/mavis/next/ai-local/rules-library/storybook-keep-tests-current.md +75 -0
  772. package/presets/mavis/next/ai-local/rules-library/storybook-modals.md +64 -0
  773. package/presets/mavis/next/ai-local/rules-library/storybook-no-app-node-modules.md +40 -0
  774. package/presets/mavis/next/ai-local/rules-library/storybook-ui-quality-gate.md +38 -0
  775. package/presets/mavis/next/ai-local/rules-library/task-levels.md +28 -0
  776. package/presets/mavis/next/ai-local/rules-library/ui-change-review-gate.md +15 -0
  777. package/presets/mavis/next/commands/task-continue.md +8 -0
  778. package/presets/mavis/next/commands/task.md +14 -1
  779. package/presets/mavis/next/rules/agent-team-intake.md +3 -0
  780. package/presets/mavis/next/rules/agent-team-orchestrator.md +23 -4
  781. package/presets/mavis/next/rules/ai-local-overlay.md +20 -2
  782. package/presets/mavis/next/rules/code-quality-and-refactoring.md +22 -3
  783. package/presets/mavis/next/rules/code-review-mr.md +21 -7
  784. package/presets/mavis/next/rules/component-catalog-gate.md +31 -0
  785. package/presets/mavis/next/rules/design-tokens-binding.md +24 -2
  786. package/presets/mavis/next/rules/feature-delivery-workflow.md +41 -19
  787. package/presets/mavis/next/rules/forms-validation.md +26 -0
  788. package/presets/mavis/next/rules/language-policy.md +43 -0
  789. package/presets/mavis/next/rules/mcp-usage.md +1 -0
  790. package/presets/mavis/next/rules/mockup-review.md +78 -2
  791. package/presets/mavis/next/rules/next-app-core.md +9 -0
  792. package/presets/mavis/next/rules/next-static-export.md +28 -0
  793. package/presets/mavis/next/rules/post-change-lint.md +4 -0
  794. package/presets/mavis/next/rules/preset-goals.md +31 -0
  795. package/presets/mavis/next/rules/preset-layering.md +1 -1
  796. package/presets/mavis/next/rules/preset-pr-checklist.md +4 -0
  797. package/presets/mavis/next/rules/preset-twin-sync.md +19 -77
  798. package/presets/mavis/next/rules/preset-writing-style.md +42 -0
  799. package/presets/mavis/next/rules/product-specs-authoring.md +1 -0
  800. package/presets/mavis/next/rules/product-specs.md +1 -0
  801. package/presets/mavis/next/rules/react-next-anti-hallucination.md +10 -0
  802. package/presets/mavis/next/rules/react-ui.md +19 -1
  803. package/presets/mavis/next/rules/reference-features.md +7 -2
  804. package/presets/mavis/next/rules/security-next.md +12 -0
  805. package/presets/mavis/next/rules/store-rtk.md +6 -0
  806. package/presets/mavis/next/rules/tests-e2e-structure.md +2 -1
  807. package/presets/mavis/next/rules/tests-unit.md +1 -0
  808. package/presets/mavis/next/skills/README.md +1 -0
  809. package/presets/mavis/next/skills/code-review/SKILL.md +1 -1
  810. package/presets/mavis/next/skills/figma-fidelity/SKILL.md +91 -0
  811. package/presets/mavis/next/skills/mockup-review/SKILL.md +5 -1
  812. package/presets/mavis/next/team/README.md +12 -0
  813. package/presets/mavis/next/team/fixtures/artifact-manifest.example.json +1 -1
  814. package/presets/mavis/next/team/fixtures/feature-with-ux-no-figma.json +3 -4
  815. package/presets/mavis/nuxt/REPO_AGENTS.md +3 -0
  816. package/presets/mavis/nuxt/adapter-map.json +30 -3
  817. package/presets/mavis/nuxt/agents/README.md +7 -0
  818. package/presets/mavis/nuxt/agents/build-verifier.md +12 -0
  819. package/presets/mavis/nuxt/agents/code-reviewer.md +12 -0
  820. package/presets/mavis/nuxt/agents/debugger.md +12 -0
  821. package/presets/mavis/nuxt/agents/feature-developer.md +12 -0
  822. package/presets/mavis/nuxt/agents/task-analyst.md +43 -2
  823. package/presets/mavis/nuxt/agents/task-router.md +8 -0
  824. package/presets/mavis/nuxt/ai-local/conventions.md +8 -0
  825. package/presets/mavis/nuxt/commands/task-continue.md +8 -0
  826. package/presets/mavis/nuxt/commands/task.md +14 -1
  827. package/presets/mavis/nuxt/rules/agent-team-intake.md +3 -0
  828. package/presets/mavis/nuxt/rules/agent-team-orchestrator.md +23 -4
  829. package/presets/mavis/nuxt/rules/ai-local-overlay.md +4 -0
  830. package/presets/mavis/nuxt/rules/code-quality-and-refactoring.md +20 -1
  831. package/presets/mavis/nuxt/rules/code-review-mr.md +6 -6
  832. package/presets/mavis/nuxt/rules/feature-delivery-workflow.md +30 -16
  833. package/presets/mavis/nuxt/rules/language-policy.md +43 -0
  834. package/presets/mavis/nuxt/rules/mockup-review.md +56 -1
  835. package/presets/mavis/nuxt/rules/nuxt-app-core.md +6 -0
  836. package/presets/mavis/nuxt/rules/preset-goals.md +31 -0
  837. package/presets/mavis/nuxt/rules/preset-layering.md +1 -1
  838. package/presets/mavis/nuxt/rules/preset-pr-checklist.md +4 -0
  839. package/presets/mavis/nuxt/rules/preset-twin-sync.md +19 -77
  840. package/presets/mavis/nuxt/rules/preset-writing-style.md +42 -0
  841. package/presets/mavis/nuxt/rules/reference-features.md +2 -2
  842. package/presets/mavis/nuxt/rules/tests-e2e-structure.md +1 -1
  843. package/presets/mavis/nuxt/team/README.md +11 -0
  844. package/presets/mavis/nuxt/team/fixtures/artifact-manifest.example.json +1 -1
  845. package/presets/mavis/php-hexagonal/REPO_AGENTS.md +3 -0
  846. package/presets/mavis/php-hexagonal/adapter-map.json +30 -3
  847. package/presets/mavis/php-hexagonal/agents/README.md +5 -0
  848. package/presets/mavis/php-hexagonal/agents/build-verifier.md +12 -0
  849. package/presets/mavis/php-hexagonal/agents/code-reviewer.md +12 -0
  850. package/presets/mavis/php-hexagonal/agents/debugger.md +12 -0
  851. package/presets/mavis/php-hexagonal/agents/feature-developer.md +12 -0
  852. package/presets/mavis/php-hexagonal/agents/task-analyst.md +31 -1
  853. package/presets/mavis/php-hexagonal/agents/task-router.md +8 -0
  854. package/presets/mavis/php-hexagonal/ai-local/conventions.md +8 -0
  855. package/presets/mavis/php-hexagonal/commands/task-continue.md +8 -0
  856. package/presets/mavis/php-hexagonal/commands/task.md +14 -1
  857. package/presets/mavis/php-hexagonal/rules/agent-team-intake.md +3 -0
  858. package/presets/mavis/php-hexagonal/rules/agent-team-orchestrator.md +23 -4
  859. package/presets/mavis/php-hexagonal/rules/ai-local-overlay.md +4 -0
  860. package/presets/mavis/php-hexagonal/rules/code-quality-and-refactoring.md +21 -2
  861. package/presets/mavis/php-hexagonal/rules/feature-delivery-workflow.md +11 -1
  862. package/presets/mavis/php-hexagonal/rules/language-policy.md +43 -0
  863. package/presets/mavis/php-hexagonal/rules/php-app-core.md +6 -0
  864. package/presets/mavis/php-hexagonal/rules/preset-goals.md +31 -0
  865. package/presets/mavis/php-hexagonal/rules/preset-layering.md +1 -1
  866. package/presets/mavis/php-hexagonal/rules/preset-pr-checklist.md +4 -0
  867. package/presets/mavis/php-hexagonal/rules/preset-twin-sync.md +19 -77
  868. package/presets/mavis/php-hexagonal/rules/preset-writing-style.md +42 -0
  869. package/presets/mavis/php-hexagonal/team/README.md +11 -0
  870. package/presets/mavis/php-laravel/REPO_AGENTS.md +3 -0
  871. package/presets/mavis/php-laravel/adapter-map.json +30 -3
  872. package/presets/mavis/php-laravel/agents/README.md +5 -0
  873. package/presets/mavis/php-laravel/agents/build-verifier.md +12 -0
  874. package/presets/mavis/php-laravel/agents/code-reviewer.md +12 -0
  875. package/presets/mavis/php-laravel/agents/debugger.md +12 -0
  876. package/presets/mavis/php-laravel/agents/feature-developer.md +12 -0
  877. package/presets/mavis/php-laravel/agents/task-analyst.md +31 -1
  878. package/presets/mavis/php-laravel/agents/task-router.md +8 -0
  879. package/presets/mavis/php-laravel/ai-local/conventions.md +8 -0
  880. package/presets/mavis/php-laravel/commands/task-continue.md +8 -0
  881. package/presets/mavis/php-laravel/commands/task.md +14 -1
  882. package/presets/mavis/php-laravel/rules/agent-team-intake.md +3 -0
  883. package/presets/mavis/php-laravel/rules/agent-team-orchestrator.md +23 -4
  884. package/presets/mavis/php-laravel/rules/ai-local-overlay.md +4 -0
  885. package/presets/mavis/php-laravel/rules/code-quality-and-refactoring.md +21 -2
  886. package/presets/mavis/php-laravel/rules/feature-delivery-workflow.md +11 -1
  887. package/presets/mavis/php-laravel/rules/language-policy.md +43 -0
  888. package/presets/mavis/php-laravel/rules/laravel-app-core.md +6 -0
  889. package/presets/mavis/php-laravel/rules/preset-goals.md +31 -0
  890. package/presets/mavis/php-laravel/rules/preset-layering.md +1 -1
  891. package/presets/mavis/php-laravel/rules/preset-pr-checklist.md +4 -0
  892. package/presets/mavis/php-laravel/rules/preset-twin-sync.md +19 -77
  893. package/presets/mavis/php-laravel/rules/preset-writing-style.md +42 -0
  894. package/presets/mavis/php-laravel/team/README.md +11 -0
  895. package/presets/mavis/svelte/REPO_AGENTS.md +3 -0
  896. package/presets/mavis/svelte/adapter-map.json +30 -3
  897. package/presets/mavis/svelte/agents/README.md +7 -0
  898. package/presets/mavis/svelte/agents/build-verifier.md +12 -0
  899. package/presets/mavis/svelte/agents/code-reviewer.md +12 -0
  900. package/presets/mavis/svelte/agents/debugger.md +12 -0
  901. package/presets/mavis/svelte/agents/feature-developer.md +12 -0
  902. package/presets/mavis/svelte/agents/task-analyst.md +43 -2
  903. package/presets/mavis/svelte/agents/task-router.md +8 -0
  904. package/presets/mavis/svelte/ai-local/conventions.md +8 -0
  905. package/presets/mavis/svelte/commands/task-continue.md +8 -0
  906. package/presets/mavis/svelte/commands/task.md +14 -1
  907. package/presets/mavis/svelte/rules/agent-team-intake.md +3 -0
  908. package/presets/mavis/svelte/rules/agent-team-orchestrator.md +23 -4
  909. package/presets/mavis/svelte/rules/ai-local-overlay.md +4 -0
  910. package/presets/mavis/svelte/rules/code-quality-and-refactoring.md +20 -1
  911. package/presets/mavis/svelte/rules/code-review-mr.md +6 -6
  912. package/presets/mavis/svelte/rules/feature-delivery-workflow.md +16 -2
  913. package/presets/mavis/svelte/rules/language-policy.md +43 -0
  914. package/presets/mavis/svelte/rules/mockup-review.md +56 -1
  915. package/presets/mavis/svelte/rules/preset-goals.md +31 -0
  916. package/presets/mavis/svelte/rules/preset-layering.md +1 -1
  917. package/presets/mavis/svelte/rules/preset-pr-checklist.md +4 -0
  918. package/presets/mavis/svelte/rules/preset-twin-sync.md +19 -77
  919. package/presets/mavis/svelte/rules/preset-writing-style.md +42 -0
  920. package/presets/mavis/svelte/rules/reference-features.md +2 -2
  921. package/presets/mavis/svelte/rules/svelte-app-core.md +6 -0
  922. package/presets/mavis/svelte/rules/tests-e2e-structure.md +1 -1
  923. package/presets/mavis/svelte/team/README.md +11 -0
  924. package/presets/mavis/svelte/team/fixtures/artifact-manifest.example.json +1 -1
  925. package/presets/opencode/android-kotlin/REPO_AGENTS.md +3 -0
  926. package/presets/opencode/android-kotlin/adapter-map.json +29 -2
  927. package/presets/opencode/android-kotlin/agents/README.md +7 -0
  928. package/presets/opencode/android-kotlin/agents/build-verifier.md +12 -0
  929. package/presets/opencode/android-kotlin/agents/code-reviewer.md +12 -0
  930. package/presets/opencode/android-kotlin/agents/debugger.md +12 -0
  931. package/presets/opencode/android-kotlin/agents/feature-developer.md +12 -0
  932. package/presets/opencode/android-kotlin/agents/task-analyst.md +31 -1
  933. package/presets/opencode/android-kotlin/agents/task-router.md +8 -0
  934. package/presets/opencode/android-kotlin/ai-local/conventions.md +8 -0
  935. package/presets/opencode/android-kotlin/commands/task-continue.md +8 -0
  936. package/presets/opencode/android-kotlin/commands/task.md +14 -1
  937. package/presets/opencode/android-kotlin/rules/agent-team-intake.md +3 -0
  938. package/presets/opencode/android-kotlin/rules/agent-team-orchestrator.md +23 -4
  939. package/presets/opencode/android-kotlin/rules/ai-local-overlay.md +4 -0
  940. package/presets/opencode/android-kotlin/rules/android-app-core.md +6 -0
  941. package/presets/opencode/android-kotlin/rules/code-quality-and-refactoring.md +20 -1
  942. package/presets/opencode/android-kotlin/rules/code-review-mr.md +6 -6
  943. package/presets/opencode/android-kotlin/rules/feature-delivery-workflow.md +4 -0
  944. package/presets/opencode/android-kotlin/rules/language-policy.md +43 -0
  945. package/presets/opencode/android-kotlin/rules/mockup-review.md +56 -1
  946. package/presets/opencode/android-kotlin/rules/preset-goals.md +31 -0
  947. package/presets/opencode/android-kotlin/rules/preset-layering.md +1 -1
  948. package/presets/opencode/android-kotlin/rules/preset-pr-checklist.md +4 -0
  949. package/presets/opencode/android-kotlin/rules/preset-twin-sync.md +19 -77
  950. package/presets/opencode/android-kotlin/rules/preset-writing-style.md +42 -0
  951. package/presets/opencode/android-kotlin/team/README.md +11 -0
  952. package/presets/opencode/go/REPO_AGENTS.md +3 -0
  953. package/presets/opencode/go/adapter-map.json +30 -3
  954. package/presets/opencode/go/agents/README.md +5 -0
  955. package/presets/opencode/go/agents/build-verifier.md +12 -0
  956. package/presets/opencode/go/agents/code-reviewer.md +12 -0
  957. package/presets/opencode/go/agents/debugger.md +12 -0
  958. package/presets/opencode/go/agents/feature-developer.md +12 -0
  959. package/presets/opencode/go/agents/task-analyst.md +31 -1
  960. package/presets/opencode/go/agents/task-router.md +8 -0
  961. package/presets/opencode/go/ai-local/conventions.md +8 -0
  962. package/presets/opencode/go/commands/task-continue.md +8 -0
  963. package/presets/opencode/go/commands/task.md +14 -1
  964. package/presets/opencode/go/rules/agent-team-intake.md +3 -0
  965. package/presets/opencode/go/rules/agent-team-orchestrator.md +23 -4
  966. package/presets/opencode/go/rules/ai-local-overlay.md +4 -0
  967. package/presets/opencode/go/rules/code-quality-and-refactoring.md +21 -2
  968. package/presets/opencode/go/rules/feature-delivery-workflow.md +11 -1
  969. package/presets/opencode/go/rules/go-app-core.md +6 -0
  970. package/presets/opencode/go/rules/language-policy.md +43 -0
  971. package/presets/opencode/go/rules/preset-goals.md +31 -0
  972. package/presets/opencode/go/rules/preset-layering.md +1 -1
  973. package/presets/opencode/go/rules/preset-pr-checklist.md +4 -0
  974. package/presets/opencode/go/rules/preset-twin-sync.md +19 -77
  975. package/presets/opencode/go/rules/preset-writing-style.md +42 -0
  976. package/presets/opencode/go/team/README.md +11 -0
  977. package/presets/opencode/ios-swift/REPO_AGENTS.md +3 -0
  978. package/presets/opencode/ios-swift/adapter-map.json +29 -2
  979. package/presets/opencode/ios-swift/agents/README.md +7 -0
  980. package/presets/opencode/ios-swift/agents/build-verifier.md +12 -0
  981. package/presets/opencode/ios-swift/agents/code-reviewer.md +12 -0
  982. package/presets/opencode/ios-swift/agents/debugger.md +12 -0
  983. package/presets/opencode/ios-swift/agents/feature-developer.md +12 -0
  984. package/presets/opencode/ios-swift/agents/task-analyst.md +31 -1
  985. package/presets/opencode/ios-swift/agents/task-router.md +8 -0
  986. package/presets/opencode/ios-swift/ai-local/conventions.md +8 -0
  987. package/presets/opencode/ios-swift/commands/task-continue.md +8 -0
  988. package/presets/opencode/ios-swift/commands/task.md +14 -1
  989. package/presets/opencode/ios-swift/rules/agent-team-intake.md +3 -0
  990. package/presets/opencode/ios-swift/rules/agent-team-orchestrator.md +23 -4
  991. package/presets/opencode/ios-swift/rules/ai-local-overlay.md +4 -0
  992. package/presets/opencode/ios-swift/rules/code-quality-and-refactoring.md +21 -2
  993. package/presets/opencode/ios-swift/rules/code-review-mr.md +6 -6
  994. package/presets/opencode/ios-swift/rules/feature-delivery-workflow.md +29 -15
  995. package/presets/opencode/ios-swift/rules/ios-app-core.md +6 -0
  996. package/presets/opencode/ios-swift/rules/language-policy.md +43 -0
  997. package/presets/opencode/ios-swift/rules/mockup-review.md +56 -1
  998. package/presets/opencode/ios-swift/rules/preset-goals.md +31 -0
  999. package/presets/opencode/ios-swift/rules/preset-layering.md +1 -1
  1000. package/presets/opencode/ios-swift/rules/preset-pr-checklist.md +4 -0
  1001. package/presets/opencode/ios-swift/rules/preset-twin-sync.md +19 -77
  1002. package/presets/opencode/ios-swift/rules/preset-writing-style.md +42 -0
  1003. package/presets/opencode/ios-swift/rules/reference-features.md +3 -3
  1004. package/presets/opencode/ios-swift/team/README.md +11 -0
  1005. package/presets/opencode/java/REPO_AGENTS.md +3 -0
  1006. package/presets/opencode/java/adapter-map.json +30 -3
  1007. package/presets/opencode/java/agents/README.md +5 -0
  1008. package/presets/opencode/java/agents/build-verifier.md +12 -0
  1009. package/presets/opencode/java/agents/code-reviewer.md +12 -0
  1010. package/presets/opencode/java/agents/debugger.md +12 -0
  1011. package/presets/opencode/java/agents/feature-developer.md +12 -0
  1012. package/presets/opencode/java/agents/task-analyst.md +31 -1
  1013. package/presets/opencode/java/agents/task-router.md +8 -0
  1014. package/presets/opencode/java/ai-local/conventions.md +8 -0
  1015. package/presets/opencode/java/commands/task-continue.md +8 -0
  1016. package/presets/opencode/java/commands/task.md +14 -1
  1017. package/presets/opencode/java/rules/agent-team-intake.md +3 -0
  1018. package/presets/opencode/java/rules/agent-team-orchestrator.md +23 -4
  1019. package/presets/opencode/java/rules/ai-local-overlay.md +4 -0
  1020. package/presets/opencode/java/rules/code-quality-and-refactoring.md +21 -2
  1021. package/presets/opencode/java/rules/feature-delivery-workflow.md +11 -1
  1022. package/presets/opencode/java/rules/java-app-core.md +6 -0
  1023. package/presets/opencode/java/rules/language-policy.md +43 -0
  1024. package/presets/opencode/java/rules/preset-goals.md +31 -0
  1025. package/presets/opencode/java/rules/preset-layering.md +1 -1
  1026. package/presets/opencode/java/rules/preset-pr-checklist.md +4 -0
  1027. package/presets/opencode/java/rules/preset-twin-sync.md +19 -77
  1028. package/presets/opencode/java/rules/preset-writing-style.md +42 -0
  1029. package/presets/opencode/java/team/README.md +11 -0
  1030. package/presets/opencode/mcp-ts/REPO_AGENTS.md +3 -0
  1031. package/presets/opencode/mcp-ts/adapter-map.json +28 -1
  1032. package/presets/opencode/mcp-ts/agents/README.md +7 -0
  1033. package/presets/opencode/mcp-ts/agents/build-verifier.md +12 -0
  1034. package/presets/opencode/mcp-ts/agents/feature-developer.md +12 -0
  1035. package/presets/opencode/mcp-ts/agents/task-analyst.md +31 -1
  1036. package/presets/opencode/mcp-ts/agents/task-router.md +8 -0
  1037. package/presets/opencode/mcp-ts/ai-local/conventions.md +8 -0
  1038. package/presets/opencode/mcp-ts/commands/task-continue.md +8 -0
  1039. package/presets/opencode/mcp-ts/commands/task.md +14 -1
  1040. package/presets/opencode/mcp-ts/rules/agent-team-intake.md +3 -0
  1041. package/presets/opencode/mcp-ts/rules/agent-team-orchestrator.md +23 -4
  1042. package/presets/opencode/mcp-ts/rules/ai-local-overlay.md +4 -0
  1043. package/presets/opencode/mcp-ts/rules/code-quality-and-refactoring.md +20 -1
  1044. package/presets/opencode/mcp-ts/rules/feature-delivery-workflow.md +11 -1
  1045. package/presets/opencode/mcp-ts/rules/language-policy.md +43 -0
  1046. package/presets/opencode/mcp-ts/rules/mcp-ts-app-core.md +6 -0
  1047. package/presets/opencode/mcp-ts/rules/preset-goals.md +31 -0
  1048. package/presets/opencode/mcp-ts/rules/preset-layering.md +1 -1
  1049. package/presets/opencode/mcp-ts/rules/preset-pr-checklist.md +4 -0
  1050. package/presets/opencode/mcp-ts/rules/preset-twin-sync.md +19 -77
  1051. package/presets/opencode/mcp-ts/rules/preset-writing-style.md +42 -0
  1052. package/presets/opencode/mcp-ts/team/README.md +11 -0
  1053. package/presets/opencode/next/REPO_AGENTS.md +14 -1
  1054. package/presets/opencode/next/adapter-map.json +229 -10
  1055. package/presets/opencode/next/agents/README.md +6 -0
  1056. package/presets/opencode/next/agents/build-verifier.md +13 -0
  1057. package/presets/opencode/next/agents/code-reviewer.md +24 -0
  1058. package/presets/opencode/next/agents/debugger.md +12 -0
  1059. package/presets/opencode/next/agents/feature-developer.md +21 -2
  1060. package/presets/opencode/next/agents/mockup-reviewer.md +25 -4
  1061. package/presets/opencode/next/agents/openspec-author.md +2 -0
  1062. package/presets/opencode/next/agents/task-analyst.md +50 -2
  1063. package/presets/opencode/next/agents/task-router.md +9 -0
  1064. package/presets/opencode/next/ai-local/conventions.md +8 -0
  1065. package/presets/opencode/next/ai-local/rules-library/agent-artifacts-no-local-paths.md +41 -8
  1066. package/presets/opencode/next/ai-local/rules-library/agent-pipeline-gates.md +19 -0
  1067. package/presets/opencode/next/ai-local/rules-library/analytics-events.md +18 -0
  1068. package/presets/opencode/next/ai-local/rules-library/api-contract-source.md +14 -0
  1069. package/presets/opencode/next/ai-local/rules-library/artifact-lifecycle.md +17 -0
  1070. package/presets/opencode/next/ai-local/rules-library/code-style.md +68 -0
  1071. package/presets/opencode/next/ai-local/rules-library/component-child-decomposition.md +81 -0
  1072. package/presets/opencode/next/ai-local/rules-library/feature-flags-experiments.md +15 -0
  1073. package/presets/opencode/next/ai-local/rules-library/mcp-required-for-ui-layout.md +5 -1
  1074. package/presets/opencode/next/ai-local/rules-library/no-react-fc.md +46 -0
  1075. package/presets/opencode/next/ai-local/rules-library/no-test-driven-behavior-change.md +1 -1
  1076. package/presets/opencode/next/ai-local/rules-library/pwa-service-worker.md +15 -0
  1077. package/presets/opencode/next/ai-local/rules-library/qa-test-cases.md +14 -0
  1078. package/presets/opencode/next/ai-local/rules-library/router-pages.md +4 -2
  1079. package/presets/opencode/next/ai-local/rules-library/single-source-copy-constants.md +3 -1
  1080. package/presets/opencode/next/ai-local/rules-library/storybook-catalog-structure.md +62 -0
  1081. package/presets/opencode/next/ai-local/rules-library/storybook-cleanup-temp-screenshots.md +40 -0
  1082. package/presets/opencode/next/ai-local/rules-library/storybook-csf-authoring.md +100 -0
  1083. package/presets/opencode/next/ai-local/rules-library/storybook-dev-compare-figma.md +71 -0
  1084. package/presets/opencode/next/ai-local/rules-library/storybook-keep-tests-current.md +75 -0
  1085. package/presets/opencode/next/ai-local/rules-library/storybook-modals.md +64 -0
  1086. package/presets/opencode/next/ai-local/rules-library/storybook-no-app-node-modules.md +40 -0
  1087. package/presets/opencode/next/ai-local/rules-library/storybook-ui-quality-gate.md +38 -0
  1088. package/presets/opencode/next/ai-local/rules-library/task-levels.md +28 -0
  1089. package/presets/opencode/next/ai-local/rules-library/ui-change-review-gate.md +15 -0
  1090. package/presets/opencode/next/commands/task-continue.md +8 -0
  1091. package/presets/opencode/next/commands/task.md +14 -1
  1092. package/presets/opencode/next/rules/agent-team-intake.md +3 -0
  1093. package/presets/opencode/next/rules/agent-team-orchestrator.md +23 -4
  1094. package/presets/opencode/next/rules/ai-local-overlay.md +20 -2
  1095. package/presets/opencode/next/rules/code-quality-and-refactoring.md +22 -3
  1096. package/presets/opencode/next/rules/code-review-mr.md +21 -7
  1097. package/presets/opencode/next/rules/component-catalog-gate.md +31 -0
  1098. package/presets/opencode/next/rules/design-tokens-binding.md +24 -2
  1099. package/presets/opencode/next/rules/feature-delivery-workflow.md +41 -19
  1100. package/presets/opencode/next/rules/forms-validation.md +26 -0
  1101. package/presets/opencode/next/rules/language-policy.md +43 -0
  1102. package/presets/opencode/next/rules/mcp-usage.md +1 -0
  1103. package/presets/opencode/next/rules/mockup-review.md +78 -2
  1104. package/presets/opencode/next/rules/next-app-core.md +9 -0
  1105. package/presets/opencode/next/rules/next-static-export.md +28 -0
  1106. package/presets/opencode/next/rules/post-change-lint.md +4 -0
  1107. package/presets/opencode/next/rules/preset-goals.md +31 -0
  1108. package/presets/opencode/next/rules/preset-layering.md +1 -1
  1109. package/presets/opencode/next/rules/preset-pr-checklist.md +4 -0
  1110. package/presets/opencode/next/rules/preset-twin-sync.md +19 -77
  1111. package/presets/opencode/next/rules/preset-writing-style.md +42 -0
  1112. package/presets/opencode/next/rules/product-specs-authoring.md +1 -0
  1113. package/presets/opencode/next/rules/product-specs.md +1 -0
  1114. package/presets/opencode/next/rules/react-next-anti-hallucination.md +10 -0
  1115. package/presets/opencode/next/rules/react-ui.md +19 -1
  1116. package/presets/opencode/next/rules/reference-features.md +7 -2
  1117. package/presets/opencode/next/rules/security-next.md +12 -0
  1118. package/presets/opencode/next/rules/store-rtk.md +6 -0
  1119. package/presets/opencode/next/rules/tests-e2e-structure.md +2 -1
  1120. package/presets/opencode/next/rules/tests-unit.md +1 -0
  1121. package/presets/opencode/next/skills/README.md +1 -0
  1122. package/presets/opencode/next/skills/code-review/SKILL.md +1 -1
  1123. package/presets/opencode/next/skills/figma-fidelity/SKILL.md +96 -0
  1124. package/presets/opencode/next/skills/mockup-review/SKILL.md +5 -1
  1125. package/presets/opencode/next/team/README.md +12 -0
  1126. package/presets/opencode/next/team/fixtures/artifact-manifest.example.json +1 -1
  1127. package/presets/opencode/next/team/fixtures/feature-with-ux-no-figma.json +3 -4
  1128. package/presets/opencode/nuxt/REPO_AGENTS.md +3 -0
  1129. package/presets/opencode/nuxt/adapter-map.json +30 -3
  1130. package/presets/opencode/nuxt/agents/README.md +7 -0
  1131. package/presets/opencode/nuxt/agents/build-verifier.md +12 -0
  1132. package/presets/opencode/nuxt/agents/code-reviewer.md +12 -0
  1133. package/presets/opencode/nuxt/agents/debugger.md +12 -0
  1134. package/presets/opencode/nuxt/agents/feature-developer.md +12 -0
  1135. package/presets/opencode/nuxt/agents/task-analyst.md +43 -2
  1136. package/presets/opencode/nuxt/agents/task-router.md +8 -0
  1137. package/presets/opencode/nuxt/ai-local/conventions.md +8 -0
  1138. package/presets/opencode/nuxt/commands/task-continue.md +8 -0
  1139. package/presets/opencode/nuxt/commands/task.md +14 -1
  1140. package/presets/opencode/nuxt/rules/agent-team-intake.md +3 -0
  1141. package/presets/opencode/nuxt/rules/agent-team-orchestrator.md +23 -4
  1142. package/presets/opencode/nuxt/rules/ai-local-overlay.md +4 -0
  1143. package/presets/opencode/nuxt/rules/code-quality-and-refactoring.md +20 -1
  1144. package/presets/opencode/nuxt/rules/code-review-mr.md +6 -6
  1145. package/presets/opencode/nuxt/rules/feature-delivery-workflow.md +30 -16
  1146. package/presets/opencode/nuxt/rules/language-policy.md +43 -0
  1147. package/presets/opencode/nuxt/rules/mockup-review.md +56 -1
  1148. package/presets/opencode/nuxt/rules/nuxt-app-core.md +6 -0
  1149. package/presets/opencode/nuxt/rules/preset-goals.md +31 -0
  1150. package/presets/opencode/nuxt/rules/preset-layering.md +1 -1
  1151. package/presets/opencode/nuxt/rules/preset-pr-checklist.md +4 -0
  1152. package/presets/opencode/nuxt/rules/preset-twin-sync.md +19 -77
  1153. package/presets/opencode/nuxt/rules/preset-writing-style.md +42 -0
  1154. package/presets/opencode/nuxt/rules/reference-features.md +2 -2
  1155. package/presets/opencode/nuxt/rules/tests-e2e-structure.md +1 -1
  1156. package/presets/opencode/nuxt/team/README.md +11 -0
  1157. package/presets/opencode/nuxt/team/fixtures/artifact-manifest.example.json +1 -1
  1158. package/presets/opencode/php-hexagonal/REPO_AGENTS.md +3 -0
  1159. package/presets/opencode/php-hexagonal/adapter-map.json +30 -3
  1160. package/presets/opencode/php-hexagonal/agents/README.md +5 -0
  1161. package/presets/opencode/php-hexagonal/agents/build-verifier.md +12 -0
  1162. package/presets/opencode/php-hexagonal/agents/code-reviewer.md +12 -0
  1163. package/presets/opencode/php-hexagonal/agents/debugger.md +12 -0
  1164. package/presets/opencode/php-hexagonal/agents/feature-developer.md +12 -0
  1165. package/presets/opencode/php-hexagonal/agents/task-analyst.md +31 -1
  1166. package/presets/opencode/php-hexagonal/agents/task-router.md +8 -0
  1167. package/presets/opencode/php-hexagonal/ai-local/conventions.md +8 -0
  1168. package/presets/opencode/php-hexagonal/commands/task-continue.md +8 -0
  1169. package/presets/opencode/php-hexagonal/commands/task.md +14 -1
  1170. package/presets/opencode/php-hexagonal/rules/agent-team-intake.md +3 -0
  1171. package/presets/opencode/php-hexagonal/rules/agent-team-orchestrator.md +23 -4
  1172. package/presets/opencode/php-hexagonal/rules/ai-local-overlay.md +4 -0
  1173. package/presets/opencode/php-hexagonal/rules/code-quality-and-refactoring.md +21 -2
  1174. package/presets/opencode/php-hexagonal/rules/feature-delivery-workflow.md +11 -1
  1175. package/presets/opencode/php-hexagonal/rules/language-policy.md +43 -0
  1176. package/presets/opencode/php-hexagonal/rules/php-app-core.md +6 -0
  1177. package/presets/opencode/php-hexagonal/rules/preset-goals.md +31 -0
  1178. package/presets/opencode/php-hexagonal/rules/preset-layering.md +1 -1
  1179. package/presets/opencode/php-hexagonal/rules/preset-pr-checklist.md +4 -0
  1180. package/presets/opencode/php-hexagonal/rules/preset-twin-sync.md +19 -77
  1181. package/presets/opencode/php-hexagonal/rules/preset-writing-style.md +42 -0
  1182. package/presets/opencode/php-hexagonal/team/README.md +11 -0
  1183. package/presets/opencode/php-laravel/REPO_AGENTS.md +3 -0
  1184. package/presets/opencode/php-laravel/adapter-map.json +30 -3
  1185. package/presets/opencode/php-laravel/agents/README.md +5 -0
  1186. package/presets/opencode/php-laravel/agents/build-verifier.md +12 -0
  1187. package/presets/opencode/php-laravel/agents/code-reviewer.md +12 -0
  1188. package/presets/opencode/php-laravel/agents/debugger.md +12 -0
  1189. package/presets/opencode/php-laravel/agents/feature-developer.md +12 -0
  1190. package/presets/opencode/php-laravel/agents/task-analyst.md +31 -1
  1191. package/presets/opencode/php-laravel/agents/task-router.md +8 -0
  1192. package/presets/opencode/php-laravel/ai-local/conventions.md +8 -0
  1193. package/presets/opencode/php-laravel/commands/task-continue.md +8 -0
  1194. package/presets/opencode/php-laravel/commands/task.md +14 -1
  1195. package/presets/opencode/php-laravel/rules/agent-team-intake.md +3 -0
  1196. package/presets/opencode/php-laravel/rules/agent-team-orchestrator.md +23 -4
  1197. package/presets/opencode/php-laravel/rules/ai-local-overlay.md +4 -0
  1198. package/presets/opencode/php-laravel/rules/code-quality-and-refactoring.md +21 -2
  1199. package/presets/opencode/php-laravel/rules/feature-delivery-workflow.md +11 -1
  1200. package/presets/opencode/php-laravel/rules/language-policy.md +43 -0
  1201. package/presets/opencode/php-laravel/rules/laravel-app-core.md +6 -0
  1202. package/presets/opencode/php-laravel/rules/preset-goals.md +31 -0
  1203. package/presets/opencode/php-laravel/rules/preset-layering.md +1 -1
  1204. package/presets/opencode/php-laravel/rules/preset-pr-checklist.md +4 -0
  1205. package/presets/opencode/php-laravel/rules/preset-twin-sync.md +19 -77
  1206. package/presets/opencode/php-laravel/rules/preset-writing-style.md +42 -0
  1207. package/presets/opencode/php-laravel/team/README.md +11 -0
  1208. package/presets/opencode/svelte/REPO_AGENTS.md +3 -0
  1209. package/presets/opencode/svelte/adapter-map.json +30 -3
  1210. package/presets/opencode/svelte/agents/README.md +7 -0
  1211. package/presets/opencode/svelte/agents/build-verifier.md +12 -0
  1212. package/presets/opencode/svelte/agents/code-reviewer.md +12 -0
  1213. package/presets/opencode/svelte/agents/debugger.md +12 -0
  1214. package/presets/opencode/svelte/agents/feature-developer.md +12 -0
  1215. package/presets/opencode/svelte/agents/task-analyst.md +43 -2
  1216. package/presets/opencode/svelte/agents/task-router.md +8 -0
  1217. package/presets/opencode/svelte/ai-local/conventions.md +8 -0
  1218. package/presets/opencode/svelte/commands/task-continue.md +8 -0
  1219. package/presets/opencode/svelte/commands/task.md +14 -1
  1220. package/presets/opencode/svelte/rules/agent-team-intake.md +3 -0
  1221. package/presets/opencode/svelte/rules/agent-team-orchestrator.md +23 -4
  1222. package/presets/opencode/svelte/rules/ai-local-overlay.md +4 -0
  1223. package/presets/opencode/svelte/rules/code-quality-and-refactoring.md +20 -1
  1224. package/presets/opencode/svelte/rules/code-review-mr.md +6 -6
  1225. package/presets/opencode/svelte/rules/feature-delivery-workflow.md +16 -2
  1226. package/presets/opencode/svelte/rules/language-policy.md +43 -0
  1227. package/presets/opencode/svelte/rules/mockup-review.md +56 -1
  1228. package/presets/opencode/svelte/rules/preset-goals.md +31 -0
  1229. package/presets/opencode/svelte/rules/preset-layering.md +1 -1
  1230. package/presets/opencode/svelte/rules/preset-pr-checklist.md +4 -0
  1231. package/presets/opencode/svelte/rules/preset-twin-sync.md +19 -77
  1232. package/presets/opencode/svelte/rules/preset-writing-style.md +42 -0
  1233. package/presets/opencode/svelte/rules/reference-features.md +2 -2
  1234. package/presets/opencode/svelte/rules/svelte-app-core.md +6 -0
  1235. package/presets/opencode/svelte/rules/tests-e2e-structure.md +1 -1
  1236. package/presets/opencode/svelte/team/README.md +11 -0
  1237. package/presets/opencode/svelte/team/fixtures/artifact-manifest.example.json +1 -1
  1238. package/scripts/_lib/embed-stems.json +8 -1
  1239. package/scripts/check-figma-contract-presence.sh +119 -0
  1240. package/scripts/check-generated-drift.mjs +42 -2
  1241. package/scripts/check-local-overlay.sh +39 -0
  1242. package/scripts/check-plan-contract.sh +133 -0
  1243. package/scripts/check-preset-goal-contract.sh +214 -0
  1244. package/scripts/check-preset-language-policy.sh +292 -0
  1245. package/scripts/check-preset-prompt-persistence.sh +191 -0
  1246. package/scripts/check-preset-self-review-contract.sh +179 -0
  1247. package/scripts/check-preset-structure.sh +51 -0
  1248. package/scripts/check-preset-token-budget.sh +3 -0
  1249. package/scripts/fixtures/cli-golden/claude/next.json +63 -56
  1250. package/scripts/fixtures/cli-golden/cursor/next.json +88 -61
  1251. package/scripts/fixtures/cli-golden/mavis/android-kotlin.json +39 -36
  1252. package/scripts/fixtures/cli-golden/mavis/go.json +25 -22
  1253. package/scripts/fixtures/cli-golden/mavis/ios-swift.json +29 -26
  1254. package/scripts/fixtures/cli-golden/mavis/java.json +25 -22
  1255. package/scripts/fixtures/cli-golden/mavis/mcp-ts.json +22 -19
  1256. package/scripts/fixtures/cli-golden/mavis/next.json +87 -60
  1257. package/scripts/fixtures/cli-golden/mavis/nuxt.json +43 -40
  1258. package/scripts/fixtures/cli-golden/mavis/php-hexagonal.json +25 -22
  1259. package/scripts/fixtures/cli-golden/mavis/php-laravel.json +25 -22
  1260. package/scripts/fixtures/cli-golden/mavis/svelte.json +43 -40
  1261. package/scripts/fixtures/cli-golden/opencode/android-kotlin.json +39 -36
  1262. package/scripts/fixtures/cli-golden/opencode/go.json +25 -22
  1263. package/scripts/fixtures/cli-golden/opencode/ios-swift.json +29 -26
  1264. package/scripts/fixtures/cli-golden/opencode/java.json +25 -22
  1265. package/scripts/fixtures/cli-golden/opencode/mcp-ts.json +22 -19
  1266. package/scripts/fixtures/cli-golden/opencode/next.json +87 -60
  1267. package/scripts/fixtures/cli-golden/opencode/nuxt.json +43 -40
  1268. package/scripts/fixtures/cli-golden/opencode/php-hexagonal.json +25 -22
  1269. package/scripts/fixtures/cli-golden/opencode/php-laravel.json +25 -22
  1270. package/scripts/fixtures/cli-golden/opencode/svelte.json +43 -40
  1271. package/scripts/lib/generate-adapter-common.mjs +17 -0
  1272. package/scripts/lib/generate-mavis-adapter.mjs +9 -3
  1273. package/scripts/lib/generate-opencode-adapter.mjs +9 -3
  1274. package/scripts/test-plan-contract-fixtures.mjs +132 -0
  1275. package/scripts/test-preset-goal-contract-fixtures.mjs +162 -0
  1276. package/scripts/test-preset-language-policy-fixtures.mjs +194 -0
  1277. package/scripts/test-preset-prompt-persistence-fixtures.mjs +175 -0
  1278. package/scripts/test-preset-self-review-contract-fixtures.mjs +163 -0
@@ -11,98 +11,40 @@ paths:
11
11
 
12
12
  # Preset twin sync
13
13
 
14
- Cursor `.mdc` — **SoT per stack**. Claude topic `.md` — derived twin.
14
+ Cursor `.mdc` is the **SoT per stack**; every other platform tree is derived in the **same PR**.
15
15
 
16
- ## Matrix
16
+ ## Derivations
17
17
 
18
- | Stack | Cursor SoT | Claude derive | Mapping table |
19
- |-------|------------|---------------|---------------|
20
- | `next` | `presets/cursor/next/rules/*.mdc` | `presets/claude/next/rules/<topic>/` | **Required** in `claude/next/rules/README.md` |
21
- | `nuxt` | `presets/cursor/nuxt/rules/*.mdc` | `presets/claude/nuxt/rules/<topic>/` | **Required** in `claude/nuxt/rules/README.md` |
22
- | `svelte` | `presets/cursor/svelte/rules/*.mdc` | `presets/claude/svelte/rules/<topic>/` | **Required** in `claude/svelte/rules/README.md` |
23
- | `ios-swift` | `presets/cursor/ios-swift/rules/*.mdc` | `presets/claude/ios-swift/rules/<topic>/` | Keep in `claude/ios-swift/rules/README.md` |
24
- | `go` | `presets/cursor/go/rules/*.mdc` | `presets/claude/go/rules/<topic>/` | Keep in `claude/go/rules/README.md` |
25
- | `java` | `presets/cursor/java/rules/*.mdc` | `presets/claude/java/rules/<topic>/` | Keep in `claude/java/rules/README.md` |
26
- | `mcp-ts` | `presets/cursor/mcp-ts/rules/*.mdc` | `presets/claude/mcp-ts/rules/<topic>/` | Keep in `claude/mcp-ts/rules/README.md` |
27
- | `php-hexagonal` | `presets/cursor/php-hexagonal/rules/*.mdc` | `presets/claude/php-hexagonal/rules/<topic>/` | Keep in `claude/php-hexagonal/rules/README.md` |
28
- | `php-laravel` | `presets/cursor/php-laravel/rules/*.mdc` | `presets/claude/php-laravel/rules/<topic>/` | Keep in `claude/php-laravel/rules/README.md` |
29
- | `android-kotlin` | `presets/cursor/android-kotlin/rules/*.mdc` | `presets/claude/android-kotlin/rules/<topic>/` | Keep in `claude/android-kotlin/rules/README.md` |
18
+ | Target | From | Command / rule |
19
+ |--------|------|----------------|
20
+ | **Claude twin** | `cursor/<stack>/rules/*.mdc` | hand-derived: body + `paths:` (from `globs:`), drop `alwaysApply`; row **required** in `claude/<stack>/rules/README.md` |
21
+ | **Mavis** | `cursor/<stack>/**` | `generate-mavis.mjs --stack <stack>`; manifest `adapter-map.json` required |
22
+ | **OpenCode** | `cursor/<stack>/**` | `generate-opencode.mjs --stack <stack>`; manifest `adapter-map.json` required |
30
23
 
31
- ## Mavis derivation (not a Claude twin)
32
-
33
- | Stack | Cursor SoT | Mavis derive | Manifest |
34
- |-------|------------|--------------|----------|
35
- | `next` | `presets/cursor/next/**` | `presets/mavis/next/**` via `generate-mavis.mjs --stack next` | **Required** `adapter-map.json` |
36
- | `nuxt` | `presets/cursor/nuxt/**` | `presets/mavis/nuxt/**` via `generate-mavis.mjs --stack nuxt` | **Required** `adapter-map.json` |
37
- | `svelte` | `presets/cursor/svelte/**` | `presets/mavis/svelte/**` via `generate-mavis.mjs --stack svelte` | **Required** `adapter-map.json` |
38
- | `ios-swift` | `presets/cursor/ios-swift/**` | `presets/mavis/ios-swift/**` via `generate-mavis.mjs --stack ios-swift` | **Required** `adapter-map.json` |
39
- | `android-kotlin` | `presets/cursor/android-kotlin/**` | `presets/mavis/android-kotlin/**` via `generate-mavis.mjs --stack android-kotlin` | **Required** `adapter-map.json` |
40
- | `go` | `presets/cursor/go/**` | `presets/mavis/go/**` via `generate-mavis.mjs --stack go` | **Required** `adapter-map.json` |
41
- | `java` | `presets/cursor/java/**` | `presets/mavis/java/**` via `generate-mavis.mjs --stack java` | **Required** `adapter-map.json` |
42
- | `mcp-ts` | `presets/cursor/mcp-ts/**` | `presets/mavis/mcp-ts/**` via `generate-mavis.mjs --stack mcp-ts` | **Required** `adapter-map.json` |
43
- | `php-hexagonal` | `presets/cursor/php-hexagonal/**` | `presets/mavis/php-hexagonal/**` via `generate-mavis.mjs --stack php-hexagonal` | **Required** `adapter-map.json` |
44
- | `php-laravel` | `presets/cursor/php-laravel/**` | `presets/mavis/php-laravel/**` via `generate-mavis.mjs --stack php-laravel` | **Required** `adapter-map.json` |
45
-
46
- Mavis is a **third platform adapter**, not a Claude-style topic twin:
47
-
48
- ```text
49
- _shared/core → cursor/<stack> → mavis/<stack>
50
- ```
51
-
52
- Regenerate with `node packages/ai-rules/scripts/generate-mavis.mjs --stack <stack>`; validate with `node packages/ai-rules/scripts/check-mavis-adapter-map.mjs`.
53
-
54
- ## OpenCode derivation (not a Claude twin)
55
-
56
- | Stack | Cursor SoT | OpenCode derive | Manifest |
57
- |-------|------------|-----------------|----------|
58
- | `next` | `presets/cursor/next/**` | `presets/opencode/next/**` via `generate-opencode.mjs --stack next` | **Required** `adapter-map.json` |
59
- | `nuxt` | `presets/cursor/nuxt/**` | `presets/opencode/nuxt/**` via `generate-opencode.mjs --stack nuxt` | **Required** `adapter-map.json` |
60
- | `svelte` | `presets/cursor/svelte/**` | `presets/opencode/svelte/**` via `generate-opencode.mjs --stack svelte` | **Required** `adapter-map.json` |
61
- | `ios-swift` | `presets/cursor/ios-swift/**` | `presets/opencode/ios-swift/**` via `generate-opencode.mjs --stack ios-swift` | **Required** `adapter-map.json` |
62
- | `android-kotlin` | `presets/cursor/android-kotlin/**` | `presets/opencode/android-kotlin/**` via `generate-opencode.mjs --stack android-kotlin` | **Required** `adapter-map.json` |
63
- | `go` | `presets/cursor/go/**` | `presets/opencode/go/**` via `generate-opencode.mjs --stack go` | **Required** `adapter-map.json` |
64
- | `java` | `presets/cursor/java/**` | `presets/opencode/java/**` via `generate-opencode.mjs --stack java` | **Required** `adapter-map.json` |
65
- | `mcp-ts` | `presets/cursor/mcp-ts/**` | `presets/opencode/mcp-ts/**` via `generate-opencode.mjs --stack mcp-ts` | **Required** `adapter-map.json` |
66
- | `php-hexagonal` | `presets/cursor/php-hexagonal/**` | `presets/opencode/php-hexagonal/**` via `generate-opencode.mjs --stack php-hexagonal` | **Required** `adapter-map.json` |
67
- | `php-laravel` | `presets/cursor/php-laravel/**` | `presets/opencode/php-laravel/**` via `generate-opencode.mjs --stack php-laravel` | **Required** `adapter-map.json` |
68
-
69
- OpenCode is a **fourth platform adapter** with a **native** install root (`.opencode/`), not a Claude-style topic twin and not an owned overlay like `.mavis/`:
24
+ All 10 stacks: `next`, `nuxt`, `svelte`, `ios-swift`, `android-kotlin`, `go`, `java`, `mcp-ts`, `php-hexagonal`, `php-laravel`. Mavis and OpenCode are **platform adapters**, not Claude-style topic twins; never derive OpenCode from Claude.
70
25
 
71
26
  ```text
72
- _shared/core → cursor/<stack> → opencode/<stack>
27
+ _shared/core → cursor/<stack> → { claude/<stack>, mavis/<stack>, opencode/<stack> }
73
28
  ```
74
29
 
75
- Regenerate with `node packages/ai-rules/scripts/generate-opencode.mjs --stack <stack>`; validate with `node packages/ai-rules/scripts/check-opencode-adapter-map.mjs`. Do not derive OpenCode sources from Claude.
30
+ Validate: `check-mavis-adapter-map.mjs`, `check-opencode-adapter-map.mjs`, `check-shared-core-drift.sh`.
76
31
 
77
32
  ## Same-PR checklist
78
33
 
79
- 1. Edit Cursor rule first (body + frontmatter).
80
- 2. Update Claude twin: body + `paths:` (from Cursor `globs:` / requestable triggers); drop `alwaysApply`.
81
- 3. Update mapping table row if stem/path changed.
82
- 4. If body embeds core (`<!-- shared-core: … -->`), sync core consumers across stacks when core changed.
83
- 5. When mapped `cursor/<stack>/` sources change, regenerate `mavis/<stack>/` and refresh `adapter-map.json` `sourceRevision` in the **same PR** (run `generate-mavis.mjs --stack <stack>` + `check-mavis-adapter-map.mjs`).
84
- 6. When mapped `cursor/<stack>/` sources change, regenerate `opencode/<stack>/` and refresh `adapter-map.json` `sourceRevision` in the **same PR** (run `generate-opencode.mjs --stack <stack>` + `check-opencode-adapter-map.mjs`).
34
+ 1. Edit the Cursor rule first (body + frontmatter).
35
+ 2. Update the Claude twin (body + `paths:`); update the README mapping row if the stem/path changed.
36
+ 3. Core changed → sync every `<!-- shared-core: … -->` consumer (`sync-shared-core-embeds.sh`).
37
+ 4. Cursor source changed → regenerate `mavis/<stack>/` and `opencode/<stack>/` and refresh each `adapter-map.json` `sourceRevision`.
85
38
 
86
39
  ## Twin depth
87
40
 
88
- - **Domain** rules: ≥15 body lines (FAIL if thin without documented alias reason).
41
+ - **Domain** rules: ≥15 body lines (FAIL if thin without a documented alias reason).
89
42
  - **Thin aliases** (`agent-team-intake`, `technical-retro`): may be shorter (soft) if they only point to a command/skill.
90
- - **Slim-companion rules** (UI-edit bundle, slim app-cores, slim tooling): may be shorter than 15 lines **if and only if** the body is a pointer into shared-core / stack-prose (no standalone prose). Examples live in stack `rules/README.md` (e.g. `cursor/next/rules/README.md` "UI-edit bundle" intent).
91
- - Mechanical enforcement lives in `packages/ai-rules/scripts/check-preset-token-budget.sh` — see `SLIM_COMPANION_ALLOWLIST` (the 53 stems accepted as slim pointers) and `MIN_SLIM_BODY_LINES` (5-line floor). Slim-companion rules with a body of 6–14 lines whose stem is **not** in the allowlist are reported as slim violations by the script.
43
+ - **Slim-companion rules** (UI-edit bundle, slim app-cores, slim tooling): may be shorter only if the body is a pointer into shared-core / stack prose. `check-preset-token-budget.sh` enforces this via `SLIM_COMPANION_ALLOWLIST` and the 5-line floor; 6–14-line stems outside the allow-list are slim violations.
92
44
 
93
45
  ## Severity (build-verifier)
94
46
 
95
- - **next:** missing Claude twin for a changed Cursor rule → **FAIL** (mapping table required).
96
- - **nuxt:** missing Claude twin for a changed Cursor rule → **FAIL** (mapping table required).
97
- - **svelte:** missing Claude twin for a changed Cursor rule → **FAIL** (mapping table required).
98
- - **ios-swift:** missing Claude twin for a changed Cursor rule → **FAIL**.
99
- - **go:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift; mapping table required).
100
- - **java:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go; mapping table required).
101
- - **mcp-ts:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java; mapping table required).
102
- - **php-hexagonal:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java / mcp-ts; mapping table required).
103
- - **php-laravel:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java / mcp-ts / php-hexagonal; mapping table required).
104
- - **android-kotlin:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java / mcp-ts / php-*; mapping table required).
105
- - **mavis/<stack>:** `cursor/<stack>` mapped source changed without mavis regeneration / `adapter-map.json` `sourceRevision` drift → **FAIL** (`check-mavis-adapter-map.mjs`).
106
- - **opencode/<stack>:** `cursor/<stack>` mapped source changed without opencode regeneration / `adapter-map.json` `sourceRevision` drift → **FAIL** (`check-opencode-adapter-map.mjs`).
47
+ - Missing Claude twin for a changed Cursor rule → **FAIL** (all 10 stacks; mapping table required).
48
+ - `cursor/<stack>` mapped source changed without mavis / opencode regeneration, or with `adapter-map.json` `sourceRevision` drift → **FAIL**.
107
49
 
108
- Dogfood: sync packages → root `.cursor/` after Cursor SoT changes (not the reverse). Use `packages/ai-rules/scripts/sync-dogfood-cursor.sh`.
50
+ Dogfood: sync packages → root `.cursor/` after Cursor SoT changes (never the reverse): `sync-dogfood-cursor.sh`.
@@ -0,0 +1,51 @@
1
+ ---
2
+ description: "Preset authoring: concise, no-demagogy prose for preset rules, docs, and artifacts. Use when editing packages/ai-rules/presets/**."
3
+ paths:
4
+ - packages/ai-rules/presets/**/*
5
+ - .claude/**/*
6
+ - .cursor/rules/**/*
7
+ - .ai.local/team/tasks/**/*
8
+ ---
9
+
10
+ <!-- shared-core: meta/preset-writing-style.md -->
11
+
12
+ # Preset writing style
13
+
14
+ Rules for **preset authors** (`packages/ai-rules/presets/**`). Requestable; not always-on in consumer apps.
15
+
16
+ Write for two readers at once: an **agent** loading one file out of context, and a **human** scanning for the rule. State the rule, not the motivation.
17
+
18
+ ## Do
19
+
20
+ - One rule per line: imperative and testable (`Do X` / `Never Y`), not "it is important that X".
21
+ - Lead with the rule; state *what* before *why*.
22
+ - Keep the *why* only when it changes behavior — a hidden constraint or the failure it prevents. Drop it when the rule already implies it.
23
+ - Be concrete: name the file, command, symbol, or counter-example.
24
+ - Prefer a table or short list to a paragraph; one idea per bullet.
25
+ - Reuse the shared vocabulary (rule stems, `always-on`, `requestable`, `must` / `should` / `may`) — see the `PRESET-ENGLISH-STYLE` glossary.
26
+ - Delete any sentence that carries no instruction.
27
+
28
+ ## Don't (demagogy)
29
+
30
+ - No filler, hedging, or motivational prose.
31
+ - No restating the heading, the rule, or a sibling rule.
32
+ - No emphasis inflation — bold / `must` / `never` only for a hard gate, not the whole page.
33
+ - No selling, urgency, or self-congratulation; no "best practice" without the failure it prevents.
34
+ - No scenario storytelling, rhetorical questions, or meta-narration ("this section explains…").
35
+ - No duplicated rule text across stems — link instead.
36
+
37
+ ## Size
38
+
39
+ - Shortest form that still changes behavior: if a bullet fits as a clause, make it a clause.
40
+ - 12+ undifferentiated bullets → split or rank; do not append.
41
+
42
+ ## Applies to
43
+
44
+ All preset prose: `_shared/core/**`, stack rules, agents, skills, commands, hook comments, and preset-facing docs (`packages/ai-rules/docs/**`, READMEs).
45
+
46
+ ## See also
47
+
48
+ - `preset-goals` — why presets exist.
49
+ - `preset-token-budget` — the caps this style keeps in range.
50
+ - `code-quality-and-refactoring` § Comments & prose — the consumer-side clause.
51
+ - `packages/ai-rules/docs/PRESET-ENGLISH-STYLE.md` — language, glossary, modality.
@@ -16,6 +16,7 @@ Shared `/task` runtime for Cursor, Claude, Mavis, and OpenCode. Seeded at **`.ai
16
16
  status.json # hook-owned lifecycle
17
17
  metrics.json # hook-owned append-only ledger
18
18
  artifact-manifest.json # producer receipts
19
+ prompt.md # verbatim original ask + resolved `language: <BCP-47>` header (write-if-absent; write point = /task Slug bootstrap; path on the routing entry)
19
20
  brief.md, decomposition.md, implementation.md, review.md, …
20
21
  .memlog.md # optional agent notes (hook does not parse)
21
22
  ```
@@ -75,3 +76,19 @@ Same JSON on Claude, Mavis, or OpenCode: `bash .<tool>/hooks/chain-team-phases.s
75
76
  - Manifest schema: shared core `agent-team/agent-artifact-contracts.md`. Read it first; producers upsert only their IDs.
76
77
  - Metrics: append-only allowlisted events — `agent-team/agent-task-metrics.md`. Aggregate: `node packages/ai-rules/scripts/aggregate-agent-task-metrics.mjs --team-root .ai.local/team`.
77
78
  - Commit `.ai.local/team/` templates (and slugs if you want them in clones).
79
+
80
+ ## Plan graph & checkpoint (optional)
81
+
82
+ `decomposition.md` is a dependency graph: every task carries `dependsOn[]`; the artifact holds a DAG (critical path + parallelizable groups) and, for large flows, epics/stages with exit criteria (`## Epics / stages`); `## Plan revision` tracks replans (`rev: N`).
83
+
84
+ `pipeline.json` MAY carry these additive, **hook-ignored** fields (schema v1 ignores unknown fields; the hook never parses them): `epics[]` (staging + exit criteria), `planRevision` (current plan rev), `contextBudget` (budget / checkpoint note).
85
+
86
+ **Checkpoint / resume:** progress is checkpointed to `tasks/<slug>/.memlog.md` (`## <date>` + `event:` entries) and the `artifact-manifest.json` `implementation` entry (`authoritativePaths`). A resumed run reads both and continues at the first stage whose exit criteria are unmet.
87
+
88
+ **Self-review / re-anchor:** each producing agent records a `## Self-review` block in the artifact it owns (`brief.md` / `implementation.md` / `debug-report.md` / `validation-report.md` / `review.md`) and, on detected context loss / excess, a re-anchor line in `.memlog.md` — `event:` (no plan change) or `decision: replan rev N → N+1` (plan change). No hook/lifecycle field is added.
89
+
90
+ ## Contracts
91
+
92
+ - Manifest schema: shared core `agent-team/agent-artifact-contracts.md`. Read it first; producers upsert only their IDs.
93
+ - Metrics: append-only allowlisted events — `agent-team/agent-task-metrics.md`. Aggregate: `node packages/ai-rules/scripts/aggregate-agent-task-metrics.mjs --team-root .ai.local/team`.
94
+ - Commit `.ai.local/team/` templates (and slugs if you want them in clones).
@@ -7,6 +7,9 @@ Cross-tool repo-root guide. Tool-specific maps stay under `.cursor/AGENTS.md`, `
7
7
  - Treat this file as the **shared** entry for any agent (Cursor, Claude Code, Mavis, OpenCode, or other).
8
8
  - All four platforms ship **the same** root file. `init` overwrites it; content does not depend on which tool ran last.
9
9
  - Tool maps (agent-team tables, slash commands) live in `.cursor/AGENTS.md` / `.claude/CLAUDE.md` / `.mavis/AGENTS.md` / `.opencode/AGENTS.md` — use them when that tool is installed.
10
+ - **Language.** Keep development, reasoning, and artifacts in **English**; answer the user in their
11
+ **native language** (`.ai.local/conventions.md` `## Language`, else the prompt language, else English) for
12
+ every question, gate prompt, status, and summary — see the `language-policy` rule.
10
13
  - Install:
11
14
 
12
15
  ```bash
@@ -43,6 +46,8 @@ Working directory for app scripts: **`app/`**. Detect the package manager from l
43
46
 
44
47
  After code edits: invoke **`post-change-lint`** (requestable). Full gate: agent `build-verifier`.
45
48
 
49
+ Repositories with more than one package (e.g. `app/` + `storybook/`) run each package's own scripts from its own directory; do not conflate runners.
50
+
46
51
  ## Security basics
47
52
 
48
53
  - Do not commit secrets (`.env`, tokens, credentials).
@@ -65,10 +70,18 @@ Skills: `.cursor/skills/`, `.claude/skills/`, `.mavis/skills/`, or `.opencode/sk
65
70
 
66
71
  Gotchas, local patterns, and team decisions: **`.ai.local/conventions.md`** (fill after init; `init` does not overwrite it).
67
72
 
73
+ ## Seed library (`.ai.local/rules-library/`)
74
+
75
+ `init` seeds **staged-inactive** rule templates here (Cursor `.mdc` sources analog: `presets/cursor/next/ai-local/rules-library/**`). They are **not** active until moved into `.ai.local/rules/`. When a seed matches the task scope, apply it and tell the owner to move it. Typical seeds: `router-pages` (Pages Router override), `no-react-fc`, `component-child-decomposition`, `single-source-copy-constants`, `commit-hygiene`, `pre-pr-checklist`, `api-contract-source`, `agent-pipeline-gates`, `task-levels`, `analytics-events`, `feature-flags-experiments`, `pwa-service-worker`, `qa-test-cases`, `forms-validation`, and the `storybook-*` set.
76
+
77
+ ## Managed vs preserved
78
+
79
+ `init` owns `.cursor/**`, `.claude/**`, `.mavis/**`, `.opencode/**`, root `AGENTS.md`, and the tool MCP config; it **overwrites/merges** them. Durable project config and authoritative specs belong **outside** those trees: `.ai.local/**`, `.ai/context/**`, `docs/specs/**`, `openspec/**`, repo-root `.mcp.json`. After a re-init, re-check any consumer-owned block added to a managed file.
80
+
68
81
  ## Local overlay (`.ai.local/`) — MANDATORY
69
82
 
70
83
  A `.ai.local/` directory MAY exist at the repo root or at any nesting depth in monorepos. **All agents MUST read and apply it on every turn.** Rules there override preset rules; in conflicts, the local rule wins. `override: kill <preset-rule-name>` drops the named preset rule from the agent's context entirely.
71
84
 
72
- Plain markdown rules under `.ai.local/rules/*.md` are read by the agent with higher priority than preset rules. Living gotchas live in `.ai.local/conventions.md`.
85
+ Plain markdown rules under `.ai.local/rules/*.md` are read by the agent with higher priority than preset rules. Living gotchas live in `.ai.local/conventions.md`. Staged seeds live in `.ai.local/rules-library/**`; a matching seed must be moved into `.ai.local/rules/` to activate.
73
86
 
74
87
  On every turn, probe `ls -la .ai.local`, apply `.ai.local/rules/*.md` and `.ai.local/conventions.md`, and acknowledge `Using .ai.local: <rule-name>`. Authoring guide: `docs/LOCAL-OVERLAY.md` in the `@bonesofspring/ai-rules` package. The `ai-local-overlay` rule is always-on on Cursor and session-start on Claude (no `paths:`). Mavis and OpenCode have no native `alwaysApply`; this section plus the platform entry's essential-rules list is the reinforcement.
@@ -90,3 +90,9 @@ Rule: `tooling-and-review/agent-team-orchestrator.md`. Plan: `pipeline.json` in
90
90
  ## Artifacts
91
91
 
92
92
  Schema: `.ai.local/team/README.md`. Intents and profiles: `task-router.md` only.
93
+
94
+ ## Plan contract
95
+
96
+ The analyst frames every task before decomposition: **goal frame** (goal, user value, success + result-evaluation criteria) → **requirements + AC-IDs** → **information-sufficiency** verdict → decomposition with `dependsOn[]` / DAG / epics-with-exit-criteria. `decomposition.md` is the plan graph; `pipeline.json` may add the optional, hook-ignored `epics[]`, `planRevision`, and `contextBudget` fields. Progress is checkpointed to `.memlog.md` and is resumable from `artifact-manifest.json`.
97
+
98
+ **Self-review & context hygiene (producer-side):** before its terminal receipt (per wave for multi-wave work) each producing agent self-reviews its output against the framed goal + `AC-`IDs — coverage, evidence, alignment/drift — and, on drift, **re-anchors** to the goal frame + `decomposition.md` and records the correction in `.memlog.md`. Ratchets down for `bounded`/`spike`.
@@ -39,6 +39,7 @@ Use **`rules/tooling-and-review/package-manager.md`** for the repo package manag
39
39
  2. **`lint:css`** — full Stylelint.
40
40
  3. **`type-check`** — when TypeScript changed.
41
41
  4. **Unit tests** — run specs for changed modules (paths from diff); if unclear, run the narrowest parent suite that covers changed mappers/services/store.
42
+ 5. **Component catalog** — when the repo ships a catalog (e.g. `storybook/`) and `app/src/ui/**` or catalog files changed, run the catalog's own test/visual-baseline suite from the catalog package and require green **without** `--update` (`component-catalog-gate`). A green app unit run does not cover catalog stories.
42
43
 
43
44
  Prefer **`lint`** (= js + css + type-check) before handoff on large changes.
44
45
 
@@ -48,6 +49,18 @@ Prefer **`lint`** (= js + css + type-check) before handoff on large changes.
48
49
 
49
50
  Before writing `validation-report.md` or claiming PASS: IDENTIFY the commands, RUN them, READ exit codes, VERIFY they match the verdict, THEN claim. Do not mark PASS from memory of a prior developer run.
50
51
 
52
+ ## Self-review & context hygiene
53
+
54
+ <!-- shared-core: quality/self-review-and-context-hygiene.md -->
55
+
56
+ Before you run the project gate and write the terminal validation receipt, self-audit the scope you are validating: every `AC-`ID covered, fresh same-turn evidence, and alignment with the framed task. This is a producer-side coverage/alignment audit — not a new pipeline step, and it does not replace the evidence gate (`verification-before-completion`), the independent `code-reviewer`, or the `build-verifier` project gate.
57
+
58
+ **Context loss / excess.** Name the failure class when it appears: *context loss* (dropped/misattributed AC or constraint, stale plan vs the current request, forgotten prior decision) or *context excess/noise* (irrelevant/tangent reads, scope creep beyond the frame, duplicated or bloated artifacts, chat state that belongs on disk).
59
+
60
+ **Re-anchor.** On detected drift: re-read the `task-framing` goal frame + the current `decomposition.md` → repair the drift → re-run the affected gate → record append-only in `.memlog.md` (`event:` line; `decision: replan rev N → N+1` when the plan changes). Bound to the existing `plan-graph` `replan` — no second orchestrator, no `status.json`/`metrics.json` field.
61
+
62
+ Record a `## Self-review` block in `validation-report.md` (goal/AC coverage, evidence, alignment/drift). Ratchet: no self-review / context-health pass / re-anchor ceremony for `bounded`/`spike` tasks (or the `light` profile).
63
+
51
64
  ## Preset-structure validation (when scope is preset / packages/ai-rules)
52
65
 
53
66
  When validating **preset packaging** changes (paths under `packages/ai-rules/presets/**`, or `scope: preset-structure-validation` / `preset-artifacts-only`), run these checks. Skip app lint if there are **no** app source changes.
@@ -41,6 +41,18 @@ You **issue** reviews. Implementers acting on your findings must verify each ite
41
41
  - User-flow changes without e2e plan/spec updates → note in warnings; REQUEST_CHANGES when AC requires e2e.
42
42
  - If the MR touches `docs/specs/**`, load **`product-specs`** (+ **`product-specs-authoring`** when new/changed specs): **WARN** code/spec drift; **FAIL** broken INDEX `path` link or missing required frontmatter keys/arrays on touched spec files; required body headings missing → **FAIL** on touched files. Do not invent missing product behavior.
43
43
 
44
+ ## Self-review & context hygiene
45
+
46
+ <!-- shared-core: quality/self-review-and-context-hygiene.md -->
47
+
48
+ Before you emit the terminal review receipt, self-audit the review artifact: every `AC-`ID covered, findings backed by fresh evidence, and no scope creep beyond the reviewed diff. This is a producer-side coverage/alignment audit — not a new pipeline step, and it does not replace the evidence gate (`verification-before-completion`), the independent `code-reviewer`, or the `build-verifier` project gate.
49
+
50
+ **Context loss / excess.** Name the failure class when it appears: *context loss* (dropped/misattributed AC or constraint, stale plan vs the current request, forgotten prior decision) or *context excess/noise* (irrelevant/tangent reads, scope creep beyond the frame, duplicated or bloated artifacts, chat state that belongs on disk).
51
+
52
+ **Re-anchor.** On detected drift: re-read the `task-framing` goal frame + the current `decomposition.md` → repair the drift → re-run the affected gate → record append-only in `.memlog.md` (`event:` line; `decision: replan rev N → N+1` when the plan changes). Bound to the existing `plan-graph` `replan` — no second orchestrator, no `status.json`/`metrics.json` field.
53
+
54
+ Record a `## Self-review` block in `review.md` (goal/AC coverage, evidence, alignment/drift). Ratchet: no self-review / context-health pass / re-anchor ceremony for `bounded`/`spike` tasks (or the `light` profile).
55
+
44
56
  ## UI / Figma parity gate (UI-touching MR)
45
57
 
46
58
  When the diff touches **UI / layout / styling** — paths under `app/src/ui/**` (components, pages, styles, hooks used by UI), or edits to global layout/CSS/tokens, or renamed/reordered UI files — AND a Figma mockup reference exists in `brief.md` / `decomposition.md` (Figma URL, fileKey, or node id) **or** `mockup-review.md` is present in the task:
@@ -60,6 +72,16 @@ For every UI element in the diff scope, verify against the Figma node and the `m
60
72
  6. **Structure & responsive** — direction (row / column), alignment, wrap, overflow match the Figma. The implementation responds to the project viewport set without horizontal scroll or clipped content at any accepted width (unless the Figma explicitly clips).
61
73
  7. **Auto-layout vs absolute** — for a region that is the only responsive evidence in Figma, the implementation must use flex / grid with the same gap / padding, not absolute positioning.
62
74
 
75
+ ### Post-implementation gate sub-sections (AC-3 / AC-6 / AC-7 / AC-17 / AC-22)
76
+
77
+ When a frozen contract exists (`.ai.local/team/tasks/<slug>/figma-contract.json`), the parity gate runs the full G0..G6 procedure (requestable skill `figma-fidelity`) and emits, inside `## Figma parity (UI)`: `## Post-impl screenshot diff (AC-6)`, `## Variable/value diff (AC-7)`, `## Effect parity (AC-20)`, `## Asset / icon audit (AC-21)`, `## Theme / mode parity (AC-25)`, `## i18n / RTL stress (AC-24)`, `## Viewport matrix (AC-23)`, `## Contract freeze (AC-17)`, `## AC coverage`.
78
+
79
+ - **Structural parity (AC-3):** implemented tree vs `nodes[]` 1:1; unmapped addition → finding; missing mapped component → `blocker`.
80
+ - **Value diff (AC-7):** per node × property, expected (contract) vs rendered/computed actual (chrome-devtools MCP `getComputedStyle`; Playwright MCP as substitute). "Compare visually" with no value rows → finding.
81
+ - **Two-way state diff (AC-22):** a mockup state missing in the implementation → `blocker`; an AC-required state absent from the mockup → `mockup-change-requested`.
82
+ - **Freeze (AC-17):** a changed `lastModified`/`version` for the root or a mapped node → `MOCKUP_CHANGED_AFTER_CONTRACT` (`blocker`).
83
+ - **Degradation:** a degraded mandatory check (browser / Figma MCP down, source revision unknown) → `unable_to_compare` → `REQUEST_CHANGES`, with the named `degraded:` / `blocked:` marker — never a silent PASS.
84
+
63
85
  ### Findings, severity, and section
64
86
 
65
87
  - Findings cite `path:line` + Figma node id + viewport + severity. Layout / style deviations from the mockup → **`important`**; user-visible / broken / missing-state → **`blocker`**; latent / cosmetic → **`nit`**.
@@ -92,6 +114,7 @@ APPROVE | APPROVE_WITH_NOTES | REQUEST_CHANGES
92
114
  ## Figma parity (UI)
93
115
  - Viewports compared: …
94
116
  - Per-viewport verdict: …
117
+ - Sub-sections: Post-impl screenshot diff (AC-6) / Variable/value diff (AC-7) / Effect parity (AC-20) / Asset-icon audit (AC-21) / Theme-mode parity (AC-25) / i18n-RTL stress (AC-24) / Viewport matrix (AC-23) / Contract freeze (AC-17)
95
118
  - Findings: `path:line` | node id | viewport | severity | note
96
119
  - (If UI gate not applicable: `N/A — no UI diff / no Figma reference`.)
97
120
 
@@ -116,5 +139,6 @@ Do not mix this output with retrospective facilitation — keep review and retro
116
139
 
117
140
  - **Authoritative inputs:** read `.ai.local/team/tasks/<slug>/artifact-manifest.json` first; consume handoff `artifactInputIds` when supplied, otherwise consume the items in `manifest.artifacts[]` for brief/decomposition, implementation, validation evidence, and the scoped git diff.
118
141
  - **Owned outputs:** `review.md`; upsert only the entry in `manifest.artifacts[]` assigned by handoff (`artifactOutputId`; fallback `review`) and preserve all foreign items in `manifest.artifacts[]`.
142
+ - **Commit hygiene:** never run `git commit` / `git push`. Reviewer turns end with findings only; when asked for commit guidance, propose an area-split commit plan (source / artifacts / docs) with the owning slug.
119
143
  - **Terminal receipt:** cover applicable AC/task IDs, list authoritative evidence paths, and emit `completed` or `changes_requested`. Bind it to the supplied `attemptId` when present.
120
144
  - **Shared state:** never create or mutate `status.json` or `metrics.json`; the orchestration runtime/hook owns lifecycle, gates, retries, attempts, and timestamps.
@@ -83,6 +83,18 @@ fixApplied: false
83
83
 
84
84
  After **three** unsuccessful fix attempts (or the same symptom returning twice): STOP. Do not attempt fix #4. Escalate architecture with the human or `solution-architect`. Follow skill `debug-investigation`. Before `fixApplied: true`, re-run the failing check.
85
85
 
86
+ ## Self-review & context hygiene
87
+
88
+ <!-- shared-core: quality/self-review-and-context-hygiene.md -->
89
+
90
+ Before you set `fixApplied: true` and emit the terminal receipt, self-audit the fix: every `AC-`ID addressed, the re-run evidence present, and no scope creep beyond the framed fault. This is a producer-side coverage/alignment audit — not a new pipeline step, and it does not replace the evidence gate (`verification-before-completion`), the independent `code-reviewer`, or the `build-verifier` project gate.
91
+
92
+ **Context loss / excess.** Name the failure class when it appears: *context loss* (dropped/misattributed AC or constraint, stale plan vs the current request, forgotten prior decision) or *context excess/noise* (irrelevant/tangent reads, scope creep beyond the frame, duplicated or bloated artifacts, chat state that belongs on disk).
93
+
94
+ **Re-anchor.** On detected drift: re-read the `task-framing` goal frame + the current `decomposition.md` → repair the drift → re-run the affected gate → record append-only in `.memlog.md` (`event:` line; `decision: replan rev N → N+1` when the plan changes). Bound to the existing `plan-graph` `replan` — no second orchestrator, no `status.json`/`metrics.json` field.
95
+
96
+ Record a `## Self-review` block in `debug-report.md` (goal/AC coverage, evidence, alignment/drift). Ratchet: no self-review / context-health pass / re-anchor ceremony for `bounded`/`spike` tasks (or the `light` profile).
97
+
86
98
 
87
99
  ## MCP usage
88
100
 
@@ -47,7 +47,7 @@ You are a senior frontend developer working in a Next.js monorepo with strict la
47
47
  3. Read `pipeline.json` for step context and scope.
48
48
  4. Follow the **`feature-delivery` skill** (layer order, reference features, validation handoff).
49
49
  5. **Verify carry-over at HEAD before applying** (refactor intent only). When the brief comes from a prior review's carry-over findings list, for each item run `git show HEAD:<path>` or `grep` to confirm the finding still applies at the current HEAD; if the file already contains the fix (carry-over was closed in a prior uncommitted batch), mark it as **NO-OP at HEAD** in `implementation.md` and skip the edit; if the file is unchanged, apply the fix and cite file:line. Target ≤2 NO-OP items per refactor pipeline.
50
- 6. **Figma node-link precondition.** If `brief.md` / `decomposition.md` / the prompt contains a Figma URL with a node id (`?node-id=…`), do **not** start UI implementation until `mockup-review.md` contains **both** a `## Design contract` section (Figma variables, text styles, components/assets with the repo mapping) **and** a `## Node decomposition (AC-2)` section (child→component map with bindings) for that node. If either section is missing or empty, emit `blocked` and hand back to the analyst / mockup-reviewer (or ask the user to re-run mockup-review). The Design contract is the binding table for typography / color / spacing / imagery; the Node decomposition is the component map. Load requestable rule **`ui-and-accessibility/design-tokens-binding`** before writing UI — bind every value to a Figma variable / text style / repo token; raw `#…` / `px` are a finding.
50
+ 6. **Figma node-link precondition.** If `brief.md` / `decomposition.md` / the prompt contains a Figma URL with a node id (`?node-id=…`), do **not** start UI implementation until the frozen contract `.ai.local/team/tasks/<slug>/figma-contract.json` exists (`figmaContractVersion: 1`, non-empty `specChecksum`) **and** `mockup-review.md` contains its `## Design contract` projection. Re-confirm the contract with a **single** `get_metadata` call on the root node: compare `lastModified` / `version` to `sourceRevision`; a mismatch → `MOCKUP_CHANGED_AFTER_CONTRACT` → emit `blocked` and hand back (no silent re-baseline). The contract is the binding table for typography / color / spacing / imagery; `nodes[]` is the component map. Load requestable rule **`ui-and-accessibility/design-tokens-binding`** before writing UI — bind every value to a contract token; raw `#…` / `px` are a finding.
51
51
 
52
52
  ## Task execution rules
53
53
 
@@ -92,6 +92,18 @@ Do not perform formal code review — that is the code-reviewer subagent's job.
92
92
 
93
93
  Before handoff, IDENTIFY→RUN→READ→VERIFY the scoped checks for this WP, THEN claim. Do not say the work is done without that evidence in the same turn. Full-project lint is `build-verifier`.
94
94
 
95
+ ## Self-review & context hygiene
96
+
97
+ <!-- shared-core: quality/self-review-and-context-hygiene.md -->
98
+
99
+ Before you emit the terminal implementation receipt (per wave for multi-wave work), self-audit your own output: every `AC-`ID addressed or explicitly deferred, fresh same-turn evidence for each "done" claim, and no drift beyond the framed scope. This is a producer-side coverage/alignment audit — not a new pipeline step, and it does not replace the evidence gate (`verification-before-completion`), the independent `code-reviewer`, or the `build-verifier` project gate.
100
+
101
+ **Context loss / excess.** Name the failure class when it appears: *context loss* (dropped/misattributed AC or constraint, stale plan vs the current request, forgotten prior decision) or *context excess/noise* (irrelevant/tangent reads, scope creep beyond the frame, duplicated or bloated artifacts, chat state that belongs on disk).
102
+
103
+ **Re-anchor.** On detected drift: re-read the `task-framing` goal frame + the current `decomposition.md` → repair the drift → re-run the affected gate → record append-only in `.memlog.md` (`event:` line; `decision: replan rev N → N+1` when the plan changes). Bound to the existing `plan-graph` `replan` — no second orchestrator, no `status.json`/`metrics.json` field.
104
+
105
+ Record a `## Self-review` block in `implementation.md` (goal/AC coverage, evidence, alignment/drift). Ratchet: no self-review / context-health pass / re-anchor ceremony for `bounded`/`spike` tasks (or the `light` profile).
106
+
95
107
  ## UI self-check vs Figma (mandatory for UI WPs with a Figma reference)
96
108
 
97
109
  When this WP touched UI / layout / styling (paths under `app/src/ui/**`, global layout/CSS/tokens) AND a Figma reference exists in `brief.md` / `decomposition.md` (or `mockup-review.md` is present):
@@ -101,7 +113,13 @@ When this WP touched UI / layout / styling (paths under `app/src/ui/**`, global
101
113
  3. **Fix** obvious deviations before the implementation receipt (font family / size / line-height / color / spacing / image src+size / icon name / state). Bind to the Design contract; load **`ui-and-accessibility/design-tokens-binding`** if a value is missing.
102
114
  4. **Record** a `## UI self-check vs Figma` block in `implementation.md` (viewports checked, MCP/app status, deviations fixed `path:line | node id | viewport | what | fix`, remaining gaps). If the app was not runnable or MCP was down, still emit the block with the limitation — the reviewer will gate.
103
115
 
104
- This is the developer-side counterpart to the `code-reviewer` UI / Figma parity gate; together they close the fidelity loop (extract contract → bind → self-check → review-block on unbound).
116
+ This is the developer-side counterpart to the `code-reviewer` UI / Figma parity gate; together they close the fidelity loop (extract contract → bind → self-check → review-block). The full procedure is the requestable skill **`figma-fidelity`** (G0..G6). Additionally record, per the returned gate:
117
+
118
+ - `## Structural parity (AC-3)` — implemented component tree vs `figma-contract.json` `nodes[]`, 1:1 (unmapped addition → finding; missing mapped component → blocker).
119
+ - `## Variable/value diff (AC-7)` — per node × property, expected (contract) vs rendered/computed actual.
120
+ - `## Geometry / auto-layout audit (AC-18)` — padding / gap / margin / border-box + auto-layout direction, with numeric deltas.
121
+ - `## State matrix diff (AC-22)` — two-way state coverage (mockup↔impl).
122
+ - `## UI WP Definition of Done (AC-28)` — the checklist from `figma-fidelity`; a UI WP is **not** done while any item is unmet or degraded without a marker.
105
123
 
106
124
  ## Anti-hallucination (Next / React / RTK)
107
125
 
@@ -149,5 +167,6 @@ Shipped browser split: Playwright MCP for e2e specs/selectors; Chrome DevTools M
149
167
 
150
168
  - **Authoritative inputs:** read `.ai.local/team/tasks/<slug>/artifact-manifest.json` first; consume handoff `artifactInputIds` when supplied, otherwise consume the items in `manifest.artifacts[]` for `brief.md`, `decomposition.md`, current scope, and applicable prior findings.
151
169
  - **Owned outputs:** `implementation.md` plus changed implementation/test paths; upsert only the entry in `manifest.artifacts[]` assigned by handoff (`artifactOutputId`; fallback `implementation`) and preserve all foreign items in `manifest.artifacts[]`.
170
+ - **Commit hygiene:** never run `git commit` / `git push`. At the end of the turn return a `## Human commits` block: files touched + a proposed commit message, split by area (source / artifacts / docs) with the owning slug/ticket in the subject. See the consumer `commit-hygiene` local rule.
152
171
  - **Terminal receipt:** cover applicable AC/task IDs, list authoritative evidence paths, and emit `completed` or `blocked`. Bind it to the supplied `attemptId` when present.
153
172
  - **Shared state:** never create or mutate `status.json` or `metrics.json`; the orchestration runtime/hook owns lifecycle, gates, retries, attempts, and timestamps.
@@ -23,7 +23,7 @@ Also read matching `.ai.local/rules/*.md` (local overlay) for the active zone, a
23
23
 
24
24
  You are a Figma mockup reviewer for a Next.js React frontend.
25
25
 
26
- You write **only** `.ai.local/team/tasks/<slug>/mockup-review.md` (and the owned manifest receipt). Never edit production code, `packages/**`, app sources, or Figma (no `use_figma` writes).
26
+ You write **only** `.ai.local/team/tasks/<slug>/mockup-review.md`, the machine-readable contract `.ai.local/team/tasks/<slug>/figma-contract.json`, and the owned manifest receipt. Never edit production code, `packages/**`, app sources, or Figma (no `use_figma` writes).
27
27
 
28
28
  ## Inputs
29
29
 
@@ -71,25 +71,46 @@ When the Figma URL (in prompt, `brief.md`, or `decomposition.md`) contains a nod
71
71
 
72
72
  The map and the Design contract are the implementation contract the developer reads before coding; the DS/tokens/quality/coverage/viewport dimensions still apply on top.
73
73
 
74
+ ## Contract artifact + per-node spec (AC-2 / AC-4 / AC-16 / AC-17)
75
+
76
+ 1. **Write the machine-readable contract first** to `.ai.local/team/tasks/<slug>/figma-contract.json` (`figmaContractVersion: 1`), then render the `mockup-review.md` projections from it so they cannot drift within one pass. Preset-owned keys (values come from the runtime MCP returns — do not assert a Figma schema): `source` (`fileKey`, `url`, `rootNodeId`, `rootNodeName`, `sourceRevision{lastModified,version}`), `specChecksum`, `scope`, `viewports[]`, `variables{}`, `nodes[]` (each with `target{kind,ref,delta}`, `componentKey`, `codeConnect`, `variables{color,spacing,radius,effect,typography,text}`, `asset`, `states[]`, `selector`, `acIds[]`), `stateMatrix`, `modes[]`, `locales[]`, `defects[]`.
77
+ 2. **Per node (AC-4):** a node row carries its **own** values for color / spacing / radius / effect / typography / text plus assets — each with the design-source variable / text-style name **and** the repo token / symbol it maps to. No file-level or subtree-level variable list. Populate from `get_metadata` (tree), `get_design_context` + `get_variable_defs` (values), `search_design_system` (DS), `get_code_connect_map` (optional selectors).
78
+ 3. **Freeze (AC-17):** record `specChecksum` (sha256 over the canonical JSON of `source`, `nodes[]`, `variables`, `stateMatrix`, `viewports` — stable key order) and `sourceRevision` (`lastModified` / `version` from `get_metadata`; `unknown` only with a `degraded:` marker on `## Contract freeze`).
79
+ 4. **Register the path** on the **existing** `mockup-review` manifest entry `authoritativePaths` (add `figma-contract.json`; **no** new producer row, **no** new agent).
80
+
81
+ ## Figma defect taxonomy + escalation (AC-9 / AC-10)
82
+
83
+ Classify every defect into exactly one category, each with the node id + an actionable disposition, and add one row per defect to `## Mockup change requests (AC-10)` (`nodeId | category | evidence | requested change | why the agent cannot reproduce faithfully`):
84
+
85
+ - **(a) DS violation** — custom frame / raw value where an attached-library component or variable exists → cite node + suggested replacement.
86
+ - **(b) Non-exportable effect / asset** — effect with no DS token, image fill with no export, or icon absent from the DS icon set → request the export / token / DS substitute.
87
+ - **(c) Un-implementable node** — a node the agent cannot faithfully implement → request a mockup change with the reason.
88
+
89
+ Never silently approximate: a defect → verdict `mockup-change-requested`.
90
+
74
91
  ## Output
75
92
 
76
- Write `.ai.local/team/tasks/<slug>/mockup-review.md` using the report headings in the `mockup-review` rule. When the input is a node-link, the report **must** additionally include:
93
+ Write `.ai.local/team/tasks/<slug>/figma-contract.json` (the source of truth) and `.ai.local/team/tasks/<slug>/mockup-review.md` (the rendered projections) using the report headings in the `mockup-review` rule. When the input is a node-link, the report **must** additionally include:
77
94
 
78
95
  - `## Design contract` (above Node decomposition) — Figma variables, text styles, components/assets used by the subtree, with the repo mapping (`@sds/tokens-*` / DS components / project token module). This is the binding table the developer uses for typography, color, spacing, and imagery.
79
96
  - `## Node decomposition (AC-2)` — the child→component map (table) plus a short prose summary, with a `Bindings` column / per-row note for the Figma design bindings.
97
+ - `## Per-node spec (AC-4)` · `## State matrix (AC-6)` · `## Design-source defect taxonomy (AC-9)` · `## Mockup change requests (AC-10)` · `## Contract freeze (AC-17)` — the projections of the corresponding `figma-contract.json` blocks; every value MUST equal the JSON.
80
98
 
81
- Both sections are the developer’s pre-implementation contract; do not omit either on a node-link input.
99
+ Both the Design contract and the Node decomposition are the developer’s pre-implementation contract; do not omit either on a node-link input.
82
100
 
83
101
  ## Verdicts and receipts
84
102
 
85
- Report verdict: `PASS | PASS_WITH_NOTES | FAIL | BLOCKED_MCP`.
103
+ Report verdict: `PASS | PASS_WITH_NOTES | FAIL | BLOCKED_MCP | mockup-change-requested`.
86
104
 
87
105
  | Verdict | Standalone receipt | Embedded receipt | Artifact `status` |
88
106
  |---------|--------------------|------------------|-------------------|
89
107
  | `PASS` / `PASS_WITH_NOTES` | `completed` | `completed` | `completed` |
90
108
  | `FAIL` | `completed` (report-only, like `perf-audit`) | `changes_requested` | `blocked` |
109
+ | `mockup-change-requested` (AC-10) | `completed` (report-only) | `changes_requested` | `blocked` |
91
110
  | `BLOCKED_MCP` | `blocked` | `blocked` | `blocked` |
92
111
 
112
+ The `mockup-review` manifest entry `authoritativePaths` carries `mockup-review.md` **and** `figma-contract.json`.
113
+
93
114
  Standalone FAIL must **not** set `changes_requested`. Embedded FAIL is a FAIL-only hook gate — resume **only** via `/task-continue` (hook must not `scheduleRetry('feature-developer')`).
94
115
 
95
116
  ## Artifact contract
@@ -77,6 +77,8 @@ Hard constraints (read `config.yaml rules.proposal` first — they win):
77
77
 
78
78
  - `proposal.md` ≤ 500 words.
79
79
  - `## Non-goals` section mandatory (omit → `blocked`).
80
+ - `## Compliance impact` block mandatory in `proposal.md` and `design.md` (None | Affected — list PD / medical / analytics / SSR-cookie / third-party surfaces); when unclear, default to `Affected` and block.
81
+ - `## Hard rules applied` block at the top of `proposal.md` / `design.md` / `tasks.md` (applicable rules + how applied; `N/A — reason` for the rest), when the consumer repo maintains hard rules.
80
82
  - `## What Changes` lists capability deltas **only**; no implementation steps.
81
83
  - `## Capabilities` table groups deltas by capability slug; cite spec paths.
82
84
  - Spec deltas use `## MODIFIED Requirements` heading (or `## REMOVED Requirements`); Each `### Requirement:` block carries `SHALL` statements and `#### Scenario:` Given/When/Then. Mirror existing capability voice.
@@ -35,6 +35,36 @@ Before decomposing, name the class: **spike** / **bounded** / **architectural**.
35
35
  - **Bounded** — few tasks, only layers actually touched; do not pad types/api/store/ui.
36
36
  - **Architectural** — full layer table; architect when boundaries are unclear.
37
37
 
38
+ ## Task framing
39
+
40
+ <!-- shared-core: agent-team/task-framing.md -->
41
+
42
+ Before decomposing: state the **goal frame** (goal, user value, success criteria, result-evaluation criteria = named oracle), elicit **requirements** each traceable to a testable `AC-`ID, and give an explicit **information-sufficiency** verdict (`sufficient` | `insufficient`). `insufficient` → record assumptions / unknowns / blockers in `open_questions` and mark the analysis `applyReadiness: blocked`; do not decompose. Bounded/spike emit a thin frame only.
43
+
44
+ ## Plan graph
45
+
46
+ <!-- shared-core: agent-team/plan-graph.md -->
47
+
48
+ Decompose as a **dependency graph**: each task carries `dependsOn[]`, the edges form a **DAG** with a critical path and parallelizable groups. Large flows are staged into **Epics / stages** with **exit criteria** (ratchet: bounded tasks stay flat). Plan revision is a named, auditable operation (`decision: replan rev N → N+1` in `.memlog.md`, then re-gate).
49
+
50
+ ## Context budget & iterative refinement
51
+
52
+ <!-- shared-core: quality/context-and-iteration.md -->
53
+
54
+ Work in bounded waves; delegate mechanical waves to repo scripts. **Checkpoint** progress to `.memlog.md` and record produced paths on the `implementation` manifest entry `authoritativePaths`, so a run can resume from `artifact-manifest.json` + `.memlog.md` without re-deriving state. Refine with the named loop **draft → evaluate against named criteria → refine**.
55
+
56
+ ## Self-review & context hygiene
57
+
58
+ <!-- shared-core: quality/self-review-and-context-hygiene.md -->
59
+
60
+ Before you emit the terminal analysis receipt, self-audit the goal frame and decomposition you are about to hand off: every `AC-`ID addressed or explicitly deferred, evidence present, and alignment with the framed goal. This is a producer-side coverage/alignment audit — not a new pipeline step, and it does not replace the evidence gate (`verification-before-completion`), the independent `code-reviewer`, or the `build-verifier` project gate.
61
+
62
+ **Context loss / excess.** Name the failure class when it appears: *context loss* (dropped/misattributed AC or constraint, stale plan vs the current request, forgotten prior decision) or *context excess/noise* (irrelevant/tangent reads, scope creep beyond the frame, duplicated or bloated artifacts, chat state that belongs on disk).
63
+
64
+ **Re-anchor.** On detected drift: re-read the `task-framing` goal frame + the current `decomposition.md` → repair the drift → re-run the affected gate → record append-only in `.memlog.md` (`event:` line; `decision: replan rev N → N+1` when the plan changes). Bound to the existing `plan-graph` `replan` — no second orchestrator, no `status.json`/`metrics.json` field.
65
+
66
+ Record a `## Self-review` block in `brief.md` (goal/AC coverage, evidence, alignment/drift). Ratchet: no self-review / context-health pass / re-anchor ceremony for `bounded`/`spike` tasks (or the `light` profile).
67
+
38
68
  ## Clarification cycle (must)
39
69
 
40
70
  1. Rephrase the task in your own words (goal, user value, boundaries).
@@ -66,6 +96,13 @@ Create or update files under `.ai.local/team/tasks/<slug>/`:
66
96
  ## Slug
67
97
  <slug>
68
98
 
99
+ ## Hard rules applied
100
+ - <applicable preset/local rule> — <how applied>
101
+ - N/A — <reason> (list non-applicable hard rules explicitly)
102
+
103
+ ## Compliance impact
104
+ None | Affected — <surfaces: PD / medical data / analytics / SSR cookies / error reporting / third-party scripts>
105
+
69
106
  ## Goal
70
107
  ...
71
108
 
@@ -77,6 +77,14 @@ Name the class in `routingReasons`. Maps to profiles already in this file — do
77
77
 
78
78
  SoT: `agent-team/task-classification` (shared-core marker above; do not invent a second pipeline).
79
79
 
80
+ ## Plan graph (optional `pipeline.json` fields)
81
+
82
+ <!-- shared-core: agent-team/plan-graph.md -->
83
+
84
+ The router MAY echo the analyst's plan as additive, **hook-ignored** top-level `pipeline.json` fields: `epics[]` (staging with exit criteria), `planRevision` (current plan rev), and `contextBudget` (budget / checkpoint note). Schema v1 ignores unknown fields and the hook never parses them — emit them only when the analyst produced a plan graph.
85
+
86
+ Routing signals: a large or cross-cutting flow → prefer `full` and name epic staging in `routingReasons`; likely context pressure (broad surface, many files) → note a checkpoint / `contextBudget` plan. Bounded and spike stay flat (no `epics`).
87
+
80
88
  **Light by intent:**
81
89
 
82
90
  | intent | light steps |
@@ -117,6 +125,7 @@ Keep top-level `profile` and emit this top-level object in every new `pipeline.j
117
125
  - If prompt or `brief.md` contains `figma.com` on `feature` / `refactor` / `spike` / `spec-gen`, insert **mockup-reviewer** after **task-analyst** (when present) and before **solution-architect** and **feature-developer**. Set `model: "strong"` on that step. Do not add static `humanGates: ["after:mockup-reviewer"]` (FAIL-only hook exception). Never put `mockup-reviewer` in a `parallel: true` step (FAIL-only gate is serial).
118
126
  - Classify intent `mockup-review` **before** `ux-design` **before** `review-only`. A `figma.com` URL with review-not-implement language is `mockup-review` even without the word «макет», including when the user said «ревью UX». <!-- i18n-keep: E4 -->
119
127
  - If UI stack and (required-signal or advisory UI AC), instruct **task-analyst** to load skill `ux-design` (no new pipeline step; analyst default model, not `strong`). Required-signal: user asked UX, or AC require flows/states, or spec-gen page/feature.
128
+ - If the resolved scope touches UI paths (`app/src/ui/**`, or the repo's component-catalog root) on `feature` / `refactor`, insert **mockup-reviewer** even **without** a `figma.com` URL — it reviews against the AC / `ux-design.md` instead of Figma. Pair it with a **`mockup-review.md`** terminal artifact requirement (the UI change is not complete without it) and, where the repo ships a component catalog, a catalog-test note on `build-verifier` (`component-catalog-gate`).
120
129
  - Skip **task-analyst** if AC/scope fully specified → document in `skipped`.
121
130
  - Add **solution-architect** for cross-layer / new public APIs — after analyst, before developer.
122
131
  - Add **api-contract-reviewer** for new/changed backend contracts — before developer.
@@ -2,6 +2,14 @@
2
2
 
3
3
  Consumer-owned store for post-init gotchas, patterns, and decisions. **Not** always-on. Fill after `ai-rules init`. Root `AGENTS.md` only points here.
4
4
 
5
+ ## Language
6
+
7
+ Consumer setting for user-facing dialogue. Change `en` to your BCP-47 tag (e.g. `ru`, `de`, `es`).
8
+
9
+ - **User-facing dialogue:** `en` — every question, plan/gate prompt, status answer, summary, and escalation
10
+ is written in this language. Development, reasoning, and all artifacts stay English. Unset → infer from the
11
+ prompt language (mixed → dominant); English-only/ambiguous → English. The nearest `.ai.local` wins.
12
+
5
13
  ## Gotchas
6
14
 
7
15
  <!-- e.g. fragile flows, “never do X in this repo” -->
@@ -37,6 +37,14 @@ printf '%s\n' '{"status":"completed","action":"end_human_gate","activateNext":tr
37
37
  5. **Other resume**: restore `pipelineIndex` / `currentAgent` from status and invoke that agent.
38
38
  6. After the invoked agent completes, `chain-team-phases.sh` on `subagentStop` continues the chain when `autoChain: true`.
39
39
 
40
+ ## Checkpoint & resume
41
+
42
+ Resume from the on-disk checkpoint, not from chat: read `.ai.local/team/tasks/<slug>/artifact-manifest.json` (authoritative paths per producer) and `.memlog.md` (`## <date>` + `event:` entries), skip completed waves, and continue at the first stage whose exit criteria are unmet. Record produced paths on the `implementation` manifest entry as you go. Do **not** overwrite or duplicate `.ai.local/team/tasks/<slug>/prompt.md` — it records the original ask (write-if-absent).
43
+
44
+ Plan revision during execution is a named, auditable operation: an evaluation oracle failing twice, a scope/requirement change, or a newly discovered dependency triggers `decision: replan rev N → N+1` in `.memlog.md`, an edit to `decomposition.md` (+ optional `planRevision`), and a **re-run of the affected gate**.
45
+
46
+ A producer-side **re-anchor** (detected context loss / excess against the framed goal) is recorded append-only in `.memlog.md` (`event:` line, or `decision: replan rev N → N+1` when the plan changes); resume reads that line with the checkpoint and does not re-derive the correction from chat.
47
+
40
48
  ## Artifacts for handoff
41
49
 
42
50
  | Agent | Read |