Jet-Long Extends LLM Context with Dynamic Bifocal RoPE

Haozhan Tang, Zerui Wang, Yuxian Gu, Song Han, Han Cai· July 10, 2026 View original

▶ The 2-minute explainer

Summary

Jet-Long is a tuning-free, zero-shot method that efficiently extends Large Language Models' context windows by dynamically adapting a bifocal RoPE (Rotary Position Embedding) strategy. It maintains short-context fidelity while extrapolating cleanly to very long contexts, achieving superior performance and throughput.

Large Language Models (LLMs) are increasingly used in applications requiring very long contexts, often exceeding their pretraining window. Existing zero-shot context extension methods typically use a fixed rescaling factor, which either compromises short-context performance or fails at extremely long contexts. This research introduces Jet-Long, a novel tuning-free, zero-shot method designed to overcome these limitations. Jet-Long employs a dynamic bifocal RoPE (Rotary Position Embedding) strategy. It combines a local RoPE-faithful window with a long-range window whose rescaling factor adjusts dynamically based on the current sequence length. This design ensures that the base model's performance is recovered exactly for short inputs, while also allowing for clean extrapolation to significantly longer contexts. The method integrates an inclusion-exclusion attention merge and an on-the-fly RoPE correction rotation, making the bifocal construction computationally efficient during inference. Fused into a single CuTe kernel, Jet-Long achieves up to 1.39x FA2 throughput on H100 GPUs during long-context prefill and incurs minimal overhead (<=4%) during single-batch generation across all lengths. Benchmarked on Qwen3-1.7B/4B/8B up to 128K context, Jet-Long consistently outperforms strong baselines, achieves the best overall accuracy on HELMET-RAG, and shows the lowest PG-19 perplexity. It also generalizes to hybrid attention architectures and demonstrates hyperparameter resilience, simplifying deployment.

Why it matters

For professionals working with LLMs in applications like RAG, coding, or agentic workflows, Jet-Long provides a critical advancement by enabling efficient and reliable long-context processing without costly retraining or fine-tuning. This directly translates to more capable and versatile AI systems.

How to implement this in your domain

  1. 1Evaluate Jet-Long for extending the context window of your deployed or in-development LLMs.
  2. 2Integrate the dynamic bifocal RoPE strategy to enhance long-context performance without fine-tuning.
  3. 3Benchmark Jet-Long's throughput and accuracy on your specific long-context applications, such as RAG or code generation.
  4. 4Leverage its tuning-free nature to quickly deploy LLMs for tasks requiring extensive context.
  5. 5Explore its compatibility with various LLM architectures to maximize existing model investments.

Who benefits

Software DevelopmentAI/ML PlatformsResearch & DevelopmentContent CreationLegalTech

Key takeaways

  • Jet-Long is a tuning-free method for efficiently extending LLM context windows.
  • It uses a dynamic bifocal RoPE strategy, adapting to sequence length.
  • The method maintains short-context fidelity while extrapolating cleanly to long contexts.
  • Jet-Long achieves superior performance and high throughput with minimal inference overhead.

Original post by Haozhan Tang, Zerui Wang, Yuxian Gu, Song Han, Han Cai

"arXiv:2607.07740v1 Announce Type: new Abstract: Modern LLMs are increasingly deployed in long-context applications such as retrieval-augmented generation, repository-level coding, and agentic workflows whose accumulated reasoning and tool traces routinely push the input an order…"

View on X

Originally posted by Haozhan Tang, Zerui Wang, Yuxian Gu, Song Han, Han Cai on X · view source

Want to go deeper?

Turn these trends into skills with Learnijoy's hands-on AI & tech courses.

Explore courses