⚡️ Why you should build Science Fiction — Sunil Pai, Cloudflare
Sunil Pai from Cloudflare discusses building efficient AI agent architectures using Durable Objects and Dynamic Workers as an alternative to platforms like Anthropic's. He explores the search for a standardized 'React-like' framework for agents, the culture of forking in open source, and encourages developers to pursue original, 'sci-fi' style projects.
Building Efficient AI Agent Architectures with Cloudflare
In response to new platforms like Anthropic’s cloud-managed agents, Cloudflare is positioned to offer a more efficient and powerful architecture for building AI agents. This capability is built upon two core primitives:
-
Durable Objects: Described as stateful serverless programming, this is presented as the first infrastructure-level implementation of the Actor Model. It allows for the creation of millions of stateful, background-running “things” with serverless characteristics, avoiding the overhead of spinning up entire virtual machines for state management.
-
Dynamic Workers: This technology provides a secure environment for evaluating LLM-generated code, a practice historically considered unsafe (
eval). Dynamic Workers offer a zero-startup-time environment where developers can expose only the specific APIs they want and can completely control—or by default, block—all outgoing traffic.
A practical application of this is how Cloudflare handles its own API, which has over 2,600 endpoints. Instead of exposing a tool for each endpoint, they use two tool calls: search and execute. The LLM generates and submits JavaScript code to these tools, which is then run in a secure isolate. This allows for complex, multi-step operations in a single, type-checked tool call, such as finding all workers associated with a DNS record starting with “Z” and applying DDoS protection to them. This approach leverages the strength of LLMs in code generation to create a more dynamic and efficient agentic system.
The Search for a Standardized “React” for AI Agents
The industry is currently in a discovery phase, searching for the definitive new architecture for building AI software. The current situation is compared to the web development world before React, where various frameworks existed but none had established a dominant, unifying pattern.
“No one has built the React yet… I suspect we everyone now everyone is building a harness and everyone’s like well it should be in this shape it should be in that shape. Uh someone needs to come out with some original thinking around something that is reproducible across languages across companies across infrastructure.”
While concepts like Anthropic’s “harness” (which separates the intelligence layer from the sandboxed execution environment) and “skills” are promising, a cross-platform, cross-language standard has yet to emerge. Skills are noted for their scalability and accessibility as plain English, but they face the challenge of becoming overly specific, at which point expressing the logic as code becomes more practical.
Open Source: Forking Culture and Modern Challenges
The conversation touches on a misunderstanding between Sunil and Vercel’s CTO over a forked project. This anecdote serves as a backdrop to a broader discussion on the nature of open source.
-
The Philosophy of Forking: Forking code is framed not as an act of theft, but as a “great sign of prestige and respect.” It is fundamental to the growth of open-source ecosystems, allowing developers to build upon prior work. The idea of “slop forks” is encouraged, as it enables developers to own their dependencies by vendoring and modifying them, thus avoiding systemic risks seen in incidents like the
xzbackdoor. -
Adversarial Environment: Today, popular open-source repositories have become “adversarial grounds.” Maintainers face significant challenges, leading some to shut down public contributions entirely. A major issue is the rise of fake security reports, which are now a primary vector for attacks on open-source projects.
A Call for Originality and Courage
The discussion concludes with an encouragement for developers to leverage modern tools to be more ambitious and original. Instead of making incremental improvements or solely chasing enterprise contracts, developers have an unprecedented agency to change the world.
“Don’t even try to do something incrementally better. Build sci-fi stuff… I want people to just be original. I want them to try the wild stuff for which infrastructure and LLM almost fail you at this moment. Like how do we get to the next step change? Uh I this is my only thing I desire of people like just I I’m begging you to be original and to have courage to try a new idea.”