docs(subagents): default to background-first execution to avoid blocking the main chat - #26
Conversation
…ing the main chat The main session is the user's interactive channel; stalling it on builds, test suites, CR/CI watchers, or research fan-outs forces them to wait on work that could run detached. Background-first means: spawn independent or long-running agents with run_in_background: true, use the same flag for long Bash commands, never poll for results, and run foreground only when the very next step genuinely needs the output.
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughDocumentation updated to establish background-first execution as the default strategy for subagent work: ChangesBackground-first subagent execution strategy
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related PRs
Suggested labels
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Warning Tools execution failed with the following error: Failed to run tools: Stream initialization permanently failed: 13 INTERNAL: Received RST_STREAM with code 2 (Internal server error) Comment |
Summary
### 2. Subagent Strategywith a "Background-first" policy that sets background execution as the default for any long-running or independent work, explains when foreground is appropriate, and keeps the parallel-calls and lock-patterns guidance.## Background-first executionsection (placed between the PR-shipping tier split section and the model rubric), covering: background-by-default for builds/suites/watchers/sweeps/research, the never-poll rule, parallelizing independent work, handing control back while work runs, and keeping post-implementation verification honest.Rationale
Blocking the main (interactive) session on work that could run detached costs the user time and keeps the session context busy on waiting rather than on useful work. Making background-first the explicit default - rather than an implied option - closes the gap where agents default to foreground for convenience and stall the conversation.
Test plan
git diff --stat origin/mainreports exactly CLAUDE.md + subagent-strategy.md (2 files, 11 insertions, 1 deletion)security/directory is not staged or included in the commitSummary by CodeRabbit
Documentation