@leeovery/claude-technical-workflows 2.1.42 → 2.2.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 (117) hide show
  1. package/hooks/workflows/compact-recovery.sh +3 -23
  2. package/hooks/workflows/write-session-state.sh +2 -26
  3. package/package.json +1 -1
  4. package/skills/link-dependencies/SKILL.md +0 -1
  5. package/skills/migrate/SKILL.md +0 -1
  6. package/skills/migrate/scripts/migrations/013-discussion-work-type.sh +76 -0
  7. package/skills/migrate/scripts/migrations/014-specification-work-type.sh +76 -0
  8. package/skills/migrate/scripts/migrations/015-plan-work-type.sh +76 -0
  9. package/skills/start-bugfix/SKILL.md +80 -0
  10. package/skills/start-bugfix/references/gather-bug-context.md +75 -0
  11. package/skills/start-bugfix/references/invoke-investigation.md +46 -0
  12. package/skills/start-bugfix/references/topic-name-check.md +59 -0
  13. package/skills/start-discussion/SKILL.md +51 -46
  14. package/skills/start-discussion/references/gather-context.md +54 -10
  15. package/skills/start-discussion/references/handle-selection.md +14 -4
  16. package/skills/start-discussion/references/invoke-skill.md +71 -3
  17. package/skills/start-discussion/references/research-analysis.md +2 -0
  18. package/skills/start-discussion/references/route-scenario.md +39 -0
  19. package/skills/start-discussion/references/validate-topic.md +46 -0
  20. package/skills/start-discussion/scripts/discovery.sh +3 -0
  21. package/skills/start-feature/SKILL.md +28 -84
  22. package/skills/start-feature/references/invoke-discussion.md +8 -4
  23. package/skills/start-feature/references/invoke-research.md +29 -0
  24. package/skills/start-feature/references/invoke-skill.md +35 -0
  25. package/skills/start-feature/references/research-gating.md +65 -0
  26. package/skills/start-feature/references/topic-name-check.md +61 -0
  27. package/skills/start-implementation/SKILL.md +35 -289
  28. package/skills/start-implementation/references/check-dependencies.md +65 -0
  29. package/skills/start-implementation/references/display-plans.md +159 -0
  30. package/skills/start-implementation/references/environment-check.md +45 -0
  31. package/skills/start-implementation/references/invoke-skill.md +42 -0
  32. package/skills/start-implementation/references/route-scenario.md +32 -0
  33. package/skills/start-implementation/references/validate-plan.md +45 -0
  34. package/skills/start-implementation/scripts/discovery.sh +3 -0
  35. package/skills/start-investigation/SKILL.md +145 -0
  36. package/skills/start-investigation/references/gather-context-fresh.md +72 -0
  37. package/skills/start-investigation/references/gather-context.md +31 -0
  38. package/skills/start-investigation/references/invoke-skill.md +54 -0
  39. package/skills/start-investigation/references/route-scenario.md +69 -0
  40. package/skills/start-investigation/references/validate-investigation.md +46 -0
  41. package/skills/start-investigation/scripts/discovery.sh +92 -0
  42. package/skills/start-planning/SKILL.md +32 -72
  43. package/skills/start-planning/references/cross-cutting-context.md +5 -5
  44. package/skills/start-planning/references/invoke-skill.md +27 -4
  45. package/skills/start-planning/references/route-plan-state.md +30 -0
  46. package/skills/start-planning/references/route-scenario.md +38 -0
  47. package/skills/start-planning/references/validate-spec.md +47 -0
  48. package/skills/start-planning/scripts/discovery.sh +7 -0
  49. package/skills/start-research/SKILL.md +17 -6
  50. package/skills/start-research/references/invoke-skill.md +3 -0
  51. package/skills/start-review/SKILL.md +32 -60
  52. package/skills/start-review/references/determine-review-version.md +24 -0
  53. package/skills/start-review/references/display-plans.md +2 -2
  54. package/skills/start-review/references/route-scenario.md +74 -0
  55. package/skills/start-review/references/select-plans.md +8 -6
  56. package/skills/start-review/references/validate-artifacts.md +63 -0
  57. package/skills/start-review/scripts/discovery.sh +3 -0
  58. package/skills/start-specification/SKILL.md +44 -20
  59. package/skills/start-specification/references/check-existing-spec.md +57 -0
  60. package/skills/start-specification/references/check-prerequisites.md +15 -0
  61. package/skills/start-specification/references/handoffs/continue-concluded.md +3 -0
  62. package/skills/start-specification/references/handoffs/continue.md +3 -0
  63. package/skills/start-specification/references/handoffs/create-with-incorporation.md +3 -0
  64. package/skills/start-specification/references/handoffs/create.md +3 -0
  65. package/skills/start-specification/references/handoffs/unify-with-incorporation.md +3 -0
  66. package/skills/start-specification/references/handoffs/unify.md +3 -0
  67. package/skills/start-specification/references/invoke-skill-bridge.md +74 -0
  68. package/skills/start-specification/references/route-scenario.md +23 -0
  69. package/skills/start-specification/references/validate-source.md +91 -0
  70. package/skills/start-specification/scripts/discovery.sh +6 -0
  71. package/skills/status/SKILL.md +6 -3
  72. package/skills/status/scripts/discovery.sh +9 -0
  73. package/skills/technical-discussion/SKILL.md +15 -4
  74. package/skills/technical-discussion/references/template.md +9 -1
  75. package/skills/technical-implementation/SKILL.md +24 -1
  76. package/skills/technical-implementation/references/analysis-loop.md +4 -4
  77. package/skills/technical-implementation/references/task-loop.md +2 -2
  78. package/skills/technical-investigation/SKILL.md +239 -0
  79. package/skills/technical-investigation/references/analysis-patterns.md +181 -0
  80. package/skills/technical-investigation/references/symptom-gathering.md +164 -0
  81. package/skills/technical-investigation/references/template.md +164 -0
  82. package/skills/technical-planning/SKILL.md +24 -1
  83. package/skills/technical-planning/references/author-tasks.md +16 -16
  84. package/skills/technical-planning/references/define-tasks.md +2 -2
  85. package/skills/technical-planning/references/plan-construction.md +11 -30
  86. package/skills/technical-planning/references/plan-review.md +3 -3
  87. package/skills/technical-research/SKILL.md +38 -2
  88. package/skills/technical-review/SKILL.md +1 -2
  89. package/skills/technical-review/references/review-actions-loop.md +43 -1
  90. package/skills/technical-specification/SKILL.md +1 -2
  91. package/skills/technical-specification/references/spec-completion.md +34 -6
  92. package/skills/technical-specification/references/spec-construction.md +1 -1
  93. package/skills/technical-specification/references/spec-review.md +5 -5
  94. package/skills/view-plan/SKILL.md +0 -1
  95. package/skills/workflow/bridge/SKILL.md +82 -0
  96. package/skills/workflow/bridge/references/bugfix-continuation.md +59 -0
  97. package/skills/workflow/bridge/references/feature-continuation.md +60 -0
  98. package/skills/workflow/bridge/references/greenfield-continuation.md +224 -0
  99. package/skills/workflow/bridge/scripts/discovery.sh +512 -0
  100. package/skills/workflow/start/SKILL.md +97 -0
  101. package/skills/workflow/start/references/bugfix-routing.md +117 -0
  102. package/skills/workflow/start/references/feature-routing.md +117 -0
  103. package/skills/workflow/start/references/greenfield-routing.md +140 -0
  104. package/skills/workflow/start/references/work-type-selection.md +83 -0
  105. package/skills/workflow/start/scripts/discovery.sh +577 -0
  106. package/skills/begin-implementation/SKILL.md +0 -162
  107. package/skills/begin-planning/SKILL.md +0 -92
  108. package/skills/begin-review/SKILL.md +0 -90
  109. package/skills/continue-feature/SKILL.md +0 -186
  110. package/skills/continue-feature/references/detect-phase.md +0 -99
  111. package/skills/continue-feature/references/invoke-implementation.md +0 -43
  112. package/skills/continue-feature/references/invoke-planning.md +0 -43
  113. package/skills/continue-feature/references/invoke-review.md +0 -43
  114. package/skills/continue-feature/references/invoke-specification.md +0 -55
  115. package/skills/continue-feature/references/phase-bridge.md +0 -57
  116. package/skills/continue-feature/scripts/discovery.sh +0 -233
  117. package/skills/start-feature/references/phase-bridge.md +0 -37
