The virtual operating system for agents.
An isolated operating system for every agent, embedded in the backend you already run: a file system, code execution, tools, and human review.
What agentOS is.
agentOS is an open-source library that boots a small virtual operating system for each agent VM you run: a virtual kernel with a file system, processes, networking, and deny-by-default permissions, inside your backend. Agents like Pi, Claude Code, Codex, and OpenCode run in it, and your code, or a framework like Eve or Flue, drives them through sessions, bindings, and workflows.
agent vm
node · python · shell
fs · processes · sockets · permissions
agent vm
node · python · shell
fs · processes · sockets · permissions
The benefits of a sandbox, without the sandbox.
Sandbox providers give every agent a full VM across a network gap and leave orchestration to you. agentOS runs each agent in its own VM inside your backend, with sessions, workflows, and approvals built in.
Faster starts, less memory, lower cost.
Measured against E2B, the fastest mainstream sandbox cold start, and Daytona, the cheapest per-second sandbox, as of March 30, 2026.
Workload: Minimal shell workload running simple commands
Why the gap: agentOS runs agents in-process — V8 isolates and Wasm inside your host. No VM to boot, no network hop, no disk image. Sandboxes must boot an entire environment, allocate memory, and establish a network connection before code can run.
Sandbox baseline: E2B, the fastest mainstream sandbox provider as of March 30, 2026.
agentOS: Median of 10,000 runs (100 iterations x 100 samples) on Intel i7-12700KF.4.8 ms
Why the gap: In-process isolates share the host's memory. Each additional execution only adds its own heap and stack. Sandboxes allocate a dedicated environment with a minimum memory reservation, even if the code inside uses far less.
Sandbox baseline: Daytona, the cheapest mainstream sandbox provider as of March 30, 2026. Default sandbox: 1 vCPU + 1 GiB RAM.
agentOS: ~22 MB for the minimal shell workload under sustained load.~22 MB
Sandboxes reserve idle RAM per agent.
server price per second / concurrent executions per serverWhy it's cheaper: Each execution uses ~22 MB instead of a ~1024 MB sandbox minimum. And you run on your own hardware, which is significantly cheaper than per-second sandbox billing.
Sandbox baseline: Daytona, the cheapest mainstream sandbox provider as of March 30, 2026. Default sandbox: 1 vCPU + 1 GiB RAM at $0.0504/vCPU-h + $0.0162/GiB-h.
agentOS: ~22 MB baseline per execution, assuming 70% utilization (industry-standard HPA scaling threshold). Select a hardware tier above to compare.$0.000000073/s
Assumes one agent per sandbox, needed for isolation.
Measured on Intel i7-12700KF. Cold start baseline: E2B, the fastest mainstream sandbox provider as of March 30, 2026. Cost baseline: Daytona, the cheapest mainstream sandbox provider as of March 30, 2026 (1 vCPU + 1 GiB default). Cost assumes 70% utilization on self-hosted hardware vs. per-second sandbox billing. Benchmark document
Any execution layer.
Agents write JavaScript, Python, and shell. agentOS runs all three natively behind one exec API, so an agent can script its work in JavaScript as easily as in bash.
Everything your agent expects from an operating system.
A persistent file system, session memory, integrations, human oversight, and preview URLs, in a single npm package.
Any agent harness
Claude Code, Codex, OpenCode, and Pi all run behind one unified API. Swap or add agents without touching your infrastructure.
Persistent file system
Mount a host directory, S3, Google Drive, or a custom JavaScript file system. State survives sleep and wake.
State previews
Every app the agent runs gets its own unique preview URL, served straight from the VM.
Integrations
Bindings turn your JavaScript functions into CLI commands inside the VM. Connect MCP servers, skills, and other agents.
Human in the loop
Each tool call raises a permission request your app approves or denies, from a client UI or a server-side hook. Unanswered requests reject after 120 seconds, and interactive PTYs let a person take over.
Memory
Sessions persist automatically with replayable transcripts, and sqlite3 runs inside the VM for structured agent memory.
Supports the tools you'd expect.
git, curl, ripgrep, jq, and SQLite run inside the VM. Browsers, file system mounts, and sandboxes install the same way from the registry.
Orchestrate fleets of agents in a few lines of code.
Durable sessions, multiplayer, and agent-to-agent delegation are built in, and every event streams back to your code. It works with the frameworks you already use, including Eve and Flue.
import { createClient } from "@rivet-dev/agentos/client";
import type { registry } from "./server";
const client = createClient<typeof registry>("http://localhost:6420");
const agent = client.vm.getOrCreate("my-agent").connect();
// Stream events (tool calls, text output, etc.)
agent.on("sessionEvent", (data) => console.log(data.event));
// Create a session and send a prompt
const session = await agent.createSession("pi", { env: { ANTHROPIC_API_KEY: process.env.ANTHROPIC_API_KEY! } });
await agent.sendPrompt(session.sessionId, "Write a Python script that calculates pi");Durable sessions
Every run is a managed session with its own state, history, and lifecycle. Pause, resume, and replay.
Workflows
Chain durable, multi-step workflows that survive restarts and pick up exactly where they left off.
Observability
Stream every event, tool call, and state change for full visibility into what your agents are doing.
Start local. Scale to millions.
agentOS runs as Rivet Actors, so agents live next to their state and deploy wherever you already ship. The same SDK runs as a library in development and as a platform in production.
Local Development as a Library
Install a package and run locally. No servers, no infrastructure — VMs and agents run in your process during development.
Get StartedRivet Cloud
Fully managed agentOS on a global edge network. Bring your own cloud or run on Rivet Compute. Zero-ops, scales to millions of agents.
Sign UpSelf-Host
Run the open-source Rivet platform on your own infrastructure — Kubernetes, Hetzner, VMs, and more.
Self-Hosting DocsGive your agents an OS.
agentOS is open source under Apache 2.0. Install it from npm and run it inside your existing backend.