@bonesofspring/ai-rules 0.2.74 → 0.2.77

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 (856) hide show
  1. package/CHANGELOG.md +119 -0
  2. package/README.md +2 -2
  3. package/bin/lib/engine-scripts.js +4 -0
  4. package/docs/PRESET-CONTRIBUTION.md +6 -3
  5. package/docs/TEAM-DB.md +10 -0
  6. package/docs/TOKEN-ECONOMY.md +18 -5
  7. package/docs/ZCODE.md +1 -1
  8. package/package.json +6 -2
  9. package/presets/_shared/ai-local/scripts/check-write-scope.mjs +126 -34
  10. package/presets/_shared/ai-local/scripts/lock.mjs +103 -30
  11. package/presets/_shared/ai-local/scripts/rule-improver.mjs +4 -0
  12. package/presets/_shared/ai-local/scripts/run-compact.mjs +132 -0
  13. package/presets/_shared/ai-local/scripts/signals.mjs +3 -1
  14. package/presets/_shared/ai-local/scripts/team-db-api.mjs +7 -2
  15. package/presets/_shared/ai-local/scripts/team-db-project.mjs +276 -1
  16. package/presets/_shared/ai-local/scripts/team-db-scheduler.mjs +32 -2
  17. package/presets/_shared/ai-local/scripts/team-db-schema.mjs +99 -0
  18. package/presets/_shared/ai-local/scripts/team-db-task-runner.mjs +3 -1
  19. package/presets/_shared/core/agent-team/agent-task-metrics.md +29 -0
  20. package/presets/_shared/core/agent-team/agent-team-orchestrator.md +1 -1
  21. package/presets/_shared/core/architecture/feature-delivery-workflow.md +1 -1
  22. package/presets/_shared/core/meta/preset-pr-checklist.md +2 -2
  23. package/presets/_shared/core/quality/context-and-iteration.md +1 -1
  24. package/presets/_shared/hooks/chain-team-phases.sh.tmpl +4 -1
  25. package/presets/_shared/hooks/compact-shell-output.mjs +68 -0
  26. package/presets/claude/android-kotlin/CLAUDE.md +1 -1
  27. package/presets/claude/android-kotlin/REPO_AGENTS.md +8 -0
  28. package/presets/claude/android-kotlin/agents/README.md +4 -0
  29. package/presets/claude/android-kotlin/agents/accessibility-reviewer.md +1 -1
  30. package/presets/claude/android-kotlin/agents/api-contract-reviewer.md +1 -1
  31. package/presets/claude/android-kotlin/agents/build-verifier.md +1 -1
  32. package/presets/claude/android-kotlin/agents/ci-investigator.md +0 -1
  33. package/presets/claude/android-kotlin/agents/code-reviewer.md +1 -1
  34. package/presets/claude/android-kotlin/agents/codebase-analyzer.md +1 -1
  35. package/presets/claude/android-kotlin/agents/debugger.md +0 -1
  36. package/presets/claude/android-kotlin/agents/feature-developer.md +0 -1
  37. package/presets/claude/android-kotlin/agents/migration-specialist.md +1 -1
  38. package/presets/claude/android-kotlin/agents/mockup-reviewer.md +1 -0
  39. package/presets/claude/android-kotlin/agents/openspec-author.md +2 -1
  40. package/presets/claude/android-kotlin/agents/performance-auditor.md +1 -1
  41. package/presets/claude/android-kotlin/agents/qa-tester.md +0 -1
  42. package/presets/claude/android-kotlin/agents/security-reviewer.md +1 -1
  43. package/presets/claude/android-kotlin/agents/solution-architect.md +1 -1
  44. package/presets/claude/android-kotlin/agents/task-analyst.md +1 -1
  45. package/presets/claude/android-kotlin/agents/task-router.md +1 -1
  46. package/presets/claude/android-kotlin/agents/tech-writer.md +1 -1
  47. package/presets/claude/android-kotlin/agents/unit-test-generator.md +0 -1
  48. package/presets/claude/android-kotlin/agents/unit-test-healer.md +0 -1
  49. package/presets/claude/android-kotlin/agents/unit-test-planner.md +1 -1
  50. package/presets/claude/android-kotlin/hooks/chain-team-phases.sh +4 -1
  51. package/presets/claude/android-kotlin/rules/architecture/feature-delivery.md +66 -8
  52. package/presets/claude/android-kotlin/rules/architecture/reference-features.md +48 -2
  53. package/presets/claude/android-kotlin/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  54. package/presets/claude/android-kotlin/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  55. package/presets/claude/android-kotlin/skills/unit-testing/SKILL.md +1 -1
  56. package/presets/claude/android-kotlin/team/README.md +1 -1
  57. package/presets/claude/android-kotlin/team/fixtures/feature-parallel.json +84 -0
  58. package/presets/claude/go/CLAUDE.md +1 -1
  59. package/presets/claude/go/REPO_AGENTS.md +8 -0
  60. package/presets/claude/go/agents/README.md +4 -0
  61. package/presets/claude/go/agents/api-contract-reviewer.md +1 -1
  62. package/presets/claude/go/agents/build-verifier.md +1 -1
  63. package/presets/claude/go/agents/ci-investigator.md +0 -1
  64. package/presets/claude/go/agents/code-reviewer.md +3 -3
  65. package/presets/claude/go/agents/codebase-analyzer.md +1 -1
  66. package/presets/claude/go/agents/debugger.md +0 -1
  67. package/presets/claude/go/agents/feature-developer.md +2 -3
  68. package/presets/claude/go/agents/integration-test-generator.md +1 -2
  69. package/presets/claude/go/agents/integration-test-healer.md +1 -2
  70. package/presets/claude/go/agents/integration-test-planner.md +1 -2
  71. package/presets/claude/go/agents/migration-specialist.md +1 -1
  72. package/presets/claude/go/agents/openspec-author.md +2 -1
  73. package/presets/claude/go/agents/performance-auditor.md +1 -1
  74. package/presets/claude/go/agents/qa-tester.md +0 -1
  75. package/presets/claude/go/agents/security-reviewer.md +2 -2
  76. package/presets/claude/go/agents/solution-architect.md +1 -1
  77. package/presets/claude/go/agents/task-analyst.md +1 -1
  78. package/presets/claude/go/agents/task-router.md +1 -1
  79. package/presets/claude/go/agents/tech-writer.md +1 -1
  80. package/presets/claude/go/agents/unit-test-generator.md +1 -2
  81. package/presets/claude/go/agents/unit-test-healer.md +1 -2
  82. package/presets/claude/go/agents/unit-test-planner.md +1 -1
  83. package/presets/claude/go/hooks/chain-team-phases.sh +4 -1
  84. package/presets/claude/go/rules/architecture/feature-delivery.md +50 -1
  85. package/presets/claude/go/rules/architecture/reference-features.md +22 -0
  86. package/presets/claude/go/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  87. package/presets/claude/go/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  88. package/presets/claude/go/skills/feature-delivery/SKILL.md +2 -2
  89. package/presets/claude/go/skills/unit-testing/SKILL.md +1 -1
  90. package/presets/claude/go/team/README.md +1 -1
  91. package/presets/claude/go/team/fixtures/feature-parallel.json +84 -0
  92. package/presets/claude/ios-swift/CLAUDE.md +1 -1
  93. package/presets/claude/ios-swift/REPO_AGENTS.md +8 -0
  94. package/presets/claude/ios-swift/agents/README.md +4 -0
  95. package/presets/claude/ios-swift/agents/accessibility-reviewer.md +1 -1
  96. package/presets/claude/ios-swift/agents/api-contract-reviewer.md +1 -1
  97. package/presets/claude/ios-swift/agents/build-verifier.md +1 -1
  98. package/presets/claude/ios-swift/agents/ci-investigator.md +0 -1
  99. package/presets/claude/ios-swift/agents/code-reviewer.md +1 -1
  100. package/presets/claude/ios-swift/agents/codebase-analyzer.md +1 -1
  101. package/presets/claude/ios-swift/agents/debugger.md +0 -1
  102. package/presets/claude/ios-swift/agents/feature-developer.md +0 -1
  103. package/presets/claude/ios-swift/agents/migration-specialist.md +1 -1
  104. package/presets/claude/ios-swift/agents/mockup-reviewer.md +1 -0
  105. package/presets/claude/ios-swift/agents/openspec-author.md +2 -1
  106. package/presets/claude/ios-swift/agents/performance-auditor.md +1 -1
  107. package/presets/claude/ios-swift/agents/qa-tester.md +0 -1
  108. package/presets/claude/ios-swift/agents/security-reviewer.md +1 -1
  109. package/presets/claude/ios-swift/agents/solution-architect.md +1 -1
  110. package/presets/claude/ios-swift/agents/task-analyst.md +1 -1
  111. package/presets/claude/ios-swift/agents/task-router.md +1 -1
  112. package/presets/claude/ios-swift/agents/tech-writer.md +1 -1
  113. package/presets/claude/ios-swift/agents/unit-test-generator.md +0 -1
  114. package/presets/claude/ios-swift/agents/unit-test-healer.md +0 -1
  115. package/presets/claude/ios-swift/agents/unit-test-planner.md +1 -1
  116. package/presets/claude/ios-swift/agents/xcuitest-test-generator.md +0 -1
  117. package/presets/claude/ios-swift/agents/xcuitest-test-healer.md +0 -1
  118. package/presets/claude/ios-swift/agents/xcuitest-test-planner.md +0 -1
  119. package/presets/claude/ios-swift/hooks/chain-team-phases.sh +4 -1
  120. package/presets/claude/ios-swift/rules/architecture/feature-delivery.md +8 -8
  121. package/presets/claude/ios-swift/rules/architecture/reference-features.md +2 -21
  122. package/presets/claude/ios-swift/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  123. package/presets/claude/ios-swift/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  124. package/presets/claude/ios-swift/skills/unit-testing/SKILL.md +1 -1
  125. package/presets/claude/ios-swift/team/README.md +1 -1
  126. package/presets/claude/ios-swift/team/fixtures/feature-parallel.json +84 -0
  127. package/presets/claude/java/CLAUDE.md +2 -2
  128. package/presets/claude/java/REPO_AGENTS.md +8 -0
  129. package/presets/claude/java/agents/README.md +4 -0
  130. package/presets/claude/java/agents/api-contract-reviewer.md +1 -1
  131. package/presets/claude/java/agents/build-verifier.md +1 -1
  132. package/presets/claude/java/agents/ci-investigator.md +0 -1
  133. package/presets/claude/java/agents/code-reviewer.md +3 -3
  134. package/presets/claude/java/agents/codebase-analyzer.md +1 -1
  135. package/presets/claude/java/agents/debugger.md +0 -1
  136. package/presets/claude/java/agents/feature-developer.md +2 -3
  137. package/presets/claude/java/agents/integration-test-generator.md +1 -2
  138. package/presets/claude/java/agents/integration-test-healer.md +1 -2
  139. package/presets/claude/java/agents/integration-test-planner.md +1 -2
  140. package/presets/claude/java/agents/migration-specialist.md +1 -1
  141. package/presets/claude/java/agents/openspec-author.md +2 -1
  142. package/presets/claude/java/agents/performance-auditor.md +1 -1
  143. package/presets/claude/java/agents/qa-tester.md +0 -1
  144. package/presets/claude/java/agents/security-reviewer.md +2 -2
  145. package/presets/claude/java/agents/solution-architect.md +1 -1
  146. package/presets/claude/java/agents/task-analyst.md +1 -1
  147. package/presets/claude/java/agents/task-router.md +1 -1
  148. package/presets/claude/java/agents/tech-writer.md +1 -1
  149. package/presets/claude/java/agents/unit-test-generator.md +1 -2
  150. package/presets/claude/java/agents/unit-test-healer.md +1 -2
  151. package/presets/claude/java/agents/unit-test-planner.md +1 -1
  152. package/presets/claude/java/hooks/chain-team-phases.sh +4 -1
  153. package/presets/claude/java/rules/architecture/feature-delivery.md +51 -1
  154. package/presets/claude/java/rules/architecture/reference-features.md +22 -0
  155. package/presets/claude/java/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  156. package/presets/claude/java/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  157. package/presets/claude/java/skills/feature-delivery/SKILL.md +2 -2
  158. package/presets/claude/java/team/README.md +1 -1
  159. package/presets/claude/java/team/fixtures/feature-parallel.json +84 -0
  160. package/presets/claude/mcp-ts/CLAUDE.md +1 -1
  161. package/presets/claude/mcp-ts/REPO_AGENTS.md +8 -0
  162. package/presets/claude/mcp-ts/agents/README.md +4 -0
  163. package/presets/claude/mcp-ts/agents/build-verifier.md +1 -1
  164. package/presets/claude/mcp-ts/agents/feature-developer.md +2 -3
  165. package/presets/claude/mcp-ts/agents/security-reviewer.md +2 -2
  166. package/presets/claude/mcp-ts/agents/solution-architect.md +1 -1
  167. package/presets/claude/mcp-ts/agents/task-analyst.md +1 -1
  168. package/presets/claude/mcp-ts/agents/task-router.md +1 -1
  169. package/presets/claude/mcp-ts/hooks/chain-team-phases.sh +4 -1
  170. package/presets/claude/mcp-ts/rules/architecture/feature-delivery.md +47 -1
  171. package/presets/claude/mcp-ts/rules/architecture/reference-features.md +22 -0
  172. package/presets/claude/mcp-ts/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  173. package/presets/claude/mcp-ts/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  174. package/presets/claude/mcp-ts/skills/code-review/SKILL.md +1 -1
  175. package/presets/claude/mcp-ts/skills/feature-delivery/SKILL.md +2 -2
  176. package/presets/claude/mcp-ts/skills/unit-testing/SKILL.md +1 -1
  177. package/presets/claude/mcp-ts/team/README.md +1 -1
  178. package/presets/claude/mcp-ts/team/fixtures/feature-parallel.json +84 -0
  179. package/presets/claude/mol/CLAUDE.md +1 -1
  180. package/presets/claude/mol/REPO_AGENTS.md +8 -0
  181. package/presets/claude/mol/agents/README.md +2 -4
  182. package/presets/claude/mol/agents/accessibility-reviewer.md +1 -0
  183. package/presets/claude/mol/agents/api-contract-reviewer.md +1 -0
  184. package/presets/claude/mol/agents/build-verifier.md +1 -0
  185. package/presets/claude/mol/agents/code-reviewer.md +1 -0
  186. package/presets/claude/mol/agents/codebase-analyzer.md +1 -0
  187. package/presets/claude/mol/agents/migration-specialist.md +1 -0
  188. package/presets/claude/mol/agents/mockup-reviewer.md +1 -0
  189. package/presets/claude/mol/agents/openspec-author.md +1 -0
  190. package/presets/claude/mol/agents/performance-auditor.md +1 -0
  191. package/presets/claude/mol/agents/security-reviewer.md +1 -0
  192. package/presets/claude/mol/agents/solution-architect.md +1 -0
  193. package/presets/claude/mol/agents/task-analyst.md +1 -0
  194. package/presets/claude/mol/agents/task-router.md +1 -0
  195. package/presets/claude/mol/agents/tech-writer.md +1 -0
  196. package/presets/claude/mol/agents/unit-test-planner.md +1 -0
  197. package/presets/claude/mol/hooks/chain-team-phases.sh +4 -1
  198. package/presets/claude/mol/rules/architecture/feature-delivery-workflow.md +10 -10
  199. package/presets/claude/mol/rules/architecture/reference-features.md +0 -19
  200. package/presets/claude/mol/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  201. package/presets/claude/mol/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  202. package/presets/claude/mol/team/README.md +1 -1
  203. package/presets/claude/next/CLAUDE.md +3 -3
  204. package/presets/claude/next/REPO_AGENTS.md +8 -0
  205. package/presets/claude/next/agents/README.md +4 -0
  206. package/presets/claude/next/agents/accessibility-reviewer.md +1 -0
  207. package/presets/claude/next/agents/api-contract-reviewer.md +1 -0
  208. package/presets/claude/next/agents/build-verifier.md +2 -1
  209. package/presets/claude/next/agents/code-reviewer.md +3 -0
  210. package/presets/claude/next/agents/codebase-analyzer.md +1 -1
  211. package/presets/claude/next/agents/migration-specialist.md +1 -0
  212. package/presets/claude/next/agents/mockup-reviewer.md +1 -0
  213. package/presets/claude/next/agents/openspec-author.md +1 -0
  214. package/presets/claude/next/agents/performance-auditor.md +1 -0
  215. package/presets/claude/next/agents/security-reviewer.md +1 -0
  216. package/presets/claude/next/agents/solution-architect.md +1 -0
  217. package/presets/claude/next/agents/task-analyst.md +1 -0
  218. package/presets/claude/next/agents/task-router.md +12 -0
  219. package/presets/claude/next/agents/tech-writer.md +1 -0
  220. package/presets/claude/next/agents/unit-test-planner.md +1 -0
  221. package/presets/claude/next/ai-local/rules-library/agent-artifacts-no-local-paths.md +71 -0
  222. package/presets/claude/next/ai-local/rules-library/agent-pipeline-gates.md +19 -0
  223. package/presets/claude/next/ai-local/rules-library/analytics-events.md +18 -0
  224. package/presets/claude/next/ai-local/rules-library/api-contract-source.md +14 -0
  225. package/presets/claude/next/ai-local/rules-library/artifact-lifecycle.md +17 -0
  226. package/presets/claude/next/ai-local/rules-library/code-style.md +68 -0
  227. package/presets/claude/next/ai-local/rules-library/commit-hygiene.md +17 -0
  228. package/presets/claude/next/ai-local/rules-library/component-child-decomposition.md +81 -0
  229. package/presets/claude/next/ai-local/rules-library/feature-flags-experiments.md +15 -0
  230. package/presets/claude/next/ai-local/rules-library/mcp-required-for-ui-layout.md +45 -0
  231. package/presets/claude/next/ai-local/rules-library/no-react-fc.md +46 -0
  232. package/presets/claude/next/ai-local/rules-library/no-test-driven-behavior-change.md +14 -0
  233. package/presets/claude/next/ai-local/rules-library/pre-pr-checklist.md +16 -0
  234. package/presets/claude/next/ai-local/rules-library/pwa-service-worker.md +15 -0
  235. package/presets/claude/next/ai-local/rules-library/qa-test-cases.md +14 -0
  236. package/presets/claude/next/ai-local/rules-library/router-pages.md +25 -0
  237. package/presets/claude/next/ai-local/rules-library/single-source-copy-constants.md +18 -0
  238. package/presets/claude/next/ai-local/rules-library/storybook-catalog-structure.md +62 -0
  239. package/presets/claude/next/ai-local/rules-library/storybook-cleanup-temp-screenshots.md +40 -0
  240. package/presets/claude/next/ai-local/rules-library/storybook-csf-authoring.md +100 -0
  241. package/presets/claude/next/ai-local/rules-library/storybook-dev-compare-figma.md +72 -0
  242. package/presets/claude/next/ai-local/rules-library/storybook-keep-tests-current.md +75 -0
  243. package/presets/claude/next/ai-local/rules-library/storybook-modals.md +64 -0
  244. package/presets/claude/next/ai-local/rules-library/storybook-no-app-node-modules.md +40 -0
  245. package/presets/claude/next/ai-local/rules-library/storybook-ui-quality-gate.md +38 -0
  246. package/presets/claude/next/ai-local/rules-library/ui-change-review-gate.md +16 -0
  247. package/presets/claude/next/hooks/chain-team-phases.sh +4 -1
  248. package/presets/claude/next/rules/architecture/feature-delivery-workflow.md +13 -13
  249. package/presets/claude/next/rules/architecture/reference-features.md +0 -19
  250. package/presets/claude/next/rules/stack/next-app-core.md +1 -1
  251. package/presets/claude/next/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  252. package/presets/claude/next/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  253. package/presets/claude/next/team/README.md +1 -1
  254. package/presets/claude/next/team/fixtures/feature-l2-lite.json +27 -0
  255. package/presets/claude/nuxt/CLAUDE.md +3 -3
  256. package/presets/claude/nuxt/REPO_AGENTS.md +8 -0
  257. package/presets/claude/nuxt/agents/README.md +2 -4
  258. package/presets/claude/nuxt/agents/accessibility-reviewer.md +1 -0
  259. package/presets/claude/nuxt/agents/api-contract-reviewer.md +1 -0
  260. package/presets/claude/nuxt/agents/build-verifier.md +1 -0
  261. package/presets/claude/nuxt/agents/code-reviewer.md +1 -0
  262. package/presets/claude/nuxt/agents/codebase-analyzer.md +1 -1
  263. package/presets/claude/nuxt/agents/migration-specialist.md +1 -0
  264. package/presets/claude/nuxt/agents/mockup-reviewer.md +1 -0
  265. package/presets/claude/nuxt/agents/openspec-author.md +2 -1
  266. package/presets/claude/nuxt/agents/performance-auditor.md +1 -0
  267. package/presets/claude/nuxt/agents/playwright-test-generator.md +24 -68
  268. package/presets/claude/nuxt/agents/playwright-test-healer.md +28 -54
  269. package/presets/claude/nuxt/agents/playwright-test-planner.md +18 -51
  270. package/presets/claude/nuxt/agents/security-reviewer.md +1 -0
  271. package/presets/claude/nuxt/agents/solution-architect.md +1 -0
  272. package/presets/claude/nuxt/agents/task-analyst.md +12 -0
  273. package/presets/claude/nuxt/agents/task-router.md +1 -0
  274. package/presets/claude/nuxt/agents/tech-writer.md +1 -0
  275. package/presets/claude/nuxt/agents/unit-test-planner.md +1 -0
  276. package/presets/claude/nuxt/hooks/chain-team-phases.sh +4 -1
  277. package/presets/claude/nuxt/rules/architecture/feature-delivery-workflow.md +9 -9
  278. package/presets/claude/nuxt/rules/architecture/reference-features.md +1 -20
  279. package/presets/claude/nuxt/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  280. package/presets/claude/nuxt/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  281. package/presets/claude/nuxt/team/README.md +1 -1
  282. package/presets/claude/nuxt/team/fixtures/feature-parallel.json +84 -0
  283. package/presets/claude/php-hexagonal/CLAUDE.md +2 -2
  284. package/presets/claude/php-hexagonal/REPO_AGENTS.md +8 -0
  285. package/presets/claude/php-hexagonal/agents/README.md +4 -0
  286. package/presets/claude/php-hexagonal/agents/api-contract-reviewer.md +1 -1
  287. package/presets/claude/php-hexagonal/agents/build-verifier.md +1 -1
  288. package/presets/claude/php-hexagonal/agents/ci-investigator.md +0 -1
  289. package/presets/claude/php-hexagonal/agents/code-reviewer.md +3 -3
  290. package/presets/claude/php-hexagonal/agents/codebase-analyzer.md +1 -1
  291. package/presets/claude/php-hexagonal/agents/debugger.md +0 -1
  292. package/presets/claude/php-hexagonal/agents/feature-developer.md +2 -3
  293. package/presets/claude/php-hexagonal/agents/integration-test-generator.md +1 -2
  294. package/presets/claude/php-hexagonal/agents/integration-test-healer.md +1 -2
  295. package/presets/claude/php-hexagonal/agents/integration-test-planner.md +1 -2
  296. package/presets/claude/php-hexagonal/agents/migration-specialist.md +1 -1
  297. package/presets/claude/php-hexagonal/agents/openspec-author.md +2 -1
  298. package/presets/claude/php-hexagonal/agents/performance-auditor.md +1 -1
  299. package/presets/claude/php-hexagonal/agents/qa-tester.md +0 -1
  300. package/presets/claude/php-hexagonal/agents/security-reviewer.md +2 -2
  301. package/presets/claude/php-hexagonal/agents/solution-architect.md +1 -1
  302. package/presets/claude/php-hexagonal/agents/task-analyst.md +1 -1
  303. package/presets/claude/php-hexagonal/agents/task-router.md +1 -1
  304. package/presets/claude/php-hexagonal/agents/tech-writer.md +1 -1
  305. package/presets/claude/php-hexagonal/agents/unit-test-generator.md +1 -2
  306. package/presets/claude/php-hexagonal/agents/unit-test-healer.md +1 -2
  307. package/presets/claude/php-hexagonal/agents/unit-test-planner.md +1 -1
  308. package/presets/claude/php-hexagonal/hooks/chain-team-phases.sh +4 -1
  309. package/presets/claude/php-hexagonal/rules/architecture/feature-delivery.md +51 -1
  310. package/presets/claude/php-hexagonal/rules/architecture/reference-features.md +25 -0
  311. package/presets/claude/php-hexagonal/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  312. package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  313. package/presets/claude/php-hexagonal/skills/feature-delivery/SKILL.md +2 -2
  314. package/presets/claude/php-hexagonal/team/README.md +1 -1
  315. package/presets/claude/php-hexagonal/team/fixtures/feature-parallel.json +84 -0
  316. package/presets/claude/php-laravel/CLAUDE.md +1 -1
  317. package/presets/claude/php-laravel/REPO_AGENTS.md +8 -0
  318. package/presets/claude/php-laravel/agents/README.md +4 -0
  319. package/presets/claude/php-laravel/agents/api-contract-reviewer.md +1 -1
  320. package/presets/claude/php-laravel/agents/build-verifier.md +1 -1
  321. package/presets/claude/php-laravel/agents/ci-investigator.md +0 -1
  322. package/presets/claude/php-laravel/agents/code-reviewer.md +1 -1
  323. package/presets/claude/php-laravel/agents/codebase-analyzer.md +1 -1
  324. package/presets/claude/php-laravel/agents/debugger.md +0 -1
  325. package/presets/claude/php-laravel/agents/feature-developer.md +2 -3
  326. package/presets/claude/php-laravel/agents/integration-test-generator.md +1 -2
  327. package/presets/claude/php-laravel/agents/integration-test-healer.md +1 -2
  328. package/presets/claude/php-laravel/agents/integration-test-planner.md +1 -2
  329. package/presets/claude/php-laravel/agents/migration-specialist.md +1 -1
  330. package/presets/claude/php-laravel/agents/openspec-author.md +2 -1
  331. package/presets/claude/php-laravel/agents/performance-auditor.md +1 -1
  332. package/presets/claude/php-laravel/agents/qa-tester.md +0 -1
  333. package/presets/claude/php-laravel/agents/security-reviewer.md +1 -1
  334. package/presets/claude/php-laravel/agents/solution-architect.md +1 -1
  335. package/presets/claude/php-laravel/agents/task-analyst.md +1 -1
  336. package/presets/claude/php-laravel/agents/task-router.md +1 -1
  337. package/presets/claude/php-laravel/agents/tech-writer.md +1 -1
  338. package/presets/claude/php-laravel/agents/unit-test-generator.md +1 -2
  339. package/presets/claude/php-laravel/agents/unit-test-healer.md +1 -2
  340. package/presets/claude/php-laravel/agents/unit-test-planner.md +1 -1
  341. package/presets/claude/php-laravel/hooks/chain-team-phases.sh +4 -1
  342. package/presets/claude/php-laravel/rules/architecture/feature-delivery.md +54 -1
  343. package/presets/claude/php-laravel/rules/architecture/reference-features.md +27 -0
  344. package/presets/claude/php-laravel/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  345. package/presets/claude/php-laravel/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  346. package/presets/claude/php-laravel/skills/feature-delivery/SKILL.md +2 -2
  347. package/presets/claude/php-laravel/team/README.md +1 -1
  348. package/presets/claude/php-laravel/team/fixtures/feature-parallel.json +84 -0
  349. package/presets/claude/svelte/CLAUDE.md +3 -3
  350. package/presets/claude/svelte/REPO_AGENTS.md +8 -0
  351. package/presets/claude/svelte/agents/README.md +2 -4
  352. package/presets/claude/svelte/agents/accessibility-reviewer.md +1 -0
  353. package/presets/claude/svelte/agents/api-contract-reviewer.md +1 -0
  354. package/presets/claude/svelte/agents/build-verifier.md +1 -0
  355. package/presets/claude/svelte/agents/code-reviewer.md +1 -0
  356. package/presets/claude/svelte/agents/codebase-analyzer.md +1 -1
  357. package/presets/claude/svelte/agents/migration-specialist.md +1 -0
  358. package/presets/claude/svelte/agents/mockup-reviewer.md +1 -0
  359. package/presets/claude/svelte/agents/openspec-author.md +2 -1
  360. package/presets/claude/svelte/agents/performance-auditor.md +1 -0
  361. package/presets/claude/svelte/agents/playwright-test-generator.md +24 -68
  362. package/presets/claude/svelte/agents/playwright-test-healer.md +28 -54
  363. package/presets/claude/svelte/agents/playwright-test-planner.md +18 -51
  364. package/presets/claude/svelte/agents/security-reviewer.md +1 -0
  365. package/presets/claude/svelte/agents/solution-architect.md +1 -0
  366. package/presets/claude/svelte/agents/task-analyst.md +12 -0
  367. package/presets/claude/svelte/agents/task-router.md +1 -1
  368. package/presets/claude/svelte/agents/tech-writer.md +1 -0
  369. package/presets/claude/svelte/agents/unit-test-planner.md +1 -0
  370. package/presets/claude/svelte/hooks/chain-team-phases.sh +4 -1
  371. package/presets/claude/svelte/rules/architecture/feature-delivery-workflow.md +7 -7
  372. package/presets/claude/svelte/rules/architecture/reference-features.md +1 -20
  373. package/presets/claude/svelte/rules/tooling-and-review/agent-team-orchestrator.md +1 -1
  374. package/presets/claude/svelte/rules/tooling-and-review/preset-pr-checklist.md +2 -2
  375. package/presets/claude/svelte/team/README.md +1 -1
  376. package/presets/claude/svelte/team/fixtures/feature-parallel.json +84 -0
  377. package/presets/cursor/android-kotlin/REPO_AGENTS.md +8 -0
  378. package/presets/cursor/android-kotlin/hooks/chain-team-phases.sh +4 -1
  379. package/presets/cursor/android-kotlin/hooks/compact-shell-output.mjs +68 -0
  380. package/presets/cursor/android-kotlin/hooks.json +7 -0
  381. package/presets/cursor/android-kotlin/rules/agent-team-orchestrator.mdc +17 -5
  382. package/presets/cursor/android-kotlin/rules/feature-delivery-workflow.mdc +66 -8
  383. package/presets/cursor/android-kotlin/rules/preset-pr-checklist.mdc +2 -2
  384. package/presets/cursor/android-kotlin/rules/reference-features.mdc +48 -2
  385. package/presets/cursor/android-kotlin/skills/unit-testing/SKILL.md +1 -1
  386. package/presets/cursor/android-kotlin/team/README.md +1 -1
  387. package/presets/cursor/android-kotlin/team/fixtures/feature-parallel.json +84 -0
  388. package/presets/cursor/go/REPO_AGENTS.md +8 -0
  389. package/presets/cursor/go/hooks/chain-team-phases.sh +4 -1
  390. package/presets/cursor/go/hooks/compact-shell-output.mjs +68 -0
  391. package/presets/cursor/go/hooks.json +7 -0
  392. package/presets/cursor/go/rules/agent-team-orchestrator.mdc +16 -5
  393. package/presets/cursor/go/rules/feature-delivery-workflow.mdc +63 -5
  394. package/presets/cursor/go/rules/preset-pr-checklist.mdc +2 -2
  395. package/presets/cursor/go/rules/reference-features.mdc +46 -6
  396. package/presets/cursor/go/skills/feature-delivery/SKILL.md +2 -2
  397. package/presets/cursor/go/skills/unit-testing/SKILL.md +1 -1
  398. package/presets/cursor/go/team/README.md +1 -1
  399. package/presets/cursor/go/team/fixtures/feature-parallel.json +84 -0
  400. package/presets/cursor/ios-swift/REPO_AGENTS.md +8 -0
  401. package/presets/cursor/ios-swift/hooks/chain-team-phases.sh +4 -1
  402. package/presets/cursor/ios-swift/hooks/compact-shell-output.mjs +68 -0
  403. package/presets/cursor/ios-swift/hooks.json +7 -0
  404. package/presets/cursor/ios-swift/rules/agent-team-orchestrator.mdc +17 -5
  405. package/presets/cursor/ios-swift/rules/feature-delivery-workflow.mdc +64 -8
  406. package/presets/cursor/ios-swift/rules/preset-pr-checklist.mdc +2 -2
  407. package/presets/cursor/ios-swift/rules/reference-features.mdc +44 -21
  408. package/presets/cursor/ios-swift/skills/unit-testing/SKILL.md +1 -1
  409. package/presets/cursor/ios-swift/team/README.md +1 -1
  410. package/presets/cursor/ios-swift/team/fixtures/feature-parallel.json +84 -0
  411. package/presets/cursor/java/AGENTS.md +1 -1
  412. package/presets/cursor/java/REPO_AGENTS.md +8 -0
  413. package/presets/cursor/java/hooks/chain-team-phases.sh +4 -1
  414. package/presets/cursor/java/hooks/compact-shell-output.mjs +68 -0
  415. package/presets/cursor/java/hooks.json +7 -0
  416. package/presets/cursor/java/rules/agent-team-orchestrator.mdc +16 -5
  417. package/presets/cursor/java/rules/feature-delivery-workflow.mdc +63 -5
  418. package/presets/cursor/java/rules/preset-pr-checklist.mdc +2 -2
  419. package/presets/cursor/java/rules/reference-features.mdc +46 -6
  420. package/presets/cursor/java/skills/feature-delivery/SKILL.md +2 -2
  421. package/presets/cursor/java/team/README.md +1 -1
  422. package/presets/cursor/java/team/fixtures/feature-parallel.json +84 -0
  423. package/presets/cursor/mcp-ts/REPO_AGENTS.md +8 -0
  424. package/presets/cursor/mcp-ts/hooks/chain-team-phases.sh +4 -1
  425. package/presets/cursor/mcp-ts/hooks/compact-shell-output.mjs +68 -0
  426. package/presets/cursor/mcp-ts/hooks.json +7 -0
  427. package/presets/cursor/mcp-ts/rules/agent-team-orchestrator.mdc +17 -6
  428. package/presets/cursor/mcp-ts/rules/feature-delivery-workflow.mdc +63 -5
  429. package/presets/cursor/mcp-ts/rules/preset-pr-checklist.mdc +2 -2
  430. package/presets/cursor/mcp-ts/rules/reference-features.mdc +46 -6
  431. package/presets/cursor/mcp-ts/skills/code-review/SKILL.md +1 -1
  432. package/presets/cursor/mcp-ts/skills/feature-delivery/SKILL.md +2 -2
  433. package/presets/cursor/mcp-ts/skills/unit-testing/SKILL.md +1 -1
  434. package/presets/cursor/mcp-ts/team/README.md +1 -1
  435. package/presets/cursor/mcp-ts/team/fixtures/feature-parallel.json +84 -0
  436. package/presets/cursor/mol/REPO_AGENTS.md +8 -0
  437. package/presets/cursor/mol/hooks/chain-team-phases.sh +4 -1
  438. package/presets/cursor/mol/hooks/compact-shell-output.mjs +68 -0
  439. package/presets/cursor/mol/hooks.json +7 -0
  440. package/presets/cursor/mol/rules/agent-team-orchestrator.mdc +16 -5
  441. package/presets/cursor/mol/rules/feature-delivery-workflow.mdc +65 -9
  442. package/presets/cursor/mol/rules/preset-pr-checklist.mdc +2 -2
  443. package/presets/cursor/mol/rules/reference-features.mdc +43 -20
  444. package/presets/cursor/mol/team/README.md +1 -1
  445. package/presets/cursor/next/README.md +2 -2
  446. package/presets/cursor/next/REPO_AGENTS.md +8 -0
  447. package/presets/cursor/next/agents/build-verifier.md +1 -1
  448. package/presets/cursor/next/agents/code-reviewer.md +2 -0
  449. package/presets/cursor/next/hooks/chain-team-phases.sh +4 -1
  450. package/presets/cursor/next/hooks/compact-shell-output.mjs +68 -0
  451. package/presets/cursor/next/hooks.json +7 -0
  452. package/presets/cursor/next/rules/README.md +2 -2
  453. package/presets/cursor/next/rules/agent-team-orchestrator.mdc +16 -5
  454. package/presets/cursor/next/rules/feature-delivery-workflow.mdc +68 -12
  455. package/presets/cursor/next/rules/next-app-core.mdc +1 -1
  456. package/presets/cursor/next/rules/preset-pr-checklist.mdc +2 -2
  457. package/presets/cursor/next/rules/reference-features.mdc +42 -19
  458. package/presets/cursor/next/team/README.md +1 -1
  459. package/presets/cursor/nuxt/REPO_AGENTS.md +8 -0
  460. package/presets/cursor/nuxt/hooks/chain-team-phases.sh +4 -1
  461. package/presets/cursor/nuxt/hooks/compact-shell-output.mjs +68 -0
  462. package/presets/cursor/nuxt/hooks.json +7 -0
  463. package/presets/cursor/nuxt/rules/README.md +2 -2
  464. package/presets/cursor/nuxt/rules/agent-team-orchestrator.mdc +16 -5
  465. package/presets/cursor/nuxt/rules/feature-delivery-workflow.mdc +64 -8
  466. package/presets/cursor/nuxt/rules/preset-pr-checklist.mdc +2 -2
  467. package/presets/cursor/nuxt/rules/reference-features.mdc +37 -14
  468. package/presets/cursor/nuxt/team/README.md +1 -1
  469. package/presets/cursor/nuxt/team/fixtures/feature-parallel.json +84 -0
  470. package/presets/cursor/php-hexagonal/AGENTS.md +1 -1
  471. package/presets/cursor/php-hexagonal/REPO_AGENTS.md +8 -0
  472. package/presets/cursor/php-hexagonal/hooks/chain-team-phases.sh +4 -1
  473. package/presets/cursor/php-hexagonal/hooks/compact-shell-output.mjs +68 -0
  474. package/presets/cursor/php-hexagonal/hooks.json +7 -0
  475. package/presets/cursor/php-hexagonal/rules/agent-team-orchestrator.mdc +16 -5
  476. package/presets/cursor/php-hexagonal/rules/feature-delivery-workflow.mdc +63 -5
  477. package/presets/cursor/php-hexagonal/rules/preset-pr-checklist.mdc +2 -2
  478. package/presets/cursor/php-hexagonal/rules/reference-features.mdc +46 -6
  479. package/presets/cursor/php-hexagonal/skills/feature-delivery/SKILL.md +2 -2
  480. package/presets/cursor/php-hexagonal/team/README.md +1 -1
  481. package/presets/cursor/php-hexagonal/team/fixtures/feature-parallel.json +84 -0
  482. package/presets/cursor/php-laravel/AGENTS.md +1 -1
  483. package/presets/cursor/php-laravel/REPO_AGENTS.md +8 -0
  484. package/presets/cursor/php-laravel/hooks/chain-team-phases.sh +4 -1
  485. package/presets/cursor/php-laravel/hooks/compact-shell-output.mjs +68 -0
  486. package/presets/cursor/php-laravel/hooks.json +7 -0
  487. package/presets/cursor/php-laravel/rules/agent-team-orchestrator.mdc +16 -5
  488. package/presets/cursor/php-laravel/rules/feature-delivery-workflow.mdc +63 -5
  489. package/presets/cursor/php-laravel/rules/preset-pr-checklist.mdc +2 -2
  490. package/presets/cursor/php-laravel/rules/reference-features.mdc +46 -6
  491. package/presets/cursor/php-laravel/skills/feature-delivery/SKILL.md +2 -2
  492. package/presets/cursor/php-laravel/team/README.md +1 -1
  493. package/presets/cursor/php-laravel/team/fixtures/feature-parallel.json +84 -0
  494. package/presets/cursor/svelte/REPO_AGENTS.md +8 -0
  495. package/presets/cursor/svelte/hooks/chain-team-phases.sh +4 -1
  496. package/presets/cursor/svelte/hooks/compact-shell-output.mjs +68 -0
  497. package/presets/cursor/svelte/hooks.json +7 -0
  498. package/presets/cursor/svelte/rules/README.md +1 -1
  499. package/presets/cursor/svelte/rules/agent-team-orchestrator.mdc +16 -5
  500. package/presets/cursor/svelte/rules/feature-delivery-workflow.mdc +62 -6
  501. package/presets/cursor/svelte/rules/preset-pr-checklist.mdc +2 -2
  502. package/presets/cursor/svelte/rules/reference-features.mdc +40 -17
  503. package/presets/cursor/svelte/team/README.md +1 -1
  504. package/presets/cursor/svelte/team/fixtures/feature-parallel.json +84 -0
  505. package/presets/mavis/android-kotlin/REPO_AGENTS.md +8 -0
  506. package/presets/mavis/android-kotlin/adapter-map.json +19 -2
  507. package/presets/mavis/android-kotlin/hooks/chain-team-phases.sh +4 -1
  508. package/presets/mavis/android-kotlin/rules/agent-team-orchestrator.md +1 -1
  509. package/presets/mavis/android-kotlin/rules/feature-delivery-workflow.md +66 -8
  510. package/presets/mavis/android-kotlin/rules/preset-pr-checklist.md +2 -2
  511. package/presets/mavis/android-kotlin/rules/reference-features.md +48 -2
  512. package/presets/mavis/android-kotlin/skills/unit-testing/SKILL.md +1 -1
  513. package/presets/mavis/android-kotlin/team/README.md +1 -1
  514. package/presets/mavis/android-kotlin/team/fixtures/feature-parallel.json +84 -0
  515. package/presets/mavis/go/REPO_AGENTS.md +8 -0
  516. package/presets/mavis/go/adapter-map.json +17 -1
  517. package/presets/mavis/go/hooks/chain-team-phases.sh +4 -1
  518. package/presets/mavis/go/rules/agent-team-orchestrator.md +1 -1
  519. package/presets/mavis/go/rules/feature-delivery-workflow.md +50 -1
  520. package/presets/mavis/go/rules/preset-pr-checklist.md +2 -2
  521. package/presets/mavis/go/rules/reference-features.md +22 -0
  522. package/presets/mavis/go/skills/feature-delivery/SKILL.md +2 -2
  523. package/presets/mavis/go/skills/unit-testing/SKILL.md +1 -1
  524. package/presets/mavis/go/team/README.md +1 -1
  525. package/presets/mavis/go/team/fixtures/feature-parallel.json +84 -0
  526. package/presets/mavis/ios-swift/REPO_AGENTS.md +8 -0
  527. package/presets/mavis/ios-swift/adapter-map.json +17 -1
  528. package/presets/mavis/ios-swift/hooks/chain-team-phases.sh +4 -1
  529. package/presets/mavis/ios-swift/rules/agent-team-orchestrator.md +1 -1
  530. package/presets/mavis/ios-swift/rules/feature-delivery-workflow.md +8 -8
  531. package/presets/mavis/ios-swift/rules/preset-pr-checklist.md +2 -2
  532. package/presets/mavis/ios-swift/rules/reference-features.md +2 -21
  533. package/presets/mavis/ios-swift/skills/unit-testing/SKILL.md +1 -1
  534. package/presets/mavis/ios-swift/team/README.md +1 -1
  535. package/presets/mavis/ios-swift/team/fixtures/feature-parallel.json +84 -0
  536. package/presets/mavis/java/MAVIS.md +1 -1
  537. package/presets/mavis/java/REPO_AGENTS.md +8 -0
  538. package/presets/mavis/java/adapter-map.json +17 -1
  539. package/presets/mavis/java/hooks/chain-team-phases.sh +4 -1
  540. package/presets/mavis/java/rules/agent-team-orchestrator.md +1 -1
  541. package/presets/mavis/java/rules/feature-delivery-workflow.md +51 -1
  542. package/presets/mavis/java/rules/preset-pr-checklist.md +2 -2
  543. package/presets/mavis/java/rules/reference-features.md +22 -0
  544. package/presets/mavis/java/skills/feature-delivery/SKILL.md +2 -2
  545. package/presets/mavis/java/team/README.md +1 -1
  546. package/presets/mavis/java/team/fixtures/feature-parallel.json +84 -0
  547. package/presets/mavis/mcp-ts/REPO_AGENTS.md +8 -0
  548. package/presets/mavis/mcp-ts/adapter-map.json +17 -1
  549. package/presets/mavis/mcp-ts/hooks/chain-team-phases.sh +4 -1
  550. package/presets/mavis/mcp-ts/rules/agent-team-orchestrator.md +1 -1
  551. package/presets/mavis/mcp-ts/rules/feature-delivery-workflow.md +47 -1
  552. package/presets/mavis/mcp-ts/rules/preset-pr-checklist.md +2 -2
  553. package/presets/mavis/mcp-ts/rules/reference-features.md +22 -0
  554. package/presets/mavis/mcp-ts/skills/code-review/SKILL.md +1 -1
  555. package/presets/mavis/mcp-ts/skills/feature-delivery/SKILL.md +2 -2
  556. package/presets/mavis/mcp-ts/skills/unit-testing/SKILL.md +1 -1
  557. package/presets/mavis/mcp-ts/team/README.md +1 -1
  558. package/presets/mavis/mcp-ts/team/fixtures/feature-parallel.json +84 -0
  559. package/presets/mavis/mol/REPO_AGENTS.md +8 -0
  560. package/presets/mavis/mol/adapter-map.json +9 -1
  561. package/presets/mavis/mol/hooks/chain-team-phases.sh +4 -1
  562. package/presets/mavis/mol/rules/agent-team-orchestrator.md +1 -1
  563. package/presets/mavis/mol/rules/feature-delivery-workflow.md +10 -10
  564. package/presets/mavis/mol/rules/preset-pr-checklist.md +2 -2
  565. package/presets/mavis/mol/rules/reference-features.md +0 -19
  566. package/presets/mavis/mol/team/README.md +1 -1
  567. package/presets/mavis/next/REPO_AGENTS.md +8 -0
  568. package/presets/mavis/next/adapter-map.json +9 -1
  569. package/presets/mavis/next/agents/build-verifier.md +1 -1
  570. package/presets/mavis/next/agents/code-reviewer.md +2 -0
  571. package/presets/mavis/next/hooks/chain-team-phases.sh +4 -1
  572. package/presets/mavis/next/rules/agent-team-orchestrator.md +1 -1
  573. package/presets/mavis/next/rules/feature-delivery-workflow.md +13 -13
  574. package/presets/mavis/next/rules/next-app-core.md +1 -1
  575. package/presets/mavis/next/rules/preset-pr-checklist.md +2 -2
  576. package/presets/mavis/next/rules/reference-features.md +0 -19
  577. package/presets/mavis/next/team/README.md +1 -1
  578. package/presets/mavis/nuxt/REPO_AGENTS.md +8 -0
  579. package/presets/mavis/nuxt/adapter-map.json +17 -1
  580. package/presets/mavis/nuxt/hooks/chain-team-phases.sh +4 -1
  581. package/presets/mavis/nuxt/rules/agent-team-orchestrator.md +1 -1
  582. package/presets/mavis/nuxt/rules/feature-delivery-workflow.md +9 -9
  583. package/presets/mavis/nuxt/rules/preset-pr-checklist.md +2 -2
  584. package/presets/mavis/nuxt/rules/reference-features.md +1 -20
  585. package/presets/mavis/nuxt/team/README.md +1 -1
  586. package/presets/mavis/nuxt/team/fixtures/feature-parallel.json +84 -0
  587. package/presets/mavis/php-hexagonal/MAVIS.md +1 -1
  588. package/presets/mavis/php-hexagonal/REPO_AGENTS.md +8 -0
  589. package/presets/mavis/php-hexagonal/adapter-map.json +17 -1
  590. package/presets/mavis/php-hexagonal/hooks/chain-team-phases.sh +4 -1
  591. package/presets/mavis/php-hexagonal/rules/agent-team-orchestrator.md +1 -1
  592. package/presets/mavis/php-hexagonal/rules/feature-delivery-workflow.md +51 -1
  593. package/presets/mavis/php-hexagonal/rules/preset-pr-checklist.md +2 -2
  594. package/presets/mavis/php-hexagonal/rules/reference-features.md +25 -0
  595. package/presets/mavis/php-hexagonal/skills/feature-delivery/SKILL.md +2 -2
  596. package/presets/mavis/php-hexagonal/team/README.md +1 -1
  597. package/presets/mavis/php-hexagonal/team/fixtures/feature-parallel.json +84 -0
  598. package/presets/mavis/php-laravel/MAVIS.md +1 -1
  599. package/presets/mavis/php-laravel/REPO_AGENTS.md +8 -0
  600. package/presets/mavis/php-laravel/adapter-map.json +17 -1
  601. package/presets/mavis/php-laravel/hooks/chain-team-phases.sh +4 -1
  602. package/presets/mavis/php-laravel/rules/agent-team-orchestrator.md +1 -1
  603. package/presets/mavis/php-laravel/rules/feature-delivery-workflow.md +54 -1
  604. package/presets/mavis/php-laravel/rules/preset-pr-checklist.md +2 -2
  605. package/presets/mavis/php-laravel/rules/reference-features.md +27 -0
  606. package/presets/mavis/php-laravel/skills/feature-delivery/SKILL.md +2 -2
  607. package/presets/mavis/php-laravel/team/README.md +1 -1
  608. package/presets/mavis/php-laravel/team/fixtures/feature-parallel.json +84 -0
  609. package/presets/mavis/svelte/REPO_AGENTS.md +8 -0
  610. package/presets/mavis/svelte/adapter-map.json +17 -1
  611. package/presets/mavis/svelte/hooks/chain-team-phases.sh +4 -1
  612. package/presets/mavis/svelte/rules/agent-team-orchestrator.md +1 -1
  613. package/presets/mavis/svelte/rules/feature-delivery-workflow.md +7 -7
  614. package/presets/mavis/svelte/rules/preset-pr-checklist.md +2 -2
  615. package/presets/mavis/svelte/rules/reference-features.md +1 -20
  616. package/presets/mavis/svelte/team/README.md +1 -1
  617. package/presets/mavis/svelte/team/fixtures/feature-parallel.json +84 -0
  618. package/presets/opencode/android-kotlin/REPO_AGENTS.md +8 -0
  619. package/presets/opencode/android-kotlin/adapter-map.json +19 -2
  620. package/presets/opencode/android-kotlin/hooks/chain-team-phases.sh +4 -1
  621. package/presets/opencode/android-kotlin/rules/agent-team-orchestrator.md +1 -1
  622. package/presets/opencode/android-kotlin/rules/feature-delivery-workflow.md +66 -8
  623. package/presets/opencode/android-kotlin/rules/preset-pr-checklist.md +2 -2
  624. package/presets/opencode/android-kotlin/rules/reference-features.md +48 -2
  625. package/presets/opencode/android-kotlin/skills/unit-testing/SKILL.md +1 -1
  626. package/presets/opencode/android-kotlin/team/README.md +1 -1
  627. package/presets/opencode/android-kotlin/team/fixtures/feature-parallel.json +84 -0
  628. package/presets/opencode/go/REPO_AGENTS.md +8 -0
  629. package/presets/opencode/go/adapter-map.json +17 -1
  630. package/presets/opencode/go/hooks/chain-team-phases.sh +4 -1
  631. package/presets/opencode/go/rules/agent-team-orchestrator.md +1 -1
  632. package/presets/opencode/go/rules/feature-delivery-workflow.md +50 -1
  633. package/presets/opencode/go/rules/preset-pr-checklist.md +2 -2
  634. package/presets/opencode/go/rules/reference-features.md +22 -0
  635. package/presets/opencode/go/skills/feature-delivery/SKILL.md +2 -2
  636. package/presets/opencode/go/skills/unit-testing/SKILL.md +1 -1
  637. package/presets/opencode/go/team/README.md +1 -1
  638. package/presets/opencode/go/team/fixtures/feature-parallel.json +84 -0
  639. package/presets/opencode/ios-swift/REPO_AGENTS.md +8 -0
  640. package/presets/opencode/ios-swift/adapter-map.json +17 -1
  641. package/presets/opencode/ios-swift/hooks/chain-team-phases.sh +4 -1
  642. package/presets/opencode/ios-swift/rules/agent-team-orchestrator.md +1 -1
  643. package/presets/opencode/ios-swift/rules/feature-delivery-workflow.md +8 -8
  644. package/presets/opencode/ios-swift/rules/preset-pr-checklist.md +2 -2
  645. package/presets/opencode/ios-swift/rules/reference-features.md +2 -21
  646. package/presets/opencode/ios-swift/skills/unit-testing/SKILL.md +1 -1
  647. package/presets/opencode/ios-swift/team/README.md +1 -1
  648. package/presets/opencode/ios-swift/team/fixtures/feature-parallel.json +84 -0
  649. package/presets/opencode/java/OPENCODE.md +1 -1
  650. package/presets/opencode/java/REPO_AGENTS.md +8 -0
  651. package/presets/opencode/java/adapter-map.json +17 -1
  652. package/presets/opencode/java/hooks/chain-team-phases.sh +4 -1
  653. package/presets/opencode/java/rules/agent-team-orchestrator.md +1 -1
  654. package/presets/opencode/java/rules/feature-delivery-workflow.md +51 -1
  655. package/presets/opencode/java/rules/preset-pr-checklist.md +2 -2
  656. package/presets/opencode/java/rules/reference-features.md +22 -0
  657. package/presets/opencode/java/skills/feature-delivery/SKILL.md +2 -2
  658. package/presets/opencode/java/team/README.md +1 -1
  659. package/presets/opencode/java/team/fixtures/feature-parallel.json +84 -0
  660. package/presets/opencode/mcp-ts/REPO_AGENTS.md +8 -0
  661. package/presets/opencode/mcp-ts/adapter-map.json +17 -1
  662. package/presets/opencode/mcp-ts/hooks/chain-team-phases.sh +4 -1
  663. package/presets/opencode/mcp-ts/rules/agent-team-orchestrator.md +1 -1
  664. package/presets/opencode/mcp-ts/rules/feature-delivery-workflow.md +47 -1
  665. package/presets/opencode/mcp-ts/rules/preset-pr-checklist.md +2 -2
  666. package/presets/opencode/mcp-ts/rules/reference-features.md +22 -0
  667. package/presets/opencode/mcp-ts/skills/code-review/SKILL.md +1 -1
  668. package/presets/opencode/mcp-ts/skills/feature-delivery/SKILL.md +2 -2
  669. package/presets/opencode/mcp-ts/skills/unit-testing/SKILL.md +1 -1
  670. package/presets/opencode/mcp-ts/team/README.md +1 -1
  671. package/presets/opencode/mcp-ts/team/fixtures/feature-parallel.json +84 -0
  672. package/presets/opencode/mol/REPO_AGENTS.md +8 -0
  673. package/presets/opencode/mol/adapter-map.json +9 -1
  674. package/presets/opencode/mol/hooks/chain-team-phases.sh +4 -1
  675. package/presets/opencode/mol/rules/agent-team-orchestrator.md +1 -1
  676. package/presets/opencode/mol/rules/feature-delivery-workflow.md +10 -10
  677. package/presets/opencode/mol/rules/preset-pr-checklist.md +2 -2
  678. package/presets/opencode/mol/rules/reference-features.md +0 -19
  679. package/presets/opencode/mol/team/README.md +1 -1
  680. package/presets/opencode/next/REPO_AGENTS.md +8 -0
  681. package/presets/opencode/next/adapter-map.json +9 -1
  682. package/presets/opencode/next/agents/build-verifier.md +1 -1
  683. package/presets/opencode/next/agents/code-reviewer.md +2 -0
  684. package/presets/opencode/next/hooks/chain-team-phases.sh +4 -1
  685. package/presets/opencode/next/rules/agent-team-orchestrator.md +1 -1
  686. package/presets/opencode/next/rules/feature-delivery-workflow.md +13 -13
  687. package/presets/opencode/next/rules/next-app-core.md +1 -1
  688. package/presets/opencode/next/rules/preset-pr-checklist.md +2 -2
  689. package/presets/opencode/next/rules/reference-features.md +0 -19
  690. package/presets/opencode/next/team/README.md +1 -1
  691. package/presets/opencode/nuxt/REPO_AGENTS.md +8 -0
  692. package/presets/opencode/nuxt/adapter-map.json +17 -1
  693. package/presets/opencode/nuxt/hooks/chain-team-phases.sh +4 -1
  694. package/presets/opencode/nuxt/rules/agent-team-orchestrator.md +1 -1
  695. package/presets/opencode/nuxt/rules/feature-delivery-workflow.md +9 -9
  696. package/presets/opencode/nuxt/rules/preset-pr-checklist.md +2 -2
  697. package/presets/opencode/nuxt/rules/reference-features.md +1 -20
  698. package/presets/opencode/nuxt/team/README.md +1 -1
  699. package/presets/opencode/nuxt/team/fixtures/feature-parallel.json +84 -0
  700. package/presets/opencode/php-hexagonal/OPENCODE.md +1 -1
  701. package/presets/opencode/php-hexagonal/REPO_AGENTS.md +8 -0
  702. package/presets/opencode/php-hexagonal/adapter-map.json +17 -1
  703. package/presets/opencode/php-hexagonal/hooks/chain-team-phases.sh +4 -1
  704. package/presets/opencode/php-hexagonal/rules/agent-team-orchestrator.md +1 -1
  705. package/presets/opencode/php-hexagonal/rules/feature-delivery-workflow.md +51 -1
  706. package/presets/opencode/php-hexagonal/rules/preset-pr-checklist.md +2 -2
  707. package/presets/opencode/php-hexagonal/rules/reference-features.md +25 -0
  708. package/presets/opencode/php-hexagonal/skills/feature-delivery/SKILL.md +2 -2
  709. package/presets/opencode/php-hexagonal/team/README.md +1 -1
  710. package/presets/opencode/php-hexagonal/team/fixtures/feature-parallel.json +84 -0
  711. package/presets/opencode/php-laravel/OPENCODE.md +1 -1
  712. package/presets/opencode/php-laravel/REPO_AGENTS.md +8 -0
  713. package/presets/opencode/php-laravel/adapter-map.json +17 -1
  714. package/presets/opencode/php-laravel/hooks/chain-team-phases.sh +4 -1
  715. package/presets/opencode/php-laravel/rules/agent-team-orchestrator.md +1 -1
  716. package/presets/opencode/php-laravel/rules/feature-delivery-workflow.md +54 -1
  717. package/presets/opencode/php-laravel/rules/preset-pr-checklist.md +2 -2
  718. package/presets/opencode/php-laravel/rules/reference-features.md +27 -0
  719. package/presets/opencode/php-laravel/skills/feature-delivery/SKILL.md +2 -2
  720. package/presets/opencode/php-laravel/team/README.md +1 -1
  721. package/presets/opencode/php-laravel/team/fixtures/feature-parallel.json +84 -0
  722. package/presets/opencode/plugins/output-guard/README.md +3 -2
  723. package/presets/opencode/plugins/output-guard/rewrite.ts +10 -1
  724. package/presets/opencode/svelte/REPO_AGENTS.md +8 -0
  725. package/presets/opencode/svelte/adapter-map.json +17 -1
  726. package/presets/opencode/svelte/hooks/chain-team-phases.sh +4 -1
  727. package/presets/opencode/svelte/rules/agent-team-orchestrator.md +1 -1
  728. package/presets/opencode/svelte/rules/feature-delivery-workflow.md +7 -7
  729. package/presets/opencode/svelte/rules/preset-pr-checklist.md +2 -2
  730. package/presets/opencode/svelte/rules/reference-features.md +1 -20
  731. package/presets/opencode/svelte/team/README.md +1 -1
  732. package/presets/opencode/svelte/team/fixtures/feature-parallel.json +84 -0
  733. package/presets/zcode/android-kotlin/REPO_AGENTS.md +8 -0
  734. package/presets/zcode/android-kotlin/adapter-map.json +19 -2
  735. package/presets/zcode/android-kotlin/hooks/chain-team-phases.sh +4 -1
  736. package/presets/zcode/android-kotlin/rules/README.md +3 -3
  737. package/presets/zcode/android-kotlin/rules/agent-team-orchestrator.md +1 -1
  738. package/presets/zcode/android-kotlin/rules/feature-delivery-workflow.md +66 -8
  739. package/presets/zcode/android-kotlin/rules/preset-pr-checklist.md +2 -2
  740. package/presets/zcode/android-kotlin/rules/reference-features.md +48 -2
  741. package/presets/zcode/android-kotlin/skills/unit-testing/SKILL.md +1 -1
  742. package/presets/zcode/android-kotlin/team/README.md +1 -1
  743. package/presets/zcode/android-kotlin/team/fixtures/feature-parallel.json +84 -0
  744. package/presets/zcode/go/REPO_AGENTS.md +8 -0
  745. package/presets/zcode/go/adapter-map.json +17 -1
  746. package/presets/zcode/go/hooks/chain-team-phases.sh +4 -1
  747. package/presets/zcode/go/rules/README.md +3 -3
  748. package/presets/zcode/go/rules/agent-team-orchestrator.md +1 -1
  749. package/presets/zcode/go/rules/feature-delivery-workflow.md +50 -1
  750. package/presets/zcode/go/rules/preset-pr-checklist.md +2 -2
  751. package/presets/zcode/go/rules/reference-features.md +22 -0
  752. package/presets/zcode/go/skills/feature-delivery/SKILL.md +2 -2
  753. package/presets/zcode/go/skills/unit-testing/SKILL.md +1 -1
  754. package/presets/zcode/go/team/README.md +1 -1
  755. package/presets/zcode/go/team/fixtures/feature-parallel.json +84 -0
  756. package/presets/zcode/ios-swift/REPO_AGENTS.md +8 -0
  757. package/presets/zcode/ios-swift/adapter-map.json +17 -1
  758. package/presets/zcode/ios-swift/hooks/chain-team-phases.sh +4 -1
  759. package/presets/zcode/ios-swift/rules/README.md +3 -3
  760. package/presets/zcode/ios-swift/rules/agent-team-orchestrator.md +1 -1
  761. package/presets/zcode/ios-swift/rules/feature-delivery-workflow.md +8 -8
  762. package/presets/zcode/ios-swift/rules/preset-pr-checklist.md +2 -2
  763. package/presets/zcode/ios-swift/rules/reference-features.md +2 -21
  764. package/presets/zcode/ios-swift/skills/unit-testing/SKILL.md +1 -1
  765. package/presets/zcode/ios-swift/team/README.md +1 -1
  766. package/presets/zcode/ios-swift/team/fixtures/feature-parallel.json +84 -0
  767. package/presets/zcode/java/REPO_AGENTS.md +8 -0
  768. package/presets/zcode/java/adapter-map.json +17 -1
  769. package/presets/zcode/java/hooks/chain-team-phases.sh +4 -1
  770. package/presets/zcode/java/rules/README.md +3 -3
  771. package/presets/zcode/java/rules/agent-team-orchestrator.md +1 -1
  772. package/presets/zcode/java/rules/feature-delivery-workflow.md +51 -1
  773. package/presets/zcode/java/rules/preset-pr-checklist.md +2 -2
  774. package/presets/zcode/java/rules/reference-features.md +22 -0
  775. package/presets/zcode/java/skills/feature-delivery/SKILL.md +2 -2
  776. package/presets/zcode/java/team/README.md +1 -1
  777. package/presets/zcode/java/team/fixtures/feature-parallel.json +84 -0
  778. package/presets/zcode/mcp-ts/REPO_AGENTS.md +8 -0
  779. package/presets/zcode/mcp-ts/adapter-map.json +17 -1
  780. package/presets/zcode/mcp-ts/hooks/chain-team-phases.sh +4 -1
  781. package/presets/zcode/mcp-ts/rules/README.md +3 -3
  782. package/presets/zcode/mcp-ts/rules/agent-team-orchestrator.md +1 -1
  783. package/presets/zcode/mcp-ts/rules/feature-delivery-workflow.md +47 -1
  784. package/presets/zcode/mcp-ts/rules/preset-pr-checklist.md +2 -2
  785. package/presets/zcode/mcp-ts/rules/reference-features.md +22 -0
  786. package/presets/zcode/mcp-ts/skills/code-review/SKILL.md +1 -1
  787. package/presets/zcode/mcp-ts/skills/feature-delivery/SKILL.md +2 -2
  788. package/presets/zcode/mcp-ts/skills/unit-testing/SKILL.md +1 -1
  789. package/presets/zcode/mcp-ts/team/README.md +1 -1
  790. package/presets/zcode/mcp-ts/team/fixtures/feature-parallel.json +84 -0
  791. package/presets/zcode/mol/REPO_AGENTS.md +8 -0
  792. package/presets/zcode/mol/adapter-map.json +9 -1
  793. package/presets/zcode/mol/hooks/chain-team-phases.sh +4 -1
  794. package/presets/zcode/mol/rules/README.md +3 -3
  795. package/presets/zcode/mol/rules/agent-team-orchestrator.md +1 -1
  796. package/presets/zcode/mol/rules/feature-delivery-workflow.md +10 -10
  797. package/presets/zcode/mol/rules/preset-pr-checklist.md +2 -2
  798. package/presets/zcode/mol/rules/reference-features.md +0 -19
  799. package/presets/zcode/mol/team/README.md +1 -1
  800. package/presets/zcode/next/REPO_AGENTS.md +8 -0
  801. package/presets/zcode/next/adapter-map.json +9 -1
  802. package/presets/zcode/next/agents/build-verifier.md +1 -1
  803. package/presets/zcode/next/agents/code-reviewer.md +2 -0
  804. package/presets/zcode/next/hooks/chain-team-phases.sh +4 -1
  805. package/presets/zcode/next/rules/README.md +3 -3
  806. package/presets/zcode/next/rules/agent-team-orchestrator.md +1 -1
  807. package/presets/zcode/next/rules/feature-delivery-workflow.md +13 -13
  808. package/presets/zcode/next/rules/next-app-core.md +1 -1
  809. package/presets/zcode/next/rules/preset-pr-checklist.md +2 -2
  810. package/presets/zcode/next/rules/reference-features.md +0 -19
  811. package/presets/zcode/next/team/README.md +1 -1
  812. package/presets/zcode/nuxt/REPO_AGENTS.md +8 -0
  813. package/presets/zcode/nuxt/adapter-map.json +17 -1
  814. package/presets/zcode/nuxt/hooks/chain-team-phases.sh +4 -1
  815. package/presets/zcode/nuxt/rules/README.md +3 -3
  816. package/presets/zcode/nuxt/rules/agent-team-orchestrator.md +1 -1
  817. package/presets/zcode/nuxt/rules/feature-delivery-workflow.md +9 -9
  818. package/presets/zcode/nuxt/rules/preset-pr-checklist.md +2 -2
  819. package/presets/zcode/nuxt/rules/reference-features.md +1 -20
  820. package/presets/zcode/nuxt/team/README.md +1 -1
  821. package/presets/zcode/nuxt/team/fixtures/feature-parallel.json +84 -0
  822. package/presets/zcode/php-hexagonal/REPO_AGENTS.md +8 -0
  823. package/presets/zcode/php-hexagonal/adapter-map.json +17 -1
  824. package/presets/zcode/php-hexagonal/hooks/chain-team-phases.sh +4 -1
  825. package/presets/zcode/php-hexagonal/rules/README.md +3 -3
  826. package/presets/zcode/php-hexagonal/rules/agent-team-orchestrator.md +1 -1
  827. package/presets/zcode/php-hexagonal/rules/feature-delivery-workflow.md +51 -1
  828. package/presets/zcode/php-hexagonal/rules/preset-pr-checklist.md +2 -2
  829. package/presets/zcode/php-hexagonal/rules/reference-features.md +25 -0
  830. package/presets/zcode/php-hexagonal/skills/feature-delivery/SKILL.md +2 -2
  831. package/presets/zcode/php-hexagonal/team/README.md +1 -1
  832. package/presets/zcode/php-hexagonal/team/fixtures/feature-parallel.json +84 -0
  833. package/presets/zcode/php-laravel/REPO_AGENTS.md +8 -0
  834. package/presets/zcode/php-laravel/adapter-map.json +17 -1
  835. package/presets/zcode/php-laravel/hooks/chain-team-phases.sh +4 -1
  836. package/presets/zcode/php-laravel/rules/README.md +3 -3
  837. package/presets/zcode/php-laravel/rules/agent-team-orchestrator.md +1 -1
  838. package/presets/zcode/php-laravel/rules/feature-delivery-workflow.md +54 -1
  839. package/presets/zcode/php-laravel/rules/preset-pr-checklist.md +2 -2
  840. package/presets/zcode/php-laravel/rules/reference-features.md +27 -0
  841. package/presets/zcode/php-laravel/skills/feature-delivery/SKILL.md +2 -2
  842. package/presets/zcode/php-laravel/team/README.md +1 -1
  843. package/presets/zcode/php-laravel/team/fixtures/feature-parallel.json +84 -0
  844. package/presets/zcode/svelte/REPO_AGENTS.md +8 -0
  845. package/presets/zcode/svelte/adapter-map.json +17 -1
  846. package/presets/zcode/svelte/hooks/chain-team-phases.sh +4 -1
  847. package/presets/zcode/svelte/rules/README.md +3 -3
  848. package/presets/zcode/svelte/rules/agent-team-orchestrator.md +1 -1
  849. package/presets/zcode/svelte/rules/feature-delivery-workflow.md +7 -7
  850. package/presets/zcode/svelte/rules/preset-pr-checklist.md +2 -2
  851. package/presets/zcode/svelte/rules/reference-features.md +1 -20
  852. package/presets/zcode/svelte/team/README.md +1 -1
  853. package/presets/zcode/svelte/team/fixtures/feature-parallel.json +84 -0
  854. package/scripts/close-agent-task-human-gate.mjs +3 -3
  855. package/scripts/report-context-cost.mjs +10 -3
  856. package/scripts/aggregate-agent-task-metrics.mjs +0 -480
