@ktpartners/dgs-platform 2.6.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +38 -0
- package/README.md +851 -0
- package/agents/dgs-codebase-cross-analyzer.md +183 -0
- package/agents/dgs-codebase-mapper.md +782 -0
- package/agents/dgs-codebase-synthesizer.md +156 -0
- package/agents/dgs-debugger.md +1256 -0
- package/agents/dgs-executor.md +550 -0
- package/agents/dgs-integration-checker.md +481 -0
- package/agents/dgs-nyquist-auditor.md +178 -0
- package/agents/dgs-phase-researcher.md +563 -0
- package/agents/dgs-phase-verifier.md +450 -0
- package/agents/dgs-plan-checker.md +708 -0
- package/agents/dgs-planner.md +1324 -0
- package/agents/dgs-project-researcher.md +631 -0
- package/agents/dgs-research-synthesizer.md +249 -0
- package/agents/dgs-roadmapper.md +652 -0
- package/agents/dgs-verifier.md +607 -0
- package/bin/install.js +2073 -0
- package/commands/dgs/add-doc.md +45 -0
- package/commands/dgs/add-idea.md +38 -0
- package/commands/dgs/add-phase.md +43 -0
- package/commands/dgs/add-repo.md +54 -0
- package/commands/dgs/add-tests.md +41 -0
- package/commands/dgs/add-todo.md +47 -0
- package/commands/dgs/approve-spec.md +38 -0
- package/commands/dgs/audit-milestone.md +36 -0
- package/commands/dgs/audit-phase.md +37 -0
- package/commands/dgs/cancel-job.md +23 -0
- package/commands/dgs/capture-principle.md +143 -0
- package/commands/dgs/check-todos.md +45 -0
- package/commands/dgs/cleanup.md +18 -0
- package/commands/dgs/complete-milestone.md +136 -0
- package/commands/dgs/complete-project.md +70 -0
- package/commands/dgs/consolidate-ideas.md +50 -0
- package/commands/dgs/create-milestone-job.md +37 -0
- package/commands/dgs/debug.md +164 -0
- package/commands/dgs/develop-idea.md +53 -0
- package/commands/dgs/discuss-idea.md +41 -0
- package/commands/dgs/discuss-phase.md +83 -0
- package/commands/dgs/execute-phase.md +41 -0
- package/commands/dgs/fast.md +38 -0
- package/commands/dgs/find-related-ideas.md +43 -0
- package/commands/dgs/health.md +28 -0
- package/commands/dgs/help.md +22 -0
- package/commands/dgs/import-spec.md +36 -0
- package/commands/dgs/init-product.md +28 -0
- package/commands/dgs/insert-phase.md +32 -0
- package/commands/dgs/join-discord.md +18 -0
- package/commands/dgs/list-docs.md +40 -0
- package/commands/dgs/list-ideas.md +42 -0
- package/commands/dgs/list-jobs.md +22 -0
- package/commands/dgs/list-phase-assumptions.md +46 -0
- package/commands/dgs/list-projects.md +57 -0
- package/commands/dgs/list-specs.md +40 -0
- package/commands/dgs/map-codebase.md +92 -0
- package/commands/dgs/new-milestone.md +44 -0
- package/commands/dgs/new-project.md +42 -0
- package/commands/dgs/node-repair.md +26 -0
- package/commands/dgs/overlap-check.md +20 -0
- package/commands/dgs/pause-work.md +38 -0
- package/commands/dgs/plan-milestone-gaps.md +34 -0
- package/commands/dgs/plan-phase.md +44 -0
- package/commands/dgs/progress.md +24 -0
- package/commands/dgs/quick.md +41 -0
- package/commands/dgs/reactivate-project.md +70 -0
- package/commands/dgs/reapply-patches.md +110 -0
- package/commands/dgs/refine-spec.md +38 -0
- package/commands/dgs/reject-idea.md +43 -0
- package/commands/dgs/remove-doc.md +44 -0
- package/commands/dgs/remove-phase.md +31 -0
- package/commands/dgs/remove-repo.md +69 -0
- package/commands/dgs/research-idea.md +43 -0
- package/commands/dgs/research-phase.md +189 -0
- package/commands/dgs/restore-idea.md +45 -0
- package/commands/dgs/resume-work.md +40 -0
- package/commands/dgs/rollback-job.md +24 -0
- package/commands/dgs/run-job.md +35 -0
- package/commands/dgs/search.md +40 -0
- package/commands/dgs/set-profile.md +34 -0
- package/commands/dgs/settings.md +38 -0
- package/commands/dgs/switch-project.md +58 -0
- package/commands/dgs/undo-consolidation.md +42 -0
- package/commands/dgs/update-idea.md +44 -0
- package/commands/dgs/update.md +37 -0
- package/commands/dgs/validate-phase.md +35 -0
- package/commands/dgs/verify-work.md +39 -0
- package/commands/dgs/write-spec.md +49 -0
- package/deliver-great-systems/.planning/phases/09-backend-wiring-and-error-handling/09-01-SUMMARY.md +84 -0
- package/deliver-great-systems/.planning/phases/09-backend-wiring-and-error-handling/09-02-SUMMARY.md +86 -0
- package/deliver-great-systems/.planning/phases/10-v1-to-v2-migration-flow/10-01-SUMMARY.md +85 -0
- package/deliver-great-systems/bin/dgs-tools.cjs +1444 -0
- package/deliver-great-systems/bin/lib/auto-test.cjs +1365 -0
- package/deliver-great-systems/bin/lib/commands.cjs +570 -0
- package/deliver-great-systems/bin/lib/config.cjs +417 -0
- package/deliver-great-systems/bin/lib/conflict-agent.cjs +1063 -0
- package/deliver-great-systems/bin/lib/conflict-agent.test.cjs +554 -0
- package/deliver-great-systems/bin/lib/context.cjs +929 -0
- package/deliver-great-systems/bin/lib/context.test.cjs +693 -0
- package/deliver-great-systems/bin/lib/core.cjs +744 -0
- package/deliver-great-systems/bin/lib/core.test.cjs +822 -0
- package/deliver-great-systems/bin/lib/docs.cjs +919 -0
- package/deliver-great-systems/bin/lib/docs.test.cjs +211 -0
- package/deliver-great-systems/bin/lib/execution.cjs +705 -0
- package/deliver-great-systems/bin/lib/execution.test.cjs +1472 -0
- package/deliver-great-systems/bin/lib/frontmatter.cjs +324 -0
- package/deliver-great-systems/bin/lib/ideas.cjs +1406 -0
- package/deliver-great-systems/bin/lib/ideas.test.cjs +1417 -0
- package/deliver-great-systems/bin/lib/identity.cjs +125 -0
- package/deliver-great-systems/bin/lib/init.cjs +1114 -0
- package/deliver-great-systems/bin/lib/init.test.cjs +1271 -0
- package/deliver-great-systems/bin/lib/jobs.cjs +2015 -0
- package/deliver-great-systems/bin/lib/jobs.test.cjs +2619 -0
- package/deliver-great-systems/bin/lib/merge-conflicts.cjs +654 -0
- package/deliver-great-systems/bin/lib/merge-conflicts.test.cjs +370 -0
- package/deliver-great-systems/bin/lib/migration.cjs +352 -0
- package/deliver-great-systems/bin/lib/migration.test.cjs +582 -0
- package/deliver-great-systems/bin/lib/milestone.cjs +243 -0
- package/deliver-great-systems/bin/lib/overlap.cjs +437 -0
- package/deliver-great-systems/bin/lib/overlap.test.cjs +747 -0
- package/deliver-great-systems/bin/lib/path-audit.test.cjs +384 -0
- package/deliver-great-systems/bin/lib/paths.cjs +144 -0
- package/deliver-great-systems/bin/lib/paths.test.cjs +486 -0
- package/deliver-great-systems/bin/lib/phase.cjs +910 -0
- package/deliver-great-systems/bin/lib/projects.cjs +691 -0
- package/deliver-great-systems/bin/lib/projects.test.cjs +871 -0
- package/deliver-great-systems/bin/lib/repos.cjs +1432 -0
- package/deliver-great-systems/bin/lib/repos.test.cjs +1882 -0
- package/deliver-great-systems/bin/lib/roadmap.cjs +305 -0
- package/deliver-great-systems/bin/lib/search.cjs +570 -0
- package/deliver-great-systems/bin/lib/specs.cjs +1303 -0
- package/deliver-great-systems/bin/lib/state.cjs +893 -0
- package/deliver-great-systems/bin/lib/template.cjs +228 -0
- package/deliver-great-systems/bin/lib/test-helpers.cjs +291 -0
- package/deliver-great-systems/bin/lib/verify.cjs +796 -0
- package/deliver-great-systems/references/checkpoints.md +776 -0
- package/deliver-great-systems/references/conflict-resolution.md +66 -0
- package/deliver-great-systems/references/context-tiers.md +166 -0
- package/deliver-great-systems/references/continuation-format.md +249 -0
- package/deliver-great-systems/references/decimal-phase-calculation.md +67 -0
- package/deliver-great-systems/references/git-integration.md +250 -0
- package/deliver-great-systems/references/git-planning-commit.md +40 -0
- package/deliver-great-systems/references/model-profile-resolution.md +36 -0
- package/deliver-great-systems/references/model-profiles.md +95 -0
- package/deliver-great-systems/references/phase-argument-parsing.md +61 -0
- package/deliver-great-systems/references/planning-config.md +224 -0
- package/deliver-great-systems/references/questioning.md +162 -0
- package/deliver-great-systems/references/spec-review-loop.md +177 -0
- package/deliver-great-systems/references/tdd.md +265 -0
- package/deliver-great-systems/references/ui-brand.md +160 -0
- package/deliver-great-systems/references/verification-patterns.md +612 -0
- package/deliver-great-systems/templates/DEBUG.md +166 -0
- package/deliver-great-systems/templates/UAT.md +251 -0
- package/deliver-great-systems/templates/VALIDATION.md +95 -0
- package/deliver-great-systems/templates/claude-md.md +74 -0
- package/deliver-great-systems/templates/codebase/architecture.md +257 -0
- package/deliver-great-systems/templates/codebase/concerns.md +312 -0
- package/deliver-great-systems/templates/codebase/conventions.md +309 -0
- package/deliver-great-systems/templates/codebase/integrations.md +282 -0
- package/deliver-great-systems/templates/codebase/stack.md +188 -0
- package/deliver-great-systems/templates/codebase/structure.md +287 -0
- package/deliver-great-systems/templates/codebase/testing.md +482 -0
- package/deliver-great-systems/templates/config.json +38 -0
- package/deliver-great-systems/templates/context.md +354 -0
- package/deliver-great-systems/templates/continue-here.md +80 -0
- package/deliver-great-systems/templates/debug-subagent-prompt.md +93 -0
- package/deliver-great-systems/templates/discovery.md +148 -0
- package/deliver-great-systems/templates/milestone-archive.md +125 -0
- package/deliver-great-systems/templates/milestone.md +117 -0
- package/deliver-great-systems/templates/phase-prompt.md +615 -0
- package/deliver-great-systems/templates/planner-subagent-prompt.md +119 -0
- package/deliver-great-systems/templates/project.md +186 -0
- package/deliver-great-systems/templates/requirements.md +233 -0
- package/deliver-great-systems/templates/research-project/ARCHITECTURE.md +206 -0
- package/deliver-great-systems/templates/research-project/FEATURES.md +149 -0
- package/deliver-great-systems/templates/research-project/PITFALLS.md +202 -0
- package/deliver-great-systems/templates/research-project/STACK.md +122 -0
- package/deliver-great-systems/templates/research-project/SUMMARY.md +172 -0
- package/deliver-great-systems/templates/research.md +554 -0
- package/deliver-great-systems/templates/retrospective.md +54 -0
- package/deliver-great-systems/templates/roadmap.md +204 -0
- package/deliver-great-systems/templates/state.md +178 -0
- package/deliver-great-systems/templates/summary-complex.md +59 -0
- package/deliver-great-systems/templates/summary-minimal.md +41 -0
- package/deliver-great-systems/templates/summary-standard.md +48 -0
- package/deliver-great-systems/templates/summary.md +253 -0
- package/deliver-great-systems/templates/user-setup.md +313 -0
- package/deliver-great-systems/templates/verification-report.md +324 -0
- package/deliver-great-systems/workflows/add-doc.md +151 -0
- package/deliver-great-systems/workflows/add-idea.md +96 -0
- package/deliver-great-systems/workflows/add-phase.md +120 -0
- package/deliver-great-systems/workflows/add-tests.md +359 -0
- package/deliver-great-systems/workflows/add-todo.md +162 -0
- package/deliver-great-systems/workflows/approve-spec.md +194 -0
- package/deliver-great-systems/workflows/audit-milestone.md +364 -0
- package/deliver-great-systems/workflows/audit-phase.md +462 -0
- package/deliver-great-systems/workflows/cancel-job.md +108 -0
- package/deliver-great-systems/workflows/check-todos.md +181 -0
- package/deliver-great-systems/workflows/cleanup.md +247 -0
- package/deliver-great-systems/workflows/codereview.md +526 -0
- package/deliver-great-systems/workflows/complete-milestone.md +1298 -0
- package/deliver-great-systems/workflows/consolidate-ideas.md +365 -0
- package/deliver-great-systems/workflows/create-milestone-job.md +177 -0
- package/deliver-great-systems/workflows/develop-idea.md +544 -0
- package/deliver-great-systems/workflows/diagnose-issues.md +231 -0
- package/deliver-great-systems/workflows/discovery-phase.md +301 -0
- package/deliver-great-systems/workflows/discuss-idea.md +263 -0
- package/deliver-great-systems/workflows/discuss-phase.md +733 -0
- package/deliver-great-systems/workflows/execute-phase.md +571 -0
- package/deliver-great-systems/workflows/execute-plan.md +592 -0
- package/deliver-great-systems/workflows/find-related-ideas.md +271 -0
- package/deliver-great-systems/workflows/health.md +173 -0
- package/deliver-great-systems/workflows/help.md +997 -0
- package/deliver-great-systems/workflows/import-spec.md +381 -0
- package/deliver-great-systems/workflows/init-product.md +767 -0
- package/deliver-great-systems/workflows/insert-phase.md +138 -0
- package/deliver-great-systems/workflows/list-docs.md +119 -0
- package/deliver-great-systems/workflows/list-ideas.md +154 -0
- package/deliver-great-systems/workflows/list-jobs.md +89 -0
- package/deliver-great-systems/workflows/list-phase-assumptions.md +192 -0
- package/deliver-great-systems/workflows/list-specs.md +101 -0
- package/deliver-great-systems/workflows/map-codebase.md +621 -0
- package/deliver-great-systems/workflows/new-milestone.md +591 -0
- package/deliver-great-systems/workflows/new-project.md +1113 -0
- package/deliver-great-systems/workflows/node-repair.md +94 -0
- package/deliver-great-systems/workflows/overlap-check.md +86 -0
- package/deliver-great-systems/workflows/pause-work.md +134 -0
- package/deliver-great-systems/workflows/plan-milestone-gaps.md +306 -0
- package/deliver-great-systems/workflows/plan-phase.md +698 -0
- package/deliver-great-systems/workflows/progress.md +386 -0
- package/deliver-great-systems/workflows/quick.md +845 -0
- package/deliver-great-systems/workflows/refine-spec.md +275 -0
- package/deliver-great-systems/workflows/reject-idea.md +109 -0
- package/deliver-great-systems/workflows/remove-doc.md +117 -0
- package/deliver-great-systems/workflows/remove-phase.md +163 -0
- package/deliver-great-systems/workflows/research-idea.md +325 -0
- package/deliver-great-systems/workflows/research-phase.md +81 -0
- package/deliver-great-systems/workflows/restore-idea.md +101 -0
- package/deliver-great-systems/workflows/resume-project.md +311 -0
- package/deliver-great-systems/workflows/rollback-job.md +130 -0
- package/deliver-great-systems/workflows/run-job.md +498 -0
- package/deliver-great-systems/workflows/search.md +130 -0
- package/deliver-great-systems/workflows/set-profile.md +83 -0
- package/deliver-great-systems/workflows/settings.md +470 -0
- package/deliver-great-systems/workflows/transition.md +563 -0
- package/deliver-great-systems/workflows/undo-consolidation.md +155 -0
- package/deliver-great-systems/workflows/update-idea.md +157 -0
- package/deliver-great-systems/workflows/update.md +242 -0
- package/deliver-great-systems/workflows/validate-phase.md +177 -0
- package/deliver-great-systems/workflows/verify-phase.md +253 -0
- package/deliver-great-systems/workflows/verify-work.md +671 -0
- package/deliver-great-systems/workflows/write-spec.md +450 -0
- package/hooks/dist/dgs-check-update.js +62 -0
- package/hooks/dist/dgs-context-monitor.js +141 -0
- package/hooks/dist/dgs-statusline.js +115 -0
- package/package.json +60 -0
- package/scripts/build-hooks.js +43 -0
|
@@ -0,0 +1,263 @@
|
|
|
1
|
+
<purpose>
|
|
2
|
+
Structured, inline conversational workflow for developing and refining an idea. Walks through Understanding, Exploration, and Refinement phases as a thinking partner -- collaborative, opinionated, pushing back like a cofounder brainstorming. The three phases are a framework for Claude, not a visible structure imposed on the user.
|
|
3
|
+
|
|
4
|
+
Produces a Discussion Log entry in the idea file, commits the result, and suggests next steps based on the agreed Decision tag. When re-discussing a previously-discussed idea, builds on the prior log by jumping straight to unresolved Open Questions.
|
|
5
|
+
</purpose>
|
|
6
|
+
|
|
7
|
+
<context_tier>planning</context_tier>
|
|
8
|
+
|
|
9
|
+
<required_reading>
|
|
10
|
+
Read all files referenced by the invoking prompt's execution_context before starting.
|
|
11
|
+
</required_reading>
|
|
12
|
+
|
|
13
|
+
<process>
|
|
14
|
+
|
|
15
|
+
<step name="load_context" priority="first">
|
|
16
|
+
Load planning-tier context files with idea scope:
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
TIER_FILES=$(node "$HOME/.claude/deliver-great-systems/bin/dgs-tools.cjs" context load-tier planning --raw 2>/dev/null)
|
|
20
|
+
```
|
|
21
|
+
</step>
|
|
22
|
+
|
|
23
|
+
<step name="parse_arguments">
|
|
24
|
+
Parse `$ARGUMENTS` for an idea ID.
|
|
25
|
+
|
|
26
|
+
- First positional argument: treat as idea ID (e.g., `/dgs:discuss-idea 5` -> id=5)
|
|
27
|
+
- Named flag: `--id N` (e.g., `/dgs:discuss-idea --id 5` -> id=5)
|
|
28
|
+
|
|
29
|
+
If no ID provided, list pending ideas and prompt for selection:
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
PENDING=$(node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs ideas list --state pending --raw)
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
Parse the JSON `ideas` array.
|
|
36
|
+
|
|
37
|
+
**If empty:**
|
|
38
|
+
```
|
|
39
|
+
No pending ideas to discuss. Run /dgs:add-idea to capture one.
|
|
40
|
+
```
|
|
41
|
+
Exit workflow.
|
|
42
|
+
|
|
43
|
+
**If ideas exist:** Display them as a numbered list showing ID, title, and tags. Use AskUserQuestion:
|
|
44
|
+
- header: "Select Idea"
|
|
45
|
+
- question: "Which idea would you like to discuss?"
|
|
46
|
+
- Provide the numbered idea options
|
|
47
|
+
|
|
48
|
+
Extract the selected idea's ID.
|
|
49
|
+
</step>
|
|
50
|
+
|
|
51
|
+
<step name="load_idea">
|
|
52
|
+
Load the full idea content by ID:
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
LIST=$(node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs ideas list --raw)
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Find the idea in the JSON by matching `id`. If not found:
|
|
59
|
+
```
|
|
60
|
+
Idea #${id} not found.
|
|
61
|
+
```
|
|
62
|
+
Exit workflow.
|
|
63
|
+
|
|
64
|
+
Read the idea file directly using the `path` from the list result to get the full content including Discussion Log, Research Log, Notes, and body.
|
|
65
|
+
|
|
66
|
+
Set variables from the parsed content:
|
|
67
|
+
- `id` -- idea ID
|
|
68
|
+
- `title` -- idea title
|
|
69
|
+
- `body` -- idea body/problem statement
|
|
70
|
+
- `tags` -- tags array
|
|
71
|
+
- `notes` -- Notes section content (if any)
|
|
72
|
+
- `state` -- current state (pending, done, rejected)
|
|
73
|
+
- `filename` -- file name
|
|
74
|
+
- `path` -- file path
|
|
75
|
+
- `discussionLog` -- Discussion Log section content (if any)
|
|
76
|
+
- `researchLog` -- Research Log section content (if any)
|
|
77
|
+
|
|
78
|
+
**Load idea supporting documents:**
|
|
79
|
+
|
|
80
|
+
Derive the idea's docs directory path from the idea's file path:
|
|
81
|
+
```bash
|
|
82
|
+
IDEA_DIR=$(dirname "${path}")
|
|
83
|
+
IDEA_DOCS_DIR="${IDEA_DIR}/docs"
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
If a flat structure is used (ideas stored as files, not directories), derive from the filename:
|
|
87
|
+
```bash
|
|
88
|
+
IDEA_SLUG=$(echo "${filename}" | sed 's/^[0-9]*-//' | sed 's/\.md$//')
|
|
89
|
+
IDEA_DOCS_DIR="$(dirname "$(dirname "${path}")")/docs/ideas/pending/${IDEA_SLUG}"
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Check both paths. Use whichever exists.
|
|
93
|
+
|
|
94
|
+
If the docs/ directory exists, list its contents:
|
|
95
|
+
```bash
|
|
96
|
+
ls "${IDEA_DOCS_DIR}/" 2>/dev/null
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
For each file found, apply the standard docs/ loading pattern:
|
|
100
|
+
- **Text files** (.md, .txt, .json, .yaml, .yml): Read using the Read tool.
|
|
101
|
+
- **Image files** (.png, .jpg, .jpeg, .gif, .svg, .webp): Read using the Read tool directly for multimodal context. Cap at 5 images per idea.
|
|
102
|
+
- **PDF files** (.pdf): Prefer .txt sidecar (same directory, same basename with .txt extension). If sidecar exists, read it. If no sidecar, read up to 5 pages via Read tool with `pages` parameter.
|
|
103
|
+
- **Other files**: Skip silently.
|
|
104
|
+
|
|
105
|
+
If the docs/ directory does not exist: silent skip -- no docs is normal, do not mention it.
|
|
106
|
+
If any file is unreadable: skip silently -- do not mention files that cannot be read.
|
|
107
|
+
|
|
108
|
+
Store loaded docs content as `ideaDocs` for use in the discussion.
|
|
109
|
+
</step>
|
|
110
|
+
|
|
111
|
+
<step name="discussion_context">
|
|
112
|
+
Present the idea to yourself (Claude) as working context.
|
|
113
|
+
|
|
114
|
+
**For a new discussion** (no prior Discussion Log):
|
|
115
|
+
Internalize the idea's title, body, tags, any notes, and loaded supporting documents. This is the raw material for discussion.
|
|
116
|
+
|
|
117
|
+
If `ideaDocs` is not empty, include in the internalized context: "Supporting documents available: [list filenames]". Reference specific docs during the discussion when relevant (e.g., "Looking at the diagram in architecture.png...").
|
|
118
|
+
|
|
119
|
+
**For a re-discussion** (prior Discussion Log exists):
|
|
120
|
+
Review the prior discussion entries. Identify:
|
|
121
|
+
- Open Questions from the most recent entry -- these are the starting point
|
|
122
|
+
- Prior Decisions -- these are context but not necessarily locked. Use discretion on whether to revisit based on new information
|
|
123
|
+
- Key Insights from prior sessions -- build on these, don't repeat them
|
|
124
|
+
- If `ideaDocs` is not empty, note any supporting documents that may inform open questions or add new context since the last discussion
|
|
125
|
+
|
|
126
|
+
Each re-discussion produces its own fresh Decision tag regardless of prior status.
|
|
127
|
+
</step>
|
|
128
|
+
|
|
129
|
+
<step name="understanding_phase">
|
|
130
|
+
**Tone: Thinking partner, collaborative, opinionated -- like a cofounder brainstorming.**
|
|
131
|
+
|
|
132
|
+
**For a new discussion** (no prior log):
|
|
133
|
+
Restate the idea in your own words to confirm understanding. Then ask clarifying questions about the problem:
|
|
134
|
+
- Who has this problem? How often do they hit it?
|
|
135
|
+
- What's the current workaround?
|
|
136
|
+
- What does success look like?
|
|
137
|
+
|
|
138
|
+
Challenge vague problem statements and push for specifics. Adapt depth to idea complexity -- simple ideas get quick understanding (1-2 exchanges), complex ideas get deeper probing (3-4 exchanges).
|
|
139
|
+
|
|
140
|
+
**For a re-discussion** (prior log exists):
|
|
141
|
+
Jump straight to unresolved Open Questions from the last session. Skip restating and re-clarifying unless the prior understanding seems incomplete or wrong.
|
|
142
|
+
|
|
143
|
+
Use AskUserQuestion for each turn of dialogue. Continue until the problem is well-defined.
|
|
144
|
+
|
|
145
|
+
**Mid-exit handling:** If the user indicates they want to exit (says "done", "save", "exit", "stop", or changes topic), go to step handle_exit.
|
|
146
|
+
</step>
|
|
147
|
+
|
|
148
|
+
<step name="exploration_phase">
|
|
149
|
+
Proactively raise considerations the user may not have thought of:
|
|
150
|
+
- Alternative approaches to the problem
|
|
151
|
+
- Potential conflicts with existing functionality (use Grep/Glob to check the codebase if the idea relates to existing features)
|
|
152
|
+
- Scope concerns -- is this bigger than it seems?
|
|
153
|
+
- Edge cases and failure modes
|
|
154
|
+
- Dependencies or prerequisites
|
|
155
|
+
|
|
156
|
+
When one option is clearly better, recommend it with reasoning. Otherwise present options neutrally and let the user decide.
|
|
157
|
+
|
|
158
|
+
Continue the back-and-forth dialogue with AskUserQuestion. The developer steers the conversation -- follow their lead on what to explore deeper.
|
|
159
|
+
|
|
160
|
+
**Mid-exit handling:** If the user indicates they want to exit, go to step handle_exit.
|
|
161
|
+
</step>
|
|
162
|
+
|
|
163
|
+
<step name="refinement_phase">
|
|
164
|
+
Propose a refined version of the idea:
|
|
165
|
+
|
|
166
|
+
1. **Refined problem statement** -- sharper, more specific than the original
|
|
167
|
+
2. **Updated approach** -- incorporating insights from the discussion
|
|
168
|
+
3. **Open questions** -- questions that emerged during discussion and remain unresolved
|
|
169
|
+
|
|
170
|
+
Present this as a proposal for user review. Propose a Decision tag -- one of:
|
|
171
|
+
- **"Ready for research"** -- idea is well-defined, needs feasibility/landscape investigation
|
|
172
|
+
- **"Ready for spec"** -- idea is clear enough to write a formal specification
|
|
173
|
+
- **"Needs more thought"** -- idea has merit but unresolved questions remain
|
|
174
|
+
|
|
175
|
+
Use AskUserQuestion to present the proposal and get approval.
|
|
176
|
+
|
|
177
|
+
**If user rejects the proposal:** Revise based on their feedback and present again (one revision attempt). If rejected a second time, save with "Needs more thought" as the Decision tag.
|
|
178
|
+
|
|
179
|
+
**Mid-exit handling:** If the user indicates they want to exit, go to step handle_exit.
|
|
180
|
+
</step>
|
|
181
|
+
|
|
182
|
+
<step name="handle_exit">
|
|
183
|
+
**This step handles mid-discussion exit from any of the discussion phases (understanding, exploration, refinement).**
|
|
184
|
+
|
|
185
|
+
When the user indicates they want to exit:
|
|
186
|
+
|
|
187
|
+
1. **Always save on exit** -- inform the user: "Saving your progress." Do NOT ask permission.
|
|
188
|
+
2. Use **"Needs more thought"** as the Decision tag for partial discussions.
|
|
189
|
+
3. Do **NOT** update the idea body on partial save -- only write the discussion log entry.
|
|
190
|
+
4. Format the partial save entry based on how far the discussion progressed:
|
|
191
|
+
- Exited during Understanding: capture what was clarified so far
|
|
192
|
+
- Exited during Exploration: capture clarifications plus alternatives/considerations raised
|
|
193
|
+
- Exited during Refinement: capture the near-complete refinement with a note that it was not finalized
|
|
194
|
+
|
|
195
|
+
Proceed to step save_discussion with `partial = true`.
|
|
196
|
+
</step>
|
|
197
|
+
|
|
198
|
+
<step name="save_discussion">
|
|
199
|
+
Generate the discussion entry fields:
|
|
200
|
+
|
|
201
|
+
- `date`: current date in YYYY-MM-DD format
|
|
202
|
+
- `keyInsights`: bullet-pointed list of key insights from the discussion (use `\n- ` separator for each bullet)
|
|
203
|
+
- `refinedProblem`: the refined problem statement (full discussion) or summary of what was discussed (partial)
|
|
204
|
+
- `refinedApproach`: the refined approach (full discussion) or "Not yet refined" (partial)
|
|
205
|
+
- `openQuestions`: bullet-pointed list of open questions (use `\n- ` separator for each bullet)
|
|
206
|
+
- `decision`: the agreed Decision tag (e.g., "Ready for research", "Ready for spec", "Needs more thought")
|
|
207
|
+
|
|
208
|
+
For **re-discussions**: reference what changed from prior discussion in the keyInsights (e.g., "Revised approach from X to Y").
|
|
209
|
+
|
|
210
|
+
Format as a JSON string and call:
|
|
211
|
+
```bash
|
|
212
|
+
node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs ideas discuss-save --id "${id}" --entry '${entryJson}'
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
The `entryJson` should be a JSON object with these fields:
|
|
216
|
+
```json
|
|
217
|
+
{
|
|
218
|
+
"date": "YYYY-MM-DD",
|
|
219
|
+
"keyInsights": "- insight one\n- insight two",
|
|
220
|
+
"refinedProblem": "The refined problem statement",
|
|
221
|
+
"refinedApproach": "The refined approach",
|
|
222
|
+
"openQuestions": "- question one\n- question two",
|
|
223
|
+
"decision": "Ready for research"
|
|
224
|
+
}
|
|
225
|
+
```
|
|
226
|
+
|
|
227
|
+
Parse the JSON result to confirm success.
|
|
228
|
+
|
|
229
|
+
**For FULL discussions only** (not partial saves): If the idea body or approach changed significantly during refinement, also update the idea body:
|
|
230
|
+
```bash
|
|
231
|
+
node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs ideas update --id "${id}" --field body --value "${refinedBody}"
|
|
232
|
+
```
|
|
233
|
+
|
|
234
|
+
Per CONTEXT.md: idea body is NOT updated on partial save.
|
|
235
|
+
</step>
|
|
236
|
+
|
|
237
|
+
<step name="git_commit">
|
|
238
|
+
Commit the updated idea file:
|
|
239
|
+
```bash
|
|
240
|
+
node ~/.claude/deliver-great-systems/bin/dgs-tools.cjs commit "docs: discuss idea #${id} — ${title}" --files ${path}
|
|
241
|
+
```
|
|
242
|
+
</step>
|
|
243
|
+
|
|
244
|
+
<step name="suggest_next">
|
|
245
|
+
Based on the Decision tag, suggest the next action:
|
|
246
|
+
|
|
247
|
+
- **"Ready for research"**: "Run `/dgs:research-idea ${id}` to investigate feasibility and landscape."
|
|
248
|
+
- **"Ready for spec"**: "Run `/dgs:write-spec` to create a formal spec from this idea."
|
|
249
|
+
- **"Needs more thought"**: "Run `/dgs:discuss-idea ${id}` again when you're ready to continue."
|
|
250
|
+
|
|
251
|
+
For re-discussions, if the Decision tag changed from the prior session, note the progression (e.g., "Progressed from 'Needs more thought' to 'Ready for research'").
|
|
252
|
+
</step>
|
|
253
|
+
|
|
254
|
+
</process>
|
|
255
|
+
|
|
256
|
+
<success_criteria>
|
|
257
|
+
- [ ] Idea loaded and displayed as context
|
|
258
|
+
- [ ] Three-phase discussion conducted (or partial if user exits early)
|
|
259
|
+
- [ ] Discussion log entry saved to idea file via discuss-save CLI
|
|
260
|
+
- [ ] Updated timestamp refreshed
|
|
261
|
+
- [ ] Git commit created with correct message format
|
|
262
|
+
- [ ] Next steps suggested based on Decision tag
|
|
263
|
+
</success_criteria>
|