Skip to content

feat: bot activity monitoring in UI (agent trace view) #26

Description

@jlunder00

Background

The bot orchestrator now runs multi-phase, multi-agent pipelines (think_and_plan → subagent dispatches → evaluate/retry → memory consolidation → final response). When a complex request triggers 3 retry rounds across 4 anchors, there's currently no way to see what's happening except waiting for the final Telegram message.

Goal

Real-time visibility into orchestrator activity in the web UI, push-based via the existing WebSocket connection (no polling).

Proposed design

Backend:

  • Bot emits structured events via _emit_event(phase, **data)POST /api/bot-eventmanager.broadcast()
  • Event types: bot_thinking, bot_dispatching (with dispatch N/M, action, anchor_id), bot_evaluating, bot_memory, bot_done
  • Subagent reports included in bot_done event

Frontend:

  • Handle new WS event types in existing listener
  • Live activity strip/panel showing current phase + progress
  • Collapsible per-dispatch detail (action, anchor, report, mutations applied)
  • Full agent trace for completed requests (expandable history)

Spec needed before implementation

  • What level of detail to show per subagent (just report? mutations list? prompt used?)
  • How long to retain traces (session only? persist in DB?)
  • UI placement (sidebar panel? inline in plan view? floating toast?)
  • Whether failed dispatches and retry rounds should be visually distinct

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions