Leviath

A structured agent runtime for LLMs

Most agent tools hand an LLM a flat message array and hope for the best. Leviath gives it structure: context that stays coherent across hundreds of tool calls, the right model for each phase of a task, and a dozen agents running at once without melting your machine.

Private beta — for alpha/beta testers.

Coherent

Structured context regions mean an agent still knows what it read 50 tool calls ago.

Staged

Each phase of a task gets its own model, tools, and context layout, wired as a graph.

Light

Dozens of agents in one bevy_ecs process, from a single binary. No Node, Python, or Docker.

Install

Homebrew

brew tap sun-forge-ai/leviath https://github.com/Sun-Forge-AI/leviath-dist.git
brew trust sun-forge-ai/leviath
brew install leviath          # or: leviath-beta, leviath-alpha

Install script

curl -fsSL -H "Authorization: token $GITHUB_TOKEN" \
  https://raw.githubusercontent.com/Sun-Forge-AI/leviath-dist/main/install.sh \
  | bash -s -- --channel stable

PowerShell

irm -Headers @{Authorization="token $env:GITHUB_TOKEN"} `
  https://raw.githubusercontent.com/Sun-Forge-AI/leviath-dist/main/install.ps1 | iex

Build from source (requires Rust)

cargo install --git https://github.com/Sun-Forge-AI/leviath.git --bin lev

Docker (runs the daemon + API in one container)

docker run -d -p 3000:3000 -e LEVIATH_API_TOKEN=change-me -v leviath-data:/data leviath

Features

Structured context memory

Six region types with deterministic eviction; budgets as a percentage of the model window.

Learn more →
Multi-stage workflows

Linear or graph workflows with conditional transitions, error recovery, and measured stuck detection.

Learn more →
ECS agent engine

Agents run as entities in a bevy_ecs world — dozens share one process, not one per agent.

Learn more →
Sub-agents and fan-out

Split a task into work items, run one worker per item, and merge results back into the parent.

Learn more →
Human-in-the-loop

Message a running agent between inference calls; force checkpoints or grant ask_user tools.

Learn more →
Sandboxing and taint tracking

Opt-in container or namespace isolation per stage, plus an experimental data-flow sensitivity model.

Learn more →

Ten agents out of the box

Each is a multi-stage directed graph with structured context and per-stage model fallback.

software-engineerdefault

Full coding workflow with human-approved planning and stuck detection.

wide-researcher

Broad multi-topic landscape survey; compares approaches.

deep-researcher

Thorough single-topic investigation with a cited report.

coder

Focused implementation with discovery and a review loop.

reviewer

Read-only code review and audit grounded in a discovery pass.

parallel-fixer

Fixes many failing tests at once — one worker per failure.

researcher

General-purpose research with a gather↔analyze loop.

log-analyzer

Log analysis with scripted aggregation and ranked findings.

daily-briefer

Morning summaries from local and web sources.

writing-assistant

Research-backed writing with an outline checkpoint and edit loop.

Benchmarks

Leviath is a runtime that orchestrates agents, not a coding agent itself, so we don’t publish head-to-head numbers against tools like Claude Code or Codex. We measure structured vs flat context (held-out test pass rate, billed tokens, cost) and the memory footprint of one daemon running many agents. A benchmark round is being re-run under a frozen, reproducible methodology; numbers will land here when it completes, with all runs published.

Claude Code transport