paper-with-me

홈 › Papers

Surgical Repair of Collapsed Attention Heads in ALiBi Transformers

2026-03-10 · Palmer Schallon arxiv

We identify a systematic attention collapse pathology in the BLOOM family of transformer language models, where ALiBi positional encoding causes 31-44% of attention heads to attend almost entirely to the beginning-of-sequence token. The collapse follows a predictable pattern across four model scales (560M to 7.1B parameters), concentrating in head indices where ALiBi's slope schedule imposes the steepest distance penalties. We introduce surgical reinitialization: targeted Q/K/V reinitialization with zeroed output projections and gradient-masked freezing of all non-surgical parameters. Applied to BLOOM-1b7 on a single consumer GPU, the technique recovers 98.7% operational head capacity (242 to 379 of 384 heads) in two passes. A controlled comparison with C4 training data confirms that reinitialization -- not corpus content -- drives recovery, and reveals two distinct post-surgical phenomena: early global functional redistribution that improves the model, and late local degradation that accumulates under noisy training signal. An extended experiment reinitializing mostly-healthy heads alongside collapsed ones produces a model that transiently outperforms stock BLOOM-1b7 by 25% on training perplexity (12.70 vs. 16.99), suggesting that pretrained attention configurations are suboptimal local minima. Code, checkpoints, and diagnostic tools are released as open-source software.

📄 PDF Abstract BibTeX arXiv:2603.09616

Code (0)

등록된 구현이 없습니다.

Similar Papers 제목 키워드 기반

Even Heads Fix Odd Errors: Mechanistic Discovery and Surgical Repair in Transformer Attention

2025-08-26 · Gustavo Sandoval arxiv

We present a mechanistic case study of a format-dependent reasoning failure in Llama-3.1-8B-Instruct, where the model incorrectly judges "9.11" as larger than "9.8" in chat or Q&A formats, but answers correctly in simple…

When Attention Goes Blind: Numerical Failure in ALiBi Positional Encodings

2026-08-04 · Christopher Schröder, Lukas Gienapp, Ferdinand Schlatt, Martin Potthast 외 hf

We identify a previously overlooked failure mode of ALiBi positional encoding: its linear bias scaling underflows floating-point precision, which zeroes out a large fraction of attention weights and renders the affected …

Linear Recency Bias During Training Improves Transformers' Fit to Reading Times

2024-09-17 · Christian Clark, Byung-Doh Oh, William Schuler

Recent psycholinguistic research has compared human reading times to surprisal estimates from language models to study the factors shaping human sentence processing difficulty. Previous studies have shown a strong fit be…

Sentence

Toward Localizing and Repairing Bias in Transformer Attention Heads

2026-07-14 · Sigma Jahan arxiv

Transformer language models are increasingly used as software components, yet biased outputs remain difficult to localize and repair inside the model. Existing fairness testing and repair methods largely operate at the i…

Positional LSH: Binary Block Matrix Approximation for Attention with Linear Biases

2026-05-10 · Daniel Wolfson, Tal Wagner arxiv

Positional encoding in transformers is commonly implemented through positional embeddings, attention masks, or bias terms, but formal connections between these mechanisms remain limited. We study attention with positiona…