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.
Files changed (355) hide show
  1. package/bin/uds.js +5 -3
  2. package/bundled/ai/standards/acceptance-criteria-traceability.ai.yaml +178 -0
  3. package/bundled/ai/standards/agent-dispatch.ai.yaml +69 -0
  4. package/bundled/ai/standards/ai-command-behavior.ai.yaml +45 -0
  5. package/bundled/ai/standards/api-design-standards.ai.yaml +192 -0
  6. package/bundled/ai/standards/branch-completion.ai.yaml +82 -0
  7. package/bundled/ai/standards/change-batching-standards.ai.yaml +195 -0
  8. package/bundled/ai/standards/database-standards.ai.yaml +220 -0
  9. package/bundled/ai/standards/error-codes.ai.yaml +37 -2
  10. package/bundled/ai/standards/git-worktree.ai.yaml +77 -0
  11. package/bundled/ai/standards/logging.ai.yaml +21 -2
  12. package/bundled/ai/standards/model-selection.ai.yaml +81 -0
  13. package/bundled/ai/standards/pipeline-integration-standards.ai.yaml +184 -0
  14. package/bundled/ai/standards/systematic-debugging.ai.yaml +73 -0
  15. package/bundled/ai/standards/verification-evidence.ai.yaml +84 -0
  16. package/bundled/ai/standards/workflow-enforcement.ai.yaml +253 -0
  17. package/bundled/core/acceptance-criteria-traceability.md +293 -0
  18. package/bundled/core/agent-dispatch.md +149 -0
  19. package/bundled/core/ai-command-behavior.md +239 -0
  20. package/bundled/core/api-design-standards.md +938 -0
  21. package/bundled/core/branch-completion.md +158 -0
  22. package/bundled/core/change-batching-standards.md +257 -0
  23. package/bundled/core/checkin-standards.md +43 -6
  24. package/bundled/core/database-standards.md +828 -0
  25. package/bundled/core/error-code-standards.md +228 -2
  26. package/bundled/core/forward-derivation-standards.md +54 -2
  27. package/bundled/core/git-worktree.md +131 -0
  28. package/bundled/core/model-selection.md +153 -0
  29. package/bundled/core/pipeline-integration-standards.md +230 -0
  30. package/bundled/core/systematic-debugging.md +156 -0
  31. package/bundled/core/testing-standards.md +49 -39
  32. package/bundled/core/verification-evidence.md +172 -0
  33. package/bundled/core/workflow-enforcement.md +132 -0
  34. package/bundled/locales/zh-CN/CLAUDE.md +2 -2
  35. package/bundled/locales/zh-CN/README.md +4 -4
  36. package/bundled/locales/zh-CN/SECURITY.md +92 -0
  37. package/bundled/locales/zh-CN/core/acceptance-criteria-traceability.md +301 -0
  38. package/bundled/locales/zh-CN/core/acceptance-test-driven-development.md +47 -0
  39. package/bundled/locales/zh-CN/core/accessibility-standards.md +124 -0
  40. package/bundled/locales/zh-CN/core/agent-dispatch.md +113 -0
  41. package/bundled/locales/zh-CN/core/ai-agreement-standards.md +103 -0
  42. package/bundled/locales/zh-CN/core/ai-command-behavior.md +247 -0
  43. package/bundled/locales/zh-CN/core/api-design-standards.md +946 -0
  44. package/bundled/locales/zh-CN/core/behavior-driven-development.md +48 -0
  45. package/bundled/locales/zh-CN/core/branch-completion.md +112 -0
  46. package/bundled/locales/zh-CN/core/change-batching-standards.md +265 -0
  47. package/bundled/locales/zh-CN/core/checkin-standards.md +43 -5
  48. package/bundled/locales/zh-CN/core/context-aware-loading.md +106 -0
  49. package/bundled/locales/zh-CN/core/database-standards.md +836 -0
  50. package/bundled/locales/zh-CN/core/deployment-standards.md +80 -0
  51. package/bundled/locales/zh-CN/core/error-code-standards.md +2 -2
  52. package/bundled/locales/zh-CN/core/forward-derivation-standards.md +493 -0
  53. package/bundled/locales/zh-CN/core/git-worktree.md +101 -0
  54. package/bundled/locales/zh-CN/core/model-selection.md +112 -0
  55. package/bundled/locales/zh-CN/core/performance-standards.md +104 -0
  56. package/bundled/locales/zh-CN/core/pipeline-integration-standards.md +238 -0
  57. package/bundled/locales/zh-CN/core/project-context-memory.md +124 -0
  58. package/bundled/locales/zh-CN/core/requirement-engineering.md +49 -0
  59. package/bundled/locales/zh-CN/core/security-standards.md +100 -0
  60. package/bundled/locales/zh-CN/core/systematic-debugging.md +106 -0
  61. package/bundled/locales/zh-CN/core/test-governance.md +116 -0
  62. package/bundled/locales/zh-CN/core/testing-standards.md +392 -156
  63. package/bundled/locales/zh-CN/core/verification-evidence.md +118 -0
  64. package/bundled/locales/zh-CN/core/virtual-organization-standards.md +104 -0
  65. package/bundled/locales/zh-CN/core/workflow-enforcement.md +132 -0
  66. package/bundled/locales/zh-CN/docs/CHEATSHEET.md +27 -1
  67. package/bundled/locales/zh-CN/docs/CLI-INIT-OPTIONS.md +9 -1
  68. package/bundled/locales/zh-CN/docs/FEATURE-REFERENCE.md +37 -9
  69. package/bundled/locales/zh-CN/docs/USER-MANUAL.md +652 -0
  70. package/bundled/locales/zh-CN/integrations/github-copilot/copilot-instructions.md +1 -1
  71. package/bundled/locales/zh-CN/integrations/openspec/AGENTS.md +29 -4
  72. package/bundled/locales/zh-CN/integrations/spec-kit/AGENTS.md +143 -72
  73. package/bundled/locales/zh-CN/skills/ac-coverage-assistant/SKILL.md +126 -0
  74. package/bundled/locales/zh-CN/skills/api-design-assistant/SKILL.md +100 -0
  75. package/bundled/locales/zh-CN/skills/brainstorm-assistant/SKILL.md +119 -0
  76. package/bundled/locales/zh-CN/skills/ci-cd-assistant/SKILL.md +82 -0
  77. package/bundled/locales/zh-CN/skills/commands/ac-coverage.md +97 -0
  78. package/bundled/locales/zh-CN/skills/commands/api-design.md +94 -0
  79. package/bundled/locales/zh-CN/skills/commands/atdd.md +163 -0
  80. package/bundled/locales/zh-CN/skills/commands/audit.md +77 -0
  81. package/bundled/locales/zh-CN/skills/commands/bdd.md +1 -1
  82. package/bundled/locales/zh-CN/skills/commands/brainstorm.md +87 -0
  83. package/bundled/locales/zh-CN/skills/commands/changelog.md +63 -0
  84. package/bundled/locales/zh-CN/skills/commands/check.md +219 -0
  85. package/bundled/locales/zh-CN/skills/commands/checkin.md +61 -0
  86. package/bundled/locales/zh-CN/skills/commands/ci-cd.md +77 -0
  87. package/bundled/locales/zh-CN/skills/commands/commit.md +81 -0
  88. package/bundled/locales/zh-CN/skills/commands/config.md +207 -0
  89. package/bundled/locales/zh-CN/skills/commands/coverage.md +74 -0
  90. package/bundled/locales/zh-CN/skills/commands/database.md +78 -0
  91. package/bundled/locales/zh-CN/skills/commands/derive-all.md +58 -0
  92. package/bundled/locales/zh-CN/skills/commands/derive-atdd.md +54 -0
  93. package/bundled/locales/zh-CN/skills/commands/derive-bdd.md +53 -0
  94. package/bundled/locales/zh-CN/skills/commands/derive-tdd.md +54 -0
  95. package/bundled/locales/zh-CN/skills/commands/derive.md +78 -0
  96. package/bundled/locales/zh-CN/skills/commands/dev-workflow.md +119 -0
  97. package/bundled/locales/zh-CN/skills/commands/discover.md +86 -0
  98. package/bundled/locales/zh-CN/skills/commands/docgen.md +67 -0
  99. package/bundled/locales/zh-CN/skills/commands/docs.md +65 -0
  100. package/bundled/locales/zh-CN/skills/commands/durable.md +87 -0
  101. package/bundled/locales/zh-CN/skills/commands/guide.md +52 -0
  102. package/bundled/locales/zh-CN/skills/commands/incident.md +92 -0
  103. package/bundled/locales/zh-CN/skills/commands/init.md +272 -0
  104. package/bundled/locales/zh-CN/skills/commands/methodology.md +1 -1
  105. package/bundled/locales/zh-CN/skills/commands/metrics.md +73 -0
  106. package/bundled/locales/zh-CN/skills/commands/migrate.md +92 -0
  107. package/bundled/locales/zh-CN/skills/commands/pr.md +80 -0
  108. package/bundled/locales/zh-CN/skills/commands/refactor.md +1 -1
  109. package/bundled/locales/zh-CN/skills/commands/release.md +62 -0
  110. package/bundled/locales/zh-CN/skills/commands/requirement.md +54 -0
  111. package/bundled/locales/zh-CN/skills/commands/reverse-bdd.md +47 -0
  112. package/bundled/locales/zh-CN/skills/commands/reverse-sdd.md +51 -0
  113. package/bundled/locales/zh-CN/skills/commands/reverse-tdd.md +51 -0
  114. package/bundled/locales/zh-CN/skills/commands/reverse.md +63 -0
  115. package/bundled/locales/zh-CN/skills/commands/review.md +50 -0
  116. package/bundled/locales/zh-CN/skills/commands/scan.md +76 -0
  117. package/bundled/locales/zh-CN/skills/commands/sdd-retro.md +40 -0
  118. package/bundled/locales/zh-CN/skills/commands/sdd.md +379 -0
  119. package/bundled/locales/zh-CN/skills/commands/security.md +75 -0
  120. package/bundled/locales/zh-CN/skills/commands/tdd.md +111 -0
  121. package/bundled/locales/zh-CN/skills/commands/update.md +337 -0
  122. package/bundled/locales/zh-CN/skills/commit-standards/SKILL.md +1 -2
  123. package/bundled/locales/zh-CN/skills/database-assistant/SKILL.md +97 -0
  124. package/bundled/locales/zh-CN/skills/dev-workflow-guide/SKILL.md +145 -0
  125. package/bundled/locales/zh-CN/skills/durable-execution-assistant/SKILL.md +84 -0
  126. package/bundled/locales/zh-CN/skills/incident-response-assistant/SKILL.md +107 -0
  127. package/bundled/locales/zh-CN/skills/metrics-dashboard-assistant/SKILL.md +67 -0
  128. package/bundled/locales/zh-CN/skills/migration-assistant/SKILL.md +77 -0
  129. package/bundled/locales/zh-CN/skills/pr-automation-assistant/SKILL.md +90 -0
  130. package/bundled/locales/zh-CN/skills/security-assistant/SKILL.md +79 -0
  131. package/bundled/locales/zh-CN/skills/security-scan-assistant/SKILL.md +72 -0
  132. package/bundled/locales/zh-CN/skills/spec-driven-dev/SKILL.md +73 -10
  133. package/bundled/locales/zh-CN/skills/spec-driven-dev/guide.md +267 -122
  134. package/bundled/locales/zh-TW/CLAUDE.md +2 -2
  135. package/bundled/locales/zh-TW/README.md +4 -4
  136. package/bundled/locales/zh-TW/SECURITY.md +92 -0
  137. package/bundled/locales/zh-TW/core/acceptance-criteria-traceability.md +301 -0
  138. package/bundled/locales/zh-TW/core/acceptance-test-driven-development.md +47 -0
  139. package/bundled/locales/zh-TW/core/accessibility-standards.md +84 -0
  140. package/bundled/locales/zh-TW/core/agent-dispatch.md +89 -0
  141. package/bundled/locales/zh-TW/core/ai-agreement-standards.md +87 -0
  142. package/bundled/locales/zh-TW/core/ai-command-behavior.md +247 -0
  143. package/bundled/locales/zh-TW/core/api-design-standards.md +946 -0
  144. package/bundled/locales/zh-TW/core/behavior-driven-development.md +63 -0
  145. package/bundled/locales/zh-TW/core/branch-completion.md +76 -0
  146. package/bundled/locales/zh-TW/core/change-batching-standards.md +265 -0
  147. package/bundled/locales/zh-TW/core/checkin-standards.md +39 -5
  148. package/bundled/locales/zh-TW/core/context-aware-loading.md +86 -0
  149. package/bundled/locales/zh-TW/core/database-standards.md +836 -0
  150. package/bundled/locales/zh-TW/core/deployment-standards.md +66 -0
  151. package/bundled/locales/zh-TW/core/error-code-standards.md +230 -4
  152. package/bundled/locales/zh-TW/core/forward-derivation-standards.md +62 -2
  153. package/bundled/locales/zh-TW/core/git-worktree.md +104 -0
  154. package/bundled/locales/zh-TW/core/model-selection.md +83 -0
  155. package/bundled/locales/zh-TW/core/performance-standards.md +84 -0
  156. package/bundled/locales/zh-TW/core/pipeline-integration-standards.md +238 -0
  157. package/bundled/locales/zh-TW/core/project-context-memory.md +79 -0
  158. package/bundled/locales/zh-TW/core/requirement-engineering.md +79 -0
  159. package/bundled/locales/zh-TW/core/security-standards.md +74 -0
  160. package/bundled/locales/zh-TW/core/systematic-debugging.md +95 -0
  161. package/bundled/locales/zh-TW/core/test-governance.md +88 -0
  162. package/bundled/locales/zh-TW/core/testing-standards.md +309 -86
  163. package/bundled/locales/zh-TW/core/verification-evidence.md +94 -0
  164. package/bundled/locales/zh-TW/core/virtual-organization-standards.md +88 -0
  165. package/bundled/locales/zh-TW/core/workflow-enforcement.md +132 -0
  166. package/bundled/locales/zh-TW/docs/CHEATSHEET.md +27 -1
  167. package/bundled/locales/zh-TW/docs/CLI-INIT-OPTIONS.md +9 -1
  168. package/bundled/locales/zh-TW/docs/FEATURE-REFERENCE.md +37 -9
  169. package/bundled/locales/zh-TW/docs/USER-MANUAL.md +652 -0
  170. package/bundled/locales/zh-TW/integrations/github-copilot/copilot-instructions.md +1 -1
  171. package/bundled/locales/zh-TW/integrations/openspec/AGENTS.md +29 -4
  172. package/bundled/locales/zh-TW/integrations/spec-kit/AGENTS.md +142 -71
  173. package/bundled/locales/zh-TW/skills/ac-coverage-assistant/SKILL.md +127 -0
  174. package/bundled/locales/zh-TW/skills/ai-friendly-architecture/SKILL.md +1 -4
  175. package/bundled/locales/zh-TW/skills/ai-instruction-standards/SKILL.md +1 -4
  176. package/bundled/locales/zh-TW/skills/api-design-assistant/SKILL.md +97 -0
  177. package/bundled/locales/zh-TW/skills/atdd-assistant/SKILL.md +1 -4
  178. package/bundled/locales/zh-TW/skills/audit-assistant/SKILL.md +1 -4
  179. package/bundled/locales/zh-TW/skills/bdd-assistant/SKILL.md +1 -4
  180. package/bundled/locales/zh-TW/skills/brainstorm-assistant/SKILL.md +1 -4
  181. package/bundled/locales/zh-TW/skills/changelog-guide/SKILL.md +1 -4
  182. package/bundled/locales/zh-TW/skills/checkin-assistant/SKILL.md +1 -4
  183. package/bundled/locales/zh-TW/skills/ci-cd-assistant/SKILL.md +79 -0
  184. package/bundled/locales/zh-TW/skills/code-review-assistant/SKILL.md +1 -4
  185. package/bundled/locales/zh-TW/skills/commands/ac-coverage.md +95 -0
  186. package/bundled/locales/zh-TW/skills/commands/api-design.md +92 -0
  187. package/bundled/locales/zh-TW/skills/commands/atdd.md +167 -0
  188. package/bundled/locales/zh-TW/skills/commands/audit.md +75 -0
  189. package/bundled/locales/zh-TW/skills/commands/bdd.md +1 -1
  190. package/bundled/locales/zh-TW/skills/commands/brainstorm.md +91 -0
  191. package/bundled/locales/zh-TW/skills/commands/changelog.md +67 -0
  192. package/bundled/locales/zh-TW/skills/commands/check.md +223 -0
  193. package/bundled/locales/zh-TW/skills/commands/checkin.md +65 -0
  194. package/bundled/locales/zh-TW/skills/commands/ci-cd.md +75 -0
  195. package/bundled/locales/zh-TW/skills/commands/commit.md +85 -0
  196. package/bundled/locales/zh-TW/skills/commands/config.md +211 -0
  197. package/bundled/locales/zh-TW/skills/commands/coverage.md +78 -0
  198. package/bundled/locales/zh-TW/skills/commands/database.md +76 -0
  199. package/bundled/locales/zh-TW/skills/commands/derive-all.md +62 -0
  200. package/bundled/locales/zh-TW/skills/commands/derive-atdd.md +58 -0
  201. package/bundled/locales/zh-TW/skills/commands/derive-bdd.md +54 -0
  202. package/bundled/locales/zh-TW/skills/commands/derive-tdd.md +55 -0
  203. package/bundled/locales/zh-TW/skills/commands/derive.md +79 -0
  204. package/bundled/locales/zh-TW/skills/commands/dev-workflow.md +120 -0
  205. package/bundled/locales/zh-TW/skills/commands/discover.md +87 -0
  206. package/bundled/locales/zh-TW/skills/commands/docgen.md +68 -0
  207. package/bundled/locales/zh-TW/skills/commands/docs.md +66 -0
  208. package/bundled/locales/zh-TW/skills/commands/durable.md +85 -0
  209. package/bundled/locales/zh-TW/skills/commands/guide.md +51 -0
  210. package/bundled/locales/zh-TW/skills/commands/incident.md +90 -0
  211. package/bundled/locales/zh-TW/skills/commands/init.md +273 -0
  212. package/bundled/locales/zh-TW/skills/commands/methodology.md +1 -1
  213. package/bundled/locales/zh-TW/skills/commands/metrics.md +71 -0
  214. package/bundled/locales/zh-TW/skills/commands/migrate.md +90 -0
  215. package/bundled/locales/zh-TW/skills/commands/pr.md +78 -0
  216. package/bundled/locales/zh-TW/skills/commands/refactor.md +1 -1
  217. package/bundled/locales/zh-TW/skills/commands/release.md +63 -0
  218. package/bundled/locales/zh-TW/skills/commands/requirement.md +61 -0
  219. package/bundled/locales/zh-TW/skills/commands/reverse-bdd.md +54 -0
  220. package/bundled/locales/zh-TW/skills/commands/reverse-sdd.md +58 -0
  221. package/bundled/locales/zh-TW/skills/commands/reverse-tdd.md +58 -0
  222. package/bundled/locales/zh-TW/skills/commands/reverse.md +70 -0
  223. package/bundled/locales/zh-TW/skills/commands/review.md +57 -0
  224. package/bundled/locales/zh-TW/skills/commands/scan.md +74 -0
  225. package/bundled/locales/zh-TW/skills/commands/sdd-retro.md +47 -0
  226. package/bundled/locales/zh-TW/skills/commands/sdd.md +362 -0
  227. package/bundled/locales/zh-TW/skills/commands/security.md +73 -0
  228. package/bundled/locales/zh-TW/skills/commands/tdd.md +115 -0
  229. package/bundled/locales/zh-TW/skills/commands/update.md +326 -0
  230. package/bundled/locales/zh-TW/skills/commit-standards/SKILL.md +2 -6
  231. package/bundled/locales/zh-TW/skills/database-assistant/SKILL.md +94 -0
  232. package/bundled/locales/zh-TW/skills/dev-workflow-guide/SKILL.md +140 -0
  233. package/bundled/locales/zh-TW/skills/docs-generator/SKILL.md +1 -4
  234. package/bundled/locales/zh-TW/skills/documentation-guide/SKILL.md +1 -4
  235. package/bundled/locales/zh-TW/skills/durable-execution-assistant/SKILL.md +81 -0
  236. package/bundled/locales/zh-TW/skills/error-code-guide/SKILL.md +1 -4
  237. package/bundled/locales/zh-TW/skills/forward-derivation/SKILL.md +1 -4
  238. package/bundled/locales/zh-TW/skills/git-workflow-guide/SKILL.md +1 -4
  239. package/bundled/locales/zh-TW/skills/incident-response-assistant/SKILL.md +104 -0
  240. package/bundled/locales/zh-TW/skills/logging-guide/SKILL.md +1 -4
  241. package/bundled/locales/zh-TW/skills/methodology-system/SKILL.md +1 -4
  242. package/bundled/locales/zh-TW/skills/metrics-dashboard-assistant/SKILL.md +64 -0
  243. package/bundled/locales/zh-TW/skills/migration-assistant/SKILL.md +74 -0
  244. package/bundled/locales/zh-TW/skills/pr-automation-assistant/SKILL.md +87 -0
  245. package/bundled/locales/zh-TW/skills/project-discovery/SKILL.md +1 -4
  246. package/bundled/locales/zh-TW/skills/refactoring-assistant/SKILL.md +1 -4
  247. package/bundled/locales/zh-TW/skills/release-standards/SKILL.md +1 -4
  248. package/bundled/locales/zh-TW/skills/requirement-assistant/SKILL.md +1 -4
  249. package/bundled/locales/zh-TW/skills/reverse-engineer/SKILL.md +1 -4
  250. package/bundled/locales/zh-TW/skills/security-assistant/SKILL.md +76 -0
  251. package/bundled/locales/zh-TW/skills/security-scan-assistant/SKILL.md +69 -0
  252. package/bundled/locales/zh-TW/skills/spec-driven-dev/SKILL.md +74 -14
  253. package/bundled/locales/zh-TW/skills/spec-driven-dev/guide.md +243 -98
  254. package/bundled/locales/zh-TW/skills/tdd-assistant/SKILL.md +1 -4
  255. package/bundled/locales/zh-TW/skills/test-coverage-assistant/SKILL.md +1 -4
  256. package/bundled/locales/zh-TW/skills/testing-guide/SKILL.md +1 -5
  257. package/bundled/skills/README.md +11 -0
  258. package/bundled/skills/ac-coverage-assistant/SKILL.md +127 -0
  259. package/bundled/skills/ai-collaboration-standards/SKILL.md +10 -0
  260. package/bundled/skills/ai-friendly-architecture/SKILL.md +10 -0
  261. package/bundled/skills/ai-instruction-standards/SKILL.md +10 -0
  262. package/bundled/skills/api-design-assistant/SKILL.md +119 -0
  263. package/bundled/skills/atdd-assistant/SKILL.md +7 -0
  264. package/bundled/skills/bdd-assistant/SKILL.md +7 -0
  265. package/bundled/skills/brainstorm-assistant/SKILL.md +7 -0
  266. package/bundled/skills/checkin-assistant/SKILL.md +7 -0
  267. package/bundled/skills/ci-cd-assistant/SKILL.md +97 -0
  268. package/bundled/skills/code-review-assistant/SKILL.md +7 -0
  269. package/bundled/skills/commands/README.md +70 -0
  270. package/bundled/skills/commands/ac-coverage.md +135 -0
  271. package/bundled/skills/commands/api-design.md +86 -0
  272. package/bundled/skills/commands/atdd.md +69 -0
  273. package/bundled/skills/commands/audit.md +69 -0
  274. package/bundled/skills/commands/bdd.md +101 -0
  275. package/bundled/skills/commands/brainstorm.md +45 -0
  276. package/bundled/skills/commands/changelog.md +34 -0
  277. package/bundled/skills/commands/check.md +52 -1
  278. package/bundled/skills/commands/checkin.md +46 -0
  279. package/bundled/skills/commands/ci-cd.md +69 -0
  280. package/bundled/skills/commands/commit.md +79 -0
  281. package/bundled/skills/commands/config.md +48 -0
  282. package/bundled/skills/commands/coverage.md +53 -0
  283. package/bundled/skills/commands/database.md +70 -0
  284. package/bundled/skills/commands/derive-all.md +40 -0
  285. package/bundled/skills/commands/derive-atdd.md +33 -0
  286. package/bundled/skills/commands/derive-bdd.md +39 -0
  287. package/bundled/skills/commands/derive-tdd.md +40 -0
  288. package/bundled/skills/commands/derive.md +47 -0
  289. package/bundled/skills/commands/dev-workflow.md +104 -7
  290. package/bundled/skills/commands/discover.md +39 -0
  291. package/bundled/skills/commands/docgen.md +35 -0
  292. package/bundled/skills/commands/docs.md +40 -0
  293. package/bundled/skills/commands/durable.md +79 -0
  294. package/bundled/skills/commands/incident.md +84 -0
  295. package/bundled/skills/commands/init.md +55 -0
  296. package/bundled/skills/commands/methodology.md +72 -0
  297. package/bundled/skills/commands/metrics.md +65 -0
  298. package/bundled/skills/commands/migrate.md +84 -0
  299. package/bundled/skills/commands/pr.md +72 -0
  300. package/bundled/skills/commands/refactor.md +51 -0
  301. package/bundled/skills/commands/release.md +60 -0
  302. package/bundled/skills/commands/requirement.md +38 -0
  303. package/bundled/skills/commands/reverse-bdd.md +34 -0
  304. package/bundled/skills/commands/reverse-sdd.md +42 -0
  305. package/bundled/skills/commands/reverse-tdd.md +40 -0
  306. package/bundled/skills/commands/reverse.md +41 -0
  307. package/bundled/skills/commands/review.md +39 -0
  308. package/bundled/skills/commands/scan.md +68 -0
  309. package/bundled/skills/commands/sdd-retro.md +48 -0
  310. package/bundled/skills/commands/sdd.md +220 -0
  311. package/bundled/skills/commands/security.md +67 -0
  312. package/bundled/skills/commands/tdd.md +101 -0
  313. package/bundled/skills/commands/update.md +61 -0
  314. package/bundled/skills/commit-standards/SKILL.md +8 -2
  315. package/bundled/skills/database-assistant/SKILL.md +118 -0
  316. package/bundled/skills/dev-workflow-guide/SKILL.md +53 -7
  317. package/bundled/skills/dev-workflow-guide/workflow-phases.md +24 -0
  318. package/bundled/skills/durable-execution-assistant/SKILL.md +116 -0
  319. package/bundled/skills/forward-derivation/SKILL.md +7 -0
  320. package/bundled/skills/incident-response-assistant/SKILL.md +132 -0
  321. package/bundled/skills/methodology-system/SKILL.md +24 -2
  322. package/bundled/skills/metrics-dashboard-assistant/SKILL.md +109 -0
  323. package/bundled/skills/migration-assistant/SKILL.md +119 -0
  324. package/bundled/skills/pr-automation-assistant/SKILL.md +114 -0
  325. package/bundled/skills/project-discovery/SKILL.md +7 -0
  326. package/bundled/skills/refactoring-assistant/SKILL.md +7 -0
  327. package/bundled/skills/release-standards/SKILL.md +7 -0
  328. package/bundled/skills/requirement-assistant/SKILL.md +7 -0
  329. package/bundled/skills/reverse-engineer/SKILL.md +7 -0
  330. package/bundled/skills/security-assistant/SKILL.md +105 -0
  331. package/bundled/skills/security-scan-assistant/SKILL.md +96 -0
  332. package/bundled/skills/spec-driven-dev/SKILL.md +84 -4
  333. package/bundled/skills/spec-driven-dev/guide.md +156 -22
  334. package/bundled/skills/tdd-assistant/SKILL.md +7 -0
  335. package/bundled/skills/test-coverage-assistant/SKILL.md +11 -0
  336. package/bundled/skills/testing-guide/SKILL.md +23 -0
  337. package/package.json +1 -1
  338. package/src/commands/check.js +154 -8
  339. package/src/commands/config.js +231 -104
  340. package/src/commands/init.js +23 -3
  341. package/src/commands/update.js +250 -25
  342. package/src/config/ai-agent-paths.js +16 -0
  343. package/src/config/workflow-definitions.js +184 -0
  344. package/src/core/constants.js +6 -0
  345. package/src/flows/init-flow.js +23 -6
  346. package/src/i18n/messages.js +51 -3
  347. package/src/installers/integration-installer.js +67 -2
  348. package/src/installers/manifest-installer.js +1 -0
  349. package/src/installers/standards-installer.js +3 -2
  350. package/src/prompts/init.js +50 -3
  351. package/src/reconciler/manifest-migrator.js +2 -2
  352. package/src/reconciler/plan-executor.js +11 -0
  353. package/src/utils/integration-generator.js +327 -14
  354. package/src/utils/workflow-gate.js +292 -0
  355. package/standards-registry.json +160 -5
