taskchef 7.11.0 → 7.11.1
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/.codex-plugin/plugin.json +1 -1
- package/README.md +6 -6
- package/docs/spec.md +13 -12
- package/docs/workflows.md +2 -2
- package/package.json +1 -1
- package/skills/taskchef-delegate/SKILL.md +13 -11
- package/skills/taskchef-executor/SKILL.md +11 -10
- package/src/delegation.js +11 -1
package/README.md
CHANGED
|
@@ -88,11 +88,11 @@ $taskchef-delegate In payments, add structured logs for failed retries and test
|
|
|
88
88
|
|
|
89
89
|
TaskChef prepares a UUID and marker, persists the task before native creation,
|
|
90
90
|
creates the executor, and returns its task link. New executor instructions keep
|
|
91
|
-
the assignment visible from the first line, then place
|
|
92
|
-
|
|
93
|
-
reads the executor's own `CODEX_THREAD_ID`, self-links, and
|
|
94
|
-
state. Independent outcomes may become separate executors;
|
|
95
|
-
should stay together.
|
|
91
|
+
the assignment visible from the first line, then place an explicit
|
|
92
|
+
`$taskchef-executor` invocation immediately before the final correlation
|
|
93
|
+
marker. That skill reads the executor's own `CODEX_THREAD_ID`, self-links, and
|
|
94
|
+
reports lifecycle state. Independent outcomes may become separate executors;
|
|
95
|
+
dependent work should stay together.
|
|
96
96
|
|
|
97
97
|
At the start of every dispatcher turn, the managed workspace instructions ask
|
|
98
98
|
the MCP server to best-effort ensure the dashboard. A startup failure never
|
|
@@ -104,8 +104,8 @@ For example, TaskChef generates this shape:
|
|
|
104
104
|
|
|
105
105
|
```text
|
|
106
106
|
Fix duplicate charges after a retry and add a regression test.
|
|
107
|
-
<!-- taskchef_id=c0f010ff-84f2-4838-a69d-0ff1f5d721d7 -->
|
|
108
107
|
Use $taskchef-executor to execute and report this delegated TaskChef assignment.
|
|
108
|
+
<!-- taskchef_id=c0f010ff-84f2-4838-a69d-0ff1f5d721d7 -->
|
|
109
109
|
```
|
|
110
110
|
|
|
111
111
|
## Work with and report executors
|
package/docs/spec.md
CHANGED
|
@@ -18,7 +18,7 @@ is dated research, not contract.
|
|
|
18
18
|
| **Delegated task** | One independently useful outcome represented by one TaskChef task UUID and snapshot. |
|
|
19
19
|
| **Executor** | The native Codex task created to own and perform one delegated task. |
|
|
20
20
|
| **Task record** | One complete JSON object in `tasks.jsonl`; it contains immutable intent/project fields and mutable identity/result fields. |
|
|
21
|
-
| **Marker** | The exact correlation line `<!-- taskchef_id=<lowercase full UUID> -->`; new instructions place it
|
|
21
|
+
| **Marker** | The exact correlation line `<!-- taskchef_id=<lowercase full UUID> -->`; new instructions place it on the final line, immediately after the executor-skill invocation. |
|
|
22
22
|
| **Record-before-create** | Persisting a link-pending task before asking Codex to create its executor. |
|
|
23
23
|
| **Self-linking** | The executor's one-way registration of its own canonical Codex UUIDv7 from `CODEX_THREAD_ID`. |
|
|
24
24
|
| **Link-pending** | A working task whose `threadId` is null and `updatedBy` is `dispatcher`. |
|
|
@@ -119,10 +119,10 @@ the final link, preserving the delegate skill's immediate-return contract.
|
|
|
119
119
|
1. The dispatcher MUST call `prepare_dispatch` once per outcome.
|
|
120
120
|
2. It MUST choose exactly one configured project and exact native-project path.
|
|
121
121
|
3. It MUST build the instruction with the user's outcome beginning on line 1
|
|
122
|
-
and remaining uninterrupted, followed by exactly one newline,
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
122
|
+
and remaining uninterrupted, followed by exactly one newline, exactly one
|
|
123
|
+
concise explicit `$taskchef-executor` invocation, one newline, and the
|
|
124
|
+
returned marker on the final line. It MUST NOT place blank lines around the
|
|
125
|
+
invocation or marker or inline the executor protocol into a new instruction.
|
|
126
126
|
4. It MUST call `record_task` with `threadId: null` before native creation.
|
|
127
127
|
5. It MUST create exactly one native Codex executor and return immediately.
|
|
128
128
|
6. The executor MUST read its own `CODEX_THREAD_ID` and call `link_task`
|
|
@@ -141,16 +141,17 @@ If native creation fails after recording, the dispatcher MUST call
|
|
|
141
141
|
A link failure MUST remain visible and retryable; the executor MUST report it
|
|
142
142
|
visibly and MUST NOT continue substantive work.
|
|
143
143
|
|
|
144
|
-
Previously recorded instructions with the
|
|
145
|
-
|
|
144
|
+
Previously recorded instructions with the trailing marker before the
|
|
145
|
+
invocation, with or without the former blank line before that marker; a
|
|
146
|
+
first-line HTML marker; the older first-line
|
|
146
147
|
`# taskchef_id=<full UUID>` heading, or the former blank line and inline
|
|
147
148
|
executor protocol MUST remain marker-readable and executable. Their
|
|
148
149
|
`report_result` calls MUST remain supported by the deprecated alias. New
|
|
149
|
-
instructions MUST use the
|
|
150
|
-
above. A historical first-line instruction with an
|
|
151
|
-
MUST contain exactly one invocation as its final
|
|
152
|
-
instruction MUST retain non-whitespace
|
|
153
|
-
lifecycle paragraphs.
|
|
150
|
+
instructions MUST use the explicit executor invocation followed by the final
|
|
151
|
+
trailing marker contract above. A historical first-line instruction with an
|
|
152
|
+
executor-skill invocation MUST contain exactly one invocation as its final
|
|
153
|
+
line. A former inline-protocol instruction MUST retain non-whitespace
|
|
154
|
+
task-specific content beyond its known lifecycle paragraphs.
|
|
154
155
|
|
|
155
156
|
`needs_input` MUST mean a semantic user decision or missing fact. A native
|
|
156
157
|
approval prompt MUST remain live Codex state and MUST NOT be stored as
|
package/docs/workflows.md
CHANGED
|
@@ -107,8 +107,8 @@ Record-before-create makes native creation failure observable. Executor
|
|
|
107
107
|
self-linking removes dispatcher-side polling, task search, title matching, and
|
|
108
108
|
parent/child identity inference.
|
|
109
109
|
|
|
110
|
-
The generated task begins with the complete assignment, then places
|
|
111
|
-
|
|
110
|
+
The generated task begins with the complete assignment, then places one explicit
|
|
111
|
+
`$taskchef-executor` invocation immediately before its final marker. Older
|
|
112
112
|
recorded tasks with first-line HTML or heading markers and former inline
|
|
113
113
|
protocol remain readable; the deprecated `report_result` alias preserves their
|
|
114
114
|
semantic callbacks.
|
package/package.json
CHANGED
|
@@ -11,17 +11,18 @@ and return immediately.
|
|
|
11
11
|
## Invocation boundary
|
|
12
12
|
|
|
13
13
|
A task whose initial structured `codexDelegation.input` contains either the
|
|
14
|
-
exact new trailing
|
|
15
|
-
an
|
|
14
|
+
exact new trailing `$taskchef-executor` invocation plus final TaskChef marker,
|
|
15
|
+
an accepted former trailing marker-plus-invocation scaffold, an exact
|
|
16
|
+
first-line HTML marker, or the historical first-line
|
|
16
17
|
`# taskchef_id=<full UUID>` heading already owns that delegated assignment.
|
|
17
18
|
This includes former inline-protocol tasks that lack the skill invocation.
|
|
18
19
|
An owned instruction must have exactly one accepted marker and a non-whitespace
|
|
19
20
|
task-specific assignment. If it contains an executor-skill invocation, require
|
|
20
|
-
exactly one
|
|
21
|
-
misplaced-invocation inputs are not valid
|
|
22
|
-
in the current task. Do not re-dispatch it
|
|
23
|
-
or a configured project. Explicit requests
|
|
24
|
-
valid.
|
|
21
|
+
exactly one adjacent to the marker in an accepted order. Marker-only,
|
|
22
|
+
duplicate-marker, scaffold-only, or misplaced-invocation inputs are not valid
|
|
23
|
+
delegated tasks. Execute a valid one in the current task. Do not re-dispatch it
|
|
24
|
+
merely because it concerns TaskChef or a configured project. Explicit requests
|
|
25
|
+
to delegate separate work remain valid.
|
|
25
26
|
|
|
26
27
|
Use the bundled `prepare_dispatch`, `record_task`, and `report_state` MCP tools
|
|
27
28
|
directly. Never fall back to shell writes. If a required tool is unavailable,
|
|
@@ -52,11 +53,12 @@ stop and report that the TaskChef plugin must be reloaded or installed.
|
|
|
52
53
|
|
|
53
54
|
- Begin with the actual assignment on the first line and keep its complete
|
|
54
55
|
body uninterrupted.
|
|
55
|
-
- After the assignment's final character, add exactly one newline and
|
|
56
|
-
|
|
57
|
-
or after the marker.
|
|
58
|
-
- Immediately after the marker, end the instruction with exactly:
|
|
56
|
+
- After the assignment's final character, add exactly one newline and this
|
|
57
|
+
invocation on its own line:
|
|
59
58
|
`Use $taskchef-executor to execute and report this delegated TaskChef assignment.`
|
|
59
|
+
- Immediately after the invocation, end the instruction with one newline
|
|
60
|
+
and the preparation's exact marker on its own final line. Do not add blank
|
|
61
|
+
lines around the invocation or marker.
|
|
60
62
|
- Include exactly one marker and exactly one executor-skill invocation.
|
|
61
63
|
- Do not inline executor ownership, identity, linking, or result-reporting
|
|
62
64
|
protocol. The explicitly invoked executor skill owns those mechanics.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: taskchef-executor
|
|
3
|
-
description: "Execute an assignment carrying either the new exact TaskChef
|
|
3
|
+
description: "Execute an assignment carrying either the new exact TaskChef invocation-plus-final-marker scaffold or an accepted historical first-line or marker-before-invocation protocol. Includes executor ownership, self-linking, per-turn lifecycle reporting, identity safety, and final semantic state. Use when explicitly invoked by a new delegated instruction or when resuming the same new or historical executor task. Do not use to dispatch work or report on other TaskChef tasks."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# TaskChef Executor
|
|
@@ -10,12 +10,12 @@ re-dispatch it merely because it concerns TaskChef or a configured project.
|
|
|
10
10
|
Explicit requests to delegate separate work remain valid.
|
|
11
11
|
|
|
12
12
|
New instructions present the complete assignment first, followed by exactly one
|
|
13
|
-
newline, the
|
|
14
|
-
|
|
15
|
-
marker. Treat that UUID as the TaskChef task ID.
|
|
16
|
-
before the
|
|
17
|
-
part of the deliverable. Require exactly one
|
|
18
|
-
similar prose.
|
|
13
|
+
newline, the explicit skill invocation, one newline, and the exact
|
|
14
|
+
`<!-- taskchef_id=<full UUID> -->` marker on the final line. There are no blank
|
|
15
|
+
lines around the invocation or marker. Treat that UUID as the TaskChef task ID.
|
|
16
|
+
The assignment is everything before the invocation; the invocation and marker
|
|
17
|
+
are lifecycle scaffolding, not part of the deliverable. Require exactly one
|
|
18
|
+
marker and do not infer an ID from similar prose.
|
|
19
19
|
|
|
20
20
|
## Start every execution turn
|
|
21
21
|
|
|
@@ -77,9 +77,10 @@ Existing delegated tasks may include the former inline ownership, linking, and
|
|
|
77
77
|
re-dispatching. Prefer `report_state` when available. If an older installed
|
|
78
78
|
TaskChef exposes only `report_result`, follow its inline protocol; after an
|
|
79
79
|
upgrade, the deprecated `report_result` alias remains available for exact
|
|
80
|
-
legacy retries. Also accept historical instructions
|
|
81
|
-
before
|
|
82
|
-
|
|
80
|
+
legacy retries. Also accept historical trailing instructions that place the
|
|
81
|
+
marker before the invocation, with or without the former blank line before the
|
|
82
|
+
marker; an exact HTML marker on the first line with or without the former blank
|
|
83
|
+
line; or the older exact
|
|
83
84
|
first-line `# taskchef_id=<full UUID>` heading. These compatibility forms do not
|
|
84
85
|
change the identity or lifecycle rules above. For either first-line form, the
|
|
85
86
|
assignment follows the marker. Ignore the final executor invocation and any
|
package/src/delegation.js
CHANGED
|
@@ -162,6 +162,16 @@ export function parseTaskChefMarker(instruction) {
|
|
|
162
162
|
return hasHistoricalAssignment() ? id : null;
|
|
163
163
|
}
|
|
164
164
|
const executorSkillReferences = instruction.match(/\$taskchef-executor\b/gi) ?? [];
|
|
165
|
+
const isFinalMarkerScaffold = index === lines.length - 1
|
|
166
|
+
&& index >= 2
|
|
167
|
+
&& lines[0].trim().length > 0
|
|
168
|
+
&& lines.at(-2) === EXECUTOR_SKILL_INVOCATION
|
|
169
|
+
&& lines.at(-3).trim().length > 0
|
|
170
|
+
&& hasTaskSpecificContent(lines.slice(0, index - 1))
|
|
171
|
+
&& !lines.slice(0, index - 1).some((line) => HISTORICAL_EXECUTOR_SCAFFOLD_LINES.has(line))
|
|
172
|
+
&& executorSkillReferences.length === 1;
|
|
173
|
+
if (isFinalMarkerScaffold) return id;
|
|
174
|
+
|
|
165
175
|
const hasCompactBoundary = index >= 1
|
|
166
176
|
&& lines.at(index - 1).trim().length > 0;
|
|
167
177
|
const hasHistoricalBlankBoundary = index >= 2
|
|
@@ -202,7 +212,7 @@ export function prepareDelegation(instruction, { taskId = randomUUID() } = {}) {
|
|
|
202
212
|
const id = requireUuid(taskId);
|
|
203
213
|
return {
|
|
204
214
|
id,
|
|
205
|
-
instruction: `${body}\n${
|
|
215
|
+
instruction: `${body}\n${EXECUTOR_SKILL_INVOCATION}\n${taskChefMarker(id)}`,
|
|
206
216
|
};
|
|
207
217
|
}
|
|
208
218
|
|