From a1fb65010d0d0421c105dd3fe3065c8e4d23eea1 Mon Sep 17 00:00:00 2001 From: arkon Date: Mon, 19 Jan 2026 12:26:37 +0100 Subject: [PATCH] fix: improve respawn idle/working detection patterns MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Add '↵ send' as primary idle indicator (suggestion ready) - Add 'Synthesizing', 'Brewing' to working patterns - Add '✻', '✽' activity indicators to working patterns Co-Authored-By: Claude Opus 4.5 --- src/respawn-controller.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/respawn-controller.ts b/src/respawn-controller.ts index 24528b68..73f46ba1 100644 --- a/src/respawn-controller.ts +++ b/src/respawn-controller.ts @@ -82,8 +82,9 @@ export class RespawnController extends EventEmitter { private promptDetected: boolean = false; private workingDetected: boolean = false; - // Terminal patterns + // Terminal patterns - detect when Claude is ready for input private readonly PROMPT_PATTERNS = [ + '↵ send', // Suggestion ready to send (strongest indicator of idle) '❯', // Standard prompt '\u276f', // Unicode variant '⏵', // Claude Code prompt variant @@ -93,7 +94,9 @@ export class RespawnController extends EventEmitter { private readonly WORKING_PATTERNS = [ 'Thinking', 'Writing', 'Reading', 'Running', 'Searching', 'Editing', 'Creating', 'Deleting', 'Analyzing', 'Executing', + 'Synthesizing', 'Brewing', // Claude's processing indicators '⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏', // Spinner chars + '✻', '✽', // Activity indicators (spinning star) ]; private readonly CLEAR_COMPLETE_PATTERN = /conversation cleared|cleared|❯|⏵/i; private readonly INIT_COMPLETE_PATTERN = /initialized|analyzing|❯|⏵|CLAUDE\.md/i;