@su-record/vibe 2.16.3 → 3.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 (353) hide show
  1. package/.env.example +15 -0
  2. package/CLAUDE.md +8 -8
  3. package/README.en.md +46 -29
  4. package/README.md +41 -24
  5. package/agents/acceptance-tester.md +56 -0
  6. package/agents/architect.md +25 -67
  7. package/agents/build-error-resolver.md +28 -97
  8. package/agents/code-reviewer.md +89 -0
  9. package/agents/diagrammer.md +34 -165
  10. package/agents/documenter.md +43 -0
  11. package/agents/e2e-tester.md +46 -277
  12. package/agents/event/event-ops.md +54 -77
  13. package/agents/event/event-planner.md +63 -0
  14. package/agents/figma/figma-engineer.md +76 -0
  15. package/agents/implementer.md +26 -41
  16. package/agents/security-reviewer.md +56 -0
  17. package/agents/tester.md +37 -33
  18. package/agents/ui/design-reviewer.md +62 -0
  19. package/agents/ui/design-system-gen.md +63 -0
  20. package/dist/__tests__/agent-model-sync.test.d.ts +2 -0
  21. package/dist/__tests__/agent-model-sync.test.d.ts.map +1 -0
  22. package/dist/__tests__/agent-model-sync.test.js +71 -0
  23. package/dist/__tests__/agent-model-sync.test.js.map +1 -0
  24. package/dist/cli/auth.d.ts.map +1 -1
  25. package/dist/cli/auth.js +8 -1
  26. package/dist/cli/auth.js.map +1 -1
  27. package/dist/cli/commands/index.d.ts +1 -0
  28. package/dist/cli/commands/index.d.ts.map +1 -1
  29. package/dist/cli/commands/index.js +1 -0
  30. package/dist/cli/commands/index.js.map +1 -1
  31. package/dist/cli/commands/info.d.ts.map +1 -1
  32. package/dist/cli/commands/info.js +2 -0
  33. package/dist/cli/commands/info.js.map +1 -1
  34. package/dist/cli/commands/llm.d.ts +11 -0
  35. package/dist/cli/commands/llm.d.ts.map +1 -0
  36. package/dist/cli/commands/llm.js +62 -0
  37. package/dist/cli/commands/llm.js.map +1 -0
  38. package/dist/cli/commands/remove.d.ts.map +1 -1
  39. package/dist/cli/commands/remove.js +8 -10
  40. package/dist/cli/commands/remove.js.map +1 -1
  41. package/dist/cli/commands/setup.d.ts.map +1 -1
  42. package/dist/cli/commands/setup.js +35 -1
  43. package/dist/cli/commands/setup.js.map +1 -1
  44. package/dist/cli/index.d.ts +0 -4
  45. package/dist/cli/index.d.ts.map +1 -1
  46. package/dist/cli/index.js +59 -6
  47. package/dist/cli/index.js.map +1 -1
  48. package/dist/cli/llm/config.d.ts.map +1 -1
  49. package/dist/cli/llm/config.js +7 -0
  50. package/dist/cli/llm/config.js.map +1 -1
  51. package/dist/cli/llm/index.d.ts +1 -0
  52. package/dist/cli/llm/index.d.ts.map +1 -1
  53. package/dist/cli/llm/index.js +1 -0
  54. package/dist/cli/llm/index.js.map +1 -1
  55. package/dist/cli/llm/model-refresh.d.ts +29 -0
  56. package/dist/cli/llm/model-refresh.d.ts.map +1 -0
  57. package/dist/cli/llm/model-refresh.js +139 -0
  58. package/dist/cli/llm/model-refresh.js.map +1 -0
  59. package/dist/cli/llm/zai-commands.d.ts +15 -0
  60. package/dist/cli/llm/zai-commands.d.ts.map +1 -0
  61. package/dist/cli/llm/zai-commands.js +64 -0
  62. package/dist/cli/llm/zai-commands.js.map +1 -0
  63. package/dist/cli/postinstall/claude-agents.d.ts.map +1 -1
  64. package/dist/cli/postinstall/claude-agents.js +16 -77
  65. package/dist/cli/postinstall/claude-agents.js.map +1 -1
  66. package/dist/cli/postinstall/constants.d.ts.map +1 -1
  67. package/dist/cli/postinstall/constants.js +81 -296
  68. package/dist/cli/postinstall/constants.js.map +1 -1
  69. package/dist/cli/postinstall/cursor-agents.d.ts +5 -0
  70. package/dist/cli/postinstall/cursor-agents.d.ts.map +1 -1
  71. package/dist/cli/postinstall/cursor-agents.js +26 -68
  72. package/dist/cli/postinstall/cursor-agents.js.map +1 -1
  73. package/dist/cli/postinstall/cursor-skills.d.ts.map +1 -1
  74. package/dist/cli/postinstall/cursor-skills.js +26 -30
  75. package/dist/cli/postinstall/cursor-skills.js.map +1 -1
  76. package/dist/cli/postinstall/main.d.ts.map +1 -1
  77. package/dist/cli/postinstall/main.js +0 -2
  78. package/dist/cli/postinstall/main.js.map +1 -1
  79. package/dist/cli/setup/Provisioner.d.ts.map +1 -1
  80. package/dist/cli/setup/Provisioner.js +19 -21
  81. package/dist/cli/setup/Provisioner.js.map +1 -1
  82. package/dist/cli/types.d.ts +15 -0
  83. package/dist/cli/types.d.ts.map +1 -1
  84. package/dist/cli/utils.d.ts +4 -1
  85. package/dist/cli/utils.d.ts.map +1 -1
  86. package/dist/cli/utils.js +4 -1
  87. package/dist/cli/utils.js.map +1 -1
  88. package/dist/infra/lib/FrameworkDetector.js +4 -4
  89. package/dist/infra/lib/FrameworkDetector.js.map +1 -1
  90. package/dist/infra/lib/OrchestrateWorkflow.js +2 -2
  91. package/dist/infra/lib/OrchestrateWorkflow.js.map +1 -1
  92. package/dist/infra/lib/browser/launch.js +1 -1
  93. package/dist/infra/lib/browser/launch.js.map +1 -1
  94. package/dist/infra/lib/browser/types.d.ts +1 -1
  95. package/dist/infra/lib/browser/types.js +1 -1
  96. package/dist/infra/lib/config/GlobalConfigManager.d.ts +2 -0
  97. package/dist/infra/lib/config/GlobalConfigManager.d.ts.map +1 -1
  98. package/dist/infra/lib/config/GlobalConfigManager.js +6 -0
  99. package/dist/infra/lib/config/GlobalConfigManager.js.map +1 -1
  100. package/dist/infra/lib/constants.d.ts +1 -1
  101. package/dist/infra/lib/constants.d.ts.map +1 -1
  102. package/dist/infra/lib/constants.js +4 -5
  103. package/dist/infra/lib/constants.js.map +1 -1
  104. package/dist/infra/lib/evolution/__tests__/integration.test.js +7 -7
  105. package/dist/infra/lib/evolution/__tests__/integration.test.js.map +1 -1
  106. package/dist/infra/lib/llm-availability.d.ts +4 -0
  107. package/dist/infra/lib/llm-availability.d.ts.map +1 -1
  108. package/dist/infra/lib/llm-availability.js +9 -1
  109. package/dist/infra/lib/llm-availability.js.map +1 -1
  110. package/dist/infra/lib/memory/index.d.ts +0 -2
  111. package/dist/infra/lib/memory/index.d.ts.map +1 -1
  112. package/dist/infra/lib/memory/index.js +0 -2
  113. package/dist/infra/lib/memory/index.js.map +1 -1
  114. package/dist/infra/lib/telemetry/SkillTelemetry.test.js +1 -1
  115. package/dist/infra/lib/telemetry/SkillTelemetry.test.js.map +1 -1
  116. package/dist/infra/lib/zai/client.d.ts +30 -0
  117. package/dist/infra/lib/zai/client.d.ts.map +1 -0
  118. package/dist/infra/lib/zai/client.js +124 -0
  119. package/dist/infra/lib/zai/client.js.map +1 -0
  120. package/dist/infra/lib/zai/index.d.ts +11 -0
  121. package/dist/infra/lib/zai/index.d.ts.map +1 -0
  122. package/dist/infra/lib/zai/index.js +10 -0
  123. package/dist/infra/lib/zai/index.js.map +1 -0
  124. package/dist/infra/lib/zai/orchestration.d.ts +15 -0
  125. package/dist/infra/lib/zai/orchestration.d.ts.map +1 -0
  126. package/dist/infra/lib/zai/orchestration.js +54 -0
  127. package/dist/infra/lib/zai/orchestration.js.map +1 -0
  128. package/dist/infra/lib/zai/types.d.ts +40 -0
  129. package/dist/infra/lib/zai/types.d.ts.map +1 -0
  130. package/dist/infra/lib/zai/types.js +5 -0
  131. package/dist/infra/lib/zai/types.js.map +1 -0
  132. package/dist/infra/orchestrator/SmartRouter.d.ts.map +1 -1
  133. package/dist/infra/orchestrator/SmartRouter.js +16 -34
  134. package/dist/infra/orchestrator/SmartRouter.js.map +1 -1
  135. package/dist/infra/orchestrator/index.d.ts +1 -0
  136. package/dist/infra/orchestrator/index.d.ts.map +1 -1
  137. package/dist/infra/orchestrator/index.js +11 -9
  138. package/dist/infra/orchestrator/index.js.map +1 -1
  139. package/dist/infra/orchestrator/types.d.ts +32 -9
  140. package/dist/infra/orchestrator/types.d.ts.map +1 -1
  141. package/dist/infra/orchestrator/types.js +68 -37
  142. package/dist/infra/orchestrator/types.js.map +1 -1
  143. package/dist/infra/orchestrator/types.test.d.ts +2 -0
  144. package/dist/infra/orchestrator/types.test.d.ts.map +1 -0
  145. package/dist/infra/orchestrator/types.test.js +57 -0
  146. package/dist/infra/orchestrator/types.test.js.map +1 -0
  147. package/dist/tools/index.d.ts +0 -4
  148. package/dist/tools/index.d.ts.map +1 -1
  149. package/dist/tools/index.js +0 -4
  150. package/dist/tools/index.js.map +1 -1
  151. package/dist/tools/memory/autoSaveContext.d.ts +0 -1
  152. package/dist/tools/memory/autoSaveContext.d.ts.map +1 -1
  153. package/dist/tools/memory/autoSaveContext.js +13 -27
  154. package/dist/tools/memory/autoSaveContext.js.map +1 -1
  155. package/hooks/scripts/__tests__/code-check-detectors.test.js +2 -2
  156. package/hooks/scripts/__tests__/run-ledger.test.js +1 -1
  157. package/hooks/scripts/__tests__/scope-from-spec.test.js +12 -12
  158. package/hooks/scripts/__tests__/step-counter.test.js +1 -1
  159. package/hooks/scripts/code-check.js +16 -203
  160. package/hooks/scripts/context-save.js +0 -11
  161. package/hooks/scripts/lib/scope-from-spec.js +9 -6
  162. package/hooks/scripts/llm-orchestrate.js +49 -0
  163. package/hooks/scripts/post-edit-dispatcher.js +1 -1
  164. package/hooks/scripts/prompt-dispatcher.js +7 -18
  165. package/hooks/scripts/session-start.js +25 -35
  166. package/package.json +4 -4
  167. package/skills/agents-md/SKILL.md +62 -15
  168. package/skills/arch-guard/SKILL.md +1 -1
  169. package/skills/brand-assets/SKILL.md +2 -2
  170. package/skills/capability-loop/SKILL.md +1 -1
  171. package/skills/chub-usage/SKILL.md +1 -1
  172. package/skills/commerce-patterns/SKILL.md +2 -2
  173. package/skills/commit-push-pr/SKILL.md +0 -1
  174. package/skills/context7-usage/SKILL.md +1 -1
  175. package/skills/create-prd/agents/edge-case-finder.md +4 -4
  176. package/skills/create-prd/agents/prioritizer.md +4 -4
  177. package/skills/create-prd/agents/requirements-writer.md +3 -3
  178. package/skills/create-prd/agents/researcher.md +3 -3
  179. package/skills/create-prd/agents/reviewer.md +3 -3
  180. package/skills/create-prd/orchestrator.md +2 -0
  181. package/skills/design-refine/SKILL.md +140 -0
  182. package/skills/{design-polish → design-refine}/templates/polish-report.md +1 -1
  183. package/skills/{design-normalize → design-refine}/templates/token-audit.md +3 -3
  184. package/skills/design-review/SKILL.md +143 -0
  185. package/skills/{design-audit → design-review}/agents/a11y-auditor.md +1 -1
  186. package/skills/{design-audit → design-review}/agents/performance-auditor.md +1 -1
  187. package/skills/{design-audit → design-review}/agents/responsive-auditor.md +1 -1
  188. package/skills/{design-audit → design-review}/agents/slop-detector.md +1 -1
  189. package/skills/{design-audit → design-review}/frameworks/core-web-vitals.md +1 -1
  190. package/skills/{design-audit → design-review}/frameworks/wcag-checklist.md +1 -1
  191. package/skills/{design-audit → design-review}/orchestrator.md +5 -3
  192. package/skills/{design-critique → design-review}/templates/critique-report.md +3 -3
  193. package/skills/{design-audit → design-review}/templates/report.md +3 -3
  194. package/skills/design-teach/SKILL.md +11 -11
  195. package/skills/docs/SKILL.md +14 -16
  196. package/skills/e2e-commerce/SKILL.md +1 -1
  197. package/skills/event-comms/SKILL.md +1 -1
  198. package/skills/event-ops/SKILL.md +2 -2
  199. package/skills/event-planning/SKILL.md +1 -1
  200. package/skills/exec-plan/SKILL.md +2 -2
  201. package/skills/exec-plan/orchestrator.md +2 -0
  202. package/skills/figma/SKILL.md +240 -148
  203. package/skills/figma/rubrics/css-mapping.md +125 -0
  204. package/skills/git-worktree/SKILL.md +1 -1
  205. package/skills/handoff/SKILL.md +1 -1
  206. package/skills/parallel-research/SKILL.md +14 -28
  207. package/skills/parallel-research/orchestrator.md +2 -0
  208. package/skills/priority-todos/SKILL.md +1 -1
  209. package/skills/regress/SKILL.md +11 -0
  210. package/skills/restraint/SKILL.md +72 -0
  211. package/skills/seo-checklist/SKILL.md +2 -2
  212. package/skills/spec/SKILL.md +65 -836
  213. package/skills/test/SKILL.md +3 -3
  214. package/skills/tool-fallback/SKILL.md +2 -2
  215. package/skills/vercel-react-best-practices/SKILL.md +1 -1
  216. package/skills/vibe/SKILL.md +20 -35
  217. package/skills/vibe.analyze/SKILL.md +7 -9
  218. package/skills/vibe.docs/SKILL.md +1 -1
  219. package/skills/vibe.event/SKILL.md +27 -27
  220. package/skills/vibe.figma/SKILL.md +14 -18
  221. package/skills/vibe.harness/SKILL.md +5 -5
  222. package/skills/vibe.llm/SKILL.md +50 -0
  223. package/skills/vibe.reason/SKILL.md +0 -2
  224. package/skills/vibe.review/SKILL.md +45 -49
  225. package/skills/vibe.run/SKILL.md +2 -5
  226. package/skills/vibe.run/references/parallel-agents.md +33 -98
  227. package/skills/vibe.spec/SKILL.md +38 -535
  228. package/skills/vibe.utils/SKILL.md +3 -3
  229. package/skills/vibe.verify/SKILL.md +70 -542
  230. package/skills/video-production/SKILL.md +1 -1
  231. package/vibe/rules/orchestrator-contract.md +57 -0
  232. package/vibe/rules/quality/performance.md +1 -1
  233. package/vibe/templates/claudemd-template.md +1 -1
  234. package/vibe/templates/spec-template.md +35 -185
  235. package/agents/architect-low.md +0 -41
  236. package/agents/architect-medium.md +0 -59
  237. package/agents/compounder.md +0 -261
  238. package/agents/docs/api-documenter.md +0 -99
  239. package/agents/docs/changelog-writer.md +0 -93
  240. package/agents/event/event-comms.md +0 -78
  241. package/agents/event/event-content.md +0 -68
  242. package/agents/event/event-image.md +0 -95
  243. package/agents/event/event-scheduler.md +0 -69
  244. package/agents/event/event-speaker.md +0 -86
  245. package/agents/explorer-low.md +0 -42
  246. package/agents/explorer-medium.md +0 -59
  247. package/agents/explorer.md +0 -48
  248. package/agents/figma/figma-analyst.md +0 -52
  249. package/agents/figma/figma-architect.md +0 -112
  250. package/agents/figma/figma-auditor.md +0 -82
  251. package/agents/figma/figma-builder.md +0 -100
  252. package/agents/implementer-low.md +0 -43
  253. package/agents/implementer-medium.md +0 -52
  254. package/agents/junior-mentor.md +0 -141
  255. package/agents/planning/requirements-analyst.md +0 -84
  256. package/agents/planning/ux-advisor.md +0 -83
  257. package/agents/qa/acceptance-tester.md +0 -86
  258. package/agents/qa/edge-case-finder.md +0 -93
  259. package/agents/qa/qa-coordinator.md +0 -131
  260. package/agents/refactor-cleaner.md +0 -143
  261. package/agents/research/best-practices.md +0 -199
  262. package/agents/research/codebase-patterns.md +0 -157
  263. package/agents/research/framework-docs.md +0 -188
  264. package/agents/research/security-advisory.md +0 -213
  265. package/agents/review/architecture-reviewer.md +0 -107
  266. package/agents/review/complexity-reviewer.md +0 -116
  267. package/agents/review/data-integrity-reviewer.md +0 -88
  268. package/agents/review/git-history-reviewer.md +0 -103
  269. package/agents/review/performance-reviewer.md +0 -86
  270. package/agents/review/python-reviewer.md +0 -150
  271. package/agents/review/rails-reviewer.md +0 -139
  272. package/agents/review/react-reviewer.md +0 -144
  273. package/agents/review/security-reviewer.md +0 -80
  274. package/agents/review/simplicity-reviewer.md +0 -140
  275. package/agents/review/test-coverage-reviewer.md +0 -116
  276. package/agents/review/typescript-reviewer.md +0 -127
  277. package/agents/searcher.md +0 -54
  278. package/agents/simplifier.md +0 -120
  279. package/agents/teams/debug-team.md +0 -70
  280. package/agents/teams/dev-team.md +0 -88
  281. package/agents/teams/docs-team.md +0 -80
  282. package/agents/teams/figma-team.md +0 -85
  283. package/agents/teams/fullstack-team.md +0 -83
  284. package/agents/teams/lite-team.md +0 -69
  285. package/agents/teams/migration-team.md +0 -78
  286. package/agents/teams/refactor-team.md +0 -94
  287. package/agents/teams/research-team.md +0 -86
  288. package/agents/teams/review-debate-team.md +0 -125
  289. package/agents/teams/security-team.md +0 -81
  290. package/agents/ui/ui-a11y-auditor.md +0 -93
  291. package/agents/ui/ui-antipattern-detector.md +0 -102
  292. package/agents/ui/ui-dataviz-advisor.md +0 -69
  293. package/agents/ui/ui-design-system-gen.md +0 -57
  294. package/agents/ui/ui-industry-analyzer.md +0 -49
  295. package/agents/ui/ui-layout-architect.md +0 -65
  296. package/agents/ui/ui-stack-implementer.md +0 -68
  297. package/agents/ui/ux-compliance-reviewer.md +0 -81
  298. package/agents/ui-previewer.md +0 -258
  299. package/hooks/scripts/__tests__/keyword-detector.test.js +0 -242
  300. package/hooks/scripts/keyword-detector.js +0 -226
  301. package/skills/characterization-test/SKILL.md +0 -209
  302. package/skills/characterization-test/agents/behavior-capturer.md +0 -50
  303. package/skills/characterization-test/agents/coverage-checker.md +0 -54
  304. package/skills/characterization-test/agents/reporter.md +0 -50
  305. package/skills/characterization-test/agents/test-writer.md +0 -49
  306. package/skills/characterization-test/rubrics/coverage-criteria.md +0 -53
  307. package/skills/characterization-test/templates/test-template.ts +0 -101
  308. package/skills/claude-md-guide/SKILL.md +0 -353
  309. package/skills/claude-md-guide/rubrics/anti-patterns.md +0 -88
  310. package/skills/design-audit/SKILL.md +0 -154
  311. package/skills/design-critique/SKILL.md +0 -140
  312. package/skills/design-distill/SKILL.md +0 -131
  313. package/skills/design-normalize/SKILL.md +0 -135
  314. package/skills/design-polish/SKILL.md +0 -132
  315. package/skills/figma-convert/SKILL.md +0 -236
  316. package/skills/figma-extract/SKILL.md +0 -242
  317. package/skills/interview/SKILL.md +0 -358
  318. package/skills/interview/checklists/api.md +0 -101
  319. package/skills/interview/checklists/feature.md +0 -88
  320. package/skills/interview/checklists/library.md +0 -95
  321. package/skills/interview/checklists/mobile.md +0 -89
  322. package/skills/interview/checklists/webapp.md +0 -97
  323. package/skills/interview/checklists/website.md +0 -99
  324. package/skills/plan/SKILL.md +0 -254
  325. package/skills/rob-pike/SKILL.md +0 -66
  326. package/skills/spec/references/askuser-examples.md +0 -57
  327. package/skills/spec/references/example-session.md +0 -87
  328. package/skills/spec/references/templates.md +0 -194
  329. package/skills/spec-review/SKILL.md +0 -725
  330. package/skills/systematic-debugging/SKILL.md +0 -142
  331. package/skills/techdebt/SKILL.md +0 -126
  332. package/skills/techdebt/agents/analyzer.md +0 -50
  333. package/skills/techdebt/agents/fixer.md +0 -41
  334. package/skills/techdebt/agents/reviewer.md +0 -47
  335. package/skills/techdebt/agents/scanner.md +0 -44
  336. package/skills/techdebt/orchestrator.md +0 -70
  337. package/skills/techdebt/rubrics/severity.md +0 -51
  338. package/skills/techdebt/scripts/scan.js +0 -90
  339. package/skills/techdebt/templates/report.md +0 -86
  340. package/skills/typescript-advanced-types/SKILL.md +0 -68
  341. package/skills/typescript-advanced-types/rubrics/type-patterns.md +0 -109
  342. package/skills/yagni-ladder/SKILL.md +0 -90
  343. /package/skills/{claude-md-guide → agents-md}/templates/claude-md.md +0 -0
  344. /package/skills/{design-polish → design-refine}/rubrics/polish-checklist.md +0 -0
  345. /package/skills/{design-normalize → design-refine}/rubrics/token-naming.md +0 -0
  346. /package/skills/{design-distill → design-refine}/templates/design-system.md +0 -0
  347. /package/skills/{design-audit → design-review}/agents/scorer.md +0 -0
  348. /package/skills/{design-audit → design-review}/rubrics/ai-slop-patterns.md +0 -0
  349. /package/skills/{design-audit → design-review}/rubrics/scoring.md +0 -0
  350. /package/skills/{design-critique → design-review}/rubrics/ux-heuristics.md +0 -0
  351. /package/skills/{figma-convert → figma}/rubrics/conversion-rules.md +0 -0
  352. /package/skills/{figma-extract → figma}/rubrics/image-rules.md +0 -0
  353. /package/skills/{figma-convert → figma}/templates/component.md +0 -0
