@bonesofspring/ai-rules 0.2.16 → 0.2.18

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 (525) hide show
  1. package/CHANGELOG.md +41 -0
  2. package/README.md +19 -2
  3. package/bin/cli.js +39 -0
  4. package/package.json +3 -1
  5. package/presets/_shared/README.md +3 -3
  6. package/presets/_shared/assets/docs-specs/INDEX.md +9 -0
  7. package/presets/_shared/assets/docs-specs/_templates/feature.md +32 -0
  8. package/presets/_shared/assets/docs-specs/_templates/page.md +47 -0
  9. package/presets/_shared/assets/docs-specs/schemas/frontmatter-v1.schema.json +22 -0
  10. package/presets/_shared/core/agent-team/agent-artifact-contracts.md +3 -0
  11. package/presets/_shared/core/agent-team/agent-team-orchestrator.md +4 -4
  12. package/presets/_shared/core/architecture/feature-delivery-workflow.md +1 -1
  13. package/presets/_shared/core/architecture/product-specs-authoring.md +107 -0
  14. package/presets/_shared/core/architecture/product-specs.md +49 -0
  15. package/presets/_shared/core/meta/preset-no-cross-stack-leakage.md +4 -2
  16. package/presets/_shared/core/review/mockup-review.md +105 -0
  17. package/presets/_shared/core/review/ux-design.md +97 -0
  18. package/presets/claude/android-kotlin/agents/README.md +2 -2
  19. package/presets/claude/android-kotlin/agents/build-verifier.md +9 -0
  20. package/presets/claude/android-kotlin/agents/code-reviewer.md +2 -0
  21. package/presets/claude/android-kotlin/agents/feature-developer.md +13 -0
  22. package/presets/claude/android-kotlin/agents/mockup-reviewer.md +59 -0
  23. package/presets/claude/android-kotlin/agents/task-analyst.md +37 -1
  24. package/presets/claude/android-kotlin/agents/task-router.md +22 -2
  25. package/presets/claude/android-kotlin/agents/tech-writer.md +5 -0
  26. package/presets/claude/android-kotlin/commands/feature-continue.md +4 -0
  27. package/presets/claude/android-kotlin/commands/feature-start.md +8 -0
  28. package/presets/claude/android-kotlin/commands/spec-start.md +29 -0
  29. package/presets/claude/android-kotlin/commands/task-continue.md +11 -6
  30. package/presets/claude/android-kotlin/commands/task.md +2 -0
  31. package/presets/claude/android-kotlin/hooks/chain-team-phases.sh +26 -0
  32. package/presets/claude/android-kotlin/rules/README.md +4 -0
  33. package/presets/claude/android-kotlin/rules/architecture/feature-delivery.md +6 -0
  34. package/presets/claude/android-kotlin/rules/architecture/product-specs-authoring.md +121 -0
  35. package/presets/claude/android-kotlin/rules/architecture/product-specs.md +62 -0
  36. package/presets/claude/android-kotlin/rules/tooling-and-review/agent-team-orchestrator.md +8 -3
  37. package/presets/claude/android-kotlin/rules/tooling-and-review/mockup-review.md +118 -0
  38. package/presets/claude/android-kotlin/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -3
  39. package/presets/claude/android-kotlin/rules/tooling-and-review/ux-design.md +110 -0
  40. package/presets/claude/android-kotlin/skills/README.md +2 -0
  41. package/presets/claude/android-kotlin/skills/feature-delivery/SKILL.md +8 -4
  42. package/presets/claude/android-kotlin/skills/mockup-review/SKILL.md +29 -0
  43. package/presets/claude/android-kotlin/skills/spec-authoring/SKILL.md +26 -0
  44. package/presets/claude/android-kotlin/skills/ux-design/SKILL.md +36 -0
  45. package/presets/claude/android-kotlin/team/fixtures/artifact-manifest.example.json +25 -0
  46. package/presets/claude/android-kotlin/team/fixtures/feature-with-figma-url.json +17 -0
  47. package/presets/claude/android-kotlin/team/fixtures/feature-with-ux-no-figma.json +17 -0
  48. package/presets/claude/android-kotlin/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  49. package/presets/claude/android-kotlin/team/fixtures/mockup-review-standalone.json +14 -0
  50. package/presets/claude/android-kotlin/team/fixtures/ux-design-standalone.json +15 -0
  51. package/presets/claude/go/MCP.md +1 -1
  52. package/presets/claude/go/agents/build-verifier.md +9 -0
  53. package/presets/claude/go/agents/code-reviewer.md +2 -0
  54. package/presets/claude/go/agents/feature-developer.md +7 -0
  55. package/presets/claude/go/agents/task-analyst.md +19 -0
  56. package/presets/claude/go/agents/task-router.md +12 -1
  57. package/presets/claude/go/agents/tech-writer.md +5 -0
  58. package/presets/claude/go/commands/feature-continue.md +1 -0
  59. package/presets/claude/go/commands/feature-start.md +8 -0
  60. package/presets/claude/go/commands/spec-start.md +29 -0
  61. package/presets/claude/go/commands/task-continue.md +6 -3
  62. package/presets/claude/go/rules/README.md +2 -0
  63. package/presets/claude/go/rules/architecture/feature-delivery.md +4 -0
  64. package/presets/claude/go/rules/architecture/product-specs-authoring.md +121 -0
  65. package/presets/claude/go/rules/architecture/product-specs.md +63 -0
  66. package/presets/claude/go/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
  67. package/presets/claude/go/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -2
  68. package/presets/claude/go/skills/feature-delivery/SKILL.md +5 -4
  69. package/presets/claude/go/skills/spec-authoring/SKILL.md +26 -0
  70. package/presets/claude/ios-swift/agents/README.md +2 -2
  71. package/presets/claude/ios-swift/agents/build-verifier.md +9 -0
  72. package/presets/claude/ios-swift/agents/code-reviewer.md +2 -0
  73. package/presets/claude/ios-swift/agents/feature-developer.md +13 -0
  74. package/presets/claude/ios-swift/agents/mockup-reviewer.md +59 -0
  75. package/presets/claude/ios-swift/agents/task-analyst.md +37 -1
  76. package/presets/claude/ios-swift/agents/task-router.md +22 -2
  77. package/presets/claude/ios-swift/agents/tech-writer.md +2 -15
  78. package/presets/claude/ios-swift/commands/feature-continue.md +4 -0
  79. package/presets/claude/ios-swift/commands/feature-start.md +8 -0
  80. package/presets/claude/ios-swift/commands/spec-start.md +29 -0
  81. package/presets/claude/ios-swift/commands/task-continue.md +11 -6
  82. package/presets/claude/ios-swift/commands/task.md +2 -0
  83. package/presets/claude/ios-swift/hooks/chain-team-phases.sh +26 -0
  84. package/presets/claude/ios-swift/rules/README.md +7 -0
  85. package/presets/claude/ios-swift/rules/architecture/feature-delivery.md +6 -0
  86. package/presets/claude/ios-swift/rules/architecture/product-specs-authoring.md +121 -0
  87. package/presets/claude/ios-swift/rules/architecture/product-specs.md +62 -0
  88. package/presets/claude/ios-swift/rules/tooling-and-review/agent-team-orchestrator.md +8 -3
  89. package/presets/claude/ios-swift/rules/tooling-and-review/mockup-review.md +118 -0
  90. package/presets/claude/ios-swift/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -2
  91. package/presets/claude/ios-swift/rules/tooling-and-review/ux-design.md +110 -0
  92. package/presets/claude/ios-swift/skills/README.md +2 -0
  93. package/presets/claude/ios-swift/skills/feature-delivery/SKILL.md +8 -4
  94. package/presets/claude/ios-swift/skills/mockup-review/SKILL.md +29 -0
  95. package/presets/claude/ios-swift/skills/spec-authoring/SKILL.md +26 -0
  96. package/presets/claude/ios-swift/skills/ux-design/SKILL.md +36 -0
  97. package/presets/claude/ios-swift/team/fixtures/artifact-manifest.example.json +25 -0
  98. package/presets/claude/ios-swift/team/fixtures/feature-with-figma-url.json +17 -0
  99. package/presets/claude/ios-swift/team/fixtures/feature-with-ux-no-figma.json +17 -0
  100. package/presets/claude/ios-swift/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  101. package/presets/claude/ios-swift/team/fixtures/mockup-review-standalone.json +14 -0
  102. package/presets/claude/ios-swift/team/fixtures/ux-design-standalone.json +15 -0
  103. package/presets/claude/java/agents/build-verifier.md +10 -1
  104. package/presets/claude/java/agents/code-reviewer.md +2 -0
  105. package/presets/claude/java/agents/feature-developer.md +7 -0
  106. package/presets/claude/java/agents/task-analyst.md +19 -0
  107. package/presets/claude/java/agents/task-router.md +12 -1
  108. package/presets/claude/java/agents/tech-writer.md +5 -0
  109. package/presets/claude/java/commands/feature-continue.md +1 -0
  110. package/presets/claude/java/commands/feature-start.md +8 -0
  111. package/presets/claude/java/commands/spec-start.md +29 -0
  112. package/presets/claude/java/commands/task-continue.md +6 -3
  113. package/presets/claude/java/rules/README.md +2 -0
  114. package/presets/claude/java/rules/architecture/feature-delivery.md +4 -0
  115. package/presets/claude/java/rules/architecture/product-specs-authoring.md +121 -0
  116. package/presets/claude/java/rules/architecture/product-specs.md +63 -0
  117. package/presets/claude/java/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
  118. package/presets/claude/java/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -2
  119. package/presets/claude/java/skills/feature-delivery/SKILL.md +5 -4
  120. package/presets/claude/java/skills/spec-authoring/SKILL.md +26 -0
  121. package/presets/claude/mcp-ts/agents/build-verifier.md +10 -1
  122. package/presets/claude/mcp-ts/agents/feature-developer.md +7 -0
  123. package/presets/claude/mcp-ts/agents/task-analyst.md +21 -0
  124. package/presets/claude/mcp-ts/agents/task-router.md +12 -1
  125. package/presets/claude/mcp-ts/commands/feature-continue.md +4 -0
  126. package/presets/claude/mcp-ts/commands/feature-start.md +8 -0
  127. package/presets/claude/mcp-ts/commands/spec-start.md +29 -0
  128. package/presets/claude/mcp-ts/commands/task-continue.md +6 -3
  129. package/presets/claude/mcp-ts/rules/README.md +2 -0
  130. package/presets/claude/mcp-ts/rules/architecture/feature-delivery.md +4 -0
  131. package/presets/claude/mcp-ts/rules/architecture/product-specs-authoring.md +121 -0
  132. package/presets/claude/mcp-ts/rules/architecture/product-specs.md +63 -0
  133. package/presets/claude/mcp-ts/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
  134. package/presets/claude/mcp-ts/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -2
  135. package/presets/claude/mcp-ts/skills/feature-delivery/SKILL.md +4 -3
  136. package/presets/claude/mcp-ts/skills/spec-authoring/SKILL.md +26 -0
  137. package/presets/claude/next/agents/README.md +2 -1
  138. package/presets/claude/next/agents/build-verifier.md +9 -0
  139. package/presets/claude/next/agents/code-reviewer.md +1 -0
  140. package/presets/claude/next/agents/feature-developer.md +13 -0
  141. package/presets/claude/next/agents/mockup-reviewer.md +59 -0
  142. package/presets/claude/next/agents/task-analyst.md +37 -1
  143. package/presets/claude/next/agents/task-router.md +23 -3
  144. package/presets/claude/next/agents/tech-writer.md +5 -0
  145. package/presets/claude/next/commands/feature-continue.md +1 -0
  146. package/presets/claude/next/commands/feature-start.md +8 -0
  147. package/presets/claude/next/commands/spec-start.md +29 -0
  148. package/presets/claude/next/commands/task-continue.md +11 -6
  149. package/presets/claude/next/commands/task.md +2 -0
  150. package/presets/claude/next/hooks/chain-team-phases.sh +26 -0
  151. package/presets/claude/next/rules/README.md +8 -1
  152. package/presets/claude/next/rules/architecture/feature-delivery-workflow.md +6 -0
  153. package/presets/claude/next/rules/architecture/product-specs-authoring.md +121 -0
  154. package/presets/claude/next/rules/architecture/product-specs.md +63 -0
  155. package/presets/claude/next/rules/tooling-and-review/agent-team-orchestrator.md +8 -3
  156. package/presets/claude/next/rules/tooling-and-review/mockup-review.md +118 -0
  157. package/presets/claude/next/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -2
  158. package/presets/claude/next/rules/tooling-and-review/ux-design.md +110 -0
  159. package/presets/claude/next/skills/README.md +2 -0
  160. package/presets/claude/next/skills/feature-delivery/SKILL.md +7 -3
  161. package/presets/claude/next/skills/mockup-review/SKILL.md +29 -0
  162. package/presets/claude/next/skills/spec-authoring/SKILL.md +26 -0
  163. package/presets/claude/next/skills/ux-design/SKILL.md +36 -0
  164. package/presets/claude/next/team/fixtures/artifact-manifest.example.json +20 -2
  165. package/presets/claude/next/team/fixtures/feature-with-figma-url.json +17 -0
  166. package/presets/claude/next/team/fixtures/feature-with-ux-no-figma.json +17 -0
  167. package/presets/claude/next/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  168. package/presets/claude/next/team/fixtures/mockup-review-standalone.json +14 -0
  169. package/presets/claude/next/team/fixtures/ux-design-standalone.json +15 -0
  170. package/presets/claude/nuxt/agents/README.md +2 -1
  171. package/presets/claude/nuxt/agents/build-verifier.md +9 -0
  172. package/presets/claude/nuxt/agents/code-reviewer.md +2 -0
  173. package/presets/claude/nuxt/agents/feature-developer.md +13 -0
  174. package/presets/claude/nuxt/agents/mockup-reviewer.md +59 -0
  175. package/presets/claude/nuxt/agents/task-analyst.md +37 -1
  176. package/presets/claude/nuxt/agents/task-router.md +23 -3
  177. package/presets/claude/nuxt/agents/tech-writer.md +5 -0
  178. package/presets/claude/nuxt/commands/feature-continue.md +4 -0
  179. package/presets/claude/nuxt/commands/feature-start.md +8 -0
  180. package/presets/claude/nuxt/commands/spec-start.md +29 -0
  181. package/presets/claude/nuxt/commands/task-continue.md +11 -6
  182. package/presets/claude/nuxt/commands/task.md +2 -0
  183. package/presets/claude/nuxt/hooks/chain-team-phases.sh +26 -0
  184. package/presets/claude/nuxt/rules/README.md +7 -0
  185. package/presets/claude/nuxt/rules/architecture/feature-delivery-workflow.md +6 -0
  186. package/presets/claude/nuxt/rules/architecture/product-specs-authoring.md +121 -0
  187. package/presets/claude/nuxt/rules/architecture/product-specs.md +62 -0
  188. package/presets/claude/nuxt/rules/tooling-and-review/agent-team-orchestrator.md +8 -3
  189. package/presets/claude/nuxt/rules/tooling-and-review/mockup-review.md +118 -0
  190. package/presets/claude/nuxt/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -2
  191. package/presets/claude/nuxt/rules/tooling-and-review/ux-design.md +110 -0
  192. package/presets/claude/nuxt/skills/README.md +2 -0
  193. package/presets/claude/nuxt/skills/feature-delivery/SKILL.md +7 -3
  194. package/presets/claude/nuxt/skills/mockup-review/SKILL.md +29 -0
  195. package/presets/claude/nuxt/skills/spec-authoring/SKILL.md +26 -0
  196. package/presets/claude/nuxt/skills/ux-design/SKILL.md +36 -0
  197. package/presets/claude/nuxt/team/fixtures/artifact-manifest.example.json +20 -2
  198. package/presets/claude/nuxt/team/fixtures/feature-with-figma-url.json +17 -0
  199. package/presets/claude/nuxt/team/fixtures/feature-with-ux-no-figma.json +17 -0
  200. package/presets/claude/nuxt/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  201. package/presets/claude/nuxt/team/fixtures/mockup-review-standalone.json +14 -0
  202. package/presets/claude/nuxt/team/fixtures/ux-design-standalone.json +15 -0
  203. package/presets/claude/php-hexagonal/agents/build-verifier.md +10 -1
  204. package/presets/claude/php-hexagonal/agents/code-reviewer.md +2 -0
  205. package/presets/claude/php-hexagonal/agents/feature-developer.md +7 -0
  206. package/presets/claude/php-hexagonal/agents/task-analyst.md +19 -0
  207. package/presets/claude/php-hexagonal/agents/task-router.md +12 -1
  208. package/presets/claude/php-hexagonal/agents/tech-writer.md +5 -0
  209. package/presets/claude/php-hexagonal/commands/feature-continue.md +1 -0
  210. package/presets/claude/php-hexagonal/commands/feature-start.md +8 -0
  211. package/presets/claude/php-hexagonal/commands/spec-start.md +29 -0
  212. package/presets/claude/php-hexagonal/commands/task-continue.md +6 -3
  213. package/presets/claude/php-hexagonal/rules/README.md +2 -0
  214. package/presets/claude/php-hexagonal/rules/architecture/feature-delivery.md +4 -0
  215. package/presets/claude/php-hexagonal/rules/architecture/product-specs-authoring.md +121 -0
  216. package/presets/claude/php-hexagonal/rules/architecture/product-specs.md +63 -0
  217. package/presets/claude/php-hexagonal/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
  218. package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -2
  219. package/presets/claude/php-hexagonal/skills/feature-delivery/SKILL.md +5 -4
  220. package/presets/claude/php-hexagonal/skills/spec-authoring/SKILL.md +26 -0
  221. package/presets/claude/php-laravel/agents/build-verifier.md +10 -1
  222. package/presets/claude/php-laravel/agents/code-reviewer.md +2 -0
  223. package/presets/claude/php-laravel/agents/feature-developer.md +7 -0
  224. package/presets/claude/php-laravel/agents/task-analyst.md +19 -0
  225. package/presets/claude/php-laravel/agents/task-router.md +12 -1
  226. package/presets/claude/php-laravel/agents/tech-writer.md +5 -0
  227. package/presets/claude/php-laravel/commands/feature-continue.md +1 -0
  228. package/presets/claude/php-laravel/commands/feature-start.md +8 -0
  229. package/presets/claude/php-laravel/commands/spec-start.md +29 -0
  230. package/presets/claude/php-laravel/commands/task-continue.md +6 -3
  231. package/presets/claude/php-laravel/rules/README.md +2 -0
  232. package/presets/claude/php-laravel/rules/architecture/feature-delivery.md +4 -0
  233. package/presets/claude/php-laravel/rules/architecture/product-specs-authoring.md +121 -0
  234. package/presets/claude/php-laravel/rules/architecture/product-specs.md +63 -0
  235. package/presets/claude/php-laravel/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
  236. package/presets/claude/php-laravel/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -2
  237. package/presets/claude/php-laravel/skills/feature-delivery/SKILL.md +5 -4
  238. package/presets/claude/php-laravel/skills/spec-authoring/SKILL.md +26 -0
  239. package/presets/claude/svelte/agents/README.md +2 -1
  240. package/presets/claude/svelte/agents/build-verifier.md +9 -0
  241. package/presets/claude/svelte/agents/code-reviewer.md +2 -0
  242. package/presets/claude/svelte/agents/feature-developer.md +13 -0
  243. package/presets/claude/svelte/agents/mockup-reviewer.md +59 -0
  244. package/presets/claude/svelte/agents/task-analyst.md +37 -1
  245. package/presets/claude/svelte/agents/task-router.md +23 -3
  246. package/presets/claude/svelte/agents/tech-writer.md +5 -0
  247. package/presets/claude/svelte/commands/feature-continue.md +4 -0
  248. package/presets/claude/svelte/commands/feature-start.md +8 -0
  249. package/presets/claude/svelte/commands/spec-start.md +29 -0
  250. package/presets/claude/svelte/commands/task-continue.md +11 -6
  251. package/presets/claude/svelte/commands/task.md +2 -0
  252. package/presets/claude/svelte/hooks/chain-team-phases.sh +26 -0
  253. package/presets/claude/svelte/rules/README.md +7 -0
  254. package/presets/claude/svelte/rules/architecture/feature-delivery-workflow.md +6 -0
  255. package/presets/claude/svelte/rules/architecture/product-specs-authoring.md +121 -0
  256. package/presets/claude/svelte/rules/architecture/product-specs.md +62 -0
  257. package/presets/claude/svelte/rules/tooling-and-review/agent-team-orchestrator.md +8 -3
  258. package/presets/claude/svelte/rules/tooling-and-review/mockup-review.md +118 -0
  259. package/presets/claude/svelte/rules/tooling-and-review/preset-no-cross-stack-leakage.md +4 -2
  260. package/presets/claude/svelte/rules/tooling-and-review/ux-design.md +110 -0
  261. package/presets/claude/svelte/skills/README.md +2 -0
  262. package/presets/claude/svelte/skills/feature-delivery/SKILL.md +7 -3
  263. package/presets/claude/svelte/skills/mockup-review/SKILL.md +29 -0
  264. package/presets/claude/svelte/skills/spec-authoring/SKILL.md +26 -0
  265. package/presets/claude/svelte/skills/ux-design/SKILL.md +36 -0
  266. package/presets/claude/svelte/team/fixtures/artifact-manifest.example.json +20 -2
  267. package/presets/claude/svelte/team/fixtures/feature-with-figma-url.json +17 -0
  268. package/presets/claude/svelte/team/fixtures/feature-with-ux-no-figma.json +17 -0
  269. package/presets/claude/svelte/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  270. package/presets/claude/svelte/team/fixtures/mockup-review-standalone.json +14 -0
  271. package/presets/claude/svelte/team/fixtures/ux-design-standalone.json +15 -0
  272. package/presets/cursor/android-kotlin/agents/README.md +2 -2
  273. package/presets/cursor/android-kotlin/agents/build-verifier.md +9 -0
  274. package/presets/cursor/android-kotlin/agents/code-reviewer.md +2 -0
  275. package/presets/cursor/android-kotlin/agents/feature-developer.md +13 -0
  276. package/presets/cursor/android-kotlin/agents/mockup-reviewer.md +60 -0
  277. package/presets/cursor/android-kotlin/agents/task-analyst.md +37 -1
  278. package/presets/cursor/android-kotlin/agents/task-router.md +22 -2
  279. package/presets/cursor/android-kotlin/agents/tech-writer.md +5 -0
  280. package/presets/cursor/android-kotlin/commands/feature-continue.md +4 -0
  281. package/presets/cursor/android-kotlin/commands/feature-start.md +8 -0
  282. package/presets/cursor/android-kotlin/commands/spec-start.md +29 -0
  283. package/presets/cursor/android-kotlin/commands/task-continue.md +11 -6
  284. package/presets/cursor/android-kotlin/commands/task.md +2 -0
  285. package/presets/cursor/android-kotlin/hooks/chain-team-phases.sh +26 -0
  286. package/presets/cursor/android-kotlin/rules/README.md +7 -0
  287. package/presets/cursor/android-kotlin/rules/agent-team-orchestrator.mdc +8 -3
  288. package/presets/cursor/android-kotlin/rules/feature-delivery-workflow.mdc +6 -0
  289. package/presets/cursor/android-kotlin/rules/mockup-review.mdc +116 -0
  290. package/presets/cursor/android-kotlin/rules/preset-no-cross-stack-leakage.mdc +4 -3
  291. package/presets/cursor/android-kotlin/rules/product-specs-authoring.mdc +123 -0
  292. package/presets/cursor/android-kotlin/rules/product-specs.mdc +64 -0
  293. package/presets/cursor/android-kotlin/rules/ux-design.mdc +108 -0
  294. package/presets/cursor/android-kotlin/skills/README.md +2 -0
  295. package/presets/cursor/android-kotlin/skills/feature-delivery/SKILL.md +8 -4
  296. package/presets/cursor/android-kotlin/skills/mockup-review/SKILL.md +29 -0
  297. package/presets/cursor/android-kotlin/skills/spec-authoring/SKILL.md +26 -0
  298. package/presets/cursor/android-kotlin/skills/ux-design/SKILL.md +36 -0
  299. package/presets/cursor/android-kotlin/team/fixtures/artifact-manifest.example.json +25 -0
  300. package/presets/cursor/android-kotlin/team/fixtures/feature-with-figma-url.json +17 -0
  301. package/presets/cursor/android-kotlin/team/fixtures/feature-with-ux-no-figma.json +17 -0
  302. package/presets/cursor/android-kotlin/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  303. package/presets/cursor/android-kotlin/team/fixtures/mockup-review-standalone.json +14 -0
  304. package/presets/cursor/android-kotlin/team/fixtures/ux-design-standalone.json +15 -0
  305. package/presets/cursor/go/MCP.md +1 -1
  306. package/presets/cursor/go/agents/build-verifier.md +9 -0
  307. package/presets/cursor/go/agents/code-reviewer.md +2 -0
  308. package/presets/cursor/go/agents/feature-developer.md +7 -0
  309. package/presets/cursor/go/agents/task-analyst.md +19 -0
  310. package/presets/cursor/go/agents/task-router.md +12 -1
  311. package/presets/cursor/go/agents/tech-writer.md +5 -0
  312. package/presets/cursor/go/commands/feature-continue.md +4 -0
  313. package/presets/cursor/go/commands/feature-start.md +8 -0
  314. package/presets/cursor/go/commands/spec-start.md +29 -0
  315. package/presets/cursor/go/commands/task-continue.md +6 -3
  316. package/presets/cursor/go/rules/README.md +4 -1
  317. package/presets/cursor/go/rules/agent-team-orchestrator.mdc +2 -0
  318. package/presets/cursor/go/rules/feature-delivery-workflow.mdc +4 -0
  319. package/presets/cursor/go/rules/preset-no-cross-stack-leakage.mdc +4 -2
  320. package/presets/cursor/go/rules/product-specs-authoring.mdc +123 -0
  321. package/presets/cursor/go/rules/product-specs.mdc +65 -0
  322. package/presets/cursor/go/skills/feature-delivery/SKILL.md +5 -4
  323. package/presets/cursor/go/skills/spec-authoring/SKILL.md +26 -0
  324. package/presets/cursor/ios-swift/agents/README.md +2 -2
  325. package/presets/cursor/ios-swift/agents/build-verifier.md +9 -0
  326. package/presets/cursor/ios-swift/agents/code-reviewer.md +2 -0
  327. package/presets/cursor/ios-swift/agents/feature-developer.md +13 -0
  328. package/presets/cursor/ios-swift/agents/mockup-reviewer.md +60 -0
  329. package/presets/cursor/ios-swift/agents/task-analyst.md +37 -1
  330. package/presets/cursor/ios-swift/agents/task-router.md +22 -2
  331. package/presets/cursor/ios-swift/agents/tech-writer.md +2 -15
  332. package/presets/cursor/ios-swift/commands/feature-continue.md +4 -0
  333. package/presets/cursor/ios-swift/commands/feature-start.md +8 -0
  334. package/presets/cursor/ios-swift/commands/spec-start.md +29 -0
  335. package/presets/cursor/ios-swift/commands/task-continue.md +11 -6
  336. package/presets/cursor/ios-swift/commands/task.md +2 -0
  337. package/presets/cursor/ios-swift/hooks/chain-team-phases.sh +26 -0
  338. package/presets/cursor/ios-swift/rules/README.md +8 -1
  339. package/presets/cursor/ios-swift/rules/agent-team-orchestrator.mdc +8 -3
  340. package/presets/cursor/ios-swift/rules/feature-delivery-workflow.mdc +6 -0
  341. package/presets/cursor/ios-swift/rules/mockup-review.mdc +116 -0
  342. package/presets/cursor/ios-swift/rules/preset-no-cross-stack-leakage.mdc +4 -2
  343. package/presets/cursor/ios-swift/rules/product-specs-authoring.mdc +123 -0
  344. package/presets/cursor/ios-swift/rules/product-specs.mdc +64 -0
  345. package/presets/cursor/ios-swift/rules/ux-design.mdc +108 -0
  346. package/presets/cursor/ios-swift/skills/README.md +2 -0
  347. package/presets/cursor/ios-swift/skills/feature-delivery/SKILL.md +8 -4
  348. package/presets/cursor/ios-swift/skills/mockup-review/SKILL.md +29 -0
  349. package/presets/cursor/ios-swift/skills/spec-authoring/SKILL.md +26 -0
  350. package/presets/cursor/ios-swift/skills/ux-design/SKILL.md +36 -0
  351. package/presets/cursor/ios-swift/team/fixtures/artifact-manifest.example.json +25 -0
  352. package/presets/cursor/ios-swift/team/fixtures/feature-with-figma-url.json +17 -0
  353. package/presets/cursor/ios-swift/team/fixtures/feature-with-ux-no-figma.json +17 -0
  354. package/presets/cursor/ios-swift/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  355. package/presets/cursor/ios-swift/team/fixtures/mockup-review-standalone.json +14 -0
  356. package/presets/cursor/ios-swift/team/fixtures/ux-design-standalone.json +15 -0
  357. package/presets/cursor/java/agents/build-verifier.md +10 -1
  358. package/presets/cursor/java/agents/code-reviewer.md +2 -0
  359. package/presets/cursor/java/agents/feature-developer.md +7 -0
  360. package/presets/cursor/java/agents/task-analyst.md +19 -0
  361. package/presets/cursor/java/agents/task-router.md +12 -1
  362. package/presets/cursor/java/agents/tech-writer.md +5 -0
  363. package/presets/cursor/java/commands/feature-continue.md +4 -0
  364. package/presets/cursor/java/commands/feature-start.md +8 -0
  365. package/presets/cursor/java/commands/spec-start.md +29 -0
  366. package/presets/cursor/java/commands/task-continue.md +6 -3
  367. package/presets/cursor/java/rules/README.md +4 -1
  368. package/presets/cursor/java/rules/agent-team-orchestrator.mdc +2 -0
  369. package/presets/cursor/java/rules/feature-delivery-workflow.mdc +4 -0
  370. package/presets/cursor/java/rules/preset-no-cross-stack-leakage.mdc +4 -2
  371. package/presets/cursor/java/rules/product-specs-authoring.mdc +123 -0
  372. package/presets/cursor/java/rules/product-specs.mdc +65 -0
  373. package/presets/cursor/java/skills/feature-delivery/SKILL.md +5 -4
  374. package/presets/cursor/java/skills/spec-authoring/SKILL.md +26 -0
  375. package/presets/cursor/mcp-ts/agents/build-verifier.md +10 -1
  376. package/presets/cursor/mcp-ts/agents/feature-developer.md +7 -0
  377. package/presets/cursor/mcp-ts/agents/task-analyst.md +21 -0
  378. package/presets/cursor/mcp-ts/agents/task-router.md +12 -1
  379. package/presets/cursor/mcp-ts/commands/feature-continue.md +4 -0
  380. package/presets/cursor/mcp-ts/commands/feature-start.md +8 -0
  381. package/presets/cursor/mcp-ts/commands/spec-start.md +29 -0
  382. package/presets/cursor/mcp-ts/commands/task-continue.md +6 -3
  383. package/presets/cursor/mcp-ts/rules/README.md +2 -0
  384. package/presets/cursor/mcp-ts/rules/agent-team-orchestrator.mdc +2 -0
  385. package/presets/cursor/mcp-ts/rules/feature-delivery-workflow.mdc +4 -0
  386. package/presets/cursor/mcp-ts/rules/preset-no-cross-stack-leakage.mdc +4 -2
  387. package/presets/cursor/mcp-ts/rules/product-specs-authoring.mdc +123 -0
  388. package/presets/cursor/mcp-ts/rules/product-specs.mdc +65 -0
  389. package/presets/cursor/mcp-ts/skills/feature-delivery/SKILL.md +4 -3
  390. package/presets/cursor/mcp-ts/skills/spec-authoring/SKILL.md +26 -0
  391. package/presets/cursor/next/agents/README.md +2 -1
  392. package/presets/cursor/next/agents/build-verifier.md +9 -0
  393. package/presets/cursor/next/agents/code-reviewer.md +1 -0
  394. package/presets/cursor/next/agents/feature-developer.md +13 -0
  395. package/presets/cursor/next/agents/mockup-reviewer.md +60 -0
  396. package/presets/cursor/next/agents/task-analyst.md +37 -1
  397. package/presets/cursor/next/agents/task-router.md +23 -3
  398. package/presets/cursor/next/agents/tech-writer.md +5 -0
  399. package/presets/cursor/next/commands/feature-continue.md +4 -0
  400. package/presets/cursor/next/commands/feature-start.md +8 -0
  401. package/presets/cursor/next/commands/spec-start.md +29 -0
  402. package/presets/cursor/next/commands/task-continue.md +11 -6
  403. package/presets/cursor/next/commands/task.md +2 -0
  404. package/presets/cursor/next/hooks/chain-team-phases.sh +26 -0
  405. package/presets/cursor/next/rules/README.md +5 -1
  406. package/presets/cursor/next/rules/agent-team-orchestrator.mdc +8 -3
  407. package/presets/cursor/next/rules/feature-delivery-workflow.mdc +6 -0
  408. package/presets/cursor/next/rules/mockup-review.mdc +116 -0
  409. package/presets/cursor/next/rules/preset-no-cross-stack-leakage.mdc +4 -2
  410. package/presets/cursor/next/rules/product-specs-authoring.mdc +123 -0
  411. package/presets/cursor/next/rules/product-specs.mdc +65 -0
  412. package/presets/cursor/next/rules/ux-design.mdc +108 -0
  413. package/presets/cursor/next/skills/README.md +2 -0
  414. package/presets/cursor/next/skills/feature-delivery/SKILL.md +7 -3
  415. package/presets/cursor/next/skills/mockup-review/SKILL.md +29 -0
  416. package/presets/cursor/next/skills/spec-authoring/SKILL.md +26 -0
  417. package/presets/cursor/next/skills/ux-design/SKILL.md +36 -0
  418. package/presets/cursor/next/team/fixtures/artifact-manifest.example.json +20 -2
  419. package/presets/cursor/next/team/fixtures/feature-with-figma-url.json +17 -0
  420. package/presets/cursor/next/team/fixtures/feature-with-ux-no-figma.json +17 -0
  421. package/presets/cursor/next/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  422. package/presets/cursor/next/team/fixtures/mockup-review-standalone.json +14 -0
  423. package/presets/cursor/next/team/fixtures/ux-design-standalone.json +15 -0
  424. package/presets/cursor/nuxt/agents/README.md +2 -1
  425. package/presets/cursor/nuxt/agents/build-verifier.md +9 -0
  426. package/presets/cursor/nuxt/agents/code-reviewer.md +2 -0
  427. package/presets/cursor/nuxt/agents/feature-developer.md +13 -0
  428. package/presets/cursor/nuxt/agents/mockup-reviewer.md +60 -0
  429. package/presets/cursor/nuxt/agents/task-analyst.md +37 -1
  430. package/presets/cursor/nuxt/agents/task-router.md +23 -3
  431. package/presets/cursor/nuxt/agents/tech-writer.md +5 -0
  432. package/presets/cursor/nuxt/commands/feature-continue.md +4 -0
  433. package/presets/cursor/nuxt/commands/feature-start.md +8 -0
  434. package/presets/cursor/nuxt/commands/spec-start.md +29 -0
  435. package/presets/cursor/nuxt/commands/task-continue.md +11 -6
  436. package/presets/cursor/nuxt/commands/task.md +2 -0
  437. package/presets/cursor/nuxt/hooks/chain-team-phases.sh +26 -0
  438. package/presets/cursor/nuxt/rules/README.md +5 -1
  439. package/presets/cursor/nuxt/rules/agent-team-orchestrator.mdc +8 -3
  440. package/presets/cursor/nuxt/rules/feature-delivery-workflow.mdc +6 -0
  441. package/presets/cursor/nuxt/rules/mockup-review.mdc +116 -0
  442. package/presets/cursor/nuxt/rules/preset-no-cross-stack-leakage.mdc +4 -2
  443. package/presets/cursor/nuxt/rules/product-specs-authoring.mdc +123 -0
  444. package/presets/cursor/nuxt/rules/product-specs.mdc +64 -0
  445. package/presets/cursor/nuxt/rules/ux-design.mdc +108 -0
  446. package/presets/cursor/nuxt/skills/README.md +2 -0
  447. package/presets/cursor/nuxt/skills/feature-delivery/SKILL.md +7 -3
  448. package/presets/cursor/nuxt/skills/mockup-review/SKILL.md +29 -0
  449. package/presets/cursor/nuxt/skills/spec-authoring/SKILL.md +26 -0
  450. package/presets/cursor/nuxt/skills/ux-design/SKILL.md +36 -0
  451. package/presets/cursor/nuxt/team/fixtures/artifact-manifest.example.json +20 -2
  452. package/presets/cursor/nuxt/team/fixtures/feature-with-figma-url.json +17 -0
  453. package/presets/cursor/nuxt/team/fixtures/feature-with-ux-no-figma.json +17 -0
  454. package/presets/cursor/nuxt/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  455. package/presets/cursor/nuxt/team/fixtures/mockup-review-standalone.json +14 -0
  456. package/presets/cursor/nuxt/team/fixtures/ux-design-standalone.json +15 -0
  457. package/presets/cursor/php-hexagonal/agents/build-verifier.md +10 -1
  458. package/presets/cursor/php-hexagonal/agents/code-reviewer.md +2 -0
  459. package/presets/cursor/php-hexagonal/agents/feature-developer.md +7 -0
  460. package/presets/cursor/php-hexagonal/agents/task-analyst.md +19 -0
  461. package/presets/cursor/php-hexagonal/agents/task-router.md +12 -1
  462. package/presets/cursor/php-hexagonal/agents/tech-writer.md +5 -0
  463. package/presets/cursor/php-hexagonal/commands/feature-continue.md +4 -0
  464. package/presets/cursor/php-hexagonal/commands/feature-start.md +8 -0
  465. package/presets/cursor/php-hexagonal/commands/spec-start.md +29 -0
  466. package/presets/cursor/php-hexagonal/commands/task-continue.md +6 -3
  467. package/presets/cursor/php-hexagonal/rules/README.md +4 -1
  468. package/presets/cursor/php-hexagonal/rules/agent-team-orchestrator.mdc +2 -0
  469. package/presets/cursor/php-hexagonal/rules/feature-delivery-workflow.mdc +4 -0
  470. package/presets/cursor/php-hexagonal/rules/preset-no-cross-stack-leakage.mdc +4 -2
  471. package/presets/cursor/php-hexagonal/rules/product-specs-authoring.mdc +123 -0
  472. package/presets/cursor/php-hexagonal/rules/product-specs.mdc +65 -0
  473. package/presets/cursor/php-hexagonal/skills/feature-delivery/SKILL.md +5 -4
  474. package/presets/cursor/php-hexagonal/skills/spec-authoring/SKILL.md +26 -0
  475. package/presets/cursor/php-laravel/agents/build-verifier.md +10 -1
  476. package/presets/cursor/php-laravel/agents/code-reviewer.md +2 -0
  477. package/presets/cursor/php-laravel/agents/feature-developer.md +7 -0
  478. package/presets/cursor/php-laravel/agents/task-analyst.md +19 -0
  479. package/presets/cursor/php-laravel/agents/task-router.md +12 -1
  480. package/presets/cursor/php-laravel/agents/tech-writer.md +5 -0
  481. package/presets/cursor/php-laravel/commands/feature-continue.md +4 -0
  482. package/presets/cursor/php-laravel/commands/feature-start.md +8 -0
  483. package/presets/cursor/php-laravel/commands/spec-start.md +29 -0
  484. package/presets/cursor/php-laravel/commands/task-continue.md +6 -3
  485. package/presets/cursor/php-laravel/rules/README.md +4 -1
  486. package/presets/cursor/php-laravel/rules/agent-team-orchestrator.mdc +2 -0
  487. package/presets/cursor/php-laravel/rules/feature-delivery-workflow.mdc +4 -0
  488. package/presets/cursor/php-laravel/rules/preset-no-cross-stack-leakage.mdc +4 -2
  489. package/presets/cursor/php-laravel/rules/product-specs-authoring.mdc +123 -0
  490. package/presets/cursor/php-laravel/rules/product-specs.mdc +65 -0
  491. package/presets/cursor/php-laravel/skills/feature-delivery/SKILL.md +5 -4
  492. package/presets/cursor/php-laravel/skills/spec-authoring/SKILL.md +26 -0
  493. package/presets/cursor/svelte/agents/README.md +2 -1
  494. package/presets/cursor/svelte/agents/build-verifier.md +9 -0
  495. package/presets/cursor/svelte/agents/code-reviewer.md +2 -0
  496. package/presets/cursor/svelte/agents/feature-developer.md +13 -0
  497. package/presets/cursor/svelte/agents/mockup-reviewer.md +60 -0
  498. package/presets/cursor/svelte/agents/task-analyst.md +37 -1
  499. package/presets/cursor/svelte/agents/task-router.md +23 -3
  500. package/presets/cursor/svelte/agents/tech-writer.md +5 -0
  501. package/presets/cursor/svelte/commands/feature-continue.md +4 -0
  502. package/presets/cursor/svelte/commands/feature-start.md +8 -0
  503. package/presets/cursor/svelte/commands/spec-start.md +29 -0
  504. package/presets/cursor/svelte/commands/task-continue.md +11 -6
  505. package/presets/cursor/svelte/commands/task.md +2 -0
  506. package/presets/cursor/svelte/hooks/chain-team-phases.sh +26 -0
  507. package/presets/cursor/svelte/rules/README.md +5 -1
  508. package/presets/cursor/svelte/rules/agent-team-orchestrator.mdc +8 -3
  509. package/presets/cursor/svelte/rules/feature-delivery-workflow.mdc +6 -0
  510. package/presets/cursor/svelte/rules/mockup-review.mdc +116 -0
  511. package/presets/cursor/svelte/rules/preset-no-cross-stack-leakage.mdc +4 -2
  512. package/presets/cursor/svelte/rules/product-specs-authoring.mdc +123 -0
  513. package/presets/cursor/svelte/rules/product-specs.mdc +64 -0
  514. package/presets/cursor/svelte/rules/ux-design.mdc +108 -0
  515. package/presets/cursor/svelte/skills/README.md +2 -0
  516. package/presets/cursor/svelte/skills/feature-delivery/SKILL.md +7 -3
  517. package/presets/cursor/svelte/skills/mockup-review/SKILL.md +29 -0
  518. package/presets/cursor/svelte/skills/spec-authoring/SKILL.md +26 -0
  519. package/presets/cursor/svelte/skills/ux-design/SKILL.md +36 -0
  520. package/presets/cursor/svelte/team/fixtures/artifact-manifest.example.json +20 -2
  521. package/presets/cursor/svelte/team/fixtures/feature-with-figma-url.json +17 -0
  522. package/presets/cursor/svelte/team/fixtures/feature-with-ux-no-figma.json +17 -0
  523. package/presets/cursor/svelte/team/fixtures/mockup-review-fail-embedded-status.json +8 -0
  524. package/presets/cursor/svelte/team/fixtures/mockup-review-standalone.json +14 -0
  525. package/presets/cursor/svelte/team/fixtures/ux-design-standalone.json +15 -0
