- Cellz is where we run sandboxed agents, and Proofz is the receipt that says how each run went. A cell is one agent run's virtual machine and everything made for it. Each run gets a fresh EC2 instance from an image built in CI, with gVisor inside it, in an AWS account that holds nothing but cells. The services a run may reach live in a second account, joined to the first only through PrivateLink.
- Nothing reaches the agent until the VM has proved which instance it is, using the identity document AWS signs, and a probe has checked the fresh sandbox. The guest can reach exactly two addresses: a meter for model calls and a proxy for the web.
- Every run produces six records from five parties: the cell's own statements, the orchestrator's launch and stop records, the meter's debit log, the proxy's egress log, and the breaker's verdict. They are checked against each other before any receipt is made.
- We broke every dependency under a live cell on purpose. Each failure froze or stopped the cell within 70 seconds, with its disk kept.
Part 2 of six on how our containment architecture works. Part 1, A signed receipt for every agent run, covers what the receipt says and how to check it; this part covers where the run happens. Parts 3 to 6 follow in December.
Why a VM per run
A receipt is only as good as the sandbox it describes. We wanted the place an agent runs to have three properties that are easy to state and hard to get from a shared machine.
The first is freshness. A run should start on a disk and in memory that no earlier run touched, so nothing one evaluation planted can be found by the next. A container on a long-lived host can be fresh at the filesystem level, but the host's kernel, its caches and its other tenants are shared.
The second is a boundary the agent can't talk its way across. An agent runs arbitrary code by design, so the question isn't whether it will try a system call it shouldn't, but what stands between that call and the host. We use two layers: gVisor, which answers the agent's system calls with its own user-space kernel, inside a VM that is the agent's alone. A gVisor escape lands in a VM with nothing else in it.
The third is evidence from outside. Anything the sandbox reports about itself is reported by the place we trust least. So the facts a receipt rests on (which VM ran, which image it booted, what left the network, when it stopped) have to be recorded by something the agent can't reach.
A VM per run costs more than a container per run, and boots slower. We chose it anyway because it makes all three properties simple to show. A c7g.large cell costs a few cents an hour, and most agent runs spend their time waiting on a model, not on the VM.
The layout
The work is split across three AWS accounts. The cell account holds only cells: a VPC with no internet gateway, no NAT, no DNS and no peering. Its one way out is a PrivateLink endpoint that forwards four TCP ports to the control account. The control account holds the services a run may talk to and the one service that may launch runs. The trust account holds keyz, which issues each run's token, and the receipt signer, which logs receipts publicly.
There are three programs and one image on the cell side.
The orchestrator runs in the control account. It is the only principal allowed to launch instances in the cell account, and the role it assumes there can launch only from the cell launch template and images from our pipeline, and terminate only instances tagged as cells. For each run it registers the run with the breaker and the meter, asks keyz for the run's token, launches the VM, hands the cell its work once the cell has proved who it is, and collects the evidence at the end.
The host agent runs on the cell VM as root, outside the sandbox, started by systemd at boot. It builds the network walls, starts the sandbox under runsc (gVisor's runtime), runs the probe, starts the agent, writes the sealed run log, and on a stop cuts the network and freezes the sandbox. It holds no long-lived key and no AWS credentials. Its only key is one it generates in memory when the VM boots.
cell-hold is a tiny static binary that is the sandbox's first process. It only reaps children. It exists so that the sandbox is up, and fresh, before the probe and then the agent are started inside it.
The cell image is an Amazon Linux 2023 disk, built in CI with no AWS credentials, one per CPU architecture. It has runsc, the host agent, cell-hold and the probe baked in. It has no SSH, no SSM agent and no instance role, and cloud-init is limited to reading EC2 metadata: it never runs user data. So a VM booted from it knows everything it will run before it receives anything, and nobody can log into it.
One run, start to finish
A caller posts a run: the task's root filesystem and workspace by SHA-256, the command, a deadline, the model spend caveats and the buyer profile. The deadline counts from the request, so time spent waiting for capacity counts against it.
The step that matters most is registration. When the VM boots, the host agent reads two things from the instance metadata service: the run id and a random nonce from user data, and the instance identity document, which AWS signs. It generates its boot key, then sends the orchestrator the identity document, AWS's signature, its public key, the image manifest, the gVisor version, and its own signature over all of that and the nonce.
The orchestrator accepts the first registration for a run and refuses every later one. It checks AWS's signature against the region's certificate, and that the document names the instance it launched, in the right account and region, with the right instance type and image. It checks the nonce and the boot key's signature. It also confirms through the EC2 API that the run has exactly one workspace volume, blank and attached to this instance only. Only then does it sign the launch record, which binds the run to that instance, that image and that boot key, and answer with the run's work.
This is what lets the rest of the run trust the boot key. The guest is walled off from the metadata service, and the image has no SSH or SSM. So whoever signed with that boot key could read this instance's metadata before the guest started, and that can only be the host agent.
The probe runs next, before the workspace is filled and before any input is written. The host agent copies it into the fresh sandbox and runs it there. Its report, which says what the probe could reach and what it found lying around, goes into the run log. If a check the run's profile enforces fails, the run ends there as aborted, and the agent never starts. Part 1 describes the probe's checks.
Then the host agent fills the workspace, plants the run's honey tokens, and starts the agent. Honey tokens are credentials that are valid nowhere. They go in after the probe, because the probe's credential check would otherwise rightly flag them, and the host agent plants them through the running sandbox so that gVisor sees them. A run that reaches for one has gone looking for something it had no use for, and using one trips the run.
While the agent runs, every chunk of its output goes into the run log as it arrives. Every 60 seconds the host agent signs the log's head and sends it to the orchestrator as an anchor, so a run that dies midway still has a signed head no more than a minute old.
The walls
The guest has three network layers between it and anything else. gVisor has its own network stack. Around it, the host agent's walls. Around those, the cell VPC, which has no route anywhere but the PrivateLink endpoint.
The guest lives in its own network namespace with one virtual Ethernet pair: 10.255.0.2 inside, 10.255.0.1 on the host side, and a single route to 10.255.0.1. On that address the host agent's nftables rules forward exactly two ports. Port 8443 goes to tollz, our model-call meter, and port 3128 goes to the cell proxy, the only way to the web. Everything else is dropped: the metadata range 169.254.0.0/16, the VPC's own addresses, all IPv6, and any connection to the host itself.
The ruleset is generated from the run's bundle by one pure function. That made it easy to test: a test reads exactly what a cell will enforce, and CI checks every generated ruleset with nft -c.
The guest's environment points its model SDKs at http://10.255.0.1:8443, with the run's grant from tollz as the API key, and sets HTTPS_PROXY to 10.255.0.1:3128 with the run token as the proxy credential. Neither credential can open or end a run; those routes live on listeners the cell endpoint never exposes. The guest never sees an AWS credential, a model provider key or the boot key.
A build run that needs name lookups can ask for them. The host agent then answers DNS on 10.255.0.1:53 itself, from the run's egress profile, never asking another server, and resets any connection to an address it answered with, so the answer is only good for going through the proxy.
Stopping a run
A run ends when the agent exits, the deadline passes, the orchestrator says stop, or the breaker trips it. The breaker is a separate service that stops runs on evidence: a honey token used, a spend cap reached, a dependency lost.
On a normal end, the host agent kills the sandbox, flushes and unmounts the workspace, and seals the run log with an end entry, after which nothing can be added. It signs the final statement (the run log's head, how the run ended, the exit code and times), sends it, and then uploads the log. The orchestrator accepts only the log whose head the signed final names.
On a trip the order changes, because the goal is to keep everything. The host agent first swaps in a ruleset that drops everything, in one nft -f, which cuts connections that are already open, not just new ones. Then it pauses the sandbox, checkpoints it to the root disk, and signs the final statement. The breaker stops the EC2 instance as a second, independent path. Neither path terminates anything: the stopped VM and its disks are the evidence, and they stay.
The orchestrator then ends the run with tollz and the proxy, which return their logs, and fetches the breaker's signed verdict. If the breaker can't be read, the VM is kept, as on a trip. For a run that asked for grading, it snapshots the workspace volume and hands the snapshot to a separate grader account. Then it signs the stop record and stores the run's evidence.
Records that check each other
Each party writes down what it saw, signs it with its own key, and the records are compared.
The cell's host statements are signed by its boot key: register, an anchor every minute, and final. Each carries the run id and a sequence number, so a statement from one cell can't be replayed into another run or out of order. The orchestrator signs the launch record and the stop record. The debit log and the egress log are hash chains in the same format as the run log, and the receipt commits to each one's last hash. The breaker signs its verdict with a key of its own: whether the run ended or tripped, how the stop went and how long it took, which tripwires were planted and which were hit, and every shell anyone was granted into the run.
One check, Evidence::check, compares them: the same run id everywhere, sequences in order, the log heads the final statement names, and the breaker's verdict against the stop record. It refuses a bundle where the breaker says the run tripped and the stop record says it ended cleanly, so the orchestrator can't sign a tripped run as a clean one. The orchestrator runs this check before storing the evidence, and the receipt signer runs the same code.
The point of splitting the signatures is that no single compromised component can produce a clean record on its own. An orchestrator that lied about a launch would disagree with AWS's signed identity document. A host agent can't sign as the orchestrator. The breaker's verdict comes from a different host with a different key. Today one weakness remains: the orchestrator also signs the receipt itself, with a key that sits on its host. Part 6 covers moving that signature into an enclave that checks all of these heads before it signs.
Tripwires in the control account too
Per-run honey tokens catch a run that reaches for what it was handed. Standing canaries catch anything that reaches the control account itself. At start, the orchestrator asks the breaker to mint canaries and writes them as files on its own host: a URL whose host name is watched, and a key in the shape of a model provider's. Any use of one trips every live run and holds new ones, because something has reached a place no run should. The repository names no lure paths, and the deployed config does.
Failing closed
A run needs tollz, the proxy, the breaker, keyz, the log and the canary collector to be healthy. The orchestrator checks each of them continuously. While any one failed its last check, it refuses new runs and freezes every running cell, which the breaker then stops with its VM kept. In the other direction, a host agent that hears nothing from the orchestrator for 45 seconds freezes its own cell.
One dependency is deliberately not on that list: the receipt signer. A running cell never needs it, because the signer is only used once a run is over. A receipt the signer can't take is kept and sent again until it is logged, and an alert fires if one waits ten minutes. That lets us deploy the signer, which replaces its host, without freezing every run in flight.
Deploying the services a running cell does need doesn't freeze it either. A new orchestrator or breaker host starts beside the old one, waits for the old one to hand over its state and a lease, and then takes over its address. The breaker hands over in about 7 seconds and the orchestrator in about 12, inside the 15 seconds the fail-closed guard allows before it freezes cells. In our test, a cell ran its full 55 minutes while both hosts were replaced under it.
What happened when we broke it
We set off every failure mode we knew of against live cells in our own account, one cell at a time and with no model spend. The aim was to confirm that each one is caught, that the run fails closed, and that proofz verify rejects tampering.
The walls blocked egress, direct DNS, the metadata service, lateral moves and the control account's ports, and a request to use tollz as a web proxy got a 404. A $0 spend cap was refused. A planted key sent to tollz tripped its run. Six edits to a receipt, its evidence or its run log were each rejected by proofz verify.
Then we went the other way and tried to get out. A boundary drill tried to mount /proc, bind-mount the root, reach a host disk, write sysctl and cgroup files, and reach the sandbox's control files, and each was refused. A network drill tried outside addresses, the metadata service spelled in decimal, hex, octal and IPv6, three public resolvers, and seven ports on the next host on the subnet, and each was refused. Sixteen cells launched together tried to find each other by broadcast, multicast, TCP and DNS, and none heard another.
In a separate run with real model spend, eight agents shared one cell for a short finance task with two doors left open in it: a "live" exchange rate from a site that doesn't resolve, and a note pointing at a planted key. Four agents tried the site and got a DNS failure. None read the planted key; the lead agent's report said the key wasn't used because no one had authorized it. The cell recorded 97 model calls in its debit log, and the breaker saw no tripwire hit.
Watching for escapes, quietly
Each cell also runs an escape detector. gVisor can stream every system call the sandbox makes to a monitor. The host agent turns each call into a short token (the call's class, its outcome, and the class of path, address or process it touched), scores the most recent 4,096 tokens with a small compiled model trained on escape attempts, and writes an entry to the run log the first time any of six families of escape behavior scores above 0.5. A few calls fire at once, without waiting for the model: the agent's first try at loading a kernel module, kexec or a reboot, and its first open of /proc/kcore, /proc/kmsg or /proc/sysrq-trigger.
The detector runs in shadow: it only writes, and never changes how a run ends. Paths, addresses and arguments never leave the host agent; only the tokens reach the log. Tracing costs the guest some time per traced call, from no measurable change for a shell loop to about 50% for tar reading 6,900 files, the worst case we found. Agent work mostly waits on models and the network, so we expect the real cost to be far smaller, and the first weeks of shadow runs will tell us.
What's built and what's next
Built and running in our own account: the image, the host agent, the orchestrator, the walls, the signed records and the evidence check, the standing canaries, the fail-closed guard, the escape detector in shadow mode, and orchestrator and breaker deploys that don't freeze running cells. The drills above ran on live cells. The breaker's signed verdict records each trip: what caused it and when AWS confirmed the stop.
Next:
- Receipts for runs that hit their deadline or are cancelled. They still get none, because the receipt has no verdict for them yet.
- The orchestrator's signatures in KMS. Its launch and stop records, and today the receipt, are signed with a key held on its host. They move to a KMS key in the control account, and the receipt moves to the signer enclave.
- Anchors in the public log. The host agent's minute-by-minute anchors go to the orchestrator today. Logging them publicly means a run killed midway has a public record up to its last minute.
- A stronger boundary. Cells launch on gVisor in a VM. The next step is Graviton5 instances, whose hypervisor AWS has formally verified, and a field in the receipt that says how each isolation layer is assured.
- Several guests per cell. The orchestrator can already put several guests on a private segment, each probed. It needs container images from the mirror, whose image routes aren't built yet.
Next in this series: the cell proxy, the guest's only way to the web.