opencode-goopspec 0.1.3 โ†’ 0.1.5

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 (92) hide show
  1. package/README.md +252 -331
  2. package/agents/goop-debugger.md +175 -172
  3. package/agents/goop-designer.md +232 -160
  4. package/agents/goop-executor.md +197 -127
  5. package/agents/goop-explorer.md +148 -150
  6. package/agents/goop-librarian.md +218 -164
  7. package/agents/goop-orchestrator.md +364 -338
  8. package/agents/goop-planner.md +331 -153
  9. package/agents/goop-researcher.md +198 -126
  10. package/agents/goop-tester.md +277 -202
  11. package/agents/goop-verifier.md +191 -201
  12. package/agents/goop-writer.md +241 -133
  13. package/agents/memory-distiller.md +228 -136
  14. package/commands/goop-accept.md +430 -36
  15. package/commands/goop-amend.md +13 -0
  16. package/commands/goop-complete.md +13 -0
  17. package/commands/goop-debug.md +13 -0
  18. package/commands/goop-discuss.md +419 -7
  19. package/commands/goop-execute.md +386 -37
  20. package/commands/goop-help.md +11 -0
  21. package/commands/goop-map-codebase.md +13 -0
  22. package/commands/goop-memory.md +11 -0
  23. package/commands/goop-milestone.md +13 -0
  24. package/commands/goop-pause.md +12 -0
  25. package/commands/goop-plan.md +374 -254
  26. package/commands/goop-quick.md +12 -0
  27. package/commands/goop-recall.md +11 -0
  28. package/commands/goop-remember.md +12 -0
  29. package/commands/goop-research.md +13 -0
  30. package/commands/goop-resume.md +12 -0
  31. package/commands/goop-setup.md +32 -268
  32. package/commands/goop-specify.md +315 -39
  33. package/commands/goop-status.md +276 -28
  34. package/dist/index.js +34564 -135
  35. package/dist/worker/index.js +35883 -0
  36. package/package.json +4 -2
  37. package/references/context-injection.md +307 -0
  38. package/references/discovery-interview.md +278 -0
  39. package/references/enforcement-system.md +213 -0
  40. package/references/handoff-protocol.md +290 -0
  41. package/references/model-profiles.md +1 -1
  42. package/references/orchestrator-philosophy.md +155 -223
  43. package/references/phase-gates.md +360 -0
  44. package/references/plugin-architecture.md +212 -0
  45. package/references/response-format.md +41 -9
  46. package/references/subagent-protocol.md +83 -33
  47. package/references/visual-style.md +199 -0
  48. package/references/xml-response-schema.md +236 -0
  49. package/skills/accessibility/skill.md +1 -1
  50. package/skills/accessibility-testing/skill.md +1 -1
  51. package/skills/api-docs/skill.md +1 -1
  52. package/skills/architecture-design/skill.md +1 -1
  53. package/skills/atomic-commits/skill.md +1 -1
  54. package/skills/code-review/skill.md +1 -1
  55. package/skills/codebase-mapping/skill.md +1 -1
  56. package/skills/convention-detection/skill.md +1 -1
  57. package/skills/debugging/skill.md +1 -1
  58. package/skills/deviation-handling/skill.md +1 -1
  59. package/skills/documentation/skill.md +1 -1
  60. package/skills/goop-core/skill.md +3 -3
  61. package/skills/memory-usage/skill.md +1 -1
  62. package/skills/parallel-planning/skill.md +1 -1
  63. package/skills/pattern-extraction/skill.md +1 -1
  64. package/skills/performance-optimization/skill.md +1 -1
  65. package/skills/playwright/skill.md +1 -1
  66. package/skills/playwright-testing/skill.md +1 -1
  67. package/skills/progress-tracking/skill.md +1 -1
  68. package/skills/readme-generation/skill.md +1 -1
  69. package/skills/research/skill.md +1 -1
  70. package/skills/responsive-design/skill.md +1 -1
  71. package/skills/scientific-method/skill.md +1 -1
  72. package/skills/security-audit/skill.md +1 -1
  73. package/skills/task-decomposition/skill.md +1 -1
  74. package/skills/task-delegation/skill.md +1 -1
  75. package/skills/technical-writing/skill.md +1 -1
  76. package/skills/testing/skill.md +1 -1
  77. package/skills/ui-design/skill.md +1 -1
  78. package/skills/ux-patterns/skill.md +1 -1
  79. package/skills/verification/skill.md +1 -1
  80. package/skills/visual-regression/skill.md +1 -1
  81. package/templates/blueprint.md +88 -41
  82. package/templates/chronicle.md +130 -16
  83. package/templates/handoff.md +140 -0
  84. package/templates/milestone.md +1 -1
  85. package/templates/project-knowledge-base.md +93 -0
  86. package/templates/project.md +114 -0
  87. package/templates/requirements.md +121 -0
  88. package/templates/research.md +1 -1
  89. package/templates/retrospective.md +1 -1
  90. package/templates/spec.md +85 -20
  91. package/templates/state.md +103 -0
  92. package/templates/summary.md +1 -1