@@ -0,0 +1,65 @@
1
+ ---
2
+ description: Product page/feature specs under docs/specs — INDEX discovery for agents
3
+ globs:
4
+ - docs/specs/**/*
5
+ alwaysApply: false
6
+ ---
7
+
8
+ <!-- shared-core: architecture/product-specs.md -->
9
+
10
+ # Product specs (docs/specs)
11
+
12
+ Product page/feature **behavior** specs live under the consumer repo `docs/specs/**`. This stem covers **discovery and presence** — not layer implementation order (see `feature-delivery-workflow`) and not code-structure mirroring (see `reference-features`).
13
+
14
+ **Authoring** (Generate / Bootstrap modes, INDEX/frontmatter v1, body checklist, greenfield, conflict precedence) → load **`product-specs-authoring`** when generation is requested (`/spec-start`, brief AC, or router `spec-gen`).
15
+
16
+ ## Modes (summary)
17
+
18
+ | Mode | When | Behavior |
19
+ |------|------|----------|
20
+ | **Consume** (default) | INDEX exists or globs hit `docs/specs/**` without generate intent | Discover via INDEX; soft-fail on miss; **never invent** INDEX/specs |
21
+ | **Generate** | Explicit generate intent / AC / `/spec-start` with existing tree | Create/update page/feature specs + INDEX from stated sources |
22
+ | **Bootstrap** | Explicit bootstrap / `/spec-start` when tree absent | Create INDEX + templates + first domain spec |
23
+
24
+ Greenfield: agents may create INDEX/specs **only** on explicit intent, AC, or `/spec-start`. Missing INDEX alone does **not** authorize inventing the tree.
25
+
26
+ ## Presence policy
27
+
28
+ - If `docs/specs/INDEX.md` is **missing** → the tree is **optional** (greenfield OK for *consume*). Continue with code/brief discovery; do not invent an INDEX solely because this stem loaded.
29
+ - If INDEX **exists** → it is the **required discovery path** for work that touches a listed page, feature, route, or alias.
30
+
31
+ ## Discovery algorithm
32
+
33
+ 1. Always start at `docs/specs/INDEX.md` when present.
34
+ 2. Resolve the entry by: route, stable `id`, PageName / alias, or domain folder.
35
+ 3. Read the linked page spec (and optional domain `feature.md` when the INDEX or page Related links it).
36
+
37
+ ## Miss policy (INDEX present, row or file missing)
38
+
39
+ - Record the gap in `open_questions` / handoff gaps.
40
+ - Fall back to code discovery and consumer `.ai/context/**` when present.
41
+ - **Do not invent** product behavior, states, interactions, or contracts.
42
+ - Hard-fail / block only when the task’s acceptance criteria explicitly require a named spec that is absent (human/gate decision).
43
+
44
+ ## Authoring pointer
45
+
46
+ Same-changeset INDEX updates, frontmatter v1, required body headings, templates, and conflict precedence live in **`product-specs-authoring`**. Do not paste the full checklist here.
47
+
48
+ ## Non-goals
49
+
50
+ - Not a replacement for `.ai/context/**` (external AI Code Review glossary) or `reference-features` (file-layout mirror).
51
+ - Not Tessl / an external host as primary SoT.
52
+ - No stack filesystem path recipes in this core body — path examples belong only in adapter **Stack notes**.
53
+
54
+ ## Related
55
+
56
+ - `product-specs-authoring` — generation modes, contracts, self-check.
57
+ - `reference-features` — code structure mirror (how to layout files), not product behavior.
58
+ - Consumer `.ai/context/**` when present — review/domain glossary; cross-link, do not replace.
59
+
60
+
61
+ ## Stack notes
62
+
63
+ - `routes`: HTTP paths. `ui` / `store`: usually `[]` (or handler labels). `e2e`: integration/contract test paths.
64
+ - **Forbidden:** requiring `app/src/ui`, Playwright paths, or Next lint recipes.
65
+ - Requestable / `docs/specs/**` globs — not always-on / session-start.
@@ -6,10 +6,11 @@ description: Delivers Java hexagonal backend features end-to-end across domain,
6
6
  # Feature Delivery (Java hexagonal)
