tov

Faster than Rust. Written like TypeScript.

Tov is the programming language for coding agents. Your agent already knows the syntax, the compiler hands back the exact fix for every error, and what comes out is a native binary that beats Rust: faster to run, faster to compile, in a fraction of the memory.

$ curl -fsSL https://tov.sh/install.sh | sh

Tov is early. It runs on macOS and Linux.

Requests a second, a JSON API on one core

  • Tov242k/sfastest
  • Rust (axum)216k/s1.1× slower
  • Bun111k/s2.2× slower

fetch(), 64 requests at once

  • Tov177k/sfastest
  • Rust (reqwest)162k/s1.1× slower
  • Bun129k/s1.4× slower
  • Node30k/s5.8× slower

binary_trees: millions of small objects made and freed

  • Tov260 msfastest
  • Bun376 ms1.4× slower
  • Node449 ms1.7× slower
  • C688 ms2.6× slower
  • Rust791 ms3.0× slower

Compiling a program to a native binary

  • Tov42 msfastest
  • C (clang)49 ms1.2× slower
  • Rust (rustc)98 ms2.3× slower

Memory, serving that JSON API

  • Tov1.6 MBleast
  • Rust (axum)4.4 MB2.8× more
  • Bun17 MB10.4× more

Each ball crosses its lane in time with its result: Tov's sets the pace, the others take as many times longer as they're slower. Measured on an Apple M4 Max; more below, method and every result on GitHub.

Your agent writes it. Tov fixes it. You ship it.

Agents are good at TypeScript and bad at guessing. Tov keeps the language they know, and answers every mistake with the edit that fixes it.

1Your agent writes TypeScript

// hello.tov
Bun.serve({
  port: 3000,
  fetch(req) {
    const url = new URL(req.url)
    return new Response(`Hello from ${url.pathname}`)
  },
})

2Tov says exactly what to fix

$ tov check --json
{
  "code": "T0831",
  "message": "`new URL` can throw `TypeError`; mark the call `try` to pass the error on, or catch it",
  "fixes": [{
    "applicability": "safe",
    "edits": [{ "line": 4, "col": 17, "text": "try " }]
  }]
}

3You ship a native binary

// the agent applies the fix
const url = try new URL(req.url)

$ tov build hello.tov
build: hello
$ ls -lh hello
152K hello
$ ./hello & curl :3000/agents
Hello from /agents

Nothing new to learn

TypeScript's syntax with Bun's and Node's APIs: Bun.serve, fetch, node:fs, async/await. If code looks like TypeScript, it behaves like TypeScript, or it doesn't compile.

Nothing hidden

No any, null or ==. Every call that can fail is marked try, integer overflow stops the program, and arrays and records are values, so nothing changes behind the agent's back.

Errors that come with the fix

Every error has a code, a reason and a fix. tov check --json returns the exact edit, and marks the ones safe to apply as they are.

Feedback in milliseconds

A program compiles in about 40 ms and rebuilds are cached. --watch restarts on save, and tov test runs the tests written next to the code.

Faster than Rust, in less of everything

Tov compiles to C and hands it to your system's compiler. Memory is reference-counted, so there are no garbage collection pauses, and a program is one small file.

3×
faster than Rust on binary_trees: 260 ms, against 791
42 ms
to compile a program to a native binary (Rust: 98 ms)
1.6 MB
to serve 242,000 requests a second (Rust: 4.4 MB, Bun: 17 MB)
33 KB
a binary, stripped (Rust: 351 KB)

Median wall time on an Apple M4 Max; every language prints the same output. Shorter is faster.

binary_trees

  • Tov260 ms
  • Rust791 ms
  • C688 ms
  • Bun376 ms

map_insert

  • Tov284 ms
  • Rust490 ms
  • C476 ms
  • Bun823 ms

sort

  • Tov45 ms
  • Rust74 ms
  • C275 ms
  • Bun696 ms

dispatch

  • Tov36 ms
  • Rust77 ms
  • C76 ms
  • Bun109 ms

strings

  • Tov143 ms
  • Rust224 ms
  • C253 ms
  • Bun203 ms

nbody

  • Tov210 ms
  • Rust224 ms
  • C312 ms
  • Bun512 ms

In the scoreboard run these numbers come from (bench/results/scoreboard-20261006-205209.json), Tov beat Rust on every measurement but one, a tie (points: 292 ms against 291). Tov checks integer overflow by default; Rust's release builds don't. Method, every result and caveats.

Bring your npm packages

Tov programs import npm packages, and apps written for Bun run on Tov unchanged. Tov code compiles to native code; the packages run on JavaScriptCore, built into the binary.

// main.tov: Cap's media server, as Bun runs it
import server from "cap-media-server"
import { serve } from "bun"

function main() {
  try serve(server)
}

Cap's media server uses Hono, zod, FFmpeg through a native addon, Bun.serve and Bun.spawn. On Tov, without a line changed:

  • 105 msto start, against 132 ms on Bun
  • 23% lessCPU for each video it probes than on Bun
  • 65 MBa second after a burst of load, against 68–70 on Bun

Start with your agent

Paste this to Claude Code, Codex, Cursor or any agent. It installs Tov, reads the language from llms.txt, and uses tov check --json to fix its own mistakes.

By hand: curl -fsSL https://tov.sh/install.sh | sh builds Tov from source (it needs git and a C compiler, and installs Rust if it's missing).

Use Tov (https://tov.sh) for this: a programming language with TypeScript's syntax that compiles to native binaries faster than Rust's.

1. Install it: curl -fsSL https://tov.sh/install.sh | sh
2. Read https://tov.sh/llms.txt. Tov is TypeScript without a few things (no any, null or ==; int and f64 are separate types; a call that can fail is marked try).
3. Write .tov files. After every edit, run `tov check --json <files>` and apply each fix marked "safe".
4. Run with `tov run main.tov`; ship with `tov build main.tov -o app`, one binary.

What works today

Works

  • Command-line programs and web servers
  • Records, unions, generics, classes, interfaces and checked errors
  • async/await, timers, fetch() over HTTP and HTTPS
  • Bun's server API and a Node-style standard library
  • npm packages, including native addons
  • macOS and Linux

Not yet

  • Windows
  • A package manager of its own (install with npm or Bun)
  • TLS sockets and worker threads for npm packages
  • Tuples, enums and a few other TypeScript features (see the spec)