zot/internal/agent/modes
patriceckhart d653cc179d tui: slash commands work while a turn is in flight
previously typing any slash command during a turn was rejected with
"cancel the current turn (esc) before running a slash command".
annoying and unnecessary for read-only commands, and the
destructive ones can cancel the turn for you.

read-only commands run immediately, parallel to the streaming
turn: /help, /jump, /sessions, /lock, /unlock, /exit.

destructive commands trigger cancelAndWaitForIdle first (cancels
the turn ctx, polls i.busy at 10ms intervals, gives up after 2s
as a safety cap so a wedged http stream cannot freeze the ui
forever): /clear, /compact, /login, /logout, /model. once the
turn goroutine has wound down they run on the now-quiet agent.

slashCancelsTurn(head) in slash_suggest.go is the single source
of truth for which commands need the wait. readme updated to
match the new behaviour.
2026-04-19 11:21:37 +02:00
..
telegram add telegram bot bridge 2026-04-18 09:15:46 +02:00
dialog_frame.go tui: show 'update available' banner at top of chat 2026-04-18 11:49:22 +02:00
help.go add collapsible code blocks 2026-04-18 10:30:29 +02:00
interactive.go tui: slash commands work while a turn is in flight 2026-04-19 11:21:37 +02:00
json.go initial commit 2026-04-17 20:36:38 +02:00
jump_dialog.go tui: /jump to scroll to past turns, render cache for long transcripts 2026-04-18 12:22:16 +02:00
login_dialog.go initial commit 2026-04-17 20:36:38 +02:00
model_dialog.go add telegram bot bridge 2026-04-18 09:15:46 +02:00
print.go initial commit 2026-04-17 20:36:38 +02:00
session_dialog.go fix ci: portable syscall.Select via x/sys/unix; gofmt pass 2026-04-18 10:55:42 +02:00
slash_suggest.go tui: slash commands work while a turn is in flight 2026-04-19 11:21:37 +02:00
spinner.go fix ci: portable syscall.Select via x/sys/unix; gofmt pass 2026-04-18 10:55:42 +02:00
update_banner.go tui: show 'update available' banner at top of chat 2026-04-18 11:49:22 +02:00
welcome.go initial commit 2026-04-17 20:36:38 +02:00