7
7
 
8
8
  1. Read brief, AC, and decomposition.
9
- 2. Follow `feature-delivery-workflow.mdc` + `reference-features.mdc`: domain application/ports driven adapters driving adapters composition root tests.
10
- 3. Wire DI only in `configuration/` / `*Application.java`.
11
- 4. Add unit tests for domain/use cases; integration tests for risky adapters.
12
- 5. After Java edits: **invoke** `post-change-test.mdc` (+ `java-tooling.mdc`).
9
+ 2. If `docs/specs/INDEX.md` exists **or** brief/handoff lists approved generated specs, resolve via **`product-specs`** and treat approved specs as behavior SoT before layer work (soft-fail on miss — do not invent behavior). If generation was requested but not yet approved, stop for human gate do not implement against draft-only gaps.
10
+ 3. Follow `feature-delivery-workflow.mdc` + `reference-features.mdc`: domain → application/ports → driven adapters → driving adapters → composition root → tests.
11
+ 4. Wire DI only in `configuration/` / `*Application.java`.
12
+ 5. Add unit tests for domain/use cases; integration tests for risky adapters.
13
+ 6. After Java edits: **invoke** `post-change-test.mdc` (+ `java-tooling.mdc`).
13
14
 
14
15
  ## Do / Don't
15
16
 