@@ -233,7 +233,7 @@ On each `subagentStop`, the hook reconciles `status.state` from the completing p
233
233
  | `scope` | e.g. `unit-in-dev`, `e2e-only` — passed to developer/qa |
234
234
  | `model` | `cheap` \| `standard` \| `strong` — optional tier override |
235
235
 
236
- `writeScopes` are reconciled after the step, never in the hook: `node .ai.local/scripts/check-write-scope.mjs --slug <slug> --step <step-id> --json` labels every changed path `declared`, `derived`, or `out-of-scope`. The orchestrator writes the step baseline (`--step <step-id> --save-baseline`) before the step writes, so the audit sees this step's paths and not the earlier ones. Exit `3` is a skip, not a failure: a pipeline that predates step ids or `writeScopes` is not auditable, and the reason goes under `## Soft notes`. `build-verifier` hard-fails an out-of-scope implementation write; `code-reviewer` reports a reviewer-step path as advisory.
236
+ `writeScopes` are reconciled after the step, never in the hook: `node .ai.local/scripts/check-write-scope.mjs --slug <slug> --step <step-id> --json` labels every changed path `declared`, `derived`, or `out-of-scope`. The orchestrator writes the step baseline (`--step <step-id> --save-baseline`) before the step writes, so the audit sees this step's paths and not the earlier ones. Automatic selection only considers steps with an `id`, because the baseline file is keyed by it. Exit `3` is a skip, not a failure: a pipeline that predates step ids or `writeScopes` is not auditable, and the reason goes under `## Soft notes`. Exit `2` is a usage error (unknown `--step`, unreadable `pipeline.json`, failed git ref): the audit did not run and the result is neither a pass nor a finding — fix the invocation and re-run. A `no-baseline` skip is an orchestration defect: the step wrote without its baseline, so no path can be attributed to it — save the baseline and re-run the audit instead of reading the skip as a pass. `build-verifier` hard-fails an out-of-scope implementation write; `code-reviewer` reports a reviewer-step path as advisory.
237
237
 
