Latent calculator, in the browser

SmolLM2-135M, frozen, split after decoder layer 16. Three routes to the same arithmetic answer — one of them passes no tokens in either direction.

loading…

The latent route reads the query out of layer 16 (or off the prompt text, if you switch the source), runs a plain calculator in JavaScript, and adds one encoder vector to the residual stream at every answer position. The model never sees the result as text.