feat(tui): debug-pane audit logging surface (v0.10.0)
Adds wire-level visibility appropriate for a debugging TUI. Every SSE event arrival now lands as one debug-pane line; token-rate Text and Thinking deltas get aggregated counters surfaced in a per-turn summary instead of per-delta spam. Audit surfaces added (all routed to the debug pane): - per-event arrival: timestamp + event type + sse_id + event-specific summary for WorkerPhase / ToolStart / ToolResult / TextBoundary / Done / Error / Cancelled - turn-summary at terminal events: text_deltas / text_bytes / thinking_deltas / thinking_bytes / elapsed_ms - app-level state-machine transitions via new RatatoskrApp._transition helper (idle → streaming → cancelling → idle, with reason) - worker_spawn line at on_input_submitted with content_len - ctrl_c / ctrl_d audit lines documenting action + exit code - cancel POST lifecycle: _cancel_via_sse takes an optional audit callback and emits issued / ok / failed lines - app_mounted bootstrap line at on_mount (server + agent + session tail + raw + end_user_id) - wire-error exception class + body audit at _stream_turn_worker Helpers: - TuiPresenterState: text_delta_count / text_byte_count / thinking_delta_count / thinking_byte_count / turn_start_ts - module-level _ts() + _audit_line() + RatatoskrApp._audit() / _transition() Tests: 6 new test cases lock in audit-line shape, turn-summary aggregation, cancel-POST lifecycle callback, and the silence of per-Text-delta debug writes.
This commit is contained in:
+1
-1
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
||||
|
||||
[project]
|
||||
name = "ratatoskr"
|
||||
version = "0.9.0"
|
||||
version = "0.10.0"
|
||||
description = "Worldtree Conversation API debug TUI — multi-pane observability dashboard"
|
||||
readme = "README.md"
|
||||
requires-python = ">=3.12"
|
||||
|
||||
Reference in New Issue
Block a user