@@ -1,887 +1,116 @@
1
1
  ---
2
2
  name: spec
3
- description: PTCF 구조 SPEC 문서 작성 parallel research (GPT/Antigravity/Claude agents), ambiguity scan, 100-point quality gate. plan 파일 입력 → .vibe/specs/{feature}.md + .vibe/features/{feature}.feature 생성.
4
- when_to_use: vibe.spec orchestrator의 Phase 3에서 호출. 직접 호출 금지 — /vibe.spec 사용.
3
+ description: 단일 패스 SPEC 작성 본체자연어 요구사항(+첨부) 필요할 때만 인라인 명확화 질문 → .vibe/specs/{feature}.md + .vibe/features/{feature}.feature 를 한 번에 생성 → 1회 셀프 리뷰 → SPEC 승인(유일한 의무 게이트).
4
+ when_to_use: /vibe.spec 진입점 또는 /vibe 파이프라인의 spec 단계에서 호출. 직접 호출 금지 — /vibe.spec 사용.
5
5
  user-invocable: false
6
6
  tier: core
7
- chain-next: [spec-review]
8
7
  ---
9
8
 
10
- # vibe.spec — Specification Agent
9
+ # spec — Single-Pass SPEC
11
10
 
12
- Create a SPEC document (Specification Agent).
11
+ 자연어 요구사항 하나를 받아 **한 번의 패스로** 실행 가능한 SPEC 만든다. 별도의 interview → plan → review 단계는 없다 — 질문이 필요하면 이 패스 안에서 인라인으로 묻고, 리뷰는 셀프 리뷰 1회로 끝낸다. 완성된 SPEC의 승인이 loop-contract 가 정의하는 **유일한 의무적 사람 개입 지점**이다.
13
12
 
