Build AI. Ship UI.
Control memory.
Serez Code is a general-purpose language with native AI, terminal UI, GPU compute, and systems programming — all in a single runtime. No GC pauses.
import "serez-ai"
Random.seed(42)
// Build a neural network in 3 lines
let model = new Sequential()
model.add(new Dense(2, 32, "relu"))
model.add(new Dense(32, 1, "sigmoid"))
// Train with Adam optimizer
let opt = new Adam(0.01, 0.9, 0.999)
let hist = model.fit_opt(X, y, new BCE(), 500, opt, false)
out "Final loss: " + hist[hist.length() - 1] // 0.0021Everything you need. Nothing you don't.
One language. One runtime. Zero compromises.
Native AI
Built-in autodiff, neural layers (Dense, Conv2D, LSTM, Attention), and optimizers (Adam, SGD, Momentum). Train models in pure Serez — no Python needed.
UI: terminal & native
serez-ui: a React-style library — components, a virtual DOM and hooks. The same code runs as a terminal UI (TUI) or a native desktop window (GUI), with a responsive .szs stylesheet.
Exact decimals, natively
dec is a first-class base-10 type with 28–29 digits: 19.99m, 0.1m + 0.2m == 0.3m, scale preserved. It is not a library — and the compiler refuses to mix it with binary floats, so the classic lost-cent bug is a type error, not a silent rounding. Money, invoicing and COBOL-grade arithmetic without leaving the language.
GPU Compute
CPU-backed GPU compute buffers with matmul, axpy, dot, reduce, and map. Same API, zero driver hassle.
Flash Scopes
Open a bare { } block anywhere and everything declared inside it is released at the closing brace — not when a collector decides. Build a large structure, keep only the slice you need in a variable declared outside, drop the rest. Memory that follows the shape of your code.
Systems Control
Raw memory access, pointer arithmetic, unsafe blocks, and sizeof — all with the ergonomics of a high-level language.
Package Manager
sz install, sz uninstall, sz publish. Local and HTTP registry support. Packages live in ./packages — visible, portable, no magic.
Safe by Design
Typed arrays, bounded arithmetic, private fields, sealed classes, and a test suite of 388 files including a dedicated security section.
See it in action
From neural networks to raw memory — all in the same syntax.
// dec is a base-10 type built into the language, not a library.
// Binary floats drift; dec does not.
let a = 0.1 + 0.2 // decimal (f64) — binary
let b = 0.1m + 0.2m // dec — exact
out a == 0.3 // false
out b == 0.3m // true
// Scale is preserved, so "12.50" stays "12.50"
let price = 12.50m
let qty = 3
let vat = 0.21m
let net = price * qty // 37.50
let total = net + net * vat // 45.3750
out "Total: " + total.setScale(2) // 45.38
// And the compiler refuses to silently mix exact with binary:
// let bad = price * 0.21
// -> ERROR: cannot mix 'dec' (exact) and 'decimal' (f64)
// convert explicitly (d.toDecimal() / Dec.parse)Not a weekend project. The tooling is done.
A language is only usable if the things around it exist. These do.
Language server + editor extension
sz-lsp speaks stdio JSON-RPC: completion, diagnostics, go-to-definition. Ships as a VS Code extension.
Package registry in production
sz install / sz publish against a live registry, with versioning and unpublish. Packages land in ./packages — visible and portable.
433 tests, 0 failing
E2E, unit, error-path, security and AI suites run on every change, plus a documented CHANGELOG per release.
Ship a standalone binary
serez-pack builds a .exe or .msi with the runtime inside — the machine running it does not need Serez Code installed.
Run it without installing
The playground executes real programs against a pinned build of the compiler, in the browser.
Documented, not just released
Every language feature has a reference page, and every package ships its own guide with runnable examples.
Official packages
serez-ui
React-style UI library — components, a transparent Virtual DOM and hooks. 13 built-in components, responsive .szs styling, word-wrap and scrolling. Runs in the terminal (TUI) or a native window (GUI).
serez-ai
Neural networks, autodiff, and training loops. Dense, Conv2D, LSTM, Attention, BatchNorm, Dropout, Adam/SGD/Momentum. Keras-like API.
serez-agentai
GPT-style transformer stack + agentic framework — tokenizer, causal attention, KV-cache, sampling, tool calling and episodic memory.
serez-cobol
COBOL ⇆ Serez source-to-source translator and reverse compiler. Run legacy COBOL code on the Serez runtime with exact fixed-point decimal arithmetic.