Explore the research collection
3 entries · Follow this search
- Paper
The Spike, the Sparse and the Sink: Anatomy of Massive Activations and Attention Sinks
Mechanistically studies two recurring Transformer phenomena: massive activations (a few tokens show extreme outliers in a few channels) and attention sinks (certain tokens attract disproportionate attention mass regardless of relevance). Through systematic experiments, shows their co-occurrence is largely an architectural artifact of modern Transformer design, and the two serve related but distinct functions: massive activations operate globally — inducing near-constant hidden representations that persist across layers, effectively functioning as implicit parameters — while attention sinks operate locally, modulating attention outputs across heads and biasing individual heads toward short-range dependencies. The pre-norm configuration is the key architectural choice that enables the co-occurrence; ablating it decouples the two phenomena. Practical upshot: modifying normalization logic or adding dynamic gating can eradicate massive activations without hurting LM performance, giving a structural path to safer ultra-low-precision quantization and efficient KV-cache management.
- Paper
A Unified View of Attention and Residual Sinks: Outlier-Driven Rescaling is Essential for Transformer Training
Unifies the two emergent outlier phenomena in LLMs — attention sinks (a few tokens receiving large attention logits) and residual sinks (fixed dimensions with persistently large activations) — under 'outlier-driven rescaling': the outliers work jointly with normalization (softmax attention, RMSNorm) to rescale non-outlier components, and this mechanism is validated across architectures and training token counts. Main conclusions: (1) outliers function jointly with normalization — removing normalization eliminates the outliers but degrades training stability and performance; clipping outliers while keeping normalization also degrades, so outlier-driven rescaling contributes to training stability; (2) outliers act as rescale factors, not contributors — their post-norm contributions are far smaller than non-outliers'; (3) outliers can be absorbed into learnable parameters or replaced by explicit gated rescaling (GatedNorm), improving training performance by an average of 2 points and drastically improving quantization robustness (only 1.2 points degradation under W4A4). Since outliers' post-norm contribution is tiny, relying on them is what makes LLM quantization a nightmare (huge dynamic ranges).
- Paper
You Need Better Attention Priors
Generalizes attention through the lens of Entropic Optimal Transport (EOT): standard attention corresponds to a transport problem regularized by an implicit uniform prior. GOAT (Generalized Optimal Transport Attention with Trainable priors) replaces that naive assumption with a learnable, continuous prior that decouples spatial geometry from token semantics — standard positional encodings (e.g., RoPE) entangle position with meaning and corrupt semantic representations when forced to handle structural biases like attention sinks. The prior maintains full compatibility with optimized kernels like FlashAttention (zero compute overhead). GOAT also provides an EOT-based explanation of attention sinks and a solution that avoids standard attention's representational trade-offs. By absorbing spatial information into the core attention computation, GOAT learns an extrapolatable prior combining the flexibility of learned positional embeddings with the length generalization of fixed encodings — strong long-context extrapolation beyond training length.