14
- ## Usage
13
+ > 루프 시맨틱 SSOT: `vibe/rules/loop-contract.md`. SPEC = ANCHOR 아티팩트, Done Criteria = JUDGE 게이트.
15
14
 
16
- ```
17
- /vibe.spec "feature-name" # Conversation mode (requirements gathering)
18
- /vibe.spec "feature-name" ultrawork # Auto: SPEC → Review → Implementation
19
- /vibe.spec "docs/login-prd.md" # File path input (auto-detected)
20
- /vibe.spec + 📎 file attachment # Use attached file
21
- ```
22
-
23
- ### ultrawork Mode
24
-
25
- When `ultrawork` (or `ulw`) is included, automatically chains:
26
-
27
- ```
28
- /vibe.spec "feature" ultrawork
29
-
30
- [1] SPEC Creation (this command)
31
-
32
- [2] Auto: Load skill `spec-review` (chain-next from this skill)
33
-
34
- [3] Auto: /vibe.run "{feature}" ultrawork
35
- ```
36
-
37
- **No manual intervention between steps.**
38
-
39
- > **⏱️ Timer**: Call `getCurrentTime` tool at the START. Record the result as `{start_time}`.
40
-
41
- ## Input Mode Detection (Auto-detect)
42
-
43
- **Input priority:**
44
-
45
- ```
46
- 1. Attachment exists? → Use attached file
47
- 2. Argument is file path? (existence check) → Read file
48
- 3. Otherwise → Conversation mode (start with feature name)
49
- ```
50
-
51
- | Input | Result |
52
- |-------|--------|
53
- | 📎 Attached file | → Analyze attached file |
54
- | File path (exists) | → Read file (Read tool) |
55
- | Feature name | → Start conversation mode |
56
-
57
- **All supported files:**
58
- - Text: `.md`, `.txt`, `.rst`, `.html`, `.json`, `.yaml`, etc.
59
- - Documents: `.pdf` (page-by-page analysis)
60
- - Images: `.png`, `.jpg`, `.jpeg`, `.gif`, `.webp`, `.svg`, etc.
61
- - Notebooks: `.ipynb` (Jupyter)
62
- - **All formats Claude can read**
63
-
64
- **File input mode flow:**
65
-
66
- ```
67
- /vibe.spec "docs/login-prd.md"
68
-
69
- 📄 File loaded: docs/login-prd.md (2.3KB)
70
-
71
- 📋 Parsed requirements:
72
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
73
- Feature: Login
74
- - Email/password login
75
- - Social login (Google, Apple)
76
- - Password recovery
77
- - Auto login persistence
78
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
79
-
80
- ❓ Additional confirmation needed:
81
- 1. Session expiration time? (default: 24 hours)
82
- 2. Allow concurrent login?
83
- 3. Confirm tech stack? (current: React + Supabase)
84
-
85
- User: 1 hour, disallow, confirm
86
-
87
- ✅ Requirements confirmed → Run research → Generate SPEC → Review
88
- ```
89
-
90
- **Supported file formats:**
91
-
92
- | Format | Extension | Purpose |
93
- |--------|-----------|---------|
94
- | Markdown | `.md` | PRD, planning docs, README |
95
- | Text | `.txt` | Requirements list |
96
- | PDF | `.pdf` | Planning docs, design documents |
97
- | Image | `.png`, `.jpg`, `.jpeg`, `.webp` | Wireframes, UI design, screenshots |
98
-
99
- **Image input analysis:**
15
+ ## Input
100
16
 
