universal-dev-standards 5.17.0 → 6.1.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.
Files changed (563) hide show
  1. package/bin/uds.js +13 -135
  2. package/bundled/ai/options/commit-message/bilingual.ai.yaml +19 -1
  3. package/bundled/ai/standards/acceptance-criteria-traceability.ai.yaml +13 -4
  4. package/bundled/ai/standards/accessibility-standards.ai.yaml +1 -1
  5. package/bundled/ai/standards/ai-response-navigation.ai.yaml +15 -2
  6. package/bundled/ai/standards/api-design-standards.ai.yaml +27 -4
  7. package/bundled/ai/standards/behavior-snapshot.ai.yaml +86 -9
  8. package/bundled/ai/standards/checkin-standards.ai.yaml +3 -3
  9. package/bundled/ai/standards/code-review.ai.yaml +2 -2
  10. package/bundled/ai/standards/context-aware-loading.ai.yaml +3 -3
  11. package/bundled/ai/standards/data-migration-testing.ai.yaml +79 -3
  12. package/bundled/ai/standards/deprecation-standards.ai.yaml +10 -2
  13. package/bundled/ai/standards/developer-memory.ai.yaml +4 -3
  14. package/bundled/ai/standards/documentation-writing-standards.ai.yaml +1 -1
  15. package/bundled/ai/standards/flow-based-testing.ai.yaml +2 -2
  16. package/bundled/ai/standards/forward-derivation-standards.ai.yaml +26 -2
  17. package/bundled/ai/standards/frontend-design-standards.ai.yaml +33 -3
  18. package/bundled/ai/standards/full-coverage-testing.ai.yaml +34 -2
  19. package/bundled/ai/standards/git-worktree.ai.yaml +3 -3
  20. package/bundled/ai/standards/logging.ai.yaml +97 -3
  21. package/bundled/ai/standards/mock-boundary.ai.yaml +48 -2
  22. package/bundled/ai/standards/model-provenance.ai.yaml +297 -0
  23. package/bundled/ai/standards/model-selection.ai.yaml +11 -2
  24. package/bundled/ai/standards/observability-standards.ai.yaml +10 -0
  25. package/bundled/ai/standards/performance-standards.ai.yaml +46 -1
  26. package/bundled/ai/standards/pii-classification.ai.yaml +15 -1
  27. package/bundled/ai/standards/pipeline-security-gates.ai.yaml +10 -0
  28. package/bundled/ai/standards/privacy-standards.ai.yaml +2 -2
  29. package/bundled/ai/standards/project-context-memory.ai.yaml +2 -2
  30. package/bundled/ai/standards/push-standards.ai.yaml +14 -3
  31. package/bundled/ai/standards/refactoring-standards.ai.yaml +68 -3
  32. package/bundled/ai/standards/requirement-engineering.ai.yaml +42 -3
  33. package/bundled/ai/standards/resource-cost-boundary.ai.yaml +279 -0
  34. package/bundled/ai/standards/reverse-engineering-standards.ai.yaml +55 -2
  35. package/bundled/ai/standards/security-testing.ai.yaml +13 -2
  36. package/bundled/ai/standards/self-review-protocol.ai.yaml +15 -10
  37. package/bundled/ai/standards/skill-standard-alignment-check.ai.yaml +37 -2
  38. package/bundled/ai/standards/user-journey-testing.ai.yaml +107 -0
  39. package/bundled/ai/standards/verification-evidence.ai.yaml +88 -5
  40. package/bundled/ai/standards/verification-oracle.ai.yaml +278 -0
  41. package/bundled/ai/standards/versioning.ai.yaml +32 -38
  42. package/bundled/core/acceptance-criteria-traceability.md +15 -5
  43. package/bundled/core/accessibility-standards.md +8 -4
  44. package/bundled/core/ai-friendly-architecture.md +1 -1
  45. package/bundled/core/ai-response-navigation.md +31 -3
  46. package/bundled/core/anti-sycophancy-prompting.md +1 -1
  47. package/bundled/core/api-design-standards.md +92 -7
  48. package/bundled/core/audit-trail.md +119 -0
  49. package/bundled/core/behavior-snapshot.md +94 -7
  50. package/bundled/core/browser-compatibility-standards.md +15 -2
  51. package/bundled/core/checkin-standards.md +10 -3
  52. package/bundled/core/code-review-checklist.md +10 -2
  53. package/bundled/core/container-image-standards.md +97 -0
  54. package/bundled/core/context-aware-loading.md +2 -2
  55. package/bundled/core/cost-budget-test.md +1 -1
  56. package/bundled/core/cross-flow-regression.md +3 -2
  57. package/bundled/core/data-contract.md +104 -0
  58. package/bundled/core/data-migration-testing.md +90 -0
  59. package/bundled/core/data-pipeline.md +113 -0
  60. package/bundled/core/deprecation-standards.md +16 -2
  61. package/bundled/core/developer-memory.md +13 -8
  62. package/bundled/core/documentation-writing-standards.md +2 -2
  63. package/bundled/core/error-code-standards.md +4 -3
  64. package/bundled/core/feature-discovery-standards.md +191 -0
  65. package/bundled/core/flaky-test-management.md +1 -1
  66. package/bundled/core/flow-based-testing.md +3 -3
  67. package/bundled/core/forward-derivation-standards.md +33 -5
  68. package/bundled/core/frontend-design-standards.md +93 -4
  69. package/bundled/core/full-coverage-testing.md +72 -0
  70. package/bundled/core/git-worktree.md +4 -4
  71. package/bundled/core/guides/performance-guide.md +1 -1
  72. package/bundled/core/guides/security-guide.md +1 -1
  73. package/bundled/core/health-check-standards.md +2 -2
  74. package/bundled/core/iac-design-principles.md +97 -0
  75. package/bundled/core/incident-response.md +119 -0
  76. package/bundled/core/license-compliance.md +2 -0
  77. package/bundled/core/logging-standards.md +78 -2
  78. package/bundled/core/mock-boundary.md +54 -2
  79. package/bundled/core/model-provenance.md +181 -0
  80. package/bundled/core/model-selection.md +27 -2
  81. package/bundled/core/multi-environment-e2e-testing.md +195 -0
  82. package/bundled/core/packaging-standards.md +1 -0
  83. package/bundled/core/performance-standards.md +96 -2
  84. package/bundled/core/pii-classification.md +148 -0
  85. package/bundled/core/pipeline-security-gates.md +22 -2
  86. package/bundled/core/postmortem-standards.md +2 -0
  87. package/bundled/core/prd-standards.md +91 -0
  88. package/bundled/core/privacy-standards.md +14 -3
  89. package/bundled/core/product-metrics-standards.md +100 -0
  90. package/bundled/core/project-context-memory.md +8 -2
  91. package/bundled/core/prompt-regression.md +1 -1
  92. package/bundled/core/push-standards.md +82 -0
  93. package/bundled/core/refactoring-standards.md +44 -3
  94. package/bundled/core/replay-test.md +1 -1
  95. package/bundled/core/requirement-engineering.md +2 -2
  96. package/bundled/core/resource-cost-boundary.md +180 -0
  97. package/bundled/core/reverse-engineering-standards.md +66 -2
  98. package/bundled/core/runbook.md +113 -0
  99. package/bundled/core/schema-evolution.md +105 -0
  100. package/bundled/core/secret-management-standards.md +110 -0
  101. package/bundled/core/security-testing.md +26 -2
  102. package/bundled/core/self-review-protocol.md +15 -10
  103. package/bundled/core/skill-standard-alignment-check.md +53 -0
  104. package/bundled/core/slo-sli.md +109 -0
  105. package/bundled/core/smoke-test.md +1 -1
  106. package/bundled/core/tech-debt-standards.md +1 -1
  107. package/bundled/core/test-data-standards.md +2 -2
  108. package/bundled/core/user-journey-testing.md +102 -0
  109. package/bundled/core/user-story-mapping.md +96 -0
  110. package/bundled/core/verification-evidence.md +170 -10
  111. package/bundled/core/verification-oracle.md +167 -0
  112. package/bundled/core/versioning.md +133 -109
  113. package/bundled/locales/COVERAGE.md +94 -77
  114. package/bundled/locales/zh-CN/CHANGELOG.md +94 -6
  115. package/bundled/locales/zh-CN/CLAUDE.md +1 -1
  116. package/bundled/locales/zh-CN/MAINTENANCE.md +42 -661
  117. package/bundled/locales/zh-CN/README.md +25 -12
  118. package/bundled/locales/zh-CN/SECURITY.md +2 -2
  119. package/bundled/locales/zh-CN/adoption/DAILY-WORKFLOW-GUIDE.md +2 -2
  120. package/bundled/locales/zh-CN/ai/options/commit-message/bilingual.ai.yaml +6 -1
  121. package/bundled/locales/zh-CN/core/acceptance-criteria-traceability.md +4 -6
  122. package/bundled/locales/zh-CN/core/accessibility-standards.md +1 -1
  123. package/bundled/locales/zh-CN/core/adversarial-test.md +226 -0
  124. package/bundled/locales/zh-CN/core/agent-behavior-discipline.md +187 -0
  125. package/bundled/locales/zh-CN/core/ai-response-navigation.md +32 -6
  126. package/bundled/locales/zh-CN/core/anti-sycophancy-prompting.md +1 -1
  127. package/bundled/locales/zh-CN/core/api-design-standards.md +1 -1
  128. package/bundled/locales/zh-CN/core/behavior-snapshot.md +335 -0
  129. package/bundled/locales/zh-CN/core/browser-compatibility-standards.md +239 -0
  130. package/bundled/locales/zh-CN/core/cd-deployment-strategies.md +135 -0
  131. package/bundled/locales/zh-CN/core/chaos-injection-tests.md +130 -0
  132. package/bundled/locales/zh-CN/core/checkin-standards.md +1 -1
  133. package/bundled/locales/zh-CN/core/code-review-checklist.md +1 -1
  134. package/bundled/locales/zh-CN/core/container-security.md +535 -0
  135. package/bundled/locales/zh-CN/core/context-aware-loading.md +1 -1
  136. package/bundled/locales/zh-CN/core/contract-testing-standards.md +191 -0
  137. package/bundled/locales/zh-CN/core/cost-budget-test.md +86 -0
  138. package/bundled/locales/zh-CN/core/cross-flow-regression.md +200 -0
  139. package/bundled/locales/zh-CN/core/data-migration-testing.md +217 -0
  140. package/bundled/locales/zh-CN/core/deployment-standards.md +328 -9
  141. package/bundled/locales/zh-CN/core/deprecation-standards.md +1 -1
  142. package/bundled/locales/zh-CN/core/developer-memory.md +2 -2
  143. package/bundled/locales/zh-CN/core/disaster-recovery-drill.md +87 -0
  144. package/bundled/locales/zh-CN/core/documentation-structure.md +1 -1
  145. package/bundled/locales/zh-CN/core/documentation-writing-standards.md +1 -1
  146. package/bundled/locales/zh-CN/core/error-code-standards.md +2 -2
  147. package/bundled/locales/zh-CN/core/feature-manifest-standard.md +222 -0
  148. package/bundled/locales/zh-CN/core/flaky-test-management.md +87 -0
  149. package/bundled/locales/zh-CN/core/flow-based-testing.md +284 -0
  150. package/bundled/locales/zh-CN/core/forward-derivation-standards.md +3 -4
  151. package/bundled/locales/zh-CN/core/frontend-design-standards.md +1 -1
  152. package/bundled/locales/zh-CN/core/full-coverage-testing.md +269 -0
  153. package/bundled/locales/zh-CN/core/git-worktree.md +1 -1
  154. package/bundled/locales/zh-CN/core/governance-layer.md +160 -0
  155. package/bundled/locales/zh-CN/core/guides/performance-guide.md +515 -0
  156. package/bundled/locales/zh-CN/core/guides/security-guide.md +494 -0
  157. package/bundled/locales/zh-CN/core/knowledge-graph-memory.md +128 -0
  158. package/bundled/locales/zh-CN/core/license-compliance.md +131 -0
  159. package/bundled/locales/zh-CN/core/llm-output-validation.md +192 -0
  160. package/bundled/locales/zh-CN/core/logging-standards.md +205 -7
  161. package/bundled/locales/zh-CN/core/mock-boundary.md +161 -0
  162. package/bundled/locales/zh-CN/core/model-selection.md +28 -5
  163. package/bundled/locales/zh-CN/core/mutation-testing.md +106 -0
  164. package/bundled/locales/zh-CN/core/no-cicd-deployment.md +219 -0
  165. package/bundled/locales/zh-CN/core/packaging-standards.md +77 -5
  166. package/bundled/locales/zh-CN/core/pipeline-security-gates.md +146 -0
  167. package/bundled/locales/zh-CN/core/policy-as-code-testing.md +203 -0
  168. package/bundled/locales/zh-CN/core/privacy-standards.md +1 -1
  169. package/bundled/locales/zh-CN/core/project-context-memory.md +1 -1
  170. package/bundled/locales/zh-CN/core/prompt-regression.md +88 -0
  171. package/bundled/locales/zh-CN/core/property-based-testing.md +87 -0
  172. package/bundled/locales/zh-CN/core/release-quality-manifest.md +207 -0
  173. package/bundled/locales/zh-CN/core/release-readiness-gate.md +193 -0
  174. package/bundled/locales/zh-CN/core/replay-test.md +102 -0
  175. package/bundled/locales/zh-CN/core/requirement-engineering.md +1 -1
  176. package/bundled/locales/zh-CN/core/reverse-engineering-standards.md +46 -1
  177. package/bundled/locales/zh-CN/core/rollback-standards.md +120 -0
  178. package/bundled/locales/zh-CN/core/sast-advanced.md +309 -0
  179. package/bundled/locales/zh-CN/core/secure-op.md +328 -0
  180. package/bundled/locales/zh-CN/core/security-testing.md +113 -0
  181. package/bundled/locales/zh-CN/core/self-review-protocol.md +172 -0
  182. package/bundled/locales/zh-CN/core/server-ops-security.md +507 -0
  183. package/bundled/locales/zh-CN/core/smoke-test.md +79 -0
  184. package/bundled/locales/zh-CN/core/spec-driven-development.md +39 -3
  185. package/bundled/locales/zh-CN/core/supply-chain-attestation.md +131 -0
  186. package/bundled/locales/zh-CN/core/verification-evidence.md +252 -41
  187. package/bundled/locales/zh-CN/core/versioning.md +1 -1
  188. package/bundled/locales/zh-CN/docs/CHEATSHEET.md +36 -7
  189. package/bundled/locales/zh-CN/docs/FEATURE-REFERENCE.md +71 -53
  190. package/bundled/locales/zh-CN/docs/MIGRATION-v6.md +88 -0
  191. package/bundled/locales/zh-CN/docs/USAGE-MODES-COMPARISON.md +2 -2
  192. package/bundled/locales/zh-CN/docs/USER-MANUAL.md +14 -14
  193. package/bundled/locales/zh-CN/docs/specs/system/memory-adoption-strategy.md +105 -0
  194. package/bundled/locales/zh-CN/docs/user/FAQ.md +132 -0
  195. package/bundled/locales/zh-CN/docs/user/GETTING-STARTED.md +144 -0
  196. package/bundled/locales/zh-CN/docs/user/GLOSSARY.md +178 -0
  197. package/bundled/locales/zh-CN/docs/user/README.md +70 -0
  198. package/bundled/locales/zh-CN/docs/user/TROUBLESHOOTING.md +190 -0
  199. package/bundled/locales/zh-CN/integrations/github-copilot/COPILOT-CHAT-REFERENCE.md +1 -1
  200. package/bundled/locales/zh-CN/integrations/github-copilot/README.md +1 -1
  201. package/bundled/locales/zh-CN/integrations/github-copilot/skills-mapping.md +3 -3
  202. package/bundled/locales/zh-CN/integrations/opencode/skills-mapping.md +3 -3
  203. package/bundled/locales/zh-CN/methodologies/guides/sdd-guide.md +836 -0
  204. package/bundled/locales/zh-CN/options/changelog/auto-generated.md +166 -0
  205. package/bundled/locales/zh-CN/options/changelog/keep-a-changelog.md +140 -0
  206. package/bundled/locales/zh-CN/options/code-review/automated-review.md +214 -0
  207. package/bundled/locales/zh-CN/options/code-review/pair-programming.md +166 -0
  208. package/bundled/locales/zh-CN/options/code-review/pr-review.md +167 -0
  209. package/bundled/locales/zh-CN/options/commit-message/bilingual.md +10 -3
  210. package/bundled/locales/zh-CN/options/documentation/api-docs.md +191 -0
  211. package/bundled/locales/zh-CN/options/documentation/markdown-docs.md +150 -0
  212. package/bundled/locales/zh-CN/options/documentation/wiki-style.md +131 -0
  213. package/bundled/locales/zh-CN/options/project-structure/kotlin.md +144 -0
  214. package/bundled/locales/zh-CN/options/project-structure/php.md +168 -0
  215. package/bundled/locales/zh-CN/options/project-structure/ruby.md +156 -0
  216. package/bundled/locales/zh-CN/options/project-structure/rust.md +136 -0
  217. package/bundled/locales/zh-CN/options/project-structure/swift.md +165 -0
  218. package/bundled/locales/zh-CN/options/testing/contract-testing.md +237 -0
  219. package/bundled/locales/zh-CN/options/testing/industry-pyramid.md +200 -0
  220. package/bundled/locales/zh-CN/options/testing/istqb-framework.md +144 -0
  221. package/bundled/locales/zh-CN/options/testing/performance-testing.md +251 -0
  222. package/bundled/locales/zh-CN/options/testing/security-testing.md +192 -0
  223. package/bundled/locales/zh-CN/skills/README.md +89 -126
  224. package/bundled/locales/zh-CN/skills/ac-coverage/SKILL.md +5 -7
  225. package/bundled/locales/zh-CN/skills/adr-assistant/SKILL.md +1 -1
  226. package/bundled/locales/zh-CN/skills/agents/code-architect.md +263 -0
  227. package/bundled/locales/zh-CN/skills/agents/doc-writer.md +410 -0
  228. package/bundled/locales/zh-CN/skills/agents/reviewer.md +357 -0
  229. package/bundled/locales/zh-CN/skills/agents/spec-analyst.md +410 -0
  230. package/bundled/locales/zh-CN/skills/agents/test-specialist.md +368 -0
  231. package/bundled/locales/zh-CN/skills/ai-collaboration-standards/SKILL.md +2 -2
  232. package/bundled/locales/zh-CN/skills/ai-friendly-architecture/SKILL.md +2 -2
  233. package/bundled/locales/zh-CN/skills/ai-instruction-standards/SKILL.md +1 -1
  234. package/bundled/locales/zh-CN/skills/atdd-assistant/acceptance-criteria-guide.md +1 -1
  235. package/bundled/locales/zh-CN/skills/atdd-assistant/atdd-workflow.md +3 -4
  236. package/bundled/locales/zh-CN/skills/audit-assistant/SKILL.md +2 -2
  237. package/bundled/locales/zh-CN/skills/bdd-assistant/guide.md +1 -2
  238. package/bundled/locales/zh-CN/skills/brainstorm-assistant/SKILL.md +115 -17
  239. package/bundled/locales/zh-CN/skills/brainstorm-assistant/guide.md +37 -12
  240. package/bundled/locales/zh-CN/skills/checkin-assistant/SKILL.md +1 -1
  241. package/bundled/locales/zh-CN/skills/ci-cd-assistant/SKILL.md +50 -0
  242. package/bundled/locales/zh-CN/skills/code-review-assistant/SKILL.md +5 -5
  243. package/bundled/locales/zh-CN/skills/commands/ac-coverage.md +1 -1
  244. package/bundled/locales/zh-CN/skills/commands/atdd.md +3 -3
  245. package/bundled/locales/zh-CN/skills/commands/bdd.md +2 -2
  246. package/bundled/locales/zh-CN/skills/commands/brainstorm.md +26 -17
  247. package/bundled/locales/zh-CN/skills/commands/{review.md → code-review.md} +4 -4
  248. package/bundled/locales/zh-CN/skills/commands/derive-all.md +1 -1
  249. package/bundled/locales/zh-CN/skills/commands/derive-atdd.md +1 -1
  250. package/bundled/locales/zh-CN/skills/commands/derive-bdd.md +2 -3
  251. package/bundled/locales/zh-CN/skills/commands/derive-tdd.md +1 -1
  252. package/bundled/locales/zh-CN/skills/commands/derive.md +1 -1
  253. package/bundled/locales/zh-CN/skills/commands/dev-workflow.md +2 -2
  254. package/bundled/locales/zh-CN/skills/commands/methodology.md +4 -4
  255. package/bundled/locales/zh-CN/skills/commands/pr.md +1 -1
  256. package/bundled/locales/zh-CN/skills/commands/tdd.md +1 -1
  257. package/bundled/locales/zh-CN/skills/commit-standards/SKILL.md +1 -1
  258. package/bundled/locales/zh-CN/skills/contract-test-assistant/SKILL.md +1 -1
  259. package/bundled/locales/zh-CN/skills/dev-methodology/SKILL.md +1 -1
  260. package/bundled/locales/zh-CN/skills/dev-methodology/create-methodology.md +456 -0
  261. package/bundled/locales/zh-CN/skills/dev-methodology/guide.md +6 -6
  262. package/bundled/locales/zh-CN/skills/dev-methodology/runtime.md +296 -0
  263. package/bundled/locales/zh-CN/skills/dev-workflow-guide/SKILL.md +5 -5
  264. package/bundled/locales/zh-CN/skills/docs-generator/SKILL.md +1 -1
  265. package/bundled/locales/zh-CN/skills/e2e-assistant/SKILL.md +1 -1
  266. package/bundled/locales/zh-CN/skills/incident-response-assistant/SKILL.md +2 -2
  267. package/bundled/locales/zh-CN/skills/journey-test-assistant/SKILL.md +1 -1
  268. package/bundled/locales/zh-CN/skills/logging-guide/SKILL.md +169 -142
  269. package/bundled/locales/zh-CN/skills/migration-assistant/SKILL.md +1 -1
  270. package/bundled/locales/zh-CN/skills/observability-assistant/guide.md +1 -1
  271. package/bundled/locales/zh-CN/skills/pr-automation-assistant/SKILL.md +1 -1
  272. package/bundled/locales/zh-CN/skills/project-discovery/guide.md +2 -2
  273. package/bundled/locales/zh-CN/skills/reverse-engineer/SKILL.md +1 -1
  274. package/bundled/locales/zh-CN/skills/runbook-assistant/guide.md +1 -1
  275. package/bundled/locales/zh-CN/skills/security-assistant/SKILL.md +1 -1
  276. package/bundled/locales/zh-CN/skills/skill-builder/SKILL.md +3 -3
  277. package/bundled/locales/zh-CN/skills/slo-assistant/guide.md +1 -1
  278. package/bundled/locales/zh-CN/skills/spec-derivation/SKILL.md +1 -1
  279. package/bundled/locales/zh-CN/skills/spec-derivation/guide.md +8 -9
  280. package/bundled/locales/zh-CN/skills/spec-driven-dev/SKILL.md +2 -2
  281. package/bundled/locales/zh-CN/skills/sweep/SKILL.md +1 -1
  282. package/bundled/locales/zh-CN/skills/tdd-assistant/SKILL.md +1 -1
  283. package/bundled/locales/zh-CN/skills/testing-guide/SKILL.md +2 -2
  284. package/bundled/locales/zh-CN/skills/testing-guide/testing-theory.md +2298 -0
  285. package/bundled/locales/zh-CN/skills/workflows/README.md +451 -0
  286. package/bundled/locales/zh-TW/CHANGELOG.md +94 -6
  287. package/bundled/locales/zh-TW/CLAUDE.md +1 -1
  288. package/bundled/locales/zh-TW/MAINTENANCE.md +51 -4
  289. package/bundled/locales/zh-TW/README.md +25 -12
  290. package/bundled/locales/zh-TW/SECURITY.md +2 -2
  291. package/bundled/locales/zh-TW/adoption/DAILY-WORKFLOW-GUIDE.md +2 -2
  292. package/bundled/locales/zh-TW/ai/options/commit-message/bilingual.ai.yaml +6 -1
  293. package/bundled/locales/zh-TW/ai/standards/versioning.ai.yaml +8 -48
  294. package/bundled/locales/zh-TW/core/acceptance-criteria-traceability.md +4 -6
  295. package/bundled/locales/zh-TW/core/accessibility-standards.md +1 -1
  296. package/bundled/locales/zh-TW/core/adversarial-test.md +226 -0
  297. package/bundled/locales/zh-TW/core/agent-behavior-discipline.md +187 -0
  298. package/bundled/locales/zh-TW/core/ai-response-navigation.md +32 -6
  299. package/bundled/locales/zh-TW/core/anti-sycophancy-prompting.md +1 -1
  300. package/bundled/locales/zh-TW/core/api-design-standards.md +91 -9
  301. package/bundled/locales/zh-TW/core/audit-trail.md +110 -0
  302. package/bundled/locales/zh-TW/core/behavior-snapshot.md +335 -0
  303. package/bundled/locales/zh-TW/core/browser-compatibility-standards.md +1 -0
  304. package/bundled/locales/zh-TW/core/cd-deployment-strategies.md +135 -0
  305. package/bundled/locales/zh-TW/core/chaos-injection-tests.md +130 -0
  306. package/bundled/locales/zh-TW/core/checkin-standards.md +1 -1
  307. package/bundled/locales/zh-TW/core/code-review-checklist.md +1 -1
  308. package/bundled/locales/zh-TW/core/container-image-standards.md +93 -0
  309. package/bundled/locales/zh-TW/core/container-security.md +535 -0
  310. package/bundled/locales/zh-TW/core/cost-budget-test.md +86 -0
  311. package/bundled/locales/zh-TW/core/cross-flow-regression.md +1 -0
  312. package/bundled/locales/zh-TW/core/data-contract.md +101 -0
  313. package/bundled/locales/zh-TW/core/data-migration-testing.md +217 -0
  314. package/bundled/locales/zh-TW/core/data-pipeline.md +105 -0
  315. package/bundled/locales/zh-TW/core/deployment-standards.md +363 -25
  316. package/bundled/locales/zh-TW/core/deprecation-standards.md +17 -4
  317. package/bundled/locales/zh-TW/core/developer-memory.md +2 -2
  318. package/bundled/locales/zh-TW/core/disaster-recovery-drill.md +87 -0
  319. package/bundled/locales/zh-TW/core/documentation-writing-standards.md +1 -1
  320. package/bundled/locales/zh-TW/core/error-code-standards.md +2 -2
  321. package/bundled/locales/zh-TW/core/feature-manifest-standard.md +222 -0
  322. package/bundled/locales/zh-TW/core/flaky-test-management.md +87 -0
  323. package/bundled/locales/zh-TW/core/flow-based-testing.md +284 -0
  324. package/bundled/locales/zh-TW/core/forward-derivation-standards.md +3 -4
  325. package/bundled/locales/zh-TW/core/frontend-design-standards.md +1 -1
  326. package/bundled/locales/zh-TW/core/full-coverage-testing.md +250 -0
  327. package/bundled/locales/zh-TW/core/git-worktree.md +1 -1
  328. package/bundled/locales/zh-TW/core/guides/performance-guide.md +515 -0
  329. package/bundled/locales/zh-TW/core/guides/security-guide.md +494 -0
  330. package/bundled/locales/zh-TW/core/iac-design-principles.md +90 -0
  331. package/bundled/locales/zh-TW/core/incident-response.md +111 -0
  332. package/bundled/locales/zh-TW/core/license-compliance.md +131 -0
  333. package/bundled/locales/zh-TW/core/llm-output-validation.md +192 -0
  334. package/bundled/locales/zh-TW/core/logging-standards.md +208 -4
  335. package/bundled/locales/zh-TW/core/mock-boundary.md +161 -0
  336. package/bundled/locales/zh-TW/core/model-provenance.md +173 -0
  337. package/bundled/locales/zh-TW/core/model-selection.md +28 -5
  338. package/bundled/locales/zh-TW/core/mutation-testing.md +106 -0
  339. package/bundled/locales/zh-TW/core/no-cicd-deployment.md +219 -0
  340. package/bundled/locales/zh-TW/core/packaging-standards.md +77 -5
  341. package/bundled/locales/zh-TW/core/performance-standards.md +84 -5
  342. package/bundled/locales/zh-TW/core/pii-classification.md +102 -0
  343. package/bundled/locales/zh-TW/core/pipeline-security-gates.md +146 -0
  344. package/bundled/locales/zh-TW/core/policy-as-code-testing.md +203 -0
  345. package/bundled/locales/zh-TW/core/prd-standards.md +88 -0
  346. package/bundled/locales/zh-TW/core/privacy-standards.md +1 -1
  347. package/bundled/locales/zh-TW/core/product-metrics-standards.md +96 -0
  348. package/bundled/locales/zh-TW/core/project-context-memory.md +1 -1
  349. package/bundled/locales/zh-TW/core/prompt-regression.md +88 -0
  350. package/bundled/locales/zh-TW/core/property-based-testing.md +87 -0
  351. package/bundled/locales/zh-TW/core/refactoring-standards.md +43 -6
  352. package/bundled/locales/zh-TW/core/release-quality-manifest.md +207 -0
  353. package/bundled/locales/zh-TW/core/replay-test.md +102 -0
  354. package/bundled/locales/zh-TW/core/requirement-engineering.md +1 -1
  355. package/bundled/locales/zh-TW/core/resource-cost-boundary.md +175 -0
  356. package/bundled/locales/zh-TW/core/reverse-engineering-standards.md +64 -5
  357. package/bundled/locales/zh-TW/core/rollback-standards.md +120 -0
  358. package/bundled/locales/zh-TW/core/runbook.md +110 -0
  359. package/bundled/locales/zh-TW/core/sast-advanced.md +309 -0
  360. package/bundled/locales/zh-TW/core/schema-evolution.md +98 -0
  361. package/bundled/locales/zh-TW/core/secret-management-standards.md +101 -0
  362. package/bundled/locales/zh-TW/core/secure-op.md +328 -0
  363. package/bundled/locales/zh-TW/core/security-testing.md +113 -0
  364. package/bundled/locales/zh-TW/core/self-review-protocol.md +18 -13
  365. package/bundled/locales/zh-TW/core/server-ops-security.md +507 -0
  366. package/bundled/locales/zh-TW/core/slo-sli.md +108 -0
  367. package/bundled/locales/zh-TW/core/smoke-test.md +79 -0
  368. package/bundled/locales/zh-TW/core/spec-driven-development.md +19 -11
  369. package/bundled/locales/zh-TW/core/supply-chain-attestation.md +131 -0
  370. package/bundled/locales/zh-TW/core/user-journey-testing.md +111 -0
  371. package/bundled/locales/zh-TW/core/user-story-mapping.md +94 -0
  372. package/bundled/locales/zh-TW/core/verification-evidence.md +260 -31
  373. package/bundled/locales/zh-TW/core/verification-oracle.md +159 -0
  374. package/bundled/locales/zh-TW/core/versioning.md +112 -112
  375. package/bundled/locales/zh-TW/docs/CHEATSHEET.md +36 -7
  376. package/bundled/locales/zh-TW/docs/DEV-WORKFLOW-MAPPING.md +6 -6
  377. package/bundled/locales/zh-TW/docs/FEATURE-REFERENCE.md +71 -53
  378. package/bundled/locales/zh-TW/docs/MIGRATION-v6.md +88 -0
  379. package/bundled/locales/zh-TW/docs/USAGE-MODES-COMPARISON.md +2 -2
  380. package/bundled/locales/zh-TW/docs/USER-MANUAL.md +14 -14
  381. package/bundled/locales/zh-TW/docs/specs/system/memory-adoption-strategy.md +105 -0
  382. package/bundled/locales/zh-TW/docs/user/FAQ.md +132 -0
  383. package/bundled/locales/zh-TW/docs/user/GETTING-STARTED.md +144 -0
  384. package/bundled/locales/zh-TW/docs/user/GLOSSARY.md +178 -0
  385. package/bundled/locales/zh-TW/docs/user/README.md +70 -0
  386. package/bundled/locales/zh-TW/docs/user/TROUBLESHOOTING.md +190 -0
  387. package/bundled/locales/zh-TW/integrations/github-copilot/COPILOT-CHAT-REFERENCE.md +1 -1
  388. package/bundled/locales/zh-TW/integrations/github-copilot/README.md +1 -1
  389. package/bundled/locales/zh-TW/integrations/github-copilot/skills-mapping.md +3 -3
  390. package/bundled/locales/zh-TW/integrations/opencode/skills-mapping.md +3 -3
  391. package/bundled/locales/zh-TW/methodologies/guides/sdd-guide.md +523 -26
  392. package/bundled/locales/zh-TW/options/changelog/auto-generated.md +166 -0
  393. package/bundled/locales/zh-TW/options/changelog/keep-a-changelog.md +140 -0
  394. package/bundled/locales/zh-TW/options/code-review/automated-review.md +214 -0
  395. package/bundled/locales/zh-TW/options/code-review/pair-programming.md +166 -0
  396. package/bundled/locales/zh-TW/options/code-review/pr-review.md +167 -0
  397. package/bundled/locales/zh-TW/options/commit-message/bilingual.md +10 -3
  398. package/bundled/locales/zh-TW/options/documentation/api-docs.md +191 -0
  399. package/bundled/locales/zh-TW/options/documentation/markdown-docs.md +150 -0
  400. package/bundled/locales/zh-TW/options/documentation/wiki-style.md +131 -0
  401. package/bundled/locales/zh-TW/options/project-structure/kotlin.md +144 -0
  402. package/bundled/locales/zh-TW/options/project-structure/php.md +168 -0
  403. package/bundled/locales/zh-TW/options/project-structure/ruby.md +156 -0
  404. package/bundled/locales/zh-TW/options/project-structure/rust.md +136 -0
  405. package/bundled/locales/zh-TW/options/project-structure/swift.md +165 -0
  406. package/bundled/locales/zh-TW/options/testing/contract-testing.md +237 -0
  407. package/bundled/locales/zh-TW/options/testing/industry-pyramid.md +200 -0
  408. package/bundled/locales/zh-TW/options/testing/istqb-framework.md +144 -0
  409. package/bundled/locales/zh-TW/options/testing/performance-testing.md +251 -0
  410. package/bundled/locales/zh-TW/options/testing/security-testing.md +192 -0
  411. package/bundled/locales/zh-TW/skills/README.md +91 -128
  412. package/bundled/locales/zh-TW/skills/ac-coverage/SKILL.md +4 -6
  413. package/bundled/locales/zh-TW/skills/adr-assistant/SKILL.md +1 -1
  414. package/bundled/locales/zh-TW/skills/agents/code-architect.md +263 -0
  415. package/bundled/locales/zh-TW/skills/agents/doc-writer.md +410 -0
  416. package/bundled/locales/zh-TW/skills/agents/reviewer.md +357 -0
  417. package/bundled/locales/zh-TW/skills/agents/spec-analyst.md +410 -0
  418. package/bundled/locales/zh-TW/skills/agents/test-specialist.md +368 -0
  419. package/bundled/locales/zh-TW/skills/ai-collaboration-standards/SKILL.md +2 -2
  420. package/bundled/locales/zh-TW/skills/ai-friendly-architecture/SKILL.md +2 -2
  421. package/bundled/locales/zh-TW/skills/ai-instruction-standards/SKILL.md +1 -1
  422. package/bundled/locales/zh-TW/skills/atdd-assistant/SKILL.md +2 -0
  423. package/bundled/locales/zh-TW/skills/atdd-assistant/acceptance-criteria-guide.md +1 -1
  424. package/bundled/locales/zh-TW/skills/atdd-assistant/atdd-workflow.md +3 -4
  425. package/bundled/locales/zh-TW/skills/audit-assistant/SKILL.md +2 -2
  426. package/bundled/locales/zh-TW/skills/bdd-assistant/SKILL.md +2 -0
  427. package/bundled/locales/zh-TW/skills/bdd-assistant/guide.md +1 -2
  428. package/bundled/locales/zh-TW/skills/brainstorm-assistant/SKILL.md +116 -18
  429. package/bundled/locales/zh-TW/skills/brainstorm-assistant/guide.md +38 -11
  430. package/bundled/locales/zh-TW/skills/checkin-assistant/SKILL.md +3 -1
  431. package/bundled/locales/zh-TW/skills/ci-cd-assistant/SKILL.md +50 -0
  432. package/bundled/locales/zh-TW/skills/code-review-assistant/SKILL.md +7 -5
  433. package/bundled/locales/zh-TW/skills/commands/ac-coverage.md +1 -1
  434. package/bundled/locales/zh-TW/skills/commands/atdd.md +3 -3
  435. package/bundled/locales/zh-TW/skills/commands/bdd.md +2 -2
  436. package/bundled/locales/zh-TW/skills/commands/brainstorm.md +26 -17
  437. package/bundled/locales/zh-TW/skills/commands/{review.md → code-review.md} +5 -5
  438. package/bundled/locales/zh-TW/skills/commands/derive-all.md +1 -1
  439. package/bundled/locales/zh-TW/skills/commands/derive-atdd.md +1 -1
  440. package/bundled/locales/zh-TW/skills/commands/derive-bdd.md +2 -3
  441. package/bundled/locales/zh-TW/skills/commands/derive-tdd.md +1 -1
  442. package/bundled/locales/zh-TW/skills/commands/derive.md +1 -1
  443. package/bundled/locales/zh-TW/skills/commands/dev-workflow.md +2 -2
  444. package/bundled/locales/zh-TW/skills/commands/methodology.md +4 -4
  445. package/bundled/locales/zh-TW/skills/commands/pr.md +1 -1
  446. package/bundled/locales/zh-TW/skills/commands/tdd.md +1 -1
  447. package/bundled/locales/zh-TW/skills/commit-standards/SKILL.md +1 -1
  448. package/bundled/locales/zh-TW/skills/contract-test-assistant/SKILL.md +1 -1
  449. package/bundled/locales/zh-TW/skills/dev-methodology/create-methodology.md +456 -0
  450. package/bundled/locales/zh-TW/skills/dev-methodology/guide.md +5 -5
  451. package/bundled/locales/zh-TW/skills/dev-methodology/runtime.md +296 -0
  452. package/bundled/locales/zh-TW/skills/dev-workflow-guide/SKILL.md +5 -5
  453. package/bundled/locales/zh-TW/skills/docs-generator/SKILL.md +1 -1
  454. package/bundled/locales/zh-TW/skills/e2e-assistant/SKILL.md +1 -1
  455. package/bundled/locales/zh-TW/skills/incident-response-assistant/SKILL.md +2 -2
  456. package/bundled/locales/zh-TW/skills/logging-guide/SKILL.md +52 -27
  457. package/bundled/locales/zh-TW/skills/migration-assistant/SKILL.md +1 -1
  458. package/bundled/locales/zh-TW/skills/pr-automation-assistant/SKILL.md +3 -1
  459. package/bundled/locales/zh-TW/skills/project-discovery/guide.md +2 -2
  460. package/bundled/locales/zh-TW/skills/reverse-engineer/SKILL.md +1 -1
  461. package/bundled/locales/zh-TW/skills/security-assistant/SKILL.md +1 -1
  462. package/bundled/locales/zh-TW/skills/spec-derivation/guide.md +7 -8
  463. package/bundled/locales/zh-TW/skills/spec-driven-dev/SKILL.md +2 -2
  464. package/bundled/locales/zh-TW/skills/sweep/SKILL.md +1 -1
  465. package/bundled/locales/zh-TW/skills/tdd-assistant/SKILL.md +3 -1
  466. package/bundled/locales/zh-TW/skills/testing-guide/SKILL.md +2 -2
  467. package/bundled/locales/zh-TW/skills/testing-guide/testing-theory.md +2298 -0
  468. package/bundled/locales/zh-TW/skills/workflows/README.md +451 -0
  469. package/bundled/skills/README.md +1 -1
  470. package/bundled/skills/ac-coverage/SKILL.md +17 -7
  471. package/bundled/skills/adr-assistant/SKILL.md +1 -1
  472. package/bundled/skills/agents/code-architect.md +1 -1
  473. package/bundled/skills/agents/doc-writer.md +1 -1
  474. package/bundled/skills/agents/reviewer.md +2 -2
  475. package/bundled/skills/agents/spec-analyst.md +1 -1
  476. package/bundled/skills/agents/test-specialist.md +1 -1
  477. package/bundled/skills/ai-collaboration-standards/SKILL.md +2 -2
  478. package/bundled/skills/ai-friendly-architecture/SKILL.md +2 -2
  479. package/bundled/skills/ai-instruction-standards/SKILL.md +1 -1
  480. package/bundled/skills/atdd-assistant/SKILL.md +7 -0
  481. package/bundled/skills/atdd-assistant/acceptance-criteria-guide.md +1 -1
  482. package/bundled/skills/atdd-assistant/atdd-workflow.md +6 -8
  483. package/bundled/skills/audit-assistant/SKILL.md +2 -2
  484. package/bundled/skills/bdd-assistant/SKILL.md +7 -0
  485. package/bundled/skills/bdd-assistant/guide.md +1 -2
  486. package/bundled/skills/brainstorm-assistant/SKILL.md +139 -15
  487. package/bundled/skills/brainstorm-assistant/guide.md +39 -8
  488. package/bundled/skills/checkin-assistant/SKILL.md +8 -1
  489. package/bundled/skills/ci-cd-assistant/SKILL.md +57 -0
  490. package/bundled/skills/code-review-assistant/SKILL.md +15 -8
  491. package/bundled/skills/commands/COMMAND-FAMILY-OVERVIEW.md +2 -2
  492. package/bundled/skills/commands/COMMAND-INDEX.json +3 -3
  493. package/bundled/skills/commands/README.md +2 -2
  494. package/bundled/skills/commands/ac-coverage.md +1 -1
  495. package/bundled/skills/commands/atdd.md +2 -2
  496. package/bundled/skills/commands/bdd.md +2 -2
  497. package/bundled/skills/commands/brainstorm.md +25 -14
  498. package/bundled/skills/commands/{review.md → code-review.md} +6 -6
  499. package/bundled/skills/commands/derive-all.md +1 -1
  500. package/bundled/skills/commands/derive-atdd.md +1 -1
  501. package/bundled/skills/commands/derive-bdd.md +2 -3
  502. package/bundled/skills/commands/derive-tdd.md +1 -1
  503. package/bundled/skills/commands/derive.md +1 -1
  504. package/bundled/skills/commands/dev-workflow.md +1 -1
  505. package/bundled/skills/commands/journey-test.md +45 -0
  506. package/bundled/skills/commands/methodology.md +4 -4
  507. package/bundled/skills/commands/pr.md +1 -1
  508. package/bundled/skills/commands/skill-builder.md +42 -0
  509. package/bundled/skills/commands/tdd.md +1 -1
  510. package/bundled/skills/dev-methodology/create-methodology.md +1 -1
  511. package/bundled/skills/dev-methodology/guide.md +1 -1
  512. package/bundled/skills/dev-methodology/runtime.md +1 -1
  513. package/bundled/skills/dev-workflow-guide/SKILL.md +3 -3
  514. package/bundled/skills/dev-workflow-guide/workflow-phases.md +3 -3
  515. package/bundled/skills/docs-generator/SKILL.md +3 -3
  516. package/bundled/skills/incident-response-assistant/SKILL.md +2 -2
  517. package/bundled/skills/logging-guide/SKILL.md +38 -2
  518. package/bundled/skills/migration-assistant/SKILL.md +226 -0
  519. package/bundled/skills/observability-assistant/SKILL.md +74 -0
  520. package/bundled/skills/pr-automation-assistant/SKILL.md +5 -1
  521. package/bundled/skills/project-discovery/guide.md +2 -2
  522. package/bundled/skills/push/SKILL.md +1 -1
  523. package/bundled/skills/release-standards/SKILL.md +19 -5
  524. package/bundled/skills/security-assistant/SKILL.md +1 -1
  525. package/bundled/skills/skill-builder/SKILL.md +1 -1
  526. package/bundled/skills/spec-derivation/guide.md +3 -4
  527. package/bundled/skills/spec-driven-dev/SKILL.md +13 -2
  528. package/bundled/skills/sweep/SKILL.md +1 -1
  529. package/bundled/skills/tdd-assistant/SKILL.md +8 -1
  530. package/bundled/skills/testing-guide/SKILL.md +1 -1
  531. package/bundled/skills/testing-guide/testing-theory.md +1 -1
  532. package/bundled/skills/workflows/README.md +2 -2
  533. package/package.json +4 -4
  534. package/src/commands/audit.js +30 -9
  535. package/src/commands/config.js +33 -2
  536. package/src/commands/hitl.js +14 -1
  537. package/src/commands/init.js +168 -75
  538. package/src/commands/quickstart.js +1 -2
  539. package/src/commands/release.js +51 -6
  540. package/src/commands/run-intent.js +9 -0
  541. package/src/commands/spec-split.js +27 -2
  542. package/src/commands/update.js +22 -6
  543. package/src/config/ai-agent-paths.js +3 -1
  544. package/src/i18n/messages.js +3 -102
  545. package/src/missions/MissionManager.js +44 -12
  546. package/src/utils/build-manifest.js +35 -3
  547. package/src/utils/friction-detector.js +71 -22
  548. package/src/utils/health-checker.js +29 -2
  549. package/src/utils/transaction.js +111 -0
  550. package/src/utils/version-promote.js +16 -0
  551. package/standards-registry.json +61 -149
  552. package/bundled/ai/standards/agent-communication-protocol.ai.yaml +0 -42
  553. package/bundled/ai/standards/agent-dispatch.ai.yaml +0 -42
  554. package/bundled/ai/standards/branch-completion.ai.yaml +0 -44
  555. package/bundled/ai/standards/change-batching-standards.ai.yaml +0 -44
  556. package/bundled/ai/standards/execution-history.ai.yaml +0 -42
  557. package/bundled/ai/standards/pipeline-integration-standards.ai.yaml +0 -42
  558. package/bundled/ai/standards/workflow-enforcement.ai.yaml +0 -44
  559. package/bundled/ai/standards/workflow-state-protocol.ai.yaml +0 -43
  560. package/src/commands/flow.js +0 -260
  561. package/src/commands/start.js +0 -372
  562. package/src/commands/sweep.js +0 -151
  563. package/src/commands/workflow.js +0 -681
