Playground

in-browser playground
Feedback

Train a small GPT — the kind of model behind ChatGPT, a million times smaller — from scratch, right here in this tab. No server, no install. Watch the loss curve fall, then ask it to write you a sentence. Source ↗

Decision, forecasting & learned-terminal modes ↓ · one Mac-local specialist workspace

Two ways: browse the gallery for pre-trained models (same architecture, different corpora) and hit Generate, or train your own from scratch using the controls below (~4–15 min).

Train

Corpus
picks load automatically · or paste your own text below
Hyperparameters — preset above sets these. Click to edit individually.
Model —
Estimated run time —
Advanced
Your machine detecting… computing…

computing…

Want to go further?
4 Resources curated rabbit holes — 3Blue1Brown, Karpathy, papers, and this repo's own docs

Start here (visual + intuitive)

Go deeper (code + papers)

This project's own write-ups

Related projects

5 WebGPU matmul benchmark Same matmul on WebGPU + WASM, side-by-side, with a live speedup number

Runs the same matmul through the WebGPU compute kernel and the WASM kernel, parity-checks they agree, and reports the per-shape speedup on your hardware. Needs Chrome / Edge 113+. For the historical end-to-end curve and its evidence limits, see /speedup.

Not run yet.

Keyboard shortcuts

?Show this sheet EscClose any popover / dialog ⌘ / Ctrl EnterStart training ⌘ / Ctrl GGenerate from the model TTake the tour SShare this setup PPause / resume training 1–5Pick a size preset (Tiny → XL)

Are you sure?

Welcome to posttrainllm

This is the learning playground: a complete transformer that trains from scratch right here, in this tab, with no server. Load a model, train one, or take the tour. The Mac-side specialist packages live in the CLI registry and MLX export docs.

Mac-local specialist lab

Three ways to teach a small model.

Runtime disconnected

Choose an answer, forecast a series, or predict a terminal screen. One workspace for inputs, training, evaluation, and saved models.

Start your local runtime

The specialist modes run on your Mac through Python. Your inputs stay between this page and the local runtime.

uv sync --project scripts/specialists --all-extras --frozen
pnpm --dir browser run build
uv run --project scripts/specialists python scripts/specialists/lab.py serve

Download the selected model first using the setup commands. The runtime loads cached weights. Training defaults to one step; a training smoke proves wiring, not model quality.

Make a choice in one forward pass.

Compare every allowed answer. Fit temperature on separate examples before interpreting the probabilities.

Qwen3 · 1.7B · local

Edit the example or import your input. No silent prompt truncation.

Result

Unqualified model

Connect your local runtime to run this example.

These modes use a local Python runtime. Browser-only WASM/WebGPU execution for these specialists has not been built. The byte-level trainer above continues to run entirely in your tab.