101
- When image files (`.png`, `.jpg`, `.jpeg`, `.webp`) are provided as input, analyze them using the best available method:
102
-
103
- - **Antigravity Enabled**: `llm-orchestrate.js antigravity analyze-image` (Antigravity Flash - best image recognition)
104
- - **Antigravity Disabled**: Claude Opus Read tool (built-in multimodal, existing behavior)
105
-
106
- **Antigravity enabled - analyze via llm-orchestrate.js:**
107
-
108
- ```bash
109
- # [LLM_SCRIPT] = {{VIBE_PATH}}/hooks/scripts/llm-orchestrate.js
110
- node "[LLM_SCRIPT]" antigravity analyze-image "./designs/login-wireframe.png" "Analyze this UI design image. Identify all UI elements, layout structure, colors, typography, and component hierarchy. Output a structured breakdown."
111
- ```
112
-
113
- Parse the JSON result: `{ success: true, analysis: "..." }` → use `analysis` field content.
114
-
115
- If `success: false`, fall back to Claude Read tool.
116
-
117
- **Antigravity disabled - analyze via Claude Read tool:**
118
-
119
- Use the Read tool directly on the image file. Claude can read images natively.
120
-
121
- **Image input example:**
122
- ```
123
- /vibe.spec "designs/login-wireframe.png"
124
-
125
- 🖼️ Image analysis: designs/login-wireframe.png
126
- (via Antigravity Flash / Claude Opus)
127
-
128
- 📋 Detected UI elements:
129
- - Email input field
130
- - Password input field
131
- - "Login" button
132
- - "Forgot password" link
133
- - Social login buttons (Google, Apple)
134
-
135
- ❓ Confirmation needed:
136
- 1. Feature name? (e.g., "login")
137
- 2. Additional requirements?
138
-
139
- → Generate SPEC
140
- ```
141
-
142
- ## Rules Reference
143
-
144
- **Must follow `~/.claude/vibe/rules/` (global):**
145
- - `core/development-philosophy.md` - Surgical precision, simplicity
146
- - `core/quick-start.md` - Korean first, DRY, SRP
147
- - `core/communication-guide.md` - Communication principles
148
-
149
- ## Description
150
-
151
- Collect requirements through conversation with the user and create an **AI-executable PTCF structured SPEC document**.
152
-
153
- > **PTCF**: Persona, Task, Context, Format - Google Antigravity prompt optimization framework
154
-
155
- ## External LLM Integration (GPT/Antigravity)
156
-
157
- When GPT/Antigravity are enabled, they are automatically utilized during SPEC creation:
158
-
159
- ```
160
- /vibe.spec "feature"
161
-
162
- [Claude] Draft SPEC
163
-
164
- [Parallel Research] GPT + Antigravity + Claude agents (8 parallel)
165
-
166
- [SPEC Review] GPT + Antigravity parallel review
167
-
168
- [Claude] Finalize SPEC
169
- ```
170
-
171
- **Setup:**
172
- ```bash
173
- vibe gpt key <key> # Enable GPT
174
- vibe antigravity key <key> # Enable Antigravity
175
- vibe status # Check current settings
176
- ```
17
+ | 입력 | 처리 |
18
+ |---|---|
19
+ | 자연어 요구사항 | 그대로 SPEC 패스의 입력 |
20
+ | 📎 첨부 (md/txt/pdf/이미지 등) | Read 도구로 분석 요구사항에 병합 |
21
+ | 파일 경로 인자 (PRD 등) | 존재 확인 후 Read — 첨부와 동일 취급 |
22
+ | **레거시 아티팩트** `.vibe/interviews/{feature}.md`, `.vibe/plans/{feature}.md` | 존재하면 **입력 컨텍스트로만** 읽는다. 절대 요구하거나 재생성하지 않는다 — 없어도 정상 경로 |
177
23
 
178
24
  ## Process
179
25
 