@@ -14,6 +14,10 @@ Map your current software development phase to the right UDS commands and skills
14
14
 
15
15
  將你目前的軟體開發階段對應到正確的 UDS 指令與技能。即時了解在開發的每個階段應該使用哪些工具。
16
16
 
17
+ > **Related**: To choose or switch between development methodologies (SDD, BDD, TDD), use `/methodology` instead.
18
+ >
19
+ > **相關**:如需選擇或切換開發方法論(SDD、BDD、TDD),請改用 `/methodology`。
20
+
17
21
  ## Software Development Phases Overview | 軟體開發階段總覽
18
22
 
19
23
  ```
@@ -28,13 +32,13 @@ V. Release ──► VI. Documentation ──► VII. Standards ──► VIII.
28
32
 
29
33
  | Phase | UDS Commands | Purpose | 用途 |
30
34
  |-------|-------------|---------|------|
31
- | **I. Planning & Design** | `/brainstorm` `/requirement` `/sdd` `/reverse` | Requirements, specs, reverse engineering | 需求、規格、逆向工程 |
32
- | **II. Test-Driven Development** | `/bdd` `/atdd` `/tdd` `/coverage` `/derive` | Design tests before code | 先寫測試再寫程式 |
33
- | **III. Implementation** | `/refactor` `/reverse` | Write and improve code | 撰寫與改善程式碼 |
34
- | **IV. Quality Gates** | `/checkin` `/review` | Pre-commit and code review | 提交前檢查與程式碼審查 |
35
- | **V. Release & Commit** | `/commit` `/changelog` `/release` | Version, commit, publish | 版本、提交、發布 |
36
- | **VI. Documentation** | `/docs` `/docgen` `/struct` | Docs and project structure | 文件與專案結構 |
37
- | **VII. Tools & Standards** | `/discover` `/testing` `/guide` `/git` | Reference guides | 參考指南 |
35
+ | **I. Planning & Design** | `/brainstorm` `/requirement` `/sdd` `/reverse` `/api-design` `/database` | Requirements, specs, API/DB design | 需求、規格、API/DB 設計 |
36
+ | **II. Test-Driven Development** | `/bdd` `/atdd` `/tdd` `/coverage` `/derive` `/ac-coverage` | Design tests before code | 先寫測試再寫程式 |
37
+ | **III. Implementation** | `/refactor` `/reverse` `/migrate` `/durable` | Write, improve, and migrate code | 撰寫、改善與遷移程式碼 |
38
+ | **IV. Quality Gates** | `/checkin` `/review` `/security` `/scan` `/incident` | Quality, security, incident response | 品質、安全、事故回應 |
39
+ | **V. Release & Commit** | `/commit` `/changelog` `/release` `/pr` `/ci-cd` | Version, commit, PR, CI/CD | 版本、提交、PR、CI/CD |
40
+ | **VI. Documentation** | `/docs` `/docgen` | Docs and project structure | 文件與專案結構 |
41
+ | **VII. Tools & Standards** | `/discover` `/guide` `/metrics` `/audit` | Reference guides, metrics, audit | 參考指南、指標、審計 |
38
42
  | **VIII. Advanced Analysis** | `/methodology` | Cross-methodology workflows | 跨方法論工作流程 |
39
43
 
40
44
  ## Common Scenarios | 常見場景
@@ -96,6 +100,42 @@ Recommended flow for code refactoring:
96
100
  | 5 | `/checkin` | Verify quality gates | 驗證品質關卡 |
97
101
  | 6 | `/commit` | Create conventional commit | 建立規範化提交 |
98
102
 
103
+ ### Scenario 4: Security Review | 安全審查
104
+
105
+ Recommended flow for security review and vulnerability remediation:
106
+
107
+ 安全審查與漏洞修復的推薦流程:
108
+
109
+ ```
110
+ /scan → /security → /checkin → /commit
111
+ ```
112
+
113
+ | Step | Command | What to Do | 做什麼 |
114
+ |------|---------|-----------|--------|
115
+ | 1 | `/scan` | Run automated security scans (deps, secrets) | 執行自動化安全掃描 |
116
+ | 2 | `/security` | Deep security review (OWASP) | 深入安全審查 |
117
+ | 3 | `/checkin` | Verify quality gates | 驗證品質關卡 |
118
+ | 4 | `/commit` | Create conventional commit | 建立規範化提交 |
119
+
120
+ ### Scenario 5: API Design & Implementation | API 設計與實作
121
+
122
+ Recommended flow for designing and implementing APIs:
123
+
124
+ API 設計與實作的推薦流程:
125
+
126
+ ```
127
+ /brainstorm → /api-design → /sdd → /derive → /tdd → /pr
128
+ ```
129
+
130
+ | Step | Command | What to Do | 做什麼 |
131
+ |------|---------|-----------|--------|
132
+ | 1 | `/brainstorm` | Explore API approaches | 探索 API 方案 |
133
+ | 2 | `/api-design` | Design endpoints and schemas | 設計端點與 schema |
134
+ | 3 | `/sdd` | Create specification document | 建立規格文件 |
135
+ | 4 | `/derive` | Generate test skeletons | 產生測試骨架 |
136
+ | 5 | `/tdd` | Implement with tests | 搭配測試實作 |
137
+ | 6 | `/pr` | Create pull request | 建立 Pull Request |
138
+
99
139
  ## Usage | 使用方式
100
140
 
101
141
  ```bash
