fix(agents): prevent orchestrator from rushing ahead of background agents

Tighten Background Result Collection instructions so the model waits
for explore/librarian results instead of duplicating their work and
delivering premature answers.

- Remove 'Continue working immediately' which models interpreted as
  'do ALL work yourself, ignore agents'
- Clarify step 2: only do DIFFERENT independent work while waiting
- Add explicit step 3: end response when no other work remains
- Add 'not for files you already know' to explore section header

Fixes #2124, fixes #1967
This commit is contained in:
mrosnerr
2026-03-05 12:57:39 -05:00
committed by YeonGyu-Kim
parent 18f84fef93
commit 2f06f2c3b9
2 changed files with 6 additions and 7 deletions
+1 -1
View File
@@ -116,7 +116,7 @@ export function buildExploreSection(agents: AvailableAgent[]): string {
return `### Explore Agent = Contextual Grep
Use it as a **peer tool**, not a fallback. Fire liberally.
Use it as a **peer tool**, not a fallback. Fire liberally for discovery, not for files you already know.
**Use Direct Tools when:**
${avoidWhen.map((w) => `- ${w}`).join("\n")}