fix(session): remove orchestrator kickoff auto-prompt on spawn#227
Merged
harshitsinghbhandari merged 2 commits intoJun 13, 2026
Conversation
Spawning a session without an explicit prompt injected a "Get oriented..." kickoff turn for orchestrators, which surfaced as an unsolicited message to the orchestrator. Drop the auto-prompt so a promptless spawn delivers nothing to the agent, leaving it idle at an empty input box. Closes #226 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
harshitsinghbhandari has reached the 50-review limit for trial accounts. To continue receiving code reviews, upgrade your plan.
Restore re-derives the standing system prompt but only handed it to the fresh-launch fallback, not the native GetRestoreCommand path, so a resumed orchestrator/worker lost its role instructions. Pass SystemPrompt through to the restore command too, matching adapters that re-append it on resume. Also fix the recordingAgent test double to return ok=false when there is no agent-session id, mirroring every real adapter, so the fallback-launch path is actually exercised. These three TestRestore_* cases were red on main since #222. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
harshitsinghbhandari has reached the 50-review limit for trial accounts. To continue receiving code reviews, upgrade your plan.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Two fixes:
1. Remove orchestrator kickoff auto-prompt on spawn (issue #226)
Spawning a session without an explicit prompt injected a
"Get oriented: review the current repo state..."kickoff turn for orchestrators, surfacing as an unsolicited message delivered on spawn. Removed theorchestratorKickoffPromptauto-injection inbuildSpawnTexts, so a promptless spawn now delivers nothing to the agent (it lands at an empty input box). The coordinator role still rides the system prompt, unchanged.2. Re-apply derived system prompt on agent resume (pre-existing main breakage)
While running the gate, the three
TestRestore_*cases insession_managerwere red — and they were already red onmain(the Go CI job on the latest main push is failing). Root cause:restoreArgvre-derives the standing system prompt but only handed it to the fresh-launch fallback, not the nativeGetRestoreCommandpath, so a resumed orchestrator/worker lost its role instructions. NowSystemPromptis passed through to the restore command too, matching adapters that re-append it on resume (cf.TestGetRestoreCommandReappendsSystemPromptin claudecode).The
recordingAgenttest double also returnedok=trueunconditionally, so the fallback-launch path was never exercised; it now returnsok=falsewithout an agent-session id, mirroring every real adapter.Changes
backend/internal/session_manager/manager.go: droporchestratorKickoffPrompt+ its injection; passSystemPromptinto theGetRestoreCommandRestoreConfig.backend/internal/session_manager/manager_test.go:TestSpawnOrchestrator_UsesCoordinatorPromptasserts an empty launch prompt;recordingAgent.GetRestoreCommandreturnsok=falsewithout an agent-session id.Testing
cd backend && go build ./... && go test -race ./...→ 1294 passed, 0 failed (63 packages).Closes #226