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,124 @@
|
|
|
1
|
+
---
|
|
2
|
+
source: ../../../core/accessibility-standards.md
|
|
3
|
+
source_version: 1.0.0
|
|
4
|
+
translation_version: 1.0.0
|
|
5
|
+
last_synced: 2026-03-24
|
|
6
|
+
status: current
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
> **语言**: [English](../../../core/accessibility-standards.md) | 简体中文
|
|
10
|
+
|
|
11
|
+
# 无障碍标准
|
|
12
|
+
|
|
13
|
+
**版本**: 1.0.0
|
|
14
|
+
**最后更新**: 2026-01-29
|
|
15
|
+
**适用范围**: 所有包含用户界面的软件项目
|
|
16
|
+
**范围**: universal
|
|
17
|
+
**行业标准**: WCAG 2.1/2.2, WAI-ARIA 1.2, Section 508
|
|
18
|
+
**参考**: [w3.org](https://www.w3.org/WAI/WCAG21/quickref/)
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## 目的
|
|
23
|
+
|
|
24
|
+
本标准定义创建无障碍软件的综合指南,使具有不同能力的人都能使用。标准与国际规范对齐,包括 WCAG 2.1,并支持全球无障碍法规的合规性。
|
|
25
|
+
|
|
26
|
+
**参考标准**:
|
|
27
|
+
- [WCAG 2.1](https://www.w3.org/WAI/WCAG21/quickref/) - 网页内容无障碍指南
|
|
28
|
+
- [WCAG 2.2](https://www.w3.org/TR/WCAG22/) - 最新 WCAG 版本(2023)
|
|
29
|
+
- [WAI-ARIA 1.2](https://www.w3.org/TR/wai-aria-1.2/) - 无障碍富互联网应用
|
|
30
|
+
- [Section 508](https://www.section508.gov/) - 美国联邦无障碍要求
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## 无障碍原则(POUR)
|
|
35
|
+
|
|
36
|
+
```
|
|
37
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
38
|
+
│ WCAG 2.1 POUR 原则 │
|
|
39
|
+
├─────────────────────────────────────────────────────────────────┤
|
|
40
|
+
│ │
|
|
41
|
+
│ P - 可感知(PERCEIVABLE) │
|
|
42
|
+
│ ├── 用户必须能够感知信息 │
|
|
43
|
+
│ ├── 为非文本内容提供文本替代 │
|
|
44
|
+
│ ├── 为多媒体提供字幕和替代方案 │
|
|
45
|
+
│ └── 内容可适配且可区分 │
|
|
46
|
+
│ │
|
|
47
|
+
│ O - 可操作(OPERABLE) │
|
|
48
|
+
│ ├── 所有功能可通过键盘访问 │
|
|
49
|
+
│ ├── 用户有足够时间阅读和使用内容 │
|
|
50
|
+
│ ├── 不要使用可能引发癫痫的设计 │
|
|
51
|
+
│ └── 帮助用户导航和查找内容 │
|
|
52
|
+
│ │
|
|
53
|
+
│ U - 可理解(UNDERSTANDABLE) │
|
|
54
|
+
│ ├── 文本可读且可理解 │
|
|
55
|
+
│ ├── 网页以可预测的方式呈现和操作 │
|
|
56
|
+
│ └── 帮助用户避免和纠正错误 │
|
|
57
|
+
│ │
|
|
58
|
+
│ R - 健壮(ROBUST) │
|
|
59
|
+
│ ├── 与当前和未来的用户工具兼容 │
|
|
60
|
+
│ └── 使用标准化标记语言 │
|
|
61
|
+
│ │
|
|
62
|
+
└─────────────────────────────────────────────────────────────────┘
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
## WCAG 合规级别
|
|
66
|
+
|
|
67
|
+
| 级别 | 描述 | 目标 |
|
|
68
|
+
|------|------|------|
|
|
69
|
+
| **A** | 最低级别 — 基本无障碍 | 所有项目的最低要求 |
|
|
70
|
+
| **AA** | 中级 — 解决最常见的障碍 | **推荐目标**(大多数法规要求) |
|
|
71
|
+
| **AAA** | 最高级别 — 最全面的无障碍 | 针对特定需求的增强 |
|
|
72
|
+
|
|
73
|
+
## 键盘导航
|
|
74
|
+
|
|
75
|
+
| 要求 | 说明 |
|
|
76
|
+
|------|------|
|
|
77
|
+
| 所有交互元素可通过 Tab 键聚焦 | 按钮、链接、表单控件 |
|
|
78
|
+
| 焦点顺序符合逻辑 | 遵循视觉布局顺序 |
|
|
79
|
+
| 焦点指示器清晰可见 | 不要移除默认焦点样式 |
|
|
80
|
+
| 提供跳过导航链接 | 允许用户跳过重复内容 |
|
|
81
|
+
| 不要创建键盘陷阱 | 用户可以自由导航进出所有组件 |
|
|
82
|
+
|
|
83
|
+
## 颜色与对比度
|
|
84
|
+
|
|
85
|
+
| 类型 | AA 级别 | AAA 级别 |
|
|
86
|
+
|------|---------|----------|
|
|
87
|
+
| 普通文本 | 4.5:1 | 7:1 |
|
|
88
|
+
| 大文本(18px+) | 3:1 | 4.5:1 |
|
|
89
|
+
| UI 组件和图标 | 3:1 | 不适用 |
|
|
90
|
+
|
|
91
|
+
## 无障碍检查清单
|
|
92
|
+
|
|
93
|
+
- [ ] 所有图片都有 `alt` 属性
|
|
94
|
+
- [ ] 所有表单控件都有关联的标签
|
|
95
|
+
- [ ] 页面有正确的标题层级结构
|
|
96
|
+
- [ ] 颜色不是传达信息的唯一手段
|
|
97
|
+
- [ ] 对比度符合 AA 级别要求
|
|
98
|
+
- [ ] 所有功能都可通过键盘操作
|
|
99
|
+
- [ ] 使用 ARIA 属性增强语义
|
|
100
|
+
- [ ] 视频有字幕,音频有文字记录
|
|
101
|
+
|
|
102
|
+
## 测试与验证
|
|
103
|
+
|
|
104
|
+
| 工具 | 类型 | 用途 |
|
|
105
|
+
|------|------|------|
|
|
106
|
+
| axe | 自动化 | 通用无障碍测试 |
|
|
107
|
+
| WAVE | 自动化 | 可视化无障碍评估 |
|
|
108
|
+
| Lighthouse | 自动化 | 性能 + 无障碍审计 |
|
|
109
|
+
| NVDA / VoiceOver | 手动 | 屏幕阅读器测试 |
|
|
110
|
+
| 键盘操作 | 手动 | 键盘导航测试 |
|
|
111
|
+
|
|
112
|
+
---
|
|
113
|
+
|
|
114
|
+
## 相关标准
|
|
115
|
+
|
|
116
|
+
- [性能标准](performance-standards.md)
|
|
117
|
+
- [安全标准](security-standards.md)
|
|
118
|
+
- [测试标准](testing-standards.md)
|
|
119
|
+
|
|
120
|
+
---
|
|
121
|
+
|
|
122
|
+
## 许可证
|
|
123
|
+
|
|
124
|
+
本标准采用 [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) 发布。
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
---
|
|
2
|
+
source: ../../../core/agent-dispatch.md
|
|
3
|
+
source_version: 1.0.0
|
|
4
|
+
translation_version: 1.0.0
|
|
5
|
+
last_synced: 2026-03-24
|
|
6
|
+
status: current
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
> **语言**: [English](../../../core/agent-dispatch.md) | 简体中文
|
|
10
|
+
|
|
11
|
+
# 代理派遣与并行协调
|
|
12
|
+
|
|
13
|
+
**版本**: 1.0.0
|
|
14
|
+
**最后更新**: 2026-03-20
|
|
15
|
+
**适用范围**: 使用多代理编排的 AI 辅助开发
|
|
16
|
+
**范围**: universal
|
|
17
|
+
**灵感来源**: [Superpowers](https://github.com/obra/superpowers) — dispatching-parallel-agents, subagent-driven-development (MIT)
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
## 目的
|
|
22
|
+
|
|
23
|
+
定义 AI 子代理的并行派遣、工作协调与状态回报标准。确保高效并行化的同时,防止文件冲突与集成失败。
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## 术语表
|
|
28
|
+
|
|
29
|
+
| 术语 | 定义 |
|
|
30
|
+
|------|------|
|
|
31
|
+
| 子代理 | 由编排器生成的用于处理特定任务的 AI 代理 |
|
|
32
|
+
| 独立域 | 与其他任务没有共享可变状态的任务范围 |
|
|
33
|
+
| 状态协议 | 子代理必须回报的标准化返回状态 |
|
|
34
|
+
| 文件冲突 | 多个代理同时修改同一文件 |
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
## 核心原则 — 并行前先确认独立性
|
|
39
|
+
|
|
40
|
+
> **派遣代理并行执行前,必须验证其任务域是独立的(无共享可变状态)。**
|
|
41
|
+
|
|
42
|
+
---
|
|
43
|
+
|
|
44
|
+
## Prompt 设计原则
|
|
45
|
+
|
|
46
|
+
每个子代理的 prompt 必须遵循三个原则:
|
|
47
|
+
|
|
48
|
+
### 1. 聚焦(Focused)
|
|
49
|
+
|
|
50
|
+
每个代理只处理单一问题域,不混合无关任务。
|
|
51
|
+
|
|
52
|
+
### 2. 自足(Self-contained)
|
|
53
|
+
|
|
54
|
+
Prompt 包含执行所需的完整上下文,代理不需要额外提问或搜索。
|
|
55
|
+
|
|
56
|
+
### 3. 明确输出(Specific Output)
|
|
57
|
+
|
|
58
|
+
明确定义期望的返回格式。
|
|
59
|
+
|
|
60
|
+
---
|
|
61
|
+
|
|
62
|
+
## 独立性验证
|
|
63
|
+
|
|
64
|
+
在并行派遣前,必须检查以下条件:
|
|
65
|
+
|
|
66
|
+
| 检查项 | 条件 | 失败时处理 |
|
|
67
|
+
|--------|------|-----------|
|
|
68
|
+
| 文件集合不相交 | 两个任务不修改相同文件 | 串行执行 |
|
|
69
|
+
| 无共享可变状态 | 任务间不依赖共享变量 | 合并为单一任务 |
|
|
70
|
+
| 无执行顺序依赖 | 任务 B 不需要任务 A 的输出 | 串行执行 |
|
|
71
|
+
|
|
72
|
+
## 状态协议
|
|
73
|
+
|
|
74
|
+
每个子代理必须返回标准化状态:
|
|
75
|
+
|
|
76
|
+
| 状态 | 含义 | 后续动作 |
|
|
77
|
+
|------|------|---------|
|
|
78
|
+
| `SUCCESS` | 任务完成,所有验证通过 | 整合结果 |
|
|
79
|
+
| `FAILED` | 任务失败,附带错误详情 | 分析失败原因 |
|
|
80
|
+
| `BLOCKED` | 任务被外部依赖阻塞 | 解除阻塞后重试 |
|
|
81
|
+
| `PARTIAL` | 部分完成,附带进度说明 | 评估是否继续 |
|
|
82
|
+
|
|
83
|
+
## 冲突预防
|
|
84
|
+
|
|
85
|
+
### 文件级隔离
|
|
86
|
+
|
|
87
|
+
```
|
|
88
|
+
代理 A: src/auth/** ← 独立域
|
|
89
|
+
代理 B: src/payments/** ← 独立域
|
|
90
|
+
代理 C: src/shared/** ← ⚠️ 不可并行(共享域)
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
### 合并策略
|
|
94
|
+
|
|
95
|
+
| 情况 | 策略 |
|
|
96
|
+
|------|------|
|
|
97
|
+
| 无冲突 | 自动合并 |
|
|
98
|
+
| 格式冲突(仅空白/排序) | 自动解决 |
|
|
99
|
+
| 语义冲突 | 人工审查 |
|
|
100
|
+
|
|
101
|
+
---
|
|
102
|
+
|
|
103
|
+
## 相关标准
|
|
104
|
+
|
|
105
|
+
- [Git Worktree 隔离](git-worktree.md)
|
|
106
|
+
- [分支完成工作流程](branch-completion.md)
|
|
107
|
+
- [AI 模型选择策略](model-selection.md)
|
|
108
|
+
|
|
109
|
+
---
|
|
110
|
+
|
|
111
|
+
## 许可证
|
|
112
|
+
|
|
113
|
+
本标准采用 [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) 发布。
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
---
|
|
2
|
+
source: ../../../core/ai-agreement-standards.md
|
|
3
|
+
source_version: 1.0.0
|
|
4
|
+
translation_version: 1.0.0
|
|
5
|
+
last_synced: 2026-03-24
|
|
6
|
+
status: current
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
> **语言**: [English](../../../core/ai-agreement-standards.md) | 简体中文
|
|
10
|
+
|
|
11
|
+
# AI 协议标准
|
|
12
|
+
|
|
13
|
+
**版本**: 1.0.0
|
|
14
|
+
**最后更新**: 2026-01-29
|
|
15
|
+
**适用范围**: 所有 AI 辅助开发会话
|
|
16
|
+
**范围**: universal
|
|
17
|
+
**行业标准**: ISO 12207 §6.1
|
|
18
|
+
**参考**: [iso.org](https://www.iso.org/standard/63712.html)
|
|
19
|
+
**ISO 12207 映射**: 协议过程(6.1)
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
## 目的
|
|
24
|
+
|
|
25
|
+
本标准将人类(获取方)与 AI(供应方)之间的交互形式化为可验证的协议。在 "Vibe Coding" 中,prompt 上下文作为管理 AI 行为和交付物的合约。
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
## 1. 上下文合约
|
|
30
|
+
|
|
31
|
+
每个 AI 会话必须以清晰的上下文合约开始。通常通过系统提示文件实现(如 `CLAUDE.md`、`.cursorrules`)。
|
|
32
|
+
|
|
33
|
+
### 1.1 合约组件
|
|
34
|
+
|
|
35
|
+
有效的上下文合约必须定义:
|
|
36
|
+
|
|
37
|
+
| 组件 | 描述 | 示例 |
|
|
38
|
+
|------|------|------|
|
|
39
|
+
| **角色定义** | 谁代表用户 vs. AI | "你是一位资深后端工程师..." |
|
|
40
|
+
| **工作范围** | 操作边界 | "只修改 `src/utils/` 中的文件。不要动 `config/`。" |
|
|
41
|
+
| **约束法则** | 不可协商的规则 | "不要硬编码密钥。始终使用 TypeScript。" |
|
|
42
|
+
| **验收条件** | 完成的定义 | "代码必须通过 `npm test` 和 `npm run lint`。" |
|
|
43
|
+
|
|
44
|
+
---
|
|
45
|
+
|
|
46
|
+
## 2. 需求提案(RFP)标准
|
|
47
|
+
|
|
48
|
+
复杂任务应结构化为 "RFP"(需求提案),而非简单的聊天消息。
|
|
49
|
+
|
|
50
|
+
### 2.1 RFP Prompt 结构
|
|
51
|
+
|
|
52
|
+
请求复杂功能或重构时,使用此结构:
|
|
53
|
+
|
|
54
|
+
```markdown
|
|
55
|
+
# 目标
|
|
56
|
+
[任务的单行摘要]
|
|
57
|
+
|
|
58
|
+
# 上下文与约束
|
|
59
|
+
- **当前状态**: [描述现有代码/架构]
|
|
60
|
+
- **目标状态**: [描述期望结果]
|
|
61
|
+
- **约束**: [如 "必须使用库 X"、"最大复杂度 N"]
|
|
62
|
+
|
|
63
|
+
# 输入数据
|
|
64
|
+
[列出相关文件或粘贴 JSON Schema]
|
|
65
|
+
|
|
66
|
+
# 交付要求
|
|
67
|
+
1. [要求 A]
|
|
68
|
+
2. [要求 B]
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
---
|
|
72
|
+
|
|
73
|
+
## 3. 变更管理
|
|
74
|
+
|
|
75
|
+
### 3.1 范围变更协议
|
|
76
|
+
|
|
77
|
+
| 变更类型 | 处理方式 |
|
|
78
|
+
|---------|---------|
|
|
79
|
+
| **范围内** | 直接实现 |
|
|
80
|
+
| **小范围外** | 提出建议,等待确认 |
|
|
81
|
+
| **大范围外** | 暂停,要求新的 RFP |
|
|
82
|
+
|
|
83
|
+
### 3.2 冲突解决
|
|
84
|
+
|
|
85
|
+
当 AI 检测到指令冲突时:
|
|
86
|
+
|
|
87
|
+
1. 明确指出冲突
|
|
88
|
+
2. 列出冲突的指令
|
|
89
|
+
3. 提出推荐解决方案
|
|
90
|
+
4. 等待人类决策
|
|
91
|
+
|
|
92
|
+
---
|
|
93
|
+
|
|
94
|
+
## 相关标准
|
|
95
|
+
|
|
96
|
+
- [虚拟组织标准](virtual-organization-standards.md)
|
|
97
|
+
- [AI 指令标准](../../../core/ai-instruction-standards.md)
|
|
98
|
+
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
## 许可证
|
|
102
|
+
|
|
103
|
+
本标准采用 [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) 发布。
|
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
---
|
|
2
|
+
source: ../../../core/ai-command-behavior.md
|
|
3
|
+
source_version: 1.0.0
|
|
4
|
+
translation_version: 1.0.0
|
|
5
|
+
last_synced: 2026-03-24
|
|
6
|
+
status: current
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
# AI 命令行为标准
|
|
10
|
+
|
|
11
|
+
> **语言**: [English](../../../core/ai-command-behavior.md) | [繁體中文](../../zh-TW/core/ai-command-behavior.md) | 简体中文
|
|
12
|
+
|
|
13
|
+
**版本**: 1.0.0
|
|
14
|
+
**最后更新**: 2026-03-24
|
|
15
|
+
**适用范围**: 所有使用 AI 辅助命令或技能的项目
|
|
16
|
+
**范围**: universal
|
|
17
|
+
**行业标准**: 无(新兴 AI 工具实践)
|
|
18
|
+
**参考**: [SPEC-STD-07](../../../docs/specs/standards/SPEC-STD-07-ai-command-behavior.md)
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## 目的
|
|
23
|
+
|
|
24
|
+
本标准定义一套结构,用于在命令/技能定义文件中规范 AI Agent 的运行时行为。确保 AI Agent 在执行命令时产生一致、可预测的交互——无论使用哪个 AI 模型或工具。
|
|
25
|
+
|
|
26
|
+
**问题**:命令定义了「做什么」,但缺乏「AI 如何与用户交互」,导致行为不可预测。
|
|
27
|
+
|
|
28
|
+
**解决方案**:标准化的 `## AI Agent Behavior` 区段,包含四个子区段:进入路由、交互脚本、停止点、错误处理。
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
32
|
+
## AI 行为区段结构
|
|
33
|
+
|
|
34
|
+
每个需要 AI 交互的命令定义文件 SHOULD 包含:
|
|
35
|
+
|
|
36
|
+
```markdown
|
|
37
|
+
## AI Agent Behavior | AI 代理行为
|
|
38
|
+
|
|
39
|
+
### Entry Router | 进入路由
|
|
40
|
+
|
|
41
|
+
### Interaction Script | 交互脚本
|
|
42
|
+
|
|
43
|
+
### Stop Points | 停止点
|
|
44
|
+
|
|
45
|
+
### Error Handling | 错误处理
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
---
|
|
49
|
+
|
|
50
|
+
## 区段定义
|
|
51
|
+
|
|
52
|
+
### 1. 进入路由
|
|
53
|
+
|
|
54
|
+
定义 AI 对每种调用模式的行为。对于有多种调用模式的命令,使用决策表。
|
|
55
|
+
|
|
56
|
+
**格式:**
|
|
57
|
+
|
|
58
|
+
```markdown
|
|
59
|
+
| Input | AI Action |
|
|
60
|
+
|-------|-----------|
|
|
61
|
+
| `/cmd` | [无参数时的行为] |
|
|
62
|
+
| `/cmd <name>` | [有名称参数时的行为] |
|
|
63
|
+
| `/cmd <phase>` | [有阶段子命令时的行为] |
|
|
64
|
+
| `/cmd <phase> <target>` | [有阶段和目标时的行为] |
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
**简单命令**(单一调用模式)可以用一行描述代替。
|
|
68
|
+
|
|
69
|
+
**规则:**
|
|
70
|
+
- 每个文档记载的调用模式都必须有对应的条目
|
|
71
|
+
- 「无参数」的情况必须始终定义
|
|
72
|
+
- 进入行为必须是确定性的——不允许模糊
|
|
73
|
+
|
|
74
|
+
### 2. 交互脚本
|
|
75
|
+
|
|
76
|
+
使用**混合精细度**定义逐步 AI 行为:
|
|
77
|
+
|
|
78
|
+
| 元素 | 精细度 | 原因 |
|
|
79
|
+
|------|--------|------|
|
|
80
|
+
| 决策点 | 精确(IF/THEN) | 影响下游流程 |
|
|
81
|
+
| 一般步骤 | 指引式(编号列表) | AI 需要弹性 |
|
|
82
|
+
|
|
83
|
+
**决策点格式:**
|
|
84
|
+
|
|
85
|
+
```markdown
|
|
86
|
+
**Decision: [名称]**
|
|
87
|
+
- IF [条件 A] → [具体行为]
|
|
88
|
+
- IF [条件 B] → [具体行为]
|
|
89
|
+
- ELSE → [默认行为]
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
**一般步骤格式:**
|
|
93
|
+
|
|
94
|
+
```markdown
|
|
95
|
+
1. [步骤描述]
|
|
96
|
+
2. [步骤描述]
|
|
97
|
+
3. [步骤描述]
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
**规则:**
|
|
101
|
+
- 决策点必须使用明确的 IF/THEN/ELSE
|
|
102
|
+
- 一般步骤应使用编号列表
|
|
103
|
+
- 关键输出的格式(AI 展示给用户的内容)应明确指定
|
|
104
|
+
|
|
105
|
+
### 3. 停止点
|
|
106
|
+
|
|
107
|
+
定义 AI 必须暂停并等待用户确认的时刻。
|
|
108
|
+
|
|
109
|
+
**标记格式:**
|
|
110
|
+
|
|
111
|
+
```markdown
|
|
112
|
+
🛑 **STOP**: [描述] — 等待用户确认后再继续
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
**默认停止原则**(当未明确定义停止点时适用):
|
|
116
|
+
|
|
117
|
+
| 情境 | 行为 |
|
|
118
|
+
|------|------|
|
|
119
|
+
| 即将写入/修改文件 | 🛑 停止 |
|
|
120
|
+
| 即将执行不可逆操作 | 🛑 停止 |
|
|
121
|
+
| 阶段完成 | 🛑 停止 |
|
|
122
|
+
| 需要用户提供额外信息 | 🛑 停止 |
|
|
123
|
+
| 只读分析完成,展示结果 | ▶️ 继续 |
|
|
124
|
+
|
|
125
|
+
**规则:**
|
|
126
|
+
- 停止点必须明确——不依赖 AI 判断
|
|
127
|
+
- 每个停止点必须描述 AI 在等待什么
|
|
128
|
+
- 停止点的数量应与操作风险成正比
|
|
129
|
+
|
|
130
|
+
### 4. 错误处理
|
|
131
|
+
|
|
132
|
+
定义前置条件失败或遇到非预期状态时的 AI 行为。
|
|
133
|
+
|
|
134
|
+
**格式:**
|
|
135
|
+
|
|
136
|
+
```markdown
|
|
137
|
+
| 错误条件 | AI 行为 |
|
|
138
|
+
|---------|--------|
|
|
139
|
+
| [前置条件未满足] | [引导到正确步骤] |
|
|
140
|
+
| [非预期状态] | [停止并询问用户] |
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
**默认错误原则:**
|
|
144
|
+
|
|
145
|
+
1. **说明问题**:告诉用户哪个前置条件失败
|
|
146
|
+
2. **引导解决**:建议正确的命令或步骤
|
|
147
|
+
3. **不静默跳过**:不忽略失败继续执行
|
|
148
|
+
4. **不未经许可自动修复**:除非命令定义中明确允许
|
|
149
|
+
5. **不确定时询问**:停止并询问,而非猜测
|
|
150
|
+
|
|
151
|
+
---
|
|
152
|
+
|
|
153
|
+
## 适用规则
|
|
154
|
+
|
|
155
|
+
并非所有命令都需要完整的 `## AI Agent Behavior` 区段。
|
|
156
|
+
|
|
157
|
+
| 条件 | 需要完整定义 | 原因 |
|
|
158
|
+
|------|-------------|------|
|
|
159
|
+
| 多阶段工作流程 | ✅ 是 | 复杂流程需要指引 |
|
|
160
|
+
| 多种调用方式 | ✅ 是 | 否则进入路由模糊 |
|
|
161
|
+
| 单一明确动作 | ❌ 否 | 行为不言自明 |
|
|
162
|
+
| 纯信息查询 | ❌ 否 | 无交互决策 |
|
|
163
|
+
| 子命令编排 | ✅ 是 | 协调逻辑需要定义 |
|
|
164
|
+
|
|
165
|
+
**判断依据**:如果两个不同的 AI 模型可能合理地以不同方式解释该命令,则需要行为定义。
|
|
166
|
+
|
|
167
|
+
---
|
|
168
|
+
|
|
169
|
+
## 示例:最小行为区段
|
|
170
|
+
|
|
171
|
+
以中等复杂度的 `/coverage` 命令为例:
|
|
172
|
+
|
|
173
|
+
```markdown
|
|
174
|
+
## AI Agent Behavior
|
|
175
|
+
|
|
176
|
+
### Entry Router
|
|
177
|
+
|
|
178
|
+
| Input | AI Action |
|
|
179
|
+
|-------|-----------|
|
|
180
|
+
| `/coverage` | 检测测试框架,运行覆盖率,展示摘要 |
|
|
181
|
+
| `/coverage <path>` | 仅对指定路径运行覆盖率 |
|
|
182
|
+
|
|
183
|
+
### Interaction Script
|
|
184
|
+
|
|
185
|
+
1. 检测项目测试框架(查找 jest.config、vitest.config 等)
|
|
186
|
+
2. 运行覆盖率命令
|
|
187
|
+
3. 解析输出并呈现摘要表格
|
|
188
|
+
|
|
189
|
+
**Decision: 检测到低覆盖率**
|
|
190
|
+
- IF 覆盖率 < 项目阈值 → 突显差距,建议需要测试的文件
|
|
191
|
+
- ELSE → 仅展示摘要
|
|
192
|
+
|
|
193
|
+
### Stop Points
|
|
194
|
+
|
|
195
|
+
🛑 **STOP**: 展示覆盖率摘要后 — 询问用户是否需要逐文件明细
|
|
196
|
+
|
|
197
|
+
### Error Handling
|
|
198
|
+
|
|
199
|
+
| 错误条件 | AI 行为 |
|
|
200
|
+
|---------|--------|
|
|
201
|
+
| 未检测到测试框架 | 询问用户使用哪个框架 |
|
|
202
|
+
| 覆盖率运行期间测试失败 | 先展示失败,询问是否仍要覆盖率 |
|
|
203
|
+
```
|
|
204
|
+
|
|
205
|
+
---
|
|
206
|
+
|
|
207
|
+
## 快速参考卡
|
|
208
|
+
|
|
209
|
+
### 区段检查清单
|
|
210
|
+
|
|
211
|
+
| 区段 | 必须定义 | 关键规则 |
|
|
212
|
+
|------|---------|---------|
|
|
213
|
+
| 进入路由 | 所有调用模式 | 「无参数」情况必须定义 |
|
|
214
|
+
| 交互脚本 | 决策点 + 一般流程 | 决策 = 精确,步骤 = 指引 |
|
|
215
|
+
| 停止点 | 每个暂停时刻 | 明确标记,不靠 AI 猜测 |
|
|
216
|
+
| 错误处理 | 前置条件失败 | 不静默跳过 |
|
|
217
|
+
|
|
218
|
+
### 精细度指引
|
|
219
|
+
|
|
220
|
+
| 元素 | 层级 | 格式 |
|
|
221
|
+
|------|------|------|
|
|
222
|
+
| 进入路由 | 精确 | 决策表 |
|
|
223
|
+
| 停止点 | 精确 | 🛑 标记 |
|
|
224
|
+
| 交互脚本 | 指引式 | 编号步骤 + 决策用 IF/THEN |
|
|
225
|
+
| 错误处理 | 原则式 | 错误表 + 默认规则 |
|
|
226
|
+
|
|
227
|
+
---
|
|
228
|
+
|
|
229
|
+
## 相关标准
|
|
230
|
+
|
|
231
|
+
- [AI 指令文件规范](ai-instruction-standards.md) — AI 指令文件的文件结构
|
|
232
|
+
- [AI 协议标准](ai-agreement-standards.md) — 人机协作协议
|
|
233
|
+
- [反幻觉规范](anti-hallucination.md) — 基于证据的 AI 行为
|
|
234
|
+
|
|
235
|
+
---
|
|
236
|
+
|
|
237
|
+
## 版本历史
|
|
238
|
+
|
|
239
|
+
| 版本 | 日期 | 变更 |
|
|
240
|
+
|------|------|------|
|
|
241
|
+
| 1.0.0 | 2026-03-24 | 初始版本 |
|
|
242
|
+
|
|
243
|
+
---
|
|
244
|
+
|
|
245
|
+
## 许可
|
|
246
|
+
|
|
247
|
+
本标准依 [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) 许可发布。
|