From 44b2f048c861870073b6580a4cb54a53584ef91b Mon Sep 17 00:00:00 2001 From: Sawyer Cutler Date: Fri, 23 Oct 2026 09:33:43 -0700 Subject: [PATCH] fix(prompts): forbid tool-less status announcements in dispatch card --- packages/prompt-fragments/src/cards.ts | 1 + src/prompts.test.ts | 2 ++ 2 files changed, 3 insertions(+) diff --git a/packages/prompt-fragments/src/cards.ts b/packages/prompt-fragments/src/cards.ts index 83cc31baf..4b3602ce5 100644 --- a/packages/prompt-fragments/src/cards.ts +++ b/packages/prompt-fragments/src/cards.ts @@ -19,6 +19,7 @@ ${dispatchRouteSection()} - Read only enough to route and write a useful brief. Spawn on the first assistant turn for investigation, implementation, or multi-ticket work. Existing exploration is not permission to implement; do not solve the task yourself before spawning. # Rules +- A reply with no tool calls ends the turn — never emit a standalone status line before spawning; call spawn_agent in the same turn. - Edit files with file tools only, never shell redirection or sed. - Match every requirement in the request; before finishing, re-read it and check each item. - Use manage_tasks for work of three or more steps. diff --git a/src/prompts.test.ts b/src/prompts.test.ts index 935be5cb8..8f705d583 100644 --- a/src/prompts.test.ts +++ b/src/prompts.test.ts @@ -28,6 +28,8 @@ test("dispatch card is spawn-first with no parallelization cap", () => { expect(prompt).toMatch(/first assistant turn/i); expect(prompt).toMatch(/same turn/i); expect(prompt).toMatch(/same live job/i); + expect(prompt).toMatch(/reply with no tool calls ends the turn/i); + expect(prompt).toMatch(/standalone status/i); expect(prompt).not.toMatch(/Latest operator turn is law/i); expect(prompt).not.toMatch(/Do not duplicate a live worker/i); expect(prompt).not.toMatch(/diagnostic fleet/i);