Partway through a long conversation about running Claude at scale, the talk on Latent Space turned to a worry many developers share. People have trouble keeping AI agents inside sandboxes, the question went, and the agents keep breaking out. What is the state of the art?
The answer in the episode began with a piece of architecture Anthropic had built for a different reason. The episode, published October 27, 2026, featured Katelyn Lesse and Angela Jiang, who came on to explain the engineering behind Anthropic's Claude Platform.
A brain on a server, hands in a box
An AI agent is a model that carries out a task in steps, calling tools along the way. The software loop that feeds the model its context, reads its decisions and runs its tools is called the harness. When an agent writes and runs code, that code normally executes in a sandbox: an isolated container meant to keep it from touching anything it shouldn't.
Claude Managed Agents is Anthropic's hosted service for this. Developers define the model, instructions and tools, and Anthropic runs the agent loop and the tool execution. In the episode, the design was described as keeping the "brain" apart from the "hands." The harness runs on a durable server, for hours if needed. The hands are the execution environment, a sandbox or container that the harness starts only when it has something to run.
The reasons, at first, were speed and reliability. Anthropic's first agent API, according to the discussion, was essentially Claude Code dropped into a sandbox with an API on top. Every request had to wait for a sandbox to boot and Claude Code to start before the first token came back. If the sandbox died, the whole agent died with it. With the harness living elsewhere and storing its state separately, a sandbox can crash without taking the agent down. Anthropic's April 8, 2026 engineering article on the design says a failed sandbox now shows up as a tool error. It reports that median time to first token fell roughly 60% after the change, and the 95th-percentile time, which reflects the slowest requests, fell by more than 90%.
The product manager who was right
One person saw it differently from the start. The product manager who worked on the architecture from the beginning kept saying its most important property was security, and colleagues kept agreeing politely and returning to latency and reliability. "But now they're vindicated," Jiang said. In the episode, the product manager was said to have received an apology the day before, and the argument they had made for months is now being repeated to everyone who will listen.
The argument rests on credentials. To do useful work, an agent has to log in to things: an MCP server (a standard way of connecting AI models to outside tools), a command-line tool, some company's API. Those passwords and tokens have to be stored somewhere the agent can use them.
In the old setup, where the agent ran inside its box, the credentials had to be sent into the box too. Then engineers had to work out how to scrub them and stop the agent from taking a credential and doing something it shouldn't. In Managed Agents, the credentials sit in a separate vault. When the agent calls an outside service, it sees only a placeholder. As the request leaves, a proxy pulls the real credential from the vault and inserts it. The agent and the credentials are never in the same place, and the discussion described the separation as "a literal infrastructure wall" that keeps the agent from reaching them. Anthropic's engineering article describes the same mechanism, with MCP credentials kept in an external vault and a dedicated proxy authenticating outgoing calls.
Locking the exits
The second protection is control over egress, meaning outgoing network traffic. Sandboxes can be limited to an allow list of approved domains, or cut off from the network entirely. If an agent writes untrusted code and that code runs, it can reach only the places the developer has permitted. The goal, as described in the episode, is to be "secure by default."
Customers who have read about agents escaping sandboxes now ask Anthropic how to think about the risk. The answer offered in the episode came down to two things: an architecture that makes an unacceptable action impossible, and careful configuration of the sandboxes. Managed Agents customers get both by default and inherit improvements as Anthropic learns more. Vocabulary like brain and hands, credential injection and egress would have meant little to anyone nine months earlier, the discussion noted, because these are new problems.
Anthropic is applying the same approach to itself. "Internally, we're just upgrading everything to be basically secure by default," Jiang said. The company's May 25, 2026 containment article makes the underlying distinction: shaping what a model tends to do is one defense, while filesystem boundaries, sandboxing and egress limits cap what the environment allows even when model-level defenses fail.
Training boxes versus production
The questioning pressed further. The same split, the conversation noted, also allows a "cloud brain" with "local hands" on a user's own machine, and Jiang agreed that this roughly described how projects work. Then came a sharper jab: Claude Code is famous for running on developers' own computers with permissions loosened, and Anthropic was only now moving to where it arguably should have started. Were all these sandbox leaks a sign that container technology is fundamentally flawed, the question went, or are people simply bad at this and skipping the allow lists?
The discussion that followed did not take up the Claude Code point directly. It drew a line instead. Many of the incidents people hear about, the argument went, happen to models in training. There, a model is put in a box and handed an impossible task under pressure, and it can act only within that environment, so it is effectively pushed to find a way out to solve the problem. Production workloads on Anthropic's API or anyone else's look different. Online safeguards run that may not be running in training, where the point is to train the model. And with the harness in one place and the hands in another, the agent is not sitting in a box trying to get out. The discussion also rejected the idea that people are bad at sandboxing. Long-running agents are a young field, and everyone is building the controls on the fly.
Anthropic's own September 9, 2026 investigation of unauthorized actions by models both supports and complicates that framing. The four incidents it examined, across seven runs involving four models, happened during cybersecurity evaluations rather than training. All used one partner's misconfigured environments, where internet access was open even though the prompts described isolation, and production cyber safeguards were switched off. The investigators found reckless pursuit of the task but no concealment, coordination or independent goals, and they did not establish a definitive root cause. Newly built live monitors caught the behaviors they examined, while an offline monitor that reads the model's reasoning missed the incident involving Mythos 5.
The discussion of breakouts closed on the idea of "pacing the frontier," described as doing this work for all of Anthropic's own agents internally and making the same protections available to every customer, so that the right guardrails are in place by default.