@@ -122,6 +162,8 @@ Recommended flow for code refactoring:
122
162
  | `new-feature` | Scenario: New feature workflow | 場景:新功能開發 |
123
163
  | `bug-fix` | Scenario: Bug fix workflow | 場景:修復錯誤 |
124
164
  | `refactoring` | Scenario: Refactoring workflow | 場景:重構 |
165
+ | `security` | Scenario: Security review workflow | 場景:安全審查 |
166
+ | `api` | Scenario: API design workflow | 場景:API 設計 |
125
167
 
126
168
  ## Workflow Behavior | 工作流程行為
127
169
 
@@ -148,6 +190,9 @@ After `/dev-workflow` completes, the AI assistant should suggest based on user's
148
190
  > - 修復錯誤 → 執行 `/discover` 評估受影響區域 — Bug fix → Run `/discover` to assess affected area
149
191
  > - 重構程式碼 → 執行 `/discover` 評估健康度 — Refactoring → Run `/discover` to assess health
150
192
  > - 遺留系統 → 執行 `/reverse` 進行系統考古 — Legacy system → Run `/reverse` for system archeology
193
+ > - 安全審查 → 執行 `/scan` 掃描漏洞 — Security review → Run `/scan` to find vulnerabilities
194
+ > - API 開發 → 執行 `/api-design` 設計端點 — API development → Run `/api-design` to design endpoints
195
+ > - 事故回應 → 執行 `/incident` 啟動回應流程 — Incident → Run `/incident` to start response
151
196
 
