@GoodfireAI: Neural networks do math by rotating shapes. We found a shape-rotating calculator hidden inside an LLM – and it’s used f…
Summary
GoodfireAI found that neural networks perform math by rotating shapes, uncovering a shape-rotating calculator inside an LLM that is used for more than just math.
View Cached Full Text
Cached at: 05/15/26, 03:06 PM
Neural networks do math by rotating shapes.
We found a shape-rotating calculator hidden inside an LLM – and it’s used for more than just math! (1/6)
How does Llama encode numbers? Not on a number line or in binary, but as positions on several circles in parallel.
This might sound odd, but it’s just a Fourier decomposition (a common mathematical technique). Prior work shows this is true across LLMs! (2/6)
These circles form the inputs and outputs of the model’s geometric “calculator”.
To add two numbers, the calculator solves smaller problems in parallel, one for each circle.
Each circle gets its own little addition problem. (3/6)
The same calculator handles a wide range of tasks, including:
- arithmetic (“7+9”)
- weekdays (“nine days after Friday”)
- months (“six months after August”)
Llama built this mechanism from scratch in training, and uses it with striking elegance and flexibility. (4/6)
How do we know Llama is really using this geometric calculator?
We can steer it, manipulating the circles inside the network and watching the answer change.
The proof is in the steering. (5/6)
This is a glimpse of how neural geometry can lead us to discover mechanisms we’d otherwise miss - in this case, neural computation.
Understanding this machinery paves the way for better debugging, control, and design of AI.
Read the full post: https://goodfire.ai/research/a-geometric-calculator… (6/6)
getting one of those for the office rn
they definitely rotate shapes
we’re big fans of causal evidence :)
thanks for reading. more to come soon!
it’s circles all the way down
we think so!
interesting hypothesis! the role of layernorm is definitely underappreciated
Fourier would have too
it turns out that the addition module always uses base-10, even for months/hours/weekdays
Yes! full paper here
Similar Articles
@GoodfireAI: Neural networks might speak English, but they think in shapes. Understanding their rich *neural geometry* is key to und…
Goodfire AI announces a new research agenda focused on neural geometry to improve the understanding, debugging, and control of neural networks.
@DanKornas: Neural nets are easier to understand when you can see the math cell by cell. ai-by-hand-excel is a collection of Excel …
ai-by-hand-excel is an open-source collection of Excel workbooks that teach AI concepts like neural networks, backpropagation, and transformers by letting users inspect the math cell by cell, making model internals more intuitive.
@Raytar: a Google researcher walked into MIT and made an AI do math correctly by adding seven words to the prompt. the seven wor…
A thread highlights two separate insights: a Google researcher found that adding 'you are an MIT mathematician' to a prompt fixes math errors in LLMs, and Alex Albert explains how Anthropic trains Claude's personality. Both resources are free and offer deep dives into how LLMs actually work.
@FinanceYF5: Neural Networks Speak English, But They Think in "Shapes" 1/ Neural Networks Don't Think in Words They appear to speak English on the surface, but internally they may organize information in geometric space: curves, loops, surfaces, manifolds. Understanding neural geometry may be the key to understanding, debugging, and controlling models.
Neural networks appear to speak English on the surface, but internally organize information in geometric space (curves, loops, surfaces, manifolds). Understanding "neural geometry" may be the key to understanding, debugging, and controlling models.
@HowToAI_: NVIDIA has done the impossible and nobody's talking about it. They trained a 12 BILLION parameter LLM in 4-bit precisio…
NVIDIA trained a 12-billion parameter LLM in 4-bit precision using the new NVFP4 format with micro-scaling, achieving near-zero intelligence loss while halving memory usage and tripling arithmetic speed, marking a major breakthrough in efficient AI training.