@@ -1,8 +1,7 @@
1
1
  ---
2
2
  name: start-discussion
3
- description: "Start a technical discussion. Discovers research and existing discussions, offers multiple entry paths, and invokes the technical-discussion skill."
4
3
  disable-model-invocation: true
5
- allowed-tools: Bash(.claude/skills/start-discussion/scripts/discovery.sh), Bash(mkdir -p .workflows/.state), Bash(rm .workflows/.state/research-analysis.md), Bash(.claude/hooks/workflows/write-session-state.sh)
4
+ allowed-tools: Bash(.claude/skills/start-discussion/scripts/discovery.sh), Bash(mkdir -p .workflows/.state), Bash(rm .workflows/.state/research-analysis.md), Bash(.claude/hooks/workflows/write-session-state.sh), Bash(ls .workflows/discussion/)
6
5
  hooks:
7
6
  PreToolUse:
8
7
  - hooks:
@@ -52,9 +51,13 @@ Follow these steps EXACTLY as written. Do not skip steps or combine them. Presen
52
51
 
53
52
  Invoke the `/migrate` skill and assess its output.
54
53
 
55
- **If files were updated**: STOP and wait for the user to review the changes (e.g., via `git diff`) and confirm before proceeding to Step 1. Do not continue automatically.
54
+ #### If files were updated
56
55
 
