Urgent.News

What's breaking now, across hundreds of outlets.

Tech

On‑policy layer selection speeds long‑context models

FlashMorph2 shatters the long‑standing bottleneck where hybrid attention models either stall on very long sequences or sacrifice quality for speed. By eliminating hidden‑state drift, it delivers uniform acceleration that scales from a few hundred million to several billion parameters. Hybrid attention has always required a careful choice of which layers keep full attention under a compute budget,…

FlashMorph2 breaks through the long-standing obstacle limiting hybrid attention models' ability to handle extremely long sequences while maintaining high quality. By eliminating hidden-state drift, it achieves consistent speed improvements across a wide range of model sizes, from a few hundred million to several billion parameters.

Hybrid attention traditionally necessitates a delicate balance of which layers maintain full attention within strict compute constraints. However, the original FlashMorph method faced two main issues when transitioning to a discrete architecture: continuous branch interpolation and the use of teacher-forced hidden states, which caused hidden-state divergence and hampered both speed and final accuracy.

FlashMorph2 resolves these issues by conducting layer selection in just 0.72-3.57 GPU hours for 0.6B-8B models, demonstrating that on-policy evaluation and joint weight adaptation can be efficiently scaled. The method evaluates sampled discrete hybrid architectures end-to-end using their own hidden states and then backpropagates through the selection scores, allowing the entire pipeline to complete within a few GPU hours even at the largest model sizes.

Accuracy also improves with FlashMorph2, increasing average scores by 2.42 points on RULER, 1.08 on LongBench, and 0.76 on recall-intensive tasks compared to FlashMorph. These gains are observed across all tested Qwen3 variants, suggesting that the joint optimization benefits a wide range of long-context evaluations and is not merely an overfit to a single benchmark.

While the research only focuses on Qwen3 variants and linear-attention backbones, the findings raise questions about the applicability of the on-policy scheme to sparse-attention or multimodal transformers. Additionally, the extra weight-adaptation phase adds training overhead that may be challenging for teams without access to dedicated compute resources, potentially impacting the trade-off when scaling beyond 8 billion parameters.

If these results hold across broader architectures, production pipelines currently utilizing off-policy layer-selection steps should transition to FlashMorph2's on-policy joint optimization for a ready-to-deploy hybrid model that processes thousands of tokens faster without sacrificing downstream performance.

Rewritten by urgent.news; may contain errors — check the original.

Source: dev.to

Read the original at dev.to →

Report a problem with this story

More in Tech

Codex Logged Fast Mode. My Cost Tracker Still Couldn't Price 13.07M Tokens.

On November 25, I ran my Codex logs through agent-cost , a CLI I maintain that estimates costs from local usage records. It counted 13.07 million tokens from Fast mode and marked all of them unpriced…

  • 13.07 million tokens processed in Fast mode, unpriced
  • Servicetier = priority recorded, but parser misidentified mode
  • Updated parser will price Fast mode tokens correctly

I got tired of copy-pasting website tables into Excel, so I automated it with 30 lines of Python

If you have ever spent an afternoon copying a product table off a website row by row, this is the fix. You only need two libraries: requests to fetch the page, and BeautifulSoup to pull the table out.

  • Python script automates table data extraction from websites
  • Uses requests and BeautifulSoup libraries for web content fetching and HTML parsing
  • Converts extracted data into CSV files with optional pagination and data cleaning

More from Monday, 30 November 2026 →