Vercel Labs
Zero
The Programming Language
for Agents
An experimental systems language that gives AI agents structured diagnostics,
typed repair metadata, and machine-readable docs — alongside sub-10 KiB native binaries.
Systems Language
Agent-Native
v0.1.1
Apache-2.0
Experimental
Context
The Agent Repair Loop Problem
Most programming languages produce compiler output written for human readers — unstructured text that AI agents must parse to determine what failed and how to fix it. This creates a fragile loop.
- Agent writes code — compiler emits an error as unstructured text
- Agent parses text — error format can change between compiler versions
- No repair hint — there’s no built-in concept of a “repair action”
- Human steps in — the loop requires manual intervention to resolve errors
Zero was designed from day zero so agents can read the code, interpret the diagnostics, and repair the program — without human translation.
Core Feature
Structured Compiler Output
Running zero check ——json emits machine-readable diagnostics instead of plain text. Every error includes a stable code, a human message, a line number, and a typed repair ID.
$ zero check –json
{
“ok”: false,
“diagnostics”: [{
“code”: “NAM003”,
“message”: “unknown identifier”,
“line”: 3,
“repair”: { “id”: “declare-missing-symbol” }
}]
}
- code — stable identifier agents can match reliably (NAM003)
- message — human-readable description of the error
- repair — typed repair ID agents can act on without text parsing
Core Feature
zero explain & zero fix
Two CLI subcommands complete the agent repair loop without requiring agents to parse prose documentation.
zero explain
zero explain NAM003
Returns a structured explanation of any diagnostic code. Agents look up NAM003 directly — no doc scraping.
zero fix
zero fix –plan –json add.0
Emits a machine-readable fix plan describing exactly what changes to make — no inference required.
Together, zero explain and zero fix –plan –json let agents understand errors and act on them without human translation of compiler output.
Core Feature
zero skills: Version-Matched Agent Guidance
Most tools require agents to scrape external documentation that may be out of sync with the installed compiler. Zero solves this with zero skills — guidance served directly from the CLI, matched to the installed version.
zero skills get zero –full
Returns focused workflows for:
- Zero syntax — language fundamentals for the current version
- Diagnostics — how to interpret and act on compiler output
- Builds & packages — manifest structure, targets, and output
- Testing & agent edit loops — validation and repair workflow patterns
Language Design
Explicit Effects & Capability-Based I/O
In Zero, if a function touches the outside world, its signature says so. There is no hidden global process object, no implicit async, and no magic globals.
pub fun main(world: World) -> Void raises {
check world.out.write(“hello from zero\n”)
}
- world: World — capability object; grants access to I/O, filesystem, network
- check — handles fallible operations; surfaces failure up the call stack
- raises — marks that the function can propagate errors — visible in the signature
- Compile-time enforcement — unavailable capabilities are rejected at compile time, not runtime
Language Design
Predictable Memory & Tiny Binaries
Zero targets environments where binary size and memory predictability matter. There is no hidden runtime tax.
Binary Target
< 10 KiB
Native executables via static dispatch, no mandatory GC, no mandatory event loop
Cross-Compilation
zero build –emit exe \
–target linux-musl-x64 \
add.0 –out .zero/out/add
- zero size –json — reports artifact size before code generation when possible
- No hidden allocator — allocation is explicit and visible in code
- C ABI exports — target-aware interop metadata for C boundaries
Quick Start
Install & Run Zero
Install the compiler with a single curl command:
curl -fsSL https://zerolang.ai/install.sh | bash
export PATH=”$HOME/.zero/bin:$PATH”
zero –version
Check, run, and build your first program:
zero check examples/hello.0
zero run examples/add.0
zero build –emit exe –target linux-musl-x64 \
examples/add.0 –out .zero/out/add
Create a new package:
zero new cli hello
cd hello
zero check . && zero test . && zero run .
Status
What’s Available & What’s Not
- v0.1.1 (Experimental) — compiler, stdlib, and language spec are not stable yet
- No package registry — ecosystem breadth is early-stage
- Cross-compilation — limited to the documented target subset
- VS Code extension — syntax highlighting for .0 files ships in the repo
- Contributors — Chris Tate & Matt Van Horn (Vercel Labs)
Docs & Install
zerolang.ai
Source
github.com/vercel-labs/zero
Zero is a working experiment worth tracking for AI engineers interested in agent-native toolchain design — not yet a production dependency.
