tui-agent-activity

TUI '4: Log' view doesn't show actual agent events (tool calls, output, decisions)

Metadata

Statusdone
Assignedagent-47
Agent identityf51439356729d112a6c404803d88015d5b44832c6c584c62b96732b63c2b0c7e
Created2026-04-26T16:43:16.382064410+00:00
Started2026-04-26T16:45:01.084693470+00:00
Completed2026-04-26T17:05:03.329436683+00:00
Tagseval-scheduled
Eval score0.61
└ blocking impact0.55
└ completeness0.60
└ coordination overhead0.65
└ correctness0.65
└ downstream usability0.65
└ efficiency0.70
└ intent fidelity0.83
└ style adherence0.50

Description

Description

User reports: the TUI has a '4: Log' view (tab 4) but it 'has no direct view of the actual events' from running agents. So the pane exists — it just isn't surfacing what the in-progress agents are actually DOING.

Today: an agent is running (you can see it in the agent/task list), but you can't watch its tool calls, file edits, partial output, or decision stream from the TUI. Have to drop to tail -f .wg/agents/agent-N/raw_stream.jsonl in another terminal.

Spec — what the Log view should show

For each in-progress agent (or a selectable per-agent stream):

  • Live stream of events as they happen: tool calls (with args), tool results (truncated), file edits (path + lines changed), text output, model thinking blocks (when present)
  • Auto-scroll on new events; pgup/pgdown / scroll wheel to scroll back; G/gg jump to bottom/top
  • Per-agent filter — switch between agents to see different streams. Default: show ALL agent streams interleaved with agent-id prefix
  • Persistence: when an agent finishes, the log stays viewable (read from the on-disk raw_stream.jsonl for that agent)
  • Color-code by event type (tool call vs result vs text vs error)

Investigation tasks

  • Locate the current Log view source (src/tui/log_pane.rs? grep for '4: Log' or 'Log' tab key in TUI). What does it currently render?
  • Where do agent events live? .wg/agents/agent-N/raw_stream.jsonl per the daemon — verify format and schema.
  • Is there a tail-and-parse path already, or do we need to build one?

Files likely to touch

  • The existing log-pane file (find via grep)
  • src/tui/viz_viewer/state.rs — pane state machine
  • src/tui/mod.rs — top-level layout / tab routing

Validation

  • Failing test first (TUI test caveats apply): test_log_view_renders_agent_stream_events_for_inprogress_task
  • Implementation makes test pass
  • cargo build + cargo test pass with no regressions
  • Manual smoke (live):
    • Start service, publish a task that takes >1 min, agent spawns
    • In wg tui, switch to '4: Log' tab → see live event stream from the spawned agent (tool calls, edits, output) populating in real time
    • Scroll back to see earlier events
    • With multiple agents alive, see all streams (per-agent prefixed) OR a per-agent picker
    • Agent finishes → log stays visible

Depends on

Required by

Log