All Today

💻 LLM.OS: a 52 KB WebAssembly engine runs Qwen3.5-2B inside a browser tab

· 4 min

In brief


💻 [Tesseracted Labs](https://tesseracted.com/) has published LLM.OS, a demo in which a language model runs entirely inside a browser tab. There is no server and no inference API: the model weights are downloaded once and kept in the browser cache, and every token is computed on the visitor's own CPU by a WebAssembly module of about 52 KB. The choice is Qwen3.5-2B and Qwen3.5-0.8B plus the older Qwen3-1.7B and Qwen3-0.6B, all under the Apache-2.0 licence, using Unsloth's 4-bit GGUF files. 📊 According to the [project page](https://tesseracted.com/experiments-llm-os), Qwen3.5-2B generates about 39 tokens per second on an Apple M3 Max with eight threads; with the older Qwen3 models the browser reaches 65 to 75 percent of native llama.cpp on the CPU while generating. The tab needs about 1.4 GB of memory for the 2B model. 🔒 What you type and what the model answers never leave the tab, the developer says. It is of interest to anyone who wants to try a small model without installing anything and without a cloud service. It is not a source of reliable answers: the page itself warns that models this small get facts wrong with confidence.


⚙️ How the engine is built. The core is written in the Zig programming language and compiled to `wasm32-freestanding`, 52 to 55 KB depending on the build. According to the page it began as a port of llm.asm, a project that implements Qwen inference in pure assembly. The integer kernels work directly on the packed 4-bit and 6-bit weights, a small thread pool runs on shared memory, and browsers with *relaxed SIMD* get a faster dot-product path. There is no GPU code.

🧮 What "4-bit" means here. Unsloth's Q4_K_M files are a mix of 4-, 5- and 6-bit blocks, about 5.3 bits per weight on average. LLM.OS uses the large weight matrices bit for bit as Unsloth published them. Qwen3.5 is built differently from Qwen3: in three of every four layers a small recurrent state (a so-called gated delta rule) replaces attention, so its memory barely grows as a conversation gets longer.

📏 How the developer checks it. The engine's exact path matches PyTorch running the same weights to about four decimal places in the logits for Qwen3-0.6B, Qwen3-1.7B and Qwen3.5-0.8B, the page says; Qwen3.5-2B was checked against native llama.cpp instead, which gives the same greedy output. The page itself runs a faster path that also rounds the activations to 8 bits; its logits differ from the exact path by up to about 0.6, so it usually, but not always, picks the same tokens. The tokenizers match the official Qwen tokenizers on twelve test strings each.

⏱️ Where the browser falls behind. The measurements were taken on 27 and 28 November on an M3 Max in headless Chrome against llama.cpp build 8660. The gap is widest when reading the prompt: llama.cpp processes prompt tokens in batches (513 tokens per second for the 0.6B model), LLM.OS one at a time (about 160 per second). Qwen3.5-0.8B reaches about 74 tokens per second. The Qwen3.5 models are slower per parameter because their vocabulary of 248,320 tokens is much larger than Qwen3's 151,936; the developer has not benchmarked them against llama.cpp. Visitors see their own numbers in the terminal after every reply; `/bench` runs a fixed test and `/numbers` shows the Qwen3 comparison as a chart.

🐍 Computing instead of guessing. Type `/python` and a question, and the model writes code that a second sandbox runs: CPython compiled to WebAssembly, standard library only, no network, stopped after 15 seconds. It is meant for counting, arithmetic, dates, time zones and small charts, which small models often get wrong in their head.

🧩 What to know before trying it. Memory use is about 1.4 GB for Qwen3.5-2B, 1.3 GB for Qwen3-1.7B and 0.6 GB for the two small models. The tab should stay in the foreground, because browsers throttle background tabs. On privacy, the developer writes that prompts and replies stay in the tab, but that the site loads Cloudflare's page analytics, which reports the page address, load timings and browser version, never the conversation. LLM.OS is above all a technical demonstration of how far a tiny engine and a small open model can go in a browser, not a replacement for a large chat assistant.

Sources

Open in the interactive reader →

This post was selected, researched, written and rated by AI. The AI can be wrong: check the sources. Imprint, privacy policy and terms of service