152
197
  ## References | 參考
153
198
 
@@ -162,6 +207,7 @@ After `/dev-workflow` completes, the AI assistant should suggest based on user's
162
207
 
163
208
  | Version | Date | Changes |
164
209
  |---------|------|---------|
210
+ | 1.1.0 | 2026-03-24 | Add 11 new commands, 2 new scenarios (Security Review, API Design) |
165
211
  | 1.0.0 | 2026-03-04 | Initial: 8 development phases, 3 scenarios, phase-based navigation |
166
212
 
167
213
  ---
@@ -18,6 +18,8 @@
18
18
  | `/requirement` | Write user stories (INVEST) | Defining what to build | 定義要建立什麼 |
19
19
  | `/sdd` | Create specification document | Before implementation | 實作前 |
20
20
  | `/reverse` | Reverse engineer existing code | Understanding brownfield codebase | 理解既有程式碼 |
21
+ | `/api-design` | Design APIs (REST, GraphQL, gRPC) | Designing new API endpoints | 設計新 API 端點 |
22
+ | `/database` | Database design and migration | Schema design, migration planning | Schema 設計、遷移規劃 |
21
23
 
22
24
  ### Typical Flow | 典型流程
23
25
 
@@ -32,6 +34,8 @@ Idea → /brainstorm → /requirement → /sdd → Ready for Phase II
32
34
  - **`/requirement`**: You know what to build but need formal user stories. Outputs INVEST-compliant stories with acceptance criteria.
