taskchef 7.12.1 → 7.12.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/.codex-plugin/plugin.json +1 -1
- package/README.md +4 -3
- package/docs/spec.md +6 -4
- package/docs/workflows.md +3 -2
- package/package.json +1 -1
- package/skills/taskchef-delegate/SKILL.md +4 -4
- package/skills/taskchef-executor/SKILL.md +7 -5
- package/src/delegation.js +10 -5
package/README.md
CHANGED
|
@@ -88,9 +88,9 @@ $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
|
-
`$taskchef-executor` invocation immediately before the final
|
|
93
|
-
marker. That skill reads the executor's own `CODEX_THREAD_ID`, self-links, and
|
|
91
|
+
the assignment visible from the first line, leave one blank line, then place
|
|
92
|
+
an explicit `$taskchef-executor` invocation immediately before the final
|
|
93
|
+
correlation marker. That skill reads the executor's own `CODEX_THREAD_ID`, self-links, and
|
|
94
94
|
reports lifecycle state. Independent outcomes may become separate executors;
|
|
95
95
|
dependent work should stay together.
|
|
96
96
|
|
|
@@ -104,6 +104,7 @@ 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
|
+
|
|
107
108
|
Use $taskchef-executor to execute and report this delegated TaskChef assignment.
|
|
108
109
|
<!-- taskchef_id=c0f010ff-84f2-4838-a69d-0ff1f5d721d7 -->
|
|
109
110
|
```
|
package/docs/spec.md
CHANGED
|
@@ -119,10 +119,11 @@ 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
|
|
123
|
-
concise explicit `$taskchef-executor`
|
|
124
|
-
returned marker on the final line. It MUST
|
|
125
|
-
|
|
122
|
+
and remaining uninterrupted, followed by exactly two newline characters
|
|
123
|
+
(one blank line), exactly one concise explicit `$taskchef-executor`
|
|
124
|
+
invocation, one newline, and the returned marker on the final line. It MUST
|
|
125
|
+
NOT place a blank line between the invocation and marker or inline the
|
|
126
|
+
executor protocol into a new instruction.
|
|
126
127
|
4. It MUST call `record_task` with `threadId: null` before native creation.
|
|
127
128
|
5. It MUST create exactly one native Codex executor and return immediately.
|
|
128
129
|
6. The executor MUST read its own `CODEX_THREAD_ID` and call `link_task`
|
|
@@ -143,6 +144,7 @@ visibly and MUST NOT continue substantive work.
|
|
|
143
144
|
|
|
144
145
|
Previously recorded instructions with the trailing marker before the
|
|
145
146
|
invocation, with or without the former blank line before that marker; a
|
|
147
|
+
former compact assignment-to-invocation boundary with the marker last; a
|
|
146
148
|
first-line HTML marker; the older first-line
|
|
147
149
|
`# taskchef_id=<full UUID>` heading, or the former blank line and inline
|
|
148
150
|
executor protocol MUST remain marker-readable and executable. Their
|
package/docs/workflows.md
CHANGED
|
@@ -107,8 +107,9 @@ 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,
|
|
111
|
-
`$taskchef-executor` invocation immediately before its
|
|
110
|
+
The generated task begins with the complete assignment, leaves one blank line,
|
|
111
|
+
then places one explicit `$taskchef-executor` invocation immediately before its
|
|
112
|
+
final marker. Older
|
|
112
113
|
recorded tasks with first-line HTML or heading markers and former inline
|
|
113
114
|
protocol remain readable; the deprecated `report_result` alias preserves their
|
|
114
115
|
semantic callbacks.
|
package/package.json
CHANGED
|
@@ -53,12 +53,12 @@ stop and report that the TaskChef plugin must be reloaded or installed.
|
|
|
53
53
|
|
|
54
54
|
- Begin with the actual assignment on the first line and keep its complete
|
|
55
55
|
body uninterrupted.
|
|
56
|
-
- After the assignment's final character, add exactly
|
|
57
|
-
invocation on its own line:
|
|
56
|
+
- After the assignment's final character, add exactly two newline characters
|
|
57
|
+
so there is one blank line before this invocation on its own line:
|
|
58
58
|
`Use $taskchef-executor to execute and report this delegated TaskChef assignment.`
|
|
59
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
|
|
61
|
-
|
|
60
|
+
and the preparation's exact marker on its own final line. Do not add a
|
|
61
|
+
blank line between the invocation and marker.
|
|
62
62
|
- Include exactly one marker and exactly one executor-skill invocation.
|
|
63
63
|
- Do not inline executor ownership, identity, linking, or result-reporting
|
|
64
64
|
protocol. The explicitly invoked executor skill owns those mechanics.
|
|
@@ -9,10 +9,11 @@ Own and execute the delegated assignment in the current Codex task. Do not
|
|
|
9
9
|
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
|
-
New instructions present the complete assignment first, followed by exactly
|
|
13
|
-
newline, the explicit skill invocation, one
|
|
14
|
-
`<!-- taskchef_id=<full UUID> -->` marker on the final
|
|
15
|
-
|
|
12
|
+
New instructions present the complete assignment first, followed by exactly two
|
|
13
|
+
newline characters (one blank line), the explicit skill invocation, one
|
|
14
|
+
newline, and the exact `<!-- taskchef_id=<full UUID> -->` marker on the final
|
|
15
|
+
line. There is no blank line between the invocation and marker. Treat that UUID
|
|
16
|
+
as the TaskChef task ID.
|
|
16
17
|
The assignment is everything before the invocation; the invocation and marker
|
|
17
18
|
are lifecycle scaffolding, not part of the deliverable. Require exactly one
|
|
18
19
|
marker and do not infer an ID from similar prose.
|
|
@@ -79,7 +80,8 @@ TaskChef exposes only `report_result`, follow its inline protocol; after an
|
|
|
79
80
|
upgrade, the deprecated `report_result` alias remains available for exact
|
|
80
81
|
legacy retries. Also accept historical trailing instructions that place the
|
|
81
82
|
marker before the invocation, with or without the former blank line before the
|
|
82
|
-
marker;
|
|
83
|
+
marker; the former compact assignment-to-invocation boundary with the marker
|
|
84
|
+
last; an exact HTML marker on the first line with or without the former blank
|
|
83
85
|
line; or the older exact
|
|
84
86
|
first-line `# taskchef_id=<full UUID>` heading. These compatibility forms do not
|
|
85
87
|
change the identity or lifecycle rules above. For either first-line form, the
|
package/src/delegation.js
CHANGED
|
@@ -162,13 +162,18 @@ export function parseTaskChefMarker(instruction) {
|
|
|
162
162
|
return hasHistoricalAssignment() ? id : null;
|
|
163
163
|
}
|
|
164
164
|
const executorSkillReferences = instruction.match(/\$taskchef-executor\b/gi) ?? [];
|
|
165
|
+
const hasCurrentCompactBoundary = index >= 2
|
|
166
|
+
&& lines.at(index - 2).trim().length > 0;
|
|
167
|
+
const hasCurrentBlankBoundary = index >= 3
|
|
168
|
+
&& lines.at(index - 2) === ""
|
|
169
|
+
&& lines.at(index - 3).trim().length > 0;
|
|
170
|
+
const currentAssignmentEnd = hasCurrentCompactBoundary ? index - 1 : index - 2;
|
|
165
171
|
const isFinalMarkerScaffold = index === lines.length - 1
|
|
166
|
-
&&
|
|
172
|
+
&& (hasCurrentCompactBoundary || hasCurrentBlankBoundary)
|
|
167
173
|
&& lines[0].trim().length > 0
|
|
168
174
|
&& lines.at(-2) === EXECUTOR_SKILL_INVOCATION
|
|
169
|
-
&& lines.
|
|
170
|
-
&&
|
|
171
|
-
&& !lines.slice(0, index - 1).some((line) => HISTORICAL_EXECUTOR_SCAFFOLD_LINES.has(line))
|
|
175
|
+
&& hasTaskSpecificContent(lines.slice(0, currentAssignmentEnd))
|
|
176
|
+
&& !lines.slice(0, currentAssignmentEnd).some((line) => HISTORICAL_EXECUTOR_SCAFFOLD_LINES.has(line))
|
|
172
177
|
&& executorSkillReferences.length === 1;
|
|
173
178
|
if (isFinalMarkerScaffold) return id;
|
|
174
179
|
|
|
@@ -212,7 +217,7 @@ export function prepareDelegation(instruction, { taskId = randomUUID() } = {}) {
|
|
|
212
217
|
const id = requireUuid(taskId);
|
|
213
218
|
return {
|
|
214
219
|
id,
|
|
215
|
-
instruction: `${body}\n${EXECUTOR_SKILL_INVOCATION}\n${taskChefMarker(id)}`,
|
|
220
|
+
instruction: `${body}\n\n${EXECUTOR_SKILL_INVOCATION}\n${taskChefMarker(id)}`,
|
|
216
221
|
};
|
|
217
222
|
}
|
|
218
223
|
|