Run thousands of agents. Efficient, durable, auditable.
Lightspeed is open-source infrastructure for running long-lived agent fleets in production.
Its frontier-class agent harness runs as a durable headless workflow, borrows real machines when a task needs one, and stays auditable, tenant-isolated, and cheap when idle.
Try theDemoright now — no sign-up — or take the Source Code and run it yourself.
The Problem
Frontier harnesses like Claude Code, Codex, and OpenClaw are excellent, but they assume they own an operating system. That assumption is what makes them hard to scale, hard to secure, and impossible to keep alive for long.
Traditional: One OS per Agent
Heavy infrastructure load
Lightspeed: Harness Separated from Compute
Infrastructure attached only when needed
The Solution
Lightspeed separates the harness from compute.
The harness is the agent loop, context management, and session state. In Lightspeed it runs as a lightweight, deterministic, event-sourced workflow. Anything that needs an operating system — shells, code execution, full file systems, long-running jobs — happens on machines the agent borrows for exactly as long as it needs them.
Build with Lightspeed
Use Cases
Large-Scale Always-On Personal Assistant
One agent per user, reachable over Telegram or WhatsApp, remembering weeks of context, calling calendars, mail, and internal tools over MCP with each user's own OAuth identity. Nearly all agents are idle at any moment; in Lightspeed an idle agent is a suspended workflow, not a running VM.
A planner agent spawns builders, testers, and reviewers. Each sub-agent provisions its own VM from a profile, clones the repository, runs the suite, and critiques the others' work. The fleet keeps going for days and picks up where it left off after a worker restart. Fork a session to try two approaches from the same state without paying for the shared prefix twice.
Point a fleet at an undocumented landscape: dozens of repositories, servers, schemas, and cron jobs nobody fully understands. Agents explore machines and codebases in parallel, reconstruct how the pieces talk to each other, write the documentation that never existed, and keep it accurate as they continue to observe. Sub-agents split the estate; a coordinator merges what they find.
Research Agents Supervising Long Experiments
An agent launches a training run or data pipeline as a job on a GPU box, checks in on progress, adjusts parameters, and writes up the results when it finishes — hours or days later. Credentials for the cluster are injected into the environment and never pass through the model.
On-call Operations Agent
An alert starts a managed session from your incident workflow. The agent reads dashboards over MCP, inspects the host through the environment daemon, proposes a fix with a deadline, and reports back to the channel. If nobody answers, the workflow cancels it cleanly.
You already run Temporal. Give every customer, order, or ticket its own agent: your workflow starts a managed session, binds tools backed by your own activities, and receives durable emissions back. No separate agent infrastructure to run.
Designed to Perform
Lightspeed is a deterministic agent harness built from the ground up for durable workflow engines, not VMs. Written in Rust and open source, it runs on Temporal today — the same engine behind OpenAI's hosted agents. It also comes with a powerful frontend that makes it a breeze to manage your agents.
Clone theSource Codeand run it yourself, or try the hostedDemoright now.
Reusable session setups, shared across clients and fleets. A profile fixes the model, prompt, tools and grants an agent starts with — and can either activate an existing environment or provision a fresh one per session.
Read on
Every session is an event log, and the log is the only truth. Each user message, model response, tool call and tool result is recorded as an event before it is applied; the agent’s state is nothing but a replay of that log.
Because the core is deterministic, replaying the log reproduces exactly what the agent was shown at every step and the step it chose next. There is no separate audit trail to maintain: the record of what happened is the state.
Large payloads — full context, tool output, provider-native data — are referenced from the log by content hash. Each command carries the principal that issued it, scoped to its universe, so a tenant can answer who asked, what the agent was shown, and what it did.
The log lives in Lightspeed’s own event store, separate from the workflow engine’s history, so it survives restarts, redeploys and multi-week sessions.
Read on
Sessions attach to dedicated VMs, provision fresh ones per session, run provider-owned jobs for hours-long work, and power machines down when they go idle.
The model gets a real machine. The harness never lives on it.
Read on
Channels are the surfaces an agent talks through. One agent can be reachable over Telegram or WhatsApp, post into an incident channel, and hand back to a human with a written summary.
None of those integrations live inside the agent loop, so a session can gain or lose a channel without the harness changing.
Read on
A configurable slice of the universe API, exposed as generated MCP tools over Streamable HTTP. Point an agent at it and it can configure the platform it runs on.
Read on
Secrets reach environments and jobs without ever being exposed to the model. Cluster credentials, deploy keys and API tokens are injected where the work happens; the agent can use them and never sees them.
Read on
Every workflow-backed tool call can carry a deadline. If nobody answers in time, the controlling workflow cancels the session cleanly: in-flight model and tool calls are aborted, with no farewell turn.
Read on
Dedicated VMs connect as universe environment instances, and sessions use them through event-sourced active environment state. The in-repo Incus provider supplies durable full-VM provisioning, explicit takeover of existing VMs, on-demand daemon routes, and pause/stop power control.
Model-side discovery and selection is a separate, default-off grant: ordinary file and process tools simply operate on whichever environment is selected.
Read on
At the heart of every agent is a state machine that manages what goes into the model’s context window. In Lightspeed that state machine is an event-sourced, deterministic core: it replays a session’s event log into state, decides the next step, and emits thin effect intents that runtime adapters execute against real providers and tools.
The core performs no I/O itself, so it survives restarts, redeploys and multi-week lifetimes for free.
Two decisions make this practical
Minimal provider abstraction. Only the information needed to decide and branch is extracted; provider-native data stays opaque and blob-backed rather than being flattened into a fake universal message model.
Offloading to CAS. Everything the workflow logic does not need goes to content-addressed storage, so the payloads crossing between workflow and activities stay thin and the history stays small.
Read on
An AEAD-encrypted secret store, plus an OAuth token broker that refreshes tokens automatically. Secrets are held at the universe boundary and handed to environments and jobs only on use.
Read on
File and process tools always operate on the environment a session has selected — a real machine, reached through the environment daemon. Agents read and write files, run commands and inspect processes exactly as they would on a workstation.
These tools never touch linked virtual file system content; that is a separate tool family.
Read on
MCP servers are configured once for the universe, with API-key and OAuth identities shared by every session that selects that server id. Sessions carry the selection — not the transport configuration, and not the credentials.
Read on
Environments can be paused, suspended or stopped by intent. Staged idle policies power them down from the daemon’s own idle clock, and any powered-down environment wakes transparently on its next use.
Read on
A committed schema contract for the whole platform surface. The API reference, the OpenRPC document, the TypeScript client and the Configurator MCP tool descriptions are all generated from the same Rust manifest and schemas.
Read on
Sessions last weeks to months and survive worker restarts and redeploys. Because a session is a durable workflow rather than a process, staying alive costs nothing while the agent waits.
Active-run control is admitted live rather than between turns: cancel a run and in-flight model and tool calls are aborted with no farewell turn, steer it with a message the model sees on its next turn, or queue the next message behind it.
Read on
Trusted workflow controllers can create sessions with immutable tool bindings, durable emissions, keyed completions, deadlines and cancellation.
Your workflow owns the session; the agent cannot re-bind its own tools.
Read on
Frontier models are optimised to the hilt — via reinforcement learning — on the assumption that they control a full POSIX-compatible machine. An agent with only MCP servers and provider-native tools will underperform one with a real shell.
Take the machine away and you take capability away. Closing that gap without moving the harness back inside the OS is a central goal of Lightspeed.
Read on
Every agent needs its own VM or container, even while it sits idle waiting for a reply. Cost and attack surface scale with the number of agents, not with the amount of work being done.
Frontier harnesses like Claude Code, Codex and OpenClaw are designed to run inside a guest operating system and need an entire OS to themselves. In an enterprise or shared deployment you cannot simply co-locate agents on one machine, so every new agent means new infrastructure.
Read on
The agent is a workflow, not a process. The harness — the agent loop, context management and session state — runs as a lightweight durable workflow instead of inside a guest operating system.
Idle agents cost nothing. Thousands of them run on a single worker node.
Read on
Long-running work that outlives a single turn: downloads, experiments, data pipelines and delegated coding-agent runs, owned by the environment provider rather than by the agent loop.
Jobs are an advanced, default-off environment grant. They appear as model tools when the environment grants them, and live availability is checked when they are invoked.
Read on
A profile can provision a fresh machine for each session instead of sharing a long-lived one. Each sub-agent gets a clean VM from the same image, clones the repository, runs the suite, and releases the machine when it is done.
Read on
Cheap forks of a running agent’s full state, taken straight from the event-sourced log.
Try two approaches from the same starting point without replaying the work — or paying for the shared prefix — twice.
Read on
A job can report back into the session that started it. The agent checks in on progress, adjusts parameters, and writes up the result when the job finishes — hours or days later — without holding a process open in between.
Read on
Agents that start and manage other agents. A planner can spawn builders, testers and reviewers, hand each one its own profile and environment, and merge what they produce.
Because every sub-agent is itself a durable workflow, a fleet can keep working for days and pick up where it left off after a worker restart.
Read on
A generated client that tracks the API contract exactly. Types come from the same manifest as the server, so a contract change surfaces as a compile error rather than a runtime surprise.
Read on
A universe is the tenant, project or workspace boundary used throughout Lightspeed. One deployment serves many isolated universes through a single gateway: database records are keyed by universe, object-store keys are scoped under it, and public API methods never accept a universe parameter — the gateway resolves it before dispatch.
Credentials belong to the universe, so each user’s own OAuth identity can drive their agent’s tool calls without secrets being copied into sessions.
Read on
Dedicated vfs_* tools read and edit linked snapshots and workspaces with no operating system attached at all. Documentation, notes and skills live here and stay available whether or not a machine is currently borrowed.
Skills are cataloged and loaded automatically from linked VFS roots.
Read on
External workflows can add durable tools to an agent. A plugin creates and manages a session, provides tools backed by its own workflows, and relies on Lightspeed to deliver calls, wait for results, handle timeouts and cancel work.
Plugins stay independent of the core session worker.
Read on
Most agent SDKs are not designed for workflow engines. They do not separate the deterministic core from effects such as LLM and tool calls, and they pass far too much data between the workflow logic and its activities — often the entire chat history, back and forth.
Histories bloat, determinism breaks, and durability ends up bolted on after the fact.
Read on
One protocol for binding any workflow as an agent tool. If you already run Temporal, your existing activities become tools: your workflow starts a managed session, binds the tools, and receives durable emissions back.