238
238
  ## Rules (strict)
239
239
 
@@ -56,4 +56,54 @@ flowchart LR
56
56
 
57
57
  ## Zone → rules matrix
58
58
 
59
- Filled in the stack adapter: concrete globs/paths and `.mdc` / topic `.md` names.
59
+ Filled in the stack adapter: concrete globs/paths and each rule name in the format that platform ships.
60
+
61
+ ## Stack notes
62
+
63
+ Order of work:
64
+
65
+ 1. **Domain** — entities/VOs/errors (`domain-layer`).
66
+ 2. **Application + ports** — use case + outbound interfaces (`application-usecases`, `ports-interfaces`).
67
+ 3. **Driven adapters** — persistence/cache/messaging implementing ports (`adapters-driven`, `persistence-adapters`).
68
+ 4. **Driving adapters** — HTTP/gRPC/CLI mapping DTOs (`adapters-driving`, `api-http`; stubs for gRPC/messaging).
69
+ 5. **Composition root** — wire in `configuration/` / `*Application.java` (`composition-root`).
70
+ 6. **Tests** — unit (domain/app) → integration (adapters) → optional e2e smoke.
71
+ 7. **Gate** — `post-change-test` (+ `java-tooling`). When the current WP spans **more than one** layer or module, `implementation.md` includes a **Code Map** (3–8 annotated paths) and **Suggested Review Order** (`concern | path:line | ≤15 word note`). Omit both for a single-file or single-layer WP.
72
+
73
+ ```mermaid
74
+ flowchart LR
75
+ D[Domain] --> A[Application+Ports]
76
+ A --> Drv[Driven adapters]
77
+ Drv --> A
78
+ HTTP[Driving HTTP] --> A
79
+ CR[Composition root] --> HTTP
80
+ CR --> A
81
+ CR --> Drv
82
+ ```
83
+
84
+ ### Matrix
85
+
86
+ | Path | Rules |
87
+ |------|-------|
88
+ | `**/domain/**` | `domain-layer`, `architecture-boundaries` |
89
+ | `**/application/**` | `application-usecases`, `ports-interfaces` |
90
+ | `**/adapters/inbound/**`, `**/adapters/http/**` | `adapters-driving`, `api-http` / `api-grpc` |
91
+ | `**/adapters/outbound/**`, `**/adapters/persistence/**` | `adapters-driven`, `persistence-adapters` / `messaging-adapters` |
92
+ | `**/configuration/**`, `**/*Application.java` | `composition-root` |
93
+ | After `*.java` edits | `post-change-test` (+ `java-tooling`) |
94
+
95
+ ### Anti-patterns
96
+
97
+ - Framework types in domain; SQL/JPQL in use cases; DI inside controllers; skipping port interfaces “for speed”; returning JPA entities as HTTP bodies.
98
+ - **Ubiquitous language:** Domain names/boundaries reflect the feature domain — do not mix transport/framework terms into domain without need.
99
+ - Load `design-guidance` (rule stem) when assessing structure, smells, or pattern fit.
100
+ - Spring Boot is the default edge; plain Java / Quarkus / Micronaut keep the same layer order with different wiring.
101
+ - Do not mutate pipeline `status.json` / `metrics.json`; the orchestration hook is the single writer. Skills upsert the owned terminal receipt in `artifact-manifest.json`.
102
+
103
+ ### Iterative refinement loop
104
+
105
+ Every stage runs the named loop **draft → evaluate against named criteria → refine** with a named oracle (structural gate, reviewer parity check, test suite, or human approval). **Exit criteria:** a layer or stage is complete only when its named criteria hold; do not advance past a failing oracle. A repeatedly failing oracle triggers **plan revision**.
106
+
107
+ ### Related
108
+
109
+ - Product behavior discovery: requestable **`product-specs`** (`docs/specs/INDEX.md`) — do not paste the discovery algorithm here.
@@ -23,7 +23,7 @@ Checklist for PRs that touch `packages/ai-rules/presets/**` (and dogfood `.curso
23
23
  - [ ] **README:** stack `rules/README.md` core→stack mapping / catalog updated if stems added
24
24
  - [ ] **CHANGELOG / package README:** note when public preset paths or install surface change
25
25
  - [ ] **i18n anchors:** kept-marked Cyrillic fragments in `tests-unit.md(c)` stay consistent with their English counterparts. Run `packages/ai-rules/scripts/check-preset-i18n.sh`.
26
- - [ ] **Dogfood:** run `packages/ai-rules/scripts/sync-dogfood-cursor.sh`, `sync-dogfood-claude.sh`, `sync-dogfood-mavis.sh`, and `sync-dogfood-opencode.sh` when those platforms changed, or document an intentional skip, when maintaining this monorepo
26
+ - [ ] **Dogfood:** run `packages/ai-rules/scripts/sync-dogfood-cursor.sh`, `sync-dogfood-claude.sh`, `sync-dogfood-mavis.sh`, `sync-dogfood-opencode.sh`, and `sync-dogfood-zcode.sh` when those platforms changed, or document an intentional skip, when maintaining this monorepo
27
27
  - [ ] **shared-core drift:** for embed-mode stems, run `packages/ai-rules/scripts/check-shared-core-drift.sh` (or document intentional fork)
28
28
  - [ ] **Packaging:** every installable preset ships `REPO_AGENTS.md`; default `hooks.json` does not reference `hooks/examples/`; `_shared/assets/docs-specs/` ships `INDEX.md` + `_templates/{page,feature}.md`; `product-specs` / `product-specs-authoring` stay requestable
29
29
  - [ ] **UI-only surfaces:** `mockup-reviewer`, `accessibility-reviewer`, `ux-design`, and the stack performance skill ship only on UI stacks (`check-preset-leakage.sh`)
@@ -40,6 +40,6 @@ Checklist for PRs that touch `packages/ai-rules/presets/**` (and dogfood `.curso
40
40
  - Budget: `preset-token-budget`
41
41
  - Leakage: `preset-no-cross-stack-leakage`
42
42
  - Validation: same `check:task` / `check:changed` loop; `yarn release:gate` before a release (`packages/ai-rules/scripts/release-gate.sh`)
43
- - Dogfood scripts: `packages/ai-rules/scripts/sync-dogfood-cursor.sh`, `sync-dogfood-claude.sh`, `sync-dogfood-mavis.sh`, `sync-dogfood-opencode.sh`
43
+ - Dogfood scripts: `packages/ai-rules/scripts/sync-dogfood-cursor.sh`, `sync-dogfood-claude.sh`, `sync-dogfood-mavis.sh`, `sync-dogfood-opencode.sh`, `sync-dogfood-zcode.sh`
44
44
  - Drift script: `packages/ai-rules/scripts/check-shared-core-drift.sh`
45
45
  - Orchestrator: when editing presets, load this checklist + twin-sync
@@ -43,3 +43,25 @@ Path pointer and stack tables — in the preset adapter (`.ai.local/conventions.
43
43
  - skill `feature-delivery` — end-to-end scenario.
44
44
 
45
45
  > Concrete path tables, globs, and dogfood checklists live in the stack adapter **Stack notes**.
46
+
47
+ ## Stack notes
48
+
49
+ Fill concrete paths after adopting this preset in a real service repo. Defaults below match layer-first single-module; adjust for feature-first / multi-module variants.
50
+
51
+ | Area | Example path | Glob hint |
52
+ |------|--------------|-----------|
53
+ | Domain | `src/main/java/<base>/domain/` | `**/domain/**` |
54
+ | Application / ports | `src/main/java/<base>/application/` | `**/application/**` |
55
+ | HTTP adapter | `src/main/java/<base>/adapters/inbound/http/` | `**/adapters/inbound/http/**`, `**/adapters/http/**` |
56
+ | Persistence | `src/main/java/<base>/adapters/outbound/persistence/` | `**/adapters/outbound/persistence/**`, `**/adapters/persistence/**` |
57
+ | Composition root | `…/configuration/`, `*Application.java` | `**/configuration/**`, `**/*Application.java` |
58
+ | Unit tests | `src/test/java/**/*Test.java` | `**/*Test.java`, `**/src/test/java/**` |
59
+ | Integration | `*IT.java` / `*IntegrationTest.java` | `**/*IT.java`, `**/integration/**` |
60
+
61
+ ### Dogfood scenarios
62
+
63
+ 1. `/task` new use case — domain → ports → adapters → wire → `post-change-test`.
64
+ 2. Bug in handler mapping — debugger + MockMvc / controller unit.
65
+ 3. Repository contract — integration-test trio + Testcontainers.
66
+ 4. OpenAPI/proto drift — api-contract-reviewer.
67
+ 5. Secrets in logs — security-reviewer + `security-java`.
@@ -8,10 +8,10 @@ Load `java-anti-hallucination` before writing or patching code or tests.
8
8
 
9
9
  1. Read brief, AC, and decomposition.
10
10
  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.
11
- 3. Follow `feature-delivery-workflow.md` + `reference-features.md`: domain → application/ports → driven adapters → driving adapters → composition root → tests.
11
+ 3. Follow `feature-delivery-workflow` + `reference-features`: domain → application/ports → driven adapters → driving adapters → composition root → tests.
12
12
  4. Wire DI only in `configuration/` / `*Application.java`.
13
13
  5. Add unit tests for domain/use cases; integration tests for risky adapters.
14
- 6. After Java edits: **invoke** `post-change-test.md` (+ `java-tooling.md`).
14
+ 6. After Java edits: **invoke** `post-change-test` (+ `java-tooling`).
15
15
 
16
16
  ## Do / Don't
17
17
 
@@ -124,5 +124,5 @@ Use the hook path for the platform that installed the tree: `.cursor`, `.claude`
124
124
  - **Manifest field name:** receipts go in `artifacts[]`. Anything written under `entries` is ignored — the hook reads only `artifacts` and prints a dual-read warning naming the file. See `agent-team/agent-artifact-contracts.md` § Schema field name.
125
125
  - **Evidence paths:** `authoritativePaths[]` is relative to the task directory (`brief.md`). A repo-root path (`.ai.local/team/tasks/<slug>/brief.md`) is rejected. Put anything outside the task directory — e.g. `openspec/changes/**` — in `evidencePaths[]`.
126
126
  - Manifest schema: shared core `agent-team/agent-artifact-contracts.md`. Read it first; producers upsert only their IDs.
127
- - Metrics: append-only allowlisted events — `agent-team/agent-task-metrics.md`. Aggregate: `node node_modules/@bonesofspring/ai-rules/scripts/aggregate-agent-task-metrics.mjs --team-root .ai.local/team`.
127
+ - Metrics: append-only allowlisted events — `agent-team/agent-task-metrics.md`. Aggregate: `node node_modules/@bonesofspring/ai-rules/presets/_shared/ai-local/scripts/aggregate-agent-task-metrics.mjs --team-root .ai.local/team`.
128
128
  - Commit `.ai.local/team/` templates (and slugs if you want them in clones).
@@ -0,0 +1,84 @@
1
+ {
2
+ "slug": "example-feature-parallel",
3
+ "intent": "feature",
4
+ "specMode": "none",
5
+ "profile": "full",
6
+ "routingDecision": {
7
+ "complexity": "high",
8
+ "riskFlags": ["cross-layer", "concurrency-state", "broad-test-surface"],
9
+ "routingReasons": [
10
+ "Two independent review surfaces (code + security) sit on the same dependency level, so the pipeline may schedule them as one parallel wave.",
11
+ "The step graph carries declared write scopes so the conflict model can prove the wave conflict-free before any step is marked parallel."
12
+ ],
13
+ "estimatedWorkPackages": 2,
14
+ "openDecisionCount": 0
15
+ },
16
+ "summary": "Step-graph feature pipeline with one parallel review wave",
17
+ "steps": [
18
+ {
19
+ "id": "T1",
20
+ "taskIds": ["T1"],
21
+ "agent": "task-analyst",
22
+ "label": "Clarify and decompose",
23
+ "writeScopes": [".ai.local/team/tasks/<slug>/brief.md", ".ai.local/team/tasks/<slug>/decomposition.md"],
24
+ "artifactOutputId": "analysis"
25
+ },
26
+ {
27
+ "id": "T2",
28
+ "taskIds": ["T2"],
29
+ "agent": "solution-architect",
30
+ "label": "Design boundaries",
31
+ "model": "strong",
32
+ "dependsOn": ["T1"],
33
+ "writeScopes": [".ai.local/team/tasks/<slug>/architecture.md"],
34
+ "artifactOutputId": "architecture"
35
+ },
36
+ {
37
+ "id": "T3",
38
+ "taskIds": ["T3"],
39
+ "agent": "feature-developer",
40
+ "label": "Implement + unit tests",
41
+ "scope": "unit-in-dev",
42
+ "dependsOn": ["T2"],
43
+ "writeScopes": ["app/src/feature", ".ai.local/team/tasks/<slug>/implementation.md"],
44
+ "artifactOutputId": "implementation"
45
+ },
46
+ {
47
+ "id": "T4",
48
+ "taskIds": ["T4"],
49
+ "agent": ["code-reviewer", "security-reviewer"],
50
+ "label": "Review (code + security)",
51
+ "parallel": true,
52
+ "dependsOn": ["T3"],
53
+ "writeScopes": [".ai.local/team/tasks/<slug>/review.md", ".ai.local/team/tasks/<slug>/security-review.md"],
54
+ "artifactInputIds": ["implementation"],
55
+ "artifactOutputIds": {
56
+ "code-reviewer": "review",
57
+ "security-reviewer": "security-review"
58
+ }
59
+ },
60
+ {
61
+ "id": "T5",
62
+ "taskIds": ["T5"],
63
+ "agent": "tech-writer",
64
+ "label": "Documentation",
65
+ "dependsOn": ["T3"],
66
+ "writeScopes": [".ai.local/team/tasks/<slug>/documentation.md"],
67
+ "artifactOutputId": "documentation"
68
+ },
69
+ {
70
+ "id": "T6",
71
+ "taskIds": ["T6"],
72
+ "agent": "build-verifier",
73
+ "label": "Validation gate",
74
+ "model": "cheap",
75
+ "dependsOn": ["T4", "T5"],
76
+ "writeScopes": [".ai.local/team/tasks/<slug>/validation-report.md"],
77
+ "artifactInputIds": ["implementation", "review", "security-review"],
78
+ "artifactOutputId": "validation"
79
+ }
80
+ ],
81
+ "humanGates": ["after:task-analyst"],
82
+ "autoChain": true,
83
+ "skipped": []
84
+ }
@@ -54,8 +54,16 @@ Empty output or a failed run stays silent.
54
54
 
55
55
  Gotchas, local patterns, and team decisions: **`.ai.local/conventions.md`** (fill after init; `init` does not overwrite it).
56
56
 
57
+ ## ZCode host
58
+
59
+ ZCode loads this file natively and has no per-tool map: this file is the entry. The essential rules are the always-on set under `.zcode/rules/` (plain Markdown, not auto-loaded) — start with `ai-local-overlay` and the stack app-core rule, and read the rest when the task scope matches. Agents, commands, and skills live under `.zcode/agents/`, `.zcode/commands/`, and `.zcode/skills/`.
60
+
61
+ On every turn, run `node .zcode/hooks/list-ai-local.mjs` with the paths this step will touch, apply the printed `.ai.local/rules/*.md` and `.ai.local/conventions.md`, and acknowledge `Using .ai.local: <rule-name>`. On the first reply of a session, run `node .zcode/hooks/check-preset-update.mjs` when it exists; the update-notice rules above apply.
62
+
57
63
  ## Local overlay (`.ai.local/`) — MANDATORY
58
64
 
59
65
  A `.ai.local/` directory MAY exist at the repo root or at any nesting depth in monorepos. **Every agent MUST read and apply it on every turn.** Rules there override preset rules; `override: kill <preset-rule-name>` drops that preset rule from context entirely.
60
66
 
61
67
  On every turn, run `list-ai-local.mjs` from the host hooks directory (`.cursor`, `.claude`, `.mavis`, `.opencode`, or `.zcode`) with the paths this step will touch, then apply the printed `.ai.local/rules/*.md` and `.ai.local/conventions.md`. The root overlay applies to every path; a nested one applies only under its directory. Do not read `shadowed` files or `rules-library/**` as rules. Acknowledge `Using .ai.local: <rule-name>` when answering. Authoring guide: `docs/LOCAL-OVERLAY.md`.
68
+
69
+ The `ai-local-overlay` rule is always-on on Cursor and session-start on Claude; Mavis, OpenCode, and ZCode have no native always-on mechanism, so this section plus the platform entry's essential-rules list is the reinforcement.
@@ -3,7 +3,7 @@
3
3
  "platform": "mavis",
4
4
  "stack": "mcp-ts",
5
5
  "semanticSource": "cursor/mcp-ts",
6
- "sourceRevision": "205674fba79a3a2f122e5db567f670b0183c7e70a7e7a200183efd4912d29ec0",
6
+ "sourceRevision": "a349b5a802ab6976b3c304865eb6ab1c27c5fd47cfe263fd5d511ad7ed8c9ac8",
7
7
  "entries": [
8
8
  {
9
9
  "source": "AGENTS.md",
@@ -180,6 +180,14 @@
180
180
  "loadMode": "manual",
181
181
  "reason": "Agent-run version check on the first reply; no native session hook on Mavis"
182
182
  },
183
+ {
184
+ "source": "hooks/compact-shell-output.mjs",
185
+ "target": null,
186
+ "category": "hooks",
187
+ "disposition": "omit",
188
+ "loadMode": "not-installed",
189
+ "reason": "omit: Cursor preToolUse rewrite; the large-output guard has no Mavis hook event"
190
+ },
183
191
  {
184
192
  "source": "hooks/examples/format-edited.example.sh",
185
193
  "target": null,
@@ -616,6 +624,14 @@
616
624
  "loadMode": "manual",
617
625
  "reason": "File pipeline templates; runtime artifacts seed to .ai.local/team"
618
626
  },
627
+ {
628
+ "source": "team/fixtures/feature-parallel.json",
629
+ "target": "team/fixtures/feature-parallel.json",
630
+ "category": "team",
631
+ "disposition": "copy",
632
+ "loadMode": "manual",
633
+ "reason": "File pipeline templates; runtime artifacts seed to .ai.local/team"
634
+ },
619
635
  {
620
636
  "source": "team/fixtures/memlog.example.md",
621
637
  "target": "team/fixtures/memlog.example.md",
@@ -68,7 +68,10 @@ function firstSeenAtOf(file, value, now) {
68
68
  try {
69
69
  if (Date.now() - fs.statSync(file).mtimeMs > LEASE_TTL_MS) return now;
70
70
  const previous = JSON.parse(fs.readFileSync(file, 'utf8'));
71
- if (previous && previous.slug === value && typeof previous.firstSeenAt === 'string') return previous.firstSeenAt;
71
+ if (previous && previous.slug === value) {
72
+ if (typeof previous.firstSeenAt === 'string') return previous.firstSeenAt;
73
+ if (typeof previous.updatedAt === 'string') return previous.updatedAt;
74
+ }
72
75
  } catch {}
73
76
  return now;
74
77
  }
@@ -233,7 +233,7 @@ On each `subagentStop`, the hook reconciles `status.state` from the completing p
233
233
  | `scope` | e.g. `unit-in-dev`, `e2e-only` — passed to developer/qa |
234
234
  | `model` | `cheap` \| `standard` \| `strong` — optional tier override |
235
235
 
236
- `writeScopes` are reconciled after the step, never in the hook: `node .ai.local/scripts/check-write-scope.mjs --slug <slug> --step <step-id> --json` labels every changed path `declared`, `derived`, or `out-of-scope`. The orchestrator writes the step baseline (`--step <step-id> --save-baseline`) before the step writes, so the audit sees this step's paths and not the earlier ones. Exit `3` is a skip, not a failure: a pipeline that predates step ids or `writeScopes` is not auditable, and the reason goes under `## Soft notes`. `build-verifier` hard-fails an out-of-scope implementation write; `code-reviewer` reports a reviewer-step path as advisory.
236
+ `writeScopes` are reconciled after the step, never in the hook: `node .ai.local/scripts/check-write-scope.mjs --slug <slug> --step <step-id> --json` labels every changed path `declared`, `derived`, or `out-of-scope`. The orchestrator writes the step baseline (`--step <step-id> --save-baseline`) before the step writes, so the audit sees this step's paths and not the earlier ones. Automatic selection only considers steps with an `id`, because the baseline file is keyed by it. Exit `3` is a skip, not a failure: a pipeline that predates step ids or `writeScopes` is not auditable, and the reason goes under `## Soft notes`. Exit `2` is a usage error (unknown `--step`, unreadable `pipeline.json`, failed git ref): the audit did not run and the result is neither a pass nor a finding — fix the invocation and re-run. A `no-baseline` skip is an orchestration defect: the step wrote without its baseline, so no path can be attributed to it — save the baseline and re-run the audit instead of reading the skip as a pass. `build-verifier` hard-fails an out-of-scope implementation write; `code-reviewer` reports a reviewer-step path as advisory.
237
237
 
238
238
  ## Rules (strict)
239
239
 
@@ -56,4 +56,50 @@ flowchart LR
56
56
 
57
57
  ## Zone → rules matrix
58
58
 
59
- Filled in the stack adapter: concrete globs/paths and `.mdc` / topic `.md` names.
59
+ Filled in the stack adapter: concrete globs/paths and each rule name in the format that platform ships.
60
+
61
+ ## Stack notes
62
+
63
+ Order of work:
64
+
65
+ 1. **Contract** — tool/resource/prompt name, description, input/output shape (`mcp-tool-design`).
66
+ 2. **Schema** — Zod authoring + JSON Schema-compatible registration (`mcp-ts-conventions`).
67
+ 3. **Handler** — validated inputs → scoped capability → safe result/error mapping.
68
+ 4. **Registration** — wire into server modules; keep entry (`src/index.ts`) free of tool business logic.
69
+ 5. **Tests** — unit + contract fixtures (`tests-unit`, `mcp-contract-testing`).
70
+ 6. **Package validation** — typecheck/test; optional Inspector smoke; `bin`/entry OK (`mcp-transport-packaging`).
71
+ 7. **Gate** — `post-change-test` (+ `mcp-ts-tooling`). When the current WP spans **more than one** layer or module, `implementation.md` includes a **Code Map** (3–8 annotated paths) and **Suggested Review Order** (`concern | path:line | ≤15 word note`). Omit both for a single-file or single-layer WP.
72
+
73
+ ```mermaid
74
+ flowchart LR
75
+ C[Contract] --> S[Schema]
76
+ S --> H[Handler]
77
+ H --> R[Register]
78
+ R --> T[Unit/contract tests]
79
+ T --> P[Package validate]
80
+ ```
81
+
82
+ ### Matrix
83
+
84
+ | Path | Rules |
85
+ |------|-------|
86
+ | `src/tools/**`, `src/resources/**`, `src/prompts/**` | `mcp-tool-design`, `mcp-server-boundaries` |
87
+ | schemas / validation | `mcp-ts-conventions`, `mcp-contract-testing` |
88
+ | `src/index.ts`, package `bin` | `mcp-transport-packaging` |
89
+ | auth/config | `mcp-auth-secrets`, `security-mcp` |
90
+ | After `*.ts` edits | `post-change-test` |
91
+
92
+ ### Anti-patterns
93
+
94
+ - Monolithic `index.ts`; unscoped shell/FS tools; inventing SDK APIs; skipping schema tests "for speed".
95
+ - Prescribing Go hexagonal folders or Next `app/src/**`.
96
+ - Load `design-guidance` when assessing structure, smells, or pattern fit.
97
+ - Do not mutate pipeline `status.json` / `metrics.json`; the orchestration hook is the single writer. Skills upsert the owned terminal receipt in `artifact-manifest.json`.
98
+
99
+ ### Iterative refinement loop
100
+
101
+ Every stage runs the named loop **draft → evaluate against named criteria → refine** with a named oracle (structural gate, reviewer parity check, test suite, or human approval). **Exit criteria:** a layer or stage is complete only when its named criteria hold; do not advance past a failing oracle. A repeatedly failing oracle triggers **plan revision**.
102
+
103
+ ### Related
104
+
105
+ - Product behavior discovery: requestable **`product-specs`** (`docs/specs/INDEX.md`) — do not paste the discovery algorithm here.
@@ -23,7 +23,7 @@ Checklist for PRs that touch `packages/ai-rules/presets/**` (and dogfood `.curso
23
23
  - [ ] **README:** stack `rules/README.md` core→stack mapping / catalog updated if stems added
24
24
  - [ ] **CHANGELOG / package README:** note when public preset paths or install surface change
25
25
  - [ ] **i18n anchors:** kept-marked Cyrillic fragments in `tests-unit.md(c)` stay consistent with their English counterparts. Run `packages/ai-rules/scripts/check-preset-i18n.sh`.
26
- - [ ] **Dogfood:** run `packages/ai-rules/scripts/sync-dogfood-cursor.sh`, `sync-dogfood-claude.sh`, `sync-dogfood-mavis.sh`, and `sync-dogfood-opencode.sh` when those platforms changed, or document an intentional skip, when maintaining this monorepo
26
+ - [ ] **Dogfood:** run `packages/ai-rules/scripts/sync-dogfood-cursor.sh`, `sync-dogfood-claude.sh`, `sync-dogfood-mavis.sh`, `sync-dogfood-opencode.sh`, and `sync-dogfood-zcode.sh` when those platforms changed, or document an intentional skip, when maintaining this monorepo
27
27
  - [ ] **shared-core drift:** for embed-mode stems, run `packages/ai-rules/scripts/check-shared-core-drift.sh` (or document intentional fork)
28
28
  - [ ] **Packaging:** every installable preset ships `REPO_AGENTS.md`; default `hooks.json` does not reference `hooks/examples/`; `_shared/assets/docs-specs/` ships `INDEX.md` + `_templates/{page,feature}.md`; `product-specs` / `product-specs-authoring` stay requestable
29
29
  - [ ] **UI-only surfaces:** `mockup-reviewer`, `accessibility-reviewer`, `ux-design`, and the stack performance skill ship only on UI stacks (`check-preset-leakage.sh`)
@@ -40,6 +40,6 @@ Checklist for PRs that touch `packages/ai-rules/presets/**` (and dogfood `.curso
40
40
  - Budget: `preset-token-budget`
41
41
  - Leakage: `preset-no-cross-stack-leakage`
42
42
  - Validation: same `check:task` / `check:changed` loop; `yarn release:gate` before a release (`packages/ai-rules/scripts/release-gate.sh`)
43
- - Dogfood scripts: `packages/ai-rules/scripts/sync-dogfood-cursor.sh`, `sync-dogfood-claude.sh`, `sync-dogfood-mavis.sh`, `sync-dogfood-opencode.sh`
43
+ - Dogfood scripts: `packages/ai-rules/scripts/sync-dogfood-cursor.sh`, `sync-dogfood-claude.sh`, `sync-dogfood-mavis.sh`, `sync-dogfood-opencode.sh`, `sync-dogfood-zcode.sh`
44
44
  - Drift script: `packages/ai-rules/scripts/check-shared-core-drift.sh`
45
45
  - Orchestrator: when editing presets, load this checklist + twin-sync
@@ -43,3 +43,25 @@ Path pointer and stack tables — in the preset adapter (`.ai.local/conventions.
43
43
  - skill `feature-delivery` — end-to-end scenario.
44
44
 
45
45
  > Concrete path tables, globs, and dogfood checklists live in the stack adapter **Stack notes**.
46
+
47
+ ## Stack notes
48
+
49
+ Canonical layout matches `dogfood/mcp-ts-sample/` (consumer repos may rename; prefer the same shapes).
50
+
51
+ | Area | Example path | Glob hint |
52
+ |------|--------------|-----------|
53
+ | Entry / transport | `src/index.ts` | `src/index.ts` |
54
+ | Tools | `src/tools/echo.ts` | `src/tools/**` |
55
+ | Tool tests | `src/tools/echo.spec.ts` | `src/tools/**/*.{test,spec}.ts` |
56
+ | Resources | `src/resources/` (optional) | `src/resources/**` |
57
+ | Prompts | `src/prompts/` (optional) | `src/prompts/**` |
58
+ | Schemas | colocated next to tool (or `schemas.ts`) | `**/schemas.ts`, `src/tools/**` |
59
+ | Build output | `dist/index.js` | `dist/**` |
60
+
61
+ ### Dogfood scenarios (Phase 1)
62
+
63
+ 1. `/task` add tool — contract → schema → handler → register → tests → package (`dogfood/mcp-ts-sample`).
64
+ 2. Schema validation bug — unit + contract fixtures on `src/tools/*.spec.ts`.
65
+ 3. Capability / secrets review — security-reviewer + `security-mcp` (e.g. FS allowlist tool when added).
66
+
67
+ Init (maintainer): `node packages/ai-rules/bin/cli.js init cursor --preset mcp-ts --cwd dogfood/mcp-ts-sample` — do not commit generated `.cursor/` into the sample unless the team decides otherwise.
@@ -6,7 +6,7 @@ Load `mcp-ts-anti-hallucination` before writing or patching code or tests.
6
6
 
7
7
  # Code review (mcp-ts)
8
8
 
9
- 1. Follow `code-review-mr.md`, `mcp-server-boundaries.md`, `mcp-tool-design.md`, `security-mcp.md`.
9
+ 1. Follow `code-review-mr`, `mcp-server-boundaries`, `mcp-tool-design`, `security-mcp`.
10
10
  2. Flag monolithic entry files, schema/protocol mismatches, unscopeed capabilities, secret leakage.
11
11
  3. Phase 1: security-reviewer covers threat model; no separate `code-reviewer` agent yet — parent may apply this skill directly.
12
12
  4. **Depth passes** — run all five from `code-review-mr` § Depth passes (call-site sweep, invariant check, trust boundary, test gap, half-life). Carry `confidence` on every finding and close with `## Not verified`.
@@ -8,9 +8,9 @@ Load `mcp-ts-anti-hallucination` before writing or patching code or tests.
8
8
 
9
9
  1. Read brief, AC, and decomposition.
10
10
  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.
11
- 3. Follow `feature-delivery-workflow.md` + `reference-features.md`: contract → schema → handler → register → unit/contract tests → package validation.
11
+ 3. Follow `feature-delivery-workflow` + `reference-features`: contract → schema → handler → register → unit/contract tests → package validation.
12
12
  4. Keep transport/lifecycle in the entry module; tools stay in registration modules.
13
- 5. After TS edits: **invoke** `post-change-test.md` (+ `mcp-ts-tooling.md`).
13
+ 5. After TS edits: **invoke** `post-change-test` (+ `mcp-ts-tooling`).
14
14
 
15
15
  ## Do / Don't
16
16
 
@@ -8,7 +8,7 @@ Load `mcp-ts-anti-hallucination` before writing or patching code or tests.
8
8
 
9
9
  1. Prefer table-driven tests for schema reject/accept and handler outcomes.
10
10
  2. Fake FS/network capabilities — no live MCP client required for unit scope.
11
- 3. Follow `tests-unit.md` and `mcp-contract-testing.md`.
11
+ 3. Follow `tests-unit` and `mcp-contract-testing`.
12
12
  4. Discover runner via `mcp-ts-tooling` (Vitest/Jest/node:test).
13
13
 
14
14
  ## Out of scope (Phase 1)
@@ -124,5 +124,5 @@ Use the hook path for the platform that installed the tree: `.cursor`, `.claude`
124
124
  - **Manifest field name:** receipts go in `artifacts[]`. Anything written under `entries` is ignored — the hook reads only `artifacts` and prints a dual-read warning naming the file. See `agent-team/agent-artifact-contracts.md` § Schema field name.
125
125
  - **Evidence paths:** `authoritativePaths[]` is relative to the task directory (`brief.md`). A repo-root path (`.ai.local/team/tasks/<slug>/brief.md`) is rejected. Put anything outside the task directory — e.g. `openspec/changes/**` — in `evidencePaths[]`.
126
126
  - Manifest schema: shared core `agent-team/agent-artifact-contracts.md`. Read it first; producers upsert only their IDs.
127
- - Metrics: append-only allowlisted events — `agent-team/agent-task-metrics.md`. Aggregate: `node node_modules/@bonesofspring/ai-rules/scripts/aggregate-agent-task-metrics.mjs --team-root .ai.local/team`.
127
+ - Metrics: append-only allowlisted events — `agent-team/agent-task-metrics.md`. Aggregate: `node node_modules/@bonesofspring/ai-rules/presets/_shared/ai-local/scripts/aggregate-agent-task-metrics.mjs --team-root .ai.local/team`.
128
128
  - Commit `.ai.local/team/` templates (and slugs if you want them in clones).
@@ -0,0 +1,84 @@
1
+ {
2
+ "slug": "example-feature-parallel",
3
+ "intent": "feature",
4
+ "specMode": "none",
5
+ "profile": "full",
6
+ "routingDecision": {
7
+ "complexity": "high",
8
+ "riskFlags": ["cross-layer", "concurrency-state", "broad-test-surface"],
9
+ "routingReasons": [
10
+ "Two independent review surfaces (code + security) sit on the same dependency level, so the pipeline may schedule them as one parallel wave.",
11
+ "The step graph carries declared write scopes so the conflict model can prove the wave conflict-free before any step is marked parallel."
12
+ ],
13
+ "estimatedWorkPackages": 2,
14
+ "openDecisionCount": 0
15
+ },
16
+ "summary": "Step-graph feature pipeline with one parallel review wave",
17
+ "steps": [
18
+ {
19
+ "id": "T1",
20
+ "taskIds": ["T1"],
21
+ "agent": "task-analyst",
22
+ "label": "Clarify and decompose",
23
+ "writeScopes": [".ai.local/team/tasks/<slug>/brief.md", ".ai.local/team/tasks/<slug>/decomposition.md"],
24
+ "artifactOutputId": "analysis"
25
+ },
26
+ {
27
+ "id": "T2",
28
+ "taskIds": ["T2"],
29
+ "agent": "solution-architect",
30
+ "label": "Design boundaries",
31
+ "model": "strong",
32
+ "dependsOn": ["T1"],
33
+ "writeScopes": [".ai.local/team/tasks/<slug>/architecture.md"],
34
+ "artifactOutputId": "architecture"
35
+ },
36
+ {
37
+ "id": "T3",
38
+ "taskIds": ["T3"],
39
+ "agent": "feature-developer",
40
+ "label": "Implement + unit tests",
41
+ "scope": "unit-in-dev",
42
+ "dependsOn": ["T2"],
43
+ "writeScopes": ["app/src/feature", ".ai.local/team/tasks/<slug>/implementation.md"],
44
+ "artifactOutputId": "implementation"
45
+ },
46
+ {
47
+ "id": "T4",
48
+ "taskIds": ["T4"],
49
+ "agent": ["code-reviewer", "security-reviewer"],
50
+ "label": "Review (code + security)",
51
+ "parallel": true,
52
+ "dependsOn": ["T3"],
53
+ "writeScopes": [".ai.local/team/tasks/<slug>/review.md", ".ai.local/team/tasks/<slug>/security-review.md"],
54
+ "artifactInputIds": ["implementation"],
55
+ "artifactOutputIds": {
56
+ "code-reviewer": "review",
57
+ "security-reviewer": "security-review"
58
+ }
59
+ },
60
+ {
61
+ "id": "T5",
62
+ "taskIds": ["T5"],
63
+ "agent": "tech-writer",
64
+ "label": "Documentation",
65
+ "dependsOn": ["T3"],
66
+ "writeScopes": [".ai.local/team/tasks/<slug>/documentation.md"],
67
+ "artifactOutputId": "documentation"
68
+ },
69
+ {
70
+ "id": "T6",
71
+ "taskIds": ["T6"],
72
+ "agent": "build-verifier",
73
+ "label": "Validation gate",
74
+ "model": "cheap",
75
+ "dependsOn": ["T4", "T5"],
76
+ "writeScopes": [".ai.local/team/tasks/<slug>/validation-report.md"],
77
+ "artifactInputIds": ["implementation", "review", "security-review"],
78
+ "artifactOutputId": "validation"
79
+ }
80
+ ],
81
+ "humanGates": ["after:task-analyst"],
82
+ "autoChain": true,
83
+ "skipped": []
84
+ }
@@ -60,8 +60,16 @@ Gotchas, local patterns, and team decisions: **`.ai.local/conventions.md`** (fil
60
60
 
61
61
  `init` owns `.cursor/**`, `.claude/**`, `.mavis/**`, `.opencode/**`, `.zcode/**`, root `AGENTS.md`, and the tool MCP config; it overwrites or 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.
62
62
 
63
+ ## ZCode host
64
+
65
+ ZCode loads this file natively and has no per-tool map: this file is the entry. The essential rules are the always-on set under `.zcode/rules/` (plain Markdown, not auto-loaded) — start with `ai-local-overlay` and the stack app-core rule, and read the rest when the task scope matches. Agents, commands, and skills live under `.zcode/agents/`, `.zcode/commands/`, and `.zcode/skills/`.
66
+
67
+ On every turn, run `node .zcode/hooks/list-ai-local.mjs` with the paths this step will touch, apply the printed `.ai.local/rules/*.md` and `.ai.local/conventions.md`, and acknowledge `Using .ai.local: <rule-name>`. On the first reply of a session, run `node .zcode/hooks/check-preset-update.mjs` when it exists; the update-notice rules above apply.
68
+
63
69
  ## Local overlay (`.ai.local/`) — MANDATORY
64
70
 
65
71
  A `.ai.local/` directory MAY exist at the repo root or at any nesting depth in monorepos. **Every agent MUST read and apply it on every turn.** Rules there override preset rules; `override: kill <preset-rule-name>` drops that preset rule from context entirely.
66
72
 
67
73
  On every turn, run `list-ai-local.mjs` from the host hooks directory (`.cursor`, `.claude`, `.mavis`, `.opencode`, or `.zcode`) with the paths this step will touch, then apply the printed `.ai.local/rules/*.md` and `.ai.local/conventions.md`. The root overlay applies to every path; a nested one applies only under its directory. Do not read `shadowed` files or `rules-library/**` as rules. Acknowledge `Using .ai.local: <rule-name>` when answering. Authoring guide: `docs/LOCAL-OVERLAY.md`.
74
+
75
+ The `ai-local-overlay` rule is always-on on Cursor and session-start on Claude; Mavis, OpenCode, and ZCode have no native always-on mechanism, so this section plus the platform entry's essential-rules list is the reinforcement.
@@ -3,7 +3,7 @@
3
3
  "platform": "mavis",
4
4
  "stack": "mol",
5
5
  "semanticSource": "cursor/mol",
6
- "sourceRevision": "200b654fec872e4095d0c0f75673efc7a8ec4eabbbacc7b1d4f23d592453ebe0",
6
+ "sourceRevision": "a00181c6f8de7fc56a43880db945f033d47700db86d33ff3062e3013539e08ab",
7
7
  "entries": [
8
8
  {
9
9
  "source": "AGENTS.md",
@@ -567,6 +567,14 @@
567
567
  "loadMode": "manual",
568
568
  "reason": "Agent-run version check on the first reply; no native session hook on Mavis"
569
569
  },
570
+ {
571
+ "source": "hooks/compact-shell-output.mjs",
572
+ "target": null,
573
+ "category": "hooks",
574
+ "disposition": "omit",
575
+ "loadMode": "not-installed",
576
+ "reason": "omit: Cursor preToolUse rewrite; the large-output guard has no Mavis hook event"
577
+ },
570
578
  {
571
579
  "source": "hooks/examples/format-edited.example.sh",
572
580
  "target": null,
@@ -65,7 +65,10 @@ function firstSeenAtOf(file, value, now) {
65
65
  try {
66
66
  if (Date.now() - fs.statSync(file).mtimeMs > LEASE_TTL_MS) return now;
67
67
  const previous = JSON.parse(fs.readFileSync(file, 'utf8'));
68
- if (previous && previous.slug === value && typeof previous.firstSeenAt === 'string') return previous.firstSeenAt;
68
+ if (previous && previous.slug === value) {
69
+ if (typeof previous.firstSeenAt === 'string') return previous.firstSeenAt;
70
+ if (typeof previous.updatedAt === 'string') return previous.updatedAt;
71
+ }
69
72
  } catch {}
70
73
  return now;
71
74
  }
@@ -233,7 +233,7 @@ On each `subagentStop`, the hook reconciles `status.state` from the completing p
233
233
  | `scope` | e.g. `unit-in-dev`, `e2e-only` — passed to developer/qa |
234
234
  | `model` | `cheap` \| `standard` \| `strong` — optional tier override |
235
235
 
236
- `writeScopes` are reconciled after the step, never in the hook: `node .ai.local/scripts/check-write-scope.mjs --slug <slug> --step <step-id> --json` labels every changed path `declared`, `derived`, or `out-of-scope`. The orchestrator writes the step baseline (`--step <step-id> --save-baseline`) before the step writes, so the audit sees this step's paths and not the earlier ones. Exit `3` is a skip, not a failure: a pipeline that predates step ids or `writeScopes` is not auditable, and the reason goes under `## Soft notes`. `build-verifier` hard-fails an out-of-scope implementation write; `code-reviewer` reports a reviewer-step path as advisory.
236
+ `writeScopes` are reconciled after the step, never in the hook: `node .ai.local/scripts/check-write-scope.mjs --slug <slug> --step <step-id> --json` labels every changed path `declared`, `derived`, or `out-of-scope`. The orchestrator writes the step baseline (`--step <step-id> --save-baseline`) before the step writes, so the audit sees this step's paths and not the earlier ones. Automatic selection only considers steps with an `id`, because the baseline file is keyed by it. Exit `3` is a skip, not a failure: a pipeline that predates step ids or `writeScopes` is not auditable, and the reason goes under `## Soft notes`. Exit `2` is a usage error (unknown `--step`, unreadable `pipeline.json`, failed git ref): the audit did not run and the result is neither a pass nor a finding — fix the invocation and re-run. A `no-baseline` skip is an orchestration defect: the step wrote without its baseline, so no path can be attributed to it — save the baseline and re-run the audit instead of reading the skip as a pass. `build-verifier` hard-fails an out-of-scope implementation write; `code-reviewer` reports a reviewer-step path as advisory.
237
237
 
238
238
  ## Rules (strict)
239
239