Building a Full-Context Background Coding Agent with Sandboxed Development Environments

ramp · Finance · 2026 · source Agentic: yes · promotional bias: med · source-backed · extracted with prompt 0.5.4 (schema v2)

Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.

Problem

Domain: Background coding-agent infrastructure

Ramp needed a background coding agent that could start as fast as a local agent, run complete development environments, verify work with internal tools, support non-engineers, and scale to many concurrent coding sessions.

Constraints:

Architecture

Ramp built Inspect on Modal Sandboxes. Each session starts from a filesystem snapshot rebuilt every 30 minutes, giving the agent a full-stack environment with Postgres, Redis, Temporal, RabbitMQ, OpenCode, VS Code server, terminal, VNC, Chromium, GitHub, Slack, Buildkite, Sentry, and Datadog. Modal Functions rebuild snapshots, Dicts coordinate locks and image metadata, and Queues route prompts from Slack, web, and Chrome extension clients into the right session.

Diagram confidence: explicit (topology described by the source).

flowchart LR
  client-surfaces[Client surfaces] --> modal-queues[Modal Queues]
  modal-queues --> inspect-session[Inspect session]
  modal-dicts[Modal Dicts] --> inspect-session
  modal-functions[Modal Functions] --> filesystem-snapshots[Filesystem snapshots]
  filesystem-snapshots --> modal-sandbox[Modal Sandbox]
  inspect-session --> modal-sandbox
  modal-sandbox --> opencode-agent[OpenCode agent]
  opencode-agent --> developer-tools[Developer tools]
  developer-tools --> modal-sandbox
Drag to pan · scroll or use +/− to zoom · reconstructed from the source's described component topology

Components

Component Role Interacts with
Client surfaces Slack, web interface, hosted VS Code editor, streamed desktop view, and Chrome extension. Modal Queues, Inspect session
Modal Functions Cron-driven repository clone, dependency install, build, and snapshot generation jobs. Filesystem snapshots
Filesystem snapshots Near-current sandbox filesystem state rebuilt every 30 minutes and used for fast startup. Modal Functions, Modal Sandbox
Modal Queues Routes prompts from client surfaces into the right Inspect session. Client surfaces, Inspect session
Modal Dicts Stores locks and image metadata for shared coordination and multiplayer sessions. Inspect session
Inspect session Session coordinator that binds clients, queues, locks, sandbox state, and agent execution. Client surfaces, Modal Queues, Modal Dicts, Modal Sandbox
Modal Sandbox Isolated cloud development environment for one coding-agent session. Filesystem snapshots, Inspect session, OpenCode agent, Developer tools
OpenCode agent Coding agent running inside the sandbox with access to code, services, and verification tools. Modal Sandbox, Developer tools
Developer tools VS Code server, terminal, VNC, Chromium, GitHub, Slack, Buildkite, Sentry, Datadog, and internal services. Modal Sandbox, OpenCode agent

Data flow

A builder starts from Slack, web, or Chrome. Modal Queues route the prompt to the correct Inspect session. A Modal Sandbox starts from the latest snapshot, runs OpenCode plus development services, and verifies changes with tools such as browser screenshots and observability integrations. Modal Dicts coordinate session locks and image metadata for multiplayer state, while GitHub and Buildkite handle review and CI workflows.

3 supporting quotes
“Each Inspect session runs in a Modal Sandbox containing a full-stack development environment: Postgres, Redis, Temporal, RabbitMQ, and every service an engineer would have locally.”article, stated
“Queues route prompts from any client — Slack, web, Chrome extension — into the right session”article, stated
“Dicts manage session locks and store image metadata, providing the shared coordination layer that makes multiplayer sessions possible”article, stated

Why this architecture

Ramp used Modal because cloud sandboxes solved the adoption barrier for background agents: fast startup, full internal context, unlimited parallel capacity, and zero local setup. Modal's distributed primitives let Ramp focus on the agent experience while Modal handled coordination, snapshots, and concurrent sandbox execution.

3 supporting quotes
“they knew that a background agent that was slower or less capable than working locally would never get adopted. Performance was crucial.”article, stated
“Since Modal handles the distributed coordination, Ramp's team could focus entirely on the agent experience — the tools, the integrations, the UX — rather than the infrastructure underneath.”article, stated
“This is where background agents pull ahead of local ones. Inspect gives every builder at Ramp what Rahul describes as "effectively hundreds of computers that they can work on simultaneously."”article, stated

Models used: OpenCode · LLMs used by Inspect

Scale

Alternatives considered (roads not taken)

Local coding agents

Rejected because: Local agents required environment setup and could not easily integrate with Ramp's internal tooling.

