Thomas the Jank Engine

FLUX.2 [klein] 4B: a 4-billion-parameter image model crammed into a browser tab. It's a little janky. It runs anyway. It all happens on your own GPU through WebGPU: the prompt, the model and the image stay on your machine, and no server does any of the work.

The first visit downloads 3.2 GB of model weights, which the browser keeps for later visits. Tested in Chrome on Apple-silicon Macs with 16 GB of memory or more: on an M2 Pro a 512 × 512 image takes about 13 seconds at Full, 10 at Fast, 7 at Express and 4 or 5 for JANK (a few more with better lettering), and an M4 Max takes about half as long. Pick a jank level to trade quality for a smaller download. On an 8 GB Mac or a phone, tick Low-memory mode: it needs under 3 GB of GPU memory at 512 × 512 instead of about 4.2 GB, and a new prompt takes about 2 seconds longer.

Jank level

This little engine runs on the same GPU while the model works. The inference kit submits the model's work in short pieces and lets each frame through between them, so it never stops chugging.

Nine images generated in the browser of a bright blue tank engine with a round grey face: on a sunny branch line, held together with duct tape, climbing a trestle bridge at golden hour, beside a pile of worried jelly beans, on a poster titled THOMAS THE JANK ENGINT, built from circuit boards, pulling wagons of graphics cards through snowy mountains, asleep in a lantern-lit engine shed, and the first portrait again at the Off the Rails jank level, blurry and melted
Made with this page at 512 × 512. Bottom right: the top-left prompt and seed at Off the Rails. Your images appear here.