@@ -1,8 +1,9 @@
1
1
  ---
2
- source: ../../core/spec-driven-development.md
2
+ source: ../../../../methodologies/guides/sdd-guide.md
3
3
  source_version: 2.1.0
4
4
  translation_version: 2.1.0
5
- last_synced: 2026-01-26
5
+ last_synced: 2026-06-10
6
+ source_hash: 972eba45ce66
6
7
  status: current
7
8
  ---
8
9
 
@@ -13,7 +14,7 @@ status: current
13
14
  **適用範圍**: 所有採用規格驅動開發的專案
14
15
  **範圍**: universal
15
16
 
16
- > **語言**: [English](../../../../core/spec-driven-development.md) | [繁體中文](../../core/spec-driven-development.md)
17
+ > **語言**: [English](../../../../methodologies/guides/sdd-guide.md) | [繁體中文](../../methodologies/guides/sdd-guide.md)
17
18
 
18
19
  ---
19
20
 
@@ -28,6 +29,223 @@ status: current
28
29
 
29
30
  ---
30
31
 
32
+ ## SDD 作為獨立方法論
33
+
34
+ SDD(規格驅動開發,2025)是 AI 時代的方法論,有別於傳統的 TDD/BDD/ATDD 家族。它源於 AI 輔助開發工具的廣泛採用,以及現代軟體工程對「規格優先」方法的需求。
35
+
36
+ ### 歷史背景
37
+
38
+ | 方法論家族 | 時代 | 核心文獻 | 關係 |
39
+ |-----------|------|----------|------|
40
+ | **TDD/BDD/ATDD** | 1999-2011 | GOOS(Freeman & Pryce)、Dan North、Gojko Adzic | 傳統測試驅動開發家族 |
41
+ | **SDD (2025)** | 2025+ | Thoughtworks、GitHub spec-kit、Martin Fowler | AI 時代新興概念,與傳統家族獨立 |
42
+
43
+ ### 與測試方法論的關係
44
+
45
+ SDD **不屬於** "ATDD → BDD → TDD" 序列。它透過正向推演生成測試產出物,但仍是獨立方法論。
46
+
47
+ | 方法論 | 起源 | 焦點 | SDD 整合方式 |
48
+ |--------|------|------|-------------|
49
+ | **TDD** | 1999,Kent Beck | 程式碼層級測試 | 可用於 SDD 實作階段 |
50
+ | **BDD** | 2006,Dan North | 行為情境 | 正向推演生成 .feature 檔案 |
51
+ | **ATDD** | 2003-2006,GOOS | 協作驗收 | 可選的 AC 定義輸入方式 |
52
+
53
+ ### 關鍵區別
54
+
55
+ ```
56
+ ┌─────────────────────────────────────────────────────────────────────────────┐
57
+ │ 兩套獨立方法論系統 │
58
+ ├─────────────────────────────────────────────────────────────────────────────┤
59
+ │ │
60
+ │ ┌─────────────────────────────────────┐ │
61
+ │ │ SDD(AI 時代方法論) │ │
62
+ │ │ │ │
63
+ │ │ 需求 → SPEC.md → 正向推演 → 測試 │ │
64
+ │ │ │ │
65
+ │ │ • 規格是權威來源 │ │
66
+ │ │ • AI 輔助程式碼生成 │ │
67
+ │ │ • 正向推演生成測試結構 │ │
68
+ │ └─────────────────────────────────────┘ │
69
+ │ │
70
+ │ ┌─────────────────────────────────────┐ │
71
+ │ │ 雙迴圈 TDD(傳統) │ │
72
+ │ │ │ │
73
+ │ │ BDD(外迴圈)→ TDD(內迴圈) │ │
74
+ │ │ │ │
75
+ │ │ • 測試驅動設計 │ │
76
+ │ │ • 手動開發 │ │
77
+ │ │ • ATDD 是可選的協作輸入, │ │
78
+ │ │ 而非循序步驟 │ │
79
+ │ └─────────────────────────────────────┘ │
80
+ │ │
81
+ └─────────────────────────────────────────────────────────────────────────────┘
82
+ ```
83
+
84
+ ---
85
+
86
+ ## SDD 成熟度等級
87
+
88
+ 根據 Martin Fowler 對 SDD 工具的分析(2025),團隊可在不同成熟度等級運作:
89
+
90
+ | 等級 | 名稱 | 說明 | 人類角色 |
91
+ |------|------|------|---------|
92
+ | 1 | **規格優先** | 先寫規格,完成後丟棄 | 編輯規格與程式碼 |
93
+ | 2 | **規格錨定** | 在整個演進過程維護規格 | 編輯規格,AI 輔助程式碼 |
94
+ | 3 | **規格即來源** | 規格是唯一來源,程式碼自動生成 | 只編輯規格,絕不碰程式碼 |
95
+
96
+ ### 等級特性
97
+
98
+ **等級 1:規格優先**
99
+ - 在實作前撰寫規格
100
+ - 功能完成後可丟棄規格
101
+ - 程式碼仍是權威來源
102
+ - 2025 年最常見
103
+
104
+ **等級 2:規格錨定**
105
+ - 在整個生命週期維護規格
106
+ - 規格用於演進與維護
107
+ - AI 根據規格更新協助程式碼變更
108
+ - 在企業環境中逐步採用
109
+
110
+ **等級 3:規格即來源**
111
+ - 規格是唯一的真實來源
112
+ - 程式碼標注 "GENERATED - DO NOT EDIT"
113
+ - 任何變更都需先修改規格
114
+ - 2025 年仍在實驗階段
115
+
116
+ ### 參考資料
117
+
118
+ - [Thoughtworks: Spec-Driven Development](https://www.thoughtworks.com/en-us/insights/blog/agile-engineering-practices/spec-driven-development-unpacking-2025-new-engineering-practices)
119
+ - [Martin Fowler: SDD Tools (Kiro, spec-kit, Tessl)](https://martinfowler.com/articles/exploring-gen-ai/sdd-3-tools.html)
120
+ - [GitHub spec-kit](https://github.com/github/spec-kit/blob/main/spec-driven.md)
121
+
122
+ ---
123
+
124
+ ## 常見陷阱
125
+
126
+ 採用 SDD 時應避免以下常見陷阱:
127
+
128
+ | 陷阱 | 問題 | 緩解措施 |
129
+ |------|------|---------|
130
+ | **過度形式化** | 像瀑布開發一樣拖慢回饋速度 | 保持迭代,使用短週期 |
131
+ | **規格漂移** | 規格與程式碼不同步 | 持續驗證,在 CI/CD 中做漂移偵測 |
132
+ | **AI 幻覺** | AI 生成的程式碼與規格不符 | 強健的驗證、契約測試 |
133
+ | **尺寸不符** | 對小 bug 使用重量級流程 | 根據複雜度選擇合適流程 |
134
+ | **過早優化** | 跳躍至規格即來源(等級 3) | 從規格優先開始,逐步演進 |
135
+
136
+ ### 何時不使用完整 SDD
137
+
138
+ | 情境 | 建議 |
139
+ |------|------|
140
+ | 關鍵熱修復 | 先修復,後補文件 |
141
+ | 錯字與格式 | 直接 commit,不需規格 |
142
+ | 探索性原型 | 跳過正式規格,快速迭代 |
143
+ | 瑣碎 bug 修復(錯字層級、無共用程式碼) | 僅輕量追蹤 |
144
+ | 易回歸 bug 修復(共用程式碼 / 遷移 / 曾破壞路徑) | 使用下方的 Bugfix 規格模板 |
145
+
146
+ ---
147
+
148
+ ## 變更評估(SDD 前置評估)
149
+
150
+ 開始 SDD 工作流程前,先評估變更的性質與範圍。這能防止過度工程化,確保變更被正確路由。
151
+
152
+ ### 評估決策樹
153
+
154
+ ```
155
+ 新需求/變更
156
+
157
+
158
+ ┌─────────────────────────────────────────────────────────┐
159
+ │ Q1: 這個變更的適用範圍是什麼? │
160
+ │ What is the scope of this change? │
161
+ ├─────────────────────────────────────────────────────────┤
162
+ │ A) 僅限專案內部使用 │
163
+ │ → 加入 CLAUDE.md 或專案設定 │
164
+ │ → 不需要核心標準 │
165
+ │ │
166
+ │ B) 可被其他專案複用的規則 │
167
+ │ → 建立核心標準 │
168
+ │ → 評估是否需要 Skill/Command │
169
+ └─────────────────────────────────────────────────────────┘
170
+
171
+
172
+ ┌─────────────────────────────────────────────────────────┐
173
+ │ Q2: 這個功能需要 AI 互動嗎? │
174
+ │ Does this feature require AI interaction? │
175
+ ├─────────────────────────────────────────────────────────┤
176
+ │ A) 需要互動式工作流程 │
177
+ │ → 建立 Skill │
178
+ │ → 評估是否需要 Slash Command │
179
+ │ │
180
+ │ B) 靜態規則 / 背景知識 │
181
+ │ → 僅建核心標準 │
182
+ │ → 在 CLAUDE.md 中引用 │
183
+ └─────────────────────────────────────────────────────────┘
184
+
185
+
186
+ ┌─────────────────────────────────────────────────────────┐
187
+ │ Q3: 使用者需要直接觸發嗎? │
188
+ │ Does the user need to trigger this directly? │
189
+ ├─────────────────────────────────────────────────────────┤
190
+ │ A) 需要 /command 觸發 │
191
+ │ → 建立 Slash Command │
192
+ │ │
193
+ │ B) AI 自動套用 │
194
+ │ → 僅建 Skill,不需要 Command │
195
+ └─────────────────────────────────────────────────────────┘
196
+ ```
197
+
198
+ ### 評估結果
199
+
200
+ | 評估結果 | 需建立的產出物 |
201
+ |---------|-------------|
202
+ | 僅限專案 | 僅更新 CLAUDE.md |
203
+ | 通用靜態規則 | 核心標準 + CLAUDE.md 引用 |
204
+ | 通用互動式 | 核心標準 + Skill |
205
+ | 使用者觸發工作流程 | 核心標準 + Skill + Command |
206
+
207
+ ### 範圍分類標籤
208
+
209
+ 在規格文件中使用以下標籤標示範圍:
210
+
211
+ | 標籤 | 含義 | 範例 |
212
+ |------|------|------|
213
+ | `[Scope: Project]` | 專案專用,不對外發布 | CI/CD 設定、團隊慣例 |
214
+ | `[Scope: Universal]` | 可被其他專案複用 | 編碼標準、測試模式 |
215
+ | `[Scope: Utility]` | 工具/生成器,不需核心標準 | docs-generator、code-formatter |
216
+
217
+ ---
218
+
219
+ ## Bugfix 規格模板(易回歸修復)
220
+
221
+ > XSPEC-264。不是每個 bug 都需要規格——**瑣碎** bug 保持輕量即可。但**易回歸**的修復
222
+ >(觸及共用程式碼、遷移或曾被修復又破壞的路徑)值得一份輕量的
223
+ > `<BUG-ID>.bugfix.md`——比功能規格便宜得多,比盲目修補安全得多。
224
+
225
+ ```markdown
226
+ # <BUG-ID>: <簡短標題>
227
+
228
+ ## Current behavior(當前行為)
229
+ 現在發生的事(缺陷) + 重現步驟。
230
+
231
+ ## Expected behavior(預期行為)
232
+ 應該發生的事。
233
+
234
+ ## Unchanged behavior(不變行為)
235
+ 明確列出**不應改變**的內容——回歸防護範圍。
236
+
237
+ ## Root cause(根本原因)
238
+ 連結系統性除錯分析(5 個為什麼 / 二分法)。
239
+
240
+ ## Regression test(回歸測試)
241
+ 修復前失敗、修復後通過的測試——並且斷言「不變行為」仍然成立。
242
+ 將此測試視為 AC(acceptance-criteria-traceability: `@AC <BUG-ID>`)。
243
+ ```
244
+
245
+ **使用時機**(參見上方變更評估表):瑣碎 → 輕量;易回歸 → 使用此模板。`Unchanged behavior`(不變行為)+ `Regression test`(回歸測試)兩節,正是 UDS 自身的遷移/重構回歸(XSPEC-199/200/201)屢屢缺少的。設計上保持輕量;不要把瑣碎 bug 升級。
246
+
247
+ ---
248
+
31
249
  ## SDD 工作流程
32
250
 
33
251
  ```
@@ -45,12 +263,61 @@ status: current
45
263
 
46
264
  | 階段 | 說明 | 產出物 |
47
265
  |------|------|--------|
48
- | **討論** | 釐清需求與探索方案 | 討論紀錄 |
266
+ | **討論** | 釐清灰色地帶、鎖定範圍、建立 read_first 清單 | 範圍定義、規範參考 |
49
267
  | **提案** | 定義變更內容與原因 | `proposal.md` |
50
268
  | **審查** | 利害關係人核准 | 審查意見、核准紀錄 |
51
269
  | **實作** | 執行已核准的規格 | 程式碼、測試、文件 |
52
- | **驗證** | 確認實作符合規格 | 測試結果、審查 |
53
- | **歸檔** | 關閉並歸檔規格 | 已歸檔的規格與 commits/PRs 連結 |
270
+ | **驗證** | 確認實作符合規格(最多 3 次迭代) | 測試結果、追蹤矩陣 |
271
+ | **歸檔** | 關閉並歸檔規格 | 已歸檔規格及 commits/PRs 連結 |
272
+
273
+ ---
274
+
275
+ ## 雙向同步評估
276
+
277
+ 處理規格及其實作時,始終評估哪些內容需要同步。變更可能來自任何產出物,並應傳播至相關產出物。
278
+
279
+ ### 同步矩陣
280
+
281
+ | 變更來源 | 需評估同步至 |
282
+ |---------|------------|
283
+ | 核心標準 | → Skills、Commands、AI YAML、翻譯 |
284
+ | Skill | → 核心標準(如適用)、Commands、翻譯 |
285
+ | Command | → Skill、核心標準(如適用)、翻譯 |
286
+
287
+ ### 同步檢查清單範本
288
+
289
+ 在規格文件中加入此檢查清單:
290
+
291
+ ```markdown
292
+ ## Sync Checklist(同步檢查清單)
293
+
294
+ ### 從核心標準出發
295
+ - [ ] 建立/更新對應的 Skill?(若需互動)
296
+ - [ ] 建立/更新 Slash Command?(若需使用者觸發)
297
+ - [ ] 更新翻譯?(zh-TW、zh-CN 等)
298
+ - [ ] 更新 AI YAML 版本?(如適用)
299
+
300
+ ### 從 Skill 出發
301
+ - [ ] 此 Skill 應有核心標準嗎?
302
+ - [ ] 若為工具 Skill(如 docs-generator),標記為 "[Scope: Utility]"?
303
+ - [ ] 建立 Slash Command?
304
+ - [ ] 更新翻譯?
305
+
306
+ ### 從 Command 出發
307
+ - [ ] 此 Command 屬於哪個 Skill?
308
+ - [ ] 更新 Skill 文件?
309
+ - [ ] 更新翻譯?
310
+ ```
311
+
312
+ ### 同步標記
313
+
314
+ 在文件中使用以下標記表示同步狀態:
315
+
316
+ | 標記 | 含義 |
317
+ |------|------|
318
+ | `[Synced: ✓]` | 所有相關產出物已同步 |
319
+ | `[Synced: Pending]` | 需要同步但尚未完成 |
320
+ | `[Synced: N/A]` | 沒有需要同步的相關產出物(如獨立工具) |
54
321
 
55
322
  ---
56
323
 
@@ -58,7 +325,7 @@ status: current
58
325
 
59
326
  ### 1. SDD 工具命令優先
60
327
 
61
- **規則**: 當專案整合了 SDD 工具(如 OpenSpec, Spec Kit 等)且該工具提供特定命令(例如 `/openspec` 或 `/spec` 等斜線命令)時,AI 助手**必須優先使用這些命令**,而非直接手動編輯檔案。
328
+ **規則**: 當專案整合了 SDD 工具(如 OpenSpecSpec Kit 等)且該工具提供特定命令(例如 `/openspec` 或 `/spec` 等斜線命令)時,AI 助手**必須優先使用這些命令**,而非直接手動編輯檔案。
62
329
 
63
330
  **理由**:
64
331
  - **一致性**: 工具確保規格結構遵循嚴格的架構。
@@ -75,7 +342,7 @@ status: current
75
342
  **規則**: SDD 是一種方法論,不綁定於單一工具。雖然 OpenSpec 是常見的實作,但本標準適用於任何 SDD 工具(例如 Spec Kit)。
76
343
 
77
344
  **指引**:
78
- - **通用流程**: 討論 -> 提案 -> 審查 -> 實作 -> 驗證 -> 歸檔。
345
+ - **通用流程**: 討論 提案 審查 實作 驗證 歸檔。
79
346
  - **工具適應**: 適應工作區中啟用之 SDD 工具的特定命令與模式。
80
347
 
81
348
  ---
@@ -224,11 +491,11 @@ Refs: SPEC-001
224
491
 
225
492
  當規格透過反向工程生成時:
226
493
 
227
- 1. **標記狀態**:在元資料中包含 `狀態: 草稿(反向工程)`
228
- 2. **填寫未知**:所有 `[未知]` 區塊必須由人類在核准前填寫
229
- 3. **驗證推論**:所有 `[推論]` 項目必須經過審查和確認
230
- 4. **標準審查**:在實作前遵循正常 SDD 審查流程
231
- 5. **來源引用**:維護 file:line 參考以確保可追溯性
494
+ 1. **標記狀態**: 在元資料中包含 `Status: Draft (Reverse-Engineered)`
495
+ 2. **填寫未知**: 所有 `[Unknown]` 區塊必須由人類在核准前填寫
496
+ 3. **驗證推論**: 所有 `[Inferred]` 項目必須經過審查和確認
497
+ 4. **標準審查**: 在實作前遵循正常 SDD 審查流程
498
+ 5. **來源引用**: 維護 file:line 參考以確保可追溯性
232
499
 
233
500
  ### 何時使用反向工程
234
501
 
@@ -249,6 +516,216 @@ Refs: SPEC-001
249
516
 
250
517
  ---
251
518
 
519
+ ## 與正向推演整合
520
+
521
+ ### 概述
522
+
523
+ 規格核准後,使用[正向推演標準](../../core/forward-derivation-standards.md)從驗收條件自動生成 BDD 情境、TDD 測試骨架和 ATDD 驗收測試。
524
+
525
+ ### 正向推演 → SDD 流水線
526
+
527
+ ```
528
+ ┌─────────────────────────────────────────────────────────────────────────┐
529
+ │ 已核准規格 → 正向推演流水線 │
530
+ ├─────────────────────────────────────────────────────────────────────────┤
531
+ │ │
532
+ │ APPROVED SPEC-XXX.md │
533
+ │ │ │
534
+ │ ▼ │
535
+ │ ┌────────────────────────────────────────────────────────────┐ │
536
+ │ │ /derive-all specs/SPEC-XXX.md │ │
537
+ │ │ • 解析驗收條件 │ │
538
+ │ │ • 轉換 AC → Gherkin 情境 [已生成] │ │
539
+ │ │ • 生成 TDD 測試骨架 [已生成] │ │
540
+ │ │ • 建立 ATDD 驗收表格 [已生成] │ │
541
+ │ └────────────────────────────────────────────────────────────┘ │
542
+ │ │ │
543
+ │ ▼ │
544
+ │ 輸出檔案 │
545
+ │ ├── features/SPEC-XXX.feature(BDD) │
546
+ │ ├── tests/SPEC-XXX.test.ts(TDD) │
547
+ │ └── acceptance/SPEC-XXX-acceptance.md(ATDD) │
548
+ │ │ │
549
+ │ ▼ │
550
+ │ 人類審查 → BDD/TDD 工作流程繼續 │
551
+ │ │
552
+ └─────────────────────────────────────────────────────────────────────────┘
553
+ ```
554
+
555
+ ### 何時使用正向推演
556
+
557
+ | 情境 | 做法 |
558
+ |------|------|
559
+ | 規格已核准,開始實作 | 用 `/derive-all` 生成測試結構 |
560
+ | 快速需要 BDD 情境 | 用 `/derive-bdd` 生成 Gherkin |
561
+ | 開始 TDD 工作流程 | 用 `/derive-tdd` 生成測試骨架 |
562
+ | 手動驗收測試 | 用 `/derive-atdd` 生成測試表格 |
563
+
564
+ ### 相關命令
565
+
566
+ | 命令 | 輸入 | 輸出 | 用途 |
567
+ |------|------|------|------|
568
+ | `/derive-bdd` | SPEC-XXX.md | .feature | AC → Gherkin 情境 |
569
+ | `/derive-tdd` | SPEC-XXX.md | .test.ts | AC → 測試骨架 |
570
+ | `/derive-atdd` | SPEC-XXX.md | acceptance.md | AC → 測試表格 |
571
+ | `/derive-all` | SPEC-XXX.md | 以上全部 | 完整推演流水線 |
572
+ | `/derive-contracts` | SPEC-XXX.md | contract.json, schema.json | AC → 契約驗證 |
573
+
574
+ ---
575
+
576
+ ## 驗證層
577
+
578
+ SDD 需要強健的驗證機制,確保生成的程式碼與規格一致。驗證層在整個開發生命週期提供持續驗證。
579
+
580
+ ### 理論基礎
581
+
582
+ | 理論 | 來源 | 在 SDD 中的應用 |
583
+ |------|------|---------------|
584
+ | **契約式設計** | Bertrand Meyer, 1986 | AC 作為前後置條件 |
585
+ | **正式驗證** | 電腦科學 | 規格 vs 實作 |
586
+ | **規格即範例** | Gojko Adzic, 2011 | 可執行規格 |
587
+ | **契約測試** | Pact, 2013+ | 服務契約驗證 |
588
+
589
+ ### 驗證機制
590
+
591
+ | 機制 | 用途 | 工具 |
592
+ |------|------|------|
593
+ | **契約測試** | 驗證實作是否遵守介面保證 | Pact、Spring Cloud Contract、Specmatic |
594
+ | **Schema 驗證** | 拒絕違反結構要求的 payload | JSON Schema、OpenAPI 驗證器 |
595
+ | **漂移偵測** | 偵測規格與行為的偏離 | CI/CD 整合、Specmatic |
596
+ | **向後相容性** | 將變更分類為新增/破壞性 | OpenAPI diff 工具 |
597
+
598
+ ### SDD 驗證流程
599
+
600
+ ```
601
+ ┌─────────────────────────────────────────────────────────────────────────────┐
602
+ │ SDD 驗證層 │
603
+ ├─────────────────────────────────────────────────────────────────────────────┤
604
+ │ │
605
+ │ SPEC-XXX.md(已核准) │
606
+ │ │ │
607
+ │ ├──→ 正向推演 │
608
+ │ │ │ │
609
+ │ │ ├──→ 契約測試(已生成) │
610
+ │ │ ├──→ Schema 驗證器(已生成) │
611
+ │ │ ├──→ BDD 情境(已生成) │
612
+ │ │ └──→ TDD 骨架(已生成) │
613
+ │ │ │
614
+ │ └──→ 實作(AI 輔助) │
615
+ │ │ │
616
+ │ ▼ │
617
+ │ ┌─────────────────────────────────────────────────────┐ │
618
+ │ │ 持續驗證 │ │
619
+ │ │ ┌─────────────────────────────────────────────────┐│ │
620
+ │ │ │ 契約測試 ✓/✗ ││ │
621
+ │ │ │ Schema 驗證 ✓/✗ ││ │
622
+ │ │ │ 漂移偵測 ✓/✗ ││ │
623
+ │ │ │ BDD 情境 ✓/✗ ││ │
624
+ │ │ │ TDD 單元測試 ✓/✗ ││ │
625
+ │ │ └─────────────────────────────────────────────────┘│ │
626
+ │ └─────────────────────────────────────────────────────┘ │
627
+ │ │ │
628
+ │ ▼ │
629
+ │ 驗證報告 → 歸檔或迭代 │
630
+ │ │
631
+ └─────────────────────────────────────────────────────────────────────────────┘
632
+ ```
633
+
634
+ ### 生成的驗證產出物
635
+
636
+ | 產出物 | 用途 | 驗證角色 |
637
+ |--------|------|---------|
638
+ | `.feature`(BDD) | 行為情境 | 驗收驗證 |
639
+ | `.test.ts`(TDD) | 單元測試骨架 | 實作驗證 |
640
+ | `acceptance.md`(ATDD) | 驗收測試表格 | 商業驗證 |
641
+ | `contract.json` | 契約定義 | 介面驗證 |
642
+ | `schema.json` | Schema 定義 | 結構驗證 |
643
+
644
+ ### SDD 中的 V&V
645
+
646
+ - **驗證(Verification)**(正確地建造):契約測試通過、schema 有效、程式碼符合規格
647
+ - **確認(Validation)**(建造正確的東西):AC 達成、利害關係人核准、商業價值交付
648
+
649
+ ### 參考資料
650
+
651
+ - [InfoQ: Spec-Driven Development - Validation Layer](https://www.infoq.com/articles/spec-driven-development/)
652
+ - [Microsoft: Consumer-Driven Contract Testing](https://microsoft.github.io/code-with-engineering-playbook/automated-testing/cdc-testing/)
653
+ - [Wikipedia: Formal Verification](https://en.wikipedia.org/wiki/Formal_verification)
654
+ - [Specmatic: AI-powered API Contract Testing](https://specmatic.io/)
655
+
656
+ ---
657
+
658
+ ## SDD + 測試整合模型
659
+
660
+ ### 理論基礎
661
+
662
+ SDD 驗證植基於成熟的測試理論:
663
+
664
+ ```
665
+ 契約式設計(1986) 規格即範例(2011)
666
+ │ │
667
+ ▼ ▼
668
+ ┌───────────────────────────────────────────────────────────────┐
669
+ │ SDD 驗證模型 │
670
+ │ │
671
+ │ 規格(AC) ←──→ 契約測試 ←──→ 實作 │
672
+ │ ↑ ↑ ↓ │
673
+ │ 前後置 驗證 執行時 │
674
+ │ 條件 機制 行為 │
675
+ └───────────────────────────────────────────────────────────────┘
676
+ ```
677
+
678
+ ### 整合點
679
+
680
+ | SDD 階段 | 測試整合 | 理論 |
681
+ |---------|---------|------|
682
+ | **規格撰寫** | AC = 前後置條件 | 契約式設計 |
683
+ | **正向推演** | 生成契約測試 | 可執行規格 |
684
+ | **實作** | TDD(可選) | 測試驅動開發 |
685
+ | **驗證** | 契約測試 + 漂移偵測 | 執行時驗證 |
686
+ | **歸檔** | 測試結果作為證據 | 可追溯性 |
687
+
688
+ ### 實務工作流程
689
+
690
+ ```
691
+ ┌─────────────────────────────────────────────────────────────────────────────┐
692
+ │ 實務 SDD 工作流程 │
693
+ ├─────────────────────────────────────────────────────────────────────────────┤
694
+ │ │
695
+ │ 【輸入來源】(以下任一) │
696
+ │ ├── 需求訪談(最常見) │
697
+ │ ├── 利害關係人郵件/文件 │
698
+ │ ├── 產品需求文件(PRD) │
699
+ │ └── ATDD 工作坊(可選協作) │
700
+ │ ↓ │
701
+ │ 【SDD 提案撰寫】 │
702
+ │ SPEC-XXX.md 包含: │
703
+ │ - 摘要、動機 │
704
+ │ - 詳細設計 │
705
+ │ - 驗收條件(Given-When-Then) │
706
+ │ - 相依性、風險 │
707
+ │ ↓ │
708
+ │ 【審查與核准】 │
709
+ │ ↓ │
710
+ │ 【正向推演】 │
711
+ │ /derive-all → .feature, .test.ts, acceptance.md, contract.json │
712
+ │ ↓ │
713
+ │ 【實作】(TDD 可選) │
714
+ │ ↓ │
715
+ │ 【驗證】→ 【歸檔】 │
716
+ │ │
717
+ └─────────────────────────────────────────────────────────────────────────────┘
718
+ ```
719
+
720
+ ### 與傳統方法的主要調整
721
+
722
+ 1. **ATDD 工作坊是可選的**: 不是每個功能都需要正式工作坊
723
+ 2. **規格是起點**: 無論輸入來源為何,均轉換為 SPEC-XXX.md
724
+ 3. **Given-When-Then 已內嵌**: AC 格式借鑒 BDD,但不要求正式的 ATDD 流程
725
+ 4. **正向推演填補缺口**: 自動生成測試結構,彌補無工作坊的不足
726
+
727
+ ---
728
+
252
729
  ## 與正向/反向工程的整合
253
730
 
254
731
  本標準與兩個互補標準共同組成完整的規格生態系統:
@@ -299,17 +776,17 @@ Refs: SPEC-001
299
776
 
300
777
  ## 相關標準
301
778
 
302
- - [正向推演標準](../../core/forward-derivation-standards.md) - 規格轉測試轉換(規格 → BDD/TDD/ATDD)
303
- - [反向工程標準](../../core/reverse-engineering-standards.md) - 程式碼轉規格轉換
304
- - [測試驅動開發](../../core/test-driven-development.md) - TDD 工作流程與 SDD 整合
305
- - [行為驅動開發](../../../../core/behavior-driven-development.md) - BDD 工作流程與 Given-When-Then 情境
306
- - [驗收測試驅動開發](../../../../core/acceptance-test-driven-development.md) - ATDD 工作流程與商業驗收
307
- - [測試標準](../../core/testing-standards.md) - 測試框架與最佳實踐(或使用 `/testing-guide` 技能)
308
- - [測試完整性維度](../../core/test-completeness-dimensions.md) - 7 維度測試覆蓋
309
- - [Commit 訊息指南](../../core/commit-message-guide.md) - Commit 訊息規範
310
- - [程式碼簽入標準](../../core/checkin-standards.md) - 程式碼簽入標準
311
- - [程式碼審查清單](../../core/code-review-checklist.md) - 程式碼審查清單
312
- - [文件結構標準](../../core/documentation-structure.md) - 文件結構標準
779
+ - [正向推演標準](../../core/forward-derivation-standards.md) 規格轉測試轉換(規格 → BDD/TDD/ATDD)
780
+ - [反向工程標準](../../core/reverse-engineering-standards.md) 程式碼轉規格轉換(程式碼 → 規格)
781
+ - [測試驅動開發](../../core/test-driven-development.md) TDD 工作流程與 SDD 整合
782
+ - [行為驅動開發](../../core/behavior-driven-development.md) BDD 工作流程與 Given-When-Then 情境
783
+ - [驗收測試驅動開發](../../core/acceptance-test-driven-development.md) ATDD 工作流程與商業驗收
784
+ - [測試標準](../../core/testing-standards.md) 測試框架與最佳實踐(或使用 `/testing-guide` 技能)
785
+ - [測試完整性維度](../../core/test-completeness-dimensions.md) 8 維度測試覆蓋
786
+ - [Commit 訊息指南](../../core/commit-message-guide.md) Commit 訊息規範
787
+ - [程式碼簽入標準](../../core/checkin-standards.md) 程式碼簽入標準
788
+ - [程式碼審查清單](../../core/code-review-checklist.md) 程式碼審查清單
789
+ - [文件結構標準](../../core/documentation-structure.md) 文件結構標準
313
790
 
314
791
  ---
315
792
 
@@ -317,6 +794,9 @@ Refs: SPEC-001
317
794
 
318
795
  | 版本 | 日期 | 變更內容 |
319
796
  |------|------|----------|
797
+ | 2.1.0 | 2026-01-26 | 新增:變更評估(SDD 前置評估)章節含決策樹、雙向同步評估章節含同步矩陣與檢查清單 |
798
+ | 2.0.0 | 2026-01-25 | **重大重構**:新增「SDD 作為獨立方法論」章節(將 SDD 與 TDD/BDD/ATDD 家族分離)、成熟度等級(Martin Fowler 2025)、常見陷阱、含理論基礎的驗證層、SDD + 測試整合模型、/derive-contracts 命令 |
799
+ | 1.4.0 | 2026-01-19 | 新增:與正向推演整合章節、derive 命令 |
320
800
  | 1.3.0 | 2026-01-19 | 新增:與反向工程整合章節、相關命令 |
321
801
  | 1.2.0 | 2026-01-05 | 新增:IEEE 830-1998 和 SWEBOK v4.0 第 1 章(軟體需求)至參考資料 |
322
802
  | 1.1.0 | 2025-12-24 | 新增:工作流程圖、規格範本、整合指南、最佳實踐、相關標準、授權 |
@@ -326,11 +806,28 @@ Refs: SPEC-001
326
806
 
327
807
  ## 參考資料
328
808
 
809
+ ### SDD(2025 AI 時代)
810
+
811
+ - [Thoughtworks: Spec-Driven Development](https://www.thoughtworks.com/en-us/insights/blog/agile-engineering-practices/spec-driven-development-unpacking-2025-new-engineering-practices)
812
+ - [Martin Fowler: SDD Tools (Kiro, spec-kit, Tessl)](https://martinfowler.com/articles/exploring-gen-ai/sdd-3-tools.html)
813
+ - [GitHub spec-kit](https://github.com/github/spec-kit/blob/main/spec-driven.md)
814
+ - [InfoQ: Spec-Driven Development](https://www.infoq.com/articles/spec-driven-development/)
815
+
816
+ ### 傳統需求工程
817
+
329
818
  - [OpenSpec Documentation](https://github.com/openspec)
330
819
  - [Design Documents Best Practices](https://www.industrialempathy.com/posts/design-docs-at-google/)
331
820
  - [ADR (Architecture Decision Records)](https://adr.github.io/)
332
- - [IEEE 830-1998 - 軟體需求規格](https://standards.ieee.org/ieee/830/1222/) - 需求文件標準
333
- - [SWEBOK v4.0 - 第 1 章:軟體需求](https://www.computer.org/education/bodies-of-knowledge/software-engineering) - IEEE Computer Society
821
+ - [IEEE 830-1998 軟體需求規格](https://standards.ieee.org/ieee/830/1222/) 需求文件標準
822
+ - [SWEBOK v4.0 第 1 章:軟體需求](https://www.computer.org/education/bodies-of-knowledge/software-engineering) IEEE Computer Society
823
+
824
+ ### 驗證理論
825
+
826
+ - [Design by Contract — Bertrand Meyer, 1986](https://en.wikipedia.org/wiki/Design_by_contract) — 前後置條件理論
827
+ - [Wikipedia: Formal Verification](https://en.wikipedia.org/wiki/Formal_verification) — 正式驗證理論
828
+ - [Microsoft: Consumer-Driven Contract Testing](https://microsoft.github.io/code-with-engineering-playbook/automated-testing/cdc-testing/) — 契約測試框架
829
+ - [Specmatic: AI-powered API Contract Testing](https://specmatic.io/) — 現代契約測試工具
830
+ - [Gojko Adzic: Specification by Example](https://gojko.net/books/specification-by-example/) — 可執行規格(2011)
334
831
 
335
832
  ---
336
833