CoolFace
Datasetpublic

sxiong/DHSA_Long-Data-Collections

DHSA_Long-Data-Collections A length-bucketed release of togethercomputer/Long-Data-Collections, used in Long-Context Modeling with Dynamic Hierarchical Sparse Attention for Memory-Constrained LLM Inference (ICML 2026 Spotlight). Each example is assigned to exactly one length bucket based on token count with meta-llama/Llama-3.1-8B-Instruct (add_special_tokens=True): Bucket Token range lt_8k [0, 8K) 8k_16k [8K, 16K) 16k_32k [16K, 32K) 32k_64k [32K, 64K)… See the full description on the dataset page: https://huggingface.co/datasets/sxiong/DHSA_Long-Data-Collections.

sourceHugging Facemitupdated 2mo agoView on Hugging Face
6likes710downloads
Dataset Card

DHSA_Long-Data-Collections

A length-bucketed release of togethercomputer/Long-Data-Collections, used in [Long-Context Modeling with Dynamic Hierarchical Sparse Attention for Memory-Constrained LLM Inference](https://arxiv.org/pdf/2510.24606) (ICML 2026 Spotlight).

Each example is assigned to exactly one length bucket based on token count with meta-llama/Llama-3.1-8B-Instruct (add_special_tokens=True):

BucketToken range
lt_8k[0, 8K)
8k_16k[8K, 16K)
16k_32k[16K, 32K)
32k_64k[32K, 64K)
64k_128k[64K, 128K)
gt_128k≥ 128K
  • Pretrain examples are bucketed by the text field.
  • Fine-tune examples are bucketed by the prompt field.

Directory layout

Long-Data-Collections/
├── README.md
├── length_bucket_summary.json
├── pretrain/
│   ├── lt_8k/
│   │   ├── arxiv_doc_to_abs.jsonl.zst
│   │   ├── NI_decontaminated_materialized.jsonl.zst
│   │   ├── P3_decontaminated_materialized.jsonl.zst
│   │   ├── pile_sub.jsonl.zst
│   │   ├── rp_sub.jsonl.zst
│   │   └── ul2_plus_oscar_en.jsonl.zst
│   ├── 8k_16k/
│   ├── 16k_32k/
│   ├── 32k_64k/
│   ├── 64k_128k/
│   └── gt_128k/
└── fine-tune/
    ├── lt_8k/
    │   ├── booksum.jsonl.zst
    │   └── natural_questions_10_200_docs.jsonl.zst
    ├── 8k_16k/
    ├── 16k_32k/
    ├── 32k_64k/
    ├── 64k_128k/
    └── gt_128k/

All files are zstd-compressed JSONL (.jsonl.zst). Each line is a JSON object preserving the original fields (text, and optionally meta / metadata for pretrain; text, prompt, completion for fine-tune).

Example counts by bucket

Pretrain (bucketed by text length)

Datasetlt_8k8k_16k16k_32k32k_64k64k_128kgt_128k**Total**
arxivdocto_abs377,854559,745436,259150,63228,5575,2581,558,305
rp_sub913,81811,2653,8931,019368151930,514
ul2plusoscar_en3,148,215342,73960,3069,2131,8042363,562,513
pile_sub1,878,09143,44312,8183,0221,7991,2851,940,458
NIdecontaminatedmaterialized460,066117,188567210120578,043
P3decontaminatedmaterialized757,54256,4658000814,015
All pretrain7,535,5861,130,845513,851164,09632,5406,9309,383,848

Fine-tune (bucketed by prompt length)

Datasetlt_8k8k_16k16k_32k32k_64k64k_128kgt_128k**Total**
booksum7,9091,20741364529,600
naturalquestions10200docs21,37025,87941,639690088,957
All fine-tune29,27927,08642,0521335298,557

Full counts are also available in length_bucket_summary.json.

Dataset description

This collection compiles long-context datasets for training and evaluating models that require extensive comprehension over large text inputs. It is derived from the public Together AI release and reorganized into length buckets for long-context experiments.

Pretrain data (pretrain/)

FileDescription
rp_subRedPajama book subset — diverse literary text
arxiv_doc_to_absRedPajama ArXiv papers with abstract appended after the paper body
ul2_plus_oscar_enUL2-style fill-in-the-blank completions (LAION Open-Instruction-Generalist)
pile_subSubsample of The Pile
NI_decontaminated_materializedNatural Instructions, decontaminated against HELM core scenarios
P3_decontaminated_materializedPublic Pool of Prompts (P3), decontaminated against HELM core scenarios

Fine-tune data (fine-tune/)

FileDescription
natural_questions_10_200_docsMulti-passage QA from Natural Questions (10–200 Wiki passages per question)
booksumLong-context book summarization

Fine-tune records contain prompt (context + instruction), completion (target answer/summary), and text (prompt + completion).

Usage

Load a specific bucket and file with the Hugging Face datasets library:

python
from datasets import load_dataset

ds = load_dataset(
    "json",
    data_files="pretrain/16k_32k/arxiv_doc_to_abs.jsonl.zst",
    split="train",
)

Or stream locally with zstd:

python
import json, zstandard as zstd

path = "pretrain/8k_16k/rp_sub.jsonl.zst"
with open(path, "rb") as f:
    with zstd.ZstdDecompressor().stream_reader(f) as reader:
        for line in reader:
            row = json.loads(line)
            ...

Licensing

Please refer to the original sources of each sub-dataset for their respective licenses. This dataset is a length-bucketed release of togethercomputer/Long-Data-Collections; upstream licensing terms apply.

Citation

bibtex
@inproceedings{xionglong,
  title={Long-Context Modeling with Dynamic Hierarchical Sparse Attention for Memory-Constrained LLM Inference},
  author={Xiong, Siheng and Zou, Joe and Fekri, Faramarz and Cho, Yae Jee},
  booktitle={Forty-third International Conference on Machine Learning}
}