@openspoon/subtask2 0.1.12 → 0.1.14
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/README.md +106 -92
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +24 -28
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,13 +1,6 @@
|
|
|
1
|
-
#
|
|
1
|
+
# subtask2 - a stronger opencode /command handler
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
- `return` — Tell the main agent what to do with subtask results (not just "summarize")
|
|
6
|
-
- `parallel` — To run multiple subtasks concurrently (accepts arguments)
|
|
7
|
-
- `chain` — Queue follow-up prompts that fire automatically
|
|
8
|
-
- 'better' defaults — Replace the generic "summarize" on subtask return with something that keeps the agent working or a custom generic prompt
|
|
9
|
-
|
|
10
|
-
⚠️ Requires [this PR](https://github.com/sst/opencode/pull/6478) for `parallel` and non-subtask features, and for proper model inheritance to work.
|
|
3
|
+
Give super powers to your slash commands with `@openspoon/subtask2`
|
|
11
4
|
|
|
12
5
|
## Installation
|
|
13
6
|
|
|
@@ -19,22 +12,109 @@ Add subtask2 to your opencode config plugin array
|
|
|
19
12
|
}
|
|
20
13
|
```
|
|
21
14
|
|
|
15
|
+
## TL:DR - Keep the agentic loop alive + parallel commands
|
|
16
|
+
|
|
17
|
+
This plugins affects how opencode handles commands with additional frontmatter parameters and enables parallel commands
|
|
18
|
+
|
|
19
|
+
- `return` tell the main agent what to do with command or subtask(s) results. Supports multiple sequential prompts.
|
|
20
|
+
- `parallel` run multiple subtasks concurrently (accepts arguments)
|
|
21
|
+
|
|
22
|
+
⚠️ Requires [this PR](https://github.com/sst/opencode/pull/6478) for `parallel` and non-subtask command features, as well as proper model inheritance (piping the right model and agent to the right subtask) to work.
|
|
23
|
+
|
|
24
|
+
## Examples
|
|
25
|
+
|
|
26
|
+
<details>
|
|
27
|
+
<summary><strong>Checkout some use cases</strong> (click to expand)</summary>
|
|
28
|
+
|
|
29
|
+
**Parallel subtask with different models (A/B plan comparison)**
|
|
30
|
+
|
|
31
|
+
```yaml
|
|
32
|
+
---
|
|
33
|
+
description: multi-model ensemble, 3 models plan in parallel, best ideas unified
|
|
34
|
+
model: github-copilot/claude-opus-4.5
|
|
35
|
+
subtask: true
|
|
36
|
+
parallel: plan-gemini, plan-gpt
|
|
37
|
+
return:
|
|
38
|
+
- Compare all 3 plans and validate each directly against the codebase. Pick the best ideas from each and create a unified implementation plan.
|
|
39
|
+
- Feed the implementation plan to a review subagent, let's poke holes.
|
|
40
|
+
---
|
|
41
|
+
Plan the implementation for the following feature
|
|
42
|
+
> $ARGUMENTS
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
**Isolated "Plan" mode**
|
|
46
|
+
|
|
47
|
+
```yaml
|
|
48
|
+
---
|
|
49
|
+
description: two-step implementation planning and validation
|
|
50
|
+
agent: build
|
|
51
|
+
subtask: true
|
|
52
|
+
return:
|
|
53
|
+
- Challenge, verify and validate the plan by reviewing the codebase directly. Then approve, revise, or reject the plan. Implement if solid
|
|
54
|
+
- Take a step back, review what was done/planned for correctness, revise if needed
|
|
55
|
+
---
|
|
56
|
+
In this session you WILL ONLY PLAN AND NOT IMPLEMENT. You are to take the `USER INPUT` and research the codebase until you have gathered enough knowledge to elaborate a full fledged implementation plan
|
|
57
|
+
|
|
58
|
+
You MUST consider alternative paths and keep researching until you are confident you found the BEST possible implementation
|
|
59
|
+
|
|
60
|
+
BEST often means simple, lean, clean, low surface and coupling
|
|
61
|
+
Make it practical, maintainable and not overly abstracted
|
|
62
|
+
|
|
63
|
+
Follow your heart
|
|
64
|
+
> DO NOT OVERENGINEER SHIT
|
|
65
|
+
|
|
66
|
+
USER INPUT
|
|
67
|
+
$ARGUMENTS
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
**Multi-step workflow**
|
|
71
|
+
|
|
72
|
+
```yaml
|
|
73
|
+
---
|
|
74
|
+
description: design, implement, test, document
|
|
75
|
+
agent: build
|
|
76
|
+
model: github-copilot/claude-opus-4.5
|
|
77
|
+
subtask: true
|
|
78
|
+
return:
|
|
79
|
+
- Implement the component following the conceptual design specifications.
|
|
80
|
+
- Write comprehensive unit tests for all edge cases.
|
|
81
|
+
- Update the documentation and add usage examples.
|
|
82
|
+
- Run the test suite and fix any failures.
|
|
83
|
+
---
|
|
84
|
+
Conceptually design a React modal component with the following requirements
|
|
85
|
+
> $ARGUMENTS
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
</details>
|
|
89
|
+
|
|
90
|
+
---
|
|
91
|
+
|
|
22
92
|
## Features
|
|
23
93
|
|
|
24
|
-
### 1. `return` - Command
|
|
94
|
+
### 1. `return` - Command return instructions (supports chaining)
|
|
25
95
|
|
|
26
96
|
Tell the main agent exactly what to do after a command completes:
|
|
27
97
|
|
|
28
98
|
```yaml
|
|
29
99
|
---
|
|
30
100
|
subtask: true
|
|
31
|
-
return: Look again,
|
|
101
|
+
return: Look again, challenge the findings, then implement the valid fixes.
|
|
32
102
|
---
|
|
33
103
|
Review the PR# $ARGUMENTS for bugs.
|
|
34
104
|
```
|
|
35
105
|
|
|
36
|
-
|
|
37
|
-
|
|
106
|
+
For multiple sequential prompts, use an array:
|
|
107
|
+
|
|
108
|
+
```yaml
|
|
109
|
+
---
|
|
110
|
+
subtask: true
|
|
111
|
+
return: [Implement the fix, Run the tests]
|
|
112
|
+
---
|
|
113
|
+
Find the bug in auth.ts
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
- **First return** replaces opencode's "summarize" message (for subtasks) or fires as follow-up (for non-subtasks)
|
|
117
|
+
- **Additional returns** fire sequentially after each LLM turn completes
|
|
38
118
|
|
|
39
119
|
**Note:** For non-subtask commands, requires opencode with `command.execute.before` hook (pending PR).
|
|
40
120
|
|
|
@@ -61,6 +141,12 @@ When ALL complete, the main agent gets the `return` prompt.
|
|
|
61
141
|
|
|
62
142
|
**With custom arguments per command:**
|
|
63
143
|
|
|
144
|
+
```bash
|
|
145
|
+
/mycommand main args || parallel1 args || parallel2 args
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
or
|
|
149
|
+
|
|
64
150
|
```yaml
|
|
65
151
|
---
|
|
66
152
|
subtask: true
|
|
@@ -79,7 +165,7 @@ Design a new auth system for $ARGUMENTS
|
|
|
79
165
|
- `research-codebase` gets "auth middleware implementation"
|
|
80
166
|
- `security-audit` inherits the main command's `$ARGUMENTS`
|
|
81
167
|
|
|
82
|
-
**Note:** Parallel commands are forced into subtasks regardless of their own `subtask` setting. Their `return
|
|
168
|
+
**Note:** Parallel commands are forced into subtasks regardless of their own `subtask` setting. Their `return` are ignored — only the parent's `return` applies.
|
|
83
169
|
|
|
84
170
|
**Tip:** If all commands share the same arguments, use the simple syntax:
|
|
85
171
|
|
|
@@ -91,36 +177,17 @@ All three inherit the main command's `$ARGUMENTS`.
|
|
|
91
177
|
|
|
92
178
|
**Tip:** You can also pass arguments inline using `||` separator:
|
|
93
179
|
|
|
94
|
-
```
|
|
180
|
+
```bash
|
|
95
181
|
/mycommand main args || parallel1 args || parallel2 args
|
|
96
182
|
```
|
|
97
183
|
|
|
98
|
-
Each segment maps to a parallel command in order. Priority: **
|
|
184
|
+
Each segment maps to a parallel command in order. Priority: **pipe args > frontmatter args > inherit main args**.
|
|
99
185
|
|
|
100
|
-
### 3.
|
|
186
|
+
### 3. Global fallback - 'Better' default for subtasks
|
|
101
187
|
|
|
102
|
-
|
|
188
|
+
By default opencode injects a prompt in the main session once a **subtask** is completed.
|
|
103
189
|
|
|
104
|
-
|
|
105
|
-
---
|
|
106
|
-
subtask: true
|
|
107
|
-
return: Implement the fix.
|
|
108
|
-
chain:
|
|
109
|
-
- Review your implementation for correctness, make sure this work on the first try
|
|
110
|
-
- Tell me a joke
|
|
111
|
-
---
|
|
112
|
-
Find the bug in auth.ts
|
|
113
|
-
```
|
|
114
|
-
|
|
115
|
-
Flow: Command → return prompt → LLM works → chain[0] fires → LLM works → chain[1] fires → ...
|
|
116
|
-
|
|
117
|
-
**Note:** For non-subtask commands, requires opencode with `command.execute.before` hook (pending PR).
|
|
118
|
-
|
|
119
|
-
### 4. Global fallback - 'Better' default for subtasks
|
|
120
|
-
|
|
121
|
-
For `subtask: true` commands without a `return`, this plugin replaces opencode's generic "summarize" message with something better.
|
|
122
|
-
|
|
123
|
-
Default: "Challenge and validate the task output. Verify assumptions, identify gaps or errors, then continue with the next logical step."
|
|
190
|
+
For `subtask: true` commands without a `return`, this plugin replaces the opencode generic "summarize" message with by default: "Challenge and validate the task output. Verify assumptions, identify gaps or errors, then continue with the next logical step."
|
|
124
191
|
|
|
125
192
|
Configure in `~/.config/opencode/subtask2.jsonc`:
|
|
126
193
|
|
|
@@ -134,67 +201,14 @@ Configure in `~/.config/opencode/subtask2.jsonc`:
|
|
|
134
201
|
}
|
|
135
202
|
```
|
|
136
203
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
When a subtask completes, what message does the main agent see?
|
|
204
|
+
#### Priority Order
|
|
140
205
|
|
|
141
206
|
1. **`return` param** → Your specific instructions (highest priority)
|
|
142
207
|
2. **Config `generic_return`** → Your custom fallback (if `replace_generic: true`)
|
|
143
208
|
3. **Built-in default** → "Challenge and validate..." (if `replace_generic: true`)
|
|
144
209
|
4. **OpenCode original** → "Summarize..." (if `replace_generic: false`)
|
|
145
210
|
|
|
146
|
-
## Quick Examples
|
|
147
|
-
|
|
148
|
-
**Simple: Make the agent act on results**
|
|
149
|
-
|
|
150
|
-
```yaml
|
|
151
|
-
---
|
|
152
|
-
return: Implement the suggested improvements.
|
|
153
|
-
---
|
|
154
|
-
Analyze this function for performance issues.
|
|
155
|
-
```
|
|
156
|
-
|
|
157
|
-
**Parallel: Multiple perspectives at once**
|
|
158
|
-
|
|
159
|
-
```yaml
|
|
160
|
-
---
|
|
161
|
-
subtask: true
|
|
162
|
-
parallel: brainstorm-solutions, research-prior-art
|
|
163
|
-
return: Evaluate all ideas and create an implementation plan.
|
|
164
|
-
---
|
|
165
|
-
Identify the core problem in our auth flow.
|
|
166
|
-
```
|
|
167
|
-
|
|
168
|
-
**Parallel: Same task, different models**
|
|
169
|
-
|
|
170
|
-
```yaml
|
|
171
|
-
---
|
|
172
|
-
description: multi-model ensemble, 3 models plan in parallel, best ideas unified
|
|
173
|
-
agent: build
|
|
174
|
-
model: github-copilot/gpt-5.2
|
|
175
|
-
subtask: true
|
|
176
|
-
parallel: plan-gemini, plan-opus
|
|
177
|
-
return: Compare all 3 plans and validate each directly against the codebase. Pick the best ideas from each and create a unified implementation plan.
|
|
178
|
-
chain:
|
|
179
|
-
- feed the implementation plan to a @review subagent, let's poke holes.
|
|
180
211
|
---
|
|
181
|
-
Plan the implementation for the following feature: $ARGUMENTS
|
|
182
|
-
```
|
|
183
|
-
|
|
184
|
-
**Chain: Multi-step workflow**
|
|
185
|
-
|
|
186
|
-
```yaml
|
|
187
|
-
---
|
|
188
|
-
description: design, implement, test, document
|
|
189
|
-
subtask: true
|
|
190
|
-
return: Implement the component following the conceptual design specifications.
|
|
191
|
-
chain:
|
|
192
|
-
- Write comprehensive unit tests for all edge cases.
|
|
193
|
-
- Update the documentation and add usage examples.
|
|
194
|
-
- Run the test suite and fix any failures.
|
|
195
|
-
---
|
|
196
|
-
Conceptually design a React modal component with the following requirements: $ARGUMENTS
|
|
197
|
-
```
|
|
198
212
|
|
|
199
213
|
## License
|
|
200
214
|
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,MAAM,EAAC,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,MAAM,EAAC,MAAM,qBAAqB,CAAC;AAiKhD,QAAA,MAAM,MAAM,EAAE,MAmIb,CAAC;AAEF,eAAe,MAAM,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -86,8 +86,8 @@ async function buildManifest() {
|
|
|
86
86
|
const name = file.replace(/\.md$/, "");
|
|
87
87
|
const content = await Bun.file(`${dir}/${file}`).text();
|
|
88
88
|
const fm = parseFrontmatter(content);
|
|
89
|
-
const
|
|
90
|
-
const
|
|
89
|
+
const returnVal = fm.return;
|
|
90
|
+
const returnArr = returnVal ? (Array.isArray(returnVal) ? returnVal : [returnVal]) : [];
|
|
91
91
|
const parallel = fm.parallel;
|
|
92
92
|
let parallelArr = [];
|
|
93
93
|
if (parallel) {
|
|
@@ -107,8 +107,7 @@ async function buildManifest() {
|
|
|
107
107
|
}
|
|
108
108
|
}
|
|
109
109
|
manifest[name] = {
|
|
110
|
-
return:
|
|
111
|
-
chain: chainArr,
|
|
110
|
+
return: returnArr,
|
|
112
111
|
parallel: parallelArr,
|
|
113
112
|
agent: fm.agent,
|
|
114
113
|
description: fm.description,
|
|
@@ -124,7 +123,7 @@ let configs = {};
|
|
|
124
123
|
let pluginConfig = { replace_generic: true };
|
|
125
124
|
let client = null;
|
|
126
125
|
const callState = new Map();
|
|
127
|
-
const
|
|
126
|
+
const returnState = new Map();
|
|
128
127
|
const pendingReturns = new Map();
|
|
129
128
|
const pendingNonSubtaskReturns = new Map();
|
|
130
129
|
let hasActiveSubtask = false;
|
|
@@ -152,15 +151,10 @@ const plugin = async (ctx) => {
|
|
|
152
151
|
}
|
|
153
152
|
}
|
|
154
153
|
}
|
|
155
|
-
// Track non-subtask commands with return
|
|
154
|
+
// Track non-subtask commands with return for later injection
|
|
156
155
|
const hasSubtaskPart = output.parts.some((p) => p.type === "subtask");
|
|
157
|
-
if (!hasSubtaskPart && config) {
|
|
158
|
-
|
|
159
|
-
pendingNonSubtaskReturns.set(input.sessionID, config.return);
|
|
160
|
-
}
|
|
161
|
-
if (config.chain.length) {
|
|
162
|
-
chainState.set(input.sessionID, [...config.chain]);
|
|
163
|
-
}
|
|
156
|
+
if (!hasSubtaskPart && config?.return?.length) {
|
|
157
|
+
pendingNonSubtaskReturns.set(input.sessionID, [...config.return]);
|
|
164
158
|
}
|
|
165
159
|
if (!config?.parallel?.length)
|
|
166
160
|
return;
|
|
@@ -171,8 +165,8 @@ const plugin = async (ctx) => {
|
|
|
171
165
|
continue;
|
|
172
166
|
const fm = parseFrontmatter(cmdFile.content);
|
|
173
167
|
let template = getTemplateBody(cmdFile.content);
|
|
174
|
-
// Priority:
|
|
175
|
-
const args =
|
|
168
|
+
// Priority: pipe args > frontmatter args > main args
|
|
169
|
+
const args = parallelArgs[i] ?? parallelCmd.arguments ?? mainArgs;
|
|
176
170
|
template = template.replace(/\$ARGUMENTS/g, args);
|
|
177
171
|
// Parse model string "provider/model" into {providerID, modelID}
|
|
178
172
|
let model;
|
|
@@ -197,8 +191,8 @@ const plugin = async (ctx) => {
|
|
|
197
191
|
const cmd = output.args?.command;
|
|
198
192
|
if (cmd && configs[cmd]) {
|
|
199
193
|
callState.set(input.callID, cmd);
|
|
200
|
-
if (configs[cmd].
|
|
201
|
-
|
|
194
|
+
if (configs[cmd].return.length > 1) {
|
|
195
|
+
returnState.set(input.sessionID, [...configs[cmd].return.slice(1)]);
|
|
202
196
|
}
|
|
203
197
|
}
|
|
204
198
|
},
|
|
@@ -207,8 +201,8 @@ const plugin = async (ctx) => {
|
|
|
207
201
|
return;
|
|
208
202
|
const cmd = callState.get(input.callID);
|
|
209
203
|
callState.delete(input.callID);
|
|
210
|
-
if (cmd && configs[cmd]?.return) {
|
|
211
|
-
pendingReturns.set(input.sessionID, configs[cmd].return);
|
|
204
|
+
if (cmd && configs[cmd]?.return?.length) {
|
|
205
|
+
pendingReturns.set(input.sessionID, configs[cmd].return[0]);
|
|
212
206
|
}
|
|
213
207
|
},
|
|
214
208
|
"experimental.chat.messages.transform": async (_input, output) => {
|
|
@@ -233,21 +227,23 @@ const plugin = async (ctx) => {
|
|
|
233
227
|
"experimental.text.complete": async (input) => {
|
|
234
228
|
// Handle non-subtask command returns (inject as follow-up message)
|
|
235
229
|
const pendingReturn = pendingNonSubtaskReturns.get(input.sessionID);
|
|
236
|
-
if (pendingReturn && client) {
|
|
237
|
-
|
|
230
|
+
if (pendingReturn?.length && client) {
|
|
231
|
+
const next = pendingReturn.shift();
|
|
232
|
+
if (!pendingReturn.length)
|
|
233
|
+
pendingNonSubtaskReturns.delete(input.sessionID);
|
|
238
234
|
await client.session.promptAsync({
|
|
239
235
|
path: { id: input.sessionID },
|
|
240
|
-
body: { parts: [{ type: "text", text:
|
|
236
|
+
body: { parts: [{ type: "text", text: next }] },
|
|
241
237
|
});
|
|
242
238
|
return;
|
|
243
239
|
}
|
|
244
|
-
// Handle chain
|
|
245
|
-
const
|
|
246
|
-
if (!
|
|
240
|
+
// Handle remaining returns (formerly chain)
|
|
241
|
+
const remaining = returnState.get(input.sessionID);
|
|
242
|
+
if (!remaining?.length || !client)
|
|
247
243
|
return;
|
|
248
|
-
const next =
|
|
249
|
-
if (!
|
|
250
|
-
|
|
244
|
+
const next = remaining.shift();
|
|
245
|
+
if (!remaining.length)
|
|
246
|
+
returnState.delete(input.sessionID);
|
|
251
247
|
await client.session.promptAsync({
|
|
252
248
|
path: { id: input.sessionID },
|
|
253
249
|
body: { parts: [{ type: "text", text: next }] },
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AACA,OAAO,IAAI,MAAM,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AACA,OAAO,IAAI,MAAM,MAAM,CAAC;AAoBxB,MAAM,cAAc,GAClB,2IAA2I,CAAC;AAE9I,MAAM,WAAW,GAAG,GAAG,GAAG,CAAC,GAAG,CAAC,IAAI,IAAI,EAAE,kCAAkC,CAAC;AAE5E,SAAS,aAAa,CAAC,GAAY;IACjC,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,GAAG,K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
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
3
|
"name": "@openspoon/subtask2",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.14",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "Opencode plugin for enhanced subtask control with return context and prompt chaining",
|
|
7
7
|
"main": "./dist/index.js",
|