Crimson AI NewsA CrimsonLingua Network service
EN ع
← Back to news
Research paper Hugging Face

SAS Ranks Context End-to-End to Make Sparse Attention Count

AI By Crimson AI Hugging Face Papers 14 September 2026 · 00:00 30 views
Share: X Telegram

A new Hugging Face paper proposes Simple Attention Sparsification (SAS), which injects a selector's continuous scores into attention logits so the language modeling loss can train context ranking directly, outperforming trainable sparse-attention baselines, especially under tight budgets.

SAS Ranks Context End-to-End to Make Sparse Attention Count

Key points

Post-training attention sparsification is a common way to cut the quadratic cost of attention in pretrained Transformers: instead of attending to every context unit, the model selects a small set of tokens or blocks for each query. Existing trainable approaches typically rely on a lightweight selector that scores context units, followed by a hard Top-K selection step.

That hard selection blocks gradients from the language modeling loss, so these methods usually fall back on distilling layer-wise dense attention distributions. As the paper notes, this encourages the selector to imitate dense attention weights rather than to rank units by how much they actually affect predictions under a fixed attention budget — a misalignment that can waste the limited budget on less useful context.

To address this, the authors propose Simple Attention Sparsification (SAS), a gated sparse attention mechanism that optimizes context ranking end-to-end with the language modeling loss. The core idea is to inject the selector's continuous scores into the attention logits during training, letting standard backpropagation update the selector directly.

The paper highlights several design choices it says are crucial for this simple approach to work well: placing the gate inside the attention softmax in log form, using normalized softmax gates to calibrate historical context against the always-retained current block, and preserving continuous selector scores so the model learns relative priorities instead of only hard selections.

To support long-sequence training, the authors implement a memory-efficient Triton kernel that integrates SAS into FlashAttention-style computation. Across reasoning, long-context understanding, and agentic tasks, SAS is reported to consistently outperform trainable sparse attention baselines across attention budgets, with especially large gains under tight budgets — evidence, the authors argue, of more effective context ranking for downstream tasks.

Source
Hugging Face · Hugging Face Papers
Related news
Research paper
Hugging Face 15 Oct 2026

New Survey Maps How Multimodal AI Agents Remember and Evolve

A Hugging Face survey proposes a two-axis framework for multimodal agent memory, separating how information is formed and represen...

6
Research paper
Hugging Face 15 Oct 2026

CriticOPD Fixes On-Policy Distillation by Letting Teachers Critique Student Errors

Hugging Face researchers introduce CriticOPD, a method that restores the teacher's ability to recover from student mistakes during...

7
Research paper
Hugging Face 15 Oct 2026

ActionOPD: Distilling Agent Decisions, Not Tokens

A new Hugging Face paper proposes ActionOPD, an action-level on-policy distillation method that aligns a student agent's decisions...

8