From 93e22595cd59802a24253b100dcfae98a6849428 Mon Sep 17 00:00:00 2001 From: mayor Date: Wed, 21 Jan 2026 13:07:07 -0800 Subject: [PATCH] fix(deacon): add initial prompt to CLI start command The manager.go had the initial prompt fix for daemon-managed starts, but the CLI `gt deacon start` command was missing it. This caused the deacon to sit idle at the prompt after SessionStart hooks ran. Now both code paths include the GUPP initial prompt: "I am Deacon. Start patrol: check gt hook, if empty create mol-deacon-patrol wisp and execute it." This ensures the deacon starts working immediately regardless of whether it's started via CLI or daemon. Co-Authored-By: Claude Opus 4.5 --- internal/cmd/deacon.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/internal/cmd/deacon.go b/internal/cmd/deacon.go index 17286bcc..3d0971e2 100644 --- a/internal/cmd/deacon.go +++ b/internal/cmd/deacon.go @@ -413,9 +413,11 @@ func startDeaconSession(t *tmux.Tmux, sessionName, agentOverride string) error { return fmt.Errorf("creating deacon settings: %w", err) } - // Build startup command first - // Export GT_ROLE and BD_ACTOR in the command since tmux SetEnvironment only affects new panes - startupCmd, err := config.BuildAgentStartupCommandWithAgentOverride("deacon", "", townRoot, "", "", agentOverride) + // Build startup command with initial prompt for autonomous patrol. + // The prompt triggers GUPP: deacon starts patrol immediately without waiting for input. + // This prevents the agent from sitting idle at the prompt after SessionStart hooks run. + initialPrompt := "I am Deacon. Start patrol: check gt hook, if empty create mol-deacon-patrol wisp and execute it." + startupCmd, err := config.BuildAgentStartupCommandWithAgentOverride("deacon", "", townRoot, "", initialPrompt, agentOverride) if err != nil { return fmt.Errorf("building startup command: %w", err) }