180
- ### 0. Git Branch Setup (MANDATORY - Execute First!)
181
-
182
- > ⚠️ **CRITICAL: You MUST execute this step FIRST before anything else!**
183
- > This is NOT optional documentation - you must RUN these git commands.
184
-
185
- **Step 0 is BLOCKING - do not proceed to Step 1 until branch is ready.**
186
-
187
- **Execute these commands using Bash tool:**
188
-
189
- ```bash
190
- # 1. Check current branch
191
- git branch --show-current
192
- ```
193
-
194
- **Then based on result:**
195
-
196
- | Current Branch | Action |
197
- |----------------|--------|
198
- | `main` or `master` | **MUST** create feature branch: `git checkout -b feature/{feature-name}` |
199
- | `feature/*` | Ask user: "Continue on this branch or create new?" |
200
- | Other | Ask user to confirm |
201
-
202
- **Example execution:**
203
-
204
- ```
205
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
206
- 🌿 GIT BRANCH SETUP
207
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
208
-
209
- Current branch: main
210
-
211
- Creating feature branch...
212
- $ git checkout -b feature/login-page
213
-
214
- ✅ Switched to new branch: feature/login-page
215
-
216
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
217
- ```
218
-
219
- **Branch naming rules:**
220
- - Convert to lowercase: `Login Page` → `login-page`
221
- - Replace spaces with hyphens
222
- - Prefix with `feature/`
223
- - Example: `feature/passkey-auth`, `feature/dark-mode`
224
-
225
- **`.last-feature` pointer update** (immediately after Git branch setup):
226
-
227
- ```
228
- Write ".vibe/.last-feature" ← feature-name (single line)
229
- Execute at the point when the feature name is finalized.
230
- No-op if the value is already the same.
231
- ```
232
-
233
- ### 1. Project Analysis
234
-
235
- **Existing project** (`vibe init`):
236
- - Reference `CLAUDE.md` file (tech stack)
237
- - **Delegate codebase analysis to explorer agent** — do NOT read project files in main session:
238
-
239
- ```text
240
- Task(subagent_type="explorer-low",
241
- prompt="Analyze project structure: package.json, pyproject.toml, pubspec.yaml, go.mod.
242
- Find existing implementations related to [FEATURE]. Return: tech stack, relevant files, patterns used.
243
- Keep summary under 200 tokens.")
244
- ```
245
-
246
- **New project** (`vibe init <project-name>`):
247
- - Suggest tech stack (2-3 options)
248
-
249
- ### 2. Collect Requirements via Conversation
250
-
251
- **Principles:**
252
- - Ask **one question at a time**
253
- - Present options **with numbers** + "Feel free to describe in your own words"
254
- - **Natural conversation** without fixed order
255
-
256
- **Required confirmations:**
257
- - Purpose (Why): Why is it needed?
258
- - User (Who): Who will use it?
259
- - Feature scope (What): What features are needed?
260
- - Tech stack: Confirm existing stack or suggest new
261
- - Design reference: UI/UX to reference
262
-
263
- ### 2.1 Critical Requirements Confirmation (askUser) - v2.6.1
264
-
265
- **🚨 IMPORTANT: Use `askUser` tool for CRITICAL requirements that must not be missed**
266
-
267
- After initial conversation, use the structured `askUser` tool for:
268
- - 🔐 Authentication: method, MFA, password policy
269
- - 🛡️ Security: rate limiting, session management
270
- - ⏱️ Session: duration, concurrent login policy
271
- - 📊 Data Model: required fields, relationships
272
-
273
- **When to use askUser vs conversation:**
274
-
275
- | Scenario | Method |
276
- |----------|--------|
277
- | Exploratory (feature scope, style) | Natural conversation |
278
- | **Critical** (auth, security, session) | `askUser` tool |
279
- | Optional (performance, integration) | Natural conversation |
280
-
281
- **Usage**: read `references/askuser-examples.md` in this skill directory for `askUser`/`askUserQuick` invocation code, example output format, and `parseUserResponse` response parsing.
282
-
283
- **Available categories:**
284
- - `authentication`: Auth methods, MFA
285
- - `security`: Password policy, rate limiting
286
- - `session`: Session expiry, concurrent login
287
- - `data_model`: User profile fields
288
- - `performance`: Response time targets
289
- - `integration`: External service integration
290
-
291
-
292
- **ultrawork mode:**
293
- - askUser is **skipped** in ultrawork mode
294
- - Uses default values from templates automatically
295
-
296
- ### 2.5. Reference Documents via config.json (MANDATORY after tech stack confirmed)
297
-
298
- **🚨 CRITICAL: Read config.json references IMMEDIATELY after tech stack is confirmed**
299
-
300
- Reference documents are automatically generated in `config.json` based on the stack detected during `vibe init`:
301
-
302
- ```json
303
- // .vibe/config.json
304
- {
305
- "language": "ko",
306
- "stacks": [
307
- { "type": "typescript-react", "path": "package.json" }
308
- ],
309
- "references": {
310
- "rules": [
311
- "~/.claude/vibe/rules/code-quality.md",
312
- "~/.claude/vibe/rules/error-handling.md",
313
- "~/.claude/vibe/rules/security.md"
314
- ],
315
- "languages": [
316
- "~/.claude/vibe/languages/typescript-react.md"
317
- ],
318
- "templates": [
319
- "~/.claude/vibe/templates/spec-template.md",
320
- "~/.claude/vibe/templates/feature-template.md",
321
- "~/.claude/vibe/templates/constitution-template.md"
322
- ]
323
- }
324
- }
325
- ```
326
-
327
- **Workflow:**
328
-
329
- 1. Read `.vibe/config.json`
330
- 2. Extract `references.languages[]` paths
331
- 3. Read each language document for stack-specific guidelines
332
-
333
- **Example:**
334
- ```bash
335
- # 1. Check references in config.json
336
- Read .vibe/config.json
337
-
338
- # 2. Reference documents specified in references.languages
339
- Read ~/.claude/vibe/languages/typescript-react.md
340
- ```
341
-
342
- **Important:**
343
-
344
- - No manual mapping needed - config.json contains all reference paths
345
- - `config.json.references` is automatically referenced when running `/vibe.run`
346
- - Not copied to project (referenced from global package)
347
-
348
- ### 2.9 Research Cache Check (BEFORE step 3)
349
-
350
- Before spawning any research agents, check for a prior persisted dataset:
351
-
352
- ```bash
353
- # Slug = kebab-case of the feature/topic, max 50 chars
354
- ls .vibe/research/<slug>/paper.md 2>/dev/null
355
- ```
356
-
357
- **If `paper.md` exists:**
358
- 1. Read `.vibe/research/<slug>/paper.md`
359
- 2. Read `.vibe/research/<slug>/awesome-list.md` (if present)
360
- 3. Inject the **Findings**, **Recommendation**, and **Security considerations** sections verbatim into SPEC Context, prefixed with `> Source: .vibe/research/<slug>/paper.md (cached {{FILE_MTIME}})`
361
- 4. **Skip step 3** (parallel research) entirely — do not re-run GPT/Antigravity/Claude agents
362
- 5. Print: `✅ Research cache hit: <slug> (saved ~30s of LLM calls)`
363
-
364
- **Cache invalidation:**
365
- - User passes `--refresh-research` → delete dir, rerun step 3 from scratch
366
- - `paper.md` mtime older than 30 days → warn the user, ask to refresh or reuse
367
- - `stack` in `paper.md` frontmatter differs from current stack → auto-refresh
368
-
369
- **If `paper.md` does NOT exist:**
370
- Proceed to step 3. After step 3 completes, the synthesizer **must** write the 3 artifacts (see `parallel-research/orchestrator.md` Phase 5) so the next `/vibe.spec` run on this topic hits the cache.
371
-
372
- ### 3. Parallel Research (v2.5.0) - MANDATORY AFTER requirements confirmed
373
-
374
- **🚨🚨🚨 ABSOLUTE RULES FOR RESEARCH PHASE 🚨🚨🚨**
375
-
376
- **STOP! Before doing ANY research, read this carefully:**
377
-
378
- 1. **DO NOT** use Task tool to spawn research agents
379
- 2. **DO NOT** use context7 MCP directly for research
380
- 3. **DO NOT** use WebSearch tool directly for research
381
- 4. **YOU MUST** use Bash tool to call llm-orchestrate.js directly
382
-
383
- **🚨🚨🚨 CRITICAL: NO FILE CREATION DURING RESEARCH 🚨🚨🚨**
384
-
385
- 5. **DO NOT** create any files in project root during research
386
- 6. **DO NOT** create SECURITY_*.md, RESEARCH_*.md, SUMMARY_*.md files
387
- 7. **DO NOT** use Write tool during research phase
388
- 8. **ALL research results** must be returned as text output only
389
- 9. **Files are ONLY created** in Step 4 (SPEC) and Step 5 (Feature) in `.vibe/` directory
390
-
391
- **When to trigger:**
392
- 1. ✅ Feature type decided (e.g., "passkey authentication")
393
- 2. ✅ Tech stack confirmed (e.g., "React + Supabase")
394
- 3. ✅ Language guide copied (step 2.5)
395
- 4. ✅ Core requirements collected
396
-
397
- **→ IMMEDIATELY run these 6 Bash commands IN PARALLEL (all at once):**
398
-
399
- **Step 0: Script path:**
400
- - `[LLM_SCRIPT]` = `{{VIBE_PATH}}/hooks/scripts/llm-orchestrate.js`
401
-
402
- **Run all 4 in PARALLEL (each as separate Bash tool call):**
403
- ```bash
404
- # 1. GPT: Best practices (codex — code review & analysis)
405
- node "[LLM_SCRIPT]" gpt-codex orchestrate-json "Best practices for [FEATURE] with [STACK]. Focus: architecture patterns, code conventions. Return JSON: {patterns: [], antiPatterns: [], libraries: []}"
406
-
407
- # 2. GPT: Security (codex — code review & analysis)
408
- node "[LLM_SCRIPT]" gpt-codex orchestrate-json "Security vulnerabilities for [FEATURE] with [STACK]. Focus: CVE database, known exploits. Return JSON: {vulnerabilities: [], mitigations: [], checklist: []}"
409
-
410
- # 3. Antigravity: Best practices
411
- node "[LLM_SCRIPT]" antigravity orchestrate-json "Best practices for [FEATURE] with [STACK]. Focus: latest trends, framework updates. Return JSON: {patterns: [], antiPatterns: [], libraries: []}"
412
-
413
- # 4. Antigravity: Security
414
- node "[LLM_SCRIPT]" antigravity orchestrate-json "Security advisories for [FEATURE] with [STACK]. Focus: latest patches, recent incidents. Return JSON: {advisories: [], patches: [], incidents: []}"
415
- ```
416
-
417
- **Concrete example - run all 4 in parallel:**
418
- ```bash
419
- # GPT best practices (codex — code review & analysis)
420
- node "[LLM_SCRIPT]" gpt-codex orchestrate-json "Best practices for passkey authentication with React, Supabase. Focus: architecture patterns, code conventions. Return JSON: {patterns: [], antiPatterns: [], libraries: []}"
421
-
422
- # GPT security (codex — code review & analysis)
423
- node "[LLM_SCRIPT]" gpt-codex orchestrate-json "Security vulnerabilities for passkey authentication with React, Supabase. Focus: CVE database, known exploits. Return JSON: {vulnerabilities: [], mitigations: [], checklist: []}"
424
-
425
- # Antigravity best practices
426
- node "[LLM_SCRIPT]" antigravity orchestrate-json "Best practices for passkey authentication with React, Supabase. Focus: latest trends, framework updates. Return JSON: {patterns: [], antiPatterns: [], libraries: []}"
427
-
428
- # Antigravity security
429
- node "[LLM_SCRIPT]" antigravity orchestrate-json "Security advisories for passkey authentication with React, Supabase. Focus: latest patches, recent incidents. Return JSON: {advisories: [], patches: [], incidents: []}"
430
- ```
431
-
432
- **ALSO run Claude research agents in parallel using Task tool:**
433
-
434
- | Claude Agent | Role | Source |
435
- |--------------|------|--------|
436
- | `best-practices` | Best practices for [feature] + [stack] | WebSearch |
437
- | `framework-docs` | Latest docs via context7 | context7 MCP |
438
- | `codebase-patterns` | Similar patterns in existing codebase | Glob, Grep |
439
- | `security-advisory` | Security advisories for [feature] | WebSearch |
440
-
441
- **Total: 4 GPT/Antigravity calls (Bash) + 4 Claude agents (Task) = 8 parallel research tasks**
442
-
443
- **🚨 GPT/Antigravity MUST be called via Bash with llm-orchestrate.js! 🚨**
444
-
445
- #### 3.0.1 Agent Teams — Research Collaboration
446
-
447
- > **Team definition**: See `agents/teams/research-team.md`
448
- > Settings: `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1` + `teammateMode: in-process` (`~/.claude/settings.json` global — auto-configured by postinstall)
449
-
450
- **Discussion results are reflected in the SPEC's Context section.**
451
-
452
- #### 3.1 Result Merge Rules
453
-
454
- | Area | Merge Strategy |
455
- |------|----------------|
456
- | Best Practices | Deduplicate, keep most detailed |
457
- | Security | ALL included (no dedup for safety) |
458
- | Libraries | Consensus recommendations |
26
+ ### 1. Git branch + pointer
459
27
 