57
- **If no updates needed**: Proceed to Step 1.
56
+ **STOP.** Wait for the user to review the changes (e.g., via `git diff`) and confirm before proceeding.
57
+
58
+ #### If no updates needed
59
+
60
+ → Proceed to **Step 1**.
58
61
 
59
62
  ---
60
63
 
@@ -94,94 +97,96 @@ Parse the discovery output to understand:
94
97
  **From `state` section:**
95
98
  - `scenario` - one of: `"fresh"`, `"research_only"`, `"discussions_only"`, `"research_and_discussions"`
96
99
 
97
- **IMPORTANT**: Use ONLY this script for discovery. Do NOT run additional bash commands (ls, head, cat, etc.) to gather state - the script provides everything needed.
100
+ **IMPORTANT**: Use ONLY this script for discovery. Do NOT run additional bash commands (ls, head, cat, etc.) to gather state.
98
101
 
99
102
  → Proceed to **Step 2**.
100
103
 
101
104
  ---
102
105
 
103
- ## Step 2: Route Based on Scenario
106
+ ## Step 2: Determine Mode
104
107
 
105
- Use `state.scenario` from the discovery output to determine the path:
108
+ Check for arguments: work_type = `$0`, topic = `$1`
106
109
 
107
- #### If scenario is "research_only" or "research_and_discussions"
110
+ #### If work_type and topic are both provided
108
111
 
109
- Research exists and may need analysis.
112
+ Proceed to **Step 3** (Validate Topic).
110
113
 
111
- Proceed to **Step 3**.
114
+ #### If work_type is provided without topic
112
115
 
113
- #### If scenario is "discussions_only"
116
+ Store work_type for the handoff.
114
117
 
115
- No research exists, but discussions do. Skip research analysis.
118
+ Proceed to **Step 4** (Route Based on Scenario).
116
119
 
117
- Proceed to **Step 4**.
120
+ #### If neither is provided
118
121
 
119
- #### If scenario is "fresh"
122
+ Proceed to **Step 4** (Route Based on Scenario).
120
123
 
121
- No research or discussions exist yet.
124
+ ---
122
125
 
123
- ```
124
- Starting fresh - no prior research or discussions found.
126
+ ## Step 3: Validate Topic
125
127
 
126
- What topic would you like to discuss?
127
- ```
128
+ Load **[validate-topic.md](references/validate-topic.md)** and follow its instructions as written.
128
129
 
129
- **STOP.** Wait for user response.
130
+ #### If resume
130
131
 
131
- When user responds, proceed with their topic.
132
+ Proceed to **Step 8**.
132
133
 
133
- Proceed to **Step 6**.
134
+ #### If no collision
135
+
136
+ → Proceed to **Step 8**.
134
137
 
135
138
  ---
136
139
 
137
- ## Step 3: Research Analysis
140
+ ## Step 4: Route Based on Scenario
138
141
 
139
- Load **[research-analysis.md](references/research-analysis.md)** and follow its instructions as written.
142
+ Load **[route-scenario.md](references/route-scenario.md)** and follow its instructions as written.
140
143
 
141
- Proceed to **Step 4**.
144
+ #### If research exists
142
145
 
143
- ---
146
+ → Proceed to **Step 5**.
144
147
 
145
- ## Step 4: Present Options
148
+ #### If discussions only
146
149
 
147
- Load **[display-options.md](references/display-options.md)** and follow its instructions as written.
150
+ Proceed to **Step 6**.
148
151
 
