universal-dev-standards 5.0.0-rc.8 → 5.0.0
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/bin/uds.js +5 -3
- package/bundled/ai/standards/acceptance-criteria-traceability.ai.yaml +178 -0
- package/bundled/ai/standards/agent-dispatch.ai.yaml +69 -0
- package/bundled/ai/standards/ai-command-behavior.ai.yaml +45 -0
- package/bundled/ai/standards/api-design-standards.ai.yaml +192 -0
- package/bundled/ai/standards/branch-completion.ai.yaml +82 -0
- package/bundled/ai/standards/change-batching-standards.ai.yaml +195 -0
- package/bundled/ai/standards/database-standards.ai.yaml +220 -0
- package/bundled/ai/standards/error-codes.ai.yaml +37 -2
- package/bundled/ai/standards/git-worktree.ai.yaml +77 -0
- package/bundled/ai/standards/logging.ai.yaml +21 -2
- package/bundled/ai/standards/model-selection.ai.yaml +81 -0
- package/bundled/ai/standards/pipeline-integration-standards.ai.yaml +184 -0
- package/bundled/ai/standards/systematic-debugging.ai.yaml +73 -0
- package/bundled/ai/standards/verification-evidence.ai.yaml +84 -0
- package/bundled/ai/standards/workflow-enforcement.ai.yaml +253 -0
- package/bundled/core/acceptance-criteria-traceability.md +293 -0
- package/bundled/core/agent-dispatch.md +149 -0
- package/bundled/core/ai-command-behavior.md +239 -0
- package/bundled/core/api-design-standards.md +938 -0
- package/bundled/core/branch-completion.md +158 -0
- package/bundled/core/change-batching-standards.md +257 -0
- package/bundled/core/checkin-standards.md +43 -6
- package/bundled/core/database-standards.md +828 -0
- package/bundled/core/error-code-standards.md +228 -2
- package/bundled/core/forward-derivation-standards.md +54 -2
- package/bundled/core/git-worktree.md +131 -0
- package/bundled/core/model-selection.md +153 -0
- package/bundled/core/pipeline-integration-standards.md +230 -0
- package/bundled/core/systematic-debugging.md +156 -0
- package/bundled/core/testing-standards.md +49 -39
- package/bundled/core/verification-evidence.md +172 -0
- package/bundled/core/workflow-enforcement.md +132 -0
- package/bundled/locales/zh-CN/CLAUDE.md +2 -2
- package/bundled/locales/zh-CN/README.md +4 -4
- package/bundled/locales/zh-CN/SECURITY.md +92 -0
- package/bundled/locales/zh-CN/core/acceptance-criteria-traceability.md +301 -0
- package/bundled/locales/zh-CN/core/acceptance-test-driven-development.md +47 -0
- package/bundled/locales/zh-CN/core/accessibility-standards.md +124 -0
- package/bundled/locales/zh-CN/core/agent-dispatch.md +113 -0
- package/bundled/locales/zh-CN/core/ai-agreement-standards.md +103 -0
- package/bundled/locales/zh-CN/core/ai-command-behavior.md +247 -0
- package/bundled/locales/zh-CN/core/api-design-standards.md +946 -0
- package/bundled/locales/zh-CN/core/behavior-driven-development.md +48 -0
- package/bundled/locales/zh-CN/core/branch-completion.md +112 -0
- package/bundled/locales/zh-CN/core/change-batching-standards.md +265 -0
- package/bundled/locales/zh-CN/core/checkin-standards.md +43 -5
- package/bundled/locales/zh-CN/core/context-aware-loading.md +106 -0
- package/bundled/locales/zh-CN/core/database-standards.md +836 -0
- package/bundled/locales/zh-CN/core/deployment-standards.md +80 -0
- package/bundled/locales/zh-CN/core/error-code-standards.md +2 -2
- package/bundled/locales/zh-CN/core/forward-derivation-standards.md +493 -0
- package/bundled/locales/zh-CN/core/git-worktree.md +101 -0
- package/bundled/locales/zh-CN/core/model-selection.md +112 -0
- package/bundled/locales/zh-CN/core/performance-standards.md +104 -0
- package/bundled/locales/zh-CN/core/pipeline-integration-standards.md +238 -0
- package/bundled/locales/zh-CN/core/project-context-memory.md +124 -0
- package/bundled/locales/zh-CN/core/requirement-engineering.md +49 -0
- package/bundled/locales/zh-CN/core/security-standards.md +100 -0
- package/bundled/locales/zh-CN/core/systematic-debugging.md +106 -0
- package/bundled/locales/zh-CN/core/test-governance.md +116 -0
- package/bundled/locales/zh-CN/core/testing-standards.md +392 -156
- package/bundled/locales/zh-CN/core/verification-evidence.md +118 -0
- package/bundled/locales/zh-CN/core/virtual-organization-standards.md +104 -0
- package/bundled/locales/zh-CN/core/workflow-enforcement.md +132 -0
- package/bundled/locales/zh-CN/docs/CHEATSHEET.md +27 -1
- package/bundled/locales/zh-CN/docs/CLI-INIT-OPTIONS.md +9 -1
- package/bundled/locales/zh-CN/docs/FEATURE-REFERENCE.md +37 -9
- package/bundled/locales/zh-CN/docs/USER-MANUAL.md +652 -0
- package/bundled/locales/zh-CN/integrations/github-copilot/copilot-instructions.md +1 -1
- package/bundled/locales/zh-CN/integrations/openspec/AGENTS.md +29 -4
- package/bundled/locales/zh-CN/integrations/spec-kit/AGENTS.md +143 -72
- package/bundled/locales/zh-CN/skills/ac-coverage-assistant/SKILL.md +126 -0
- package/bundled/locales/zh-CN/skills/api-design-assistant/SKILL.md +100 -0
- package/bundled/locales/zh-CN/skills/brainstorm-assistant/SKILL.md +119 -0
- package/bundled/locales/zh-CN/skills/ci-cd-assistant/SKILL.md +82 -0
- package/bundled/locales/zh-CN/skills/commands/ac-coverage.md +97 -0
- package/bundled/locales/zh-CN/skills/commands/api-design.md +94 -0
- package/bundled/locales/zh-CN/skills/commands/atdd.md +163 -0
- package/bundled/locales/zh-CN/skills/commands/audit.md +77 -0
- package/bundled/locales/zh-CN/skills/commands/bdd.md +1 -1
- package/bundled/locales/zh-CN/skills/commands/brainstorm.md +87 -0
- package/bundled/locales/zh-CN/skills/commands/changelog.md +63 -0
- package/bundled/locales/zh-CN/skills/commands/check.md +219 -0
- package/bundled/locales/zh-CN/skills/commands/checkin.md +61 -0
- package/bundled/locales/zh-CN/skills/commands/ci-cd.md +77 -0
- package/bundled/locales/zh-CN/skills/commands/commit.md +81 -0
- package/bundled/locales/zh-CN/skills/commands/config.md +207 -0
- package/bundled/locales/zh-CN/skills/commands/coverage.md +74 -0
- package/bundled/locales/zh-CN/skills/commands/database.md +78 -0
- package/bundled/locales/zh-CN/skills/commands/derive-all.md +58 -0
- package/bundled/locales/zh-CN/skills/commands/derive-atdd.md +54 -0
- package/bundled/locales/zh-CN/skills/commands/derive-bdd.md +53 -0
- package/bundled/locales/zh-CN/skills/commands/derive-tdd.md +54 -0
- package/bundled/locales/zh-CN/skills/commands/derive.md +78 -0
- package/bundled/locales/zh-CN/skills/commands/dev-workflow.md +119 -0
- package/bundled/locales/zh-CN/skills/commands/discover.md +86 -0
- package/bundled/locales/zh-CN/skills/commands/docgen.md +67 -0
- package/bundled/locales/zh-CN/skills/commands/docs.md +65 -0
- package/bundled/locales/zh-CN/skills/commands/durable.md +87 -0
- package/bundled/locales/zh-CN/skills/commands/guide.md +52 -0
- package/bundled/locales/zh-CN/skills/commands/incident.md +92 -0
- package/bundled/locales/zh-CN/skills/commands/init.md +272 -0
- package/bundled/locales/zh-CN/skills/commands/methodology.md +1 -1
- package/bundled/locales/zh-CN/skills/commands/metrics.md +73 -0
- package/bundled/locales/zh-CN/skills/commands/migrate.md +92 -0
- package/bundled/locales/zh-CN/skills/commands/pr.md +80 -0
- package/bundled/locales/zh-CN/skills/commands/refactor.md +1 -1
- package/bundled/locales/zh-CN/skills/commands/release.md +62 -0
- package/bundled/locales/zh-CN/skills/commands/requirement.md +54 -0
- package/bundled/locales/zh-CN/skills/commands/reverse-bdd.md +47 -0
- package/bundled/locales/zh-CN/skills/commands/reverse-sdd.md +51 -0
- package/bundled/locales/zh-CN/skills/commands/reverse-tdd.md +51 -0
- package/bundled/locales/zh-CN/skills/commands/reverse.md +63 -0
- package/bundled/locales/zh-CN/skills/commands/review.md +50 -0
- package/bundled/locales/zh-CN/skills/commands/scan.md +76 -0
- package/bundled/locales/zh-CN/skills/commands/sdd-retro.md +40 -0
- package/bundled/locales/zh-CN/skills/commands/sdd.md +379 -0
- package/bundled/locales/zh-CN/skills/commands/security.md +75 -0
- package/bundled/locales/zh-CN/skills/commands/tdd.md +111 -0
- package/bundled/locales/zh-CN/skills/commands/update.md +337 -0
- package/bundled/locales/zh-CN/skills/commit-standards/SKILL.md +1 -2
- package/bundled/locales/zh-CN/skills/database-assistant/SKILL.md +97 -0
- package/bundled/locales/zh-CN/skills/dev-workflow-guide/SKILL.md +145 -0
- package/bundled/locales/zh-CN/skills/durable-execution-assistant/SKILL.md +84 -0
- package/bundled/locales/zh-CN/skills/incident-response-assistant/SKILL.md +107 -0
- package/bundled/locales/zh-CN/skills/metrics-dashboard-assistant/SKILL.md +67 -0
- package/bundled/locales/zh-CN/skills/migration-assistant/SKILL.md +77 -0
- package/bundled/locales/zh-CN/skills/pr-automation-assistant/SKILL.md +90 -0
- package/bundled/locales/zh-CN/skills/security-assistant/SKILL.md +79 -0
- package/bundled/locales/zh-CN/skills/security-scan-assistant/SKILL.md +72 -0
- package/bundled/locales/zh-CN/skills/spec-driven-dev/SKILL.md +73 -10
- package/bundled/locales/zh-CN/skills/spec-driven-dev/guide.md +267 -122
- package/bundled/locales/zh-TW/CLAUDE.md +2 -2
- package/bundled/locales/zh-TW/README.md +4 -4
- package/bundled/locales/zh-TW/SECURITY.md +92 -0
- package/bundled/locales/zh-TW/core/acceptance-criteria-traceability.md +301 -0
- package/bundled/locales/zh-TW/core/acceptance-test-driven-development.md +47 -0
- package/bundled/locales/zh-TW/core/accessibility-standards.md +84 -0
- package/bundled/locales/zh-TW/core/agent-dispatch.md +89 -0
- package/bundled/locales/zh-TW/core/ai-agreement-standards.md +87 -0
- package/bundled/locales/zh-TW/core/ai-command-behavior.md +247 -0
- package/bundled/locales/zh-TW/core/api-design-standards.md +946 -0
- package/bundled/locales/zh-TW/core/behavior-driven-development.md +63 -0
- package/bundled/locales/zh-TW/core/branch-completion.md +76 -0
- package/bundled/locales/zh-TW/core/change-batching-standards.md +265 -0
- package/bundled/locales/zh-TW/core/checkin-standards.md +39 -5
- package/bundled/locales/zh-TW/core/context-aware-loading.md +86 -0
- package/bundled/locales/zh-TW/core/database-standards.md +836 -0
- package/bundled/locales/zh-TW/core/deployment-standards.md +66 -0
- package/bundled/locales/zh-TW/core/error-code-standards.md +230 -4
- package/bundled/locales/zh-TW/core/forward-derivation-standards.md +62 -2
- package/bundled/locales/zh-TW/core/git-worktree.md +104 -0
- package/bundled/locales/zh-TW/core/model-selection.md +83 -0
- package/bundled/locales/zh-TW/core/performance-standards.md +84 -0
- package/bundled/locales/zh-TW/core/pipeline-integration-standards.md +238 -0
- package/bundled/locales/zh-TW/core/project-context-memory.md +79 -0
- package/bundled/locales/zh-TW/core/requirement-engineering.md +79 -0
- package/bundled/locales/zh-TW/core/security-standards.md +74 -0
- package/bundled/locales/zh-TW/core/systematic-debugging.md +95 -0
- package/bundled/locales/zh-TW/core/test-governance.md +88 -0
- package/bundled/locales/zh-TW/core/testing-standards.md +309 -86
- package/bundled/locales/zh-TW/core/verification-evidence.md +94 -0
- package/bundled/locales/zh-TW/core/virtual-organization-standards.md +88 -0
- package/bundled/locales/zh-TW/core/workflow-enforcement.md +132 -0
- package/bundled/locales/zh-TW/docs/CHEATSHEET.md +27 -1
- package/bundled/locales/zh-TW/docs/CLI-INIT-OPTIONS.md +9 -1
- package/bundled/locales/zh-TW/docs/FEATURE-REFERENCE.md +37 -9
- package/bundled/locales/zh-TW/docs/USER-MANUAL.md +652 -0
- package/bundled/locales/zh-TW/integrations/github-copilot/copilot-instructions.md +1 -1
- package/bundled/locales/zh-TW/integrations/openspec/AGENTS.md +29 -4
- package/bundled/locales/zh-TW/integrations/spec-kit/AGENTS.md +142 -71
- package/bundled/locales/zh-TW/skills/ac-coverage-assistant/SKILL.md +127 -0
- package/bundled/locales/zh-TW/skills/ai-friendly-architecture/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/ai-instruction-standards/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/api-design-assistant/SKILL.md +97 -0
- package/bundled/locales/zh-TW/skills/atdd-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/audit-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/bdd-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/brainstorm-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/changelog-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/checkin-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/ci-cd-assistant/SKILL.md +79 -0
- package/bundled/locales/zh-TW/skills/code-review-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/commands/ac-coverage.md +95 -0
- package/bundled/locales/zh-TW/skills/commands/api-design.md +92 -0
- package/bundled/locales/zh-TW/skills/commands/atdd.md +167 -0
- package/bundled/locales/zh-TW/skills/commands/audit.md +75 -0
- package/bundled/locales/zh-TW/skills/commands/bdd.md +1 -1
- package/bundled/locales/zh-TW/skills/commands/brainstorm.md +91 -0
- package/bundled/locales/zh-TW/skills/commands/changelog.md +67 -0
- package/bundled/locales/zh-TW/skills/commands/check.md +223 -0
- package/bundled/locales/zh-TW/skills/commands/checkin.md +65 -0
- package/bundled/locales/zh-TW/skills/commands/ci-cd.md +75 -0
- package/bundled/locales/zh-TW/skills/commands/commit.md +85 -0
- package/bundled/locales/zh-TW/skills/commands/config.md +211 -0
- package/bundled/locales/zh-TW/skills/commands/coverage.md +78 -0
- package/bundled/locales/zh-TW/skills/commands/database.md +76 -0
- package/bundled/locales/zh-TW/skills/commands/derive-all.md +62 -0
- package/bundled/locales/zh-TW/skills/commands/derive-atdd.md +58 -0
- package/bundled/locales/zh-TW/skills/commands/derive-bdd.md +54 -0
- package/bundled/locales/zh-TW/skills/commands/derive-tdd.md +55 -0
- package/bundled/locales/zh-TW/skills/commands/derive.md +79 -0
- package/bundled/locales/zh-TW/skills/commands/dev-workflow.md +120 -0
- package/bundled/locales/zh-TW/skills/commands/discover.md +87 -0
- package/bundled/locales/zh-TW/skills/commands/docgen.md +68 -0
- package/bundled/locales/zh-TW/skills/commands/docs.md +66 -0
- package/bundled/locales/zh-TW/skills/commands/durable.md +85 -0
- package/bundled/locales/zh-TW/skills/commands/guide.md +51 -0
- package/bundled/locales/zh-TW/skills/commands/incident.md +90 -0
- package/bundled/locales/zh-TW/skills/commands/init.md +273 -0
- package/bundled/locales/zh-TW/skills/commands/methodology.md +1 -1
- package/bundled/locales/zh-TW/skills/commands/metrics.md +71 -0
- package/bundled/locales/zh-TW/skills/commands/migrate.md +90 -0
- package/bundled/locales/zh-TW/skills/commands/pr.md +78 -0
- package/bundled/locales/zh-TW/skills/commands/refactor.md +1 -1
- package/bundled/locales/zh-TW/skills/commands/release.md +63 -0
- package/bundled/locales/zh-TW/skills/commands/requirement.md +61 -0
- package/bundled/locales/zh-TW/skills/commands/reverse-bdd.md +54 -0
- package/bundled/locales/zh-TW/skills/commands/reverse-sdd.md +58 -0
- package/bundled/locales/zh-TW/skills/commands/reverse-tdd.md +58 -0
- package/bundled/locales/zh-TW/skills/commands/reverse.md +70 -0
- package/bundled/locales/zh-TW/skills/commands/review.md +57 -0
- package/bundled/locales/zh-TW/skills/commands/scan.md +74 -0
- package/bundled/locales/zh-TW/skills/commands/sdd-retro.md +47 -0
- package/bundled/locales/zh-TW/skills/commands/sdd.md +362 -0
- package/bundled/locales/zh-TW/skills/commands/security.md +73 -0
- package/bundled/locales/zh-TW/skills/commands/tdd.md +115 -0
- package/bundled/locales/zh-TW/skills/commands/update.md +326 -0
- package/bundled/locales/zh-TW/skills/commit-standards/SKILL.md +2 -6
- package/bundled/locales/zh-TW/skills/database-assistant/SKILL.md +94 -0
- package/bundled/locales/zh-TW/skills/dev-workflow-guide/SKILL.md +140 -0
- package/bundled/locales/zh-TW/skills/docs-generator/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/documentation-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/durable-execution-assistant/SKILL.md +81 -0
- package/bundled/locales/zh-TW/skills/error-code-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/forward-derivation/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/git-workflow-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/incident-response-assistant/SKILL.md +104 -0
- package/bundled/locales/zh-TW/skills/logging-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/methodology-system/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/metrics-dashboard-assistant/SKILL.md +64 -0
- package/bundled/locales/zh-TW/skills/migration-assistant/SKILL.md +74 -0
- package/bundled/locales/zh-TW/skills/pr-automation-assistant/SKILL.md +87 -0
- package/bundled/locales/zh-TW/skills/project-discovery/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/refactoring-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/release-standards/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/requirement-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/reverse-engineer/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/security-assistant/SKILL.md +76 -0
- package/bundled/locales/zh-TW/skills/security-scan-assistant/SKILL.md +69 -0
- package/bundled/locales/zh-TW/skills/spec-driven-dev/SKILL.md +74 -14
- package/bundled/locales/zh-TW/skills/spec-driven-dev/guide.md +243 -98
- package/bundled/locales/zh-TW/skills/tdd-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/test-coverage-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/testing-guide/SKILL.md +1 -5
- package/bundled/skills/README.md +11 -0
- package/bundled/skills/ac-coverage-assistant/SKILL.md +127 -0
- package/bundled/skills/ai-collaboration-standards/SKILL.md +10 -0
- package/bundled/skills/ai-friendly-architecture/SKILL.md +10 -0
- package/bundled/skills/ai-instruction-standards/SKILL.md +10 -0
- package/bundled/skills/api-design-assistant/SKILL.md +119 -0
- package/bundled/skills/atdd-assistant/SKILL.md +7 -0
- package/bundled/skills/bdd-assistant/SKILL.md +7 -0
- package/bundled/skills/brainstorm-assistant/SKILL.md +7 -0
- package/bundled/skills/checkin-assistant/SKILL.md +7 -0
- package/bundled/skills/ci-cd-assistant/SKILL.md +97 -0
- package/bundled/skills/code-review-assistant/SKILL.md +7 -0
- package/bundled/skills/commands/README.md +70 -0
- package/bundled/skills/commands/ac-coverage.md +135 -0
- package/bundled/skills/commands/api-design.md +86 -0
- package/bundled/skills/commands/atdd.md +69 -0
- package/bundled/skills/commands/audit.md +69 -0
- package/bundled/skills/commands/bdd.md +101 -0
- package/bundled/skills/commands/brainstorm.md +45 -0
- package/bundled/skills/commands/changelog.md +34 -0
- package/bundled/skills/commands/check.md +52 -1
- package/bundled/skills/commands/checkin.md +46 -0
- package/bundled/skills/commands/ci-cd.md +69 -0
- package/bundled/skills/commands/commit.md +79 -0
- package/bundled/skills/commands/config.md +48 -0
- package/bundled/skills/commands/coverage.md +53 -0
- package/bundled/skills/commands/database.md +70 -0
- package/bundled/skills/commands/derive-all.md +40 -0
- package/bundled/skills/commands/derive-atdd.md +33 -0
- package/bundled/skills/commands/derive-bdd.md +39 -0
- package/bundled/skills/commands/derive-tdd.md +40 -0
- package/bundled/skills/commands/derive.md +47 -0
- package/bundled/skills/commands/dev-workflow.md +104 -7
- package/bundled/skills/commands/discover.md +39 -0
- package/bundled/skills/commands/docgen.md +35 -0
- package/bundled/skills/commands/docs.md +40 -0
- package/bundled/skills/commands/durable.md +79 -0
- package/bundled/skills/commands/incident.md +84 -0
- package/bundled/skills/commands/init.md +55 -0
- package/bundled/skills/commands/methodology.md +72 -0
- package/bundled/skills/commands/metrics.md +65 -0
- package/bundled/skills/commands/migrate.md +84 -0
- package/bundled/skills/commands/pr.md +72 -0
- package/bundled/skills/commands/refactor.md +51 -0
- package/bundled/skills/commands/release.md +60 -0
- package/bundled/skills/commands/requirement.md +38 -0
- package/bundled/skills/commands/reverse-bdd.md +34 -0
- package/bundled/skills/commands/reverse-sdd.md +42 -0
- package/bundled/skills/commands/reverse-tdd.md +40 -0
- package/bundled/skills/commands/reverse.md +41 -0
- package/bundled/skills/commands/review.md +39 -0
- package/bundled/skills/commands/scan.md +68 -0
- package/bundled/skills/commands/sdd-retro.md +48 -0
- package/bundled/skills/commands/sdd.md +220 -0
- package/bundled/skills/commands/security.md +67 -0
- package/bundled/skills/commands/tdd.md +101 -0
- package/bundled/skills/commands/update.md +61 -0
- package/bundled/skills/commit-standards/SKILL.md +8 -2
- package/bundled/skills/database-assistant/SKILL.md +118 -0
- package/bundled/skills/dev-workflow-guide/SKILL.md +53 -7
- package/bundled/skills/dev-workflow-guide/workflow-phases.md +24 -0
- package/bundled/skills/durable-execution-assistant/SKILL.md +116 -0
- package/bundled/skills/forward-derivation/SKILL.md +7 -0
- package/bundled/skills/incident-response-assistant/SKILL.md +132 -0
- package/bundled/skills/methodology-system/SKILL.md +24 -2
- package/bundled/skills/metrics-dashboard-assistant/SKILL.md +109 -0
- package/bundled/skills/migration-assistant/SKILL.md +119 -0
- package/bundled/skills/pr-automation-assistant/SKILL.md +114 -0
- package/bundled/skills/project-discovery/SKILL.md +7 -0
- package/bundled/skills/refactoring-assistant/SKILL.md +7 -0
- package/bundled/skills/release-standards/SKILL.md +7 -0
- package/bundled/skills/requirement-assistant/SKILL.md +7 -0
- package/bundled/skills/reverse-engineer/SKILL.md +7 -0
- package/bundled/skills/security-assistant/SKILL.md +105 -0
- package/bundled/skills/security-scan-assistant/SKILL.md +96 -0
- package/bundled/skills/spec-driven-dev/SKILL.md +84 -4
- package/bundled/skills/spec-driven-dev/guide.md +156 -22
- package/bundled/skills/tdd-assistant/SKILL.md +7 -0
- package/bundled/skills/test-coverage-assistant/SKILL.md +11 -0
- package/bundled/skills/testing-guide/SKILL.md +23 -0
- package/package.json +1 -1
- package/src/commands/check.js +154 -8
- package/src/commands/config.js +231 -104
- package/src/commands/init.js +23 -3
- package/src/commands/update.js +250 -25
- package/src/config/ai-agent-paths.js +16 -0
- package/src/config/workflow-definitions.js +184 -0
- package/src/core/constants.js +6 -0
- package/src/flows/init-flow.js +23 -6
- package/src/i18n/messages.js +51 -3
- package/src/installers/integration-installer.js +67 -2
- package/src/installers/manifest-installer.js +1 -0
- package/src/installers/standards-installer.js +3 -2
- package/src/prompts/init.js +50 -3
- package/src/reconciler/manifest-migrator.js +2 -2
- package/src/reconciler/plan-executor.js +11 -0
- package/src/utils/integration-generator.js +327 -14
- package/src/utils/workflow-gate.js +292 -0
- package/standards-registry.json +160 -5
|
@@ -0,0 +1,293 @@
|
|
|
1
|
+
# Acceptance Criteria Traceability Standards
|
|
2
|
+
|
|
3
|
+
> **Language**: English | [繁體中文](../locales/zh-TW/core/acceptance-criteria-traceability.md)
|
|
4
|
+
|
|
5
|
+
**Applicability**: All software projects using specification-driven or test-driven workflows
|
|
6
|
+
**Scope**: universal
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## Overview
|
|
11
|
+
|
|
12
|
+
Acceptance Criteria Traceability Standards define how to track the relationship between Acceptance Criteria (AC), test implementations, and coverage status. This standard ensures every AC is verifiably tested and provides standardized reporting formats for coverage analysis.
|
|
13
|
+
|
|
14
|
+
## References
|
|
15
|
+
|
|
16
|
+
| Standard/Source | Content |
|
|
17
|
+
|----------------|---------|
|
|
18
|
+
| ISO/IEC/IEEE 29119-3 | Test Documentation — Traceability Matrix |
|
|
19
|
+
| IEEE 830 | Software Requirements Specification — Traceability |
|
|
20
|
+
| ISTQB Foundation | Requirements-based testing |
|
|
21
|
+
| INVEST Principles | Acceptance criteria quality |
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## AC-to-Test Traceability Matrix
|
|
26
|
+
|
|
27
|
+
### Standard Matrix Format
|
|
28
|
+
|
|
29
|
+
| AC-ID | Test File | Test Name | Status | Notes |
|
|
30
|
+
|-------|-----------|-----------|--------|-------|
|
|
31
|
+
| AC-1 | `tests/auth.test.ts` | `should login with valid credentials` | ✅ covered | |
|
|
32
|
+
| AC-2 | `tests/auth.test.ts` | `should reject invalid credentials` | ✅ covered | |
|
|
33
|
+
| AC-3 | — | — | ❌ uncovered | Blocked by API dependency |
|
|
34
|
+
| AC-4 | `tests/auth.test.ts` | `should lock account after 5 failures` | ⚠️ partial | Missing edge case |
|
|
35
|
+
|
|
36
|
+
### Matrix Fields
|
|
37
|
+
|
|
38
|
+
| Field | Required | Description |
|
|
39
|
+
|-------|----------|-------------|
|
|
40
|
+
| `AC-ID` | Yes | Unique identifier from the specification (e.g., AC-1, AC-2) |
|
|
41
|
+
| `Test File` | Yes (if covered) | Path to the test file implementing this AC |
|
|
42
|
+
| `Test Name` | Yes (if covered) | Name of the test case or describe block |
|
|
43
|
+
| `Status` | Yes | Coverage status: `covered`, `partial`, `uncovered` |
|
|
44
|
+
| `Notes` | No | Additional context (blockers, dependencies, etc.) |
|
|
45
|
+
|
|
46
|
+
### Linking Convention
|
|
47
|
+
|
|
48
|
+
Tests MUST reference their source AC using standard annotations:
|
|
49
|
+
|
|
50
|
+
```typescript
|
|
51
|
+
// TypeScript/JavaScript
|
|
52
|
+
describe('AC-1: User login with valid credentials', () => {
|
|
53
|
+
// @AC AC-1
|
|
54
|
+
// @SPEC SPEC-001
|
|
55
|
+
it('should redirect to dashboard on successful login', () => { ... });
|
|
56
|
+
});
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
```python
|
|
60
|
+
# Python
|
|
61
|
+
class TestAC1_UserLogin:
|
|
62
|
+
"""AC-1: User login with valid credentials
|
|
63
|
+
@AC AC-1
|
|
64
|
+
@SPEC SPEC-001
|
|
65
|
+
"""
|
|
66
|
+
def test_redirect_to_dashboard(self): ...
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
```gherkin
|
|
70
|
+
# BDD Feature
|
|
71
|
+
@SPEC-001 @AC-1
|
|
72
|
+
Scenario: User login with valid credentials
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
## Coverage Status Definitions
|
|
78
|
+
|
|
79
|
+
### Status Classification
|
|
80
|
+
|
|
81
|
+
| Status | Symbol | Definition | Criteria |
|
|
82
|
+
|--------|--------|-----------|----------|
|
|
83
|
+
| **Covered** | ✅ | AC is fully tested | All conditions in AC have corresponding test assertions |
|
|
84
|
+
| **Partial** | ⚠️ | AC is partially tested | Some conditions tested, but edge cases or paths missing |
|
|
85
|
+
| **Uncovered** | ❌ | AC has no tests | No test case references this AC |
|
|
86
|
+
|
|
87
|
+
### Coverage Calculation
|
|
88
|
+
|
|
89
|
+
```
|
|
90
|
+
AC Coverage % = (covered_count / total_ac_count) × 100
|
|
91
|
+
|
|
92
|
+
Where:
|
|
93
|
+
covered_count = count of AC with status "covered"
|
|
94
|
+
total_ac_count = total number of AC in specification
|
|
95
|
+
partial counts as 0.5 for coverage calculation
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
### Example Calculation
|
|
99
|
+
|
|
100
|
+
```
|
|
101
|
+
SPEC-001: 8 AC total
|
|
102
|
+
- 5 covered (✅)
|
|
103
|
+
- 2 partial (⚠️)
|
|
104
|
+
- 1 uncovered (❌)
|
|
105
|
+
|
|
106
|
+
Coverage = (5 + 2×0.5) / 8 = 6/8 = 75%
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
---
|
|
110
|
+
|
|
111
|
+
## Quality Thresholds
|
|
112
|
+
|
|
113
|
+
### Default Thresholds
|
|
114
|
+
|
|
115
|
+
| Threshold | Value | Enforcement |
|
|
116
|
+
|-----------|-------|-------------|
|
|
117
|
+
| **Minimum AC Coverage** | 100% | Required for production release |
|
|
118
|
+
| **Minimum for Check-in** | 80% | Required for feature branch merge |
|
|
119
|
+
| **Warning Level** | 60% | Triggers coverage warning |
|
|
120
|
+
|
|
121
|
+
### Configurable Thresholds
|
|
122
|
+
|
|
123
|
+
Projects MAY customize thresholds in their configuration:
|
|
124
|
+
|
|
125
|
+
```json
|
|
126
|
+
{
|
|
127
|
+
"acCoverage": {
|
|
128
|
+
"minimum": 100,
|
|
129
|
+
"checkinMinimum": 80,
|
|
130
|
+
"warningLevel": 60,
|
|
131
|
+
"partialWeight": 0.5
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
### Threshold Exceptions
|
|
137
|
+
|
|
138
|
+
Exceptions to coverage requirements MUST be documented:
|
|
139
|
+
|
|
140
|
+
| Exception Type | When Allowed | Documentation Required |
|
|
141
|
+
|---------------|-------------|----------------------|
|
|
142
|
+
| External dependency blocker | Third-party API unavailable | Issue link + timeline |
|
|
143
|
+
| Infrastructure limitation | Test environment constraint | Workaround plan |
|
|
144
|
+
| Deferred to next iteration | Agreed with stakeholders | Ticket reference |
|
|
145
|
+
|
|
146
|
+
---
|
|
147
|
+
|
|
148
|
+
## AC Coverage Report Format
|
|
149
|
+
|
|
150
|
+
### Standard Report Structure
|
|
151
|
+
|
|
152
|
+
```markdown
|
|
153
|
+
# AC Coverage Report
|
|
154
|
+
|
|
155
|
+
**Specification**: SPEC-001 — User Authentication
|
|
156
|
+
**Generated**: 2026-03-18
|
|
157
|
+
**Coverage**: 75% (6/8 AC)
|
|
158
|
+
|
|
159
|
+
## Summary
|
|
160
|
+
|
|
161
|
+
| Status | Count | Percentage |
|
|
162
|
+
|--------|-------|------------|
|
|
163
|
+
| ✅ Covered | 5 | 62.5% |
|
|
164
|
+
| ⚠️ Partial | 2 | 25.0% |
|
|
165
|
+
| ❌ Uncovered | 1 | 12.5% |
|
|
166
|
+
|
|
167
|
+
## Traceability Matrix
|
|
168
|
+
|
|
169
|
+
| AC-ID | Description | Status | Test Reference |
|
|
170
|
+
|-------|-------------|--------|----------------|
|
|
171
|
+
| AC-1 | Login with valid credentials | ✅ | auth.test.ts:15 |
|
|
172
|
+
| AC-2 | Reject invalid credentials | ✅ | auth.test.ts:32 |
|
|
173
|
+
| AC-3 | Rate limit login attempts | ⚠️ | auth.test.ts:48 (missing edge case) |
|
|
174
|
+
| ... | ... | ... | ... |
|
|
175
|
+
|
|
176
|
+
## Gaps
|
|
177
|
+
|
|
178
|
+
### Uncovered AC
|
|
179
|
+
- **AC-8**: Social login integration — Blocked by OAuth provider sandbox
|
|
180
|
+
|
|
181
|
+
### Partial AC
|
|
182
|
+
- **AC-3**: Rate limit — Missing test for concurrent requests
|
|
183
|
+
- **AC-6**: Session timeout — Missing test for background tab behavior
|
|
184
|
+
|
|
185
|
+
## Action Items
|
|
186
|
+
1. [ ] AC-8: Set up OAuth sandbox environment (ETA: 2026-03-25)
|
|
187
|
+
2. [ ] AC-3: Add concurrent request test
|
|
188
|
+
3. [ ] AC-6: Add background tab test
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
### Machine-Readable Format
|
|
192
|
+
|
|
193
|
+
```json
|
|
194
|
+
{
|
|
195
|
+
"specId": "SPEC-001",
|
|
196
|
+
"specName": "User Authentication",
|
|
197
|
+
"generatedAt": "2026-03-18T10:00:00Z",
|
|
198
|
+
"coverage": {
|
|
199
|
+
"percentage": 75,
|
|
200
|
+
"covered": 5,
|
|
201
|
+
"partial": 2,
|
|
202
|
+
"uncovered": 1,
|
|
203
|
+
"total": 8
|
|
204
|
+
},
|
|
205
|
+
"matrix": [
|
|
206
|
+
{
|
|
207
|
+
"acId": "AC-1",
|
|
208
|
+
"description": "Login with valid credentials",
|
|
209
|
+
"status": "covered",
|
|
210
|
+
"testFile": "tests/auth.test.ts",
|
|
211
|
+
"testName": "should login with valid credentials",
|
|
212
|
+
"testLine": 15
|
|
213
|
+
}
|
|
214
|
+
]
|
|
215
|
+
}
|
|
216
|
+
```
|
|
217
|
+
|
|
218
|
+
---
|
|
219
|
+
|
|
220
|
+
## Automatic Spec Generation Quality Rules
|
|
221
|
+
|
|
222
|
+
### AC Quality Requirements
|
|
223
|
+
|
|
224
|
+
When generating specifications automatically (from PRD, user stories, or requirements), the generated AC MUST meet these quality criteria:
|
|
225
|
+
|
|
226
|
+
| Criterion | Description | Validation |
|
|
227
|
+
|-----------|-------------|-----------|
|
|
228
|
+
| **Specific** | AC describes a concrete, observable behavior | No vague terms ("should work well", "fast enough") |
|
|
229
|
+
| **Measurable** | AC has quantifiable or verifiable outcome | Contains expected values, states, or behaviors |
|
|
230
|
+
| **Achievable** | AC is technically feasible | References known APIs, data, or capabilities |
|
|
231
|
+
| **Relevant** | AC relates to the feature's purpose | Maps to a user need or business requirement |
|
|
232
|
+
| **Testable** | AC can be verified by a test | Can be expressed as Given-When-Then |
|
|
233
|
+
|
|
234
|
+
### Spec Generation I/O Contract
|
|
235
|
+
|
|
236
|
+
#### Input Format
|
|
237
|
+
|
|
238
|
+
| Input Type | Required Fields | Example |
|
|
239
|
+
|-----------|----------------|---------|
|
|
240
|
+
| PRD | Title, Description, User Stories | Product Requirements Document |
|
|
241
|
+
| User Story | As a / I want / So that | "As a user, I want to login..." |
|
|
242
|
+
| Feature Brief | Feature name, Goals, Constraints | Feature description document |
|
|
243
|
+
|
|
244
|
+
#### Output Format
|
|
245
|
+
|
|
246
|
+
Generated spec MUST include:
|
|
247
|
+
|
|
248
|
+
| Section | Required | Description |
|
|
249
|
+
|---------|----------|-------------|
|
|
250
|
+
| SPEC ID | Yes | Unique identifier (e.g., SPEC-001) |
|
|
251
|
+
| Title | Yes | Feature name |
|
|
252
|
+
| Description | Yes | What the feature does |
|
|
253
|
+
| Acceptance Criteria | Yes | Numbered AC list (AC-1, AC-2, ...) |
|
|
254
|
+
| AC Format | Yes | Given-When-Then or structured bullet |
|
|
255
|
+
| Testability Flag | Yes | Each AC marked as testable/not-testable |
|
|
256
|
+
|
|
257
|
+
#### Validation Rules
|
|
258
|
+
|
|
259
|
+
1. **AC Count**: Generated spec MUST have at least 1 AC
|
|
260
|
+
2. **AC Uniqueness**: No duplicate AC descriptions
|
|
261
|
+
3. **AC Completeness**: Happy path + at least 1 error/edge case
|
|
262
|
+
4. **AC Testability**: 100% of AC must be testable
|
|
263
|
+
5. **Traceability**: Each AC links back to source requirement
|
|
264
|
+
|
|
265
|
+
---
|
|
266
|
+
|
|
267
|
+
## Anti-Patterns
|
|
268
|
+
|
|
269
|
+
| Anti-Pattern | Impact | Correct Approach |
|
|
270
|
+
|--------------|--------|------------------|
|
|
271
|
+
| Untraceable tests | Cannot verify spec coverage | Always annotate tests with AC-ID |
|
|
272
|
+
| Claiming partial as covered | False confidence in coverage | Use honest status classification |
|
|
273
|
+
| Ignoring uncovered AC | Gaps in verification | Track and plan coverage for all AC |
|
|
274
|
+
| AC without testability | Cannot be verified | Ensure all AC are testable |
|
|
275
|
+
| Coverage without assertions | Tests run but verify nothing | Check for meaningful assertions |
|
|
276
|
+
|
|
277
|
+
---
|
|
278
|
+
|
|
279
|
+
## Related Standards
|
|
280
|
+
|
|
281
|
+
- [Forward Derivation Standards](forward-derivation-standards.md) — Generating tests from AC
|
|
282
|
+
- [Spec-Driven Development](spec-driven-development.md) — AC definition format
|
|
283
|
+
- [Testing Standards](testing-standards.md) — Test implementation standards
|
|
284
|
+
- [Check-in Standards](checkin-standards.md) — Coverage gates for check-in
|
|
285
|
+
- [Test Governance](test-governance.md) — Completion criteria
|
|
286
|
+
|
|
287
|
+
---
|
|
288
|
+
|
|
289
|
+
## Version History
|
|
290
|
+
|
|
291
|
+
| Version | Date | Changes |
|
|
292
|
+
|---------|------|---------|
|
|
293
|
+
| 1.0.0 | 2026-03-18 | Initial version — traceability matrix, coverage calculation, spec generation rules |
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
# Agent Dispatch & Parallel Coordination
|
|
2
|
+
|
|
3
|
+
> **Language**: English | [繁體中文](../locales/zh-TW/core/agent-dispatch.md)
|
|
4
|
+
|
|
5
|
+
**Version**: 1.0.0
|
|
6
|
+
**Last Updated**: 2026-03-20
|
|
7
|
+
**Applicability**: AI-assisted development with multi-agent orchestration
|
|
8
|
+
**Scope**: universal
|
|
9
|
+
**Inspired by**: [Superpowers](https://github.com/obra/superpowers) — dispatching-parallel-agents, subagent-driven-development (MIT)
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## Purpose
|
|
14
|
+
|
|
15
|
+
Define standards for dispatching AI sub-agents in parallel, coordinating their work, and handling their return states. This standard ensures efficient parallelization while preventing file conflicts and integration failures.
|
|
16
|
+
|
|
17
|
+
定義 AI 子代理的並行派遣、工作協調與狀態回報標準。確保高效並行化的同時,防止檔案衝突與整合失敗。
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
## Glossary
|
|
22
|
+
|
|
23
|
+
| Term | Definition |
|
|
24
|
+
|------|-----------|
|
|
25
|
+
| Sub-agent | An AI agent spawned by an orchestrator to handle a specific task |
|
|
26
|
+
| Independent Domain | A task scope with no shared mutable state with other tasks |
|
|
27
|
+
| Status Protocol | The standardized return states a sub-agent must report |
|
|
28
|
+
| File Conflict | When multiple agents modify the same file concurrently |
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
32
|
+
## Core Principle — Independence Before Parallelism
|
|
33
|
+
|
|
34
|
+
> **Before dispatching agents in parallel, verify their task domains are independent (no shared mutable state).**
|
|
35
|
+
|
|
36
|
+
派遣前必須識別獨立域 — 無共享可變狀態才可並行。
|
|
37
|
+
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
## Prompt Design Principles
|
|
41
|
+
|
|
42
|
+
Every sub-agent prompt must follow three principles:
|
|
43
|
+
|
|
44
|
+
### 1. Focused(聚焦)
|
|
45
|
+
|
|
46
|
+
Each agent handles exactly one problem domain. Do not combine unrelated tasks.
|
|
47
|
+
|
|
48
|
+
每個代理只處理單一問題域,不混合無關任務。
|
|
49
|
+
|
|
50
|
+
### 2. Self-contained(自足)
|
|
51
|
+
|
|
52
|
+
The prompt includes all context needed for execution. The agent should not need to ask questions or search for additional information.
|
|
53
|
+
|
|
54
|
+
Prompt 包含執行所需的完整上下文,代理不需要額外提問或搜尋。
|
|
55
|
+
|
|
56
|
+
### 3. Specific Output(明確輸出)
|
|
57
|
+
|
|
58
|
+
Define exactly what format the agent should return its results in.
|
|
59
|
+
|
|
60
|
+
明確定義期望的回報格式。
|
|
61
|
+
|
|
62
|
+
---
|
|
63
|
+
|
|
64
|
+
## Status Protocol
|
|
65
|
+
|
|
66
|
+
Every sub-agent must report one of four statuses upon completion:
|
|
67
|
+
|
|
68
|
+
| Status | Description | Orchestrator Action |
|
|
69
|
+
|--------|-------------|-------------------|
|
|
70
|
+
| `DONE` | Task completed successfully | Continue to next task |
|
|
71
|
+
| `DONE_WITH_CONCERNS` | Completed but with concerns to record | Log concerns, continue |
|
|
72
|
+
| `NEEDS_CONTEXT` | Needs more context to complete | Inject context, re-dispatch (not a retry) |
|
|
73
|
+
| `BLOCKED` | Cannot complete, needs escalation | Upgrade model tier or split task |
|
|
74
|
+
|
|
75
|
+
### Status Decision Flow
|
|
76
|
+
|
|
77
|
+
```
|
|
78
|
+
Agent completes work
|
|
79
|
+
├── All acceptance criteria met? → DONE
|
|
80
|
+
├── Criteria met but concerns exist? → DONE_WITH_CONCERNS
|
|
81
|
+
├── Missing information to proceed? → NEEDS_CONTEXT
|
|
82
|
+
└── Fundamentally unable to complete? → BLOCKED
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
---
|
|
86
|
+
|
|
87
|
+
## Conflict Detection
|
|
88
|
+
|
|
89
|
+
When parallel agents return, the orchestrator must:
|
|
90
|
+
|
|
91
|
+
1. **Check for file conflicts** — did multiple agents modify the same file?
|
|
92
|
+
2. **Run the full test suite** — verify integration after merging all changes
|
|
93
|
+
3. **Resolve conflicts** — either automatically or flag for human review
|
|
94
|
+
|
|
95
|
+
```
|
|
96
|
+
Agent A (modifies: src/auth.ts, src/auth.test.ts) ─┐
|
|
97
|
+
├─→ Conflict check → Integration test
|
|
98
|
+
Agent B (modifies: src/api.ts, src/api.test.ts) ─┘
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
---
|
|
102
|
+
|
|
103
|
+
## Rules
|
|
104
|
+
|
|
105
|
+
| ID | Trigger | Action | Priority |
|
|
106
|
+
|----|---------|--------|----------|
|
|
107
|
+
| AD-001 | Multiple agents edit the same file | Flag conflict, require merge resolution | Critical |
|
|
108
|
+
| AD-002 | Agent reports BLOCKED | Upgrade model tier and retry once | High |
|
|
109
|
+
| AD-003 | All parallel agents complete | Run full test suite to verify integration | High |
|
|
110
|
+
|
|
111
|
+
---
|
|
112
|
+
|
|
113
|
+
## Examples
|
|
114
|
+
|
|
115
|
+
### Good: Parallel Independent Tasks
|
|
116
|
+
|
|
117
|
+
```yaml
|
|
118
|
+
# Two agents working on independent modules
|
|
119
|
+
Agent 1:
|
|
120
|
+
task: "Add rate limiting to /api/users endpoint"
|
|
121
|
+
files: [src/api/users.ts, src/api/users.test.ts]
|
|
122
|
+
|
|
123
|
+
Agent 2:
|
|
124
|
+
task: "Add caching to /api/products endpoint"
|
|
125
|
+
files: [src/api/products.ts, src/api/products.test.ts]
|
|
126
|
+
|
|
127
|
+
# No shared files → safe to parallelize
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
### Bad: Parallel Dependent Tasks
|
|
131
|
+
|
|
132
|
+
```yaml
|
|
133
|
+
# Two agents modifying shared state
|
|
134
|
+
Agent 1:
|
|
135
|
+
task: "Refactor database connection pool"
|
|
136
|
+
files: [src/db.ts] # ⚠️ shared file
|
|
137
|
+
|
|
138
|
+
Agent 2:
|
|
139
|
+
task: "Add connection retry logic"
|
|
140
|
+
files: [src/db.ts] # ⚠️ conflict!
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
---
|
|
144
|
+
|
|
145
|
+
## References
|
|
146
|
+
|
|
147
|
+
- **Superpowers**: [dispatching-parallel-agents](https://github.com/obra/superpowers), [subagent-driven-development](https://github.com/obra/superpowers) (MIT)
|
|
148
|
+
- **MapReduce**: Conceptual parallel execution model
|
|
149
|
+
- **Actor Model**: Independent agent communication pattern
|
|
@@ -0,0 +1,239 @@
|
|
|
1
|
+
# AI Command Behavior Standards
|
|
2
|
+
|
|
3
|
+
> **Language**: English | [繁體中文](../locales/zh-TW/core/ai-command-behavior.md) | [简体中文](../locales/zh-CN/core/ai-command-behavior.md)
|
|
4
|
+
|
|
5
|
+
**Version**: 1.0.0
|
|
6
|
+
**Last Updated**: 2026-03-24
|
|
7
|
+
**Applicability**: All projects using AI-assisted commands or skills
|
|
8
|
+
**Scope**: universal
|
|
9
|
+
**Industry Standards**: None (Emerging AI tool practice)
|
|
10
|
+
**References**: [SPEC-STD-07](../docs/specs/standards/SPEC-STD-07-ai-command-behavior.md)
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
## Purpose
|
|
15
|
+
|
|
16
|
+
This standard defines a structure for specifying AI Agent runtime behavior in command/skill definition files. It ensures that AI agents produce consistent, predictable interactions when executing commands — regardless of which AI model or tool runs them.
|
|
17
|
+
|
|
18
|
+
**Problem**: Commands define "what" to do but lack "how" the AI should interact with the user, leading to unpredictable behavior.
|
|
19
|
+
|
|
20
|
+
**Solution**: A standard `## AI Agent Behavior` section with four subsections covering entry routing, interaction flow, stop points, and error handling.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## AI Behavior Section Structure
|
|
25
|
+
|
|
26
|
+
Every command definition file that requires AI interaction SHOULD include:
|
|
27
|
+
|
|
28
|
+
```markdown
|
|
29
|
+
## AI Agent Behavior | AI 代理行為
|
|
30
|
+
|
|
31
|
+
### Entry Router | 進入路由
|
|
32
|
+
|
|
33
|
+
### Interaction Script | 互動腳本
|
|
34
|
+
|
|
35
|
+
### Stop Points | 停止點
|
|
36
|
+
|
|
37
|
+
### Error Handling | 錯誤處理
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
---
|
|
41
|
+
|
|
42
|
+
## Section Definitions
|
|
43
|
+
|
|
44
|
+
### 1. Entry Router
|
|
45
|
+
|
|
46
|
+
Defines what the AI does for each invocation pattern. Use a decision table for commands with multiple invocation patterns.
|
|
47
|
+
|
|
48
|
+
**Format:**
|
|
49
|
+
|
|
50
|
+
```markdown
|
|
51
|
+
| Input | AI Action |
|
|
52
|
+
|-------|-----------|
|
|
53
|
+
| `/cmd` | [action when no arguments] |
|
|
54
|
+
| `/cmd <name>` | [action with name argument] |
|
|
55
|
+
| `/cmd <phase>` | [action with phase subcommand] |
|
|
56
|
+
| `/cmd <phase> <target>` | [action with phase and target] |
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
**Simple commands** (single invocation pattern) may use a one-line description instead.
|
|
60
|
+
|
|
61
|
+
**Rules:**
|
|
62
|
+
- Every documented invocation pattern MUST have a corresponding entry
|
|
63
|
+
- The "no arguments" case MUST always be defined
|
|
64
|
+
- Entry actions MUST be deterministic — no ambiguity in what happens first
|
|
65
|
+
|
|
66
|
+
### 2. Interaction Script
|
|
67
|
+
|
|
68
|
+
Defines step-by-step AI behavior using **mixed granularity**:
|
|
69
|
+
|
|
70
|
+
| Element | Granularity | Reason |
|
|
71
|
+
|---------|-------------|--------|
|
|
72
|
+
| Decision points | Precise (IF/THEN) | Affects downstream flow |
|
|
73
|
+
| General steps | Guideline (numbered list) | AI needs flexibility |
|
|
74
|
+
|
|
75
|
+
**Decision point format:**
|
|
76
|
+
|
|
77
|
+
```markdown
|
|
78
|
+
**Decision: [Name]**
|
|
79
|
+
- IF [condition A] → [specific action]
|
|
80
|
+
- IF [condition B] → [specific action]
|
|
81
|
+
- ELSE → [default action]
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
**General step format:**
|
|
85
|
+
|
|
86
|
+
```markdown
|
|
87
|
+
1. [Step description]
|
|
88
|
+
2. [Step description]
|
|
89
|
+
3. [Step description]
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
**Rules:**
|
|
93
|
+
- Decision points MUST use explicit IF/THEN/ELSE
|
|
94
|
+
- General steps SHOULD use numbered lists
|
|
95
|
+
- Output format (what the AI shows to the user) SHOULD be specified for key outputs
|
|
96
|
+
|
|
97
|
+
### 3. Stop Points
|
|
98
|
+
|
|
99
|
+
Defines moments where the AI MUST pause and wait for user confirmation.
|
|
100
|
+
|
|
101
|
+
**Marker format:**
|
|
102
|
+
|
|
103
|
+
```markdown
|
|
104
|
+
🛑 **STOP**: [description] — wait for user confirmation before continuing
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
**Default stop principles** (apply when no explicit stop points are defined):
|
|
108
|
+
|
|
109
|
+
| Situation | Action |
|
|
110
|
+
|-----------|--------|
|
|
111
|
+
| About to write/modify files | 🛑 STOP |
|
|
112
|
+
| About to execute irreversible operations | 🛑 STOP |
|
|
113
|
+
| Phase/stage completion | 🛑 STOP |
|
|
114
|
+
| Need additional information from user | 🛑 STOP |
|
|
115
|
+
| Read-only analysis complete, showing results | ▶️ CONTINUE |
|
|
116
|
+
|
|
117
|
+
**Rules:**
|
|
118
|
+
- Stop points MUST be explicit — do not rely on AI judgment
|
|
119
|
+
- Each stop point MUST describe what the AI is waiting for
|
|
120
|
+
- The number of stop points should be proportional to the operation's risk
|
|
121
|
+
|
|
122
|
+
### 4. Error Handling
|
|
123
|
+
|
|
124
|
+
Defines AI behavior when prerequisites fail or unexpected states occur.
|
|
125
|
+
|
|
126
|
+
**Format:**
|
|
127
|
+
|
|
128
|
+
```markdown
|
|
129
|
+
| Error Condition | AI Action |
|
|
130
|
+
|-----------------|-----------|
|
|
131
|
+
| [prerequisite not met] | [guide to correct step] |
|
|
132
|
+
| [unexpected state] | [stop and ask user] |
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
**Default error principles:**
|
|
136
|
+
|
|
137
|
+
1. **State the problem**: Tell user which prerequisite failed
|
|
138
|
+
2. **Guide to resolution**: Suggest the correct command or step
|
|
139
|
+
3. **Never silently skip**: Do not proceed by ignoring failures
|
|
140
|
+
4. **Never auto-fix without permission**: Unless explicitly allowed in the command definition
|
|
141
|
+
5. **Ask when uncertain**: Stop and ask rather than guess
|
|
142
|
+
|
|
143
|
+
---
|
|
144
|
+
|
|
145
|
+
## Applicability Rules
|
|
146
|
+
|
|
147
|
+
Not all commands need a full `## AI Agent Behavior` section.
|
|
148
|
+
|
|
149
|
+
| Condition | Full Definition Required | Reason |
|
|
150
|
+
|-----------|-------------------------|--------|
|
|
151
|
+
| Multi-phase workflow | ✅ Yes | Complex flow needs guidance |
|
|
152
|
+
| Multiple invocation patterns | ✅ Yes | Entry routing is ambiguous otherwise |
|
|
153
|
+
| Single clear action | ❌ No | Behavior is self-evident |
|
|
154
|
+
| Pure information query | ❌ No | No interaction decisions to make |
|
|
155
|
+
| Orchestration of sub-commands | ✅ Yes | Coordination logic needs definition |
|
|
156
|
+
|
|
157
|
+
**Heuristic**: If two different AI models could reasonably interpret the command differently, it needs a behavior definition.
|
|
158
|
+
|
|
159
|
+
---
|
|
160
|
+
|
|
161
|
+
## Example: Minimal Behavior Section
|
|
162
|
+
|
|
163
|
+
For a command like `/coverage` with moderate complexity:
|
|
164
|
+
|
|
165
|
+
```markdown
|
|
166
|
+
## AI Agent Behavior
|
|
167
|
+
|
|
168
|
+
### Entry Router
|
|
169
|
+
|
|
170
|
+
| Input | AI Action |
|
|
171
|
+
|-------|-----------|
|
|
172
|
+
| `/coverage` | Detect test framework, run coverage, show summary |
|
|
173
|
+
| `/coverage <path>` | Run coverage for specific path only |
|
|
174
|
+
|
|
175
|
+
### Interaction Script
|
|
176
|
+
|
|
177
|
+
1. Detect project test framework (look for jest.config, vitest.config, etc.)
|
|
178
|
+
2. Run coverage command
|
|
179
|
+
3. Parse output and present summary table
|
|
180
|
+
|
|
181
|
+
**Decision: Low coverage detected**
|
|
182
|
+
- IF coverage < project threshold → highlight gaps, suggest files to test
|
|
183
|
+
- ELSE → show summary only
|
|
184
|
+
|
|
185
|
+
### Stop Points
|
|
186
|
+
|
|
187
|
+
🛑 **STOP**: After showing coverage summary — ask if user wants detailed file-by-file breakdown
|
|
188
|
+
|
|
189
|
+
### Error Handling
|
|
190
|
+
|
|
191
|
+
| Error Condition | AI Action |
|
|
192
|
+
|-----------------|-----------|
|
|
193
|
+
| No test framework detected | Ask user which framework to use |
|
|
194
|
+
| Tests fail during coverage run | Show failures first, ask if user wants coverage anyway |
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
---
|
|
198
|
+
|
|
199
|
+
## Quick Reference Card
|
|
200
|
+
|
|
201
|
+
### Section Checklist
|
|
202
|
+
|
|
203
|
+
| Section | Must Define | Key Rule |
|
|
204
|
+
|---------|------------|----------|
|
|
205
|
+
| Entry Router | All invocation patterns | "No arguments" case is mandatory |
|
|
206
|
+
| Interaction Script | Decision points + general flow | Decision = precise, Steps = guideline |
|
|
207
|
+
| Stop Points | Every pause moment | Explicit markers, no AI guessing |
|
|
208
|
+
| Error Handling | Prerequisite failures | Never silently skip |
|
|
209
|
+
|
|
210
|
+
### Granularity Guide
|
|
211
|
+
|
|
212
|
+
| Element | Level | Format |
|
|
213
|
+
|---------|-------|--------|
|
|
214
|
+
| Entry Router | Precise | Decision table |
|
|
215
|
+
| Stop Points | Precise | 🛑 markers |
|
|
216
|
+
| Interaction Script | Guideline | Numbered steps + IF/THEN for decisions |
|
|
217
|
+
| Error Handling | Principles | Error table + default rules |
|
|
218
|
+
|
|
219
|
+
---
|
|
220
|
+
|
|
221
|
+
## Related Standards
|
|
222
|
+
|
|
223
|
+
- [AI Instruction Standards](ai-instruction-standards.md) — file structure for AI instruction files
|
|
224
|
+
- [AI Agreement Standards](ai-agreement-standards.md) — human-AI collaboration agreements
|
|
225
|
+
- [Anti-Hallucination Standards](anti-hallucination.md) — evidence-based AI behavior
|
|
226
|
+
|
|
227
|
+
---
|
|
228
|
+
|
|
229
|
+
## Version History
|
|
230
|
+
|
|
231
|
+
| Version | Date | Changes |
|
|
232
|
+
|---------|------|---------|
|
|
233
|
+
| 1.0.0 | 2026-03-24 | Initial release |
|
|
234
|
+
|
|
235
|
+
---
|
|
236
|
+
|
|
237
|
+
## License
|
|
238
|
+
|
|
239
|
+
This standard is released under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/).
|