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,66 @@
|
|
|
1
|
+
---
|
|
2
|
+
source: ../../../core/deployment-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
|
+
# 部署標準
|
|
10
|
+
|
|
11
|
+
> **語言**: [English](../../../core/deployment-standards.md) | 繁體中文
|
|
12
|
+
|
|
13
|
+
**版本**: 1.0.0
|
|
14
|
+
**最後更新**: 2026-02-09
|
|
15
|
+
**適用性**: 所有具有部署管線的軟體專案
|
|
16
|
+
**範圍**: 通用 (Universal)
|
|
17
|
+
**業界標準**: Twelve-Factor App、Google SRE — Release Engineering、DORA State of DevOps
|
|
18
|
+
**參考**: [12factor.net](https://12factor.net/)、[sre.google](https://sre.google/books/)、[dora.dev](https://dora.dev/)
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## 目的
|
|
23
|
+
|
|
24
|
+
本標準定義安全部署軟體到正式環境的指南,涵蓋部署策略、Feature Flags、回滾程序、環境一致性和部署效能指標。
|
|
25
|
+
|
|
26
|
+
**參考標準**:
|
|
27
|
+
- [The Twelve-Factor App](https://12factor.net/) — Factor X:開發/正式一致性
|
|
28
|
+
- [Google SRE Book — Release Engineering](https://sre.google/sre-book/release-engineering/)
|
|
29
|
+
- [DORA State of DevOps Report](https://dora.dev/)
|
|
30
|
+
|
|
31
|
+
---
|
|
32
|
+
|
|
33
|
+
## 核心原則
|
|
34
|
+
|
|
35
|
+
| 原則 | 說明 |
|
|
36
|
+
|------|------|
|
|
37
|
+
| **部署 ≠ 發布** | 部署程式碼到正式環境和將其暴露給使用者是分開的動作;使用 Feature Flags 控制曝光 |
|
|
38
|
+
| **漸進式曝光** | 將變更推送給越來越大的受眾:內部 → 金絲雀 → 百分比 → 全面上線 |
|
|
39
|
+
| **快速回滾** | 每次部署必須有經過測試的回滾路徑,在 5 分鐘內完成 |
|
|
40
|
+
| **環境一致性** | 保持開發、暫存和正式環境盡可能相似(Twelve-Factor App Factor X) |
|
|
41
|
+
| **自動化一切** | 手動部署步驟容易出錯;自動化建置、測試、部署和回滾 |
|
|
42
|
+
| **監控一切** | 部署時必須具備可觀測性;無法測量就無法安全部署 |
|
|
43
|
+
|
|
44
|
+
## 部署策略選擇
|
|
45
|
+
|
|
46
|
+
| 策略 | 停機時間 | 風險 | 適用場景 |
|
|
47
|
+
|------|----------|------|----------|
|
|
48
|
+
| **滾動更新 (Rolling)** | 零 | 低 | 無狀態服務 |
|
|
49
|
+
| **藍綠部署 (Blue-Green)** | 接近零 | 低 | 需要即時回滾 |
|
|
50
|
+
| **金絲雀部署 (Canary)** | 零 | 極低 | 高流量服務 |
|
|
51
|
+
| **重建 (Recreate)** | 有 | 中 | 資料庫遷移 |
|
|
52
|
+
|
|
53
|
+
## DORA 指標
|
|
54
|
+
|
|
55
|
+
| 指標 | 菁英水準 | 高水準 |
|
|
56
|
+
|------|----------|--------|
|
|
57
|
+
| 部署頻率 | 每天多次 | 每週至每月 |
|
|
58
|
+
| 變更前置時間 | < 1 小時 | 1 天至 1 週 |
|
|
59
|
+
| 故障率 | 0-15% | 16-30% |
|
|
60
|
+
| 服務恢復時間 | < 1 小時 | < 1 天 |
|
|
61
|
+
|
|
62
|
+
## 相關標準
|
|
63
|
+
|
|
64
|
+
- [安全標準](security-standards.md)
|
|
65
|
+
- [效能標準](performance-standards.md)
|
|
66
|
+
- [測試標準](testing-standards.md)
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
---
|
|
2
2
|
source: ../../../core/error-code-standards.md
|
|
3
|
-
source_version: 1.
|
|
4
|
-
translation_version: 1.
|
|
5
|
-
last_synced: 2026-
|
|
3
|
+
source_version: 1.2.0
|
|
4
|
+
translation_version: 1.2.0
|
|
5
|
+
last_synced: 2026-03-18
|
|
6
6
|
status: current
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
# 錯誤碼標準
|
|
10
10
|
|
|
11
|
-
> 版本: 1.
|
|
11
|
+
> 版本: 1.2.0 | 最後更新: 2026-03-18
|
|
12
12
|
|
|
13
13
|
## 概述
|
|
14
14
|
|
|
@@ -284,6 +284,228 @@ function validateEmail(email: string) {
|
|
|
284
284
|
}
|
|
285
285
|
```
|
|
286
286
|
|
|
287
|
+
## API 錯誤序列化
|
|
288
|
+
|
|
289
|
+
### RFC 7807 / RFC 9457 Problem Details
|
|
290
|
+
|
|
291
|
+
HTTP API 應使用 [RFC 7807](https://datatracker.ietf.org/doc/html/rfc7807) Problem Details 格式作為標準錯誤封裝:
|
|
292
|
+
|
|
293
|
+
```json
|
|
294
|
+
{
|
|
295
|
+
"type": "https://api.example.com/errors/auth-val-001",
|
|
296
|
+
"title": "Validation Error",
|
|
297
|
+
"status": 400,
|
|
298
|
+
"detail": "Email field is required for registration",
|
|
299
|
+
"instance": "/api/register",
|
|
300
|
+
"code": "AUTH_VAL_001",
|
|
301
|
+
"errors": [
|
|
302
|
+
{
|
|
303
|
+
"field": "email",
|
|
304
|
+
"message": "Email is required",
|
|
305
|
+
"code": "AUTH_VAL_001"
|
|
306
|
+
}
|
|
307
|
+
],
|
|
308
|
+
"requestId": "req_abc123",
|
|
309
|
+
"timestamp": "2026-03-18T10:30:00Z"
|
|
310
|
+
}
|
|
311
|
+
```
|
|
312
|
+
|
|
313
|
+
**必要欄位(RFC 7807):**
|
|
314
|
+
|
|
315
|
+
| 欄位 | 型別 | 描述 |
|
|
316
|
+
|------|------|------|
|
|
317
|
+
| `type` | URI | 錯誤文件參考連結 |
|
|
318
|
+
| `title` | string | 簡短的人類可讀摘要 |
|
|
319
|
+
| `status` | integer | HTTP 狀態碼 |
|
|
320
|
+
| `detail` | string | 人類可讀的詳細說明 |
|
|
321
|
+
| `instance` | string | 引發錯誤的請求 URI |
|
|
322
|
+
|
|
323
|
+
**擴充欄位(建議):**
|
|
324
|
+
|
|
325
|
+
| 欄位 | 型別 | 描述 |
|
|
326
|
+
|------|------|------|
|
|
327
|
+
| `code` | string | 應用程式錯誤碼(PREFIX_CATEGORY_NUMBER) |
|
|
328
|
+
| `errors` | array | 欄位層級的詳細錯誤 |
|
|
329
|
+
| `requestId` | string | 用於追蹤的關聯 ID |
|
|
330
|
+
| `timestamp` | string | ISO 8601 時間戳 |
|
|
331
|
+
|
|
332
|
+
### REST JSON 錯誤回應
|
|
333
|
+
|
|
334
|
+
結合內部錯誤碼與 RFC 7807 的標準 REST 錯誤回應:
|
|
335
|
+
|
|
336
|
+
```json
|
|
337
|
+
// 單一錯誤
|
|
338
|
+
{
|
|
339
|
+
"type": "https://api.example.com/errors/validation",
|
|
340
|
+
"title": "Validation Error",
|
|
341
|
+
"status": 400,
|
|
342
|
+
"detail": "Request validation failed",
|
|
343
|
+
"errors": [
|
|
344
|
+
{
|
|
345
|
+
"code": "AUTH_VAL_001",
|
|
346
|
+
"field": "email",
|
|
347
|
+
"message": "Email is required",
|
|
348
|
+
"pointer": "/data/attributes/email"
|
|
349
|
+
}
|
|
350
|
+
]
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
// 多重錯誤
|
|
354
|
+
{
|
|
355
|
+
"type": "https://api.example.com/errors/validation",
|
|
356
|
+
"title": "Validation Error",
|
|
357
|
+
"status": 400,
|
|
358
|
+
"detail": "Multiple validation errors occurred",
|
|
359
|
+
"errors": [
|
|
360
|
+
{
|
|
361
|
+
"code": "AUTH_VAL_001",
|
|
362
|
+
"field": "email",
|
|
363
|
+
"message": "Email is required",
|
|
364
|
+
"pointer": "/data/attributes/email"
|
|
365
|
+
},
|
|
366
|
+
{
|
|
367
|
+
"code": "AUTH_VAL_201",
|
|
368
|
+
"field": "password",
|
|
369
|
+
"message": "Password must be at least 8 characters",
|
|
370
|
+
"pointer": "/data/attributes/password"
|
|
371
|
+
}
|
|
372
|
+
]
|
|
373
|
+
}
|
|
374
|
+
```
|
|
375
|
+
|
|
376
|
+
### GraphQL 錯誤處理
|
|
377
|
+
|
|
378
|
+
GraphQL 使用不同的錯誤模型。將應用程式錯誤碼映射到 `extensions` 欄位:
|
|
379
|
+
|
|
380
|
+
```json
|
|
381
|
+
{
|
|
382
|
+
"data": null,
|
|
383
|
+
"errors": [
|
|
384
|
+
{
|
|
385
|
+
"message": "Email is required",
|
|
386
|
+
"locations": [{ "line": 2, "column": 3 }],
|
|
387
|
+
"path": ["createUser"],
|
|
388
|
+
"extensions": {
|
|
389
|
+
"code": "AUTH_VAL_001",
|
|
390
|
+
"category": "VALIDATION",
|
|
391
|
+
"field": "email",
|
|
392
|
+
"httpStatus": 400,
|
|
393
|
+
"timestamp": "2026-03-18T10:30:00Z"
|
|
394
|
+
}
|
|
395
|
+
}
|
|
396
|
+
]
|
|
397
|
+
}
|
|
398
|
+
```
|
|
399
|
+
|
|
400
|
+
**GraphQL 錯誤類別:**
|
|
401
|
+
|
|
402
|
+
| 類別 | 對應 | 用途 |
|
|
403
|
+
|------|------|------|
|
|
404
|
+
| `VALIDATION` | VAL | 輸入驗證失敗 |
|
|
405
|
+
| `BUSINESS_RULE` | BIZ | 業務邏輯違反 |
|
|
406
|
+
| `AUTHENTICATION` | AUTH (001-099) | 身份驗證失敗 |
|
|
407
|
+
| `AUTHORIZATION` | AUTH (100-199) | 權限失敗 |
|
|
408
|
+
| `INTERNAL` | SYS | 伺服器端錯誤 |
|
|
409
|
+
| `NETWORK` | NET | 上游服務失敗 |
|
|
410
|
+
|
|
411
|
+
### gRPC 錯誤處理
|
|
412
|
+
|
|
413
|
+
將應用程式錯誤碼映射到 gRPC 狀態碼,並透過 metadata 傳遞詳細資訊:
|
|
414
|
+
|
|
415
|
+
```protobuf
|
|
416
|
+
// 錯誤詳情訊息
|
|
417
|
+
message ErrorDetail {
|
|
418
|
+
string code = 1; // "AUTH_VAL_001"
|
|
419
|
+
string message = 2; // 人類可讀訊息
|
|
420
|
+
string field = 3; // 受影響的欄位
|
|
421
|
+
string documentation = 4; // 錯誤文件連結
|
|
422
|
+
}
|
|
423
|
+
```
|
|
424
|
+
|
|
425
|
+
**gRPC 狀態碼對應:**
|
|
426
|
+
|
|
427
|
+
| 類別 | gRPC 狀態 | 代碼 |
|
|
428
|
+
|------|----------|------|
|
|
429
|
+
| VAL | `INVALID_ARGUMENT` | 3 |
|
|
430
|
+
| BIZ | `FAILED_PRECONDITION` | 9 |
|
|
431
|
+
| AUTH (001-099) | `UNAUTHENTICATED` | 16 |
|
|
432
|
+
| AUTH (100-199) | `PERMISSION_DENIED` | 7 |
|
|
433
|
+
| SYS | `INTERNAL` | 13 |
|
|
434
|
+
| NET | `UNAVAILABLE` | 14 |
|
|
435
|
+
|
|
436
|
+
```go
|
|
437
|
+
// Go 範例
|
|
438
|
+
import "google.golang.org/grpc/status"
|
|
439
|
+
import "google.golang.org/grpc/codes"
|
|
440
|
+
|
|
441
|
+
st := status.New(codes.InvalidArgument, "Validation failed")
|
|
442
|
+
st, _ = st.WithDetails(&errdetails.BadRequest{
|
|
443
|
+
FieldViolations: []*errdetails.BadRequest_FieldViolation{
|
|
444
|
+
{Field: "email", Description: "AUTH_VAL_001: Email is required"},
|
|
445
|
+
},
|
|
446
|
+
})
|
|
447
|
+
return st.Err()
|
|
448
|
+
```
|
|
449
|
+
|
|
450
|
+
## 重試與冪等性
|
|
451
|
+
|
|
452
|
+
### 重試指導
|
|
453
|
+
|
|
454
|
+
| 類別 | 可重試 | 策略 |
|
|
455
|
+
|------|--------|------|
|
|
456
|
+
| VAL | 否 | 修正輸入後重新提交 |
|
|
457
|
+
| BIZ | 否 | 解決業務條件 |
|
|
458
|
+
| AUTH (001-099) | 否 | 重新驗證身份 |
|
|
459
|
+
| AUTH (200-299) | 是 | 重新整理令牌後重試 |
|
|
460
|
+
| SYS | 視情況 | 指數退避重試 |
|
|
461
|
+
| NET | 是 | 指數退避重試 |
|
|
462
|
+
|
|
463
|
+
### 重試回應標頭
|
|
464
|
+
|
|
465
|
+
```http
|
|
466
|
+
HTTP/1.1 503 Service Unavailable
|
|
467
|
+
Retry-After: 30
|
|
468
|
+
X-RateLimit-Reset: 1679961600
|
|
469
|
+
```
|
|
470
|
+
|
|
471
|
+
在錯誤回應中包含重試指導:
|
|
472
|
+
|
|
473
|
+
```json
|
|
474
|
+
{
|
|
475
|
+
"type": "https://api.example.com/errors/rate-limit",
|
|
476
|
+
"title": "Rate Limit Exceeded",
|
|
477
|
+
"status": 429,
|
|
478
|
+
"detail": "Too many requests",
|
|
479
|
+
"code": "API_NET_429",
|
|
480
|
+
"retryable": true,
|
|
481
|
+
"retryAfter": 30
|
|
482
|
+
}
|
|
483
|
+
```
|
|
484
|
+
|
|
485
|
+
### 冪等性金鑰
|
|
486
|
+
|
|
487
|
+
對於非冪等操作(POST),要求 `Idempotency-Key` 標頭:
|
|
488
|
+
|
|
489
|
+
```http
|
|
490
|
+
POST /api/payments HTTP/1.1
|
|
491
|
+
Idempotency-Key: key_abc123def456
|
|
492
|
+
Content-Type: application/json
|
|
493
|
+
|
|
494
|
+
{"amount": 100, "currency": "USD"}
|
|
495
|
+
```
|
|
496
|
+
|
|
497
|
+
**冪等性規則:**
|
|
498
|
+
|
|
499
|
+
| 動詞 | 冪等 | 需要金鑰 |
|
|
500
|
+
|------|------|---------|
|
|
501
|
+
| GET | 是 | 否 |
|
|
502
|
+
| PUT | 是 | 否 |
|
|
503
|
+
| DELETE | 是 | 否 |
|
|
504
|
+
| PATCH | 否 | 建議 |
|
|
505
|
+
| POST | 否 | 關鍵操作必須 |
|
|
506
|
+
|
|
507
|
+
---
|
|
508
|
+
|
|
287
509
|
## 文件需求
|
|
288
510
|
|
|
289
511
|
### 錯誤碼文件
|
|
@@ -365,6 +587,7 @@ AUTH_VAL_001
|
|
|
365
587
|
|
|
366
588
|
| 版本 | 日期 | 變更 |
|
|
367
589
|
|-----|------|------|
|
|
590
|
+
| 1.2.0 | 2026-03-18 | 新增:API 錯誤序列化(RFC 7807 Problem Details、REST、GraphQL、gRPC)、重試與冪等性指導 |
|
|
368
591
|
| 1.1.0 | 2026-01-05 | 新增:參考標準章節,包含 RFC 7807、RFC 9457、HTTP 狀態碼和 Microsoft REST API 指南 |
|
|
369
592
|
| 1.0.0 | 2025-12-30 | 初始錯誤碼標準 |
|
|
370
593
|
|
|
@@ -376,6 +599,9 @@ AUTH_VAL_001
|
|
|
376
599
|
- [RFC 9457 - HTTP API 問題詳情](https://datatracker.ietf.org/doc/html/rfc9457) - RFC 7807 更新版 (2023)
|
|
377
600
|
- [HTTP 狀態碼 (MDN)](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status) - HTTP 狀態碼參考
|
|
378
601
|
- [Microsoft REST API 指南 - 錯誤處理](https://github.com/microsoft/api-guidelines/blob/vNext/azure/Guidelines.md#handling-errors) - 業界最佳實踐
|
|
602
|
+
- [GraphQL 規範 - 錯誤](https://spec.graphql.org/October2021/#sec-Errors) - GraphQL 錯誤格式規範
|
|
603
|
+
- [gRPC 狀態碼](https://grpc.github.io/grpc/core/md_doc_statuscodes.html) - gRPC 錯誤處理參考
|
|
604
|
+
- [Google API 設計指南 - 錯誤](https://cloud.google.com/apis/design/errors) - Google API 錯誤設計模式
|
|
379
605
|
|
|
380
606
|
---
|
|
381
607
|
|
|
@@ -1,7 +1,15 @@
|
|
|
1
|
+
---
|
|
2
|
+
source: ../../../core/forward-derivation-standards.md
|
|
3
|
+
source_version: 1.2.0
|
|
4
|
+
translation_version: 1.2.0
|
|
5
|
+
last_synced: 2026-03-18
|
|
6
|
+
status: current
|
|
7
|
+
---
|
|
8
|
+
|
|
1
9
|
# 正向推演標準 | Forward Derivation Standards
|
|
2
10
|
|
|
3
|
-
**版本**: 1.
|
|
4
|
-
**最後更新**: 2026-
|
|
11
|
+
**版本**: 1.2.0
|
|
12
|
+
**最後更新**: 2026-03-18
|
|
5
13
|
**適用範圍**: 所有使用規格驅動開發的專案
|
|
6
14
|
|
|
7
15
|
> **語言**: [English](../../../core/forward-derivation-standards.md) | 繁體中文
|
|
@@ -363,6 +371,57 @@ spec-review → forward-derivation → discovery
|
|
|
363
371
|
|
|
364
372
|
---
|
|
365
373
|
|
|
374
|
+
## Pipeline 整合
|
|
375
|
+
|
|
376
|
+
### 自動 TDD 轉換
|
|
377
|
+
|
|
378
|
+
當正向推演由自動化 Pipeline 觸發時(參見 [Pipeline 整合標準](pipeline-integration-standards.md)),以下規則適用於轉換至 TDD 循環:
|
|
379
|
+
|
|
380
|
+
#### Auto-TDD 進入規則
|
|
381
|
+
|
|
382
|
+
| 規則 | 說明 |
|
|
383
|
+
|------|------|
|
|
384
|
+
| **推演完整性** | 所有推演輸出(BDD、TDD、ATDD)必須在進入 TDD 前完成生成 |
|
|
385
|
+
| **RED 狀態初始化** | Pipeline 在生成測試骨架後將 TDD 狀態設為 RED |
|
|
386
|
+
| **測試骨架驗證** | 生成的測試檔案必須能編譯/解析無誤後才能進入 RED |
|
|
387
|
+
| **AC 計數驗證** | 進入轉換前驗證輸出測試數量與 AC 數量匹配 |
|
|
388
|
+
|
|
389
|
+
#### Pipeline Hooks
|
|
390
|
+
|
|
391
|
+
推演步驟可透過 Pipeline 事件自動觸發:
|
|
392
|
+
|
|
393
|
+
| Hook | 觸發條件 | 動作 |
|
|
394
|
+
|------|---------|------|
|
|
395
|
+
| `on-spec-approved` | Spec 狀態變更為「已批准」 | 啟動推演 Pipeline |
|
|
396
|
+
| `on-derivation-complete` | 所有推演輸出已生成 | 轉換至 TDD RED 階段 |
|
|
397
|
+
| `on-tdd-green` | 所有推演測試通過 | 觸發審查階段 |
|
|
398
|
+
|
|
399
|
+
#### Auto-TDD 進入工作流程
|
|
400
|
+
|
|
401
|
+
```
|
|
402
|
+
┌──────────────┐ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐
|
|
403
|
+
│ Spec Approved│───▶│ Derive All │───▶│ Verify Count │───▶│ TDD RED │
|
|
404
|
+
│ (hook) │ │ BDD+TDD+ATDD│ │ AC = Tests │ │ (auto-set) │
|
|
405
|
+
└──────────────┘ └──────────────┘ └──────────────┘ └──────────────┘
|
|
406
|
+
```
|
|
407
|
+
|
|
408
|
+
1. **Spec 批准**:Pipeline 偵測到 Spec 批准(透過 hook 或輪詢)
|
|
409
|
+
2. **完整推演**:Pipeline 以專案配置的語言/框架執行 `/derive-all`
|
|
410
|
+
3. **計數驗證**:Pipeline 驗證輸出數量與 AC 數量匹配(反幻覺)
|
|
411
|
+
4. **RED 狀態**:Pipeline 將 TDD 狀態設為 RED;測試骨架存在但 assertion 為 [TODO]
|
|
412
|
+
|
|
413
|
+
#### 與 Pipeline 階段的整合
|
|
414
|
+
|
|
415
|
+
正向推演對應 [Pipeline 整合標準](pipeline-integration-standards.md) 6 階段模型中的 **DERIVE** 階段:
|
|
416
|
+
|
|
417
|
+
| Pipeline 階段 | 正向推演角色 |
|
|
418
|
+
|--------------|------------|
|
|
419
|
+
| SPEC | 輸入:已批准的規格 |
|
|
420
|
+
| **DERIVE** | 執行:解析 AC → 生成 BDD/TDD/ATDD 輸出 |
|
|
421
|
+
| BUILD | 輸出:測試骨架進入 TDD RED→GREEN 循環 |
|
|
422
|
+
|
|
423
|
+
---
|
|
424
|
+
|
|
366
425
|
## 應避免的反模式
|
|
367
426
|
|
|
368
427
|
### 生成反模式
|
|
@@ -424,6 +483,7 @@ spec-review → forward-derivation → discovery
|
|
|
424
483
|
|
|
425
484
|
| 版本 | 日期 | 變更 |
|
|
426
485
|
|------|------|------|
|
|
486
|
+
| 1.2.0 | 2026-03-18 | 新增:Pipeline 整合章節 — auto-TDD 轉換、pipeline hooks、auto-TDD 進入工作流程 |
|
|
427
487
|
| 1.0.0 | 2026-01-19 | 初始發布 |
|
|
428
488
|
|
|
429
489
|
---
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
---
|
|
2
|
+
source: ../../../core/git-worktree.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
|
+
# Git Worktree 隔離
|
|
10
|
+
|
|
11
|
+
> **語言**: [English](../../../core/git-worktree.md) | 繁體中文
|
|
12
|
+
|
|
13
|
+
**版本**: 1.0.0
|
|
14
|
+
**最後更新**: 2026-03-20
|
|
15
|
+
**適用性**: 所有使用 Git 進行版本控制的專案
|
|
16
|
+
**範圍**: 通用 (Universal)
|
|
17
|
+
**靈感來源**: [Superpowers](https://github.com/obra/superpowers) — using-git-worktrees (MIT)
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
## 目的
|
|
22
|
+
|
|
23
|
+
定義 Git Worktree 的完整生命週期管理標準,確保環境乾淨、安全合併與適當清理。Worktree 允許在多個分支上並行工作,無需 stash 或切換。
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## 術語表
|
|
28
|
+
|
|
29
|
+
| 術語 | 定義 |
|
|
30
|
+
|------|------|
|
|
31
|
+
| Worktree | Git 儲存庫在不同分支上的鏈接工作副本 |
|
|
32
|
+
| 基準測試 (Baseline Test) | 在新建 worktree 上執行的測試,用於驗證環境是乾淨的 |
|
|
33
|
+
| Worktree 目錄 | worktree 被建立的檔案系統路徑 |
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## 核心原則 — 隔離與責任
|
|
38
|
+
|
|
39
|
+
> **每個 worktree 必須以乾淨狀態開始(基準測試)、在隔離環境中工作、以合併或明確清理結束。**
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## 生命週期階段
|
|
44
|
+
|
|
45
|
+
### 階段 1:建立
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
# 建立新的 worktree
|
|
49
|
+
git worktree add ../project-feature-name feature/feature-name
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
| 步驟 | 說明 |
|
|
53
|
+
|------|------|
|
|
54
|
+
| 1. 建立 worktree | 指定路徑和分支名稱 |
|
|
55
|
+
| 2. 安裝依賴 | 在新 worktree 中執行 `npm install` 等 |
|
|
56
|
+
| 3. 基準測試 | 執行測試確認環境乾淨 |
|
|
57
|
+
|
|
58
|
+
### 階段 2:工作
|
|
59
|
+
|
|
60
|
+
- 在 worktree 中正常開發
|
|
61
|
+
- 各 worktree 之間完全隔離
|
|
62
|
+
- 不影響主工作目錄
|
|
63
|
+
|
|
64
|
+
### 階段 3:完成
|
|
65
|
+
|
|
66
|
+
| 選項 | 指令 |
|
|
67
|
+
|------|------|
|
|
68
|
+
| 合併 | 在主目錄中執行 `git merge feature/name` |
|
|
69
|
+
| 丟棄 | 執行清理流程 |
|
|
70
|
+
|
|
71
|
+
### 階段 4:清理
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
# 移除 worktree
|
|
75
|
+
git worktree remove ../project-feature-name
|
|
76
|
+
|
|
77
|
+
# 列出所有 worktree
|
|
78
|
+
git worktree list
|
|
79
|
+
|
|
80
|
+
# 清理過時的 worktree 參考
|
|
81
|
+
git worktree prune
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
## 命名慣例
|
|
85
|
+
|
|
86
|
+
| 元素 | 格式 | 範例 |
|
|
87
|
+
|------|------|------|
|
|
88
|
+
| Worktree 目錄 | `../project-feature-name` | `../myapp-login-fix` |
|
|
89
|
+
| 分支名稱 | `feature/name` 或 `fix/name` | `feature/user-auth` |
|
|
90
|
+
|
|
91
|
+
## 最佳實踐
|
|
92
|
+
|
|
93
|
+
| 實踐 | 原因 |
|
|
94
|
+
|------|------|
|
|
95
|
+
| 建立後立即執行基準測試 | 確認環境乾淨 |
|
|
96
|
+
| 完成後立即清理 | 避免 worktree 累積 |
|
|
97
|
+
| 不要在 worktree 之間共享未提交的變更 | 防止衝突 |
|
|
98
|
+
| 定期執行 `git worktree prune` | 清理過時參考 |
|
|
99
|
+
|
|
100
|
+
## 相關標準
|
|
101
|
+
|
|
102
|
+
- [分支完成工作流程](branch-completion.md)
|
|
103
|
+
- [代理派遣與並行協調](agent-dispatch.md)
|
|
104
|
+
- [Git 工作流](git-workflow.md)
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
---
|
|
2
|
+
source: ../../../core/model-selection.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/model-selection.md) | 繁體中文
|
|
12
|
+
|
|
13
|
+
**版本**: 1.0.0
|
|
14
|
+
**最後更新**: 2026-03-20
|
|
15
|
+
**適用性**: 使用多模型分級的 AI 輔助開發
|
|
16
|
+
**範圍**: 通用 (Universal)
|
|
17
|
+
**靈感來源**: [Superpowers](https://github.com/obra/superpowers) — subagent-driven-development (MIT)
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
## 目的
|
|
22
|
+
|
|
23
|
+
定義基於任務複雜度的 AI 模型分級選擇策略。使用能勝任的最便宜模型,僅在必要時升級。
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## 術語表
|
|
28
|
+
|
|
29
|
+
| 術語 | 定義 |
|
|
30
|
+
|------|------|
|
|
31
|
+
| 模型分級 (Model Tier) | 代表模型能力和成本的分類等級 |
|
|
32
|
+
| 複雜度信號 (Complexity Signal) | 指示所需能力等級的任務可觀察特徵 |
|
|
33
|
+
| 升級 (Escalation) | 低級模型失敗後升級到高級模型 |
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## 核心原則 — 成本效益
|
|
38
|
+
|
|
39
|
+
> **始終使用與任務複雜度匹配的最便宜模型。**
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## 三級模型分類
|
|
44
|
+
|
|
45
|
+
| 級別 | 適用場景 | 複雜度信號 |
|
|
46
|
+
|------|----------|-----------|
|
|
47
|
+
| **Tier 1(輕量級)** | 簡單、重複性任務 | 單一檔案、格式化、搜尋替換 |
|
|
48
|
+
| **Tier 2(標準級)** | 中等複雜度任務 | 多檔案、邏輯修改、測試撰寫 |
|
|
49
|
+
| **Tier 3(高級)** | 高複雜度任務 | 架構設計、跨系統整合、除錯 |
|
|
50
|
+
|
|
51
|
+
## 複雜度信號判斷
|
|
52
|
+
|
|
53
|
+
| 信號 | Tier 1 | Tier 2 | Tier 3 |
|
|
54
|
+
|------|--------|--------|--------|
|
|
55
|
+
| 涉及檔案數 | 1 | 2-5 | 6+ |
|
|
56
|
+
| 需要推理深度 | 淺 | 中 | 深 |
|
|
57
|
+
| 跨模組互動 | 無 | 有限 | 複雜 |
|
|
58
|
+
| 需要創意/設計 | 無 | 部分 | 大量 |
|
|
59
|
+
| 錯誤風險 | 低 | 中 | 高 |
|
|
60
|
+
|
|
61
|
+
## 升級規則
|
|
62
|
+
|
|
63
|
+
| 觸發條件 | 動作 |
|
|
64
|
+
|----------|------|
|
|
65
|
+
| 低級模型產生錯誤輸出 | 升級到下一級別 |
|
|
66
|
+
| 任務超出預期複雜度 | 升級到下一級別 |
|
|
67
|
+
| 多次重試仍失敗 | 升級到最高級別 |
|
|
68
|
+
| 安全性或架構關鍵任務 | 直接使用最高級別 |
|
|
69
|
+
|
|
70
|
+
## 成本最佳化策略
|
|
71
|
+
|
|
72
|
+
| 策略 | 說明 |
|
|
73
|
+
|------|------|
|
|
74
|
+
| **批次處理** | 將多個簡單任務合併為一次呼叫 |
|
|
75
|
+
| **快取** | 快取常見查詢結果避免重複呼叫 |
|
|
76
|
+
| **預篩選** | 先用低成本模型判斷是否需要升級 |
|
|
77
|
+
| **任務分解** | 將複雜任務拆分為多個簡單子任務 |
|
|
78
|
+
|
|
79
|
+
## 相關標準
|
|
80
|
+
|
|
81
|
+
- [代理派遣與並行協調](agent-dispatch.md)
|
|
82
|
+
- [驗證證據](verification-evidence.md)
|
|
83
|
+
- [系統化除錯](systematic-debugging.md)
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
---
|
|
2
|
+
source: ../../../core/performance-standards.md
|
|
3
|
+
source_version: 1.1.0
|
|
4
|
+
translation_version: 1.1.0
|
|
5
|
+
last_synced: 2026-03-24
|
|
6
|
+
status: current
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
# 效能標準
|
|
10
|
+
|
|
11
|
+
> **語言**: [English](../../../core/performance-standards.md) | 繁體中文
|
|
12
|
+
|
|
13
|
+
**版本**: 1.1.0
|
|
14
|
+
**最後更新**: 2026-01-29
|
|
15
|
+
**適用性**: 所有軟體專案
|
|
16
|
+
**範圍**: 通用 (Universal)
|
|
17
|
+
**業界標準**: ISO/IEC 25010 效能效率
|
|
18
|
+
**參考**: [sre.google](https://sre.google/books/)
|
|
19
|
+
|
|
20
|
+
> **詳細說明與最佳化技術,請參閱 [效能指南](../../../core/guides/performance-guide.md)**
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## 目的
|
|
25
|
+
|
|
26
|
+
本標準定義軟體效能工程的完整指南,涵蓋效能需求、測試方法論和監控實踐。
|
|
27
|
+
|
|
28
|
+
**參考標準**:
|
|
29
|
+
- [ISO/IEC 25010:2011](https://www.iso.org/standard/35733.html) - 效能效率
|
|
30
|
+
- [Google SRE Book](https://sre.google/books/) - 網站可靠性工程
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## 效能需求範本
|
|
35
|
+
|
|
36
|
+
### NFR 格式
|
|
37
|
+
|
|
38
|
+
```markdown
|
|
39
|
+
### NFR-PERF-XXX: [標題]
|
|
40
|
+
|
|
41
|
+
**分類**: 效能效率 > [時間行為/資源利用/容量]
|
|
42
|
+
**優先級**: P1/P2/P3
|
|
43
|
+
|
|
44
|
+
**需求**:
|
|
45
|
+
| 百分位 | 目標 | 最大值 |
|
|
46
|
+
|--------|------|--------|
|
|
47
|
+
| p50 | Xms | Yms |
|
|
48
|
+
| p95 | Xms | Yms |
|
|
49
|
+
| p99 | Xms | Yms |
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
## 效能預算
|
|
53
|
+
|
|
54
|
+
| 類別 | 預算 | 測量方式 |
|
|
55
|
+
|------|------|----------|
|
|
56
|
+
| 頁面載入時間 | < 3 秒 | Lighthouse |
|
|
57
|
+
| API 回應時間 (p95) | < 500ms | APM 工具 |
|
|
58
|
+
| 記憶體使用 | < 512MB | 執行時監控 |
|
|
59
|
+
| CPU 使用率 | < 70% 平均 | 系統監控 |
|
|
60
|
+
| 套件大小 | < 200KB (gzip) | 建置分析 |
|
|
61
|
+
|
|
62
|
+
## 效能測試類型
|
|
63
|
+
|
|
64
|
+
| 類型 | 目的 | 工具 |
|
|
65
|
+
|------|------|------|
|
|
66
|
+
| **負載測試** | 驗證正常負載下的效能 | k6、JMeter、Locust |
|
|
67
|
+
| **壓力測試** | 找出系統極限 | k6、Gatling |
|
|
68
|
+
| **浸泡測試** | 偵測記憶體洩漏 | k6(長時間執行) |
|
|
69
|
+
| **尖峰測試** | 驗證突發流量處理 | k6、Artillery |
|
|
70
|
+
|
|
71
|
+
## 監控與告警
|
|
72
|
+
|
|
73
|
+
| 指標類型 | 範例 | 告警閾值 |
|
|
74
|
+
|----------|------|----------|
|
|
75
|
+
| 延遲 (Latency) | p95 回應時間 | > 目標的 2 倍 |
|
|
76
|
+
| 流量 (Traffic) | 每秒請求數 | 異常波動 > 50% |
|
|
77
|
+
| 錯誤率 (Errors) | HTTP 5xx 比例 | > 1% |
|
|
78
|
+
| 飽和度 (Saturation) | CPU/記憶體使用 | > 80% |
|
|
79
|
+
|
|
80
|
+
## 相關標準
|
|
81
|
+
|
|
82
|
+
- [部署標準](deployment-standards.md)
|
|
83
|
+
- [安全標準](security-standards.md)
|
|
84
|
+
- [測試標準](testing-standards.md)
|