149
- Proceed to **Step 5**.
152
+ #### If fresh
153
+
154
+ → Proceed to **Step 8**.
150
155
 
151
156
  ---
152
157
 
153
- ## Step 5: Handle Selection
158
+ ## Step 5: Research Analysis
154
159
 
155
- Load **[handle-selection.md](references/handle-selection.md)** and follow its instructions as written.
160
+ Load **[research-analysis.md](references/research-analysis.md)** and follow its instructions as written.
156
161
 
157
162
  → Proceed to **Step 6**.
158
163
 
159
164
  ---
160
165
 
161
- ## Step 6: Gather Context
166
+ ## Step 6: Present Options
162
167
 
163
- Load **[gather-context.md](references/gather-context.md)** and follow its instructions as written.
168
+ Load **[display-options.md](references/display-options.md)** and follow its instructions as written.
164
169
 
165
170
  → Proceed to **Step 7**.
166
171
 
167
172
  ---
168
173
 
169
- ## Step 7: Invoke the Skill
174
+ ## Step 7: Handle Selection
170
175
 
171
- Before invoking the processing skill, save a session bookmark.
176
+ Load **[handle-selection.md](references/handle-selection.md)** and follow its instructions as written.
172
177
 
173
- > *Output the next fenced block as a code block:*
178
+ Proceed to **Step 8**.
174
179
 
175
- ```
176
- Saving session state so Claude can pick up where it left off if the conversation is compacted.
177
- ```
180
+ ---
178
181
 
179
- ```bash
180
- .claude/hooks/workflows/write-session-state.sh \
181
- "{topic}" \
182
- "skills/technical-discussion/SKILL.md" \
183
- ".workflows/discussion/{topic}.md"
184
- ```
182
+ ## Step 8: Gather Context
185
183
 
186
- Load **[invoke-skill.md](references/invoke-skill.md)** and follow its instructions as written.
184
+ Load **[gather-context.md](references/gather-context.md)** and follow its instructions as written.
187
185
 
186
+ → Proceed to **Step 9**.
187
+
188
+ ---
189
+
190
+ ## Step 9: Invoke the Skill
191
+
192
+ Load **[invoke-skill.md](references/invoke-skill.md)** and follow its instructions as written.
@@ -4,28 +4,72 @@
4
4
 
5
5
  ---
6
6
 
7
- Route based on the chosen path from earlier steps.
7
+ Route based on the `source` variable set in earlier steps.
8
8
 
9
- #### If starting from research
9
+ #### If source is "bridge"
10
10
 
11
- Load **[gather-context-research.md](gather-context-research.md)** and follow its instructions.
11
+ Bridge mode: topic and work_type were provided by the caller.
12
+
13
+ Check if research exists for this topic. Read `.workflows/research/{topic}.md` and look for a `> **Discussion-ready**:` marker.
14
+
15
+ **If research exists with a discussion-ready marker:**
16
+
17
+ > *Output the next fenced block as a code block:*
18
+
19
+ ```
20
+ Starting discussion: {topic:(titlecase)}
21
+ Work type: {work_type}
22
+
23
+ Research context:
24
+ {discussion-ready summary extracted from research file}
25
+
26
+ Anything to add or adjust before we begin, or "go" to proceed:
27
+ ```
28
+
29
+ **STOP.** Wait for user response.
30
+
31
+ Set source="research-bridge".
32
+
33
+ → Return to **[the skill](../SKILL.md)**.
34
+
35
+ **Otherwise:**
36
+
37
+ > *Output the next fenced block as a code block:*
38
+
39
+ ```
40
+ Starting discussion: {topic:(titlecase)}
41
+ Work type: {work_type}
42
+
43
+ What would you like to discuss? Provide some initial context:
44
+ - What's the problem or opportunity?
45
+ - What prompted this?
46
+ - Any initial thoughts or constraints?
47
+ ```
48
+
49
+ **STOP.** Wait for user response.
50
+
51
+ → Return to **[the skill](../SKILL.md)**.
52
+
53
+ #### If source is "research"
54
+
55
+ Load **[gather-context-research.md](gather-context-research.md)** and follow its instructions.
12
56
 
13
57
  **STOP.** Wait for user response.
14
58
 
15
- Proceed to **Step 7** with the gathered context.
59
+ Return to **[the skill](../SKILL.md)**.
16
60
 
17
- #### If starting fresh topic
61
+ #### If source is "fresh"
18
62
 
