@bonesofspring/ai-rules 0.2.15 → 0.2.17
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.
- package/CHANGELOG.md +31 -0
- package/README.md +22 -3
- package/bin/cli.js +41 -0
- package/package.json +3 -1
- package/presets/_shared/README.md +2 -2
- package/presets/_shared/assets/docs-specs/INDEX.md +9 -0
- package/presets/_shared/assets/docs-specs/_templates/feature.md +32 -0
- package/presets/_shared/assets/docs-specs/_templates/page.md +47 -0
- package/presets/_shared/assets/docs-specs/schemas/frontmatter-v1.schema.json +22 -0
- package/presets/_shared/core/architecture/product-specs-authoring.md +107 -0
- package/presets/_shared/core/architecture/product-specs.md +49 -0
- package/presets/_shared/core/meta/preset-layering.md +1 -1
- package/presets/_shared/core/meta/preset-no-cross-stack-leakage.md +25 -12
- package/presets/_shared/core/meta/preset-pr-checklist.md +1 -1
- package/presets/_shared/core/meta/preset-twin-sync.md +2 -0
- package/presets/claude/android-kotlin/CLAUDE.md +38 -0
- package/presets/claude/android-kotlin/MCP.md +16 -0
- package/presets/claude/android-kotlin/README.md +32 -0
- package/presets/claude/android-kotlin/REPO_AGENTS.md +48 -0
- package/presets/claude/android-kotlin/agents/README.md +44 -0
- package/presets/claude/android-kotlin/agents/accessibility-reviewer.md +60 -0
- package/presets/claude/android-kotlin/agents/api-contract-reviewer.md +70 -0
- package/presets/claude/android-kotlin/agents/build-verifier.md +70 -0
- package/presets/claude/android-kotlin/agents/ci-investigator.md +74 -0
- package/presets/claude/android-kotlin/agents/code-reviewer.md +76 -0
- package/presets/claude/android-kotlin/agents/codebase-analyzer.md +28 -0
- package/presets/claude/android-kotlin/agents/debugger.md +77 -0
- package/presets/claude/android-kotlin/agents/feature-developer.md +70 -0
- package/presets/claude/android-kotlin/agents/instrumentation-test-generator.md +19 -0
- package/presets/claude/android-kotlin/agents/instrumentation-test-healer.md +19 -0
- package/presets/claude/android-kotlin/agents/instrumentation-test-planner.md +19 -0
- package/presets/claude/android-kotlin/agents/migration-specialist.md +74 -0
- package/presets/claude/android-kotlin/agents/performance-auditor.md +67 -0
- package/presets/claude/android-kotlin/agents/qa-tester.md +66 -0
- package/presets/claude/android-kotlin/agents/security-reviewer.md +65 -0
- package/presets/claude/android-kotlin/agents/solution-architect.md +21 -0
- package/presets/claude/android-kotlin/agents/task-analyst.md +55 -0
- package/presets/claude/android-kotlin/agents/task-router.md +114 -0
- package/presets/claude/android-kotlin/agents/tech-writer.md +66 -0
- package/presets/claude/android-kotlin/agents/unit-test-generator.md +55 -0
- package/presets/claude/android-kotlin/agents/unit-test-healer.md +54 -0
- package/presets/claude/android-kotlin/agents/unit-test-planner.md +65 -0
- package/presets/claude/android-kotlin/commands/README.md +51 -0
- package/presets/claude/android-kotlin/commands/feature-continue.md +23 -0
- package/presets/claude/android-kotlin/commands/feature-start.md +41 -0
- package/presets/claude/android-kotlin/commands/spec-start.md +29 -0
- package/presets/claude/android-kotlin/commands/task-continue.md +53 -0
- package/presets/claude/android-kotlin/commands/task.md +56 -0
- package/presets/claude/android-kotlin/commands/technical-retro.md +85 -0
- package/presets/claude/android-kotlin/hooks/README.md +16 -0
- package/presets/claude/android-kotlin/hooks/chain-team-phases.sh +705 -0
- package/presets/claude/android-kotlin/hooks/examples/README.md +18 -0
- package/presets/claude/android-kotlin/hooks/examples/format-edited.example.sh +13 -0
- package/presets/claude/android-kotlin/hooks/examples/secret-guard.example.sh +10 -0
- package/presets/claude/android-kotlin/hooks/examples/test-on-save.example.sh +8 -0
- package/presets/claude/android-kotlin/hooks/guard-shell-command.sh +80 -0
- package/presets/claude/android-kotlin/mcp.json +12 -0
- package/presets/claude/android-kotlin/rules/README.md +65 -0
- package/presets/claude/android-kotlin/rules/api-and-data/README.md +10 -0
- package/presets/claude/android-kotlin/rules/api-and-data/networking.md +30 -0
- package/presets/claude/android-kotlin/rules/api-and-data/persistence.md +29 -0
- package/presets/claude/android-kotlin/rules/architecture/README.md +9 -0
- package/presets/claude/android-kotlin/rules/architecture/boundaries.md +27 -0
- package/presets/claude/android-kotlin/rules/architecture/di-dagger-feature-holders.md +34 -0
- package/presets/claude/android-kotlin/rules/architecture/feature-delivery.md +45 -0
- package/presets/claude/android-kotlin/rules/architecture/module-public-api.md +29 -0
- package/presets/claude/android-kotlin/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/android-kotlin/rules/architecture/product-specs.md +62 -0
- package/presets/claude/android-kotlin/rules/architecture/reference-features.md +28 -0
- package/presets/claude/android-kotlin/rules/stack/README.md +6 -0
- package/presets/claude/android-kotlin/rules/stack/android-app-core.md +27 -0
- package/presets/claude/android-kotlin/rules/stack/kotlin-conventions.md +30 -0
- package/presets/claude/android-kotlin/rules/testing/README.md +10 -0
- package/presets/claude/android-kotlin/rules/testing/ui.md +28 -0
- package/presets/claude/android-kotlin/rules/testing/unit.md +29 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/README.md +19 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/agent-team-intake.md +18 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/agent-team-orchestrator.md +129 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/anti-sycophancy-discipline.md +29 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/code-quality.md +52 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/code-review.md +88 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/design-guidance.md +110 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/gradle-tooling.md +30 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/post-change-build.md +34 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/preset-layering.md +36 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/preset-no-cross-stack-leakage.md +100 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/preset-pr-checklist.md +39 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/preset-token-budget.md +41 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/preset-twin-sync.md +56 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/security-android.md +29 -0
- package/presets/claude/android-kotlin/rules/tooling-and-review/technical-retro.md +18 -0
- package/presets/claude/android-kotlin/rules/ui-and-accessibility/README.md +7 -0
- package/presets/claude/android-kotlin/rules/ui-and-accessibility/compose.md +31 -0
- package/presets/claude/android-kotlin/rules/ui-and-accessibility/navigation.md +30 -0
- package/presets/claude/android-kotlin/rules/ui-and-accessibility/viewmodels.md +27 -0
- package/presets/claude/android-kotlin/skills/README.md +14 -0
- package/presets/claude/android-kotlin/skills/ci-investigation/SKILL.md +39 -0
- package/presets/claude/android-kotlin/skills/code-review/SKILL.md +39 -0
- package/presets/claude/android-kotlin/skills/debug-investigation/SKILL.md +34 -0
- package/presets/claude/android-kotlin/skills/feature-delivery/SKILL.md +36 -0
- package/presets/claude/android-kotlin/skills/instrumentation-ui-e2e/SKILL.md +17 -0
- package/presets/claude/android-kotlin/skills/spec-authoring/SKILL.md +26 -0
- package/presets/claude/android-kotlin/skills/technical-retro/SKILL.md +54 -0
- package/presets/claude/android-kotlin/skills/unit-testing/SKILL.md +32 -0
- package/presets/claude/android-kotlin/skills/write-adr/SKILL.md +41 -0
- package/presets/claude/android-kotlin/team/README.md +54 -0
- package/presets/claude/android-kotlin/team/conventions.md +17 -0
- package/presets/claude/android-kotlin/team/fixtures/bugfix-standard.json +47 -0
- package/presets/claude/android-kotlin/team/fixtures/feature-full.json +97 -0
- package/presets/claude/android-kotlin/team/fixtures/feature-light.json +38 -0
- package/presets/claude/go/agents/build-verifier.md +3 -0
- package/presets/claude/go/agents/code-reviewer.md +2 -0
- package/presets/claude/go/agents/feature-developer.md +7 -0
- package/presets/claude/go/agents/task-analyst.md +19 -0
- package/presets/claude/go/agents/task-router.md +11 -0
- package/presets/claude/go/agents/tech-writer.md +5 -0
- package/presets/claude/go/commands/feature-continue.md +1 -0
- package/presets/claude/go/commands/feature-start.md +8 -0
- package/presets/claude/go/commands/spec-start.md +29 -0
- package/presets/claude/go/commands/task-continue.md +6 -3
- package/presets/claude/go/rules/README.md +2 -0
- package/presets/claude/go/rules/architecture/feature-delivery.md +4 -0
- package/presets/claude/go/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/go/rules/architecture/product-specs.md +63 -0
- package/presets/claude/go/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
- package/presets/claude/go/rules/tooling-and-review/preset-layering.md +1 -1
- package/presets/claude/go/rules/tooling-and-review/preset-no-cross-stack-leakage.md +25 -12
- package/presets/claude/go/rules/tooling-and-review/preset-pr-checklist.md +1 -1
- package/presets/claude/go/rules/tooling-and-review/preset-twin-sync.md +2 -0
- package/presets/claude/go/skills/feature-delivery/SKILL.md +5 -4
- package/presets/claude/go/skills/spec-authoring/SKILL.md +26 -0
- package/presets/claude/ios-swift/agents/build-verifier.md +3 -0
- package/presets/claude/ios-swift/agents/code-reviewer.md +2 -0
- package/presets/claude/ios-swift/agents/feature-developer.md +7 -0
- package/presets/claude/ios-swift/agents/task-analyst.md +19 -0
- package/presets/claude/ios-swift/agents/task-router.md +11 -0
- package/presets/claude/ios-swift/agents/tech-writer.md +2 -15
- package/presets/claude/ios-swift/commands/feature-continue.md +4 -0
- package/presets/claude/ios-swift/commands/feature-start.md +8 -0
- package/presets/claude/ios-swift/commands/spec-start.md +29 -0
- package/presets/claude/ios-swift/commands/task-continue.md +6 -3
- package/presets/claude/ios-swift/rules/README.md +3 -0
- package/presets/claude/ios-swift/rules/architecture/feature-delivery.md +4 -0
- package/presets/claude/ios-swift/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/ios-swift/rules/architecture/product-specs.md +62 -0
- package/presets/claude/ios-swift/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
- package/presets/claude/ios-swift/rules/tooling-and-review/preset-layering.md +1 -1
- package/presets/claude/ios-swift/rules/tooling-and-review/preset-no-cross-stack-leakage.md +25 -12
- package/presets/claude/ios-swift/rules/tooling-and-review/preset-pr-checklist.md +1 -1
- package/presets/claude/ios-swift/rules/tooling-and-review/preset-twin-sync.md +2 -0
- package/presets/claude/ios-swift/skills/feature-delivery/SKILL.md +5 -4
- package/presets/claude/ios-swift/skills/spec-authoring/SKILL.md +26 -0
- package/presets/claude/java/agents/build-verifier.md +3 -0
- package/presets/claude/java/agents/code-reviewer.md +2 -0
- package/presets/claude/java/agents/feature-developer.md +7 -0
- package/presets/claude/java/agents/task-analyst.md +19 -0
- package/presets/claude/java/agents/task-router.md +11 -0
- package/presets/claude/java/agents/tech-writer.md +5 -0
- package/presets/claude/java/commands/feature-continue.md +1 -0
- package/presets/claude/java/commands/feature-start.md +8 -0
- package/presets/claude/java/commands/spec-start.md +29 -0
- package/presets/claude/java/commands/task-continue.md +6 -3
- package/presets/claude/java/rules/README.md +2 -0
- package/presets/claude/java/rules/architecture/feature-delivery.md +4 -0
- package/presets/claude/java/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/java/rules/architecture/product-specs.md +63 -0
- package/presets/claude/java/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
- package/presets/claude/java/rules/tooling-and-review/preset-layering.md +1 -1
- package/presets/claude/java/rules/tooling-and-review/preset-no-cross-stack-leakage.md +25 -12
- package/presets/claude/java/rules/tooling-and-review/preset-pr-checklist.md +1 -1
- package/presets/claude/java/rules/tooling-and-review/preset-twin-sync.md +2 -0
- package/presets/claude/java/skills/feature-delivery/SKILL.md +5 -4
- package/presets/claude/java/skills/spec-authoring/SKILL.md +26 -0
- package/presets/claude/mcp-ts/agents/build-verifier.md +3 -0
- package/presets/claude/mcp-ts/agents/feature-developer.md +7 -0
- package/presets/claude/mcp-ts/agents/task-analyst.md +21 -0
- package/presets/claude/mcp-ts/agents/task-router.md +11 -0
- package/presets/claude/mcp-ts/commands/feature-continue.md +4 -0
- package/presets/claude/mcp-ts/commands/feature-start.md +8 -0
- package/presets/claude/mcp-ts/commands/spec-start.md +29 -0
- package/presets/claude/mcp-ts/commands/task-continue.md +6 -3
- package/presets/claude/mcp-ts/rules/README.md +2 -0
- package/presets/claude/mcp-ts/rules/architecture/feature-delivery.md +4 -0
- package/presets/claude/mcp-ts/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/mcp-ts/rules/architecture/product-specs.md +63 -0
- package/presets/claude/mcp-ts/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
- package/presets/claude/mcp-ts/rules/tooling-and-review/preset-layering.md +1 -1
- package/presets/claude/mcp-ts/rules/tooling-and-review/preset-no-cross-stack-leakage.md +25 -12
- package/presets/claude/mcp-ts/rules/tooling-and-review/preset-pr-checklist.md +1 -1
- package/presets/claude/mcp-ts/rules/tooling-and-review/preset-twin-sync.md +2 -0
- package/presets/claude/mcp-ts/skills/feature-delivery/SKILL.md +4 -3
- package/presets/claude/mcp-ts/skills/spec-authoring/SKILL.md +26 -0
- package/presets/claude/next/agents/build-verifier.md +3 -0
- package/presets/claude/next/agents/code-reviewer.md +1 -0
- package/presets/claude/next/agents/feature-developer.md +7 -0
- package/presets/claude/next/agents/task-analyst.md +19 -0
- package/presets/claude/next/agents/task-router.md +11 -0
- package/presets/claude/next/agents/tech-writer.md +5 -0
- package/presets/claude/next/commands/feature-continue.md +1 -0
- package/presets/claude/next/commands/feature-start.md +8 -0
- package/presets/claude/next/commands/spec-start.md +29 -0
- package/presets/claude/next/commands/task-continue.md +6 -3
- package/presets/claude/next/rules/README.md +3 -0
- package/presets/claude/next/rules/architecture/feature-delivery-workflow.md +4 -0
- package/presets/claude/next/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/next/rules/architecture/product-specs.md +63 -0
- package/presets/claude/next/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
- package/presets/claude/next/rules/tooling-and-review/preset-layering.md +1 -1
- package/presets/claude/next/rules/tooling-and-review/preset-no-cross-stack-leakage.md +25 -12
- package/presets/claude/next/rules/tooling-and-review/preset-pr-checklist.md +1 -1
- package/presets/claude/next/rules/tooling-and-review/preset-twin-sync.md +2 -0
- package/presets/claude/next/skills/feature-delivery/SKILL.md +4 -3
- package/presets/claude/next/skills/spec-authoring/SKILL.md +26 -0
- package/presets/claude/nuxt/agents/build-verifier.md +3 -0
- package/presets/claude/nuxt/agents/code-reviewer.md +2 -0
- package/presets/claude/nuxt/agents/feature-developer.md +7 -0
- package/presets/claude/nuxt/agents/task-analyst.md +19 -0
- package/presets/claude/nuxt/agents/task-router.md +11 -0
- package/presets/claude/nuxt/agents/tech-writer.md +5 -0
- package/presets/claude/nuxt/commands/feature-continue.md +4 -0
- package/presets/claude/nuxt/commands/feature-start.md +8 -0
- package/presets/claude/nuxt/commands/spec-start.md +29 -0
- package/presets/claude/nuxt/commands/task-continue.md +6 -3
- package/presets/claude/nuxt/rules/README.md +3 -0
- package/presets/claude/nuxt/rules/architecture/feature-delivery-workflow.md +4 -0
- package/presets/claude/nuxt/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/nuxt/rules/architecture/product-specs.md +62 -0
- package/presets/claude/nuxt/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
- package/presets/claude/nuxt/rules/tooling-and-review/preset-layering.md +1 -1
- package/presets/claude/nuxt/rules/tooling-and-review/preset-no-cross-stack-leakage.md +25 -12
- package/presets/claude/nuxt/rules/tooling-and-review/preset-pr-checklist.md +1 -1
- package/presets/claude/nuxt/rules/tooling-and-review/preset-twin-sync.md +2 -0
- package/presets/claude/nuxt/skills/feature-delivery/SKILL.md +4 -3
- package/presets/claude/nuxt/skills/spec-authoring/SKILL.md +26 -0
- package/presets/claude/php-hexagonal/agents/build-verifier.md +3 -0
- package/presets/claude/php-hexagonal/agents/code-reviewer.md +2 -0
- package/presets/claude/php-hexagonal/agents/feature-developer.md +7 -0
- package/presets/claude/php-hexagonal/agents/task-analyst.md +19 -0
- package/presets/claude/php-hexagonal/agents/task-router.md +11 -0
- package/presets/claude/php-hexagonal/agents/tech-writer.md +5 -0
- package/presets/claude/php-hexagonal/commands/feature-continue.md +1 -0
- package/presets/claude/php-hexagonal/commands/feature-start.md +8 -0
- package/presets/claude/php-hexagonal/commands/spec-start.md +29 -0
- package/presets/claude/php-hexagonal/commands/task-continue.md +6 -3
- package/presets/claude/php-hexagonal/rules/README.md +2 -0
- package/presets/claude/php-hexagonal/rules/architecture/feature-delivery.md +4 -0
- package/presets/claude/php-hexagonal/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/php-hexagonal/rules/architecture/product-specs.md +63 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-layering.md +1 -1
- package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-no-cross-stack-leakage.md +25 -12
- package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-pr-checklist.md +1 -1
- package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-twin-sync.md +2 -0
- package/presets/claude/php-hexagonal/skills/feature-delivery/SKILL.md +5 -4
- package/presets/claude/php-hexagonal/skills/spec-authoring/SKILL.md +26 -0
- package/presets/claude/php-laravel/agents/build-verifier.md +3 -0
- package/presets/claude/php-laravel/agents/code-reviewer.md +2 -0
- package/presets/claude/php-laravel/agents/feature-developer.md +7 -0
- package/presets/claude/php-laravel/agents/task-analyst.md +19 -0
- package/presets/claude/php-laravel/agents/task-router.md +11 -0
- package/presets/claude/php-laravel/agents/tech-writer.md +5 -0
- package/presets/claude/php-laravel/commands/feature-continue.md +1 -0
- package/presets/claude/php-laravel/commands/feature-start.md +8 -0
- package/presets/claude/php-laravel/commands/spec-start.md +29 -0
- package/presets/claude/php-laravel/commands/task-continue.md +6 -3
- package/presets/claude/php-laravel/rules/README.md +2 -0
- package/presets/claude/php-laravel/rules/architecture/feature-delivery.md +4 -0
- package/presets/claude/php-laravel/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/php-laravel/rules/architecture/product-specs.md +63 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/preset-layering.md +1 -1
- package/presets/claude/php-laravel/rules/tooling-and-review/preset-no-cross-stack-leakage.md +25 -12
- package/presets/claude/php-laravel/rules/tooling-and-review/preset-pr-checklist.md +1 -1
- package/presets/claude/php-laravel/rules/tooling-and-review/preset-twin-sync.md +2 -0
- package/presets/claude/php-laravel/skills/feature-delivery/SKILL.md +5 -4
- package/presets/claude/php-laravel/skills/spec-authoring/SKILL.md +26 -0
- package/presets/claude/svelte/agents/build-verifier.md +3 -0
- package/presets/claude/svelte/agents/code-reviewer.md +2 -0
- package/presets/claude/svelte/agents/feature-developer.md +7 -0
- package/presets/claude/svelte/agents/task-analyst.md +19 -0
- package/presets/claude/svelte/agents/task-router.md +11 -0
- package/presets/claude/svelte/agents/tech-writer.md +5 -0
- package/presets/claude/svelte/commands/feature-continue.md +4 -0
- package/presets/claude/svelte/commands/feature-start.md +8 -0
- package/presets/claude/svelte/commands/spec-start.md +29 -0
- package/presets/claude/svelte/commands/task-continue.md +6 -3
- package/presets/claude/svelte/rules/README.md +3 -0
- package/presets/claude/svelte/rules/architecture/feature-delivery-workflow.md +4 -0
- package/presets/claude/svelte/rules/architecture/product-specs-authoring.md +121 -0
- package/presets/claude/svelte/rules/architecture/product-specs.md +62 -0
- package/presets/claude/svelte/rules/tooling-and-review/agent-team-orchestrator.md +2 -0
- package/presets/claude/svelte/rules/tooling-and-review/preset-layering.md +1 -1
- package/presets/claude/svelte/rules/tooling-and-review/preset-no-cross-stack-leakage.md +25 -12
- package/presets/claude/svelte/rules/tooling-and-review/preset-pr-checklist.md +1 -1
- package/presets/claude/svelte/rules/tooling-and-review/preset-twin-sync.md +2 -0
- package/presets/claude/svelte/skills/feature-delivery/SKILL.md +4 -3
- package/presets/claude/svelte/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/android-kotlin/AGENTS.md +50 -0
- package/presets/cursor/android-kotlin/BUGBOT.md +16 -0
- package/presets/cursor/android-kotlin/MCP.md +16 -0
- package/presets/cursor/android-kotlin/README.md +35 -0
- package/presets/cursor/android-kotlin/REPO_AGENTS.md +48 -0
- package/presets/cursor/android-kotlin/agents/README.md +44 -0
- package/presets/cursor/android-kotlin/agents/accessibility-reviewer.md +60 -0
- package/presets/cursor/android-kotlin/agents/api-contract-reviewer.md +70 -0
- package/presets/cursor/android-kotlin/agents/build-verifier.md +70 -0
- package/presets/cursor/android-kotlin/agents/ci-investigator.md +74 -0
- package/presets/cursor/android-kotlin/agents/code-reviewer.md +76 -0
- package/presets/cursor/android-kotlin/agents/codebase-analyzer.md +28 -0
- package/presets/cursor/android-kotlin/agents/debugger.md +77 -0
- package/presets/cursor/android-kotlin/agents/feature-developer.md +70 -0
- package/presets/cursor/android-kotlin/agents/instrumentation-test-generator.md +19 -0
- package/presets/cursor/android-kotlin/agents/instrumentation-test-healer.md +19 -0
- package/presets/cursor/android-kotlin/agents/instrumentation-test-planner.md +19 -0
- package/presets/cursor/android-kotlin/agents/migration-specialist.md +74 -0
- package/presets/cursor/android-kotlin/agents/performance-auditor.md +67 -0
- package/presets/cursor/android-kotlin/agents/qa-tester.md +66 -0
- package/presets/cursor/android-kotlin/agents/security-reviewer.md +65 -0
- package/presets/cursor/android-kotlin/agents/solution-architect.md +21 -0
- package/presets/cursor/android-kotlin/agents/task-analyst.md +55 -0
- package/presets/cursor/android-kotlin/agents/task-router.md +114 -0
- package/presets/cursor/android-kotlin/agents/tech-writer.md +66 -0
- package/presets/cursor/android-kotlin/agents/unit-test-generator.md +55 -0
- package/presets/cursor/android-kotlin/agents/unit-test-healer.md +54 -0
- package/presets/cursor/android-kotlin/agents/unit-test-planner.md +65 -0
- package/presets/cursor/android-kotlin/commands/README.md +51 -0
- package/presets/cursor/android-kotlin/commands/feature-continue.md +23 -0
- package/presets/cursor/android-kotlin/commands/feature-start.md +41 -0
- package/presets/cursor/android-kotlin/commands/spec-start.md +29 -0
- package/presets/cursor/android-kotlin/commands/task-continue.md +53 -0
- package/presets/cursor/android-kotlin/commands/task.md +56 -0
- package/presets/cursor/android-kotlin/commands/technical-retro.md +85 -0
- package/presets/cursor/android-kotlin/hooks/README.md +12 -0
- package/presets/cursor/android-kotlin/hooks/chain-team-phases.sh +723 -0
- package/presets/cursor/android-kotlin/hooks/examples/README.md +18 -0
- package/presets/cursor/android-kotlin/hooks/examples/format-edited.example.sh +13 -0
- package/presets/cursor/android-kotlin/hooks/examples/secret-guard.example.sh +10 -0
- package/presets/cursor/android-kotlin/hooks/examples/test-on-save.example.sh +8 -0
- package/presets/cursor/android-kotlin/hooks/guard-shell-command.sh +80 -0
- package/presets/cursor/android-kotlin/hooks.json +17 -0
- package/presets/cursor/android-kotlin/mcp.json +11 -0
- package/presets/cursor/android-kotlin/rules/README.md +64 -0
- package/presets/cursor/android-kotlin/rules/agent-team-intake.mdc +16 -0
- package/presets/cursor/android-kotlin/rules/agent-team-orchestrator.mdc +126 -0
- package/presets/cursor/android-kotlin/rules/android-app-core.mdc +28 -0
- package/presets/cursor/android-kotlin/rules/anti-sycophancy-discipline.mdc +30 -0
- package/presets/cursor/android-kotlin/rules/architecture-boundaries.mdc +28 -0
- package/presets/cursor/android-kotlin/rules/code-quality-and-refactoring.mdc +53 -0
- package/presets/cursor/android-kotlin/rules/code-review-mr.mdc +84 -0
- package/presets/cursor/android-kotlin/rules/compose-ui.mdc +32 -0
- package/presets/cursor/android-kotlin/rules/design-guidance.mdc +111 -0
- package/presets/cursor/android-kotlin/rules/di-dagger-feature-holders.mdc +35 -0
- package/presets/cursor/android-kotlin/rules/feature-delivery-workflow.mdc +40 -0
- package/presets/cursor/android-kotlin/rules/gradle-tooling.mdc +31 -0
- package/presets/cursor/android-kotlin/rules/kotlin-conventions.mdc +31 -0
- package/presets/cursor/android-kotlin/rules/module-public-api.mdc +30 -0
- package/presets/cursor/android-kotlin/rules/navigation-feature-launcher.mdc +31 -0
- package/presets/cursor/android-kotlin/rules/networking-data.mdc +31 -0
- package/presets/cursor/android-kotlin/rules/persistence-data.mdc +30 -0
- package/presets/cursor/android-kotlin/rules/post-change-build.mdc +30 -0
- package/presets/cursor/android-kotlin/rules/preset-layering.mdc +36 -0
- package/presets/cursor/android-kotlin/rules/preset-no-cross-stack-leakage.mdc +100 -0
- package/presets/cursor/android-kotlin/rules/preset-pr-checklist.mdc +39 -0
- package/presets/cursor/android-kotlin/rules/preset-token-budget.mdc +41 -0
- package/presets/cursor/android-kotlin/rules/preset-twin-sync.mdc +56 -0
- package/presets/cursor/android-kotlin/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/android-kotlin/rules/product-specs.mdc +64 -0
- package/presets/cursor/android-kotlin/rules/reference-features.mdc +29 -0
- package/presets/cursor/android-kotlin/rules/security-android.mdc +30 -0
- package/presets/cursor/android-kotlin/rules/state-and-viewmodels.mdc +28 -0
- package/presets/cursor/android-kotlin/rules/technical-retro.mdc +16 -0
- package/presets/cursor/android-kotlin/rules/tests-ui.mdc +29 -0
- package/presets/cursor/android-kotlin/rules/tests-unit.mdc +30 -0
- package/presets/cursor/android-kotlin/skills/README.md +14 -0
- package/presets/cursor/android-kotlin/skills/ci-investigation/SKILL.md +39 -0
- package/presets/cursor/android-kotlin/skills/code-review/SKILL.md +39 -0
- package/presets/cursor/android-kotlin/skills/debug-investigation/SKILL.md +34 -0
- package/presets/cursor/android-kotlin/skills/feature-delivery/SKILL.md +36 -0
- package/presets/cursor/android-kotlin/skills/instrumentation-ui-e2e/SKILL.md +17 -0
- package/presets/cursor/android-kotlin/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/android-kotlin/skills/technical-retro/SKILL.md +54 -0
- package/presets/cursor/android-kotlin/skills/unit-testing/SKILL.md +32 -0
- package/presets/cursor/android-kotlin/skills/write-adr/SKILL.md +41 -0
- package/presets/cursor/android-kotlin/team/README.md +54 -0
- package/presets/cursor/android-kotlin/team/conventions.md +17 -0
- package/presets/cursor/android-kotlin/team/fixtures/bugfix-standard.json +47 -0
- package/presets/cursor/android-kotlin/team/fixtures/feature-full.json +97 -0
- package/presets/cursor/android-kotlin/team/fixtures/feature-light.json +38 -0
- package/presets/cursor/go/agents/build-verifier.md +3 -0
- package/presets/cursor/go/agents/code-reviewer.md +2 -0
- package/presets/cursor/go/agents/feature-developer.md +7 -0
- package/presets/cursor/go/agents/task-analyst.md +19 -0
- package/presets/cursor/go/agents/task-router.md +11 -0
- package/presets/cursor/go/agents/tech-writer.md +5 -0
- package/presets/cursor/go/commands/feature-continue.md +4 -0
- package/presets/cursor/go/commands/feature-start.md +8 -0
- package/presets/cursor/go/commands/spec-start.md +29 -0
- package/presets/cursor/go/commands/task-continue.md +6 -3
- package/presets/cursor/go/rules/README.md +4 -1
- package/presets/cursor/go/rules/agent-team-orchestrator.mdc +2 -0
- package/presets/cursor/go/rules/feature-delivery-workflow.mdc +4 -0
- package/presets/cursor/go/rules/preset-layering.mdc +1 -1
- package/presets/cursor/go/rules/preset-no-cross-stack-leakage.mdc +25 -12
- package/presets/cursor/go/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/go/rules/preset-twin-sync.mdc +2 -0
- package/presets/cursor/go/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/go/rules/product-specs.mdc +65 -0
- package/presets/cursor/go/skills/feature-delivery/SKILL.md +5 -4
- package/presets/cursor/go/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/ios-swift/agents/build-verifier.md +3 -0
- package/presets/cursor/ios-swift/agents/code-reviewer.md +2 -0
- package/presets/cursor/ios-swift/agents/feature-developer.md +7 -0
- package/presets/cursor/ios-swift/agents/task-analyst.md +19 -0
- package/presets/cursor/ios-swift/agents/task-router.md +11 -0
- package/presets/cursor/ios-swift/agents/tech-writer.md +2 -15
- package/presets/cursor/ios-swift/commands/feature-continue.md +4 -0
- package/presets/cursor/ios-swift/commands/feature-start.md +8 -0
- package/presets/cursor/ios-swift/commands/spec-start.md +29 -0
- package/presets/cursor/ios-swift/commands/task-continue.md +6 -3
- package/presets/cursor/ios-swift/rules/README.md +4 -1
- package/presets/cursor/ios-swift/rules/agent-team-orchestrator.mdc +2 -0
- package/presets/cursor/ios-swift/rules/feature-delivery-workflow.mdc +4 -0
- package/presets/cursor/ios-swift/rules/preset-layering.mdc +1 -1
- package/presets/cursor/ios-swift/rules/preset-no-cross-stack-leakage.mdc +25 -12
- package/presets/cursor/ios-swift/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/ios-swift/rules/preset-twin-sync.mdc +2 -0
- package/presets/cursor/ios-swift/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/ios-swift/rules/product-specs.mdc +64 -0
- package/presets/cursor/ios-swift/skills/feature-delivery/SKILL.md +5 -4
- package/presets/cursor/ios-swift/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/java/agents/build-verifier.md +3 -0
- package/presets/cursor/java/agents/code-reviewer.md +2 -0
- package/presets/cursor/java/agents/feature-developer.md +7 -0
- package/presets/cursor/java/agents/task-analyst.md +19 -0
- package/presets/cursor/java/agents/task-router.md +11 -0
- package/presets/cursor/java/agents/tech-writer.md +5 -0
- package/presets/cursor/java/commands/feature-continue.md +4 -0
- package/presets/cursor/java/commands/feature-start.md +8 -0
- package/presets/cursor/java/commands/spec-start.md +29 -0
- package/presets/cursor/java/commands/task-continue.md +6 -3
- package/presets/cursor/java/rules/README.md +4 -1
- package/presets/cursor/java/rules/agent-team-orchestrator.mdc +2 -0
- package/presets/cursor/java/rules/feature-delivery-workflow.mdc +4 -0
- package/presets/cursor/java/rules/preset-layering.mdc +1 -1
- package/presets/cursor/java/rules/preset-no-cross-stack-leakage.mdc +25 -12
- package/presets/cursor/java/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/java/rules/preset-twin-sync.mdc +2 -0
- package/presets/cursor/java/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/java/rules/product-specs.mdc +65 -0
- package/presets/cursor/java/skills/feature-delivery/SKILL.md +5 -4
- package/presets/cursor/java/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/mcp-ts/agents/build-verifier.md +3 -0
- package/presets/cursor/mcp-ts/agents/feature-developer.md +7 -0
- package/presets/cursor/mcp-ts/agents/task-analyst.md +21 -0
- package/presets/cursor/mcp-ts/agents/task-router.md +11 -0
- package/presets/cursor/mcp-ts/commands/feature-continue.md +4 -0
- package/presets/cursor/mcp-ts/commands/feature-start.md +8 -0
- package/presets/cursor/mcp-ts/commands/spec-start.md +29 -0
- package/presets/cursor/mcp-ts/commands/task-continue.md +6 -3
- package/presets/cursor/mcp-ts/rules/README.md +2 -0
- package/presets/cursor/mcp-ts/rules/agent-team-orchestrator.mdc +2 -0
- package/presets/cursor/mcp-ts/rules/feature-delivery-workflow.mdc +4 -0
- package/presets/cursor/mcp-ts/rules/preset-layering.mdc +1 -1
- package/presets/cursor/mcp-ts/rules/preset-no-cross-stack-leakage.mdc +25 -12
- package/presets/cursor/mcp-ts/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/mcp-ts/rules/preset-twin-sync.mdc +2 -0
- package/presets/cursor/mcp-ts/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/mcp-ts/rules/product-specs.mdc +65 -0
- package/presets/cursor/mcp-ts/skills/feature-delivery/SKILL.md +4 -3
- package/presets/cursor/mcp-ts/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/next/agents/build-verifier.md +3 -0
- package/presets/cursor/next/agents/code-reviewer.md +1 -0
- package/presets/cursor/next/agents/feature-developer.md +7 -0
- package/presets/cursor/next/agents/task-analyst.md +19 -0
- package/presets/cursor/next/agents/task-router.md +11 -0
- package/presets/cursor/next/agents/tech-writer.md +5 -0
- package/presets/cursor/next/commands/feature-continue.md +4 -0
- package/presets/cursor/next/commands/feature-start.md +8 -0
- package/presets/cursor/next/commands/spec-start.md +29 -0
- package/presets/cursor/next/commands/task-continue.md +6 -3
- package/presets/cursor/next/rules/README.md +3 -1
- package/presets/cursor/next/rules/agent-team-orchestrator.mdc +2 -0
- package/presets/cursor/next/rules/feature-delivery-workflow.mdc +4 -0
- package/presets/cursor/next/rules/preset-layering.mdc +1 -1
- package/presets/cursor/next/rules/preset-no-cross-stack-leakage.mdc +25 -12
- package/presets/cursor/next/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/next/rules/preset-twin-sync.mdc +2 -0
- package/presets/cursor/next/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/next/rules/product-specs.mdc +65 -0
- package/presets/cursor/next/skills/feature-delivery/SKILL.md +4 -3
- package/presets/cursor/next/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/nuxt/agents/build-verifier.md +3 -0
- package/presets/cursor/nuxt/agents/code-reviewer.md +2 -0
- package/presets/cursor/nuxt/agents/feature-developer.md +7 -0
- package/presets/cursor/nuxt/agents/task-analyst.md +19 -0
- package/presets/cursor/nuxt/agents/task-router.md +11 -0
- package/presets/cursor/nuxt/agents/tech-writer.md +5 -0
- package/presets/cursor/nuxt/commands/feature-continue.md +4 -0
- package/presets/cursor/nuxt/commands/feature-start.md +8 -0
- package/presets/cursor/nuxt/commands/spec-start.md +29 -0
- package/presets/cursor/nuxt/commands/task-continue.md +6 -3
- package/presets/cursor/nuxt/rules/README.md +3 -1
- package/presets/cursor/nuxt/rules/agent-team-orchestrator.mdc +2 -0
- package/presets/cursor/nuxt/rules/feature-delivery-workflow.mdc +4 -0
- package/presets/cursor/nuxt/rules/preset-layering.mdc +1 -1
- package/presets/cursor/nuxt/rules/preset-no-cross-stack-leakage.mdc +25 -12
- package/presets/cursor/nuxt/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/nuxt/rules/preset-twin-sync.mdc +2 -0
- package/presets/cursor/nuxt/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/nuxt/rules/product-specs.mdc +64 -0
- package/presets/cursor/nuxt/skills/feature-delivery/SKILL.md +4 -3
- package/presets/cursor/nuxt/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/php-hexagonal/agents/build-verifier.md +3 -0
- package/presets/cursor/php-hexagonal/agents/code-reviewer.md +2 -0
- package/presets/cursor/php-hexagonal/agents/feature-developer.md +7 -0
- package/presets/cursor/php-hexagonal/agents/task-analyst.md +19 -0
- package/presets/cursor/php-hexagonal/agents/task-router.md +11 -0
- package/presets/cursor/php-hexagonal/agents/tech-writer.md +5 -0
- package/presets/cursor/php-hexagonal/commands/feature-continue.md +4 -0
- package/presets/cursor/php-hexagonal/commands/feature-start.md +8 -0
- package/presets/cursor/php-hexagonal/commands/spec-start.md +29 -0
- package/presets/cursor/php-hexagonal/commands/task-continue.md +6 -3
- package/presets/cursor/php-hexagonal/rules/README.md +4 -1
- package/presets/cursor/php-hexagonal/rules/agent-team-orchestrator.mdc +2 -0
- package/presets/cursor/php-hexagonal/rules/feature-delivery-workflow.mdc +4 -0
- package/presets/cursor/php-hexagonal/rules/preset-layering.mdc +1 -1
- package/presets/cursor/php-hexagonal/rules/preset-no-cross-stack-leakage.mdc +25 -12
- package/presets/cursor/php-hexagonal/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/php-hexagonal/rules/preset-twin-sync.mdc +2 -0
- package/presets/cursor/php-hexagonal/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/php-hexagonal/rules/product-specs.mdc +65 -0
- package/presets/cursor/php-hexagonal/skills/feature-delivery/SKILL.md +5 -4
- package/presets/cursor/php-hexagonal/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/php-laravel/agents/build-verifier.md +3 -0
- package/presets/cursor/php-laravel/agents/code-reviewer.md +2 -0
- package/presets/cursor/php-laravel/agents/feature-developer.md +7 -0
- package/presets/cursor/php-laravel/agents/task-analyst.md +19 -0
- package/presets/cursor/php-laravel/agents/task-router.md +11 -0
- package/presets/cursor/php-laravel/agents/tech-writer.md +5 -0
- package/presets/cursor/php-laravel/commands/feature-continue.md +4 -0
- package/presets/cursor/php-laravel/commands/feature-start.md +8 -0
- package/presets/cursor/php-laravel/commands/spec-start.md +29 -0
- package/presets/cursor/php-laravel/commands/task-continue.md +6 -3
- package/presets/cursor/php-laravel/rules/README.md +4 -1
- package/presets/cursor/php-laravel/rules/agent-team-orchestrator.mdc +2 -0
- package/presets/cursor/php-laravel/rules/feature-delivery-workflow.mdc +4 -0
- package/presets/cursor/php-laravel/rules/preset-layering.mdc +1 -1
- package/presets/cursor/php-laravel/rules/preset-no-cross-stack-leakage.mdc +25 -12
- package/presets/cursor/php-laravel/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/php-laravel/rules/preset-twin-sync.mdc +2 -0
- package/presets/cursor/php-laravel/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/php-laravel/rules/product-specs.mdc +65 -0
- package/presets/cursor/php-laravel/skills/feature-delivery/SKILL.md +5 -4
- package/presets/cursor/php-laravel/skills/spec-authoring/SKILL.md +26 -0
- package/presets/cursor/svelte/agents/build-verifier.md +3 -0
- package/presets/cursor/svelte/agents/code-reviewer.md +2 -0
- package/presets/cursor/svelte/agents/feature-developer.md +7 -0
- package/presets/cursor/svelte/agents/task-analyst.md +19 -0
- package/presets/cursor/svelte/agents/task-router.md +11 -0
- package/presets/cursor/svelte/agents/tech-writer.md +5 -0
- package/presets/cursor/svelte/commands/feature-continue.md +4 -0
- package/presets/cursor/svelte/commands/feature-start.md +8 -0
- package/presets/cursor/svelte/commands/spec-start.md +29 -0
- package/presets/cursor/svelte/commands/task-continue.md +6 -3
- package/presets/cursor/svelte/rules/README.md +3 -1
- package/presets/cursor/svelte/rules/agent-team-orchestrator.mdc +2 -0
- package/presets/cursor/svelte/rules/feature-delivery-workflow.mdc +4 -0
- package/presets/cursor/svelte/rules/preset-layering.mdc +1 -1
- package/presets/cursor/svelte/rules/preset-no-cross-stack-leakage.mdc +25 -12
- package/presets/cursor/svelte/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/svelte/rules/preset-twin-sync.mdc +2 -0
- package/presets/cursor/svelte/rules/product-specs-authoring.mdc +123 -0
- package/presets/cursor/svelte/rules/product-specs.mdc +64 -0
- package/presets/cursor/svelte/skills/feature-delivery/SKILL.md +4 -3
- package/presets/cursor/svelte/skills/spec-authoring/SKILL.md +26 -0
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Author/generate product specs (docs/specs) — modes, INDEX/frontmatter, checklist
|
|
3
|
+
globs:
|
|
4
|
+
- docs/specs/**/*
|
|
5
|
+
alwaysApply: false
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
<!-- shared-core: architecture/product-specs-authoring.md -->
|
|
9
|
+
|
|
10
|
+
# Product specs authoring
|
|
11
|
+
|
|
12
|
+
Load when **Generate** or **Bootstrap** is requested (`/spec-start`, router `spec-gen`, brief AC, or analyst author mode). Discovery-only work stays on **`product-specs`**.
|
|
13
|
+
|
|
14
|
+
## Modes
|
|
15
|
+
|
|
16
|
+
1. **Consume** — default; never invent INDEX/specs (see `product-specs`).
|
|
17
|
+
2. **Generate** — create/update page/feature specs + INDEX rows from brief AC, user intent, Figma, or code archaeology. Inventing *product* behavior is forbidden without a stated source (AC / user / UI copy / code-observed behavior labeled `status: draft` or `inferred`).
|
|
18
|
+
3. **Bootstrap** — create `INDEX.md` + `_templates/` copies + first domain spec under greenfield policy.
|
|
19
|
+
|
|
20
|
+
## Greenfield policy
|
|
21
|
+
|
|
22
|
+
Agents **may** create INDEX + first specs **only when** one of:
|
|
23
|
+
|
|
24
|
+
1. User runs `/spec-start` or explicitly asks to bootstrap `docs/specs`.
|
|
25
|
+
2. Brief/AC includes generation or bootstrap language.
|
|
26
|
+
3. Router detects `spec-gen` intent.
|
|
27
|
+
|
|
28
|
+
Otherwise: missing INDEX → optional tree; do **not** invent INDEX merely because discovery loaded.
|
|
29
|
+
|
|
30
|
+
## Conflict precedence
|
|
31
|
+
|
|
32
|
+
1. **Human gate** decision (approved brief/spec edits).
|
|
33
|
+
2. **Current task `brief.md` AC** — if AC contradicts an existing spec, analyst must reconcile (update spec as `draft` or revise AC) before developer; no silent contradiction.
|
|
34
|
+
3. **Approved `docs/specs/**`** — behavior SoT for feature-developer once gate passed.
|
|
35
|
+
4. **Code / `.ai/context`** — discovery evidence only; never override approved spec without gate.
|
|
36
|
+
|
|
37
|
+
Label inferred-from-code lines with `status: draft` until human promotes.
|
|
38
|
+
|
|
39
|
+
## INDEX.md contract (v1)
|
|
40
|
+
|
|
41
|
+
| Column | Required | Notes |
|
|
42
|
+
|--------|----------|-------|
|
|
43
|
+
| `id` | yes | Stable kebab/id matching frontmatter `id` |
|
|
44
|
+
| `type` | yes | `page` \| `feature` |
|
|
45
|
+
| `domain` | yes | Domain folder under `docs/specs/domains/<domain>/` |
|
|
46
|
+
| `title` | yes | Human label |
|
|
47
|
+
| `path` | yes | Repo-relative path to markdown file |
|
|
48
|
+
| `routes` | no | Summary; may duplicate frontmatter |
|
|
49
|
+
| `aliases` | no | Comma-separated PageName / deep-link aliases |
|
|
50
|
+
| `status` | no | `draft` \| `active` \| `deprecated` |
|
|
51
|
+
|
|
52
|
+
Layout: `docs/specs/domains/<domain>/<id>.md` (page) and optional `docs/specs/domains/<domain>/feature.md`. Adding/renaming/removing a linked file **must** update INDEX in the **same change set**.
|
|
53
|
+
|
|
54
|
+
## Frontmatter v1
|
|
55
|
+
|
|
56
|
+
| Field | Type | Required | Notes |
|
|
57
|
+
|-------|------|----------|-------|
|
|
58
|
+
| `id` | string | yes | Unique; matches INDEX |
|
|
59
|
+
| `type` | enum `page` \| `feature` | yes | Backend/MCP: prefer `feature` |
|
|
60
|
+
| `domain` | string | yes | |
|
|
61
|
+
| `routes` | string[] | yes (may be `[]`) | Web: URL paths; mobile: deep links/screens; backend: HTTP paths; mcp-ts: tool names |
|
|
62
|
+
| `ui` | string[] | yes (may be `[]`) | Component/screen refs; empty on backend/mcp |
|
|
63
|
+
| `store` | string[] | yes (may be `[]`) | Slice/module refs; empty when N/A |
|
|
64
|
+
| `api` | string[] | yes (may be `[]`) | Services/ports/tools |
|
|
65
|
+
| `aliases` | string[] | yes (may be `[]`) | |
|
|
66
|
+
| `e2e` | string[] | yes (may be `[]`) | Stack-appropriate test paths |
|
|
67
|
+
| `status` | enum | no | default `draft` on agent generate |
|
|
68
|
+
| `owners` | string[] | no | |
|
|
69
|
+
| `related` | string[] | no | Spec ids or paths |
|
|
70
|
+
|
|
71
|
+
Arrays are **always present** (empty allowed). Do not omit keys for N/A stacks.
|
|
72
|
+
|
|
73
|
+
## Body headings (minimum)
|
|
74
|
+
|
|
75
|
+
**`page` required:** Overview; Entry / actors; Primary flows; States (loading / empty / error / success as applicable — mark N/A explicitly); Acceptance criteria (links or bullets to brief AC / product source).
|
|
76
|
+
|
|
77
|
+
**`page` optional:** Analytics, Accessibility, Edge cases, Related specs.
|
|
78
|
+
|
|
79
|
+
**`feature` required:** Overview; Shared behavior / constraints; Related pages (links).
|
|
80
|
+
|
|
81
|
+
**`feature` optional:** Cross-cutting states, Analytics.
|
|
82
|
+
|
|
83
|
+
Compliant = valid frontmatter + all required headings present (non-empty prose or explicit `N/A`) + INDEX row with resolvable `path`.
|
|
84
|
+
|
|
85
|
+
## Templates & assets
|
|
86
|
+
|
|
87
|
+
**Package SoT:** `packages/ai-rules/presets/_shared/assets/docs-specs/` (`INDEX.md` stub, `_templates/page.md`, `_templates/feature.md`; optional `schemas/frontmatter-v1.schema.json`).
|
|
88
|
+
|
|
89
|
+
**CLI `init`:** when consumer `docs/specs/` is **absent**, copy INDEX stub + `_templates/*` (idempotent; **never overwrite** existing INDEX). When the tree already exists, skip seed entirely.
|
|
90
|
+
|
|
91
|
+
**Skill fallback:** if consumer `_templates/` missing during author mode, copy from package/skill assets before authoring.
|
|
92
|
+
|
|
93
|
+
## Author roles
|
|
94
|
+
|
|
95
|
+
| Role | Responsibility |
|
|
96
|
+
|------|----------------|
|
|
97
|
+
| **task-analyst** | Primary author (Generate + Bootstrap); INDEX bootstrap; brief **Related specs** + **Spec gaps / generation requested**; loads this stem + skill `spec-authoring` |
|
|
98
|
+
| **tech-writer** | Post-delivery sync where present; never invent product behavior without AC/code source |
|
|
99
|
+
| **feature-developer** | Consumes approved specs as SoT; mechanical INDEX/frontmatter fixes only on renames |
|
|
100
|
+
| **mcp-ts** | No tech-writer — author + post-sync via **task-analyst** only |
|
|
101
|
+
|
|
102
|
+
## Self-check before handoff (soft block)
|
|
103
|
+
|
|
104
|
+
Block handoff via `open_questions` until fixed:
|
|
105
|
+
|
|
106
|
+
- [ ] Required frontmatter keys present; arrays always present (may be `[]`)
|
|
107
|
+
- [ ] Required body headings present (or explicit `N/A`)
|
|
108
|
+
- [ ] INDEX row added/updated with resolvable `path` in the **same change set**
|
|
109
|
+
- [ ] Sources cited; invented product behavior absent (or labeled `draft` / `inferred`)
|
|
110
|
+
- [ ] Conflict with brief AC reconciled or flagged
|
|
111
|
+
|
|
112
|
+
## Related
|
|
113
|
+
|
|
114
|
+
- `product-specs` — discovery / consume
|
|
115
|
+
- Skill `spec-authoring` — procedural checklist
|
|
116
|
+
- Optional consumer script `scripts/check-product-specs.sh` (WARN default; `--strict` FAIL)
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
## Stack notes
|
|
120
|
+
|
|
121
|
+
- Author via skill `spec-authoring`; prefer `type: feature`; `ui`/`store` usually `[]`.
|
|
122
|
+
- **Forbidden:** web UI / Playwright path recipes.
|
|
123
|
+
- Requestable — not always-on / session-start.
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Product page/feature specs under docs/specs — INDEX discovery for agents
|
|
3
|
+
globs:
|
|
4
|
+
- docs/specs/**/*
|
|
5
|
+
alwaysApply: false
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
<!-- shared-core: architecture/product-specs.md -->
|
|
9
|
+
|
|
10
|
+
# Product specs (docs/specs)
|
|
11
|
+
|
|
12
|
+
Product page/feature **behavior** specs live under the consumer repo `docs/specs/**`. This stem covers **discovery and presence** — not layer implementation order (see `feature-delivery-workflow`) and not code-structure mirroring (see `reference-features`).
|
|
13
|
+
|
|
14
|
+
**Authoring** (Generate / Bootstrap modes, INDEX/frontmatter v1, body checklist, greenfield, conflict precedence) → load **`product-specs-authoring`** when generation is requested (`/spec-start`, brief AC, or router `spec-gen`).
|
|
15
|
+
|
|
16
|
+
## Modes (summary)
|
|
17
|
+
|
|
18
|
+
| Mode | When | Behavior |
|
|
19
|
+
|------|------|----------|
|
|
20
|
+
| **Consume** (default) | INDEX exists or globs hit `docs/specs/**` without generate intent | Discover via INDEX; soft-fail on miss; **never invent** INDEX/specs |
|
|
21
|
+
| **Generate** | Explicit generate intent / AC / `/spec-start` with existing tree | Create/update page/feature specs + INDEX from stated sources |
|
|
22
|
+
| **Bootstrap** | Explicit bootstrap / `/spec-start` when tree absent | Create INDEX + templates + first domain spec |
|
|
23
|
+
|
|
24
|
+
Greenfield: agents may create INDEX/specs **only** on explicit intent, AC, or `/spec-start`. Missing INDEX alone does **not** authorize inventing the tree.
|
|
25
|
+
|
|
26
|
+
## Presence policy
|
|
27
|
+
|
|
28
|
+
- If `docs/specs/INDEX.md` is **missing** → the tree is **optional** (greenfield OK for *consume*). Continue with code/brief discovery; do not invent an INDEX solely because this stem loaded.
|
|
29
|
+
- If INDEX **exists** → it is the **required discovery path** for work that touches a listed page, feature, route, or alias.
|
|
30
|
+
|
|
31
|
+
## Discovery algorithm
|
|
32
|
+
|
|
33
|
+
1. Always start at `docs/specs/INDEX.md` when present.
|
|
34
|
+
2. Resolve the entry by: route, stable `id`, PageName / alias, or domain folder.
|
|
35
|
+
3. Read the linked page spec (and optional domain `feature.md` when the INDEX or page Related links it).
|
|
36
|
+
|
|
37
|
+
## Miss policy (INDEX present, row or file missing)
|
|
38
|
+
|
|
39
|
+
- Record the gap in `open_questions` / handoff gaps.
|
|
40
|
+
- Fall back to code discovery and consumer `.ai/context/**` when present.
|
|
41
|
+
- **Do not invent** product behavior, states, interactions, or contracts.
|
|
42
|
+
- Hard-fail / block only when the task’s acceptance criteria explicitly require a named spec that is absent (human/gate decision).
|
|
43
|
+
|
|
44
|
+
## Authoring pointer
|
|
45
|
+
|
|
46
|
+
Same-changeset INDEX updates, frontmatter v1, required body headings, templates, and conflict precedence live in **`product-specs-authoring`**. Do not paste the full checklist here.
|
|
47
|
+
|
|
48
|
+
## Non-goals
|
|
49
|
+
|
|
50
|
+
- Not a replacement for `.ai/context/**` (external AI Code Review glossary) or `reference-features` (file-layout mirror).
|
|
51
|
+
- Not Tessl / an external host as primary SoT.
|
|
52
|
+
- No stack filesystem path recipes in this core body — path examples belong only in adapter **Stack notes**.
|
|
53
|
+
|
|
54
|
+
## Related
|
|
55
|
+
|
|
56
|
+
- `product-specs-authoring` — generation modes, contracts, self-check.
|
|
57
|
+
- `reference-features` — code structure mirror (how to layout files), not product behavior.
|
|
58
|
+
- Consumer `.ai/context/**` when present — review/domain glossary; cross-link, do not replace.
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
## Stack notes
|
|
62
|
+
|
|
63
|
+
- `routes`: HTTP paths. `ui` / `store`: usually `[]` (or handler/port labels). `e2e`: integration/contract test paths.
|
|
64
|
+
- **Forbidden:** requiring `app/src/ui`, Playwright paths, or Next lint recipes.
|
|
65
|
+
- Requestable / `docs/specs/**` globs — not always-on / session-start.
|
|
@@ -6,10 +6,11 @@ description: Delivers PHP hexagonal backend features end-to-end across domain, a
|
|
|
6
6
|
# Feature Delivery (PHP hexagonal)
|
|
7
7
|
|
|
8
8
|
1. Read brief, AC, and decomposition.
|
|
9
|
-
2.
|
|
10
|
-
3.
|
|
11
|
-
4.
|
|
12
|
-
5.
|
|
9
|
+
2. If `docs/specs/INDEX.md` exists **or** brief/handoff lists approved generated specs, resolve via **`product-specs`** and treat approved specs as behavior SoT before layer work (soft-fail on miss — do not invent behavior). If generation was requested but not yet approved, stop for human gate — do not implement against draft-only gaps.
|
|
10
|
+
3. Follow `feature-delivery-workflow.mdc` + `reference-features.mdc`: domain → application/ports → driven adapters → driving adapters → composition root → tests.
|
|
11
|
+
4. Wire DI only in `Composition/` / `Composition/*`.
|
|
12
|
+
5. Add unit tests for domain/use cases; integration tests for risky adapters.
|
|
13
|
+
6. After PHP edits: **invoke** `post-change-test.mdc` (+ `php-tooling.mdc`).
|
|
13
14
|
|
|
14
15
|
## Do / Don't
|
|
15
16
|
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: spec-authoring
|
|
3
|
+
description: Author or bootstrap consumer docs/specs (INDEX, page/feature templates, frontmatter v1). Use with task-analyst author mode, /spec-start, or when brief AC requests Generate/Bootstrap.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Spec authoring
|
|
7
|
+
|
|
8
|
+
Requestable — not always-on. Load **`product-specs`** + **`product-specs-authoring`** first.
|
|
9
|
+
|
|
10
|
+
## Steps
|
|
11
|
+
|
|
12
|
+
1. **Resolve mode** — Generate (tree exists) vs Bootstrap (create INDEX + templates + first spec). Refuse inventing INDEX without explicit intent/AC/`/spec-start`.
|
|
13
|
+
2. **Ensure templates** — if consumer `docs/specs/_templates/` missing, copy from package SoT `presets/_shared/assets/docs-specs/_templates/` (or seeded init assets).
|
|
14
|
+
3. **Fill frontmatter v1** — all array keys present (may be `[]`); prefer `type: feature` on backend/MCP; default `status: draft`.
|
|
15
|
+
4. **Fill required body headings** — page: Overview, Entry/actors, Primary flows, States, Acceptance criteria; feature: Overview, Shared behavior/constraints, Related pages. Use `N/A` explicitly when needed.
|
|
16
|
+
5. **Update INDEX** in the **same change set** (columns: id, type, domain, title, path, optional routes/aliases/status).
|
|
17
|
+
6. **Self-check** against `product-specs-authoring` checklist; put blockers in `open_questions`.
|
|
18
|
+
7. **Handoff** — list created/updated paths + INDEX diff for human gate (`after:task-analyst`). Approve before feature-developer.
|
|
19
|
+
|
|
20
|
+
## Sources
|
|
21
|
+
|
|
22
|
+
Cite AC / user / Figma / labeled code inference. Do not invent product behavior.
|
|
23
|
+
|
|
24
|
+
## mcp-ts
|
|
25
|
+
|
|
26
|
+
Analyst-only path (no tech-writer). `routes` = tool names; `ui`/`store` = `[]`.
|
|
@@ -50,3 +50,6 @@ Document PASS/FAIL in `validation-report.md`.
|
|
|
50
50
|
- **Owned outputs:** `validation-report.md`; upsert only the manifest entry assigned by handoff (`artifactOutputId`; fallback `validation`) and preserve all foreign entries.
|
|
51
51
|
- **Terminal receipt:** cover applicable AC/task IDs, list authoritative evidence paths, and emit `completed` or `validation_failed`. Bind it to the supplied `attemptId` when present.
|
|
52
52
|
- **Shared state:** never create or mutate `status.json` or `metrics.json`; the orchestration runtime/hook owns lifecycle, gates, retries, attempts, and timestamps.
|
|
53
|
+
|
|
54
|
+
13. **Product-specs assets (FAIL):** package must ship `presets/_shared/assets/docs-specs/INDEX.md`, `_templates/page.md`, `_templates/feature.md`. Cursor+Claude twins for `product-specs` and `product-specs-authoring` must embed matching shared-core markers; both stems **requestable** (`alwaysApply: false` / Claude `paths: docs/specs/**`) — never session-start.
|
|
55
|
+
14. **Optional consumer check (WARN default):** `scripts/check-product-specs.sh` + schema stub may exist for opt-in consumer CI; **FAIL** only with `--strict` or AC that requires named specs — do not force consumer CI.
|
|
@@ -18,6 +18,8 @@ Apply skill `code-review` and `code-review-mr.mdc`. Weigh `architecture-boundari
|
|
|
18
18
|
|
|
19
19
|
## Review focus (Laravel)
|
|
20
20
|
|
|
21
|
+
- If the MR touches `docs/specs/**`, load **`product-specs`** (+ **`product-specs-authoring`** when new/changed specs): **WARN** code/spec drift; **FAIL** broken INDEX `path` link or missing required frontmatter keys/arrays on touched spec files; required body headings missing → **FAIL** on touched files. Do not invent missing product behavior.
|
|
22
|
+
|
|
21
23
|
- **Layers:** thin Controllers; validation in Form Requests; AuthZ in Policies; orchestration in Actions/Services — not fat controllers or model AuthZ.
|
|
22
24
|
- **DI:** Service Providers bind interfaces/singletons only — no business rules in `app/Providers/**`.
|
|
23
25
|
- **Errors / HTTP:** map domain failures at the HTTP edge; no swallowed exceptions; consistent API Resources / error envelopes.
|
|
@@ -46,6 +46,13 @@ Update `.cursor/team/tasks/<slug>/implementation.md` and the owned implementatio
|
|
|
46
46
|
|
|
47
47
|
- When writing or changing code, load / follow rule `anti-sycophancy-discipline`.
|
|
48
48
|
|
|
49
|
+
## Product specs (docs/specs)
|
|
50
|
+
|
|
51
|
+
When work touches a page/feature/route/alias: if `docs/specs/INDEX.md` exists (or brief lists approved specs), load **`product-specs`** and treat **approved** specs from brief/handoff as **behavior SoT**. Soft-fail on miss (`open_questions` + code / `.ai/context` fallback); **never invent** product behavior.
|
|
52
|
+
|
|
53
|
+
Mechanical INDEX/frontmatter fixes only when implementation renames routes/ids. Substantive behavior edits → hand back to task-analyst (or tech-writer where present). If INDEX is absent and generation was not approved, treat specs as optional (greenfield).
|
|
54
|
+
|
|
55
|
+
|
|
49
56
|
## Artifact contract
|
|
50
57
|
|
|
51
58
|
- **Authoritative inputs:** read `.cursor/team/tasks/<slug>/artifact-manifest.json` first; consume handoff `artifactInputIds` when supplied, otherwise consume the manifest entries for `brief.md`, `decomposition.md`, current scope, and applicable prior findings.
|
|
@@ -24,6 +24,25 @@ Emit an analysis receipt; the runtime applies any configured human gate.
|
|
|
24
24
|
|
|
25
25
|
- Optional: Load `design-guidance` (rule stem) when assessing structure, smells, or pattern fit — only when decomposing refactor/architecture tasks (not default).
|
|
26
26
|
|
|
27
|
+
## Product specs (docs/specs)
|
|
28
|
+
|
|
29
|
+
**Consume (default):** When work touches a page/feature/route/alias and `docs/specs/INDEX.md` exists, load **`product-specs`**, resolve the linked page/feature spec, and cite it under **Related specs** in `brief.md`. Soft-fail on miss (`open_questions` + code / `.ai/context` fallback); **never invent** product behavior. If INDEX is absent, treat specs as optional unless author mode applies.
|
|
30
|
+
|
|
31
|
+
**Author mode (Generate / Bootstrap):** When the user runs `/spec-start`, router intent is `spec-gen` / bootstrap, or brief/AC requests generation: load **`product-specs`** + **`product-specs-authoring`** and skill **`spec-authoring`**. You are the **primary author** (INDEX bootstrap included). Follow frontmatter v1 + required headings; update INDEX in the **same change set**; default `status: draft`. Block handoff via `open_questions` until the authoring self-check passes.
|
|
32
|
+
|
|
33
|
+
### Brief sections (when author mode or INDEX exists)
|
|
34
|
+
|
|
35
|
+
Add to `brief.md`:
|
|
36
|
+
|
|
37
|
+
```markdown
|
|
38
|
+
## Related specs
|
|
39
|
+
- path or id (or N/A)
|
|
40
|
+
|
|
41
|
+
## Spec gaps / generation requested
|
|
42
|
+
- [ ] none | generate | bootstrap — sources: …
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
|
|
27
46
|
## Artifact contract
|
|
28
47
|
|
|
29
48
|
- **Authoritative inputs:** read `.cursor/team/tasks/<slug>/artifact-manifest.json` first; consume `pipeline.json`, the manifest routing entry, user-approved decisions, and any authoritative architecture/approval entries.
|
|
@@ -108,6 +108,17 @@ Write `.cursor/team/tasks/<slug>/pipeline.json` and initialize the routing entry
|
|
|
108
108
|
|
|
109
109
|
Intent + steps table + skipped + gates → invoke `steps[0].agent` (unless retro).
|
|
110
110
|
|
|
111
|
+
## Spec generation intents
|
|
112
|
+
|
|
113
|
+
Detect and set routing reasons when the user asks to **generate / bootstrap product specs**, mentions `docs/specs`, or runs `/spec-start`:
|
|
114
|
+
|
|
115
|
+
| Signal | Intent | Steps |
|
|
116
|
+
|--------|--------|-------|
|
|
117
|
+
| `/spec-start`, "bootstrap docs/specs", "generate product spec" | `spec-gen` | task-analyst (**author mode**) → human gate → stop (or continue to feature-developer only if implement-after) |
|
|
118
|
+
| Feature/task with AC "generate specs" / missing INDEX + bootstrap AC | `spec-gen` inside feature profile | task-analyst author mode first; **not** a separate agent step |
|
|
119
|
+
|
|
120
|
+
Do **not** add a dedicated `spec-author` agent. Do not require solution-architect for routine spec authoring.
|
|
121
|
+
|
|
111
122
|
## Runtime initialization
|
|
112
123
|
|
|
113
124
|
Return the routing receipt to the orchestrator. The orchestration runtime/hook exclusively initializes and updates `status.json`, `metrics.json`, attempt identities, and gate lifecycle; the router does not write those shared runtime files.
|
|
@@ -13,3 +13,8 @@ Write documentation from task artifacts (brief, architecture, implementation, re
|
|
|
13
13
|
- For ai-rules preset tasks: update PRESET-CONTRIBUTION / package README as scoped — docs only.
|
|
14
14
|
|
|
15
15
|
Do not change production `.php` business logic.
|
|
16
|
+
|
|
17
|
+
## Product specs (docs/specs)
|
|
18
|
+
|
|
19
|
+
Post-delivery: when behavior or public docs changed and `docs/specs/` is in play, load **`product-specs`** (+ **`product-specs-authoring`** if updating specs). Sync page/feature specs + INDEX in the **same change set**. **Never invent** product behavior without AC/code source; label inferred lines `status: draft`. Soft-fail on miss; no-op if INDEX absent and sync not requested.
|
|
20
|
+
|
|
@@ -17,3 +17,7 @@ Continue after a human gate. Full logic lives in **`task-continue.md`**.
|
|
|
17
17
|
4. The hook continues the chain when `autoChain: true`.
|
|
18
18
|
|
|
19
19
|
See `task-continue.md` for details and the handoff table.
|
|
20
|
+
|
|
21
|
+
## Product specs (docs/specs)
|
|
22
|
+
|
|
23
|
+
When the next agent is **feature-developer** (or other implementer): if `docs/specs/INDEX.md` exists, instruct them to load **`product-specs`** and honor **Related specs** from `brief.md` (behavior SoT). Soft-fail on miss; never invent product behavior. No-op if INDEX is absent.
|
|
@@ -19,11 +19,19 @@ Starts the **analysis phase** without the router. The parent agent acts as orche
|
|
|
19
19
|
6. Invoke subagent **task-analyst** (Task tool) with the full task description and artifact paths.
|
|
20
20
|
7. Wait for the analyst to finish. **Do not invoke developer** at this stage.
|
|
21
21
|
|
|
22
|
+
## Product specs (docs/specs)
|
|
23
|
+
|
|
24
|
+
When invoking **task-analyst**: if `docs/specs/INDEX.md` exists, instruct consume via **`product-specs`** and cite **Related specs**. Soft-fail on miss; never invent behavior.
|
|
25
|
+
|
|
26
|
+
If the user/AC requests generation or bootstrap, or INDEX is missing **with** bootstrap AC / `/spec-start` intent: instruct **author mode** inside the same analyst step — load **`product-specs-authoring`** + skill **`spec-authoring`**. Authoring is **not** a separate pipeline agent. Handoff must list created paths + INDEX diff; human gate must approve generated specs before feature-developer.
|
|
27
|
+
|
|
28
|
+
|
|
22
29
|
## Human gate
|
|
23
30
|
|
|
24
31
|
After the analyst:
|
|
25
32
|
|
|
26
33
|
- Show the user links to `brief.md` and `decomposition.md`.
|
|
34
|
+
- Also ask them to check **Related specs** in `brief.md` when `docs/specs/INDEX.md` exists.
|
|
27
35
|
- Ask them to review and approve or send edits.
|
|
28
36
|
- To continue: `/task-continue <slug>` or `/feature-continue <slug>`.
|
|
29
37
|
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: spec-start
|
|
3
|
+
description: Bootstrap or generate docs/specs (INDEX + page/feature) via task-analyst author mode. Optional docs-only path with human gate.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Spec start — generate / bootstrap product specs
|
|
7
|
+
|
|
8
|
+
Routes intent **`spec-gen`** (or bootstrap) → **task-analyst** in **author mode** → human gate (`after:task-analyst`) → stop, or continue to feature-developer if the user asked to implement after.
|
|
9
|
+
|
|
10
|
+
## What to do
|
|
11
|
+
|
|
12
|
+
1. Extract description from arguments after `/spec-start` (domain, page/feature ids, sources).
|
|
13
|
+
2. Generate a **slug** (kebab-case, ≤48 chars), e.g. `spec-<domain>-<id>`.
|
|
14
|
+
3. Ensure `.cursor/team/tasks/<slug>/` exists (Write artifacts; not Shell mkdir).
|
|
15
|
+
4. Write `.cursor/team/active-task.json` → `{ "slug": "<slug>" }`.
|
|
16
|
+
5. Write minimal `pipeline.json`: task-analyst → (optional stop) → feature-developer only if user asked implement-after. **No separate spec-author agent.**
|
|
17
|
+
6. Invoke **task-analyst** with: author mode; load **`product-specs`** + **`product-specs-authoring`** + skill **`spec-authoring`**; Bootstrap if `docs/specs/` absent, else Generate.
|
|
18
|
+
7. Wait for analyst. **Do not** invoke feature-developer until human gate passes.
|
|
19
|
+
|
|
20
|
+
## Human gate
|
|
21
|
+
|
|
22
|
+
- Show created/updated spec paths and INDEX diff.
|
|
23
|
+
- Ask user to approve drafts (`status: draft` → promote) or send edits.
|
|
24
|
+
- Continue: `/task-continue <slug>` only after approval when implementation follows; otherwise stop after docs.
|
|
25
|
+
|
|
26
|
+
## Notes
|
|
27
|
+
|
|
28
|
+
- Greenfield invent of INDEX is allowed **only** via this command, explicit ask, or AC bootstrap language.
|
|
29
|
+
- mcp-ts: analyst-only author/sync (no tech-writer).
|
|
@@ -40,11 +40,14 @@ printf '%s\n' '{"status":"completed","action":"end_human_gate","activateNext":tr
|
|
|
40
40
|
|
|
41
41
|
| Agent | Read |
|
|
42
42
|
|-------|------|
|
|
43
|
-
| feature-developer | brief.md, decomposition.md, validation-report.md (if retry), review.md (if retry), architecture.md |
|
|
43
|
+
| feature-developer | brief.md (incl. **Related specs**), decomposition.md, validation-report.md (if retry), review.md (if retry), architecture.md; if `docs/specs/INDEX.md` exists → load **`product-specs`** |
|
|
44
44
|
| build-verifier | git diff, decomposition.md |
|
|
45
45
|
| code-reviewer | brief.md, validation-report.md, git diff |
|
|
46
46
|
| qa-tester | brief.md, decomposition.md, scope from pipeline step |
|
|
47
47
|
|
|
48
|
-
##
|
|
48
|
+
## Product specs (docs/specs)
|
|
49
|
+
|
|
50
|
+
When the next agent is **feature-developer** (or other implementer): if `docs/specs/INDEX.md` exists or brief lists approved specs, instruct them to load **`product-specs`** and honor **Related specs** / approved generated specs as behavior SoT. Soft-fail on miss; never invent product behavior.
|
|
51
|
+
|
|
52
|
+
If analyst ran **author mode**, confirm human approved drafts before developer. Pass spec paths + INDEX diff in the handoff. No-op if INDEX is absent and no approved specs.
|
|
49
53
|
|
|
50
|
-
On human-gate resume, the hook action above appends `human_gate_ended` under the per-task lock **before** any new `attempt_started`. Agents must not calculate durations.
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
## Loading strategy
|
|
20
20
|
|
|
21
21
|
- **`alwaysApply: true`** (Cursor) / **without `paths:`** (Claude) — only the base invariants (**3**): `laravel-app-core`, `architecture-boundaries`, `code-quality-and-refactoring`
|
|
22
|
-
- **On-demand / requestable** — `post-change-test`, `php-tooling`, Laravel domain rules, tests, feature-delivery-workflow, reference-features, `design-guidance`, `anti-sycophancy-discipline`, `technical-retro`, agent-team
|
|
22
|
+
- **On-demand / requestable** — `post-change-test`, `php-tooling`, Laravel domain rules, tests, feature-delivery-workflow, reference-features, product-specs, product-specs-authoring, `design-guidance`, `anti-sycophancy-discipline`, `technical-retro`, agent-team
|
|
23
23
|
- **Preset author meta** (globs `packages/ai-rules/presets/**`, never alwaysApply): `preset-layering`, `preset-twin-sync`, `preset-token-budget`, `preset-pr-checklist`, `preset-no-cross-stack-leakage`
|
|
24
24
|
- **Skills** — `feature-delivery`, `code-review`, `integration-testing`, `unit-testing`, …
|
|
25
25
|
|
|
@@ -50,6 +50,8 @@ SoT prose: `packages/ai-rules/presets/_shared/core/**` (see `_shared/README.md`)
|
|
|
50
50
|
| `agent-team/agent-team-intake.md` | `agent-team-intake.mdc` | embed | thin alias |
|
|
51
51
|
| `architecture/feature-delivery-workflow.md` | `feature-delivery-workflow.mdc` | lineage | Laravel checklist |
|
|
52
52
|
| `architecture/reference-features.template.md` | `reference-features.mdc` | lineage | `dogfood/php-laravel` path table + scenarios |
|
|
53
|
+
| `architecture/product-specs.md` | `product-specs.mdc` | INDEX discovery; Stack notes field semantics |
|
|
54
|
+
| `architecture/product-specs-authoring.md` | `product-specs-authoring.mdc` | Generate/Bootstrap contract; requestable |
|
|
53
55
|
| `review/code-review-mr.md` | `code-review-mr.mdc` | embed | Laravel checklist |
|
|
54
56
|
| `review/technical-retro.md` | `technical-retro.mdc` | embed | thin alias |
|
|
55
57
|
| `meta/preset-*.md` | `preset-*.mdc` | embed | author-only globs (incl. `preset-no-cross-stack-leakage`) |
|
|
@@ -69,6 +71,7 @@ Compare with framework-agnostic hexagonal: installable id **`php-hexagonal`** (p
|
|
|
69
71
|
| `design-guidance` | full | requestable embed; Laravel Stack notes |
|
|
70
72
|
| `feature-delivery-workflow` | full | Laravel checklist + matrix |
|
|
71
73
|
| `reference-features` | full | `dogfood/php-laravel` path table |
|
|
74
|
+
| `product-specs` | full | requestable embed — docs/specs INDEX |
|
|
72
75
|
| `agent-team-orchestrator` | full | Roles table (21) + `integration-test-*` |
|
|
73
76
|
| `code-review-mr` | full | Laravel Stack notes checklist |
|
|
74
77
|
| `preset-*` (×5) | full | author meta |
|
|
@@ -201,3 +201,5 @@ When the work edits `packages/ai-rules/presets/**` (or dogfood `.cursor/` sync o
|
|
|
201
201
|
- **Risk-based security-reviewer:** schedule when the task touches auth/Policies/Gates/middleware, routes/HTTP bootstrap, Form Requests, mass assignment, Jobs/queues, config/secrets, uploads, or PII logging — see `task-router` § Security-reviewer routing. Parallel with `code-reviewer` is OK; document skip with an auditable reason when those surfaces are unaffected.
|
|
202
202
|
- Chain hook handoffs: `integration-test-*`, `post-change-test`, `php-tooling` — never `lint:js`, Playwright, XCUITest, or `xcodebuild`.
|
|
203
203
|
- Skills: `feature-delivery`, `unit-testing`, `integration-testing`, `ci-investigation`, `debug-investigation`, `code-review`, `technical-retro`, `write-adr`.
|
|
204
|
+
|
|
205
|
+
**Product specs:** When `/task`, `/feature-start`, or `/spec-start` touches pages/features/`docs/specs`: if INDEX exists and no generate intent → instruct next agent to load requestable **`product-specs`** (consume; soft-fail; never invent). If generate/bootstrap/`spec-gen` → load **`product-specs-authoring`** + skill **`spec-authoring`** inside **task-analyst** (not a separate pipeline step); pass created spec paths + INDEX diff in handoff; human gate must approve before feature-developer. No-op if INDEX absent and no author intent.
|
|
@@ -48,3 +48,7 @@ flowchart LR
|
|
|
48
48
|
- Fat controllers; Form Requests in Models; AuthZ via ad-hoc roles; skipping Feature tests for API writes.
|
|
49
49
|
- Mandating hexagonal ports/adapters folders in a Laravel-first app.
|
|
50
50
|
- Load `design-guidance` when assessing structure, smells, or pattern fit.
|
|
51
|
+
|
|
52
|
+
## Related
|
|
53
|
+
|
|
54
|
+
- Product behavior discovery: requestable **`product-specs`** (`docs/specs/INDEX.md`) — do not paste the discovery algorithm here.
|
|
@@ -24,7 +24,7 @@ Rules for **preset authors** (`packages/ai-rules/presets/**`). Not always-on in
|
|
|
24
24
|
## Where to put a new rule
|
|
25
25
|
|
|
26
26
|
1. Shared principles for all stacks → **core** + adapters with `<!-- shared-core: … -->`.
|
|
27
|
-
2. Only one of the installable stacks (`next` / `nuxt` / `svelte` / `ios-swift` / `go` / `java` / `mcp-ts` / `php-hexagonal` / `php-laravel`) → **stack-specific** (not in `_shared`).
|
|
27
|
+
2. Only one of the installable stacks (`next` / `nuxt` / `svelte` / `ios-swift` / `android-kotlin` / `go` / `java` / `mcp-ts` / `php-hexagonal` / `php-laravel`) → **stack-specific** (not in `_shared`).
|
|
28
28
|
3. Only Cursor or only Claude packaging → platform artifact / frontmatter; do not duplicate semantics.
|
|
29
29
|
|
|
30
30
|
## SoT
|
|
@@ -15,11 +15,12 @@ Ban leakage of stack-specific names, paths, and handoff stems across presets.
|
|
|
15
15
|
|
|
16
16
|
## Principles
|
|
17
17
|
|
|
18
|
-
- `next` must not require iOS-only agents/tooling (`xcuitest-*`, `xcodebuild` as required handoff, Keychain-only rules).
|
|
19
|
-
- `nuxt` must not require iOS-only agents/tooling (`xcuitest-*`, `xcodebuild` as required handoff, Keychain-only rules).
|
|
20
|
-
- `svelte` must not require iOS-only agents/tooling (`xcuitest-*`, `xcodebuild` as required handoff, Keychain-only rules).
|
|
21
|
-
- `ios-swift` must not ship Playwright handoffs or Next lint recipes as required commands.
|
|
22
|
-
- `
|
|
18
|
+
- `next` must not require iOS-only or Android-only agents/tooling (`xcuitest-*`, `instrumentation-test-*`, `xcodebuild` as required handoff, Keychain-only rules).
|
|
19
|
+
- `nuxt` must not require iOS-only or Android-only agents/tooling (`xcuitest-*`, `instrumentation-test-*`, `xcodebuild` as required handoff, Keychain-only rules).
|
|
20
|
+
- `svelte` must not require iOS-only or Android-only agents/tooling (`xcuitest-*`, `instrumentation-test-*`, `xcodebuild` as required handoff, Keychain-only rules).
|
|
21
|
+
- `ios-swift` must not ship Playwright handoffs, Android `instrumentation-test-*` handoffs, or Next lint recipes as required commands.
|
|
22
|
+
- `android-kotlin` must not ship Playwright, XCUITest, `xcodebuild`, or Next lint recipes as required handoffs.
|
|
23
|
+
- `go` / `java` / `php-hexagonal` / `php-laravel` / `mcp-ts` must not ship Playwright, XCUITest, Android instrumentation agents, Next lint recipes, or `xcodebuild`/`SwiftLint` as required handoffs.
|
|
23
24
|
- `mcp-ts` must not ship Go tool commands (`go test`, `go vet`, `golangci-lint`) or `integration-test-*` agents as required delivery gates.
|
|
24
25
|
- Shared core must not embed stack paths (`app/src/**`, `Features/**`, `playwright`, `xcodebuild`).
|
|
25
26
|
|
|
@@ -28,25 +29,37 @@ Ban leakage of stack-specific names, paths, and handoff stems across presets.
|
|
|
28
29
|
In ios-swift `chain-team-phases.sh` / agent handoffs (Cursor + Claude):
|
|
29
30
|
|
|
30
31
|
- `playwright-test-`, `playwright-agents`, `playwright-e2e`, `user-playwright`
|
|
32
|
+
- `instrumentation-test-` as required Android handoffs
|
|
31
33
|
- `app/__tests__/e2e` as a required path
|
|
32
34
|
- Positive yarn recipes `lint:js` / `lint:css` as commands to run (negation prose alone is weak — prefer zero occurrences)
|
|
33
35
|
|
|
34
36
|
Required instead: `xcuitest-test-*` stems; build-verifier mentions `xcodebuild` or `post-change-build` / `xcode-tooling`.
|
|
35
37
|
|
|
38
|
+
## Forbidden in android-kotlin hooks/agents (FAIL)
|
|
39
|
+
|
|
40
|
+
In android-kotlin `chain-team-phases.sh` / agent handoffs (Cursor + Claude):
|
|
41
|
+
|
|
42
|
+
- `playwright-test-`, `playwright-agents`, `playwright-e2e`, `user-playwright`
|
|
43
|
+
- `app/__tests__/e2e` as a required path
|
|
44
|
+
- `xcuitest-test-`, positive `xcodebuild` / `SwiftLint` as required handoffs
|
|
45
|
+
- Positive yarn recipes `lint:js` / `lint:css` as commands to run
|
|
46
|
+
|
|
47
|
+
Required instead: `instrumentation-test-*` stems; build-verifier mentions `gradle-tooling` and/or `post-change-build` (Gradle wrapper discovery — not `xcodebuild` as the default gate).
|
|
48
|
+
|
|
36
49
|
## Forbidden in next hooks/agents (FAIL when present as required)
|
|
37
50
|
|
|
38
|
-
- `xcuitest-test-` as handoff stems
|
|
51
|
+
- `xcuitest-test-` / `instrumentation-test-` as handoff stems
|
|
39
52
|
- Requiring `xcodebuild` / SwiftLint as the default post-change gate for Next app work
|
|
40
53
|
|
|
41
54
|
## Forbidden in nuxt hooks/agents (FAIL when present as required)
|
|
42
55
|
|
|
43
|
-
- `xcuitest-test-` as handoff stems
|
|
56
|
+
- `xcuitest-test-` / `instrumentation-test-` as handoff stems
|
|
44
57
|
- Requiring `xcodebuild` / SwiftLint as the default post-change gate for Nuxt app work
|
|
45
58
|
- Frontend profile mirrors `next`: Playwright / `lint:js` / `lint:css` allowed
|
|
46
59
|
|
|
47
60
|
## Forbidden in svelte hooks/agents (FAIL when present as required)
|
|
48
61
|
|
|
49
|
-
- `xcuitest-test-` as handoff stems
|
|
62
|
+
- `xcuitest-test-` / `instrumentation-test-` as handoff stems
|
|
50
63
|
- Requiring `xcodebuild` / SwiftLint as the default post-change gate for SvelteKit app work
|
|
51
64
|
- Frontend profile mirrors `next` / `nuxt`: Playwright / `lint:js` / `lint:css` allowed
|
|
52
65
|
|
|
@@ -56,7 +69,7 @@ Shared backend-stack bans (`go`, `java`, `php-hexagonal`, and `php-laravel`):
|
|
|
56
69
|
|
|
57
70
|
- `playwright-test-`, `playwright-e2e`, `user-playwright`, `app/__tests__/e2e`
|
|
58
71
|
- Positive yarn recipes `lint:js` / `lint:css`
|
|
59
|
-
- `xcuitest-test-`, `xcodebuild`, `SwiftLint` as required handoffs
|
|
72
|
+
- `xcuitest-test-`, `instrumentation-test-`, `xcodebuild`, `SwiftLint` as required handoffs
|
|
60
73
|
- Agent file `accessibility-reviewer` (no UI surface)
|
|
61
74
|
|
|
62
75
|
Required instead: `integration-test-*`; build-verifier / `post-change-test` plus stack tooling — `go-tooling` (`go test`, `go vet`), `java-tooling` (`mvn test` / `./gradlew test`), or `php-tooling` (`php artisan test` / `composer test` / `vendor/bin/phpunit`).
|
|
@@ -67,9 +80,9 @@ Same UI/mobile bans as backend stacks, plus:
|
|
|
67
80
|
|
|
68
81
|
- `playwright-test-`, `playwright-agents`, `playwright-e2e`, `user-playwright`, `app/__tests__/e2e`
|
|
69
82
|
- Positive yarn recipes `lint:js` / `lint:css` as required gates
|
|
70
|
-
- `xcuitest-test-`, `xcodebuild`, `SwiftLint` as required handoffs
|
|
83
|
+
- `xcuitest-test-`, `instrumentation-test-`, `xcodebuild`, `SwiftLint` as required handoffs
|
|
71
84
|
- Go tool commands as required MCP delivery gates: `go test`, `go vet`, `golangci-lint`
|
|
72
|
-
- Agent files: `playwright-test-*`, `xcuitest-test-*`, `integration-test-*`, `accessibility-reviewer`
|
|
85
|
+
- Agent files: `playwright-test-*`, `xcuitest-test-*`, `instrumentation-test-*`, `integration-test-*`, `accessibility-reviewer`
|
|
73
86
|
|
|
74
87
|
Required instead: package-manager–discovered typecheck/test (`mcp-ts-tooling`, `post-change-test`); Phase 1 gates `build-verifier` + `security-reviewer`.
|
|
75
88
|
|
|
@@ -80,4 +93,4 @@ Required instead: package-manager–discovered typecheck/test (`mcp-ts-tooling`,
|
|
|
80
93
|
|
|
81
94
|
## Chain fork
|
|
82
95
|
|
|
83
|
-
`hooks/chain-team-phases.sh` must differ **byte-wise** pairwise among `next`, `nuxt`, `svelte`, `ios-swift`, `go`, `java`, `mcp-ts`, `php-hexagonal`, and `php-laravel` (per platform).
|
|
96
|
+
`hooks/chain-team-phases.sh` must differ **byte-wise** pairwise among `next`, `nuxt`, `svelte`, `ios-swift`, `android-kotlin`, `go`, `java`, `mcp-ts`, `php-hexagonal`, and `php-laravel` (per platform).
|
|
@@ -17,7 +17,7 @@ Checklist for PRs that touch `packages/ai-rules/presets/**` (and dogfood `.curso
|
|
|
17
17
|
|
|
18
18
|
- [ ] **SoT:** edits in `packages/…` (not only root `.cursor/`)
|
|
19
19
|
- [ ] **Core:** if `_shared/core/**` changed — all `<!-- shared-core: … -->` consumers updated (or documented intentional fork)
|
|
20
|
-
- [ ] **Twin:** Cursor change → Claude twin **same PR** (**FAIL** if missing on next, nuxt, svelte, ios-swift, go, java, mcp-ts, php-hexagonal, and php-laravel — see `preset-twin-sync`)
|
|
20
|
+
- [ ] **Twin:** Cursor change → Claude twin **same PR** (**FAIL** if missing on next, nuxt, svelte, ios-swift, android-kotlin, go, java, mcp-ts, php-hexagonal, and php-laravel — see `preset-twin-sync`)
|
|
21
21
|
- [ ] **Mapping:** `claude/<stack>/rules/README.md` mapping table is current
|
|
22
22
|
- [ ] **Token budget:** alwaysApply / session-start ≤ 3; meta rules not always-on
|
|
23
23
|
- [ ] **Leakage:** no foreign stack agent stems / handoff strings (`preset-no-cross-stack-leakage`)
|
|
@@ -26,6 +26,7 @@ Cursor `.mdc` — **SoT per stack**. Claude topic `.md` — derived twin.
|
|
|
26
26
|
| `mcp-ts` | `presets/cursor/mcp-ts/rules/*.mdc` | `presets/claude/mcp-ts/rules/<topic>/` | Keep in `claude/mcp-ts/rules/README.md` |
|
|
27
27
|
| `php-hexagonal` | `presets/cursor/php-hexagonal/rules/*.mdc` | `presets/claude/php-hexagonal/rules/<topic>/` | Keep in `claude/php-hexagonal/rules/README.md` |
|
|
28
28
|
| `php-laravel` | `presets/cursor/php-laravel/rules/*.mdc` | `presets/claude/php-laravel/rules/<topic>/` | Keep in `claude/php-laravel/rules/README.md` |
|
|
29
|
+
| `android-kotlin` | `presets/cursor/android-kotlin/rules/*.mdc` | `presets/claude/android-kotlin/rules/<topic>/` | Keep in `claude/android-kotlin/rules/README.md` |
|
|
29
30
|
|
|
30
31
|
## Same-PR checklist
|
|
31
32
|
|
|
@@ -50,5 +51,6 @@ Cursor `.mdc` — **SoT per stack**. Claude topic `.md` — derived twin.
|
|
|
50
51
|
- **mcp-ts:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java; mapping table required).
|
|
51
52
|
- **php-hexagonal:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java / mcp-ts; mapping table required).
|
|
52
53
|
- **php-laravel:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java / mcp-ts / php-hexagonal; mapping table required).
|
|
54
|
+
- **android-kotlin:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java / mcp-ts / php-*; mapping table required).
|
|
53
55
|
|
|
54
56
|
Dogfood: sync packages → root `.cursor/` after Cursor SoT changes (not the reverse). Use `packages/ai-rules/scripts/sync-dogfood-cursor.sh`.
|