richiemcilroy/Tov

A TypeScript-shaped language built for coding agents. It compiles to small, fast native binaries.

What it solves

Tov is a programming language designed specifically for AI coding agents. It addresses the difficulty agents have with complex language behaviors and debugging by providing a syntax similar to TypeScript that is easier for LLMs to write and a compiler that provides machine-readable, actionable fixes when errors occur.

How it works

Tov uses a TypeScript-like syntax but removes ambiguous or "hard-to-reason-about" features (such as any, null, and implicit type conversions). It compiles to native binaries for high performance. For agents, the compiler can output JSON via tov check --json, which includes the exact code edits needed to fix a type error, allowing the agent to apply the fix automatically.

It maintains compatibility with the Bun and Node.js ecosystems, allowing the use of npm packages and Bun's server APIs. Programs that use npm packages are run via an embedded JavaScriptCore engine, while pure Tov programs are compiled to lean native binaries.

Who it’s for

  • AI coding agents and the developers building them.
  • Developers seeking a high-performance alternative to Bun or Node.js with stronger type safety.
  • Users who want the speed of native binaries (comparable to or faster than Rust) with the familiarity of TypeScript syntax.

Highlights

  • Agent-Centric Design: Provides machine-readable JSON error fixes that agents can apply directly to source code.
  • High Performance: Benchmarks show execution speeds and memory usage competitive with or superior to C and Rust.
  • TypeScript Compatibility: Supports Bun/Node APIs and npm packages, allowing existing Bun apps to run with minimal changes.
  • Strict Type System: Eliminates null and any, requires explicit error handling via the try keyword, and uses value-based arrays and records.

Related

  • Project
  • Project
  • Project
  • Project