Part 1 of 4 · 1 min read
Overview
Agent runs include thinking, tool calls and waits. Users need progress, a way to stop, and approvals mid-run (Level 10 module 5). The transport choice affects deployment, scaling and failure behaviour. Interviewers ask "SSE or WebSockets for an agent UI, and what happens when the connection drops?"
About the example, and what is real
Real: SSE formatting, the incremental parser, the event store and replay, heartbeat and idle-timeout logic, bounded queue policies and the 20 test cases in code/mini-stream. Assumed: 60-second proxy idle timeout, 15-second heartbeat, event sizes and rates, queue size, the 95-second tool call. Not real: no real server, browser EventSource, proxy, WebSocket or network; the infrastructure claims about session affinity and horizontal scaling come from general knowledge, not from my tests.