@@ -0,0 +1,26 @@
1
+ ---
2
+ name: spec-authoring
3
+ description: Author or bootstrap consumer docs/specs (INDEX, page/feature templates, frontmatter v1). Use with task-analyst author mode, /spec-start, or when brief AC requests Generate/Bootstrap.
4
+ ---
5
+
6
+ # Spec authoring
7
+
8
+ Requestable — not always-on. Load **`product-specs`** + **`product-specs-authoring`** first.
9
+
10
+ ## Steps
11
+
12
+ 1. **Resolve mode** — Generate (tree exists) vs Bootstrap (create INDEX + templates + first spec). Refuse inventing INDEX without explicit intent/AC/`/spec-start`.
13
+ 2. **Ensure templates** — if consumer `docs/specs/_templates/` missing, copy from package SoT `presets/_shared/assets/docs-specs/_templates/` (or seeded init assets).
14
+ 3. **Fill frontmatter v1** — all array keys present (may be `[]`); prefer `type: feature` on backend/MCP; default `status: draft`.
15
+ 4. **Fill required body headings** — page: Overview, Entry/actors, Primary flows, States, Acceptance criteria; feature: Overview, Shared behavior/constraints, Related pages. Use `N/A` explicitly when needed.
16
+ 5. **Update INDEX** in the **same change set** (columns: id, type, domain, title, path, optional routes/aliases/status).
17
+ 6. **Self-check** against `product-specs-authoring` checklist; put blockers in `open_questions`.
18
+ 7. **Handoff** — list created/updated paths + INDEX diff for human gate (`after:task-analyst`). Approve before feature-developer.
19
+
20
+ ## Sources
21
+
22
+ Cite AC / user / Figma / labeled code inference. Do not invent product behavior.
23
+
24
+ ## mcp-ts
25
+
26
+ Analyst-only path (no tech-writer). `routes` = tool names; `ui`/`store` = `[]`.
@@ -35,12 +35,21 @@ Document PASS/FAIL in `validation-report.md`. Soft leakage output:
35
35
 
