zot/internal/agent
patriceckhart 853a089fc5 tui: unify accent bar, narrow status split, restore session usage
UI polish:

- Add Theme.AccentBar(c) helper that returns the half-block leader
  ("\u258c ") in colour c. Use it everywhere a speaker / prompt bar is
  drawn: main editor prompt, /btw editor + speaker labels, login
  code editor, welcome banner, --help headline, and the chat side
  speaker headers (you / zot, including the streaming overlay).
  Single source of truth for the bar style across the UI.

- Insert one blank row between the status bar and the editor and
  one trailing blank below the editor so the input has breathing
  room from the surrounding chrome instead of sitting flush against
  the status line and the terminal edge. Cursor row math is bumped
  +1 to account for the inserted row.

- Status bar narrow split: when the idle status line would exceed
  the terminal width, split it into provider/model on one row,
  token+cost+context stats on the next, then cwd, instead of
  letting the terminal hard-wrap mid-line. Mirrors the existing
  busy-prefix split.

Session cost restoration:

- Add core.SessionUsage(path) that scans a session file for the
  latest "usage" row and returns its cumulative usage (the running
  session total). Old sessions with no usage rows return zero.

- Seed the agent with that cumulative usage on every load path:
  /sessions picker, --continue, --resume, --session. Previously
  loading a session restored the messages but not the cost, so the
  status bar showed \/bin/bash.000 until the next turn produced a fresh
  EvUsage event.

- Mirror the seeded cost into i.cumUsage on NewInteractive (CLI
  startup loads) and applySessionSelection (in-tui /sessions load)
  so the status bar reflects the historical total immediately.
2026-04-27 19:51:36 +02:00
..
extensions feat(ext): interactive extension panels + persistence 2026-04-22 08:53:21 +02:00
modes tui: unify accent bar, narrow status split, restore session usage 2026-04-27 19:51:36 +02:00
tools fix(bash): kill process group immediately on cancel 2026-04-23 18:47:44 +02:00
args.go tui: unify accent bar, narrow status split, restore session usage 2026-04-27 19:51:36 +02:00
botcmd.go fix ci on windows: split detach helper into posix/windows variants 2026-04-18 10:58:10 +02:00
botcmd_unix.go fix ci on windows: split detach helper into posix/windows variants 2026-04-18 10:58:10 +02:00
botcmd_windows.go fix ci on windows: split detach helper into posix/windows variants 2026-04-18 10:58:10 +02:00
build.go feat: remove default step limit 2026-04-26 13:32:46 +02:00
changelog.go fix(changelog): strip commit/date suffix from version strings 2026-04-25 17:50:35 +02:00
cli.go tui: unify accent bar, narrow status split, restore session usage 2026-04-27 19:51:36 +02:00
config.go feat: auto-refresh OAuth tokens before each API call 2026-04-24 19:37:44 +02:00
extcmd.go feat: extension system (subprocess + json-rpc, any language) 2026-04-19 14:09:43 +02:00
modelsync.go feat(models): support user-defined models via models.json 2026-04-23 23:09:32 +02:00
rpc.go feat(ext): interactive extension panels + persistence 2026-04-22 08:53:21 +02:00
systemprompt.go feat(tui): context diffs + framed tool blocks + paced streaming 2026-04-20 15:50:39 +02:00
update.go fix(update): re-check every launch when the cache says up-to-date 2026-04-20 18:31:51 +02:00