@bonesofspring/ai-rules 0.2.11 → 0.2.13
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 +42 -0
- package/README.md +5 -1
- package/bin/cli.js +4 -0
- package/package.json +1 -1
- package/presets/_shared/README.md +1 -1
- package/presets/_shared/core/agent-team/agent-artifact-contracts.md +114 -0
- package/presets/_shared/core/agent-team/agent-task-metrics.md +30 -0
- package/presets/_shared/core/agent-team/agent-team-orchestrator.md +71 -4
- package/presets/_shared/core/meta/preset-layering.md +1 -1
- package/presets/_shared/core/meta/preset-no-cross-stack-leakage.md +5 -5
- package/presets/_shared/core/meta/preset-pr-checklist.md +1 -1
- package/presets/_shared/core/meta/preset-twin-sync.md +4 -0
- package/presets/_shared/core/review/technical-retro.md +2 -0
- package/presets/claude/go/agents/build-verifier.md +11 -4
- package/presets/claude/go/agents/code-reviewer.md +8 -1
- package/presets/claude/go/agents/feature-developer.md +8 -1
- package/presets/claude/go/agents/task-analyst.md +8 -1
- package/presets/claude/go/agents/task-router.md +35 -3
- package/presets/claude/go/commands/task-continue.md +17 -16
- package/presets/claude/go/commands/task.md +11 -5
- package/presets/claude/go/commands/technical-retro.md +4 -0
- package/presets/claude/go/hooks/chain-team-phases.sh +411 -69
- package/presets/claude/go/rules/README.md +6 -0
- package/presets/claude/go/rules/tooling-and-review/agent-team-orchestrator.md +33 -4
- 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 +5 -5
- 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 +4 -0
- package/presets/claude/go/rules/tooling-and-review/technical-retro.md +2 -0
- package/presets/claude/go/team/README.md +19 -0
- package/presets/claude/ios-swift/agents/build-verifier.md +11 -4
- package/presets/claude/ios-swift/agents/code-reviewer.md +9 -14
- package/presets/claude/ios-swift/agents/feature-developer.md +8 -1
- package/presets/claude/ios-swift/agents/task-analyst.md +8 -1
- package/presets/claude/ios-swift/agents/task-router.md +33 -1
- package/presets/claude/ios-swift/commands/task-continue.md +17 -16
- package/presets/claude/ios-swift/commands/task.md +11 -5
- package/presets/claude/ios-swift/commands/technical-retro.md +4 -0
- package/presets/claude/ios-swift/hooks/chain-team-phases.sh +393 -70
- package/presets/claude/ios-swift/rules/README.md +6 -0
- package/presets/claude/ios-swift/rules/tooling-and-review/agent-team-orchestrator.md +36 -1
- 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 +5 -5
- 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 +4 -0
- package/presets/claude/ios-swift/rules/tooling-and-review/technical-retro.md +2 -0
- package/presets/claude/ios-swift/team/README.md +19 -0
- package/presets/claude/java/agents/build-verifier.md +11 -4
- package/presets/claude/java/agents/code-reviewer.md +8 -1
- package/presets/claude/java/agents/feature-developer.md +8 -1
- package/presets/claude/java/agents/task-analyst.md +8 -1
- package/presets/claude/java/agents/task-router.md +33 -1
- package/presets/claude/java/commands/task-continue.md +17 -16
- package/presets/claude/java/commands/task.md +11 -5
- package/presets/claude/java/commands/technical-retro.md +4 -0
- package/presets/claude/java/hooks/chain-team-phases.sh +411 -69
- package/presets/claude/java/rules/README.md +6 -0
- package/presets/claude/java/rules/tooling-and-review/agent-team-orchestrator.md +33 -4
- 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 +5 -5
- 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 +4 -0
- package/presets/claude/java/rules/tooling-and-review/technical-retro.md +2 -0
- package/presets/claude/java/team/README.md +19 -0
- package/presets/claude/mcp-ts/agents/build-verifier.md +11 -4
- package/presets/claude/mcp-ts/agents/feature-developer.md +7 -1
- package/presets/claude/mcp-ts/agents/task-analyst.md +8 -1
- package/presets/claude/mcp-ts/agents/task-router.md +35 -3
- package/presets/claude/mcp-ts/commands/task-continue.md +21 -20
- package/presets/claude/mcp-ts/commands/task.md +11 -5
- package/presets/claude/mcp-ts/commands/technical-retro.md +4 -0
- package/presets/claude/mcp-ts/hooks/chain-team-phases.sh +397 -55
- package/presets/claude/mcp-ts/rules/README.md +6 -0
- package/presets/claude/mcp-ts/rules/tooling-and-review/agent-team-orchestrator.md +33 -4
- 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 +5 -5
- 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 +4 -0
- package/presets/claude/mcp-ts/rules/tooling-and-review/technical-retro.md +2 -4
- package/presets/claude/mcp-ts/team/README.md +19 -0
- package/presets/claude/next/agents/accessibility-reviewer.md +6 -12
- package/presets/claude/next/agents/api-contract-reviewer.md +6 -12
- package/presets/claude/next/agents/build-verifier.md +10 -14
- package/presets/claude/next/agents/ci-investigator.md +7 -13
- package/presets/claude/next/agents/code-reviewer.md +9 -14
- package/presets/claude/next/agents/debugger.md +6 -12
- package/presets/claude/next/agents/feature-developer.md +8 -1
- package/presets/claude/next/agents/migration-specialist.md +6 -12
- package/presets/claude/next/agents/performance-auditor.md +5 -11
- package/presets/claude/next/agents/qa-tester.md +6 -12
- package/presets/claude/next/agents/security-reviewer.md +6 -12
- package/presets/claude/next/agents/solution-architect.md +6 -12
- package/presets/claude/next/agents/task-analyst.md +10 -16
- package/presets/claude/next/agents/task-router.md +33 -1
- package/presets/claude/next/agents/tech-writer.md +6 -13
- package/presets/claude/next/agents/unit-test-generator.md +6 -10
- package/presets/claude/next/agents/unit-test-healer.md +6 -10
- package/presets/claude/next/agents/unit-test-planner.md +5 -11
- package/presets/claude/next/commands/task-continue.md +17 -16
- package/presets/claude/next/commands/task.md +11 -5
- package/presets/claude/next/commands/technical-retro.md +4 -0
- package/presets/claude/next/hooks/chain-team-phases.sh +413 -70
- package/presets/claude/next/rules/README.md +6 -0
- package/presets/claude/next/rules/tooling-and-review/agent-team-orchestrator.md +32 -3
- 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 +5 -5
- 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 +4 -0
- package/presets/claude/next/rules/tooling-and-review/technical-retro.md +2 -0
- package/presets/claude/next/team/README.md +32 -1
- package/presets/claude/next/team/fixtures/artifact-manifest.example.json +61 -0
- package/presets/claude/next/team/fixtures/bugfix-standard.json +10 -0
- package/presets/claude/next/team/fixtures/feature-full.json +10 -0
- package/presets/claude/next/team/fixtures/feature-light.json +10 -0
- package/presets/claude/php-hexagonal/CLAUDE.md +31 -0
- package/presets/claude/php-hexagonal/MCP.md +15 -0
- package/presets/claude/php-hexagonal/README.md +26 -0
- package/presets/claude/php-hexagonal/REPO_AGENTS.md +46 -0
- package/presets/claude/php-hexagonal/agents/README.md +32 -0
- package/presets/claude/php-hexagonal/agents/api-contract-reviewer.md +23 -0
- package/presets/claude/php-hexagonal/agents/build-verifier.md +52 -0
- package/presets/claude/php-hexagonal/agents/ci-investigator.md +21 -0
- package/presets/claude/php-hexagonal/agents/code-reviewer.md +47 -0
- package/presets/claude/php-hexagonal/agents/codebase-analyzer.md +28 -0
- package/presets/claude/php-hexagonal/agents/debugger.md +29 -0
- package/presets/claude/php-hexagonal/agents/feature-developer.md +54 -0
- package/presets/claude/php-hexagonal/agents/integration-test-generator.md +22 -0
- package/presets/claude/php-hexagonal/agents/integration-test-healer.md +22 -0
- package/presets/claude/php-hexagonal/agents/integration-test-planner.md +22 -0
- package/presets/claude/php-hexagonal/agents/migration-specialist.md +31 -0
- package/presets/claude/php-hexagonal/agents/performance-auditor.md +22 -0
- package/presets/claude/php-hexagonal/agents/qa-tester.md +24 -0
- package/presets/claude/php-hexagonal/agents/security-reviewer.md +20 -0
- package/presets/claude/php-hexagonal/agents/solution-architect.md +28 -0
- package/presets/claude/php-hexagonal/agents/task-analyst.md +32 -0
- package/presets/claude/php-hexagonal/agents/task-router.md +101 -0
- package/presets/claude/php-hexagonal/agents/tech-writer.md +15 -0
- package/presets/claude/php-hexagonal/agents/unit-test-generator.md +21 -0
- package/presets/claude/php-hexagonal/agents/unit-test-healer.md +13 -0
- package/presets/claude/php-hexagonal/agents/unit-test-planner.md +26 -0
- package/presets/claude/php-hexagonal/commands/README.md +13 -0
- package/presets/claude/php-hexagonal/commands/feature-continue.md +51 -0
- package/presets/claude/php-hexagonal/commands/feature-start.md +30 -0
- package/presets/claude/php-hexagonal/commands/task-continue.md +50 -0
- package/presets/claude/php-hexagonal/commands/task.md +55 -0
- package/presets/claude/php-hexagonal/commands/technical-retro.md +62 -0
- package/presets/claude/php-hexagonal/hooks/README.md +16 -0
- package/presets/claude/php-hexagonal/hooks/chain-team-phases.sh +724 -0
- package/presets/claude/php-hexagonal/hooks/examples/README.md +18 -0
- package/presets/claude/php-hexagonal/hooks/examples/format-edited.example.sh +11 -0
- package/presets/claude/php-hexagonal/hooks/examples/secret-guard.example.sh +10 -0
- package/presets/claude/php-hexagonal/hooks/examples/test-on-save.example.sh +19 -0
- package/presets/claude/php-hexagonal/hooks/guard-shell-command.sh +80 -0
- package/presets/claude/php-hexagonal/mcp.json +11 -0
- package/presets/claude/php-hexagonal/rules/README.md +67 -0
- package/presets/claude/php-hexagonal/rules/api-and-data/README.md +14 -0
- package/presets/claude/php-hexagonal/rules/api-and-data/adapters-driven.md +38 -0
- package/presets/claude/php-hexagonal/rules/api-and-data/adapters-driving.md +38 -0
- package/presets/claude/php-hexagonal/rules/api-and-data/api-grpc.md +29 -0
- package/presets/claude/php-hexagonal/rules/api-and-data/api-http.md +36 -0
- package/presets/claude/php-hexagonal/rules/api-and-data/messaging-adapters.md +37 -0
- package/presets/claude/php-hexagonal/rules/api-and-data/persistence-adapters.md +33 -0
- package/presets/claude/php-hexagonal/rules/architecture/README.md +16 -0
- package/presets/claude/php-hexagonal/rules/architecture/application-usecases.md +31 -0
- package/presets/claude/php-hexagonal/rules/architecture/boundaries.md +34 -0
- package/presets/claude/php-hexagonal/rules/architecture/composition-root.md +33 -0
- package/presets/claude/php-hexagonal/rules/architecture/domain-layer.md +37 -0
- package/presets/claude/php-hexagonal/rules/architecture/feature-delivery.md +53 -0
- package/presets/claude/php-hexagonal/rules/architecture/module-public-api.md +31 -0
- package/presets/claude/php-hexagonal/rules/architecture/ports-interfaces.md +34 -0
- package/presets/claude/php-hexagonal/rules/architecture/reference-features.md +39 -0
- package/presets/claude/php-hexagonal/rules/stack/README.md +10 -0
- package/presets/claude/php-hexagonal/rules/stack/php-app-core.md +35 -0
- package/presets/claude/php-hexagonal/rules/stack/php-conventions.md +51 -0
- package/presets/claude/php-hexagonal/rules/testing/README.md +11 -0
- package/presets/claude/php-hexagonal/rules/testing/e2e.md +35 -0
- package/presets/claude/php-hexagonal/rules/testing/integration.md +31 -0
- package/presets/claude/php-hexagonal/rules/testing/unit.md +32 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/README.md +21 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/agent-team-intake.md +26 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/agent-team-orchestrator.md +208 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/anti-sycophancy-discipline.md +29 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/code-quality.md +53 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/code-review.md +60 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/design-guidance.md +111 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/php-tooling.md +39 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/post-change-test.md +31 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-layering.md +36 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-no-cross-stack-leakage.md +69 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-pr-checklist.md +39 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-token-budget.md +41 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/preset-twin-sync.md +50 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/security-php.md +29 -0
- package/presets/claude/php-hexagonal/rules/tooling-and-review/technical-retro.md +22 -0
- package/presets/claude/php-hexagonal/rules/ui-and-accessibility/README.md +5 -0
- package/presets/claude/php-hexagonal/skills/README.md +5 -0
- package/presets/claude/php-hexagonal/skills/ci-investigation/SKILL.md +11 -0
- package/presets/claude/php-hexagonal/skills/code-review/SKILL.md +25 -0
- package/presets/claude/php-hexagonal/skills/debug-investigation/SKILL.md +15 -0
- package/presets/claude/php-hexagonal/skills/feature-delivery/SKILL.md +30 -0
- package/presets/claude/php-hexagonal/skills/integration-testing/SKILL.md +15 -0
- package/presets/claude/php-hexagonal/skills/technical-retro/SKILL.md +54 -0
- package/presets/claude/php-hexagonal/skills/unit-testing/SKILL.md +14 -0
- package/presets/claude/php-hexagonal/skills/write-adr/SKILL.md +41 -0
- package/presets/claude/php-hexagonal/team/README.md +48 -0
- package/presets/claude/php-hexagonal/team/conventions.md +21 -0
- package/presets/claude/php-hexagonal/team/fixtures/bugfix-standard.json +37 -0
- package/presets/claude/php-hexagonal/team/fixtures/feature-full.json +25 -0
- package/presets/claude/php-hexagonal/team/fixtures/feature-light.json +17 -0
- package/presets/claude/php-laravel/CLAUDE.md +20 -0
- package/presets/claude/php-laravel/MCP.md +5 -0
- package/presets/claude/php-laravel/README.md +30 -0
- package/presets/claude/php-laravel/REPO_AGENTS.md +47 -0
- package/presets/claude/php-laravel/agents/README.md +32 -0
- package/presets/claude/php-laravel/agents/api-contract-reviewer.md +23 -0
- package/presets/claude/php-laravel/agents/build-verifier.md +52 -0
- package/presets/claude/php-laravel/agents/ci-investigator.md +21 -0
- package/presets/claude/php-laravel/agents/code-reviewer.md +47 -0
- package/presets/claude/php-laravel/agents/codebase-analyzer.md +28 -0
- package/presets/claude/php-laravel/agents/debugger.md +29 -0
- package/presets/claude/php-laravel/agents/feature-developer.md +54 -0
- package/presets/claude/php-laravel/agents/integration-test-generator.md +22 -0
- package/presets/claude/php-laravel/agents/integration-test-healer.md +22 -0
- package/presets/claude/php-laravel/agents/integration-test-planner.md +22 -0
- package/presets/claude/php-laravel/agents/migration-specialist.md +31 -0
- package/presets/claude/php-laravel/agents/performance-auditor.md +22 -0
- package/presets/claude/php-laravel/agents/qa-tester.md +30 -0
- package/presets/claude/php-laravel/agents/security-reviewer.md +32 -0
- package/presets/claude/php-laravel/agents/solution-architect.md +29 -0
- package/presets/claude/php-laravel/agents/task-analyst.md +32 -0
- package/presets/claude/php-laravel/agents/task-router.md +120 -0
- package/presets/claude/php-laravel/agents/tech-writer.md +15 -0
- package/presets/claude/php-laravel/agents/unit-test-generator.md +21 -0
- package/presets/claude/php-laravel/agents/unit-test-healer.md +13 -0
- package/presets/claude/php-laravel/agents/unit-test-planner.md +26 -0
- package/presets/claude/php-laravel/commands/README.md +13 -0
- package/presets/claude/php-laravel/commands/feature-continue.md +51 -0
- package/presets/claude/php-laravel/commands/feature-start.md +30 -0
- package/presets/claude/php-laravel/commands/task-continue.md +50 -0
- package/presets/claude/php-laravel/commands/task.md +55 -0
- package/presets/claude/php-laravel/commands/technical-retro.md +62 -0
- package/presets/claude/php-laravel/hooks/README.md +16 -0
- package/presets/claude/php-laravel/hooks/chain-team-phases.sh +724 -0
- package/presets/claude/php-laravel/hooks/examples/README.md +18 -0
- package/presets/claude/php-laravel/hooks/examples/format-edited.example.sh +11 -0
- package/presets/claude/php-laravel/hooks/examples/secret-guard.example.sh +10 -0
- package/presets/claude/php-laravel/hooks/examples/test-on-save.example.sh +19 -0
- package/presets/claude/php-laravel/hooks/guard-shell-command.sh +80 -0
- package/presets/claude/php-laravel/mcp.json +11 -0
- package/presets/claude/php-laravel/rules/README.md +67 -0
- package/presets/claude/php-laravel/rules/api-and-data/README.md +3 -0
- package/presets/claude/php-laravel/rules/api-and-data/eloquent-persistence.md +31 -0
- package/presets/claude/php-laravel/rules/api-and-data/events-listeners.md +31 -0
- package/presets/claude/php-laravel/rules/api-and-data/form-requests.md +29 -0
- package/presets/claude/php-laravel/rules/api-and-data/http-layer.md +32 -0
- package/presets/claude/php-laravel/rules/api-and-data/jobs-queues.md +41 -0
- package/presets/claude/php-laravel/rules/api-and-data/policies-authorization.md +29 -0
- package/presets/claude/php-laravel/rules/api-and-data/routes-api.md +29 -0
- package/presets/claude/php-laravel/rules/architecture/README.md +3 -0
- package/presets/claude/php-laravel/rules/architecture/actions-services.md +30 -0
- package/presets/claude/php-laravel/rules/architecture/boundaries.md +34 -0
- package/presets/claude/php-laravel/rules/architecture/domain-layer.md +24 -0
- package/presets/claude/php-laravel/rules/architecture/feature-delivery.md +51 -0
- package/presets/claude/php-laravel/rules/architecture/module-public-api.md +29 -0
- package/presets/claude/php-laravel/rules/architecture/reference-features.md +40 -0
- package/presets/claude/php-laravel/rules/architecture/service-providers.md +28 -0
- package/presets/claude/php-laravel/rules/stack/README.md +3 -0
- package/presets/claude/php-laravel/rules/stack/laravel-app-core.md +32 -0
- package/presets/claude/php-laravel/rules/stack/laravel-conventions.md +38 -0
- package/presets/claude/php-laravel/rules/testing/README.md +3 -0
- package/presets/claude/php-laravel/rules/testing/e2e.md +34 -0
- package/presets/claude/php-laravel/rules/testing/integration.md +30 -0
- package/presets/claude/php-laravel/rules/testing/unit.md +30 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/README.md +3 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/agent-team-intake.md +21 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/agent-team-orchestrator.md +205 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/anti-sycophancy-discipline.md +29 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/code-quality.md +52 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/code-review.md +58 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/design-guidance.md +111 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/php-tooling.md +37 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/post-change-test.md +29 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/preset-layering.md +33 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/preset-no-cross-stack-leakage.md +66 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/preset-pr-checklist.md +36 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/preset-token-budget.md +38 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/preset-twin-sync.md +47 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/security-php.md +58 -0
- package/presets/claude/php-laravel/rules/tooling-and-review/technical-retro.md +17 -0
- package/presets/claude/php-laravel/rules/ui-and-accessibility/README.md +3 -0
- package/presets/claude/php-laravel/skills/README.md +5 -0
- package/presets/claude/php-laravel/skills/ci-investigation/SKILL.md +11 -0
- package/presets/claude/php-laravel/skills/code-review/SKILL.md +25 -0
- package/presets/claude/php-laravel/skills/debug-investigation/SKILL.md +15 -0
- package/presets/claude/php-laravel/skills/feature-delivery/SKILL.md +30 -0
- package/presets/claude/php-laravel/skills/integration-testing/SKILL.md +15 -0
- package/presets/claude/php-laravel/skills/technical-retro/SKILL.md +54 -0
- package/presets/claude/php-laravel/skills/unit-testing/SKILL.md +14 -0
- package/presets/claude/php-laravel/skills/write-adr/SKILL.md +41 -0
- package/presets/claude/php-laravel/team/README.md +28 -0
- package/presets/claude/php-laravel/team/conventions.md +21 -0
- package/presets/claude/php-laravel/team/fixtures/bugfix-standard.json +12 -0
- package/presets/claude/php-laravel/team/fixtures/feature-full.json +15 -0
- package/presets/claude/php-laravel/team/fixtures/feature-light.json +8 -0
- package/presets/cursor/go/agents/build-verifier.md +10 -3
- package/presets/cursor/go/agents/code-reviewer.md +8 -1
- package/presets/cursor/go/agents/feature-developer.md +8 -1
- package/presets/cursor/go/agents/task-analyst.md +8 -1
- package/presets/cursor/go/agents/task-router.md +33 -1
- package/presets/cursor/go/commands/task-continue.md +17 -16
- package/presets/cursor/go/commands/task.md +11 -5
- package/presets/cursor/go/commands/technical-retro.md +4 -0
- package/presets/cursor/go/hooks/chain-team-phases.sh +411 -69
- package/presets/cursor/go/rules/README.md +6 -0
- package/presets/cursor/go/rules/agent-team-orchestrator.mdc +33 -4
- package/presets/cursor/go/rules/preset-layering.mdc +1 -1
- package/presets/cursor/go/rules/preset-no-cross-stack-leakage.mdc +5 -5
- package/presets/cursor/go/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/go/rules/preset-twin-sync.mdc +4 -0
- package/presets/cursor/go/rules/technical-retro.mdc +2 -0
- package/presets/cursor/go/team/README.md +19 -0
- package/presets/cursor/ios-swift/agents/build-verifier.md +11 -4
- package/presets/cursor/ios-swift/agents/code-reviewer.md +9 -14
- package/presets/cursor/ios-swift/agents/feature-developer.md +8 -1
- package/presets/cursor/ios-swift/agents/task-analyst.md +8 -1
- package/presets/cursor/ios-swift/agents/task-router.md +33 -1
- package/presets/cursor/ios-swift/commands/task-continue.md +17 -16
- package/presets/cursor/ios-swift/commands/task.md +11 -5
- package/presets/cursor/ios-swift/commands/technical-retro.md +4 -0
- package/presets/cursor/ios-swift/hooks/chain-team-phases.sh +411 -70
- package/presets/cursor/ios-swift/rules/README.md +6 -0
- package/presets/cursor/ios-swift/rules/agent-team-orchestrator.mdc +26 -1
- package/presets/cursor/ios-swift/rules/preset-layering.mdc +1 -1
- package/presets/cursor/ios-swift/rules/preset-no-cross-stack-leakage.mdc +5 -5
- package/presets/cursor/ios-swift/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/ios-swift/rules/preset-twin-sync.mdc +4 -0
- package/presets/cursor/ios-swift/rules/technical-retro.mdc +2 -0
- package/presets/cursor/ios-swift/team/README.md +19 -0
- package/presets/cursor/java/agents/build-verifier.md +11 -4
- package/presets/cursor/java/agents/code-reviewer.md +8 -1
- package/presets/cursor/java/agents/feature-developer.md +8 -1
- package/presets/cursor/java/agents/task-analyst.md +8 -1
- package/presets/cursor/java/agents/task-router.md +33 -1
- package/presets/cursor/java/commands/task-continue.md +17 -16
- package/presets/cursor/java/commands/task.md +11 -5
- package/presets/cursor/java/commands/technical-retro.md +4 -0
- package/presets/cursor/java/hooks/chain-team-phases.sh +411 -69
- package/presets/cursor/java/rules/README.md +6 -0
- package/presets/cursor/java/rules/agent-team-orchestrator.mdc +33 -4
- package/presets/cursor/java/rules/preset-layering.mdc +1 -1
- package/presets/cursor/java/rules/preset-no-cross-stack-leakage.mdc +5 -5
- package/presets/cursor/java/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/java/rules/preset-twin-sync.mdc +4 -0
- package/presets/cursor/java/rules/technical-retro.mdc +2 -0
- package/presets/cursor/java/team/README.md +19 -0
- package/presets/cursor/mcp-ts/agents/build-verifier.md +10 -3
- package/presets/cursor/mcp-ts/agents/feature-developer.md +7 -1
- package/presets/cursor/mcp-ts/agents/task-analyst.md +8 -1
- package/presets/cursor/mcp-ts/agents/task-router.md +33 -1
- package/presets/cursor/mcp-ts/commands/task-continue.md +19 -18
- package/presets/cursor/mcp-ts/commands/task.md +11 -5
- package/presets/cursor/mcp-ts/commands/technical-retro.md +4 -0
- package/presets/cursor/mcp-ts/hooks/chain-team-phases.sh +397 -55
- package/presets/cursor/mcp-ts/rules/README.md +6 -0
- package/presets/cursor/mcp-ts/rules/agent-team-orchestrator.mdc +33 -4
- package/presets/cursor/mcp-ts/rules/preset-layering.mdc +1 -1
- package/presets/cursor/mcp-ts/rules/preset-no-cross-stack-leakage.mdc +5 -5
- package/presets/cursor/mcp-ts/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/mcp-ts/rules/preset-twin-sync.mdc +4 -0
- package/presets/cursor/mcp-ts/rules/technical-retro.mdc +2 -4
- package/presets/cursor/mcp-ts/team/README.md +19 -0
- package/presets/cursor/next/agents/accessibility-reviewer.md +7 -14
- package/presets/cursor/next/agents/api-contract-reviewer.md +7 -14
- package/presets/cursor/next/agents/build-verifier.md +10 -15
- package/presets/cursor/next/agents/ci-investigator.md +7 -14
- package/presets/cursor/next/agents/code-reviewer.md +9 -14
- package/presets/cursor/next/agents/debugger.md +6 -12
- package/presets/cursor/next/agents/feature-developer.md +8 -1
- package/presets/cursor/next/agents/migration-specialist.md +7 -14
- package/presets/cursor/next/agents/performance-auditor.md +6 -13
- package/presets/cursor/next/agents/qa-tester.md +6 -13
- package/presets/cursor/next/agents/security-reviewer.md +7 -14
- package/presets/cursor/next/agents/solution-architect.md +6 -12
- package/presets/cursor/next/agents/task-analyst.md +10 -16
- package/presets/cursor/next/agents/task-router.md +33 -1
- package/presets/cursor/next/agents/tech-writer.md +6 -13
- package/presets/cursor/next/agents/unit-test-generator.md +6 -11
- package/presets/cursor/next/agents/unit-test-healer.md +6 -11
- package/presets/cursor/next/agents/unit-test-planner.md +6 -13
- package/presets/cursor/next/commands/task-continue.md +17 -16
- package/presets/cursor/next/commands/task.md +11 -5
- package/presets/cursor/next/commands/technical-retro.md +4 -0
- package/presets/cursor/next/hooks/chain-team-phases.sh +417 -70
- package/presets/cursor/next/rules/README.md +6 -0
- package/presets/cursor/next/rules/agent-team-orchestrator.mdc +33 -4
- package/presets/cursor/next/rules/preset-layering.mdc +1 -1
- package/presets/cursor/next/rules/preset-no-cross-stack-leakage.mdc +5 -5
- package/presets/cursor/next/rules/preset-pr-checklist.mdc +1 -1
- package/presets/cursor/next/rules/preset-twin-sync.mdc +4 -0
- package/presets/cursor/next/rules/technical-retro.mdc +2 -0
- package/presets/cursor/next/team/README.md +33 -2
- package/presets/cursor/next/team/fixtures/artifact-manifest.example.json +61 -0
- package/presets/cursor/next/team/fixtures/bugfix-standard.json +10 -0
- package/presets/cursor/next/team/fixtures/feature-full.json +10 -0
- package/presets/cursor/next/team/fixtures/feature-light.json +10 -0
- package/presets/cursor/next/team/fixtures/metrics-scenarios/tasks/human-gate/metrics.json +69 -0
- package/presets/cursor/next/team/fixtures/metrics-scenarios/tasks/missing-ledger/status.json +5 -0
- package/presets/cursor/next/team/fixtures/metrics-scenarios/tasks/parallel-receipts/metrics.json +79 -0
- package/presets/cursor/next/team/fixtures/metrics-scenarios/tasks/serial-retry/metrics.json +124 -0
- package/presets/cursor/next/team/fixtures/metrics-scenarios/tasks/validation-failed/metrics.json +124 -0
- package/presets/cursor/next/team/fixtures/metrics.example.json +54 -0
- package/presets/cursor/php-hexagonal/AGENTS.md +39 -0
- package/presets/cursor/php-hexagonal/BUGBOT.md +11 -0
- package/presets/cursor/php-hexagonal/MCP.md +15 -0
- package/presets/cursor/php-hexagonal/README.md +26 -0
- package/presets/cursor/php-hexagonal/REPO_AGENTS.md +46 -0
- package/presets/cursor/php-hexagonal/agents/README.md +36 -0
- package/presets/cursor/php-hexagonal/agents/api-contract-reviewer.md +23 -0
- package/presets/cursor/php-hexagonal/agents/build-verifier.md +52 -0
- package/presets/cursor/php-hexagonal/agents/ci-investigator.md +21 -0
- package/presets/cursor/php-hexagonal/agents/code-reviewer.md +47 -0
- package/presets/cursor/php-hexagonal/agents/codebase-analyzer.md +28 -0
- package/presets/cursor/php-hexagonal/agents/debugger.md +29 -0
- package/presets/cursor/php-hexagonal/agents/feature-developer.md +54 -0
- package/presets/cursor/php-hexagonal/agents/integration-test-generator.md +22 -0
- package/presets/cursor/php-hexagonal/agents/integration-test-healer.md +22 -0
- package/presets/cursor/php-hexagonal/agents/integration-test-planner.md +22 -0
- package/presets/cursor/php-hexagonal/agents/migration-specialist.md +31 -0
- package/presets/cursor/php-hexagonal/agents/performance-auditor.md +22 -0
- package/presets/cursor/php-hexagonal/agents/qa-tester.md +24 -0
- package/presets/cursor/php-hexagonal/agents/security-reviewer.md +20 -0
- package/presets/cursor/php-hexagonal/agents/solution-architect.md +28 -0
- package/presets/cursor/php-hexagonal/agents/task-analyst.md +32 -0
- package/presets/cursor/php-hexagonal/agents/task-router.md +101 -0
- package/presets/cursor/php-hexagonal/agents/tech-writer.md +15 -0
- package/presets/cursor/php-hexagonal/agents/unit-test-generator.md +21 -0
- package/presets/cursor/php-hexagonal/agents/unit-test-healer.md +13 -0
- package/presets/cursor/php-hexagonal/agents/unit-test-planner.md +26 -0
- package/presets/cursor/php-hexagonal/commands/README.md +54 -0
- package/presets/cursor/php-hexagonal/commands/feature-continue.md +19 -0
- package/presets/cursor/php-hexagonal/commands/feature-start.md +33 -0
- package/presets/cursor/php-hexagonal/commands/task-continue.md +50 -0
- package/presets/cursor/php-hexagonal/commands/task.md +55 -0
- package/presets/cursor/php-hexagonal/commands/technical-retro.md +85 -0
- package/presets/cursor/php-hexagonal/hooks/README.md +12 -0
- package/presets/cursor/php-hexagonal/hooks/chain-team-phases.sh +724 -0
- package/presets/cursor/php-hexagonal/hooks/examples/README.md +18 -0
- package/presets/cursor/php-hexagonal/hooks/examples/format-edited.example.sh +11 -0
- package/presets/cursor/php-hexagonal/hooks/examples/secret-guard.example.sh +10 -0
- package/presets/cursor/php-hexagonal/hooks/examples/test-on-save.example.sh +19 -0
- package/presets/cursor/php-hexagonal/hooks/guard-shell-command.sh +80 -0
- package/presets/cursor/php-hexagonal/hooks.json +17 -0
- package/presets/cursor/php-hexagonal/mcp.json +11 -0
- package/presets/cursor/php-hexagonal/rules/README.md +106 -0
- package/presets/cursor/php-hexagonal/rules/adapters-driven.mdc +41 -0
- package/presets/cursor/php-hexagonal/rules/adapters-driving.mdc +42 -0
- package/presets/cursor/php-hexagonal/rules/agent-team-intake.mdc +20 -0
- package/presets/cursor/php-hexagonal/rules/agent-team-orchestrator.mdc +202 -0
- package/presets/cursor/php-hexagonal/rules/anti-sycophancy-discipline.mdc +30 -0
- package/presets/cursor/php-hexagonal/rules/api-grpc.mdc +31 -0
- package/presets/cursor/php-hexagonal/rules/api-http.mdc +40 -0
- package/presets/cursor/php-hexagonal/rules/application-usecases.mdc +33 -0
- package/presets/cursor/php-hexagonal/rules/architecture-boundaries.mdc +36 -0
- package/presets/cursor/php-hexagonal/rules/code-quality-and-refactoring.mdc +54 -0
- package/presets/cursor/php-hexagonal/rules/code-review-mr.mdc +54 -0
- package/presets/cursor/php-hexagonal/rules/composition-root.mdc +37 -0
- package/presets/cursor/php-hexagonal/rules/design-guidance.mdc +112 -0
- package/presets/cursor/php-hexagonal/rules/domain-layer.mdc +39 -0
- package/presets/cursor/php-hexagonal/rules/feature-delivery-workflow.mdc +47 -0
- package/presets/cursor/php-hexagonal/rules/messaging-adapters.mdc +38 -0
- package/presets/cursor/php-hexagonal/rules/module-public-api.mdc +32 -0
- package/presets/cursor/php-hexagonal/rules/persistence-adapters.mdc +35 -0
- package/presets/cursor/php-hexagonal/rules/php-app-core.mdc +37 -0
- package/presets/cursor/php-hexagonal/rules/php-conventions.mdc +53 -0
- package/presets/cursor/php-hexagonal/rules/php-tooling.mdc +38 -0
- package/presets/cursor/php-hexagonal/rules/ports-interfaces.mdc +37 -0
- package/presets/cursor/php-hexagonal/rules/post-change-test.mdc +30 -0
- package/presets/cursor/php-hexagonal/rules/preset-layering.mdc +36 -0
- package/presets/cursor/php-hexagonal/rules/preset-no-cross-stack-leakage.mdc +69 -0
- package/presets/cursor/php-hexagonal/rules/preset-pr-checklist.mdc +39 -0
- package/presets/cursor/php-hexagonal/rules/preset-token-budget.mdc +41 -0
- package/presets/cursor/php-hexagonal/rules/preset-twin-sync.mdc +50 -0
- package/presets/cursor/php-hexagonal/rules/reference-features.mdc +40 -0
- package/presets/cursor/php-hexagonal/rules/security-php.mdc +33 -0
- package/presets/cursor/php-hexagonal/rules/technical-retro.mdc +16 -0
- package/presets/cursor/php-hexagonal/rules/tests-e2e.mdc +36 -0
- package/presets/cursor/php-hexagonal/rules/tests-integration.mdc +33 -0
- package/presets/cursor/php-hexagonal/rules/tests-unit.mdc +35 -0
- package/presets/cursor/php-hexagonal/skills/README.md +5 -0
- package/presets/cursor/php-hexagonal/skills/ci-investigation/SKILL.md +11 -0
- package/presets/cursor/php-hexagonal/skills/code-review/SKILL.md +25 -0
- package/presets/cursor/php-hexagonal/skills/debug-investigation/SKILL.md +15 -0
- package/presets/cursor/php-hexagonal/skills/feature-delivery/SKILL.md +30 -0
- package/presets/cursor/php-hexagonal/skills/integration-testing/SKILL.md +15 -0
- package/presets/cursor/php-hexagonal/skills/technical-retro/SKILL.md +54 -0
- package/presets/cursor/php-hexagonal/skills/unit-testing/SKILL.md +14 -0
- package/presets/cursor/php-hexagonal/skills/write-adr/SKILL.md +41 -0
- package/presets/cursor/php-hexagonal/team/README.md +52 -0
- package/presets/cursor/php-hexagonal/team/conventions.md +21 -0
- package/presets/cursor/php-hexagonal/team/fixtures/bugfix-standard.json +37 -0
- package/presets/cursor/php-hexagonal/team/fixtures/feature-full.json +25 -0
- package/presets/cursor/php-hexagonal/team/fixtures/feature-light.json +17 -0
- package/presets/cursor/php-laravel/AGENTS.md +39 -0
- package/presets/cursor/php-laravel/BUGBOT.md +9 -0
- package/presets/cursor/php-laravel/MCP.md +5 -0
- package/presets/cursor/php-laravel/README.md +33 -0
- package/presets/cursor/php-laravel/REPO_AGENTS.md +47 -0
- package/presets/cursor/php-laravel/agents/README.md +36 -0
- package/presets/cursor/php-laravel/agents/api-contract-reviewer.md +23 -0
- package/presets/cursor/php-laravel/agents/build-verifier.md +52 -0
- package/presets/cursor/php-laravel/agents/ci-investigator.md +21 -0
- package/presets/cursor/php-laravel/agents/code-reviewer.md +47 -0
- package/presets/cursor/php-laravel/agents/codebase-analyzer.md +28 -0
- package/presets/cursor/php-laravel/agents/debugger.md +29 -0
- package/presets/cursor/php-laravel/agents/feature-developer.md +54 -0
- package/presets/cursor/php-laravel/agents/integration-test-generator.md +22 -0
- package/presets/cursor/php-laravel/agents/integration-test-healer.md +22 -0
- package/presets/cursor/php-laravel/agents/integration-test-planner.md +22 -0
- package/presets/cursor/php-laravel/agents/migration-specialist.md +31 -0
- package/presets/cursor/php-laravel/agents/performance-auditor.md +22 -0
- package/presets/cursor/php-laravel/agents/qa-tester.md +30 -0
- package/presets/cursor/php-laravel/agents/security-reviewer.md +32 -0
- package/presets/cursor/php-laravel/agents/solution-architect.md +29 -0
- package/presets/cursor/php-laravel/agents/task-analyst.md +32 -0
- package/presets/cursor/php-laravel/agents/task-router.md +120 -0
- package/presets/cursor/php-laravel/agents/tech-writer.md +15 -0
- package/presets/cursor/php-laravel/agents/unit-test-generator.md +21 -0
- package/presets/cursor/php-laravel/agents/unit-test-healer.md +13 -0
- package/presets/cursor/php-laravel/agents/unit-test-planner.md +26 -0
- package/presets/cursor/php-laravel/commands/README.md +54 -0
- package/presets/cursor/php-laravel/commands/feature-continue.md +19 -0
- package/presets/cursor/php-laravel/commands/feature-start.md +33 -0
- package/presets/cursor/php-laravel/commands/task-continue.md +50 -0
- package/presets/cursor/php-laravel/commands/task.md +55 -0
- package/presets/cursor/php-laravel/commands/technical-retro.md +85 -0
- package/presets/cursor/php-laravel/hooks/README.md +12 -0
- package/presets/cursor/php-laravel/hooks/chain-team-phases.sh +724 -0
- package/presets/cursor/php-laravel/hooks/examples/README.md +18 -0
- package/presets/cursor/php-laravel/hooks/examples/format-edited.example.sh +11 -0
- package/presets/cursor/php-laravel/hooks/examples/secret-guard.example.sh +10 -0
- package/presets/cursor/php-laravel/hooks/examples/test-on-save.example.sh +19 -0
- package/presets/cursor/php-laravel/hooks/guard-shell-command.sh +80 -0
- package/presets/cursor/php-laravel/hooks.json +17 -0
- package/presets/cursor/php-laravel/mcp.json +11 -0
- package/presets/cursor/php-laravel/rules/README.md +111 -0
- package/presets/cursor/php-laravel/rules/actions-services.mdc +33 -0
- package/presets/cursor/php-laravel/rules/agent-team-intake.mdc +20 -0
- package/presets/cursor/php-laravel/rules/agent-team-orchestrator.mdc +203 -0
- package/presets/cursor/php-laravel/rules/anti-sycophancy-discipline.mdc +30 -0
- package/presets/cursor/php-laravel/rules/architecture-boundaries.mdc +37 -0
- package/presets/cursor/php-laravel/rules/code-quality-and-refactoring.mdc +54 -0
- package/presets/cursor/php-laravel/rules/code-review-mr.mdc +56 -0
- package/presets/cursor/php-laravel/rules/design-guidance.mdc +112 -0
- package/presets/cursor/php-laravel/rules/domain-layer.mdc +27 -0
- package/presets/cursor/php-laravel/rules/eloquent-persistence.mdc +34 -0
- package/presets/cursor/php-laravel/rules/events-listeners.mdc +34 -0
- package/presets/cursor/php-laravel/rules/feature-delivery-workflow.mdc +50 -0
- package/presets/cursor/php-laravel/rules/form-requests.mdc +32 -0
- package/presets/cursor/php-laravel/rules/http-layer.mdc +35 -0
- package/presets/cursor/php-laravel/rules/jobs-queues.mdc +44 -0
- package/presets/cursor/php-laravel/rules/laravel-app-core.mdc +35 -0
- package/presets/cursor/php-laravel/rules/laravel-conventions.mdc +41 -0
- package/presets/cursor/php-laravel/rules/module-public-api.mdc +31 -0
- package/presets/cursor/php-laravel/rules/php-tooling.mdc +39 -0
- package/presets/cursor/php-laravel/rules/policies-authorization.mdc +32 -0
- package/presets/cursor/php-laravel/rules/post-change-test.mdc +31 -0
- package/presets/cursor/php-laravel/rules/preset-layering.mdc +36 -0
- package/presets/cursor/php-laravel/rules/preset-no-cross-stack-leakage.mdc +69 -0
- package/presets/cursor/php-laravel/rules/preset-pr-checklist.mdc +39 -0
- package/presets/cursor/php-laravel/rules/preset-token-budget.mdc +41 -0
- package/presets/cursor/php-laravel/rules/preset-twin-sync.mdc +50 -0
- package/presets/cursor/php-laravel/rules/reference-features.mdc +42 -0
- package/presets/cursor/php-laravel/rules/routes-api.mdc +32 -0
- package/presets/cursor/php-laravel/rules/security-php.mdc +61 -0
- package/presets/cursor/php-laravel/rules/service-providers.mdc +31 -0
- package/presets/cursor/php-laravel/rules/technical-retro.mdc +16 -0
- package/presets/cursor/php-laravel/rules/tests-e2e.mdc +36 -0
- package/presets/cursor/php-laravel/rules/tests-integration.mdc +33 -0
- package/presets/cursor/php-laravel/rules/tests-unit.mdc +33 -0
- package/presets/cursor/php-laravel/skills/README.md +5 -0
- package/presets/cursor/php-laravel/skills/ci-investigation/SKILL.md +11 -0
- package/presets/cursor/php-laravel/skills/code-review/SKILL.md +25 -0
- package/presets/cursor/php-laravel/skills/debug-investigation/SKILL.md +15 -0
- package/presets/cursor/php-laravel/skills/feature-delivery/SKILL.md +30 -0
- package/presets/cursor/php-laravel/skills/integration-testing/SKILL.md +15 -0
- package/presets/cursor/php-laravel/skills/technical-retro/SKILL.md +54 -0
- package/presets/cursor/php-laravel/skills/unit-testing/SKILL.md +14 -0
- package/presets/cursor/php-laravel/skills/write-adr/SKILL.md +41 -0
- package/presets/cursor/php-laravel/team/README.md +28 -0
- package/presets/cursor/php-laravel/team/conventions.md +21 -0
- package/presets/cursor/php-laravel/team/fixtures/bugfix-standard.json +12 -0
- package/presets/cursor/php-laravel/team/fixtures/feature-full.json +15 -0
- package/presets/cursor/php-laravel/team/fixtures/feature-light.json +8 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,48 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
### Agent artifact contracts
|
|
6
|
+
|
|
7
|
+
- New shared-core schema SoT: `presets/_shared/core/agent-team/agent-artifact-contracts.md` — per-slug `artifact-manifest.json` (schema v1) as context index + completion receipts; markdown remains narrative evidence.
|
|
8
|
+
- Agents upsert only owned manifest entries/receipts; the orchestration runtime/hook is the sole writer of `status.json` lifecycle fields and `metrics.json`.
|
|
9
|
+
- All seven Cursor/Claude stack team docs and existing task-router, task-analyst, feature-developer, build-verifier, and code-reviewer prompts declare authoritative inputs, owned outputs, and terminal receipt outcomes (orchestration runtime/hook remains the sole writer of `status.json` / `metrics.json`; hook instrumentation for metrics and receipt reconciliation is covered below).
|
|
10
|
+
- Added mirrored Next `artifact-manifest.example.json` fixtures and the `apply-agent-team-p0` dogfood pilot. Existing tasks without a manifest fall back to `brief.md`, `decomposition.md`, and `pipeline.json` and report the gap.
|
|
11
|
+
|
|
12
|
+
### Agent-team routing rubric
|
|
13
|
+
|
|
14
|
+
- New agent-team pipelines retain top-level `profile` and emit a structured `routingDecision` with `complexity`, `riskFlags`, auditable `routingReasons`, `estimatedWorkPackages`, and `openDecisionCount`.
|
|
15
|
+
- Updated all seven Cursor routers and seven Claude twins with shared low/moderate/high heuristics and concrete risk signals. Next light/standard/full fixtures demonstrate the contract; existing pipelines without the optional block remain valid.
|
|
16
|
+
|
|
17
|
+
### Agent-task metrics
|
|
18
|
+
|
|
19
|
+
- Added local schema-v1 `metrics.json` ledgers for agent-team pipelines: append-only task, attempt, retry, skip, completion, and human-gate lifecycle events. Allowlisted identifiers/timestamps/outcomes only (no prompts, secrets, file paths/contents, or remote telemetry). Shared-core policy: `presets/_shared/core/agent-team/agent-task-metrics.md` (requestable via orchestrator; no new always-on rule).
|
|
20
|
+
- Instrumented all Cursor/Claude `chain-team-phases.sh` forks with lock-safe temp-and-rename ledger/status writes, `status.json` `activeAttempts` / `lastCompletedAttempt` bridge, and conservative parallel attribution (payload `attemptId`, sole active attempt, or `.metrics-receipts.json` fallback—never guess from `currentAgent`). Repeated work-package retries now target the nearest preceding developer and return to the requesting verifier/reviewer; stale duplicate stops are ignored.
|
|
21
|
+
- Human-gate resume is a hook action: `{"status":"completed","action":"end_human_gate","activateNext":true}` on the installed `hooks/chain-team-phases.sh` (`/task-continue`); optional wrapper `scripts/close-agent-task-human-gate.mjs`.
|
|
22
|
+
- Added `aggregate-agent-task-metrics.mjs` (role/count/duration, gate wait, attribution confidence, and separate missing-ledger, malformed-JSON, duplicate-ID, unterminated, unmatched, and duplicate-terminal completeness categories), Next fixtures under `presets/cursor/next/team/fixtures/`, and a 14-fork lifecycle harness covering retry, concurrent parallel completion, skip, gate, and invalid-ledger scenarios. Technical-retro commands include a Metrics evidence section.
|
|
23
|
+
|
|
24
|
+
### PHP Laravel preset (`php-laravel`)
|
|
25
|
+
|
|
26
|
+
- New installable preset **`php-laravel`** (Cursor + Claude twins): Laravel backend/API projects — flat `app/` layout, Eloquent, Form Requests, Policies, Actions/Services, Service Providers, Jobs/Queues/Events; thin controllers with clean-architecture leanings (repositories only when justified).
|
|
27
|
+
- Always-on trio `laravel-app-core`, `architecture-boundaries`, `code-quality-and-refactoring` (session-start body budget ≤140).
|
|
28
|
+
- Rule catalog (34 stems): Laravel domain rules (`http-layer`, `form-requests`, `eloquent-persistence`, `actions-services`, `service-providers`, `policies-authorization`, `jobs-queues`, `events-listeners`, …); no `api-grpc` / `messaging-adapters` stubs (async covered by Jobs/Events); `integration-test-*` agents (no Playwright / XCUITest / a11y).
|
|
29
|
+
- Gates: `php-tooling` + `post-change-test` (prefer `php artisan test` / `composer test`; Pint/PHPStan/Psalm only if configured in repo/CI).
|
|
30
|
+
- Structure scripts include `php-laravel` (`STACKS` + `PHP_FORBIDDEN_*`); meta shared-core + embed adapters list php-laravel as 7th installable stack; chain forks pairwise vs all stacks including `php-hexagonal`.
|
|
31
|
+
- **Coexistence:** distinct install id from **`php-hexagonal`** (framework-agnostic ports/adapters PHP); comparison table in stack READMEs — neither replaces the other.
|
|
32
|
+
- Install: `npx @bonesofspring/ai-rules init cursor|claude --preset php-laravel`.
|
|
33
|
+
- Dogfood: `dogfood/php-laravel` (full `laravel/framework` via create-project; Todo API; committed `composer.lock`; P1–P3 prompts).
|
|
34
|
+
- Review follow-ups (non-blocking): secondary agents (`task-analyst`, `solution-architect`, test planners) may retain hexagonal vocabulary — Laravel pass scheduled; run `sync-dogfood-cursor.sh` before monorepo merge; `check:rule-eval` remains next-only.
|
|
35
|
+
|
|
36
|
+
### PHP hexagonal preset (`php-hexagonal`)
|
|
37
|
+
|
|
38
|
+
- New installable preset **`php-hexagonal`** (Cursor + Claude twins): PHP 8.x + Composer + PSR-4 hexagonal backends; framework-agnostic HTTP edge (Slim / Symfony HttpFoundation / Laravel HTTP as documented variants only).
|
|
39
|
+
- Always-on trio `php-app-core`, `architecture-boundaries`, `code-quality-and-refactoring` (session-start body budget ≤140).
|
|
40
|
+
- Rule catalog (34 stems) with thin stub for `api-grpc`; full `messaging-adapters` (java parity); `integration-test-*` agents (no Playwright / XCUITest / a11y).
|
|
41
|
+
- Gates: `php-tooling` + `post-change-test` (Composer / PHPUnit / Pest discovery; PHPStan/Psalm/Pint only if configured in repo/CI).
|
|
42
|
+
- Structure scripts include `php-hexagonal` (`STACKS` + `PHP_FORBIDDEN_*`); meta shared-core + embed adapters list php-hexagonal alongside go/java; chain forks pairwise vs other stacks.
|
|
43
|
+
- Install: `npx @bonesofspring/ai-rules init cursor|claude --preset php-hexagonal`.
|
|
44
|
+
- Dogfood: `dogfood/php-hexagonal` (domain → ports → HTTP/persistence/messaging adapters → composition → PHPUnit unit + integration).
|
|
45
|
+
- Review follow-ups: README titles use install name `php-hexagonal`; dogfood twin-sync paths synced; leakage checker scans `team/fixtures` (`steps[]` FAIL / `skipped[]` anti-pattern OK); composition-root HTTP integration test; AB.md PHP sample note; `check:rule-eval` documented as next-only.
|
|
46
|
+
|
|
5
47
|
### MCP TypeScript preset (`mcp-ts`)
|
|
6
48
|
|
|
7
49
|
- New installable preset **`mcp-ts`** (Cursor + Claude twins): TypeScript MCP server authoring with `@modelcontextprotocol/sdk`, stdio-first transport, Context7-only MCP, package-manager–discovered typecheck/test via `mcp-ts-tooling` / `post-change-test`.
|
package/README.md
CHANGED
|
@@ -53,7 +53,7 @@ Where things go on `init`:
|
|
|
53
53
|
|
|
54
54
|
Skills of note: `write-adr` (all stacks); `react-performance` (**next only**). Living gotchas: `team/conventions.md`. Opt-in rule samples eval: `yarn check:rule-eval` (workflow `rule-eval.yml`; not part of `check:preset-structure`).
|
|
55
55
|
|
|
56
|
-
The package ships presets including **`next`** (Next.js stack), **`ios-swift`** (iOS apps on Swift / SwiftUI), **`go`** (Go backends with hexagonal architecture), **`java`** (Java / Spring Boot hexagonal backends),
|
|
56
|
+
The package ships presets including **`next`** (Next.js stack), **`ios-swift`** (iOS apps on Swift / SwiftUI), **`go`** (Go backends with hexagonal architecture), **`java`** (Java / Spring Boot hexagonal backends), **`mcp-ts`** (TypeScript MCP servers with `@modelcontextprotocol/sdk`), **`php-hexagonal`** (PHP / Composer hexagonal backends), and **`php-laravel`** (Laravel backend/API with Eloquent, Form Requests, Policies, Actions/Services). Other preset names: see `presets/` in the [repo](https://github.com/bonesofspring/ai-rules). Name is a single path segment, no `/` or `..`.
|
|
57
57
|
|
|
58
58
|
```bash
|
|
59
59
|
npx @bonesofspring/ai-rules init cursor --preset ios-swift
|
|
@@ -64,6 +64,10 @@ npx @bonesofspring/ai-rules init cursor --preset java
|
|
|
64
64
|
npx @bonesofspring/ai-rules init claude --preset java
|
|
65
65
|
npx @bonesofspring/ai-rules init cursor --preset mcp-ts
|
|
66
66
|
npx @bonesofspring/ai-rules init claude --preset mcp-ts
|
|
67
|
+
npx @bonesofspring/ai-rules init cursor --preset php-hexagonal
|
|
68
|
+
npx @bonesofspring/ai-rules init claude --preset php-hexagonal
|
|
69
|
+
npx @bonesofspring/ai-rules init cursor --preset php-laravel
|
|
70
|
+
npx @bonesofspring/ai-rules init claude --preset php-laravel
|
|
67
71
|
```
|
|
68
72
|
|
|
69
73
|
Help: `ai-rules --help`.
|
package/bin/cli.js
CHANGED
|
@@ -74,11 +74,15 @@ Examples:
|
|
|
74
74
|
npx @bonesofspring/ai-rules init cursor --preset go
|
|
75
75
|
npx @bonesofspring/ai-rules init cursor --preset java
|
|
76
76
|
npx @bonesofspring/ai-rules init cursor --preset mcp-ts
|
|
77
|
+
npx @bonesofspring/ai-rules init cursor --preset php-hexagonal
|
|
78
|
+
npx @bonesofspring/ai-rules init cursor --preset php-laravel
|
|
77
79
|
npx @bonesofspring/ai-rules init claude
|
|
78
80
|
npx @bonesofspring/ai-rules init claude --preset ios-swift
|
|
79
81
|
npx @bonesofspring/ai-rules init claude --preset go
|
|
80
82
|
npx @bonesofspring/ai-rules init claude --preset java
|
|
81
83
|
npx @bonesofspring/ai-rules init claude --preset mcp-ts
|
|
84
|
+
npx @bonesofspring/ai-rules init claude --preset php-hexagonal
|
|
85
|
+
npx @bonesofspring/ai-rules init claude --preset php-laravel
|
|
82
86
|
npx @bonesofspring/ai-rules clean cursor
|
|
83
87
|
`);
|
|
84
88
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Shared preset core (`presets/_shared`)
|
|
2
2
|
|
|
3
|
-
Stack-agnostic **prose and checklists** for all installable presets: `next`, `ios-swift`, `go`, and `
|
|
3
|
+
Stack-agnostic **prose and checklists** for all installable presets: `next`, `ios-swift`, `go`, `java`, `mcp-ts`, and `php-hexagonal` (`cursor/<stack>`, `claude/<stack>`).
|
|
4
4
|
|
|
5
5
|
**Not an installable preset.** CLI `init` copies only under `presets/cursor/<name>/` or `presets/claude/<name>/` — this sibling is never shipped to consumer apps.
|
|
6
6
|
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
# Agent artifact contracts
|
|
2
|
+
|
|
3
|
+
Each pipeline slug has one context index and receipt ledger:
|
|
4
|
+
|
|
5
|
+
- Cursor: `.cursor/team/tasks/<slug>/artifact-manifest.json`
|
|
6
|
+
- Claude: `.claude/team/tasks/<slug>/artifact-manifest.json`
|
|
7
|
+
|
|
8
|
+
Markdown remains the narrative evidence. The manifest identifies authoritative inputs and outputs; it does not duplicate report contents or replace `pipeline.json`, `status.json`, or `metrics.json`.
|
|
9
|
+
|
|
10
|
+
## Schema v1
|
|
11
|
+
|
|
12
|
+
```json
|
|
13
|
+
{
|
|
14
|
+
"schemaVersion": 1,
|
|
15
|
+
"slug": "example-slug",
|
|
16
|
+
"updatedAt": "2026-07-31T12:00:00.000Z",
|
|
17
|
+
"artifacts": [
|
|
18
|
+
{
|
|
19
|
+
"id": "analysis",
|
|
20
|
+
"producer": "task-analyst",
|
|
21
|
+
"status": "completed",
|
|
22
|
+
"authoritativePaths": ["brief.md", "decomposition.md"],
|
|
23
|
+
"acceptanceCriteriaIds": ["AC-1"],
|
|
24
|
+
"taskIds": ["T1"],
|
|
25
|
+
"timestamps": {
|
|
26
|
+
"createdAt": "2026-07-31T11:55:00.000Z",
|
|
27
|
+
"updatedAt": "2026-07-31T12:00:00.000Z",
|
|
28
|
+
"completedAt": "2026-07-31T12:00:00.000Z"
|
|
29
|
+
},
|
|
30
|
+
"receipt": {
|
|
31
|
+
"outcome": "completed",
|
|
32
|
+
"summary": "Acceptance criteria and implementation tasks are ready.",
|
|
33
|
+
"evidencePaths": ["brief.md", "decomposition.md"]
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
]
|
|
37
|
+
}
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
### Required fields
|
|
41
|
+
|
|
42
|
+
| Location | Field | Contract |
|
|
43
|
+
|----------|-------|----------|
|
|
44
|
+
| root | `schemaVersion` | Integer `1` |
|
|
45
|
+
| root | `slug` | Matches the task directory |
|
|
46
|
+
| root | `updatedAt` | ISO 8601 timestamp of the latest manifest update |
|
|
47
|
+
| artifact | `id` | Stable, slug-local kebab-case identifier |
|
|
48
|
+
| artifact | `producer` | Agent or orchestrator role that owns this entry |
|
|
49
|
+
| artifact | `status` | `planned` \| `in_progress` \| `completed` \| `blocked` \| `superseded` |
|
|
50
|
+
| artifact | `authoritativePaths` | Non-empty paths relative to the slug directory; the current sources of truth |
|
|
51
|
+
| artifact | `acceptanceCriteriaIds` | Explicit IDs from `brief.md`; `[]` only when the task has no applicable AC |
|
|
52
|
+
| artifact | `taskIds` | Explicit IDs from `decomposition.md`; `[]` only when no decomposition task applies |
|
|
53
|
+
| artifact | `timestamps` | `createdAt`, `updatedAt`, and `completedAt` for terminal entries; ISO 8601 |
|
|
54
|
+
| artifact | `receipt` | Required when `status` is terminal (`completed`, `blocked`, or `superseded`) |
|
|
55
|
+
|
|
56
|
+
Unknown fields are ignored in schema v1 for forward compatibility. Producers must preserve entries and fields they do not own.
|
|
57
|
+
|
|
58
|
+
## Context index conventions
|
|
59
|
+
|
|
60
|
+
1. Before work, read the manifest first, then only the listed authoritative inputs needed by the current pipeline step.
|
|
61
|
+
2. Pipeline steps may declare `artifactInputIds: string[]` and, for a single producer, `artifactOutputId: string`. Parallel steps use `artifactOutputIds: Record<agent, id>` so every producer has a distinct entry. The hook includes these assignments in the handoff.
|
|
62
|
+
3. When these optional fields are omitted, use the default producer → entry map below. Repeated checkpoints for the same producer must set distinct output IDs; the fallback default is only safe when that producer has one active checkpoint in the pipeline.
|
|
63
|
+
4. If the manifest is absent or unreadable, fall back to `brief.md`, `decomposition.md`, and `pipeline.json`, then report the gap.
|
|
64
|
+
5. `authoritativePaths` points to current files, not globs and not historical alternatives. Mark an old entry `superseded` before replacing its authority.
|
|
65
|
+
6. Every applicable acceptance criterion and decomposition task ID is traceable to at least one terminal entry.
|
|
66
|
+
7. The manifest contains no prompts, secrets, report bodies, model claims, durations, or remote telemetry.
|
|
67
|
+
|
|
68
|
+
## Completion receipts
|
|
69
|
+
|
|
70
|
+
A producer finishes its step by upserting only its owned artifact entry and terminal receipt:
|
|
71
|
+
|
|
72
|
+
- `outcome`: `completed` | `blocked` | `changes_requested` | `validation_failed`
|
|
73
|
+
- `attemptId`: optional stable attempt ID supplied by the hook; when present it must match the active attempt
|
|
74
|
+
- `summary`: one short factual sentence
|
|
75
|
+
- `evidencePaths`: authoritative files that support the outcome
|
|
76
|
+
|
|
77
|
+
`changes_requested` and `validation_failed` use artifact `status: "blocked"` while retaining their distinct receipt outcome. A later successful attempt updates the same owned entry to `completed`; timestamps and evidence must reflect the latest result. Do not infer success from a Markdown filename alone.
|
|
78
|
+
|
|
79
|
+
`blocked` is terminal for the producer attempt but non-advancing for the pipeline: the hook persists `status.state` / `phase` as `blocked` and emits no next-agent handoff. A receipt must either carry the active `attemptId` or belong to the step's assigned output entry. Its terminal timestamp must be at or after the active attempt's `startedAt`; otherwise the hook keeps the attempt active in `awaiting_artifact_receipt` and does not advance or retry.
|
|
80
|
+
|
|
81
|
+
## Ownership and writes
|
|
82
|
+
|
|
83
|
+
- Agents own their output artifacts and their manifest entries/receipts. They merge by stable `id` and preserve all foreign entries.
|
|
84
|
+
- The router owns `pipeline.json` and its routing manifest entry. The analyst owns analysis entries; implementers own implementation entries; reviewers and verifiers own their report entries.
|
|
85
|
+
- The orchestration runtime/hook is the single writer for `status.json` lifecycle fields and `metrics.json`. Agents read status for eligibility but do not rewrite `pipelineIndex`, `currentAgent`, `state`, gates, retry fields, active attempts, timestamps, or metrics.
|
|
86
|
+
- On `subagentStop`, the hook reconciles the completing producer's attempt-bound or assigned-output receipt and maps `completed` / `blocked` / `changes_requested` / `validation_failed` onto `status.state` before metrics terminal events and retry/advance logic. Tasks without a readable manifest retain the host-completion fallback. Parent orchestrators must not start the next step until reconciliation lands.
|
|
87
|
+
- A producer never edits another producer's receipt. Corrections create a new owned entry or supersede an earlier entry owned by the same producer.
|
|
88
|
+
- Parallel producers need distinct entry IDs. Their parent/orchestrator serializes manifest merges; agents must not use the shared manifest as a concurrency lock.
|
|
89
|
+
|
|
90
|
+
## Default producer → entry map
|
|
91
|
+
|
|
92
|
+
| Producer | Default entry `id` | Typical authoritative paths |
|
|
93
|
+
|----------|--------------------|-----------------------------|
|
|
94
|
+
| `task-router` | `routing` | `pipeline.json` |
|
|
95
|
+
| `task-analyst` | `analysis` | `brief.md`, `decomposition.md` |
|
|
96
|
+
| `solution-architect` | `architecture` | `architecture.md` |
|
|
97
|
+
| `migration-specialist` | `migration-plan` | `migration-plan.md` |
|
|
98
|
+
| `debugger` | `debug` | `debug-report.md` |
|
|
99
|
+
| `ci-investigator` | `ci` | `ci-report.md` |
|
|
100
|
+
| `feature-developer` | `implementation` | `implementation.md` (+ changed code/tests as listed) |
|
|
101
|
+
| `build-verifier` | `validation` | `validation-report.md` |
|
|
102
|
+
| `code-reviewer` | `review` | `review.md` |
|
|
103
|
+
| `security-reviewer` | `security-review` | `security-review.md` |
|
|
104
|
+
| `accessibility-reviewer` | `a11y-review` | `a11y-review.md` |
|
|
105
|
+
| `performance-auditor` | `perf-report` | `perf-report.md` |
|
|
106
|
+
| `api-contract-reviewer` | `api-contract-review` | `api-contract-review.md` |
|
|
107
|
+
| `qa-tester` / unit or e2e planners | stack-native test IDs | plan/spec paths named in the agent prompt |
|
|
108
|
+
| `tech-writer` | `documentation` | `documentation.md` |
|
|
109
|
+
|
|
110
|
+
Use these defaults unless a step's `artifactOutputId` / `artifactOutputIds` assigns a distinct owned ID (parallel reviewers must not share one `id`). `artifactInputIds` defaults to the applicable authoritative entries already present in the manifest.
|
|
111
|
+
|
|
112
|
+
## Minimal terminal handoff
|
|
113
|
+
|
|
114
|
+
Report the owned entry ID, outcome, authoritative paths, covered AC/task IDs, and remaining gaps. The hook advances pipeline state from the terminal receipt; the agent receipt is evidence that drives the state transition, not a substitute for writing `status.json`.
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# Agent-task metrics
|
|
2
|
+
|
|
3
|
+
Metrics are local task artifacts for evaluating pipeline effectiveness. They are not remote telemetry and must never contain prompts, secrets, file paths or contents, user identifiers, model transcripts, or arbitrary error text.
|
|
4
|
+
|
|
5
|
+
## Ledger contract
|
|
6
|
+
|
|
7
|
+
Each pipeline run owns `<team>/tasks/<slug>/metrics.json`:
|
|
8
|
+
|
|
9
|
+
```json
|
|
10
|
+
{
|
|
11
|
+
"schemaVersion": 1,
|
|
12
|
+
"task": { "runId": "uuid", "slug": "example", "preset": "ai-rules", "stack": "next", "platform": "cursor", "intent": "feature", "profile": "standard" },
|
|
13
|
+
"events": []
|
|
14
|
+
}
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
`events` is append-only. A task is one `runId`; a subtask is one invocation of `pipeline.steps[i]`. Every invocation has an `attemptId`, including each member of a parallel step. Events inherit the immutable task dimensions rather than duplicating them.
|
|
18
|
+
|
|
19
|
+
Allowed event types are `task_started`, `attempt_started`, `attempt_finished`, `retry_scheduled`, `attempt_skipped`, `human_gate_started`, `human_gate_ended`, and `task_completed`. Terminal outcomes are `completed`, `changes_requested`, `validation_failed`, `skipped`, `cancelled`, or `unknown`.
|
|
20
|
+
|
|
21
|
+
## Collection policy
|
|
22
|
+
|
|
23
|
+
1. The router creates the ledger and task dimensions, then records `task_started` and an `attempt_started` immediately before every invocation.
|
|
24
|
+
2. The completion hook uses the host clock for `attempt_finished`, `task_completed`, and gate edges. It computes `durationMs` from the stored start timestamp; agents must not calculate durations or rewrite the ledger.
|
|
25
|
+
3. `status.json.activeAttempts` is a transient bridge keyed by `attemptId`; `lastCompletedAttempt` is diagnostic only. The ledger is the history authority.
|
|
26
|
+
4. A retry ends its prior attempt, emits `retry_scheduled`, then creates a new attempt number. In repeated work-package pipelines, the fix targets the nearest preceding developer step and then returns to the exact verifier/reviewer step that requested the fix. A skipped step emits `attempt_skipped`. Human-gate wait is recorded with separate start/end events and never added to attempt duration.
|
|
27
|
+
5. For parallel completion, the hook accepts a payload `attemptId` only when it directly names an active attempt. A supplied stale or unknown `attemptId` is ignored and must not fall back to another active attempt or advance the pipeline. Other runtime IDs have no verified start-time mapping and are not stored as `runtimeIdentity`. If no direct `attemptId` exists, attribute only when exactly one active attempt exists. Otherwise accept an explicit task-local completion receipt and mark it `source: "agent"` with `attributionConfidence: "fallback"`; never guess from `currentAgent`.
|
|
28
|
+
6. Writers use a per-task lock and temporary-file rename for both ledger and status updates so concurrent completions do not lose events or state. Aggregation reports missing ledgers, malformed JSON, duplicate attempt IDs, unterminated attempts, unmatched terminals, and duplicate terminals as separate incomplete-data categories; none count as a successful task.
|
|
29
|
+
|
|
30
|
+
Only allowlisted identifiers and timestamps belong in events. Use `source` (`router`, `hook`, `agent`) and `attributionConfidence` (`high`, `fallback`, `unknown`) to expose incomplete collection rather than invent precision.
|
|
@@ -28,7 +28,7 @@ Roster of specialists is **stack-specific** (agent names and write scopes differ
|
|
|
28
28
|
|
|
29
29
|
**Cursor frontmatter:** all team pipeline agents use `readonly: false` so they can write team artifacts. Production/app restrictions live in the agent prompt body — do **not** set `readonly: true`.
|
|
30
30
|
|
|
31
|
-
Full prompts: stack `agents/*.md`. Artifact conventions: stack `team/README.md
|
|
31
|
+
Full prompts: stack `agents/*.md`. Artifact conventions: stack `team/README.md`; schema SoT: **agent-artifact-contracts**.
|
|
32
32
|
|
|
33
33
|
## Dynamic pipeline
|
|
34
34
|
|
|
@@ -54,6 +54,60 @@ flowchart TD
|
|
|
54
54
|
|
|
55
55
|
**Source of truth for order:** `pipeline.json` → `steps[]`. Never hardcode analyst → dev → review → QA when `pipeline.json` exists.
|
|
56
56
|
|
|
57
|
+
## Routing decision contract
|
|
58
|
+
|
|
59
|
+
Keep top-level `profile` (`light` | `standard` | `full`) and add a top-level `routingDecision` object:
|
|
60
|
+
|
|
61
|
+
```json
|
|
62
|
+
{
|
|
63
|
+
"profile": "standard",
|
|
64
|
+
"routingDecision": {
|
|
65
|
+
"complexity": "moderate",
|
|
66
|
+
"riskFlags": ["behavior-regression"],
|
|
67
|
+
"routingReasons": [
|
|
68
|
+
"The failure needs root-cause analysis before a bounded fix.",
|
|
69
|
+
"Behavior changes require validation and independent review."
|
|
70
|
+
],
|
|
71
|
+
"estimatedWorkPackages": 1,
|
|
72
|
+
"openDecisionCount": 0
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
| Field | Contract |
|
|
78
|
+
|-------|----------|
|
|
79
|
+
| `complexity` | `low` \| `moderate` \| `high`; classify scope and coordination, not perceived coding difficulty |
|
|
80
|
+
| `riskFlags` | Array of concrete signals such as `public-contract`, `cross-layer`, `security-sensitive`, `migration`, `destructive`, `concurrency-state`, `external-dependency`, `unclear-acceptance-criteria`, `broad-test-surface`, `behavior-regression` |
|
|
81
|
+
| `routingReasons` | Non-empty, auditable facts from the request; each reason explains a profile, gate, specialist, skip, or checkpoint choice |
|
|
82
|
+
| `estimatedWorkPackages` | Integer ≥1; count meaningful independently verifiable delivery scopes, not files or agents |
|
|
83
|
+
| `openDecisionCount` | Integer ≥0; unresolved product/architecture/contract choices at routing time |
|
|
84
|
+
|
|
85
|
+
Rubric:
|
|
86
|
+
|
|
87
|
+
- `low`: one bounded scope, explicit acceptance criteria, reversible change, no risk flags or open decisions. Use `light` only when stack verification policy permits.
|
|
88
|
+
- `moderate`: several files or adjacent concerns, a regression/refactor with known boundaries, or one contained risk flag. Usually `standard`.
|
|
89
|
+
- `high`: cross-layer/public-contract work, migration/destructive/security/concurrency risk, broad test surface, multiple work packages, or unclear acceptance criteria. Usually `full`.
|
|
90
|
+
- Increase the profile when risk, open decisions, or required checkpoints demand it; do not lower complexity merely because the implementation is familiar.
|
|
91
|
+
- Do not write generic reasons such as “standard by default.” Name the observed signal and the routing consequence.
|
|
92
|
+
|
|
93
|
+
Existing pipelines without `routingDecision` remain valid; routers emit it for new pipelines. The block is documentary routing evidence in P0 and does not change hook behavior.
|
|
94
|
+
|
|
95
|
+
## Metrics lifecycle
|
|
96
|
+
|
|
97
|
+
For local metrics policy and the `metrics.json` ledger, see **agent-task-metrics**. The orchestration runtime records `task_started` and one `attempt_started` before each invocation; the hook records host-clock terminal and human-gate events. Keep active attempt identities in `status.json.activeAttempts` so parallel completions can be bound safely.
|
|
98
|
+
|
|
99
|
+
Do not calculate durations in agents. For parallel steps, never attribute a stop using `currentAgent` alone: use a stable runtime identity, the sole active attempt, or an explicit receipt marked with fallback confidence.
|
|
100
|
+
|
|
101
|
+
## Artifact context index and receipts
|
|
102
|
+
|
|
103
|
+
Each slug has one `artifact-manifest.json`: `.cursor/team/tasks/<slug>/` or `.claude/team/tasks/<slug>/`. The full schema and completion conventions live in **agent-artifact-contracts**.
|
|
104
|
+
|
|
105
|
+
- Read the manifest before broad prior-artifact discovery. Each step receives authoritative input entry IDs, owns named output entry IDs, and finishes with one terminal receipt linked to AC/task IDs.
|
|
106
|
+
- Markdown remains detailed evidence; the manifest points to authoritative paths and records producer, status, timestamps, outcome, and evidence paths.
|
|
107
|
+
- Agents upsert only entries they own and preserve foreign entries. Parallel agents use distinct IDs; the parent/orchestrator serializes manifest merges.
|
|
108
|
+
- The orchestration runtime/hook is the single writer for `status.json` lifecycle fields and `metrics.json`. Agents read status for eligibility but never rewrite unrelated state, gate, retry, attempt, timestamp, or metrics fields.
|
|
109
|
+
- Missing/stale manifests are reported as a handoff gap; fall back to `brief.md`, `decomposition.md`, and `pipeline.json` rather than inventing authority.
|
|
110
|
+
|
|
57
111
|
## status.json (pipeline mode)
|
|
58
112
|
|
|
59
113
|
```json
|
|
@@ -64,10 +118,21 @@ flowchart TD
|
|
|
64
118
|
"currentAgent": "task-analyst",
|
|
65
119
|
"phase": "executing",
|
|
66
120
|
"state": "in_progress",
|
|
67
|
-
"awaitingHumanGate": false
|
|
121
|
+
"awaitingHumanGate": false,
|
|
122
|
+
"activeAttempts": {},
|
|
123
|
+
"lastCompletedAttempt": null,
|
|
124
|
+
"parallelCompleted": [],
|
|
125
|
+
"parallelOutcomes": {}
|
|
68
126
|
}
|
|
69
127
|
```
|
|
70
128
|
|
|
129
|
+
| Field | Meaning |
|
|
130
|
+
|-------|---------|
|
|
131
|
+
| `activeAttempts` | Transient timing bridge keyed by `attemptId` |
|
|
132
|
+
| `lastCompletedAttempt` | Diagnostic pointer to the latest finished attempt |
|
|
133
|
+
| `parallelCompleted` | Agents that have stopped in the current parallel step |
|
|
134
|
+
| `parallelOutcomes` | Per-agent `{ outcome, attemptId, confidence }` for the current parallel join; cleared when the step advances or retries |
|
|
135
|
+
|
|
71
136
|
| state | Meaning |
|
|
72
137
|
|-------|---------|
|
|
73
138
|
| `in_progress` | Current step running |
|
|
@@ -76,6 +141,8 @@ flowchart TD
|
|
|
76
141
|
| `changes_requested` | Reviewer blocked; re-run developer (`retryAfterFix`) |
|
|
77
142
|
| `validation_failed` | build-verifier failed; re-run developer then build-verifier |
|
|
78
143
|
|
|
144
|
+
On each `subagentStop`, the hook reconciles `status.state` from the completing producer's terminal `artifact-manifest.json` receipt (`completed` \| `changes_requested` \| `validation_failed`) when agents left lifecycle fields untouched. Parent orchestrators must wait for that handoff before invoking the next step.
|
|
145
|
+
|
|
79
146
|
## Pipeline step options
|
|
80
147
|
|
|
81
148
|
| Field | Use |
|
|
@@ -91,7 +158,7 @@ flowchart TD
|
|
|
91
158
|
2. Read `pipeline.json` before every subagent invocation.
|
|
92
159
|
3. One role per Task call — **except** parallel steps: multiple Task calls in one message.
|
|
93
160
|
4. **Never** skip `humanGates` without `/task-continue` or explicit user approval.
|
|
94
|
-
5. Persist handoffs to disk (`brief.md`, `decomposition.md`, `debug-report.md`, `validation-report.md`, `architecture.md`, `migration-plan.md`, `ci-report.md`, `a11y-review.md`, `perf-report.md`, `security-review.md`, `api-contract-review.md`, `unit-test-plan.md`, `documentation.md`, `review.md`).
|
|
161
|
+
5. Persist handoffs to disk (`brief.md`, `decomposition.md`, `debug-report.md`, `validation-report.md`, `architecture.md`, `migration-plan.md`, `ci-report.md`, `a11y-review.md`, `perf-report.md`, `security-review.md`, `api-contract-review.md`, `unit-test-plan.md`, `documentation.md`, `review.md`) and update the producer-owned terminal receipt in `artifact-manifest.json`.
|
|
95
162
|
6. On `changes_requested` from reviewers: hook sets `retryAfterFix` → developer → same reviewer.
|
|
96
163
|
7. On `validation_failed` from `build-verifier`: hook sets `retryAfterFix: build-verifier` → developer → build-verifier.
|
|
97
164
|
8. When all steps complete, suggest `/technical-retro <slug>`.
|
|
@@ -116,7 +183,7 @@ Use Task tool or `/agent-name`. Pass: slug, artifact paths, step `scope` if set.
|
|
|
116
183
|
- **`strong`** → **never** pass `fast`; rely on agent pin or parent Max model.
|
|
117
184
|
3. Parallel steps: apply the step-level `model` to **each** agent in the array (or omit → each agent’s own frontmatter).
|
|
118
185
|
|
|
119
|
-
After each agent completes,
|
|
186
|
+
After each agent completes, verify its terminal manifest receipt, then let the orchestration runtime/hook reconcile `status.json` (`completed`, a blocking outcome, or `awaiting_approval`) from that receipt. Do not ask the agent to mutate shared lifecycle fields, and do not invoke the next specialist until the hook has written the handoff / updated `status.json`.
|
|
120
187
|
|
|
121
188
|
## Legacy mode
|
|
122
189
|
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
## Куда класть новое правило
|
|
14
14
|
|
|
15
15
|
1. Общие принципы для всех стеков → **core** + адаптеры с `<!-- shared-core: … -->`.
|
|
16
|
-
2. Только один из installable стеков (`next` / `ios-swift` / `go` / `java`) → **stack-specific** (не в `_shared`).
|
|
16
|
+
2. Только один из installable стеков (`next` / `ios-swift` / `go` / `java` / `mcp-ts` / `php-hexagonal` / `php-laravel`) → **stack-specific** (не в `_shared`).
|
|
17
17
|
3. Только Cursor или только Claude packaging → platform artifact / frontmatter, не дублировать семантику.
|
|
18
18
|
|
|
19
19
|
## SoT
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
- `next` must not require iOS-only agents/tooling (`xcuitest-*`, `xcodebuild` as required handoff, Keychain-only rules).
|
|
8
8
|
- `ios-swift` must not ship Playwright handoffs or Next lint recipes as required commands.
|
|
9
|
-
- `go` / `java` / `mcp-ts` must not ship Playwright, XCUITest, Next lint recipes, or `xcodebuild`/`SwiftLint` as required handoffs.
|
|
9
|
+
- `go` / `java` / `php-hexagonal` / `php-laravel` / `mcp-ts` must not ship Playwright, XCUITest, Next lint recipes, or `xcodebuild`/`SwiftLint` as required handoffs.
|
|
10
10
|
- `mcp-ts` must not ship Go tool commands (`go test`, `go vet`, `golangci-lint`) or `integration-test-*` agents as required delivery gates.
|
|
11
11
|
- Shared core must not embed stack paths (`app/src/**`, `Features/**`, `playwright`, `xcodebuild`).
|
|
12
12
|
|
|
@@ -25,16 +25,16 @@ Required instead: `xcuitest-test-*` stems; build-verifier mentions `xcodebuild`
|
|
|
25
25
|
- `xcuitest-test-` as handoff stems
|
|
26
26
|
- Requiring `xcodebuild` / SwiftLint as the default post-change gate for Next app work
|
|
27
27
|
|
|
28
|
-
## Forbidden in go / java hooks/agents (FAIL)
|
|
28
|
+
## Forbidden in go / java / php-hexagonal / php-laravel hooks/agents (FAIL)
|
|
29
29
|
|
|
30
|
-
Shared backend-stack bans (
|
|
30
|
+
Shared backend-stack bans (`go`, `java`, `php-hexagonal`, and `php-laravel`):
|
|
31
31
|
|
|
32
32
|
- `playwright-test-`, `playwright-e2e`, `user-playwright`, `app/__tests__/e2e`
|
|
33
33
|
- Positive yarn recipes `lint:js` / `lint:css`
|
|
34
34
|
- `xcuitest-test-`, `xcodebuild`, `SwiftLint` as required handoffs
|
|
35
35
|
- Agent file `accessibility-reviewer` (no UI surface)
|
|
36
36
|
|
|
37
|
-
Required instead: `integration-test-*`; build-verifier / `post-change-test` plus stack tooling — `go-tooling` (`go test`, `go vet`)
|
|
37
|
+
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`).
|
|
38
38
|
|
|
39
39
|
## Forbidden in mcp-ts hooks/agents (FAIL)
|
|
40
40
|
|
|
@@ -55,4 +55,4 @@ Required instead: package-manager–discovered typecheck/test (`mcp-ts-tooling`,
|
|
|
55
55
|
|
|
56
56
|
## Chain fork
|
|
57
57
|
|
|
58
|
-
`hooks/chain-team-phases.sh` must differ **byte-wise** pairwise among `next`, `ios-swift`, `go`, `java`,
|
|
58
|
+
`hooks/chain-team-phases.sh` must differ **byte-wise** pairwise among `next`, `ios-swift`, `go`, `java`, `mcp-ts`, `php-hexagonal`, and `php-laravel` (per platform).
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
- [ ] **SoT:** правки в `packages/…` (не только root `.cursor/`)
|
|
8
8
|
- [ ] **Core:** если менялся `_shared/core/**` — обновлены все `<!-- shared-core: … -->` consumers (или documented intentional fork)
|
|
9
|
-
- [ ] **Twin:** Cursor change → Claude twin **same PR** (**FAIL** if missing on next, ios-swift, go, and
|
|
9
|
+
- [ ] **Twin:** Cursor change → Claude twin **same PR** (**FAIL** if missing on next, ios-swift, go, java, mcp-ts, php-hexagonal, and php-laravel — см. `preset-twin-sync`)
|
|
10
10
|
- [ ] **Mapping:** `claude/<stack>/rules/README.md` mapping table актуален
|
|
11
11
|
- [ ] **Token budget:** alwaysApply / session-start ≤ 3; meta rules not always-on
|
|
12
12
|
- [ ] **Leakage:** нет чужих stack agent stems / handoff strings (`preset-no-cross-stack-leakage`)
|
|
@@ -11,6 +11,8 @@ Cursor `.mdc` — **SoT per stack**. Claude topic `.md` — derived twin.
|
|
|
11
11
|
| `go` | `presets/cursor/go/rules/*.mdc` | `presets/claude/go/rules/<topic>/` | Keep in `claude/go/rules/README.md` |
|
|
12
12
|
| `java` | `presets/cursor/java/rules/*.mdc` | `presets/claude/java/rules/<topic>/` | Keep in `claude/java/rules/README.md` |
|
|
13
13
|
| `mcp-ts` | `presets/cursor/mcp-ts/rules/*.mdc` | `presets/claude/mcp-ts/rules/<topic>/` | Keep in `claude/mcp-ts/rules/README.md` |
|
|
14
|
+
| `php-hexagonal` | `presets/cursor/php-hexagonal/rules/*.mdc` | `presets/claude/php-hexagonal/rules/<topic>/` | Keep in `claude/php-hexagonal/rules/README.md` |
|
|
15
|
+
| `php-laravel` | `presets/cursor/php-laravel/rules/*.mdc` | `presets/claude/php-laravel/rules/<topic>/` | Keep in `claude/php-laravel/rules/README.md` |
|
|
14
16
|
|
|
15
17
|
## Same-PR checklist
|
|
16
18
|
|
|
@@ -31,5 +33,7 @@ Cursor `.mdc` — **SoT per stack**. Claude topic `.md` — derived twin.
|
|
|
31
33
|
- **go:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift; mapping table required).
|
|
32
34
|
- **java:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go; mapping table required).
|
|
33
35
|
- **mcp-ts:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java; mapping table required).
|
|
36
|
+
- **php-hexagonal:** missing Claude twin for a changed Cursor rule → **FAIL** (same as next / ios-swift / go / java / mcp-ts; mapping table required).
|
|
37
|
+
- **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).
|
|
34
38
|
|
|
35
39
|
Dogfood: sync packages → root `.cursor/` after Cursor SoT changes (not the reverse). Use `packages/ai-rules/scripts/sync-dogfood-cursor.sh`.
|
|
@@ -4,4 +4,6 @@
|
|
|
4
4
|
|
|
5
5
|
**`commands/technical-retro.md`** → `/technical-retro`
|
|
6
6
|
|
|
7
|
+
When a task has `metrics.json`, use the local aggregation script and state the cohort, sample size, incomplete artifacts, attribution confidence, active attempt duration, and human-gate wait separately. Do not score malformed artifacts or gate wait as agent work.
|
|
8
|
+
|
|
7
9
|
Используй rule только если command недоступен. Не дублируй содержимое command в ответе — следуй command-файлу и skill `technical-retro`.
|
|
@@ -12,8 +12,8 @@ You are the build verifier for **Go hexagonal** services (and for **ai-rules pre
|
|
|
12
12
|
1. Run from module root: `go test ./...`, `go vet ./...`.
|
|
13
13
|
2. If present: `golangci-lint` / `staticcheck` per repo docs (`go-tooling`, `post-change-test`).
|
|
14
14
|
3. Optional `-race` when concurrency touched.
|
|
15
|
-
4. Write `.
|
|
16
|
-
5. On failure:
|
|
15
|
+
4. Write `.claude/team/tasks/<slug>/validation-report.md` with commands + results.
|
|
16
|
+
5. On failure: emit receipt outcome `validation_failed` — do **not** patch production code (developer retries).
|
|
17
17
|
|
|
18
18
|
**Never** require Playwright, XCUITest, `lint:js`/`lint:css`, or `xcodebuild`/`SwiftLint` as the Go gate.
|
|
19
19
|
|
|
@@ -29,7 +29,14 @@ Hard gates: twin-map (stacks include **go**), token-budget (alwaysApply/session-
|
|
|
29
29
|
|
|
30
30
|
Document PASS/FAIL in `validation-report.md`.
|
|
31
31
|
|
|
32
|
-
1. **Root AGENTS template:** each installable preset (`cursor|claude` × `next|ios-swift|go|java`) must ship `REPO_AGENTS.md` when validating preset packaging → **FAIL** if missing.
|
|
32
|
+
1. **Root AGENTS template:** each installable preset (`cursor|claude` × `next|ios-swift|go|java|mcp-ts|php-hexagonal`) must ship `REPO_AGENTS.md` when validating preset packaging → **FAIL** if missing.
|
|
33
33
|
2. **Hooks cookbook:** default `hooks.json` must **not** reference `hooks/examples/` → **FAIL** if it does.
|
|
34
|
-
3. **No react-performance on ios/go/java:** skill directory / required handoff must be absent under ios-swift, go, and
|
|
34
|
+
3. **No react-performance on ios/go/java:** skill directory / required handoff must be absent under ios-swift, go, java, mcp-ts, php-hexagonal, and php-laravel → **FAIL** (leakage). Prefer `check:preset-leakage`.
|
|
35
35
|
4. **Rule eval (WARN):** `scripts/check-rule-eval.mjs` / `yarn check:rule-eval` should exist for maintainers; smoke optional. Hard fail only when the opt-in eval job runs — not part of default `check:preset-structure`.
|
|
36
|
+
|
|
37
|
+
## Artifact contract
|
|
38
|
+
|
|
39
|
+
- **Authoritative inputs:** read `.claude/team/tasks/<slug>/artifact-manifest.json` first; consume handoff `artifactInputIds` when supplied, otherwise consume the manifest entries for brief/decomposition, implementation evidence, pipeline scope, and changed files.
|
|
40
|
+
- **Owned outputs:** `validation-report.md`; upsert only the manifest entry assigned by handoff (`artifactOutputId`; fallback `validation`) and preserve all foreign entries.
|
|
41
|
+
- **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.
|
|
42
|
+
- **Shared state:** never create or mutate `status.json` or `metrics.json`; the orchestration runtime/hook owns lifecycle, gates, retries, attempts, and timestamps.
|
|
@@ -33,8 +33,15 @@ Apply skill `code-review` and `code-review-mr.mdc`. Weigh `architecture-boundari
|
|
|
33
33
|
|
|
34
34
|
## Artifact
|
|
35
35
|
|
|
36
|
-
Write `.claude/team/tasks/<slug>/review.md` with verdict APPROVE | REQUEST_CHANGES, findings by severity, AC coverage. Update
|
|
36
|
+
Write `.claude/team/tasks/<slug>/review.md` with verdict APPROVE | REQUEST_CHANGES, findings by severity, AC coverage. Update the owned terminal receipt accordingly.
|
|
37
37
|
|
|
38
38
|
## Design guidance
|
|
39
39
|
|
|
40
40
|
- Load `design-guidance` (rule stem) when assessing structure, smells, or pattern fit.
|
|
41
|
+
|
|
42
|
+
## Artifact contract
|
|
43
|
+
|
|
44
|
+
- **Authoritative inputs:** read `.claude/team/tasks/<slug>/artifact-manifest.json` first; consume handoff `artifactInputIds` when supplied, otherwise consume the manifest entries for brief/decomposition, implementation, validation evidence, and the scoped git diff.
|
|
45
|
+
- **Owned outputs:** `review.md`; upsert only the manifest entry assigned by handoff (`artifactOutputId`; fallback `review`) and preserve all foreign entries.
|
|
46
|
+
- **Terminal receipt:** cover applicable AC/task IDs, list authoritative evidence paths, and emit `completed` or `changes_requested`. Bind it to the supplied `attemptId` when present.
|
|
47
|
+
- **Shared state:** never create or mutate `status.json` or `metrics.json`; the orchestration runtime/hook owns lifecycle, gates, retries, attempts, and timestamps.
|
|
@@ -36,7 +36,7 @@ Implement Go features following hexagonal boundaries.
|
|
|
36
36
|
|
|
37
37
|
When editing ai-rules `presets/**/go/**`, keep Cursor/Claude twins in sync and preserve chain fork ≠ next/ios-swift.
|
|
38
38
|
|
|
39
|
-
Update `.claude/team/tasks/<slug>/implementation.md` and
|
|
39
|
+
Update `.claude/team/tasks/<slug>/implementation.md` and the owned implementation receipt.
|
|
40
40
|
|
|
41
41
|
## Design guidance
|
|
42
42
|
|
|
@@ -45,3 +45,10 @@ Update `.claude/team/tasks/<slug>/implementation.md` and `status.json`.
|
|
|
45
45
|
## Anti-sycophancy discipline
|
|
46
46
|
|
|
47
47
|
- When writing or changing code, load / follow rule `anti-sycophancy-discipline`.
|
|
48
|
+
|
|
49
|
+
## Artifact contract
|
|
50
|
+
|
|
51
|
+
- **Authoritative inputs:** read `.claude/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.
|
|
52
|
+
- **Owned outputs:** `implementation.md` plus changed implementation/test paths; upsert only the manifest entry assigned by handoff (`artifactOutputId`; fallback `implementation`) and preserve all foreign entries.
|
|
53
|
+
- **Terminal receipt:** cover applicable AC/task IDs, list authoritative evidence paths, and emit `completed` or `blocked`. Bind it to the supplied `attemptId` when present.
|
|
54
|
+
- **Shared state:** never create or mutate `status.json` or `metrics.json`; the orchestration runtime/hook owns lifecycle, gates, retries, attempts, and timestamps.
|
|
@@ -18,8 +18,15 @@ Use domain, application/ports, driving/driven adapters, composition root — not
|
|
|
18
18
|
|
|
19
19
|
## Gates
|
|
20
20
|
|
|
21
|
-
|
|
21
|
+
Emit an analysis receipt; the runtime applies any configured human gate.
|
|
22
22
|
|
|
23
23
|
## Design guidance (optional)
|
|
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
|
+
|
|
27
|
+
## Artifact contract
|
|
28
|
+
|
|
29
|
+
- **Authoritative inputs:** read `.claude/team/tasks/<slug>/artifact-manifest.json` first; consume `pipeline.json`, the manifest routing entry, user-approved decisions, and any authoritative architecture/approval entries.
|
|
30
|
+
- **Owned outputs:** `brief.md` and `decomposition.md`; upsert only the manifest entry assigned by handoff (`artifactOutputId`; fallback `analysis`) and preserve all foreign entries.
|
|
31
|
+
- **Terminal receipt:** cover applicable AC/task IDs, list authoritative evidence paths, and emit `completed` or `blocked`. Bind it to the supplied `attemptId` when present.
|
|
32
|
+
- **Shared state:** never create or mutate `status.json` or `metrics.json`; the orchestration runtime/hook owns lifecycle, gates, retries, attempts, and timestamps.
|
|
@@ -10,7 +10,7 @@ You are a task router for a **Go hexagonal backend** agent team. You **do not**
|
|
|
10
10
|
## Inputs
|
|
11
11
|
|
|
12
12
|
- User task description (from `/task` or orchestrator).
|
|
13
|
-
- Optional: existing files under `.
|
|
13
|
+
- Optional: existing files under `.claude/team/tasks/<slug>/`.
|
|
14
14
|
- Pipeline JSON schema — **`agents/README.md`**.
|
|
15
15
|
|
|
16
16
|
## Intent detection
|
|
@@ -39,6 +39,27 @@ You are a task router for a **Go hexagonal backend** agent team. You **do not**
|
|
|
39
39
|
|
|
40
40
|
**Never skip `build-verifier`** after developer when Go sources changed.
|
|
41
41
|
|
|
42
|
+
## Routing decision rubric
|
|
43
|
+
|
|
44
|
+
Keep top-level `profile` and emit this top-level object in every new `pipeline.json`:
|
|
45
|
+
|
|
46
|
+
```json
|
|
47
|
+
"routingDecision": {
|
|
48
|
+
"complexity": "low | moderate | high",
|
|
49
|
+
"riskFlags": [],
|
|
50
|
+
"routingReasons": ["Concrete request signal and its routing consequence."],
|
|
51
|
+
"estimatedWorkPackages": 1,
|
|
52
|
+
"openDecisionCount": 0
|
|
53
|
+
}
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
- `low`: one bounded layer/file set, explicit AC, reversible, no risk flags/open decisions → `light` when verification policy permits.
|
|
57
|
+
- `moderate`: adjacent concerns or a regression/refactor with known boundaries → usually `standard`.
|
|
58
|
+
- `high`: cross-layer/public contract, security, migration/destructive or concurrency/state risk, broad integration-test surface, unclear AC, or multiple work packages → usually `full`.
|
|
59
|
+
- Use concrete flags: `public-contract`, `cross-layer`, `security-sensitive`, `migration`, `destructive`, `concurrency-state`, `external-dependency`, `unclear-acceptance-criteria`, `broad-test-surface`, `behavior-regression`.
|
|
60
|
+
- `routingReasons` must be non-empty and explain profile, gates, specialists, skips, or checkpoints; never write “standard by default.”
|
|
61
|
+
- `estimatedWorkPackages` is an integer ≥1; `openDecisionCount` is an integer ≥0. Do not lower complexity because implementation is familiar.
|
|
62
|
+
|
|
42
63
|
## Model tiers (`steps[].model`)
|
|
43
64
|
|
|
44
65
|
Optional: `"model": "cheap" | "standard" | "strong"`. Same policy as other presets:
|
|
@@ -47,7 +68,7 @@ Optional: `"model": "cheap" | "standard" | "strong"`. Same policy as other prese
|
|
|
47
68
|
- `full` / `spike` / security|perf specialists → `strong` on architect, migration, security, perf steps
|
|
48
69
|
- never `strong` on build-verifier / tech-writer / task-router
|
|
49
70
|
|
|
50
|
-
Fixtures: `.
|
|
71
|
+
Fixtures: `.claude/team/fixtures/` (feature-full, feature-light, bugfix-standard).
|
|
51
72
|
|
|
52
73
|
## humanGates (defaults)
|
|
53
74
|
|
|
@@ -62,8 +83,19 @@ Fixtures: `.cursor/team/fixtures/` (feature-full, feature-light, bugfix-standard
|
|
|
62
83
|
|
|
63
84
|
## Output
|
|
64
85
|
|
|
65
|
-
Write `.
|
|
86
|
+
Write `.claude/team/tasks/<slug>/pipeline.json` and initialize the routing entry in `artifact-manifest.json`; set `.claude/team/active-task.json`. The orchestration runtime creates and owns `status.json`.
|
|
66
87
|
|
|
67
88
|
## Handoff
|
|
68
89
|
|
|
69
90
|
Intent + steps table + skipped + gates → invoke `steps[0].agent` (unless retro).
|
|
91
|
+
|
|
92
|
+
## Runtime initialization
|
|
93
|
+
|
|
94
|
+
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.
|
|
95
|
+
|
|
96
|
+
## Artifact contract
|
|
97
|
+
|
|
98
|
+
- **Authoritative inputs:** read `.claude/team/tasks/<slug>/artifact-manifest.json` first; consume the user request and any existing authoritative task/decision entries.
|
|
99
|
+
- **Owned outputs:** `pipeline.json` and the routing manifest entry; upsert only the manifest entry assigned by handoff (`artifactOutputId`; fallback `routing`) and preserve all foreign entries.
|
|
100
|
+
- **Terminal receipt:** cover applicable AC/task IDs, list authoritative evidence paths, and emit `completed` or `blocked`. Bind it to the supplied `attemptId` when present.
|
|
101
|
+
- **Shared state:** never create or mutate `status.json` or `metrics.json`; the orchestration runtime/hook owns lifecycle, gates, retries, attempts, and timestamps.
|