19
- Load **[gather-context-fresh.md](gather-context-fresh.md)** and follow its instructions.
63
+ Load **[gather-context-fresh.md](gather-context-fresh.md)** and follow its instructions.
20
64
 
21
65
  **STOP.** Wait for user response.
22
66
 
23
- Proceed to **Step 7** with the gathered context.
67
+ Return to **[the skill](../SKILL.md)**.
24
68
 
25
- #### If continuing existing discussion
69
+ #### If source is "continue"
26
70
 
27
- Load **[gather-context-continue.md](gather-context-continue.md)** and follow its instructions.
71
+ Load **[gather-context-continue.md](gather-context-continue.md)** and follow its instructions.
28
72
 
29
73
  **STOP.** Wait for user response.
30
74
 
31
- Proceed to **Step 7** with the gathered context.
75
+ Return to **[the skill](../SKILL.md)**.
@@ -10,9 +10,12 @@ Route based on the user's choice from the options display.
10
10
 
11
11
  User chose to start from research (e.g., "research 1", "1", "from research", or a topic name).
12
12
 
13
+ Set source="research".
14
+
13
15
  **If user specified a topic inline** (e.g., "research 2", "2", or topic name):
14
16
  - Identify the selected topic from the numbered list
15
- - Control returns to the backbone
17
+
18
+ → Return to **[the skill](../SKILL.md)**.
16
19
 
17
20
  **If user just said "from research" without specifying:**
18
21
 
@@ -28,9 +31,12 @@ Which research topic would you like to discuss? (Enter a number or topic name)
28
31
 
29
32
  User chose to continue a discussion (e.g., "continue auth-flow" or "continue discussion").
30
33
 
34
+ Set source="continue".
35
+
31
36
  **If user specified a discussion inline** (e.g., "continue auth-flow"):
32
37
  - Identify the selected discussion from the list
33
- - Control returns to the backbone
38
+
39
+ → Return to **[the skill](../SKILL.md)**.
34
40
 
35
41
  **If user just said "continue discussion" without specifying:**
36
42
 
@@ -44,7 +50,11 @@ Which discussion would you like to continue?
44
50
 
45
51
  #### If user chose "Fresh topic"
46
52
 
47
- User wants to start a fresh discussion. Control returns to the backbone.
53
+ User wants to start a fresh discussion.
54
+
55
+ Set source="fresh".
56
+
57
+ → Return to **[the skill](../SKILL.md)**.
48
58
 
49
59
  #### If user chose "refresh"
50
60
 
@@ -59,4 +69,4 @@ Delete the cache file:
59
69
  rm .workflows/.state/research-analysis.md
60
70
  ```
61
71
 
62
- Return to **Step 3** to re-analyze.
72
+ Proceed to **[Step 5](../SKILL.md)** to re-analyze.
@@ -4,13 +4,38 @@
4
4
 
5
5
  ---
6
6
 
7
+ Before invoking the processing skill, save a session bookmark.
8
+
9
+ > *Output the next fenced block as a code block:*
10
+
11
+ ```
12
+ Saving session state so Claude can pick up where it left off if the conversation is compacted.
13
+ ```
14
+
15
+ ```bash
16
+ .claude/hooks/workflows/write-session-state.sh \
17
+ "{topic}" \
18
+ "skills/technical-discussion/SKILL.md" \
19
+ ".workflows/discussion/{topic}.md"
20
+ ```
21
+
7
22
  This skill's purpose is now fulfilled.
8
23
 
9
24
  Invoke the [technical-discussion](../../technical-discussion/SKILL.md) skill for your next instructions. Do not act on the gathered information until the skill is loaded - it contains the instructions for how to proceed.
10
25
 
11
- **Example handoff (from research):**
26
+ ---
27
+
28
+ ## Handoff
29
+
30
+ Construct the handoff based on how this discussion was initiated.
31
+
32
+ #### If source is "research"
33
+
34
+ **If work_type is available** (from Step 2), add the Work type line:
35
+
12
36
  ```
13
37
  Discussion session for: {topic}
38
+ Work type: {work_type}
14
39
  Output: .workflows/discussion/{topic}.md
15
40
 
16
41
  Research reference:
@@ -20,10 +45,53 @@ Summary: {the 1-2 sentence summary from the research analysis}
20
45
  Invoke the technical-discussion skill.
