Engineering brief
How OpenGov Replaced LangGraph with an Effect-Native Agent Loop
At a glance
- Relevance
- Practical value
- Warnings
- None
OpenGov abandoned LangGraph for a custom Effect-native agent loop, gaining tracing, structured concurrency, and safety via human approvals and sandboxing. That trade-off paid off in operational control but demands functional programming expertise.
Custom agent infrastructure can deliver control and safety that general frameworks lack; the trade‑off is steep functional programming expertise.
Summary
OpenGov abandoned LangGraph for a homegrown agent loop built on the Effect TypeScript library. The move gave them full control over tracing, structured concurrency, and model swapping—essential for complex multi-product assistants. The architectural bet paid off in operational control but demands a team comfortable with functional programming and building infrastructure in-house.
They adopted Google's Agent-to-Agent (A2A) protocol as a rigid contract between frontend and backend, ensuring that agent cards and routes are always consistent. Their core pattern is a tools-and-skills architecture: product teams independently build toolkits registered with the model, enabling parallel development of customer‑facing AI capabilities while keeping the agent loop centralized.
Safety is enforced by deterministically interrupting the loop for human approval on mutating tool calls and by running code execution inside ephemeral sandboxes. Long context is handled via rolling summarization with recall, avoiding token‑limit headaches. All of this is observed through Effect’s automatic tracing, which makes cross‑service debugging and profiling straightforward without extra instrumentation.
The talk promotes Effect heavily, but the real signal is that production agents often require custom infrastructure to meet safety, observability, and multi‑team scaling requirements. ‘Tools and skills are all you need’ is an oversimplification, yet it captures a decoupled architecture that lets model quality and business capabilities evolve independently.
Watch the video
This video is blocked due to your privacy settings. To watch this video, please accept YouTube marketing cookies.
Related breakdowns
300 agents in 60 people: The ungoverned AI agent sprawl
A 60-person company discovered 300 AI agents running daily. The security and cost surprises that followed apply to every team deploying agents today.
Google's managed agents: convenience vs lock-in for agent deployment.
Google's managed agents promise seamless scaling and multi-agent workflows. But the real signal is the operational overhead tradeoff and vendor lock-in risk.
AI Engineers: Stop Writing Features, Start Building the Loop
The AI engineer role is pivoting from coding features to building self-improving agent loops. But enterprise data messiness and eval trust are open questions.
Get TL;DW
Too Long; Didn't Watch.
A concise breakdowns of the AI and devtools videos that actually matter for engineering leaders.
Free. Weekly. No hype.
Video and thumbnails remain the property of their respective creators. tldw.news provides editorial analysis, commentary, and discovery links to original content.