CrazyJames26's picture
Add round-2 pretraining, SFT and evaluation data
bb6bc62 verified
|
Raw History Blame Contribute Delete
4.28 kB
---
license: other
language:
- en
tags:
- long-context
- distillation
- linear-attention
- deltanet
pretty_name: Dynamic DeltaNet round-2 training and evaluation data
size_categories:
- 1M<n<10M
---
# Dynamic DeltaNet — round-2 data
Exact tokenized data used in round 2 of the [Dynamic DeltaNet](https://github.com/Crazy-James26/Dynamic_DeltaNet) experiments, which replace all 28 attention layers of Qwen3-0.6B with DeltaNet-family mixers. Trained students are in [CrazyJames26/Dynamic_DeltaNet](https://huggingface.co/CrazyJames26/Dynamic_DeltaNet).
All token IDs use the Qwen3 tokenizer (`Qwen/Qwen3-0.6B`, vocab 151,936, EOS 151645; tokenizer SHA-256 `4c6e2f1d…2e86`).
| Directory | Stage | Records | Valid tokens |
|---|---|---:|---:|
| `pretraining_30b/distillation/` | Distillation (4,360 steps × 256) | 1,116,103 | 15,000,048,688 |
| `pretraining_30b/continued_pretraining/` | Full-parameter continued pretraining (4,222 steps × 256) | 1,080,598 | 15,000,048,736 |
| `sft_dhsa_untruncated/` | SFT, 2 epochs (442 steps) | 56,365 | 501,952,807 |
| `evaluation_1510/` | Evaluation prompts | 1,510 | — |
## Pretraining corpus (30B tokens)
Every record is 8,192–16,384 tokens. Each stage is mixed by token count:
| Source | Share | Tokens per stage |
|---|---:|---:|
| The Pile (Pile-CC, GitHub, Wikipedia-en, OpenWebText2, StackExchange) | 40% | 6.0B |
| RedPajama (CommonCrawl, C4, GitHub, StackExchange, Book) | 35% | 5.25B |
| Natural Instructions | 5% | 0.75B |
| P3 | 5% | 0.75B |
| arXiv long-document summarization | 15% | 2.25B |
Pile and RedPajama documents are deduplicated across sources (normalized document SHA-256). Short documents are packed with an EOS separator; long documents are split. NI and P3 keep whole prompt/answer units. The two stages use separate selections. Per-component token counts and selection hashes are in `pretraining_30b/provenance_audit.json`. `lr_sweep_holdout_128.json` lists the 128 held-out sample IDs used to choose the distillation learning rate.
## SFT
All 56,365 rows of the two DHSA buckets of [`sxiong/DHSA_Long-Data-Collections`](https://huggingface.co/datasets/sxiong/DHSA_Long-Data-Collections) (revision `61d64f96`): BookSum and Natural Questions (10–200 docs), 29,279 `lt_8k` and 27,086 `8k_16k` rows. Prompts and answers are complete; the longest record is 90,971 tokens. Loss is applied to answer tokens only.
## Evaluation
`evaluation_1510/samples.jsonl` holds 1,200 RULER needle-in-a-haystack items (8 tasks × 4K/8K/16K) plus 310 general-task and reading-comprehension items. RULER prompts are fed as `input + answer_prefix` and generate at most 128 tokens. `manifest.json` lists task counts and sources.
## File format
Each token directory (one per pretraining chunk `chunk_NNNNN/`, and `sft_dhsa_untruncated/`) contains:
- `tokens.bin` — flat little-endian `uint32` token IDs.
- `offsets.npy` — `int64` array of shape `(records, 3)`: `[start, length, prompt_length]`. `prompt_length` is 0 for pretraining; for SFT, tokens before it are the prompt (no loss).
- `manifest.json` — counts and SHA-256 of `tokens.bin` and `offsets.npy`.
The stage-level `manifest.json` lists all chunks in order with their hashes and the training plan (seed 4211, global batch 256). `selection.jsonl` / `selected_refs.jsonl` record the source of every row; `candidate_manifest` paths refer to the original cluster storage.
```python
import json, numpy as np
from pathlib import Path
def records(directory):
d = Path(directory)
tokens = np.memmap(d / "tokens.bin", dtype="<u4", mode="r")
for start, length, prompt in np.load(d / "offsets.npy"):
yield tokens[start:start + length], int(prompt)
stage = Path("pretraining_30b/distillation")
for shard in json.loads((stage / "manifest.json").read_text())["shards"]:
for ids, _ in records(stage / Path(shard["manifest"]).parent):
...
```
## License
This repository redistributes tokenized text from third-party datasets; each portion remains under its upstream terms (The Pile, RedPajama-Data, Natural Instructions, P3/PromptSource, arXiv summarization, DHSA Long-Data-Collections, RULER and the general-task benchmarks). The RedPajama `book` component may include copyrighted books. Check the upstream licenses before use.