@@ -1,22 +1,434 @@
1
1
  ---
2
2
  name: goop-discuss
3
- description: Capture user vision before planning
3
+ description: Capture user vision through discovery interview before planning
4
+ phase: discuss
5
+ next-step: "When discovery is complete, create the blueprint"
6
+ next-command: /goop-plan
7
+ alternatives:
8
+ - command: /goop-research
9
+ when: "If there are unknowns to investigate first"
10
+ - command: /goop-quick
11
+ when: "For small, single-file tasks that don't need planning"
4
12
  ---
5
13
 
6
14
  # /goop-discuss
7
15
 
8
- **Deprecated.** Use `/goop-plan`.
16
+ **Start the Discovery Interview.** Capture vision, requirements, constraints, and risks before planning begins.
9
17
 
10
18
  ## Usage
11
19
 
12
20
  ```bash
13
- /goop-discuss [topic]
21
+ /goop-discuss [brief description of what you want to build]
14
22
  ```
15
23
 
16
- ## Description
24
+ ## Core Purpose
17
25
 
18
- This command is an alias for `/goop-plan`.
26
+ The Discovery Interview is a **mandatory gate** before planning. It ensures requirements are "nailed down" before any work begins.
19
27
 
20
- In GoopSpec Wave 3, the "discussion" or "interview" phase is an integral part of **Planning**. When you run `/goop-plan`, the agent automatically engages in a discovery conversation to clarify requirements before generating artifacts.
28
+ ```
29
+ +================================================================+
30
+ | NO PLANNING WITHOUT DISCOVERY. |
31
+ | The interview ensures we build the RIGHT thing. |
32
+ | Skipping discovery leads to scope creep and rework. |
33
+ +================================================================+
34
+ ```
35
+
36
+ ## Orchestrator Role
37
+
38
+ **YOU conduct the interview directly.** Do NOT spawn agents for conversation.
39
+
40
+ Why: The interview builds shared understanding. That understanding stays in YOUR context and informs how you delegate. Spawning for conversation fragments knowledge.
41
+
42
+ ## The Six Questions
43
+
44
+ Every discovery interview MUST answer these questions:
45
+
46
+ ### 1. Vision (The What)
47
+ - What are you trying to build?
48
+ - What problem does this solve?
49
+ - Who is this for?
50
+
51
+ ### 2. Must-Haves (The Contract)
52
+ - What are the non-negotiable requirements?
53
+ - What MUST be delivered for this to be complete?
54
+ - What are the acceptance criteria?
55
+
56
+ ### 3. Constraints (The Boundaries)
57
+ - What stack/frameworks are we using?
58
+ - What are the performance requirements?
59
+ - What existing code must we integrate with?
60
+
61
+ ### 4. Out of Scope (The Guardrails)
62
+ - What are we explicitly NOT building?
63
+ - What features are deferred to later?
64
+
65
+ ### 5. Assumptions (The Baseline)
66
+ - What existing functionality are we relying on?
67
+ - What decisions have already been made?
68
+
69
+ ### 6. Risks (The Unknowns)
70
+ - What could go wrong?
71
+ - What are we uncertain about?
72
+ - What dependencies could block us?
73
+
74
+ ## Tools Used
75
+
76
+ | Tool | Purpose in This Command |
77
+ |------|------------------------|
78
+ | `goop_status` | Check current phase and project state |
79
+ | `memory_search` | Find prior context about the project |
80
+ | `memory_save` | Persist discovery interview results |
81
+ | `goop_reference` | Load discovery-interview protocol |
82
+
83
+ **Hook Support:** `system.transform` injects relevant memories before execution.
84
+
85
+ ---
86
+
87
+ ## Process
88
+
89
+ ### Phase 1: Setup
90
+
91
+ **Execute these checks BEFORE any user interaction:**
92
+
93
+ **1.1 Check current state:**
94
+ ```
95
+ goop_status()
96
+ goop_state({ action: "get" }) # NEVER read state.json directly
97
+ Read(".goopspec/REQUIREMENTS.md") # If exists, interview was done
98
+ ```
99
+
100
+ **CRITICAL: Never read or edit .goopspec/state.json directly. Always use `goop_state` tool.**
101
+
102
+ **1.2 If REQUIREMENTS.md exists:**
103
+
104
+ Use `question` tool:
105
+ - header: "Existing Discovery"
106
+ - question: "I found an existing discovery interview. How would you like to proceed?"
107
+ - options:
108
+ - "Start fresh (Recommended)" โ€” Clear previous discovery, start new interview
109
+ - "Review and update" โ€” Load previous answers, modify as needed
110
+ - "Use existing" โ€” Skip interview, go straight to /goop-plan
111
+
112
+ **1.3 Initialize if needed:**
113
+ ```bash
114
+ mkdir -p .goopspec
115
+ ```
116
+
117
+ **1.4 Search memory for context:**
118
+ ```
119
+ memory_search({ query: "project preferences architecture [user's topic]", limit: 5 })
120
+ ```
121
+
122
+ Store relevant findings - use them to skip questions you already know answers to.
123
+
124
+ ### Phase 2: Discovery Interview
125
+
126
+ **Display stage banner:**
127
+ ```
128
+ ## ๐Ÿ”ฎ GoopSpec ยท Discovery Interview
129
+
130
+ Let's nail down the requirements before planning.
131
+ I'll ask six key questions to understand your needs.
132
+
133
+ ---
134
+ ```
135
+
136
+ **2.1 Open the conversation:**
137
+
138
+ If `$ARGUMENTS` provided:
139
+ > "You want to **[argument]**. Let me understand this better."
140
+
141
+ Otherwise:
142
+ > "What do you want to build?"
143
+
144
+ **2.2 Work through the six questions:**
145
+
146
+ Ask naturally, not as a checklist. Weave questions based on their responses.
147
+
148
+ **Memory-first protocol:**
149
+ Before asking ANYTHING:
150
+ 1. Check memory: `memory_search({ query: "[topic] preference" })`
151
+ 2. If found: "I recall you prefer X for this. Still true? [Y/n]"
152
+ 3. If not found: Ask, then SAVE the answer with `memory_note`
153
+
154
+ **2.3 Probe for specifics:**
155
+
156
+ | Vague Answer | Follow-up |
157
+ |--------------|-----------|
158
+ | "It should be fast" | "What's the target? Sub-100ms? Sub-1s?" |
159
+ | "Standard auth" | "JWT? Sessions? OAuth? What's the token TTL?" |
160
+ | "Good UX" | "What does that mean for this feature? Animations? Accessibility level?" |
161
+
162
+ **2.4 Checklist tracker (internal):**
163
+
164
+ Track progress through the six questions:
165
+ - [ ] Vision defined (goal, problem, users)
166
+ - [ ] Must-haves listed (at least 1)
167
+ - [ ] Constraints documented (stack, performance)
168
+ - [ ] Out of scope defined (at least 1 item)
169
+ - [ ] Assumptions listed
170
+ - [ ] Risks identified (at least 1 with mitigation)
171
+
172
+ **2.5 Completion check:**
173
+
174
+ When all six questions are answered, confirm:
175
+
176
+ Use `question` tool:
177
+ - header: "Discovery Check"
178
+ - question: "I think I have what I need. Let me summarize..."
179
+ - options:
180
+ - "Looks good, proceed" โ€” Generate REQUIREMENTS.md
181
+ - "I want to add more" โ€” Continue discussion
182
+ - "Start over" โ€” Clear and restart interview
183
+
184
+ ### Phase 3: Generate REQUIREMENTS.md
185
+
186
+ **Display stage banner:**
187
+ ```
188
+ ## ๐Ÿ”ฎ GoopSpec ยท Saving Discovery
189
+
190
+ โณ Generating REQUIREMENTS.md...
191
+
192
+ ---
193
+ ```
194
+
195
+ **3.1 Create REQUIREMENTS.md:**
196
+
197
+ Write directly (orchestrator can write planning docs):
198
+
199
+ ```markdown
200
+ # REQUIREMENTS: [Feature Name]
201
+
202
+ **Generated:** [timestamp]
203
+ **Interview Status:** Complete
204
+ **Ready for Planning:** Yes
205
+
206
+ ---
207
+
208
+ ## Vision
209
+
210
+ [Vision statement from interview]
211
+
212
+ **Problem Solved:** [From interview]
213
+
214
+ **Why Now:** [From interview]
215
+
216
+ ---
217
+
218
+ ## Must-Haves (The Contract)
219
+
220
+ - [ ] **MH1**: [Title]
221
+ - [Description]
222
+ - **Acceptance:** [Criteria]
223
+
224
+ - [ ] **MH2**: [Title]
225
+ - [Description]
226
+ - **Acceptance:** [Criteria]
227
+
228
+ ---
229
+
230
+ ## Out of Scope
231
+
232
+ - **[Item]** โ€” [Reason]
233
+ - **[Item]** โ€” [Reason]
234
+
235
+ ---
236
+
237
+ ## Constraints
238
+
239
+ ### Technical Constraints
240
+ - [Stack, frameworks, versions]
241
+
242
+ ### Practical Constraints
243
+ - [Timeline, resources]
244
+
245
+ ---
246
+
247
+ ## Assumptions
248
+
249
+ - **[Assumption]** โ€” If false: [Impact]
250
+
251
+ ---
252
+
253
+ ## Risks & Mitigations
254
+
255
+ | Risk | Impact | Likelihood | Mitigation |
256
+ |------|--------|------------|------------|
257
+ | [Risk] | [H/M/L] | [H/M/L] | [Plan] |
258
+
259
+ ---
260
+
261
+ *Discovery interview completed. Ready for /goop-plan.*
262
+ ```
263
+
264
+ **3.2 Mark interview complete (using goop_state tool):**
265
+
266
+ ```
267
+ goop_state({ action: "complete-interview" })
268
+ ```
269
+
270
+ This atomically updates the workflow state. **NEVER edit state.json directly.**
271
+
272
+ **3.3 Save to memory:**
273
+
274
+ ```
275
+ memory_save({
276
+ type: "note",
277
+ title: "Discovery: [Feature Name]",
278
+ content: "[Summary of key requirements and constraints]",
279
+ concepts: ["discovery", "requirements", "[domain]"],
280
+ importance: 0.7
281
+ })
282
+ ```
283
+
284
+ ### Phase 4: Completion
285
+
286
+ **Display completion banner:**
287
+
288
+ ```
289
+ ## ๐Ÿ”ฎ GoopSpec ยท Discovery Complete
290
+
291
+ โœจ Requirements captured successfully
292
+
293
+ **Feature:** [Name]
294
+
295
+ | Question | Status |
296
+ |----------|--------|
297
+ | Vision | โœ“ Defined |
298
+ | Must-Haves | โœ“ [N] items |
299
+ | Constraints | โœ“ Documented |
300
+ | Out of Scope | โœ“ [M] items |
301
+ | Assumptions | โœ“ Listed |
302
+ | Risks | โœ“ [P] identified |
303
+
304
+ ### Next Step
305
+
306
+ **Create the blueprint** โ€” Transform requirements into an execution plan
307
+
308
+ โ†’ `/goop-plan`
309
+
310
+ ---
311
+
312
+ **Also available:**
313
+ - `cat .goopspec/REQUIREMENTS.md` โ€” Review discovery output
314
+ - `/goop-research [topic]` โ€” Investigate unknowns first
315
+ ```
316
+
317
+ ## Output
318
+
319
+ | File | Purpose |
320
+ |------|---------|
321
+ | `.goopspec/REQUIREMENTS.md` | Discovery interview output |
322
+ | State (via goop_state) | Updated with `interviewComplete: true` |
323
+
324
+ ## Transitions
325
+
326
+ | Outcome | Next Step |
327
+ |---------|-----------|
328
+ | Discovery complete | `/goop-plan` to create blueprint |
329
+ | Unknowns found | `/goop-research` to investigate |
330
+ | Small task | `/goop-quick` to skip planning |
331
+
332
+ ## Bypass Conditions
333
+
334
+ Discovery MAY be skipped only for:
335
+ - `/goop-quick` small tasks (single file, < 30 min work)
336
+ - Bug fixes with clear reproduction steps
337
+ - Documentation-only changes
338
+
339
+ ## Examples
340
+
341
+ **Simple Feature:**
342
+ ```
343
+ User: /goop-discuss add dark mode toggle
344
+
345
+ Orchestrator: "Dark mode toggle. Let me understand what you need.
346
+
347
+ **Vision:** What's the goal here?
348
+ - Toggle in settings that switches the app theme
349
+ - Persist preference across sessions
350
+ - Respect system preference as default
351
+
352
+ **Must-haves:** What MUST work?
353
+ - Toggle UI in settings
354
+ - Theme actually changes
355
+ - Persists to localStorage
356
+
357
+ **Out of scope?**
358
+ - Per-component theme overrides
359
+ - Multiple theme options beyond light/dark
360
+
361
+ **Constraints?**
362
+ - Using existing Tailwind dark: classes
363
+ - No new dependencies
364
+
365
+ **Assumptions?**
366
+ - CSS already has dark variants (will verify)
367
+
368
+ **Risks?**
369
+ - Some components may not have dark styles โ†’ will audit first
370
+
371
+ Great, I have what I need. Creating REQUIREMENTS.md..."
372
+ ```
373
+
374
+ **Complex Feature:**
375
+ ```
376
+ User: /goop-discuss rebuild the payment system
377
+
378
+ Orchestrator: "Payment system rebuild - that's significant.
379
+ Let me understand the scope.
380
+
381
+ **Vision:** What's driving this?
382
+ - Current system uses deprecated Stripe API
383
+ - Need to add PayPal as alternative
384
+ - Improve error handling and retry logic
385
+
386
+ **Must-haves:**
387
+ - Migrate to Stripe v2 API
388
+ - Add PayPal integration
389
+ - Unified payment interface
390
+ - Retry with exponential backoff
391
+ - Webhook handling for async payments
392
+
393
+ **Out of scope:**
394
+ - Cryptocurrency payments (future)
395
+ - Subscription management (separate project)
396
+
397
+ **Risks:**
398
+ - Stripe migration may have breaking changes โ†’ research first
399
+ - PayPal integration complexity unknown โ†’ estimate 2x buffer
400
+
401
+ I'd recommend running `/goop-research stripe v2 migration` before
402
+ planning. Want to do that first?"
403
+ ```
404
+
405
+ ## Success Criteria
406
+
407
+ - [ ] All six questions answered with specifics
408
+ - [ ] At least 1 must-have defined
409
+ - [ ] At least 1 out-of-scope item defined
410
+ - [ ] At least 1 risk with mitigation
411
+ - [ ] REQUIREMENTS.md created
412
+ - [ ] State updated via `goop_state({ action: "complete-interview" })`
413
+ - [ ] User knows next step is `/goop-plan`
414
+
415
+ ## Anti-Patterns
416
+
417
+ **DON'T:**
418
+ - Accept vague answers ("it should be good")
419
+ - Skip the risks question ("nothing could go wrong")
420
+ - Rush through to get to coding
421
+ - Spawn agents to conduct the interview
422
+ - Create SPEC.md directly (that's /goop-plan's job)
423
+
424
+ **DO:**
425
+ - Probe vague answers for specifics
426
+ - Challenge "no risks" with scenarios
427
+ - Take time - discovery is highest leverage
428
+ - Conduct interview yourself (keeps context)
429
+ - Save answers to memory for future reference
430
+
431
+ ---
21
432
 
22
- See [/goop-plan](./goop-plan.md) for details.
433
+ *Discovery Interview Protocol v0.1.5*
434
+ *"Nail the spec before you write the code."*