460
- **IMPORTANT:**
461
- - DO NOT skip research step
462
- - ❌ DO NOT ask user "should I run research?"
463
- - ✅ ALWAYS run after requirements confirmed
464
- - ✅ Show "Running parallel research (Claude + GPT + Antigravity)..." message
465
- - ✅ Include all agent + LLM results in SPEC Context
466
- - ✅ Run all 4 Bash LLM calls in parallel + 4 Task agents in parallel
28
+ - `git branch --show-current` — `main`/`master` 이면 `git checkout -b feature/{feature-name}` (소문자·하이픈). feature 브랜치면 그대로 진행.
29
+ - feature 이름 확정 즉시 `.vibe/.last-feature` 에 이름 한 줄 기록 (값이 같으면 no-op).
467
30
 
468
- **Research results are reflected in SPEC's Context section.**
31
+ ### 2. Project context
469
32
 
470
- ### 3.2 UI/UX Design Intelligence (Auto-triggered)
33
+ - `.vibe/config.json` 읽기 `references.languages[]` 의 스택 가이드, `stacks` 확인.
34
+ - 기존 코드 파악이 필요하면 네이티브 Explore 서브에이전트에 위임 (main session 에서 프로젝트 파일을 훑지 않는다):
471
35
 
472
- > **Condition**: Auto-executes when UI/UX keywords are present in the SPEC context (website, landing, dashboard, app, e-commerce, portfolio, SaaS, mobile app, web app, UI, UX, frontend, design)
473
- > **Disable**: Set `"uiUxAnalysis": false` in `.vibe/config.json`
474
-
475
- **When UI/UX keywords are detected, run 3 agents sequentially in parallel with research:**
476
-
477
- ```
478
- [Parallel Research] GPT + Antigravity + Claude agents
479
- ↓ (concurrent execution)
480
- [UI/UX Intelligence]
481
- ① ui-industry-analyzer (Haiku) → industry analysis + design strategy
482
-
483
- ②③ parallel execution:
484
- ② ui-design-system-gen (Sonnet) → generate MASTER.md
485
- ③ ui-layout-architect (Haiku) → layout design
486
- ```
487
-
488
- **How to execute:**
489
-
490
- 1. **① ui-industry-analyzer** — Run as Task(haiku) agent:
491
- ```text
492
- Task(subagent_type="ui-industry-analyzer",
493
- prompt="Analyze product: [USER_DESCRIPTION]. Use core_ui_search to detect category, style priority, color mood, typography mood. Save result to .vibe/design-system/{project}/analysis-result.json")
494
- ```
495
-
496
- 2. **②③ parallel execution** — Using ①'s result as input:
497
36
  ```text
498
- # ② Generate design system (Sonnet)
499
- Task(subagent_type="ui-design-system-gen",
500
- prompt="Generate design system from analysis-result.json for project '{project}'. Use core_ui_search for style/color/typography, then core_ui_generate_design_system and core_ui_persist_design_system.")
501
-
502
- # ③ Layout design (Haiku) — parallel execution
503
- Task(subagent_type="ui-layout-architect",
504
- prompt="Design layout from analysis-result.json for project '{project}'. Use core_ui_search for landing patterns and dashboard layout.")
505
- ```
506
-
507
- 3. **Inject results into SPEC Context:**
508
- ```markdown
509
- ### Design System (Auto-generated)
510
- - Category: {① category}
511
- - Style: {① style_priority}
512
- - MASTER.md: .vibe/design-system/{project}/MASTER.md
513
- - Layout: {③ pattern + sections}
514
- ```
515
-
516
- ### 3.9 Persist Research Cache (AFTER research completes, BEFORE SPEC write)
517
-
518
- > The "no Write during research" rule from step 3 does **not** apply here — research is done; artifacts are safe to persist.
519
-
520
- After parallel research + UI/UX intelligence complete, before writing the SPEC, save the merged research to `.vibe/research/<slug>/`:
521
-
522
- 1. Compute slug: kebab-case of feature name, max 50 chars
523
- 2. Write **three files** using templates from `parallel-research/templates/`:
524
- - `.vibe/research/<slug>/synthesis.md` — raw merged findings (all agent outputs)
525
- - `.vibe/research/<slug>/awesome-list.md` — curated links/repos/patterns (every entry needs a one-line "why"; drop entries without one)
526
- - `.vibe/research/<slug>/paper.md` — structured survey (Abstract → Background → Method → Findings → Recommendation → Security → References)
527
- 3. Include a frontmatter header in `paper.md` with a `stack:` field so step 2.9 can detect stack drift
528
- 4. If the directory already exists (user passed `--refresh-research`), overwrite
529
-
530
- This makes the next `/vibe.spec` (or future `/vibe.research`) invocation on the same topic hit the cache at step 2.9.
531
-
532
- ### 4. Write SPEC Document (PTCF Structure)
533
-
534
- #### 4.0 Large Scope Detection & Auto-Split (MANDATORY)
535
-
536
- **🚨 CRITICAL: Automatically split SPEC when scope is large**
537
-
538
- **❌ DO NOT ask user for confirmation - auto-split silently**
539
-
540
- **Detection criteria (ANY triggers split):**
541
-
542
- | Criteria | Threshold |
543
- |----------|-----------|
544
- | Phases | 5+ phases |
545
- | Files to create | 15+ files |
546
- | Platforms | 2+ platforms |
547
- | Major features | 4+ distinct features |
548
-
549
- **Auto-split output (SPEC + Feature files must match):**
550
-
551
- ```
552
- .vibe/specs/{feature-name}/
553
- ├── _index.md # Master SPEC
554
- ├── phase-1-setup.md
555
- ├── phase-2-core.md
556
- └── ...
557
-
558
- .vibe/features/{feature-name}/
559
- ├── _index.feature # Master Feature
560
- ├── phase-1-setup.feature
561
- ├── phase-2-core.feature
562
- └── ...
563
- ```
564
-
565
- **🚨 CRITICAL: Each SPEC phase file MUST have a matching Feature file**
566
-
567
- **Master SPEC / Master Feature**: copy the `Master SPEC (_index.md)` and `Master Feature (_index.feature)` templates from `references/templates.md`.
568
-
569
- **Small scope (default):**
570
-
571
- Create `.vibe/specs/{feature-name}.md` with the **Single SPEC template** in `references/templates.md` — PTCF structure (Persona / Context / Task / Constraints / Output Format / Acceptance Criteria) + status frontmatter (status/currentPhase/totalPhases/createdAt/lastUpdated).
572
-
573
- ### 5. Create Feature File (BDD) - Required
574
-
575
- **🚨 CRITICAL: Feature files MUST match SPEC file structure**
576
-
577
- | SPEC Structure | Feature Structure |
578
- |----------------|-------------------|
579
- | Single file (`{feature}.md`) | Single file (`{feature}.feature`) |
580
- | Split (`{feature}/_index.md` + phases) | Split (`{feature}/_index.feature` + phases) |
581
-
582
- #### 5.1 Single File (Small Scope)
583
-
584
- Create `.vibe/features/{feature-name}.feature`:
585
-
586
- **Creation rules:**
587
- 1. Convert each SPEC Acceptance Criteria → one Scenario
588
- 2. Include Happy Path (normal case) + Edge Case (exception case)
589
- 3. Follow Given-When-Then format
590
-
591
- Use the **Single Feature template** in `references/templates.md` — User Story + gherkin Given-When-Then scenarios + Coverage table mapping each scenario to a SPEC AC.
592
-
593
- #### 5.2 Split Files (Large Scope)
594
-
595
- When SPEC is split into phases, Feature files MUST also be split:
596
-
597
- ```
598
- .vibe/features/{feature-name}/
599
- ├── _index.feature # Master: links to all phase features
600
- ├── phase-1-setup.feature # Scenarios for phase-1-setup.md
601
- ├── phase-2-core.feature # Scenarios for phase-2-core.md
602
- └── ...
603
- ```
604
-
605
- **Phase Feature file structure**: use the **Phase Feature template** in `references/templates.md`.
606
-
607
- ### 6. Ambiguity Scan - Required
608
-
609
- After creating SPEC draft, **must perform systematic ambiguity check**.
610
-
611
- #### 6.1 Mandatory Check Categories
612
-
613
- | Category | Check Items | Red Flags |
614
- |----------|-------------|-----------|
615
- | **Functional Scope** | Missing features, unclear behavior | "etc.", "other", "if needed" |
616
- | **Data Model** | Undefined entities, relationships | Undefined types, missing fields |
617
- | **Non-Functional** | Performance, security requirements | Performance requirements without numbers |
618
- | **Edge Cases** | Boundary conditions, errors | 0 failure scenarios |
619
- | **Integration Points** | External APIs, contracts | API version/endpoint undefined |
620
- | **User Input** | Validation rules, limits | Input limits not specified |
621
- | **State Management** | State transitions, persistence | Missing state diagram |
622
-
623
- #### 6.2 Forbidden Ambiguous Terms
624
-
625
- If the following terms exist in SPEC, **clarification is mandatory**:
626
-
627
- | Forbidden Term | Replacement Method |
628
- |----------------|-------------------|
629
- | "appropriately", "properly" | Provide specific criteria (e.g., "within 3 seconds") |
630
- | "quickly", "rapidly" | Specify with numbers (e.g., "under 100ms") |
631
- | "various", "multiple" | List specific items |
632
- | "etc.", "other" | Specify complete list or limit scope |
633
- | "if needed", "depending on situation" | Specify conditions (e.g., "when credits < 10") |
634
- | "later", "in the future" | Explicitly exclude from current scope |
635
-
636
- #### 6.3 Check Process
637
-
638
- ```
639
- 1. Write SPEC draft
640
-
641
- 2. Auto-scan for forbidden terms
642
-
643
- 3. Review checklist by category
644
-
645
- 4. List discovered ambiguities
646
-
647
- 5. Auto-fixable items → Fix immediately
648
- Needs user confirmation → Ask question
649
-
650
- 6. Re-verify (max 2 rounds — remaining ambiguities → user confirmation or TODO)
37
+ Task(subagent_type="Explore",
38
+ prompt="Find existing implementations related to [FEATURE]. Return: tech stack, relevant files, patterns. Under 200 tokens.")
651
39
  ```
