ADR-007: Full TUI From Day One
Status
Accepted
Context
We could build a headless-only MVP first and add a TUI later, or build the TUI as a core feature from the start.
Decision
Build the full Ratatui TUI as a core feature. swarm start launches the TUI by default; --no-tui provides headless mode.
Rationale
- Observability is critical for a multi-agent system — users need to see what agents are doing in real time.
- Building the TUI later would require retrofitting state observation APIs.
- Ratatui is lightweight and well-suited for this use case.
Stack
- Ratatui for layout/rendering
- Crossterm as the terminal backend
Consequences
- TUI event loop must integrate with Tokio (poll crossterm events alongside async tasks).
- Agent states are exposed via
watch::Receiver<AgentState>channels for the TUI to observe. - Log viewing is file-based (tail agent's
current.log). - The TUI is the primary shutdown trigger (user presses
q).