36
36
  1. **Root AGENTS template:** each installable preset (`cursor|claude` × `next|nuxt|svelte|ios-swift|go|java|mcp-ts|php-hexagonal|php-laravel`) must ship `REPO_AGENTS.md` when validating preset packaging → **FAIL** if missing.
37
37
  2. **Hooks cookbook:** default `hooks.json` must **not** reference `hooks/examples/` → **FAIL** if it does.
38
- 3. **Forbidden agent filenames** (Playwright / XCUITest / integration-test / accessibility-reviewer / contract-test): must be absent → **FAIL** via `check:preset-leakage`.
38
+ 3. **Forbidden agent filenames** (Playwright / XCUITest / integration-test / accessibility-reviewer / mockup-reviewer / ux-designer / contract-test): must be absent → **FAIL** via `check:preset-leakage`.
39
39
  4. **Rule eval (WARN):** optional maintainer smoke — not part of default `check:preset-structure`.
40
40
 
41
+
42
+ **Forbidden mockup-reviewer:** agent file `agents/mockup-reviewer.md` or required `AGENT_HANDOFF` / pipeline handoff for `mockup-reviewer` → **FAIL** (no UI mockup reviewer).
43
+
44
+ **Forbidden ux-designer / ux-design:** agent file `agents/ux-designer.md` or required `skills/ux-design` / `rules/ux-design` / pipeline handoff stem `ux-design` → **FAIL** (no UI UX surface).
45
+
46
+
41
47
  ## Artifact contract
42
48
 
43
49
  - **Authoritative inputs:** read `.cursor/team/tasks/<slug>/artifact-manifest.json` first; consume handoff `artifactInputIds` when supplied, otherwise consume the manifest entries for brief/decomposition, implementation evidence, pipeline scope, and changed files.
44
50
  - **Owned outputs:** `validation-report.md`; upsert only the manifest entry assigned by handoff (`artifactOutputId`; fallback `validation`) and preserve all foreign entries.
45
51
  - **Terminal receipt:** cover applicable AC/task IDs, list authoritative evidence paths, and emit `completed` or `validation_failed`. Bind it to the supplied `attemptId` when present.
46
52
  - **Shared state:** never create or mutate `status.json` or `metrics.json`; the orchestration runtime/hook owns lifecycle, gates, retries, attempts, and timestamps.
53
+
54
+ 13. **Product-specs assets (FAIL):** package must ship `presets/_shared/assets/docs-specs/INDEX.md`, `_templates/page.md`, `_templates/feature.md`. Cursor+Claude twins for `product-specs` and `product-specs-authoring` must embed matching shared-core markers; both stems **requestable** (`alwaysApply: false` / Claude `paths: docs/specs/**`) — never session-start.
55
+ 14. **Optional consumer check (WARN default):** `scripts/check-product-specs.sh` + schema stub may exist for opt-in consumer CI; **FAIL** only with `--strict` or AC that requires named specs — do not force consumer CI.
@@ -45,6 +45,13 @@ Implement MCP server features following **mcp-ts** boundaries.
45
45
  - Load `design-guidance` and `anti-sycophancy-discipline` when writing or changing code.
46
46
 
47
47
 
48
+ ## Product specs (docs/specs)
49
+
50
+ When work touches a page/feature/route/alias: if `docs/specs/INDEX.md` exists (or brief lists approved specs), load **`product-specs`** and treat **approved** specs from brief/handoff as **behavior SoT**. Soft-fail on miss (`open_questions` + code / `.ai/context` fallback); **never invent** product behavior.
51
+
52
+ Mechanical INDEX/frontmatter fixes only when implementation renames routes/ids. Substantive behavior edits → hand back to task-analyst (or tech-writer where present). If INDEX is absent and generation was not approved, treat specs as optional (greenfield).
53
+
54
+
48
55
  ## Artifact contract
49
56
 
50
57
  - **Authoritative inputs:** read `.cursor/team/tasks/<slug>/artifact-manifest.json` first; consume handoff `artifactInputIds` when supplied, otherwise consume the manifest entries for `brief.md`, `decomposition.md`, current scope, and applicable prior findings.
@@ -24,6 +24,27 @@ Analyze MCP server work requests for the **mcp-ts** preset.
24
24
  - Schedule Phase 2-only agents.
25
25
  - Prescribe Go hexagonal or Next app layers.
26
26
 
27
+ ## Product specs (docs/specs)
28
+
29
+ **Consume (default):** When work touches a page/feature/route/alias and `docs/specs/INDEX.md` exists, load **`product-specs`**, resolve the linked page/feature spec, and cite it under **Related specs** in `brief.md`. Soft-fail on miss (`open_questions` + code / `.ai/context` fallback); **never invent** product behavior. If INDEX is absent, treat specs as optional unless author mode applies.
30
+
31
+ **Author mode (Generate / Bootstrap):** When the user runs `/spec-start`, router intent is `spec-gen` / bootstrap, or brief/AC requests generation: load **`product-specs`** + **`product-specs-authoring`** and skill **`spec-authoring`**. You are the **primary author** (INDEX bootstrap included). Follow frontmatter v1 + required headings; update INDEX in the **same change set**; default `status: draft`. Block handoff via `open_questions` until the authoring self-check passes.
32
+
33
+ ### Brief sections (when author mode or INDEX exists)
34
+
35
+ Add to `brief.md`:
36
+
37
+ ```markdown
38
+ ## Related specs
39
+ - path or id (or N/A)
40
+
41
+ ## Spec gaps / generation requested
42
+ - [ ] none | generate | bootstrap — sources: …
43
+ ```
44
+
45
+ **mcp-ts:** no tech-writer — own Generate/Bootstrap **and** post-sync via docs-only / regenerate intents. Prefer `type: feature`; `routes` = tool names; `ui`/`store` = `[]`.
46
+
47
+
27
48
  ## Artifact contract
28
49
 
29
50
  - **Authoritative inputs:** read `.cursor/team/tasks/<slug>/artifact-manifest.json` first; consume `pipeline.json`, the manifest routing entry, user-approved decisions, and any authoritative architecture/approval entries.
@@ -38,7 +38,7 @@ Append **`security-reviewer` after `build-verifier`** for `feature` / `bugfix` /
38
38
 
39
39
  **Phase 1 available agents only:** `task-router`, `task-analyst`, `solution-architect`, `feature-developer`, `build-verifier`, `security-reviewer`.
40
40
 
41
- **Never schedule** Playwright (`playwright-test-*`), XCUITest (`xcuitest-test-*`), `accessibility-reviewer`, `integration-test-*`, or Phase 2 `contract-test-*`. Put them in `skipped` with reason "mcp-ts Phase 1 roster".
41
+ **Never schedule** Playwright (`playwright-test-*`), XCUITest (`xcuitest-test-*`), `accessibility-reviewer`, `mockup-reviewer`, `integration-test-*`, or Phase 2 `contract-test-*`. Put them in `skipped` with reason "mcp-ts Phase 1 roster".
42
42
 
43
43
  ## Pipeline profiles
44
44
 
@@ -93,6 +93,17 @@ Write `.cursor/team/tasks/<slug>/pipeline.json` and initialize the routing entry
93
93
 
94
94
  Intent + steps table + skipped + gates → invoke `steps[0].agent` (unless retro).
95
95
 
96
+ ## Spec generation intents
97
+
98
+ Detect and set routing reasons when the user asks to **generate / bootstrap product specs**, mentions `docs/specs`, or runs `/spec-start`:
99
+
100
+ | Signal | Intent | Steps |
101
+ |--------|--------|-------|
102
+ | `/spec-start`, "bootstrap docs/specs", "generate product spec" | `spec-gen` | task-analyst (**author mode**) → human gate → stop (or continue to feature-developer only if implement-after) |
103
+ | Feature/task with AC "generate specs" / missing INDEX + bootstrap AC | `spec-gen` inside feature profile | task-analyst author mode first; **not** a separate agent step |
104
+
105
+ Do **not** add a dedicated `spec-author` agent. Do not require solution-architect for routine spec authoring.
106
+
96
107
  ## Runtime initialization
97
108
 
98
109
  Return the routing receipt to the orchestrator. The orchestration runtime/hook exclusively initializes and updates `status.json`, `metrics.json`, attempt identities, and gate lifecycle; the router does not write those shared runtime files.
@@ -17,3 +17,7 @@ Continue after a human gate. Full logic lives in **`task-continue.md`**.
17
17
  4. The hook continues the chain when `autoChain: true`.
18
18
 
19
19
  See `task-continue.md` for details and the handoff table.
20
+
21
+ ## Product specs (docs/specs)
22
+
23
+ When the next agent is **feature-developer** (or other implementer): if `docs/specs/INDEX.md` exists, instruct them to load **`product-specs`** and honor **Related specs** from `brief.md` (behavior SoT). Soft-fail on miss; never invent product behavior. No-op if INDEX is absent.
@@ -19,11 +19,19 @@ Starts the **analysis phase** without the router. The parent agent acts as orche
19
19
  6. Invoke subagent **task-analyst** (Task tool) with the full task description and artifact paths.
20
20
  7. Wait for the analyst to finish. **Do not invoke developer** at this stage.
21
21
 
22
+ ## Product specs (docs/specs)
23
+
24
+ When invoking **task-analyst**: if `docs/specs/INDEX.md` exists, instruct consume via **`product-specs`** and cite **Related specs**. Soft-fail on miss; never invent behavior.
25
+
26
+ If the user/AC requests generation or bootstrap, or INDEX is missing **with** bootstrap AC / `/spec-start` intent: instruct **author mode** inside the same analyst step — load **`product-specs-authoring`** + skill **`spec-authoring`**. Authoring is **not** a separate pipeline agent. Handoff must list created paths + INDEX diff; human gate must approve generated specs before feature-developer.
27
+
28
+
22
29
  ## Human gate
23
30
 
24
31
  After the analyst:
25
32
 
26
33
  - Show the user links to `brief.md` and `decomposition.md`.
34
+ - Also ask them to check **Related specs** in `brief.md` when `docs/specs/INDEX.md` exists.
27
35
  - Ask them to review and approve or send edits.
28
36
  - To continue: `/task-continue <slug>` or `/feature-continue <slug>`.
29
37
 
@@ -0,0 +1,29 @@
1
+ ---
2
+ name: spec-start
3
+ description: Bootstrap or generate docs/specs (INDEX + page/feature) via task-analyst author mode. Optional docs-only path with human gate.
4
+ ---
5
+
6
+ # Spec start — generate / bootstrap product specs
7
+
8
+ Routes intent **`spec-gen`** (or bootstrap) → **task-analyst** in **author mode** → human gate (`after:task-analyst`) → stop, or continue to feature-developer if the user asked to implement after.
9
+
10
+ ## What to do
11
+
12
+ 1. Extract description from arguments after `/spec-start` (domain, page/feature ids, sources).
13
+ 2. Generate a **slug** (kebab-case, ≤48 chars), e.g. `spec-<domain>-<id>`.
14
+ 3. Ensure `.cursor/team/tasks/<slug>/` exists (Write artifacts; not Shell mkdir).
15
+ 4. Write `.cursor/team/active-task.json` → `{ "slug": "<slug>" }`.
16
+ 5. Write minimal `pipeline.json`: task-analyst → (optional stop) → feature-developer only if user asked implement-after. **No separate spec-author agent.**
17
+ 6. Invoke **task-analyst** with: author mode; load **`product-specs`** + **`product-specs-authoring`** + skill **`spec-authoring`**; Bootstrap if `docs/specs/` absent, else Generate.
18
+ 7. Wait for analyst. **Do not** invoke feature-developer until human gate passes.
19
+
20
+ ## Human gate
21
+
22
+ - Show created/updated spec paths and INDEX diff.
23
+ - Ask user to approve drafts (`status: draft` → promote) or send edits.
24
+ - Continue: `/task-continue <slug>` only after approval when implementation follows; otherwise stop after docs.
25
+
26
+ ## Notes
27
+
28
+ - Greenfield invent of INDEX is allowed **only** via this command, explicit ask, or AC bootstrap language.
29
+ - mcp-ts: analyst-only author/sync (no tech-writer).
@@ -40,11 +40,14 @@ printf '%s\n' '{"status":"completed","action":"end_human_gate","activateNext":tr
40
40
 
41
41
  | Agent | Read |
42
42
  |-------|------|
43
- | feature-developer | brief.md, decomposition.md, validation-report.md (if retry), review.md (if retry), architecture.md |
43
+ | feature-developer | brief.md (incl. **Related specs**), decomposition.md, validation-report.md (if retry), review.md (if retry), architecture.md; if `docs/specs/INDEX.md` exists → load **`product-specs`** |
44
44
  | build-verifier | git diff, decomposition.md |
45
45
  | code-reviewer | brief.md, validation-report.md, git diff |
46
46
  | qa-tester | brief.md, decomposition.md, scope from pipeline step |
47
47
 
48
- ## Metrics
48
+ ## Product specs (docs/specs)
49
+
50
+ When the next agent is **feature-developer** (or other implementer): if `docs/specs/INDEX.md` exists or brief lists approved specs, instruct them to load **`product-specs`** and honor **Related specs** / approved generated specs as behavior SoT. Soft-fail on miss; never invent product behavior.
51
+
52
+ If analyst ran **author mode**, confirm human approved drafts before developer. Pass spec paths + INDEX diff in the handoff. No-op if INDEX is absent and no approved specs.
49
53
 
50
- On human-gate resume, the hook action above appends `human_gate_ended` under the per-task lock **before** any new `attempt_started`. Agents must not calculate durations.
@@ -43,6 +43,8 @@
43
43
  | `agent-team/agent-team-intake.md` | `agent-team-intake.mdc` | embed |
44
44
  | `architecture/feature-delivery-workflow.md` | `feature-delivery-workflow.mdc` | lineage |
45
45
  | `architecture/reference-features.template.md` | `reference-features.mdc` | lineage |
46
+ | `architecture/product-specs.md` | `product-specs.mdc` | INDEX discovery; Stack notes field semantics |
47
+ | `architecture/product-specs-authoring.md` | `product-specs-authoring.mdc` | Generate/Bootstrap contract; requestable |
46
48
  | `review/code-review-mr.md` | `code-review-mr.mdc` | embed |
47
49
  | `review/technical-retro.md` | `technical-retro.mdc` | embed |
48
50
  | `meta/preset-*` (five) | `preset-*.mdc` | embed |