21
46
  ```
22
47
 
23
- **Example handoff (continuing or fresh):**
48
+ #### If source is "research-bridge"
49
+
50
+ ```
51
+ Discussion session for: {topic}
52
+ Work type: {work_type}
53
+ Research source: .workflows/research/{topic}.md
54
+ Output: .workflows/discussion/{topic}.md
55
+
56
+ Research reference:
57
+ Source: .workflows/research/{topic}.md
58
+ Summary: {the discussion-ready summary from the research file}
59
+
60
+ Invoke the technical-discussion skill.
61
+ ```
62
+
63
+ #### If source is "continue"
64
+
65
+ Read work_type from the existing discussion frontmatter.
66
+
67
+ ```
68
+ Discussion session for: {topic}
69
+ Work type: {work_type}
70
+ Source: existing discussion
71
+ Output: .workflows/discussion/{topic}.md
72
+
73
+ Invoke the technical-discussion skill.
74
+ ```
75
+
76
+ #### If source is "fresh"
77
+
78
+ **If work_type is available** (from Step 2), add the Work type line:
79
+
80
+ ```
81
+ Discussion session for: {topic}
82
+ Work type: {work_type}
83
+ Source: fresh
84
+ Output: .workflows/discussion/{topic}.md
85
+
86
+ Invoke the technical-discussion skill.
87
+ ```
88
+
89
+ #### If source is "bridge"
90
+
24
91
  ```
25
92
  Discussion session for: {topic}
26
- Source: {existing discussion | fresh}
93
+ Work type: {work_type}
94
+ Source: fresh
27
95
  Output: .workflows/discussion/{topic}.md
28
96
 
29
97
  Invoke the technical-discussion skill.