652
40
 
653
- #### 6.4 Auto-Fix for Common Ambiguities
41
+ ### 3. Clarify 진짜 모호할 때만
654
42
 
655
- | Ambiguity Type | Auto-Fix Method |
656
- |----------------|-----------------|
657
- | Timeout undefined | Apply default 30 seconds |
658
- | Retry count undefined | Apply default 3 retries |
659
- | Pagination undefined | Apply default 20 items/page |
660
- | Input length undefined | Text 500 chars, password 8-64 chars |
661
- | File size undefined | Image 5MB, video 100MB |
43
+ 별도 인터뷰 단계가 아니다. 요구사항·첨부·레거시 아티팩트·코드베이스 컨텍스트로 답을 합리적으로 정할 수 있으면 **묻지 않는다**. 다음 조건을 모두 만족할 때만 질문한다:
662
44
 
663
- #### 6.5 Ambiguity Output Format
45
+ - 답에 따라 Done Criteria 나 구현 방향이 실제로 갈라진다 (인증 방식, 데이터 모델의 필수 필드, 외부 연동 여부 등)
46
+ - 합리적 기본값을 SPEC 의 Assumptions 로 명시하는 것으로 대체할 수 없다
664
47
 
665
- ```markdown
666
- ## 🔍 Ambiguity Scan Results
48
+ 질문할 때는 **한 번에 묶어서** (번호 목록, 최대 5개), 각 질문에 제안 기본값을 붙인다. `automationLevel: autonomous` 면 질문 없이 기본값을 채택하고 전부 SPEC 의 Assumptions 섹션에 기록한다.
667
49
 
668
- ### Found Issues: 3
50
+ 사소한 값(타임아웃, 페이지 크기, 재시도 횟수 등)은 묻지 말고 상식적 기본값을 채택 + Assumptions 에 기록.
669
51
 
670
- #### 1. Functional Scope
671
- - ⚠️ "Login failure behavior" not defined
672
- → **Auto-fix**: Apply 5-minute lockout after 3 failures
673
- - ⚠️ "Session expiration handling" unclear
674
- → **Question**: Session expiration time? (30min/1hour/24hours)
52
+ ### 4. Write SPEC — one pass
675
53
 
676
- #### 2. Edge Cases
677
- - ⚠️ Concurrent login permission undefined
678
- → **Question**: Allow concurrent login? (Y/N)
54
+ `vibe/templates/spec-template.md` 구조로 `.vibe/specs/{feature-name}.md` 작성한다. 핵심 요건:
679
55
 
680
- ### Auto-fixed: 1
681
- ### Needs clarification: 2
682
- ```
683
-
684
- ### 7. Quality Validation (Self-Check)
56
+ - **Overview / Goal** — 무엇을, 왜. 1-3 문장.
57
+ - **Done Criteria** — 결정론적 게이트만. 각 항목은 "명령/관찰로 pass·fail 판정 가능"해야 한다 (테스트 exit code, 빌드 성공, 특정 동작 관찰). "잘 동작한다" 류 서술 금지 — 이것이 루프의 JUDGE 입력이 된다.
58
+ - **Scenarios** — Given-When-Then. Happy path + 주요 edge case. 각 시나리오는 Done Criteria 중 하나에 매핑.
59
+ - **Out of Scope** — 이번에 하지 않는 것을 명시 (비어 있으면 스코프 팽창 신호).
60
+ - **Assumptions** 3단계에서 채택한 기본값 전부.
61
+ - **API Contract** (해당 시에만) — 엔드포인트/요청/응답 형태. 이 섹션이 있으면 이후 `/vibe.contract` 가 drift 를 검사한다.
685
62
 
686
- **Must perform self-quality check after SPEC completion**
63
+ 이어서 `.vibe/features/{feature-name}.feature` 생성한다: 시나리오 섹션을 gherkin 으로 변환 (Done Criteria ↔ Scenario 매핑 유지). `/vibe.run` 이 이 파일을 구현·검증 단위로 사용한다.
687
64
 
688
- #### 7.1 Quality Checklist (Required Items)
65
+ **Large scope** (5+ phases 또는 15+ 신규 파일 또는 4+ 독립 기능): 폴더 분할 — `.vibe/specs/{feature}/_index.md` + `phase-N-{name}.md`, feature 파일도 동일 구조로 매칭. 조용히 분할하고 결과만 보고한다.
689
66
 
690
- | Category | Check Item | Weight |
691
- |----------|------------|--------|
692
- | **Completeness** | All user flows included in Task | 15% |
693
- | **Completeness** | All ACs converted to Feature scenarios | 10% |
694
- | **Clarity** | No ambiguous terms (e.g., "appropriately", "quickly") | 10% |
695
- | **Clarity** | All numbers/limits specified (e.g., "max 500 chars") | 10% |
696
- | **Testability** | All ACs are auto-testable | 10% |
697
- | **Security** | Authentication/authorization requirements defined | 10% |
698
- | **Security** | Sensitive data handling method specified | 5% |
699
- | **Error Handling** | Major failure scenarios defined | 10% |
700
- | **Error Handling** | User error messages specified | 5% |
701
- | **Performance** | Response time/throughput targets specified | 5% |
702
- | **Edge Cases** | Boundary condition handling defined | 5% |
703
- | **Dependencies** | External systems/APIs specified | 5% |
67
+ **파일 규칙**: `.vibe/` 밖에 파일을 만들지 않는다. SPEC 파일마다 매칭되는 Feature 파일이 있어야 한다.
704
68
 
705
- #### 7.2 Quality Score Calculation
69
+ ### 5. Self-review once
706
70
 
707
- ```
708
- Score = Σ(Check item met × Weight) / 100
71
+ 작성 직후, 아래 체크리스트로 자기 SPEC 을 **1회** 점검하고 걸리는 항목을 즉시 고친다. 외부 LLM 리뷰 없음, 수렴 루프 없음 — 한 번 고치면 끝.
709
72
 
710
- Grades:
711
- - 95-100: EXCELLENT - Ready to start implementation
712
- - 90-94: ⚠️ GOOD - Minor improvements required before implementation
713
- - 80-89: ⚠️ FAIR - Significant improvements required
714
- - 0-79: ❌ POOR - Rewrite required
715
- ```
73
+ - [ ] 모든 Done Criteria 가 명령/관찰로 판정 가능한가 (모델 자기 보고가 아닌)
74
+ - [ ] 모든 시나리오가 Done Criteria 매핑되는가 (고아 시나리오 없음)
75
+ - [ ] 수치가 필요한 곳에 수치가 있는가 (제한·타임아웃·크기 — 없으면 기본값 + Assumptions)
76
+ - [ ] Out of Scope 가 비어 있지 않은가
77
+ - [ ] 요구사항에 있던 것 중 SPEC 에서 빠진 것이 없는가
716
78
 
717
- #### 7.3 Quality Gate (Auto-verification)
79
+ ### 6. Approval the single gate
718
80
 
719
- **100 points required to complete SPEC draft. Loop until perfect ask user if auto-fixer hits a wall.**
81
+ SPEC 요약(Goal, Done Criteria, 시나리오 수, Out of Scope, 열린 Assumptions)을 제시하고 승인을 받는다:
720
82
 