33
35
  - **`/sdd`**: You have requirements and need a technical specification. Creates a structured spec document with API design, data models, and acceptance criteria.
34
36
  - **`/reverse`**: You need to understand existing code before modifying it. Generates specs, BDD scenarios, or TDD coverage maps from existing code.
37
+ - **`/api-design`**: You need to design API endpoints following REST, GraphQL, or gRPC best practices. Guides you through DEFINE→DESIGN→VALIDATE→DOCUMENT.
38
+ - **`/database`**: You need to design a database schema, plan a migration, or optimize queries. Guides through PLAN→WRITE→TEST→DEPLOY→VERIFY.
35
39
 
36
40
  ---
37
41
 
@@ -85,11 +89,15 @@ SDD 規格 → /derive → /bdd → /tdd → 測試就緒
85
89
  |---------|---------|-------------|----------|
86
90
  | `/refactor` | Refactoring guidance | Improving code structure | 改善程式碼結構 |
87
91
  | `/reverse` | Reverse engineer code | Understanding code before changes | 修改前理解程式碼 |
92
+ | `/migrate` | Code migration guidance | Framework upgrades, tech modernization | 框架升級、技術現代化 |
93
+ | `/durable` | Failure recovery patterns | Checkpoints, retries, rollback | 檢查點、重試、回滾 |
88
94
 
89
95
  ### When to Use Each | 各指令適用場景
90
96
 
91
97
  - **`/refactor`**: Code works but needs structural improvement. Guides you through extract method, rename, move, and other refactoring patterns with safety checks.
92
98
  - **`/reverse`**: You're working in unfamiliar code and need to understand data flow, runtime behavior, or module boundaries before making changes.
99
+ - **`/migrate`**: You need to upgrade a framework (e.g., Vue 2→3), modernize dependencies, or move to a new tech stack. Guides through ASSESS→PLAN→PREPARE→MIGRATE→VERIFY→CLEANUP.
100
+ - **`/durable`**: Your workflow has failure points that need resilience. Helps design checkpoint, retry, and rollback strategies for long-running operations.
93
101
 
94
102
  ---
95
103
 
@@ -103,6 +111,9 @@ SDD 規格 → /derive → /bdd → /tdd → 測試就緒
103
111
  |---------|---------|-------------|----------|
104
112
  | `/checkin` | Pre-commit verification | Before every commit | 每次提交前 |
105
113
  | `/review` | Systematic code review | Before merging PRs | 合併 PR 前 |
