Make your own event-sourced agent harness using stream processors — Jonas Templestein, Iterate
May 14, 2026 · 1:04:27
Jonas Templestein and Misha from Iterate introduce an event-sourced agent harness built on stream processors, arguing that agents should be modeled as an append-only event log with a synchronous reducer for state and an after-append hook for side effects. They demonstrate how every action—streaming chunks, tool calls, errors—becomes an event, enabling full debuggability and replay without re-running LLM calls. The key innovation is a "dynamic worker configured" event whose payload is a JavaScript processor; appending it to any stream instantly turns that stream into an AI agent with no server or dependencies. This allows processors from different authors and languages to compose on the same stream, and a safety checker can inject context within 200ms without blocking the agent. The hosts emphasize eventual consistency over before-hooks, and show deployment via Cloudflare Workers or by simply subscribing from any HTTP client.