@@ -70,3 +70,5 @@ research_files:
70
70
  ```
71
71
 
72
72
  **Cross-reference**: For each topic, note if a discussion already exists (from `discussions.files` in discovery).
73
+
74
+ → Return to **[the skill](../SKILL.md)**.
@@ -0,0 +1,39 @@
1
+ # Route Based on Scenario
2
+
3
+ *Reference for **[start-discussion](../SKILL.md)***
4
+
5
+ ---
6
+
7
+ Use `state.scenario` from the discovery output to determine the path.
8
+
9
+ #### If scenario is "research_only" or "research_and_discussions"
10
+
11
+ Research exists and may need analysis.
12
+
13
+ → Return to **[the skill](../SKILL.md)** for **Step 5**.
14
+
15
+ #### If scenario is "discussions_only"
16
+
17
+ No research exists, but discussions do. Skip research analysis.
18
+
19
+ → Return to **[the skill](../SKILL.md)** for **Step 6**.
20
+
21
+ #### If scenario is "fresh"
22
+
23
+ No research or discussions exist yet.
24
+
25
+ Set source="fresh".
26
+
27
+ > *Output the next fenced block as a code block:*
28
+
29
+ ```
30
+ Starting fresh - no prior research or discussions found.
31
+
32
+ What topic would you like to discuss?
33
+ ```
34
+
35
+ **STOP.** Wait for user response.
36
+
37
+ When user responds, proceed with their topic.
38
+
39
+ → Return to **[the skill](../SKILL.md)** for **Step 8**.
@@ -0,0 +1,46 @@
1
+ # Validate Topic
2
+
3
+ *Reference for **[start-discussion](../SKILL.md)***
4
+
5
+ ---
6
+
7
+ Check if discussion already exists for this topic.
8
+
9
+ ```bash
10
+ ls .workflows/discussion/
11
+ ```
12
+
13
+ #### If discussion exists for this topic
14
+
15
+ Read `.workflows/discussion/{topic}.md` frontmatter to check status.
16
+
17
+ #### If status is "in-progress"
18
+
19
+ > *Output the next fenced block as a code block:*
20
+
21
+ ```
22
+ Resuming discussion: {topic:(titlecase)}
23
+ ```
24
+
25
+ Set source="continue".
26
+
27
+ → Return to **[the skill](../SKILL.md)** for **Step 8**.
28
+
29
+ #### If status is "concluded"
30
+
31
+ > *Output the next fenced block as a code block:*
32
+
33
+ ```
34
+ Discussion Concluded
35
+
36
+ The discussion for "{topic:(titlecase)}" has already concluded.
37
+ Run /start-specification to continue to spec.
38
+ ```
39
+
40
+ **STOP.** Do not proceed — terminal condition.
41
+
42
+ #### If no collision
43
+
44
+ Set source="bridge".
45
+
46
+ → Return to **[the skill](../SKILL.md)**.
@@ -83,9 +83,12 @@ if [ -d "$DISCUSSION_DIR" ] && [ -n "$(ls -A "$DISCUSSION_DIR" 2>/dev/null)" ];
83
83
  status=$(extract_field "$file" "status")
84
84
  status=${status:-"unknown"}
85
85
  date=$(extract_field "$file" "date")
86
+ work_type=$(extract_field "$file" "work_type")
87
+ work_type=${work_type:-"greenfield"}
86
88
 
87
89
  echo " - name: \"$name\""
88
90
  echo " status: \"$status\""
91
+ echo " work_type: \"$work_type\""
89
92
  if [ -n "$date" ]; then
90
93
  echo " date: \"$date\""
91
94
  fi
@@ -1,8 +1,7 @@
1
1
  ---
2
2
  name: start-feature
3
- description: "Start a new feature through the full pipeline. Gathers context via structured interview, creates a discussion, then bridges to continue-feature for specification, planning, and implementation."
4
3
  disable-model-invocation: true
5
- allowed-tools: Bash(ls .workflows/discussion/), Bash(.claude/hooks/workflows/write-session-state.sh)
4
+ allowed-tools: Bash(ls .workflows/discussion/), Bash(ls .workflows/research/), Bash(.claude/hooks/workflows/write-session-state.sh)
6
5
  hooks:
7
6
  PreToolUse:
8
7
  - hooks:
@@ -11,7 +10,9 @@ hooks:
11
10
  once: true
12
11
  ---
13
12
 
14
- Start a new feature and route it through the pipeline: Discussion → Specification → Planning → Implementation.
13
+ Start a new feature and route it through the pipeline: (Research) → Discussion → Specification → Planning → Implementation → Review.
14
+
15
+ Research is optional — offered when significant uncertainties exist.
15
16
 
16
17
  > **⚠️ ZERO OUTPUT RULE**: Do not narrate your processing. Produce no output until a step or reference file explicitly specifies display content. No "proceeding with...", no discovery summaries, no routing decisions, no transition text. Your first output must be content explicitly called for by the instructions.
17
18
 
@@ -28,120 +29,63 @@ Follow these steps EXACTLY as written. Do not skip steps or combine them.
28
29
 
29
30
  ---
30
31
 
31
- ## Step 0: Run Migrations
32
-
33
- **This step is mandatory. You must complete it before proceeding.**
34
-
35
- Invoke the `/migrate` skill and assess its output.
36
-
37
- **If files were updated**: STOP and wait for the user to review the changes (e.g., via `git diff`) and confirm before proceeding to Step 1. Do not continue automatically.
38
-
39
- **If no updates needed**: Proceed to Step 1.
40
-
41
- ---
42
-
43
32
  ## Resuming After Context Refresh
44
33
 
45
34
  Context refresh (compaction) summarizes the conversation, losing procedural detail. When you detect a context refresh has occurred — the conversation feels abruptly shorter, you lack memory of recent steps, or a summary precedes this message — follow this recovery protocol:
46
35
 
47
36
  1. **Re-read this skill file completely.** Do not rely on your summary of it. The full process, steps, and rules must be reloaded.
48
- 2. **Identify the topic.** Check conversation history for the topic name. If unknown, check `.workflows/discussion/` for recently modified files via `git log --oneline -5`.
37
+ 2. **Identify the topic.** Check conversation history for the topic name. If unknown, check `.workflows/discussion/` or `.workflows/research/` for recently modified files.
49
38
  3. **Determine current step from artifacts:**
50
- - No discussion file exists → resume at **Step 1**
51
- - Discussion exists with `status: in-progress` → resume at **Step 3** (re-invoke technical-discussion)
52
- - Discussion exists with `status: concluded` → resume at **Step 4** (phase bridge)
39
+ - No research or discussion file exists → resume at **Step 1**
40
+ - Research file exists, no discussion → resume at **Step 4** (re-invoke technical-research)
41
+ - Discussion exists with `status: in-progress` → resume at **Step 4** (re-invoke technical-discussion)
42
+ - Discussion exists with `status: concluded` → already handled by processing skill's bridge invocation
53
43
  4. **Announce your position** to the user before continuing: what step you believe you're at, what's been completed, and what comes next. Wait for confirmation.
54
44
 
55
45
  Do not guess at progress or continue from memory. The files on disk and git history are authoritative — your recollection is not.
56
46
 
57
47
  ---
58
48
 
59
- ## Step 1: Gather Feature Context
60
-
61
- Load **[gather-feature-context.md](references/gather-feature-context.md)** and follow its instructions.
62
-
63
- → Proceed to **Step 2**.
64
-
65
- ---
66
-
67
- ## Step 2: Topic Name and Conflict Check
68
-
69
- Based on the feature description, suggest a topic name:
70
-
71
- > *Output the next fenced block as a code block:*
72
-
73
- ```
74
- Suggested topic name: {suggested-topic:(kebabcase)}
49
+ ## Step 0: Run Migrations
75
50
 
