AI “Solved” a 167-Year-Old Math Problem. Color Me Skeptical.
17.4 million lines of Lean, six checkers say it proves the Riemann hypothesis, and nobody can explain why. It went public the day after Anthropic’s IPO, on a date settled with its CEO.
Swapping dot‑product attention for RBF attention sounds like an architectural revolution. In Raphael Pisoni’s experiment, it turned out to be…

Swapping dot‑product attention for RBF attention sounds like an architectural revolution. In Raphael Pisoni’s experiment, it turned out to be something stranger: a one‑line algebraic tweak that silently reproduces half the “mysterious” behaviors of modern Transformers, and breaks the hardware stack in the process.
TL;DR
Pisoni’s math trick is the key: start from a distance‑based score instead of a dot product,
[
\text{score}(q,k) = -\gamma\lVert q – k\rVert^2
]
and expand:
[
-\lVert q – k\rVert^2 = -\lVert q\rVert^2 + 2 q\cdot k – \lVert k\rVert^2
]
Softmax over keys is translation‑invariant, so for a fixed query the (-\lVert q\rVert^2) term is just a constant offset and disappears. What remains is:
[
\text{softmax}(-\gamma\lVert q – k\rVert^2) \equiv \text{softmax}(2\gamma\,q\cdot k – \gamma\lVert k\rVert^2)
]
So scaled RBF attention is algebraically:
The first non‑obvious implication: you don’t need a new attention primitive to get the “RBF effect”. You can keep SDPA and add an explicit (-\lambda\lVert k\rVert^2) score bias per key. PyTorch’s FlexAttention exists precisely so you can inject this kind of score modification and still compile down to something FlashAttention‑like.
That means “distance‑based attention” is less a separate family of methods than a reparameterization of dot‑product attention’s existing geometry.
The real question becomes: what does that key‑norm penalty actually do to the model’s behavior?
In standard dot‑product attention, the score is
[
\text{score}(q,k) = \frac{q\cdot k}{\sqrt{d_k}}
]
Geometrically, that’s “cosine similarity times magnitudes.” A key with a huge norm can “win” even if it isn’t well‑aligned with the query, the “magnitude bullying” Pisoni calls out.
We already know the network leans on this. The attention sinks phenomenon (e.g. StreamingLLM’s
RBF attention quietly revokes that hack:
This does two things to the “shape” of attention:
You can see the same story from the opposite direction: many recent tricks, from QK‑Norm to learnable query gains, are ways of manually managing these norms. RBF attention just bakes one particular management policy, “don’t let keys blow up”, directly into the scoring rule.
So RBF is not “attention but different.” It’s attention with one very specific inductive bias surfaced and made non‑optional: keys should live on a reasonably sized shell, not spike into infinity.
On paper, swapping the metric is a two‑line refactor.
On actual GPUs, it’s a cascade failure.
Pisoni’s experiment ran into three kinds of breakage that are more interesting than the final TinyStories loss curves.
Naively computing pairwise distances with torch.cdist materializes the full (N\times N) distance matrix, instant OOM for any realistic context.
FlashAttention avoided this for dot‑products by treating attention as a tiled matmul with streaming softmax, never materializing full score matrices. As soon as your score is “dot product plus custom norm penalty,” you’re off the happy path.
The Triton RBF attention kernel in the repo has to re‑implement that tiling logic just to insert “(-\lVert k\rVert^2)” inside the fused loop. That’s effort most teams don’t want to repeat.
PyTorch’s FlexAttention is essentially a recognition that we’ve hit a software lottery: if your attention variant fits the built‑in kernels, it’s fast; if not, enjoy the OOMs. FlexAttention’s score_mod API is a way to write “2·qk − ||k||²” in Python and let torch.compile generate the fused kernel.
But until that kind of path is standard and stable, any deviation from SDPA is an explicit tax on memory‑efficient training and deployment.
RoPE works by rotating Q and K in a complex plane so that relative position becomes a phase shift in the dot product. It’s beautifully matched to cosine‑style similarity.
Euclidean distance doesn’t share those symmetries. Rotate Q and K jointly and the dot product is preserved; the distance is not. Pisoni finds that RoPE “interferes poorly” with RBF: you’re injecting position in a way that scrambles the distance geometry the score now cares about.
His fix is Subspace Sinusoidal Embeddings (SuSiE), sinusoids in a subspace with a learnable scale, no rotations. That’s an architectural fork:
If you’ve standardized on RoPE across a fleet of models, “just try RBF attention” actually means “also invent and validate a new positional scheme.”
Once you penalize key norms, the model loses its cheap attention sinks. That’s not just cosmetic; it affects optimization. Early in training, it’s often safer for a query to “look away” to a generic token than to make a sharp but wrong choice.
RBF attention removes that escape valve, so Pisoni introduces Register Tokens:
Again, this isn’t “RBF vs SDPA” in isolation. It’s a new architectural component whose presence or absence may matter more than the metric swap.
When you add up custom position encodings, register tokens, and custom kernels, the metric change has turned into an entire mini‑model family.
That’s the real engineering lesson: changing a single algebraic primitive in attention forces you to reveal how much of the stack, from RoPE to FlashAttention, is contingent on that choice.
So is RBF attention “better”?
On TinyStories‑scale experiments, Pisoni reports slightly better convergence than SDPA, but nothing like a phase change. Given the number of knobs moved (metric, position, extra tokens, kernel), that’s almost a wash.
The more interesting conclusion is different: RBF attention is most valuable as a probe, not a permanent replacement.
Three concrete uses:
The pattern here is familiar from other transitions (e.g., from naive PyTorch ops to custom CUDA, or from dense matmuls to sparsity): the “new” method is initially most powerful as a way to see what the old method was secretly doing, not as a wholesale drop‑in.
With RBF attention, that secret is simple: dot‑product attention is already a geometry over norms, we just hid the policy choice (how much to reward big keys) behind opaque training dynamics and hardware‑driven assumptions.
In a world tuned for dot products, RBF attention is less a new engine and more a diagnostic port: plug it in, see how your model behaves when you turn off norm‑based hacks, then decide which of those hacks you actually wanted all along.
17.4 million lines of Lean, six checkers say it proves the Riemann hypothesis, and nobody can explain why. It went public the day after Anthropic’s IPO, on a date settled with its CEO.
OpenAI’s machine-checked ETH proof covers a weaker theorem than it announced. Anthropic’s was checked by its own AI. A month on, not one human has confirmed either.
The ‘sixfold’ math boost from GPT-6 Astra? Run Qwen with thinking off, as its makers recommend, and the unedited model already scores 44–52%. The edit just stopped a known loop.