Matt Carrie and Sunil Pai from Cloudflare present durable objects and dynamic workers as innovative compute primitives that enable stateful, low-latency, and globally distributed AI applications by allowing secure, on-demand execution of user- or AI-generated code with persistent state. Their platform simplifies building collaborative AI experiences and complex workflows by integrating with popular AI SDKs, supporting multiple languages, and abstracting distributed system complexities, positioning Cloudflare as a leader in scalable, flexible, and secure serverless computing.
In this presentation, Matt Carrie and Sunil Pai from Cloudflare introduce their work on AI agents built on Cloudflare’s unique infrastructure, particularly focusing on durable objects. Durable objects are described as a stateful serverless compute model that allows code to maintain state across requests, overcoming traditional serverless limitations where state is lost between invocations. This technology enables low-latency, globally distributed applications, exemplified by real-time collaborative tools like TLDraw, and serves as an ideal foundation for building AI agents that require persistent state and background processing.
The speakers highlight the evolution of their platform, including the development of dynamic workers—a new compute primitive that allows running user-generated or AI-generated code securely and efficiently in isolated environments. Unlike traditional serverless functions, dynamic workers can execute arbitrary code strings on demand, providing a sandboxed environment with fine-grained control over capabilities and network access. This innovation opens up possibilities for more flexible and powerful AI applications, such as running code generated by large language models (LLMs) or enabling complex workflows without the overhead of full virtual machines or containers.
Matt and Sunil emphasize the practical benefits of their approach, such as seamless resumable streaming and multi-device synchronization, which are challenging to implement with conventional serverless architectures. Durable objects inherently support these features, making it easier to build collaborative and stateful AI experiences. They also discuss how their backend integrates with popular AI SDKs like Vercel’s, enhancing production readiness with features like tool calls and session synchronization. This infrastructure aims to simplify the development of AI-powered applications by abstracting away complex distributed systems concerns.
The conversation touches on the broader vision of enabling users and developers to generate and run code dynamically within a secure and scalable environment. This capability challenges traditional notions of code execution security and enterprise restrictions, with Cloudflare positioning itself as a pioneer in providing a fast, cheap, and secure platform for such use cases. They also mention support for multiple programming languages, including JavaScript, Python, and WASM-based languages like Zig, further broadening the platform’s applicability.
Finally, the presenters share insights into upcoming features and projects, such as a new CMS built entirely on their platform and enhanced plugin security through dynamic workers. They invite the audience to explore their open-source resources, attend their talks, and engage with the community. The overall message is that Cloudflare’s durable objects and dynamic workers represent a transformative compute primitive that can redefine how AI agents and serverless applications are built, offering unprecedented flexibility, scalability, and developer experience.