76
- This will create: .workflows/discussion/{suggested-topic}.md
77
- ```
51
+ **This step is mandatory. You must complete it before proceeding.**
78
52
 
79
- > *Output the next fenced block as markdown (not a code block):*
53
+ Invoke the `/migrate` skill and assess its output.
80
54
 
81
- ```
82
- · · · · · · · · · · · ·
83
- Is this name okay?
55
+ #### If files were updated
84
56
 
85
- - **`y`/`yes`** Use this name
86
- - **`s`/`something else`** — Suggest a different name
87
- · · · · · · · · · · · ·
88
- ```
57
+ **STOP.** Wait for the user to review the changes (e.g., via `git diff`) and confirm before proceeding.
89
58
 
90
- **STOP.** Wait for user response.
59
+ #### If no updates needed
91
60
 
92
- Once the topic name is confirmed, check for naming conflicts:
61
+ Proceed to **Step 1**.
93
62
 
94
- ```bash
95
- ls .workflows/discussion/
96
- ```
63
+ ---
97
64
 
98
- If a discussion with the same name exists, inform the user:
65
+ ## Step 1: Gather Feature Context
99
66
 
100
- > *Output the next fenced block as markdown (not a code block):*
67
+ Load **[gather-feature-context.md](references/gather-feature-context.md)** and follow its instructions.
101
68
 
102
- ```
103
- · · · · · · · · · · · ·
104
- A discussion named "{topic}" already exists.
69
+ → Proceed to **Step 2**.
105
70
 
106
- - **`r`/`resume`** — Resume the existing discussion
107
- - **`n`/`new`** — Choose a different name
108
- · · · · · · · · · · · ·
109
- ```
71
+ ---
110
72
 
111
- **STOP.** Wait for user response.
73
+ ## Step 2: Topic Name and Conflict Check
112
74
 
113
- If resuming, check the discussion status. If concluded → skip to Step 4. If in-progress proceed to Step 3.
75
+ Load **[topic-name-check.md](references/topic-name-check.md)** and follow its instructions.
114
76
 
115
77
  → Proceed to **Step 3**.
116
78
 
117
79
  ---
118
80
 
119
- ## Step 3: Invoke Discussion
120
-
121
- Before invoking the processing skill, save a session bookmark.
81
+ ## Step 3: Research Gating
122
82
 
123
- > *Output the next fenced block as a code block:*
83
+ Load **[research-gating.md](references/research-gating.md)** and follow its instructions.
124
84
 
125
- ```
126
- Saving session state so Claude can pick up where it left off and continue the feature pipeline if the conversation is compacted.
127
- ```
128
-
129
- ```bash
130
- .claude/hooks/workflows/write-session-state.sh \
131
- "{topic}" \
132
- "skills/technical-discussion/SKILL.md" \
133
- ".workflows/discussion/{topic}.md" \
134
- --pipeline "This session is part of the feature pipeline. After the discussion concludes, load and follow the phase bridge at skills/start-feature/references/phase-bridge.md for topic '{topic}'."
135
- ```
136
-
137
- Load **[invoke-discussion.md](references/invoke-discussion.md)** and follow its instructions.
138
-
139
- **CRITICAL**: When the discussion concludes (status becomes "concluded"), you MUST proceed to **Step 4** below. Do not end the session — the feature pipeline continues to specification via the phase bridge.
85
+ → Proceed to **Step 4**.
140
86
 
141
87
  ---
142
88
 
143
- ## Step 4: Phase Bridge
144
-
145
- Load **[phase-bridge.md](references/phase-bridge.md)** and follow its instructions.
89
+ ## Step 4: Invoke Processing Skill
146
90
 
147
- The bridge will enter plan mode with instructions to invoke continue-feature for the topic in the next session.
91
+ Load **[invoke-skill.md](references/invoke-skill.md)** and follow its instructions.