Scaling Instruction-tuned LLMs to Million-token Contexts via Hierarchical Synthetic Data Generation

Linda He, Jue Wang, Maurice Weber, Shang Zhu, Ben Athiwaratkun +1 more
2/12/2026

No confident code implementation found for this paper. 5 possible matches can be shown below.

Abstract

Large Language Models (LLMs) struggle with long-context reasoning, not only due to the quadratic scaling of computational complexity with sequence length but also because of the scarcity and expense of annotating long-context data. There has been barely any open-source work that systematically ablates long-context data, nor is there any openly available instruction tuning dataset with contexts surpassing 100K tokens. To bridge this gap, we introduce a novel post-training synthetic data generation strategy designed to efficiently extend the context window of LLMs while preserving their general task performance. Our approach scalably extends to arbitrarily long context lengths, unconstrained by the length of available real-world data, which effectively addresses the scarcity of raw long-context data. Through a step-by-step rotary position embedding (RoPE) scaling training strategy, we demonstrate that our model, with a context length of up to 1M tokens, performs well on the RULER benchmark and InfiniteBench and maintains robust performance on general language tasks.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 5 weaker matches are hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{he2026scaling,
  title  = {Scaling Instruction-tuned LLMs to Million-token Contexts via Hierarchical Synthetic Data Generation},
  author = {Linda He and Jue Wang and Maurice Weber and Shang Zhu and Ben Athiwaratkun and Ce Zhang},
  year   = {2026},
  eprint = {2504.12637},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2504.12637},
  journal = {ICLR 2025 2025}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2504.12637.svg)](https://codeofpaper.com/paper/2504.12637)

Discussion