Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 10 additions & 4 deletions plugins/omo/components/ultrawork/directive.md
Original file line number Diff line number Diff line change
Expand Up @@ -289,10 +289,16 @@ as inconclusive. Do not generate a plan before spawned research lanes
that feed the plan have returned or been closed as inconclusive.
Do not write the final answer, PR handoff, or completion summary while
active child agents remain open. Use short `multi_agent_v1.wait_agent` cycles.
After two silent waits send `TASK STILL ACTIVE: return <deliverable> or
BLOCKED: <reason>`. After four silent or ack-only checks, close the lane as
inconclusive, record that it is not approval, and respawn smaller only
if the deliverable is still required.
A silent wait is not a child-state transition and must not by itself
trigger `TASK STILL ACTIVE`, `close_agent`, or a respawn. Send
`TASK STILL ACTIVE: return <deliverable> or BLOCKED: <reason>` only when
the child has completed without the deliverable, responded ack-only
after a targeted followup, explicitly reported `BLOCKED:`, or is no
longer running. If no final status or completion signal exists, treat
the child as still active and continue independent root work. Close the
lane as inconclusive and respawn smaller only after one of those
non-running or non-delivering states is observed and the deliverable is
still required.

# Verification gate (TRIGGERED, NOT OPTIONAL)

Expand Down
19 changes: 19 additions & 0 deletions plugins/omo/components/ultrawork/test/codex-hook.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,25 @@ describe("codex ultrawork hook", () => {
expect(directive).toMatch(/WORKING:/);
});

it("#given directive #when wait_agent is silent #then timeout counters never close running children", () => {
// given
const payload = {
hook_event_name: "UserPromptSubmit",
prompt: "ulw",
};

// when
const output = runUserPromptSubmitHook(payload);
const parsed = parseHookOutput(output);

// then
const directive = parsed.hookSpecificOutput.additionalContext;
expect(directive).toMatch(/A silent wait is not a child-state transition/);
expect(directive).toMatch(/must not by itself\s+trigger `TASK STILL ACTIVE`/);
expect(directive).not.toMatch(/After two silent waits/);
expect(directive).not.toMatch(/After four silent/);
});

it("#given directive #when inspected #then keeps impact-proportional sizing invariants", () => {
// given
const payload = {
Expand Down
14 changes: 10 additions & 4 deletions plugins/omo/components/ulw-loop/directive.md
Original file line number Diff line number Diff line change
Expand Up @@ -289,10 +289,16 @@ as inconclusive. Do not generate a plan before spawned research lanes
that feed the plan have returned or been closed as inconclusive.
Do not write the final answer, PR handoff, or completion summary while
active child agents remain open. Use short `multi_agent_v1.wait_agent` cycles.
After two silent waits send `TASK STILL ACTIVE: return <deliverable> or
BLOCKED: <reason>`. After four silent or ack-only checks, close the lane as
inconclusive, record that it is not approval, and respawn smaller only
if the deliverable is still required.
A silent wait is not a child-state transition and must not by itself
trigger `TASK STILL ACTIVE`, `close_agent`, or a respawn. Send
`TASK STILL ACTIVE: return <deliverable> or BLOCKED: <reason>` only when
the child has completed without the deliverable, responded ack-only
after a targeted followup, explicitly reported `BLOCKED:`, or is no
longer running. If no final status or completion signal exists, treat
the child as still active and continue independent root work. Close the
lane as inconclusive and respawn smaller only after one of those
non-running or non-delivering states is observed and the deliverable is
still required.

# Verification gate (TRIGGERED, NOT OPTIONAL)

Expand Down