Transformers Learn Two Competing Sorting Algorithms, and Only One Length-Generalizes
arXiv:2610.26974v1 Announce Type: new Abstract: We show that two-layer transformers trained to near-zero loss on a sorting task converge to one of two mechanistically distinct solution classes depending on their initialization. One solution class consists of solutions that do not use the second att…
Read the full story at arXiv cs.LG ↗
Timeline · 1 report
- 2026-10-21 04:00 · arXiv cs.LG
Transformers Learn Two Competing Sorting Algorithms, and Only One Length-Generalizes