Loom attention rewires Transformer circuits at every token
Original title: Rewirable Circuits in Transformers with Loom Attention
On the same 300B tokens and 2% extra FLOPs, LoomPythia-2.8B matches or beats Pythia-12B in the reported shot settings.
The paper proposes loom attention, mixing a head's vertical attention over earlier head outputs with horizontal attention over tokens. A per-token matrix memory acts as a second residual stream, producing LoomFormer. Across sizes and token budgets, the authors report it matching Transformers trained with over 3x compute and residual-stream baselines trained with about 1.7-2.8x. Code is released.
Unconfirmed: Compute and downstream gains are the authors' reported comparisons, not an independent replication.
- Vertical attention uses normalized, gated linear attention over matrix memory.
- LoomPythia-2.8B gained about 1.6x mHC-Pythia-2.8B's average downstream gain over Pythia-2.8B.
- It matched Pythia-12B at 0-shot and surpassed it at 5-shot, the authors report.
- Compared baselines include HC/mHC, MUDDFormer, and AttnRes.
- Organizations
- Caiyun-AI
From the original article
1 min read at huggingface.coWe propose loom attention, which allows a Transformer to dynamically rewire its circuits at every token by interweaving a head's vertical attention over the outputs of earlier heads (to obtain its query, key and value) with its horizontal attention over tokens.
By Da Xiao, Qingye Meng, Shengping Li · huggingface.co
A short excerpt; the article and its images belong to the publisher. Summary, key facts and assessment above are AI-written from the article and can be wrong.