A Programming Language with No Compiler
A specification-first, English-like language with AI-generated interpreters and a shared test suite. Execution still depends on host toolchains.
There’s a concept gaining traction in AI engineering circles: the ghost library — software distributed as a specification rather than code. No package manager. No dependency. Just a spec and a set of tests. You hand both to an AI agent, and it builds the implementation in whatever language you need.
It’s a clever idea. But a library is small. A handful of functions. A few hundred lines of spec.
What if you went further? What if the spec didn’t describe a utility — but an entire programming language?
A Language Where the Syntax Is English
The idea builds on natural-language interfaces to programming. NVIDIA is a major supplier of AI accelerators, but AI systems also run on other accelerators and CPUs. The interesting question here is what a language specification can make reproducible.
So I built that future. Meet humanlang — a programming language with no compiler.
The project begins with a specification and 86 test cases, then asks an AI agent to generate an interpreter in a chosen host language. Execution still requires that interpreter and its host runtime or compiled executable.
Its syntax is English-like, with a formal grammar. It is not unrestricted natural English.
This is what FizzBuzz looks like in humanlang:
-- FizzBuzz in humanlang
for n from 1 to 100:
if n modulo 15 is equal to 0:
print "FizzBuzz"
otherwise if n modulo 3 is equal to 0:
print "Fizz"
otherwise if n modulo 5 is equal to 0:
print "Buzz"
otherwise:
print n
No semicolons. No curly braces. No && or || or !=. Just English words arranged into logic.
What’s in the Repo
The humanlang repository contains:
| File | Purpose |
|---|---|
SPEC.md |
Complete language specification with EBNF grammar |
tests.yaml |
86 language-agnostic test cases |
INSTALL.md |
Build instructions (a prompt) |
examples/ |
Sample humanlang programs |
python/ |
AI-generated Python interpreter (1,465 lines) |
typescript/ |
AI-generated TypeScript interpreter (2,188 lines) |
kotlin/ |
AI-generated Kotlin interpreter (1,332 lines) |
rust/ |
AI-generated Rust interpreter (2,103 lines) |
ocaml/ |
AI-generated OCaml interpreter (1,429 lines) |
zig/ |
AI-generated Zig interpreter (1,741 lines) |
haskell/ |
AI-generated Haskell interpreter (1,243 lines) |
asm/ |
AI-generated ARM64 assembly interpreter (5,271 lines) |
What’s not in the repo: hand-written code. Not a single line. Every interpreter was generated entirely by AI agents reading the spec.
The installation instructions are a prompt:
Build a humanlang interpreter in [LANGUAGE].
1. Read SPEC.md for the complete language specification
2. Parse tests.yaml and generate a test file
3. Implement a lexer, parser, and tree-walk interpreter
4. The entry point should accept a .hl file path as a command-line argument
5. Run tests until all pass
6. Place implementation in [LOCATION]
Pick your language. Pick your location. Copy, paste, go.
More Than a Gimmick
humanlang is a complete programming language. Variables, arithmetic, strings, booleans, lists, conditionals, loops, functions, recursion, type conversion. Here’s a recursive factorial:
define factorial with n:
if n is at most 1:
return 1
return n times (call factorial with (n minus 1))
print call factorial with 10
And here’s a function that filters even numbers from a list:
define is_even with n:
return n modulo 2 is equal to 0
define filter_even with numbers:
set result to []
for each n in numbers:
if call is_even with n:
append n to result
return result
set evens to call filter_even with [1, 2, 3, 4, 5, 6, 7, 8]
print evens
Output: [2, 4, 6, 8]. A working program, written in sentences.
Spec-Driven to the Core
This is spec-driven agentic development taken to its logical extreme. When I wrote about OpenSpec and the idea that you should write the spec first, review it, freeze it, then let an AI agent build — I was talking about features and APIs. But the same principle applies to something far more fundamental: an entire programming language.
The SPEC.md file is 400 lines. It defines every data type, every operator, every control flow construct, and a complete EBNF grammar. The tests.yaml file contains 86 test cases covering everything from basic printing to recursive functions to FizzBuzz.
Give the specification and tests to a capable AI coding agent and ask it to generate an interpreter in a chosen host language. The specification and tests are intended to be language-agnostic; each implementation still depends on that host language’s tools. The runs below explore this approach across several programming paradigms.
The Proof
I gave Claude Code the same SPEC.md and tests.yaml repeatedly. Same spec. Same 86 tests. Different languages. Different paradigms.
| Language | Paradigm | Lines | Build |
|---|---|---|---|
| Python | Dynamic / Scripting | 1,465 | python3 humanlang.py |
| TypeScript | Typed JS / Node.js | 2,188 | npx tsx humanlang.ts |
| Kotlin | JVM / OOP + Functional | 1,332 | kotlinc humanlang.kt -include-runtime -d humanlang.jar |
| Rust | Systems / Ownership model | 2,103 | cargo build --release |
| OCaml | Functional / Algebraic data types | 1,429 | ocamlopt -o humanlang humanlang.ml |
| Zig | Manual memory / Zero overhead | 1,741 | zig build -Doptimize=ReleaseSafe |
| Haskell | Pure lazy functional | 1,243 | ghc -O2 -o humanlang Main.hs |
| ARM64 Assembly | Raw machine instructions | 5,271 | cc -o humanlang humanlang.s |
The reported implementation runs generated interpreters from the specification and iterated until the supplied 86 tests passed. These results describe those runs and that test suite, not a proof of complete language conformance.
The host languages exercise different implementation choices: dynamic and static typing, ownership, functional state handling, manual memory management and assembly. Agreement across this sample is useful evidence about the specification, while untested cases can still expose ambiguity or defects.
The implementations and test runner are in the repository. Run the suite in the intended environment and record the revision and toolchain. The reported 86/86 results are a baseline to reproduce, not a guarantee for every environment or future change.
From Ghost Libraries to Ghost Languages
A ghost library replaces a dependency. You don’t install a package — you describe what the package should do, and an AI builds it locally.
humanlang extends the idea to a small programming language with a grammar, scoping rules, control flow and recursion. The reported implementations demonstrate this approach across several host languages. Generated implementations still require iteration, toolchains, testing and review.
A specification-first language changes how an implementation is produced. It does not remove the interpreter, compiler or runtime needed to execute the resulting program.
The Quiet Revolution
Something is happening that most people haven’t fully processed yet.
Software can be distributed as a specification and tests that serve as inputs for generating an implementation. This changes the starting point; it does not remove the work of building, testing, reviewing and maintaining the resulting software.
Human language isn’t just becoming the best way to write code. It’s becoming the best way to distribute code.
The repo is here: github.com/vpetreski/humanlang. Clone it. Give the spec to your favorite AI agent. Watch it build a programming language from a document.
Then ask yourself what else we’ve been over-engineering all this time.