“They wanted to go beyond what was possible with local agents, which required dev environment setup and couldn't easily integrate with internal tooling.”article, stated

Cold sandbox startup from scratch

Rejected because: Snapshots let sessions start from a nearly current state and avoid slow clone/install work.

“Because filesystem snapshots are stored as diffs from the base image, only the modified files are persisted—keeping them fast and lightweight.”article, stated

Building distributed coordination infrastructure in-house

Rejected because: Modal Functions, Dicts, Queues, and Sandboxes provided the primitives Ramp needed.

“Outside the sandbox, the rest of Inspect's infrastructure is built on Modal's distributed primitives:”article, stated

Patterns

batch-offline-processing (infrastructure)

Repository images and filesystem snapshots are prepared on a 30-minute cron so interactive sessions avoid setup latency.

“Functions run on a cron job every 30 minutes to clone repositories, install dependencies, and build fresh filesystem snapshots”article, stated

latency-optimization (operations)

Filesystem snapshots and delta syncs make cloud sandboxes start fast enough to compete with local agents.

“Since the snapshot is at most 30 minutes old, syncing with the head of the repo is nearly instant.”article, stated

tool-use-orchestration (orchestration)

Inspect wires the agent into developer services, browser verification, CI, GitHub, Slack, and observability tools.

“The whole setup is wired into GitHub, Slack, Buildkite, and Ramp's observability stack including Sentry and Datadog.”article, stated

multi-agent-orchestration (orchestration)

Builders can run multiple versions of prompts and let Inspect spawn child sessions across repositories.

“A builder can kick off multiple versions of the same prompt, try different models, or let Inspect spawn child sessions to parallelize work across repositories—all running concurrently in the cloud.”article, stated

human-in-the-loop-gate (workflow)

The outcome is review-ready pull requests, not automatic merging; engineers and other builders review generated changes.

“The current generation is already producing review-ready pull requests.”article, stated

Tradeoffs

Use Modal Sandboxes for execution

Chose ephemeral full-stack cloud environments over local machines or lightweight tool-only execution.

Rationale: Sandboxes provided fast startup, services, isolation, and effectively unlimited parallel capacity.

“Ramp spins up full development environments in seconds, giving every builder at the company access to what is effectively unlimited parallel engineering capacity”article, stated

Expose Inspect beyond engineers

Chose Slack, web, VS Code, desktop stream, and Chrome extension clients over an engineer-only CLI or IDE integration.

Rationale: The goal was for product managers and designers to ship changes too, without local setup.

“give every builder at Ramp—engineers, product managers, designers—the ability to ship code using AI.”article, stated

Rely on Modal primitives for coordination

Chose Functions, Dicts, Queues, and Sandboxes over custom distributed coordination infrastructure.

Rationale: This let Ramp scale from prototype to hundreds of sessions without rewriting the infrastructure.

“a prototype built in days scaled to hundreds of concurrent sessions without a rewrite.”article, stated

Gotchas (what bit them)

Hosted coding agents fail adoption if they feel slower than local workflows.

Root cause: Developers compare against local agent latency and environment availability.

Resolution: Use prebuilt snapshots and cloud sandboxes that start in seconds.

“it had to start just as fast as a local agent”article, stated

Cloud agents need the same internal context humans use to verify changes.

Root cause: Coding alone is insufficient for production; frontend and backend work needs CI, observability, browsers, and services.

Resolution: Put the full development stack and verification tools inside the sandbox.

“confirm its work visually—just as a human would.”article, stated

Multiple client surfaces can conflict if they do not share session state.

Root cause: Slack, web, Chrome, and multiplayer sessions all feed prompts to the same work.

Resolution: Route prompts through queues and coordinate locks/metadata with Modal Dicts.

“decoupling input from execution so multiple clients can feed into one session without conflicts”article, stated

Evaluation

The source evaluates adoption and operational impact by pull-request share, self-hosting usage, session concurrency, startup speed, and ability to produce review-ready PRs.

Metrics: over half of merged pull requests · over 80% of Inspect written by Inspect · few-second session start · hundreds of concurrent sessions

“roughly half of all merged pull requests across Ramp's frontend and backend repos are started by Inspect”article, stated
“End-to-end, sessions start working on a prompt in a few seconds.”article, stated

Outcomes

The article reports over-half PR share, over 80% self-authorship of Inspect, sessions starting in seconds, and hundreds of concurrent sessions.

“Within a couple of months, roughly half of all merged pull requests across Ramp's frontend and backend repos are started by Inspect”article, stated
“complete accessibility for users who don’t want to install things locally”article, stated