114
+ | `/security` | Security review (OWASP) | Auditing for vulnerabilities | 審計漏洞 |
115
+ | `/scan` | Automated security scanning | Dependency audit, secret detection | 相依掃描、機密偵測 |
116
+ | `/incident` | Incident response | Production issues, post-mortems | 生產事故、事後檢討 |
106
117
 
107
118
  ### Checkin Verification | 提交前驗證
108
119
 
@@ -140,6 +151,8 @@ SDD 規格 → /derive → /bdd → /tdd → 測試就緒
140
151
  | `/commit` | Conventional Commits format | Creating each commit | 建立每次提交 |
141
152
  | `/changelog` | Generate changelog entries | Before releases | 發布前 |
142
153
  | `/release` | Release process management | Publishing versions | 發布版本 |
154
+ | `/pr` | Pull request automation | Creating and reviewing PRs | 建立與審查 PR |
155
+ | `/ci-cd` | CI/CD pipeline guidance | Designing/optimizing pipelines | 設計/優化管線 |
143
156
 
144
157
  ### Commit Message Format | 提交訊息格式
145
158
 
@@ -190,6 +203,8 @@ Types: `feat`, `fix`, `docs`, `chore`, `test`, `refactor`, `style`
190
203
  | Command | Purpose | When to Use | 使用時機 |
191
204
  |---------|---------|-------------|----------|
192
205
  | `/discover` | Project health assessment | Before major changes | 重大變更前 |
206
+ | `/metrics` | Development metrics tracking | Monitoring project health | 監控專案健康 |
207
+ | `/audit` | UDS health check | Checking standards adoption | 檢查標準採用 |
193
208
  | `/guide` | Access all UDS guides | Looking up standards | 查找標準 |
194
209
  | `/guide testing` | Testing standards | Setting up tests | 設定測試 |
195
210
  | `/guide error-codes` | Error code standards | Designing error codes | 設計錯誤碼 |
@@ -237,13 +252,22 @@ Start here | 從這裡開始
237
252
 
238
253
  ├─ "I have a vague idea" → /brainstorm
239
254
  ├─ "I know what to build" → /requirement → /sdd
255
+ ├─ "I need to design an API" → /api-design
256
+ ├─ "I need to design a database" → /database
240
257
  ├─ "I have a spec, need tests" → /derive
241
258
  ├─ "I'm writing tests" → /tdd or /bdd
242
259
  ├─ "I'm writing code" → (just code, or /refactor)
260
+ ├─ "I need to migrate/upgrade" → /migrate
243
261
  ├─ "I'm done coding" → /checkin → /commit
244
262
  ├─ "I need to review code" → /review
263
+ ├─ "I need a security check" → /scan → /security
264
+ ├─ "There's a production issue" → /incident
265
+ ├─ "I need to create a PR" → /pr
245
266
  ├─ "I'm preparing a release" → /changelog → /release
267
+ ├─ "I need to set up CI/CD" → /ci-cd
246
268
  ├─ "I need to understand code" → /reverse or /discover
269
+ ├─ "I want project metrics" → /metrics
247
270
  ├─ "I need a reference guide" → /guide [topic]
271
+ ├─ "I need to audit standards" → /audit
248
272
  └─ "I need a complex workflow" → /methodology
