LiteLong: Resource-Efficient Long-Context Data Synthesis for LLMs

Junlong Jia, Xing Wu, Chaochen Gao, Ziyang Chen, Zijia Lin, Zhongzhi Li, Weinong Wang, Haotian Xu, Donghui Jin, Debing Zhang, Binghui Guo

TL;DR

This paper introduces LiteLong, a novel and resource-efficient method for synthesizing high-quality long-context data for LLMs. By leveraging the BISAC book classification system and a multi-agent debate mechanism, LiteLong generates diverse and relevant topics, enabling the creation of 128K-token training samples with significantly reduced computational costs compared to existing methods.

What Problem Does This Paper Address?

Large language models (LLMs) are increasingly being developed with larger context windows to handle complex tasks like document summarization and question answering over extensive texts. However, a major bottleneck in training these models is the scarcity of high-quality, long-form documents. Existing methods for synthesizing such data often rely on computationally expensive relevance-based aggregation techniques, which require substantial GPU resources for embedding generation or complex query construction. This makes creating large-scale long-context datasets a significant challenge, hindering further research and development in this area.

Methods

LiteLong tackles this problem through a two-stage process:

  1. Structured Topic Generation: Instead of relying on purely semantic similarity, LiteLong uses the BISAC (Book Industry Standards and Communications) classification system. This hierarchical system provides a structured and comprehensive way to organize topics. To ensure diversity and quality within these topics, a multi-agent debate mechanism is employed. Two "Debate LLMs" independently generate topic candidates for each BISAC subcategory. These candidates are then critiqued by each other, and a "Judge LLM" filters out low-quality or redundant topics. This debate process, conducted at the topic level, is computationally efficient.
  2. Resource-Efficient Data Synthesis: Once a curated set of topics is generated, LiteLong uses a lightweight BM25 retrieval method to find the top 256 relevant documents from a pretraining corpus for each topic. These documents are then concatenated to form training samples of the target length (128K tokens). This retrieval-based approach is significantly less computationally intensive than methods requiring dense embeddings for the entire corpus.

LiteLong can also be seamlessly integrated with existing long-dependency enhancement methods like NExtLong, further improving model performance.

Datasets

  • Training Data Sources: The paper utilizes two primary datasets for document retrieval:
  • FineWeb-Edu: A curated subset of web content focusing on educational resources, scholarly articles, and instructional content.
  • Cosmopedia V2: A comprehensive knowledge corpus covering multiple domains with an emphasis on factual accuracy.
  • A mixed dataset combining FineWeb-Edu and Cosmopedia V2 was found to yield the best results.
  • Evaluation Benchmarks:
    • HELMET: A benchmark designed to assess long-context understanding across multiple dimensions like recall, retrieval, and reasoning.
  • RULER: Another benchmark for evaluating long-context understanding.
  • LongBench v2: Used for evaluating performance after supervised fine-tuning.

Key Insights and Ideas

  • BISAC as a Structured Foundation: Leveraging a hierarchical, expert-curated classification system like BISAC provides a more structured and manageable approach to topic generation than purely unsupervised methods. This significantly reduces the computational burden.
  • Multi-Agent Debate for Quality and Diversity: The debate mechanism, where LLMs critique each other's topic suggestions, effectively balances generative diversity with discriminative filtering, leading to higher quality and more varied topics.
  • BM25 for Efficiency: Using BM25 for document retrieval is a key factor in LiteLong's resource efficiency, avoiding the high costs associated with dense vector embeddings for large corpora.
  • Topic Abstraction Matters: The level of abstraction in generated topics impacts downstream performance. Highly abstract topics benefit reasoning tasks, while specific topics are better for memory-intensive tasks like recall. This suggests that LiteLong's topic generation can be tailored for specific downstream applications.
  • LiteLong Complements Existing Methods: LiteLong doesn't just replace existing methods; it can be effectively combined with them (e.g., NExtLong) to achieve even better performance, demonstrating its versatility.

Key Results

  • LiteLong achieved the highest average score (61.90) across long-context metrics on the HELMET and RULER benchmarks, outperforming Quest by 6.65 points.
  • It showed particularly strong performance on Recall (83.23) and RULER (83.88) tasks.
  • When combined with NExtLong (LiteLong+NExtLong), it achieved a higher average score (63.04) than NExtLong alone (62.58).
  • Resource Efficiency: LiteLong demonstrated a dramatic reduction in computational cost. For generation, it required only 6 GPU hours compared to Quest's 806 GPU hours. In the combined setting, LiteLong+NExtLong used 176 GPU hours, while NExtLong alone required 928 GPU hours.
  • LiteLong maintained comparable performance on short-context tasks, indicating no significant degradation.
  • After supervised fine-tuning, LiteLong achieved a competitive score on LongBench v2, using only 19% of the GPU resources of NExtLong.

Limitations and Future Work

  • Limitations:
    • The paper acknowledges that while BISAC is effective, future LLMs might surpass it with automatic classification systems.
  • The effectiveness of the "Judge LLM" is better at identifying low-quality topics than selecting optimal ones, suggesting the "Filter-Reject" strategy is most effective.
  • The performance impact of topic scaling suggests that an optimal number of topics exists, and too many can lead to redundancy.
  • Future Work:
    • Exploring other modalities beyond text.
  • Incorporating more diverse retrieval strategies.
  • Investigating how LLM combinations in the debate mechanism can be used to tailor training data for specific long-context task categories.

Summary updated

BibTeX
@inproceedings{jia2026litelong,
  author = {Junlong Jia and Xing Wu and Chaochen Gao and Ziyang Chen and Zijia Lin and Zhongzhi Li and Weinong Wang and Haotian Xu and Donghui Jin and Debing Zhang and Binghui Guo},
  title = {{LiteLong: Resource-Efficient Long-Context Data Synthesis for LLMs}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2026},
  doi = {10.1609/aaai.v40i37.40390},
}
Figure