Synthetic Worlds.

Realistic worlds for agent evals and RL

Seahaven is our open-source Python framework for building synthetic worlds: working copies of your agent's tools, realistic enough that the agent can't tell the difference.

Introducing Seahaven video: “Your agent thinks this is real.” beside an isometric island town with a blue agent pin among the houses.

Simulate your agent's world

01 · Private

A private world for every run

Each instance is its own SQLite database, copied from a fixture in milliseconds and thrown away at the end. The agent can read, write, and even break things without touching anyone else's run.

02 · Fixtures

Freeze known starting states

Freeze starting states like small_startup or big_co once, then reuse them across every run. Same fixture, same clock, same random seed: the same run, every time.

03 · Parallel

Hundreds of worlds, one process

seahaven serve hosts hundreds of world instances per process, at thousands of requests per second. Each new connection gets its own world.

04 · State

Grade on state, not transcripts

Every row the agent changed is logged, before and after, in one JSON document. Did the agent refund the right charge? Check the row, not what the agent says it did.

05 · Connect

Plugs into what you already use

Every world is an OpenEnv environment, the open standard for RL environments. Evaluate and optimize agents with Kiln, train models with TRL, or publish your world to Hugging Face.

Realistic like production.
Isolated like a mock.

Production is realistic but shared. Mocks are private but fake. Seahaven gets you the realism of production with the isolation of a mock.

Capability SeahavenProduction or stagingHand-written mocks
Realistic tools and data
Stateful across arbitrary tool calls
A private instance for every run
Hundreds of parallel instances
Every run starts from a known state
Reproducible
Every change logged for grading
Safe for the agent to break things

A tool is just a Python function.

Seahaven builds each tool's JSON schema from its signature, and the docstring is what the agent reads. Start from the scaffold: schema, tools, tests, a fixture generator, and an AGENTS.md.

src/crm_world/tools/contacts.py python
@world.tool
def create_lead(ctx: seahaven.Ctx, email: str) -> dict[str, str]:
    """Add a contact to the pipeline as a new lead."""
    lead = {"id": ctx.ids.uuid(), "email": email,
            "stage": "lead", "updated_at": ctx.clock.iso()}
    ctx.db.execute("INSERT INTO contacts VALUES (?, ?, ?, ?)", *lead.values())
    return lead

Everything a synthetic world needs

Recreate any environment

Mock AI tool calls, REST APIs, sandboxed SQL, search, or any custom format.

Stateful

Every instance has its own SQLite database, so a write changes every later read.

Composable

Add Stripe World and a chat world to your world, the agent can navigate the combined tool set.

Reproducible

The clock and seed are wired into SQLite, so even CURRENT_TIMESTAMP replays exactly.

OpenEnv

Drive any world from any OpenEnv client, or publish it to Hugging Face.

Web console

Open instances, call tools, and inspect state in your browser.

MCP

seahaven mcp connects a world to Claude, Cursor, or any MCP client.

Just Python

Tools are functions and tests use pytest, so coding agents already know the stack.

Evaluate and optimize agents with Kiln.

Kiln connects to any Seahaven world. Write scenarios against a fixture, evaluate your agent on the state it leaves behind, then use the Kiln Harness Optimizer to improve the harness: prompts, tools, skills, subagents and model choice, all scored against those evals.

★ Open source · MIT

Build your first synthetic world.

Scaffold a world with one command, hand it to your coding agent, and run your agent against it in minutes.

$ uvx seahaven new my_world