@@ -186,3 +186,5 @@ When the work edits `packages/ai-rules/presets/**` (or dogfood `.cursor/` sync o
186
186
  - **Phase 1 artifacts:** `brief.md`, `decomposition.md`, `architecture.md`, `validation-report.md`, `security-review.md`; schema/style review via parent skill `code-review` → `review.md`. Shared-core names like `a11y-review.md`, `ci-report.md`, `unit-test-plan.md` are N/A until Phase 2 agents ship.
187
187
  - **Review-only:** pipeline step = `security-reviewer` for threat/capability diffs; parent applies skill `code-review` for schema/contract/style (no `code-reviewer` agent in Phase 1).
188
188
  - After TS changes, pipeline includes **build-verifier** with repository typecheck/test via `post-change-test` / `mcp-ts-tooling`.
189
+
190
+ **Product specs:** When `/task`, `/feature-start`, or `/spec-start` touches pages/features/`docs/specs`: if INDEX exists and no generate intent → instruct next agent to load requestable **`product-specs`** (consume; soft-fail; never invent). If generate/bootstrap/`spec-gen` → load **`product-specs-authoring`** + skill **`spec-authoring`** inside **task-analyst** (not a separate pipeline step); pass created spec paths + INDEX diff in handoff; human gate must approve before feature-developer. No-op if INDEX absent and no author intent.
@@ -41,3 +41,7 @@ flowchart LR
41
41
  - Monolithic `index.ts`; unscoped shell/FS tools; inventing SDK APIs; skipping schema tests "for speed".
42
42
  - Prescribing Go hexagonal folders or Next `app/src/**`.
43
43
  - Load `design-guidance` when assessing structure, smells, or pattern fit.
44
+
45
+ ## Related
46
+
47
+ - Product behavior discovery: requestable **`product-specs`** (`docs/specs/INDEX.md`) — do not paste the discovery algorithm here.
@@ -70,7 +70,8 @@ Shared backend-stack bans (`go`, `java`, `php-hexagonal`, and `php-laravel`):
70
70
  - `playwright-test-`, `playwright-e2e`, `user-playwright`, `app/__tests__/e2e`
71
71
  - Positive yarn recipes `lint:js` / `lint:css`
72
72
  - `xcuitest-test-`, `instrumentation-test-`, `xcodebuild`, `SwiftLint` as required handoffs
73
- - Agent file `accessibility-reviewer` (no UI surface)
73
+ - Agent files `accessibility-reviewer`, `mockup-reviewer`, `ux-designer` (no UI surface)
74
+ - Required `skills/ux-design`, required `rules/ux-design`, or required pipeline handoff stem `ux-design`
74
75
 
75
76
  Required instead: `integration-test-*`; build-verifier / `post-change-test` plus stack tooling — `go-tooling` (`go test`, `go vet`), `java-tooling` (`mvn test` / `./gradlew test`), or `php-tooling` (`php artisan test` / `composer test` / `vendor/bin/phpunit`).
76
77
 
@@ -82,7 +83,8 @@ Same UI/mobile bans as backend stacks, plus:
82
83
  - Positive yarn recipes `lint:js` / `lint:css` as required gates
83
84
  - `xcuitest-test-`, `instrumentation-test-`, `xcodebuild`, `SwiftLint` as required handoffs
84
85
  - Go tool commands as required MCP delivery gates: `go test`, `go vet`, `golangci-lint`
85
- - Agent files: `playwright-test-*`, `xcuitest-test-*`, `instrumentation-test-*`, `integration-test-*`, `accessibility-reviewer`
86
+ - Agent files: `playwright-test-*`, `xcuitest-test-*`, `instrumentation-test-*`, `integration-test-*`, `accessibility-reviewer`, `mockup-reviewer`, `ux-designer`
87
+ - Required `skills/ux-design`, required `rules/ux-design`, or required pipeline handoff stem `ux-design`
86
88
 
87
89
  Required instead: package-manager–discovered typecheck/test (`mcp-ts-tooling`, `post-change-test`); Phase 1 gates `build-verifier` + `security-reviewer`.
88
90
 
@@ -0,0 +1,123 @@
1
+ ---
2
+ description: Author/generate product specs (docs/specs) — modes, INDEX/frontmatter, checklist
3
+ globs:
4
+ - docs/specs/**/*
5
+ alwaysApply: false
6
+ ---
7
+
8
+ <!-- shared-core: architecture/product-specs-authoring.md -->
9
+
10
+ # Product specs authoring
11
+
12
+ Load when **Generate** or **Bootstrap** is requested (`/spec-start`, router `spec-gen`, brief AC, or analyst author mode). Discovery-only work stays on **`product-specs`**.
13
+
14
+ ## Modes
15
+
16
+ 1. **Consume** — default; never invent INDEX/specs (see `product-specs`).
17
+ 2. **Generate** — create/update page/feature specs + INDEX rows from brief AC, user intent, Figma, or code archaeology. Inventing *product* behavior is forbidden without a stated source (AC / user / UI copy / code-observed behavior labeled `status: draft` or `inferred`).
18
+ 3. **Bootstrap** — create `INDEX.md` + `_templates/` copies + first domain spec under greenfield policy.
19
+
20
+ ## Greenfield policy
21
+
22
+ Agents **may** create INDEX + first specs **only when** one of:
23
+
24
+ 1. User runs `/spec-start` or explicitly asks to bootstrap `docs/specs`.
25
+ 2. Brief/AC includes generation or bootstrap language.
26
+ 3. Router detects `spec-gen` intent.
27
+
28
+ Otherwise: missing INDEX → optional tree; do **not** invent INDEX merely because discovery loaded.
29
+
30
+ ## Conflict precedence
31
+
32
+ 1. **Human gate** decision (approved brief/spec edits).
33
+ 2. **Current task `brief.md` AC** — if AC contradicts an existing spec, analyst must reconcile (update spec as `draft` or revise AC) before developer; no silent contradiction.
34
+ 3. **Approved `docs/specs/**`** — behavior SoT for feature-developer once gate passed.
35
+ 4. **Code / `.ai/context`** — discovery evidence only; never override approved spec without gate.
36
+
37
+ Label inferred-from-code lines with `status: draft` until human promotes.
38
+
39
+ ## INDEX.md contract (v1)
40
+
41
+ | Column | Required | Notes |
42
+ |--------|----------|-------|
43
+ | `id` | yes | Stable kebab/id matching frontmatter `id` |
44
+ | `type` | yes | `page` \| `feature` |
45
+ | `domain` | yes | Domain folder under `docs/specs/domains/<domain>/` |
46
+ | `title` | yes | Human label |
47
+ | `path` | yes | Repo-relative path to markdown file |
48
+ | `routes` | no | Summary; may duplicate frontmatter |
49
+ | `aliases` | no | Comma-separated PageName / deep-link aliases |
50
+ | `status` | no | `draft` \| `active` \| `deprecated` |
51
+
52
+ Layout: `docs/specs/domains/<domain>/<id>.md` (page) and optional `docs/specs/domains/<domain>/feature.md`. Adding/renaming/removing a linked file **must** update INDEX in the **same change set**.
53
+
54
+ ## Frontmatter v1
55
+
56
+ | Field | Type | Required | Notes |
57
+ |-------|------|----------|-------|
58
+ | `id` | string | yes | Unique; matches INDEX |
59
+ | `type` | enum `page` \| `feature` | yes | Backend/MCP: prefer `feature` |
60
+ | `domain` | string | yes | |
61
+ | `routes` | string[] | yes (may be `[]`) | Web: URL paths; mobile: deep links/screens; backend: HTTP paths; mcp-ts: tool names |
62
+ | `ui` | string[] | yes (may be `[]`) | Component/screen refs; empty on backend/mcp |
63
+ | `store` | string[] | yes (may be `[]`) | Slice/module refs; empty when N/A |
64
+ | `api` | string[] | yes (may be `[]`) | Services/ports/tools |
65
+ | `aliases` | string[] | yes (may be `[]`) | |
66
+ | `e2e` | string[] | yes (may be `[]`) | Stack-appropriate test paths |
67
+ | `status` | enum | no | default `draft` on agent generate |
68
+ | `owners` | string[] | no | |
69
+ | `related` | string[] | no | Spec ids or paths |
70
+
71
+ Arrays are **always present** (empty allowed). Do not omit keys for N/A stacks.
72
+
73
+ ## Body headings (minimum)
74
+
75
+ **`page` required:** Overview; Entry / actors; Primary flows; States (loading / empty / error / success as applicable — mark N/A explicitly); Acceptance criteria (links or bullets to brief AC / product source).
76
+
77
+ **`page` optional:** Analytics, Accessibility, Edge cases, Related specs.
78
+
79
+ **`feature` required:** Overview; Shared behavior / constraints; Related pages (links).
80
+
81
+ **`feature` optional:** Cross-cutting states, Analytics.
82
+
83
+ Compliant = valid frontmatter + all required headings present (non-empty prose or explicit `N/A`) + INDEX row with resolvable `path`.
84
+
85
+ ## Templates & assets
86
+
87
+ **Package SoT:** `packages/ai-rules/presets/_shared/assets/docs-specs/` (`INDEX.md` stub, `_templates/page.md`, `_templates/feature.md`; optional `schemas/frontmatter-v1.schema.json`).
88
+
89
+ **CLI `init`:** when consumer `docs/specs/` is **absent**, copy INDEX stub + `_templates/*` (idempotent; **never overwrite** existing INDEX). When the tree already exists, skip seed entirely.
90
+
91
+ **Skill fallback:** if consumer `_templates/` missing during author mode, copy from package/skill assets before authoring.
92
+
93
+ ## Author roles
94
+
95
+ | Role | Responsibility |
96
+ |------|----------------|
97
+ | **task-analyst** | Primary author (Generate + Bootstrap); INDEX bootstrap; brief **Related specs** + **Spec gaps / generation requested**; loads this stem + skill `spec-authoring` |
98
+ | **tech-writer** | Post-delivery sync where present; never invent product behavior without AC/code source |
99
+ | **feature-developer** | Consumes approved specs as SoT; mechanical INDEX/frontmatter fixes only on renames |
100
+ | **mcp-ts** | No tech-writer — author + post-sync via **task-analyst** only |
101
+
102
+ ## Self-check before handoff (soft block)
103
+
104
+ Block handoff via `open_questions` until fixed:
105
+
106
+ - [ ] Required frontmatter keys present; arrays always present (may be `[]`)
107
+ - [ ] Required body headings present (or explicit `N/A`)
108
+ - [ ] INDEX row added/updated with resolvable `path` in the **same change set**
109
+ - [ ] Sources cited; invented product behavior absent (or labeled `draft` / `inferred`)
110
+ - [ ] Conflict with brief AC reconciled or flagged
111
+
112
+ ## Related
113
+
114
+ - `product-specs` — discovery / consume
115
+ - Skill `spec-authoring` — procedural checklist
116
+ - Optional consumer script `scripts/check-product-specs.sh` (WARN default; `--strict` FAIL)
117
+
118
+
119
+ ## Stack notes
120
+
121
+ - Author via skill `spec-authoring` + **task-analyst only** (no tech-writer on this stack).
122
+ - `routes` = tool names; `ui`/`store` = `[]`; prefer `type: feature`.
123
+ - Requestable — not always-on / session-start.
@@ -0,0 +1,65 @@
1
+ ---
2
+ description: Product page/feature specs under docs/specs — INDEX discovery for agents
3
+ globs:
4
+ - docs/specs/**/*
5
+ alwaysApply: false
6
+ ---
7
+
8
+ <!-- shared-core: architecture/product-specs.md -->
9
+
10
+ # Product specs (docs/specs)
11
+
12
+ Product page/feature **behavior** specs live under the consumer repo `docs/specs/**`. This stem covers **discovery and presence** — not layer implementation order (see `feature-delivery-workflow`) and not code-structure mirroring (see `reference-features`).
13
+
14
+ **Authoring** (Generate / Bootstrap modes, INDEX/frontmatter v1, body checklist, greenfield, conflict precedence) → load **`product-specs-authoring`** when generation is requested (`/spec-start`, brief AC, or router `spec-gen`).
15
+
16
+ ## Modes (summary)
17
+
18
+ | Mode | When | Behavior |
19
+ |------|------|----------|
20
+ | **Consume** (default) | INDEX exists or globs hit `docs/specs/**` without generate intent | Discover via INDEX; soft-fail on miss; **never invent** INDEX/specs |
21
+ | **Generate** | Explicit generate intent / AC / `/spec-start` with existing tree | Create/update page/feature specs + INDEX from stated sources |
22
+ | **Bootstrap** | Explicit bootstrap / `/spec-start` when tree absent | Create INDEX + templates + first domain spec |
23
+
24
+ Greenfield: agents may create INDEX/specs **only** on explicit intent, AC, or `/spec-start`. Missing INDEX alone does **not** authorize inventing the tree.
25
+
26
+ ## Presence policy
27
+
28
+ - If `docs/specs/INDEX.md` is **missing** → the tree is **optional** (greenfield OK for *consume*). Continue with code/brief discovery; do not invent an INDEX solely because this stem loaded.
29
+ - If INDEX **exists** → it is the **required discovery path** for work that touches a listed page, feature, route, or alias.
30
+
31
+ ## Discovery algorithm
32
+
33
+ 1. Always start at `docs/specs/INDEX.md` when present.
34
+ 2. Resolve the entry by: route, stable `id`, PageName / alias, or domain folder.
35
+ 3. Read the linked page spec (and optional domain `feature.md` when the INDEX or page Related links it).
36
+
37
+ ## Miss policy (INDEX present, row or file missing)
38
+
39
+ - Record the gap in `open_questions` / handoff gaps.
40
+ - Fall back to code discovery and consumer `.ai/context/**` when present.
41
+ - **Do not invent** product behavior, states, interactions, or contracts.
42
+ - Hard-fail / block only when the task’s acceptance criteria explicitly require a named spec that is absent (human/gate decision).
43
+
44
+ ## Authoring pointer
45
+
46
+ Same-changeset INDEX updates, frontmatter v1, required body headings, templates, and conflict precedence live in **`product-specs-authoring`**. Do not paste the full checklist here.
47
+
48
+ ## Non-goals
49
+
50
+ - Not a replacement for `.ai/context/**` (external AI Code Review glossary) or `reference-features` (file-layout mirror).
51
+ - Not Tessl / an external host as primary SoT.
52
+ - No stack filesystem path recipes in this core body — path examples belong only in adapter **Stack notes**.
53
+
54
+ ## Related
55
+
56
+ - `product-specs-authoring` — generation modes, contracts, self-check.
57
+ - `reference-features` — code structure mirror (how to layout files), not product behavior.
58
+ - Consumer `.ai/context/**` when present — review/domain glossary; cross-link, do not replace.
59
+
60
+
61
+ ## Stack notes
62
+
63
+ - `routes`: MCP **tool names**. `ui` / `store`: `[]`. `api`: tools/handlers. `e2e`: contract/unit paths.
64
+ - Prefer `type: feature`. **Forbidden:** requiring `app/src/ui`, Playwright paths, or Next lint recipes.
65
+ - Requestable / `docs/specs/**` globs — not always-on / session-start.
@@ -6,9 +6,10 @@ description: Delivers TypeScript MCP server features end-to-end across contracts
6
6
  # Feature Delivery (mcp-ts)
7
7
 
8
8
  1. Read brief, AC, and decomposition.
9
- 2. Follow `feature-delivery-workflow.mdc` + `reference-features.mdc`: contract schema handler register unit/contract tests package validation.
10
- 3. Keep transport/lifecycle in the entry module; tools stay in registration modules.
11
- 4. After TS edits: **invoke** `post-change-test.mdc` (+ `mcp-ts-tooling.mdc`).
9
+ 2. If `docs/specs/INDEX.md` exists **or** brief/handoff lists approved generated specs, resolve via **`product-specs`** and treat approved specs as behavior SoT before layer work (soft-fail on miss — do not invent behavior). If generation was requested but not yet approved, stop for human gate — do not implement against draft-only gaps.
10
+ 3. Follow `feature-delivery-workflow.mdc` + `reference-features.mdc`: contract schema handler register → unit/contract tests → package validation.
11
+ 4. Keep transport/lifecycle in the entry module; tools stay in registration modules.
12
+ 5. After TS edits: **invoke** `post-change-test.mdc` (+ `mcp-ts-tooling.mdc`).
12
13
 
13
14
  ## Do / Don't
14
15
 
@@ -0,0 +1,26 @@
1
+ ---
2
+ name: spec-authoring
3
+ description: Author or bootstrap consumer docs/specs (INDEX, page/feature templates, frontmatter v1). Use with task-analyst author mode, /spec-start, or when brief AC requests Generate/Bootstrap.
4
+ ---
5
+
6
+ # Spec authoring
7
+
8
+ Requestable — not always-on. Load **`product-specs`** + **`product-specs-authoring`** first.
9
+
10
+ ## Steps
11
+
12
+ 1. **Resolve mode** — Generate (tree exists) vs Bootstrap (create INDEX + templates + first spec). Refuse inventing INDEX without explicit intent/AC/`/spec-start`.
13
+ 2. **Ensure templates** — if consumer `docs/specs/_templates/` missing, copy from package SoT `presets/_shared/assets/docs-specs/_templates/` (or seeded init assets).
14
+ 3. **Fill frontmatter v1** — all array keys present (may be `[]`); prefer `type: feature` on backend/MCP; default `status: draft`.
15
+ 4. **Fill required body headings** — page: Overview, Entry/actors, Primary flows, States, Acceptance criteria; feature: Overview, Shared behavior/constraints, Related pages. Use `N/A` explicitly when needed.
16
+ 5. **Update INDEX** in the **same change set** (columns: id, type, domain, title, path, optional routes/aliases/status).
17
+ 6. **Self-check** against `product-specs-authoring` checklist; put blockers in `open_questions`.
18
+ 7. **Handoff** — list created/updated paths + INDEX diff for human gate (`after:task-analyst`). Approve before feature-developer.
19
+
20
+ ## Sources
21
+
22
+ Cite AC / user / Figma / labeled code inference. Do not invent product behavior.
23
+
24
+ ## mcp-ts
25
+
26
+ Analyst-only path (no tech-writer). `routes` = tool names; `ui`/`store` = `[]`.
@@ -35,6 +35,7 @@ Role-based subagents for the Cursor team pipeline.
35
35
  | A11y reviewer | `accessibility-reviewer.md` | no |
36
36
  | Security reviewer | `security-reviewer.md` | no |
37
37
  | Performance auditor | `performance-auditor.md` | no |
38
+ | Mockup reviewer | `mockup-reviewer.md` | no |
38
39
 
39
40
  ## Testing
40
41
 
@@ -70,7 +71,7 @@ Default SoT — YAML `model` in each agent file. Optional `steps[].model` (`chea
70
71
  |------|---------------------|--------|
71
72
  | **cheap** | `fast` | `task-router`, `task-analyst`, `build-verifier`, `code-reviewer`, `tech-writer`, `codebase-analyzer` |
72
73
  | **standard** | `inherit` | `feature-developer`, `debugger`, `ci-investigator`, `api-contract-reviewer`, `accessibility-reviewer`, `qa-tester`, `unit-test-*`, `playwright-test-*` |
73
- | **strong** | `claude-opus-4-8[effort=high]` | `solution-architect`, `migration-specialist`, `security-reviewer`, `performance-auditor` |
74
+ | **strong** | `claude-opus-4-8[effort=high]` | `solution-architect`, `migration-specialist`, `security-reviewer`, `performance-auditor`, `mockup-reviewer` |
74
75
 
75
76
  **Notes**
76
77
 
@@ -46,6 +46,15 @@ When validating **preset packaging** changes (paths under `packages/ai-rules/pre
46
46
  11. **Performance skill by stack:** next → `react-performance`; nuxt → `vue-performance`. **No react-performance/vue-performance on ios/go/java:** skill directory / required handoff must be absent under ios-swift, go, java, mcp-ts, php-hexagonal, and php-laravel → **FAIL** (leakage). Prefer `check:preset-leakage`.
47
47
  12. **Rule eval (WARN):** `scripts/check-rule-eval.mjs` / `yarn check:rule-eval` should exist for maintainers; smoke optional. Hard fail only when the opt-in eval job runs — not part of default `check:preset-structure`.
48
48
 
49
+ 13. **Product-specs assets (FAIL):** package must ship `presets/_shared/assets/docs-specs/INDEX.md`, `_templates/page.md`, `_templates/feature.md`. Cursor+Claude twins for `product-specs` and `product-specs-authoring` must embed matching shared-core markers; both stems **requestable** (`alwaysApply: false` / Claude `paths: docs/specs/**`) — never session-start.
50
+ 14. **Optional consumer check (WARN default):** `scripts/check-product-specs.sh` + schema stub may exist for opt-in consumer CI; **FAIL** only with `--strict` or AC that requires named specs — do not force consumer CI.
51
+
52
+
53
+ **mockup-reviewer (UI):** `agents/mockup-reviewer.md` and `skills/mockup-review/` must exist (Cursor + Claude). Missing → **FAIL**. Backend stacks must **not** ship that agent file or a required `mockup-reviewer` chain handoff → **FAIL** if present.
54
+
55
+ **ux-design (UI):** `skills/ux-design/` and requestable rule `ux-design` (`ux-design.mdc` / `tooling-and-review/ux-design.md`) must exist (Cursor + Claude). Missing → **FAIL**. Do **not** require `agents/ux-designer.md`. Backend stacks must **not** ship that agent file or a required `ux-design` skill/rule/handoff → **FAIL** if present.
56
+
57
+
49
58
  ### Soft notes
50
59
 
51
60
  - Thin aliases may be &lt;15 body lines.
@@ -20,6 +20,7 @@ Apply the **`code-review` skill** and **`code-review-mr.mdc`** checklist.
20
20
  - If diff changes mappers, store reducers/thunks, or domain logic **without** new/updated `*.spec.ts` → **REQUEST_CHANGES** unless task scope explicitly excludes tests.
21
21
  - If `validation-report.md` exists and verdict is FAIL → **REQUEST_CHANGES** (developer must fix before review passes).
22
22
  - User-flow changes without e2e plan/spec updates → note in warnings; REQUEST_CHANGES when AC requires e2e.
23
+ - 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.
23
24
 
24
25
  ## Review artifact
25
26