Make your own event-sourced agent harness using stream processors — Jonas Templestein, Iterate

AI Engineer · Beginner ·🤖 AI Agents & Automation ·2mo ago

Key Takeaways

Building an event-sourced agent harness using stream processors

Original Description

The abstraction is three things: state, a synchronous reducer that derives state from events, and an after-append hook for side effects. The split matters: when your program restarts after 100 events, you want to catch up state without replaying LLM requests. Everything that happens (streaming chunks, tool calls, errors, circuit breaker triggers) is an event in the log. The interesting part is deployment. Jonas demos "dynamic worker configured," an event whose payload is a JavaScript string containing a processor. Append it to any stream and that stream becomes an AI agent without server or dependencies. The broader implication: processors from different authors on different servers can compose against the same stream, and a safety checker can inject context in a 200ms window before an LLM request without blocking the agent if it doesn't make it. Speaker info: - https://x.com/jonas - https://www.linkedin.com/in/jonashuckestein - https://github.com/jonastemplestein
Watch on YouTube ↗ (saves to browser)
Sign in to unlock AI tutor explanation · ⚡30

Related Reads

📰
How to Use AI APIs Without Giving Up Your Privacy
Learn how to use AI APIs without compromising your privacy, and discover ways to navigate the private AI chatbot landscape
Dev.to AI
📰
AlterLab vs Apify: Best API for AI Agent Data Pipelines
Choose the best API for AI agent data pipelines by comparing AlterLab and Apify
Dev.to · AlterLab
📰
Kevin Weil joins Stoke Space: why AI money is chasing rockets
Former OpenAI product chief Kevin Weil joins Stoke Space board, signaling AI investment in rocket technology, relevant for builders with limited budgets
Dev.to · Induwara Ashinsana
📰
Why we're building PotenAI with adaptive AI instead of static assessments
Learn how adaptive AI can improve career and personality assessments by providing more accurate and personalized results
Dev.to · Abdullah Huseynli
Up next
Which AI Stage Are You? From ChatGPT User to AI Agent Builder
Project Shift
Watch →