PR #34 ships reply routing with a single pending pointer (set on inbound, consumed on agent_end). Kern + Flint confirmed the correlation is reliable for single-agent conversational use (agent_end fires once per prompt; most-recent pending correlates). Known limitation: if messages from DIFFERENT channels arrive before a turn completes, the reply routes to the most-recent channel (same-channel rapid messages are handled correctly → one coherent reply). Acceptable + non-blocking for the EA use (rare, degrades gracefully, always an allow-listed channel, no security issue). Follow-up: replace the single pointer with a FIFO queue of {channelId, replyTo} popped per agent_end, once the sendUserMessage→agent_end ordering under true concurrency is locked down. Low priority.
PR #34 ships reply routing with a single
pendingpointer (set on inbound, consumed onagent_end). Kern + Flint confirmed the correlation is reliable for single-agent conversational use (agent_end fires once per prompt; most-recent pending correlates). Known limitation: if messages from DIFFERENT channels arrive before a turn completes, the reply routes to the most-recent channel (same-channel rapid messages are handled correctly → one coherent reply). Acceptable + non-blocking for the EA use (rare, degrades gracefully, always an allow-listed channel, no security issue). Follow-up: replace the single pointer with a FIFO queue of {channelId, replyTo} popped per agent_end, once the sendUserMessage→agent_end ordering under true concurrency is locked down. Low priority.