249
273
  ```
@@ -0,0 +1,116 @@
1
+ ---
2
+ name: durable
3
+ scope: partial
4
+ description: "[UDS] Guide workflow failure recovery with checkpoints, retries, and rollback"
5
+ allowed-tools: Read, Write, Grep, Glob
6
+ argument-hint: "[workflow name or failure context | 工作流名稱或失敗情境]"
7
+ ---
8
+
9
+ # Durable Execution Assistant | 持久執行助手
10
+
11
+ Guide fault-tolerant workflow design with automatic recovery, checkpoints, and retry strategies.
12
+
13
+ 引導容錯工作流程設計,包含自動恢復、檢查點與重試策略。
14
+
15
+ ## Usage | 使用方式
16
+
17
+ | Command | Purpose | 用途 |
18
+ |---------|---------|------|
19
+ | `/durable` | Start interactive failure recovery guide | 啟動互動式故障恢復引導 |
20
+ | `/durable --checkpoint` | Design checkpoint strategy | 設計檢查點策略 |
21
+ | `/durable --retry` | Configure retry policies | 配置重試策略 |
22
+ | `/durable --rollback` | Plan rollback procedures | 規劃回滾程序 |
23
+ | `/durable <workflow>` | Analyze specific workflow for durability | 分析特定工作流的持久性 |
24
+
25
+ ## Core Concepts | 核心概念
26
+
27
+ | Concept | Definition | 定義 |
28
+ |---------|-----------|------|
29
+ | **Checkpoint** | Save execution state at known-good points | 在已知正確的位置儲存執行狀態 |
30
+ | **Retry** | Automatically re-attempt failed operations | 自動重新嘗試失敗的操作 |
31
+ | **Rollback** | Revert to last known-good state on failure | 失敗時回復到上一個已知正確狀態 |
32
+ | **Idempotency** | Operations produce same result on re-execution | 操作重新執行時產生相同結果 |
33
+ | **Circuit Breaker** | Stop retries when failure rate exceeds threshold | 失敗率超過閾值時停止重試 |
34
+
35
+ ## Failure Recovery Decision Tree | 故障恢復決策樹
36
+
37
+ ```
38
+ Failure detected
39
+ ├── Is it transient? (network, timeout)
40
+ │ ├── Yes → Retry with backoff
41
+ │ └── No → Is state corrupted?
42
+ │ ├── Yes → Rollback to checkpoint
43
+ │ └── No → Is it a logic error?
44
+ │ ├── Yes → Stop, report, fix code
45
+ │ └── No → Escalate with diagnostics
46
+ ```
47
+
48
+ ## Retry Strategy Guide | 重試策略指南
49
+
50
+ | Strategy | When to Use | Config | 使用時機 |
51
+ |----------|-------------|--------|---------|
52
+ | **Immediate** | Rare glitches, fast ops | max 2 retries | 罕見故障、快速操作 |
53
+ | **Exponential Backoff** | Network/API calls | base 1s, max 30s | 網路/API 呼叫 |
54
+ | **Circuit Breaker** | Downstream service issues | threshold 50%, window 60s | 下游服務問題 |
55
+ | **Dead Letter** | Unrecoverable after retries | max 5 retries then queue | 重試後仍不可恢復 |
56
+
57
+ ## Checkpoint Granularity | 檢查點粒度
58
+
59
+ | Granularity | Use Case | 使用場景 |
60
+ |-------------|----------|---------|
61
+ | **Per-step** | Long pipelines (> 5 steps) | 長管線(> 5 步驟) |
62
+ | **Per-batch** | Bulk data processing | 批量資料處理 |
63
+ | **Per-phase** | Multi-phase workflows | 多階段工作流程 |
64
+ | **Start/End** | Short, atomic operations | 短暫的原子操作 |
65
+
66
+ ## Workflow | 工作流程
67
+
68
+ 1. **DETECT** - Identify failure type and scope
69
+ 2. **DIAGNOSE** - Determine root cause category
70
+ 3. **RECOVER** - Apply appropriate recovery strategy
71
+ 4. **VERIFY** - Confirm system state is consistent
72
+ 5. **RESUME** - Continue from last checkpoint
73
+
74
+ ---
75
+
76
+ 1. **偵測** - 識別故障類型與範圍
77
+ 2. **診斷** - 判定根本原因類別
78
+ 3. **恢復** - 套用適當的恢復策略
79
+ 4. **驗證** - 確認系統狀態一致
80
+ 5. **繼續** - 從上一個檢查點繼續
81
+
82
+ ## Usage Examples | 使用範例
83
+
84
+ ```
85
+ User: /durable deploy-pipeline
86
+ AI: Analyzing deploy-pipeline for durability...
87
+ Steps: build → test → deploy → verify
88
+ Risk: deploy step has no rollback strategy.
89
+ Recommendation: Add checkpoint after test,
90
+ configure rollback for deploy using blue-green strategy.
91
+ ```
92
+
93
+ ## Next Steps Guidance | 下一步引導
94
+
95
+ After `/durable` completes, the AI assistant should suggest:
96
+
97
+ > **持久性分析完成。建議下一步 / Durability analysis complete. Suggested next steps:**
98
+ > - 執行 `/methodology` 選擇適合的開發方法論 — Choose suitable methodology
99
+ > - 執行 `/commit` 提交持久化設計變更 — Commit durability design changes
100
+
101
+ ## Version History | 版本歷史
102
+
103
+ | Version | Date | Changes | 變更 |
104
+ |---------|------|---------|------|
105
+ | 1.0.0 | 2026-03-24 | Initial release | 初始版本 |
106
+
107
+
108
+ ## AI Agent Behavior | AI 代理行為
109
+
110
+ > 完整的 AI 行為定義請參閱對應的命令文件:[`/durable`](../commands/durable.md#ai-agent-behavior--ai-代理行為)
111
+ >
112
+ > For complete AI agent behavior definition, see the corresponding command file: [`/durable`](../commands/durable.md#ai-agent-behavior--ai-代理行為)
113
+
114
+ ## License | 授權
115
+
116
+ CC BY 4.0
@@ -69,3 +69,10 @@ After `/derive` completes, the AI assistant should suggest:
69
69
 
70
70
  - Detailed guide: [guide.md](./guide.md)
71
71
  - Core standard: [forward-derivation-standards.md](../../core/forward-derivation-standards.md)
72
+
73
+
74
+ ## AI Agent Behavior | AI 代理行為
75
+
76
+ > 完整的 AI 行為定義請參閱對應的命令文件:[`/derive`](../commands/derive.md#ai-agent-behavior--ai-代理行為)
77
+ >
78
+ > For complete AI agent behavior definition, see the corresponding command file: [`/derive`](../commands/derive.md#ai-agent-behavior--ai-代理行為)
@@ -0,0 +1,132 @@
1
+ ---
2
+ name: incident
3
+ scope: universal
4
+ description: |
5
+ Guide incident response, root cause analysis, and post-mortem documentation.
6
+ Use when: production incident, outage response, post-mortem writing, RCA.
7
+ Keywords: incident, outage, post-mortem, RCA, root cause, 事故, 故障, 根因分析.
8
+ allowed-tools: Read, Write, Grep, Glob
9
+ argument-hint: "[incident description or severity | 事故描述或嚴重程度]"
10
+ ---
11
+
12
+ # Incident Response Assistant | 事故回應助手
13
+
14
+ > **Language**: English | [繁體中文](../../locales/zh-TW/skills/incident-response-assistant/SKILL.md)
15
+
16
+ Guide structured incident response from detection through post-mortem.
17
+
18
+ 引導結構化的事故回應流程,從偵測到事後檢討。
19
+
20
+ ## Severity Classification | 嚴重程度分類
21
+
22
+ | Level | Name | Criteria | 標準 | Response Time |
23
+ |-------|------|----------|------|---------------|
24
+ | **SEV-1** | Critical 重大 | Full service outage, data loss | 全面服務中斷、資料遺失 | Immediate (< 15 min) |
25
+ | **SEV-2** | High 高 | Major feature degraded, partial outage | 主要功能降級、部分中斷 | < 30 min |
26
+ | **SEV-3** | Medium 中 | Minor feature affected, workaround exists | 次要功能受影響、有替代方案 | < 4 hours |
27
+ | **SEV-4** | Low 低 | Cosmetic issue, minimal user impact | 外觀問題、最小用戶影響 | Next business day |
28
+
29
+ ## Response Workflow | 回應工作流程
30
+
31
+ ```
32
+ DETECT ──► TRIAGE ──► MITIGATE ──► RESOLVE ──► POST-MORTEM
33
+ 偵測 分級 緩解 解決 事後檢討
34
+ ```
35
+
36
+ ### 1. Detect — Identify the Incident | 偵測事故
37
+ - Monitor alerts, user reports, error spikes
38
+ - 監控告警、使用者回報、錯誤量飆升
39
+
40
+ ### 2. Triage — Classify Severity | 分級嚴重程度
41
+ - Assign SEV level, identify Incident Commander (IC)
42
+ - 指定嚴重等級、識別事故指揮官(IC)
43
+
44
+ ### 3. Mitigate — Reduce Impact | 緩解影響
45
+ - Apply temporary fix: rollback, feature flag, traffic shift
46
+ - 套用暫時修復:回滾、功能開關、流量切換
47
+
48
+ ### 4. Resolve — Permanent Fix | 永久修復
49
+ - Root cause analysis, implement proper fix, deploy
50
+ - 根因分析、實作正確修復、部署
51
+
52
+ ### 5. Post-Mortem — Learn & Improve | 事後檢討
53
+ - Document timeline, impact, root cause, action items
54
+ - 記錄時間軸、影響範圍、根因、行動項目
55
+
56
+ ## Post-Mortem Template | 事後檢討模板
57
+
58
+ ```markdown
59
+ ## Post-Mortem: [Incident Title]
60
+ **Date**: YYYY-MM-DD | **Severity**: SEV-N | **Duration**: Xh Ym
61
+
62
+ ### Timeline
63
+ | Time | Event |
64
+ |------|-------|
65
+ | HH:MM | Alert triggered / 告警觸發 |
66
+ | HH:MM | IC assigned / 指派事故指揮官 |
67
+ | HH:MM | Mitigation applied / 套用緩解措施 |
68
+ | HH:MM | Resolved / 解決 |
69
+
70
+ ### Impact
71
+ - Users affected / 受影響用戶數: N
72
+ - Revenue impact / 營收影響: $N
73
+ - SLA breach / SLA 違反: Yes/No
74
+
75
+ ### Root Cause
76
+ [Description of the underlying cause / 根本原因描述]
77
+
78
+ ### Action Items
79
+ | Action | Owner | Due Date | Priority |
80
+ |--------|-------|----------|----------|
81
+ | [Fix] | @name | YYYY-MM-DD | P0 |
82
+ ```
83
+
84
+ ## Communication Template | 溝通模板
85
+
86
+ ```
87
+ [SEV-N] [Service Name] — [Brief Description]
88
+ Status: Investigating / Mitigating / Resolved
89
+ Impact: [Who is affected and how]
90
+ Next update: [Time]
91
+ ```
92
+
93
+ ## Usage | 使用方式
94
+
95
+ ```bash
96
+ /incident # Show full incident response guide | 顯示完整事故回應指南
97
+ /incident "API 500 errors" # Guided response for specific incident | 特定事故引導回應
98
+ /incident --post-mortem # Generate post-mortem template | 產生事後檢討模板
99
+ /incident --sev1 # SEV-1 rapid response checklist | SEV-1 快速回應清單
100
+ ```
101
+
102
+ ## Next Steps Guidance | 下一步引導
103
+
104
+ After `/incident` completes, the AI assistant should suggest:
105
+
106
+ > **事故回應指引已提供。建議下一步 / Incident response guidance provided. Suggested next steps:**
107
+ > - 提交修復 → 執行 `/commit` 建立修復提交 — Create fix commit
108
+ > - 程式碼審查 → 執行 `/review` 審查修復變更 — Review fix changes
109
+ > - 記錄學習 → 執行 `/docs` 更新文件 — Document learnings
110
+ > - 安全審查 → 執行 `/security` 檢查安全影響 — Check security impact
111
+
112
+ ## Reference | 參考
113
+
114
+ - Core standard: [deployment-standards.md](../../core/deployment-standards.md)
115
+ - Core standard: [logging.md](../../core/logging.md)
116
+
117
+ ## Version History | 版本歷史
118
+
119
+ | Version | Date | Changes | 變更說明 |
120
+ |---------|------|---------|----------|
121
+ | 1.0.0 | 2026-03-24 | Initial release | 初始版本 |
122
+
123
+
124
+ ## AI Agent Behavior | AI 代理行為
125
+
126
+ > 完整的 AI 行為定義請參閱對應的命令文件:[`/incident`](../commands/incident.md#ai-agent-behavior--ai-代理行為)
127
+ >
128
+ > For complete AI agent behavior definition, see the corresponding command file: [`/incident`](../commands/incident.md#ai-agent-behavior--ai-代理行為)
129
+
130
+ ## License | 授權
131
+
132
+ CC BY 4.0 — Documentation content
@@ -14,9 +14,24 @@ argument-hint: "[action] [argument]"
14
14
  > This feature is under active development and may change significantly in v4.0.
15
15
  > 此功能正在積極開發中,可能在 v4.0 中有重大變更。
16
16
 
17
- Manage the active development methodology for the current project with two independent systems.
17
+ Select and manage the active development methodology for the current project. This skill focuses on **choosing which methodology to use** (SDD, BDD, TDD) and tracking phase progress within the chosen methodology.
18
18
 
19
- 管理當前專案的開發方法論,支援兩個獨立系統。
19
+ 選擇並管理當前專案的開發方法論。此技能專注於**選擇使用哪種方法論**(SDD、BDD、TDD)並追蹤所選方法論內的階段進度。
20
+
21
+ > **Related**: For navigating development phases and finding the right UDS command at each stage, use `/dev-workflow` instead.
22
+ >
23
+ > **相關**:如需查詢開發階段對應的 UDS 指令,請改用 `/dev-workflow`。
24
+
25
+ ### When to Use `/methodology` vs `/dev-workflow` | 何時使用
26
+
27
+ | Scenario | `/methodology` | `/dev-workflow` |
28
+ |----------|---------------|-----------------|
29
+ | Choose SDD vs BDD vs TDD | ✅ | ❌ |
30
+ | Switch between methodologies | ✅ | ❌ |
31
+ | Track current phase progress | ✅ | ❌ |
32
+ | Find the right UDS command for a task | ❌ | ✅ |
33
+ | Get step-by-step workflow for new feature / bug fix | ❌ | ✅ |
34
+ | Navigate 8 development phases | ❌ | ✅ |
20
35
 
21
36
  **Two Independent Systems / 兩個獨立系統:**
22
37
  - **System A: SDD** - Spec-Driven Development (AI-era, spec-first)
@@ -83,3 +98,10 @@ After `/methodology` completes, the AI assistant should suggest based on the sel
83
98
  ## Reference | 參考
84
99
 
85
100
  - Detailed guide: [guide.md](./guide.md)
101
+
102
+
103
+ ## AI Agent Behavior | AI 代理行為
104
+
105
+ > 完整的 AI 行為定義請參閱對應的命令文件:[`/methodology`](../commands/methodology.md#ai-agent-behavior--ai-代理行為)
106
+ >
107
+ > For complete AI agent behavior definition, see the corresponding command file: [`/methodology`](../commands/methodology.md#ai-agent-behavior--ai-代理行為)
@@ -0,0 +1,109 @@
1
+ ---
2
+ name: metrics
3
+ scope: universal
4
+ description: "[UDS] Track development metrics, code quality indicators, and project health"
5
+ allowed-tools: Read, Grep, Glob, Bash(npm:*, git:log)
6
+ argument-hint: "[metric type or module | 指標類型或模組]"
7
+ ---
8
+
9
+ # Metrics Dashboard Assistant | 開發指標助手
10
+
11
+ Track development metrics, code quality indicators, and project health over time.
12
+
13
+ 追蹤開發指標、程式碼品質指示器,以及專案隨時間的健康狀態。
14
+
15
+ ## Usage | 使用方式
16
+
17
+ | Command | Purpose | 用途 |
18
+ |---------|---------|------|
19
+ | `/metrics` | Run full project health check | 執行完整專案健康檢查 |
20
+ | `/metrics --quality` | Code quality metrics only | 僅程式碼品質指標 |
21
+ | `/metrics --debt` | Technical debt summary | 技術債摘要 |
22
+ | `/metrics --test` | Test health metrics | 測試健康指標 |
23
+ | `/metrics src/` | Scope to specific module | 限定特定模組範圍 |
24
+
25
+ ## Metric Categories | 指標類別
26
+
27
+ | Category | Metrics | 指標說明 |
28
+ |----------|---------|----------|
29
+ | **Code Quality** | Complexity, duplication, lint warnings | 複雜度、重複率、lint 警告 |
30
+ | **Test Health** | Coverage %, pass rate, flaky count | 覆蓋率 %、通過率、不穩定測試數 |
31
+ | **Commit Quality** | Size, frequency, conventional format | 大小、頻率、格式合規 |
32
+ | **Debt Tracking** | TODO/FIXME counts, age of issues | TODO/FIXME 數量、問題存在時間 |
33
+ | **Dependency Health** | Outdated packages, vulnerability count | 過時套件、漏洞數量 |
34
+
35
+ ## Quick Health Score | 快速健康分數
36
+
37
+ The health score is a weighted composite:
38
+
39
+ 健康分數為加權組合:
40
+
41
+ | Factor | Weight | Ideal | 理想值 |
42
+ |--------|--------|-------|--------|
43
+ | Test coverage | 30% | >= 80% | >= 80% |
44
+ | Lint pass rate | 20% | 100% | 100% |
45
+ | TODO/FIXME density | 15% | < 1 per 1K lines | < 每千行 1 個 |
46
+ | Build success | 20% | 100% | 100% |
47
+ | Dependency freshness | 15% | < 3 months | < 3 個月 |
48
+
49
+ **Score = sum(factor_score * weight)**
50
+
51
+ ## Workflow | 工作流程
52
+
53
+ 1. **COLLECT** - Gather raw metrics from tools and git history
54
+ 2. **ANALYZE** - Compare against thresholds and historical trends
55
+ 3. **REPORT** - Generate summary with actionable highlights
56
+ 4. **TREND** - Show direction (improving / declining / stable)
57
+
58
+ ---
59
+
60
+ 1. **收集** - 從工具與 git 歷史收集原始指標
61
+ 2. **分析** - 與閾值及歷史趨勢比較
62
+ 3. **報告** - 產生含可行動重點的摘要
63
+ 4. **趨勢** - 顯示方向(改善 / 衰退 / 穩定)
64
+
65
+ ## Usage Examples | 使用範例
66
+
67
+ ```
68
+ User: /metrics
69
+ AI: Analyzing project health...
70
+ Code Quality: B+ (complexity avg 8.2, 0 lint errors)
71
+ Test Health: A (coverage 87%, 0 flaky tests)
72
+ Debt Tracking: C (42 TODOs, 3 FIXMEs)
73
+ Overall Score: 78/100 (Good)
74
+ ```
75
+
76
+ ```
77
+ User: /metrics --debt
78
+ AI: Technical Debt Summary:
79
+ TODO: 42 (12 in src/legacy/, 8 in src/utils/)
80
+ FIXME: 3 (all in src/parser/)
81
+ Oldest: 6 months (src/legacy/auth.js:45)
82
+ Trend: +5 since last month (increasing)
83
+ ```
84
+
85
+ ## Next Steps Guidance | 下一步引導
86
+
87
+ After `/metrics` completes, the AI assistant should suggest:
88
+
89
+ > **指標分析完成。建議下一步 / Metrics analysis complete. Suggested next steps:**
90
+ > - 執行 `/refactor` 處理高複雜度模組 — Address high-complexity modules
91
+ > - 執行 `/coverage` 改善低覆蓋率區域 — Improve low-coverage areas
92
+ > - 執行 `/audit` 檢視安全與依賴問題 — Review security & dependency issues
93
+
94
+ ## Version History | 版本歷史
95
+
96
+ | Version | Date | Changes | 變更 |
97
+ |---------|------|---------|------|
98
+ | 1.0.0 | 2026-03-24 | Initial release | 初始版本 |
99
+
100
+
101
+ ## AI Agent Behavior | AI 代理行為
102
+
103
+ > 完整的 AI 行為定義請參閱對應的命令文件:[`/metrics`](../commands/metrics.md#ai-agent-behavior--ai-代理行為)
104
+ >
105
+ > For complete AI agent behavior definition, see the corresponding command file: [`/metrics`](../commands/metrics.md#ai-agent-behavior--ai-代理行為)
106
+
107
+ ## License | 授權
108
+
109
+ CC BY 4.0