721
83
  ```
722
- SPEC writing complete
723
-
724
- [Calculate Quality Score]
725
-
726
- Score < 100? → Show missing items → Auto-fix → Re-evaluate
727
-
728
- Stuck? (score == prev_score)
729
- ├─ Interactive: ask user → fill values OR "proceed" OR "abort"
730
- └─ ultrawork: record gaps as TODO → proceed
731
-
732
- Score == 100 (or user-approved) → SPEC Draft Complete → Handoff to spec-review skill
733
- ```
734
-
735
- #### 7.4 Auto-Fix for Low Score
736
-
737
- If score is below 100, attempt automatic fixes:
84
+ 📋 SPEC 준비 완료: {feature-name}
85
+ .vibe/specs/{feature-name}.md · .vibe/features/{feature-name}.feature
738
86
 
739
- | Missing Item | Auto-Fix Method |
740
- |--------------|-----------------|
741
- | Missing AC | Auto-generate AC based on Task |
742
- | Numbers not specified | Apply project defaults (e.g., timeout 30s) |
743
- | Missing error handling | Add common error scenarios |
744
- | Missing performance targets | Apply industry standard criteria |
87
+ Goal: {1줄}
88
+ Done Criteria: {N}개 (전부 결정론 게이트)
89
+ Scenarios: {M}개 · Out of Scope: {K}항목
90
+ Assumptions: {요약 또는 "없음"}
745
91
 
746
- ### 8. SPEC Draft Complete - Handoff to Review
747
-
748
- **🚨 IMPORTANT: GPT/Antigravity review is now a SEPARATE command**
749
-
750
- After SPEC draft is complete (score ≥ 95):
751
-
752
- **If `ultrawork` mode:**
753
- - ❌ DO NOT show handoff message
754
- - ❌ DO NOT ask for confirmation
755
- - ✅ Immediately load skill `spec-review` with feature `{feature-name}` (chain-next)
756
- - ✅ After review passes, immediately proceed to `/vibe.run "{feature-name}" ultrawork`
757
-
758
- **If normal mode:**
759
- Output the handoff message:
760
-
761
- ```
762
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
763
- ✅ SPEC DRAFT COMPLETE: {feature-name}
764
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
765
-
766
- 📋 SPEC: .vibe/specs/{feature-name}.md
767
- 📋 Feature: .vibe/features/{feature-name}.feature
768
- 📊 Quality Score: {score}/100
769
- ⏱️ Started: {start_time}
770
- ⏱️ Completed: {getCurrentTime result}
771
-
772
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
773
- ⚠️ NEXT STEP: Run SPEC review (spec-review skill)
774
-
775
- Option 1 (same session):
776
- Load skill `spec-review` with feature `{feature-name}`
777
- (or natural language: "spec review")
778
-
779
- Option 2 (recommended for large context):
780
- /new → /vibe.spec "{feature-name}"
781
- (Smart Resume will start from Phase 4)
782
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
92
+ 승인하면 SPEC 루프의 Done 정의가 됩니다.
93
+ [1] 승인 → 구현 진행 [2] 수정 요청 [3] 중단
783
94
  ```
784
95
 
785
- **Tip:** New session recommended when context > 50% to ensure review accuracy
786
-
787
- ## Output (MANDATORY File Creation)
96
+ - 수정 요청 반영 재제시 (사용자 주도 반복 자동 루프 아님).
97
+ - `automationLevel: autonomous` → 승인 생략, 요약만 출력하고 진행.
98
+ - 승인 후 SPEC 변경은 코드 변경과 같은 커밋으로 (SPEC-First `vibe.run` 참조).
788
99
 
789
- **🚨 CRITICAL: Files MUST be created in these EXACT paths. NO exceptions.**
100
+ ## Output
790
101
 
791
- ### Small Scope (Single File)
102
+ | 파일 | 경로 |
103
+ |---|---|
104
+ | SPEC | `.vibe/specs/{feature-name}.md` (또는 분할 폴더) |
105
+ | Feature (BDD) | `.vibe/features/{feature-name}.feature` (또는 분할 폴더) |
106
+ | Pointer | `.vibe/.last-feature` |
792
107
 
793
- | File | Path | When |
794
- |------|------|------|
795
- | SPEC | `.vibe/specs/{feature-name}.md` | After quality validation (Step 7) |
796
- | Feature | `.vibe/features/{feature-name}.feature` | Immediately after SPEC |
797
-
798
- ### Large Scope (Split Files)
799
-
800
- | File | Path | When |
801
- |------|------|------|
802
- | Master SPEC | `.vibe/specs/{feature-name}/_index.md` | After quality validation |
803
- | Phase SPEC | `.vibe/specs/{feature-name}/phase-{N}-{name}.md` | Per phase |
804
- | Master Feature | `.vibe/features/{feature-name}/_index.feature` | After Master SPEC |
805
- | Phase Feature | `.vibe/features/{feature-name}/phase-{N}-{name}.feature` | Per phase SPEC |
806
-
807
- **❌ FORBIDDEN:**
808
-
809
- - Creating files in project root (e.g., `feature-name.md`)
810
- - Creating files outside `.vibe/` directory
811
- - Skipping file creation
812
- - Using different file names than feature-name
813
- - Creating split SPEC without matching split Feature files
814
-
815
- **✅ REQUIRED:**
816
-
817
- - Use Write tool to create files
818
- - Verify directories exist (create if needed)
819
- - Confirm file creation in response
820
- - **Each SPEC file must have a matching Feature file**
821
-
822
- ### File Creation Template
823
-
824
- **Single file:**
825
- ```
826
- 1. Write .vibe/specs/{feature-name}.md
827
- 2. Write .vibe/features/{feature-name}.feature
828
- 3. Confirm: "✅ Created: specs/{feature-name}.md + features/{feature-name}.feature"
829
- ```
830
-
831
- **Split files:**
832
- ```
833
- 1. Write .vibe/specs/{feature-name}/_index.md
834
- 2. Write .vibe/specs/{feature-name}/phase-1-setup.md
835
- 3. Write .vibe/specs/{feature-name}/phase-2-core.md
836
- 4. Write .vibe/features/{feature-name}/_index.feature
837
- 5. Write .vibe/features/{feature-name}/phase-1-setup.feature
838
- 6. Write .vibe/features/{feature-name}/phase-2-core.feature
839
- 7. Confirm: "✅ Created: {N} SPEC files + {N} Feature files"
840
- ```
841
-
842
- ## Example
843
-
844
- Full interview → ambiguity scan → quality gate → review walkthrough: read `references/example-session.md` in this skill directory (load only when you need a concrete end-to-end example).
845
-
846
- ## Core Tools (Semantic Analysis & Memory)
847
-
848
- ### Tool Invocation
849
- All tools are called via:
850
- ```bash
851
- node -e "import('{{VIBE_PATH_URL}}/node_modules/@su-record/vibe/dist/tools/index.js').then(t => t.TOOL_NAME({...args}).then(r => console.log(r.content[0].text)))"
852
- ```
853
-
854
- ### Recommended Tools for SPEC Creation
855
-
856
- | Tool | Purpose | When to Use |
857
- |------|---------|-------------|
858
- | `findSymbol` | Find symbol definitions | Locate existing implementations to reference |
859
- | `findReferences` | Find all references | Understand how existing code is used |
860
- | `analyzeComplexity` | Code complexity analysis | Evaluate complexity of code to modify |
861
- | `saveMemory` | Save important decisions | Store confirmed requirements, design decisions |
862
- | `recallMemory` | Recall saved memory | Retrieve previous project decisions |
863
-
864
- ### Example Tool Usage in SPEC Creation
865
-
866
- **1. Find existing auth implementation:**
867
- ```bash
868
- node -e "import('{{VIBE_PATH_URL}}/node_modules/@su-record/vibe/dist/tools/index.js').then(t => t.findSymbol({symbolName: 'login', searchPath: 'src/'}).then(r => console.log(r.content[0].text)))"
869
- ```
870
-
871
- **2. Save confirmed requirements:**
872
- ```bash
873
- node -e "import('{{VIBE_PATH_URL}}/node_modules/@su-record/vibe/dist/tools/index.js').then(t => t.saveMemory({key: 'brick-game-requirements', value: 'Platform: Web, Stack: Phaser.js, Style: Neon', category: 'spec', projectPath: process.cwd()}).then(r => console.log(r.content[0].text)))"
874
- ```
875
-
876
- **3. Recall previous decisions:**
877
- ```bash
878
- node -e "import('{{VIBE_PATH_URL}}/node_modules/@su-record/vibe/dist/tools/index.js').then(t => t.recallMemory({key: 'brick-game-requirements', projectPath: process.cwd()}).then(r => console.log(r.content[0].text)))"
879
- ```
108
+ 승인된 SPEC 루프의 ANCHOR 쓰인다: `/vibe.run` 이 시나리오 단위로 구현·검증하고, `/vibe.verify` 가 Done Criteria 를 판정해 `.vibe/metrics/run-ledger.json` 의 `verifyPassed` 를 기록한다. 게이트 통과 여부는 항상 run-ledger·테스트 exit code 가 판정한다.
880
109
 
881
110
  ## Next Step
882
111
 
883
112
  ```
884
- /vibe.run "brick-game"
113
+ /vibe.run "{feature-name}"
885
114
  ```
886
115
 
887
116
  ---