Erratum: Predicting How Transformers Attend §5.2 Theorem 5.2 — Heat capacity coefficient at γ=1
# Erratum — Predicting How Transformers Attend §5.2 Theorem 5.2 ========================================================= **Author**: Carles Marín — `[email protected]` **Date**: 2026-05-02 **Original paper**: [Marín 2026, Predicting How Transformers Attend (Zenodo 19826343)](https://doi.org/10.5281/zenodo.19826343) ========================================================== ## TL;DR §5.2 Theorem 5.2 of the paper states > $C_V(\gamma=1, N) = (\log N)^2 / 4$ and the correct asymptotic large-$N$ coefficient is $1/12$, not $1/4$: > $C_V(\gamma=1, N) \;\to\; (\log N)^2 / 12$ as $N \to \infty$ The error is **a factor of three**. It originates in the truncation of the partition-function expansion at first order in $(1-\gamma)$, missing a quadratic term that contributes the correction. The qualitative conclusion of §5.2 ($C_V$ finite at finite $N$, sharp in $N \to \infty$) is **unaffected**. The TAF Agent diagnostic tool ([HF Space](https://huggingface.co/spaces/karlexmarin/taf-agent)) computes $C_V$ via numerical derivative of $U(\gamma)$, not via the analytic formula, and therefore returns the corrected value automatically. ## Where the proof goes wrong The original proof retained only the linear term in $(1-\gamma)$ of the Z expansion. Including the quadratic term: $$ Z(\gamma, N) \;\approx\; \log N\,\Bigl[1 + \tfrac{(1-\gamma)\log N}{2} + \tfrac{(1-\gamma)^2 (\log N)^2}{6}\Bigr] $$ gives, after taking $\log Z$ and differentiating: $$ U(\gamma) \;=\; \tfrac{\log N}{2} + (1-\gamma)\,\tfrac{(\log N)^2}{12} + \mathcal O((1-\gamma)^2) $$ so that $$ C_V(\gamma=1, N) \;=\; -\gamma^2\,\tfrac{\mathrm{d}U}{\mathrm{d}\gamma}\bigg|_{\gamma=1} \;=\; \tfrac{(\log N)^2}{12}. $$ ## Independent confirmation The same result follows immediately from the cumulant identity $C_V(\gamma) = \gamma^2\,\mathrm{Var}_p(\log d)$ for $p \propto d^{-\gamma}$. At $\gamma=1$: $$ \mathrm{Var}(\log d) \;\to\; \tfrac{(\log N)^2}{3} - \tfrac{(\log N)^2}{4} \;=\; \tfrac{(\log N)^2}{12}. $$ ## Triple-system numerical verification | System | Method | Result | |---|---|---| | Sócrates / NumPy | Direct discrete $\mathrm{Var}_p(\log d)$, $N{=}10^4$ | $C_V = 7.89$ ; ratio to $(\log N)^2/4 = 0.37$ | | Sage docker | Exact rational arithmetic for $N \in \{10, 50, 100\}$ | ratio$/12 \to 1$ from above ; ratio$/4 \to 1/3$ | | SymPy | Symbolic integration of cumulant identity | $\mathrm{Var}(\log d) = (\log N)^2/12$ exactly | Three independent computer-algebra systems agree. The hand-derivation above produces the same coefficient. ## Impact | Item | Affected? | |---|---| | §5.2 qualitative conclusion (crossover, not divergence) | No | | §5.2 numerical example $N{=}2000 \to 14.4$ | Yes — corrected value $\approx 4.81$ | | §5.3 Fisher–metric identity $I = C_V/\gamma^2$ | No | | §3.3 Padé formula for $\gamma$ | No | | §4 MaxEnt power-law derivation | No | | §6 critical-layer formula | No | | §7 KV-compression theorems | No | | §8+ attention grammar / RLHF / fingerprinting | No | | TAF Agent (`heat_capacity_Cv`) | No (uses numerical derivative) | The corrected value $\sim (\log N)^2/12 \approx 4.81$ at $N=2000$ is **closer to the empirical broad-peak measurement of 6.86** at $\gamma \approx 1.235$ reported in the paper, removing the previously unexplained factor-3 discrepancy between theory and the paper's own measurement. ## How the error was caught This erratum was generated by the **Sócrates Audit Framework**, a methodology for self-falsifying scientific claims, applied recursively to its own author's published work. The framework's three-stage algebraic / numerical / triangulation workflow flagged the §5.2 claim within minutes of being run on the paper. It is the framework's first published real-world impact. The full audit log, the Sage script that triangulated the result, and the SymPy symbolic derivation are reproducible from the framework's repository. ------------------------------------------------------------------------------------------------------------ **Related fix**: TAF Agent v0.5.3 (KV-compression bug for Phase B models, simultaneous deploy) **Contact**: `[email protected]`
Authors
- CARLES MARÍN MUÑOZ
Publication Details
- Journal
- Zenodo (CERN European Organization for Nuclear Research)
- Published
- 2026-05-02
- DOI
- https://doi.org/10.5281/zenodo.19986818
- Primary Topic
- Heat Transfer and Numerical Methods
- Type
- article
- Field-Weighted Citation Impact
- 0.00