AdaMLLab/WebTerminal
Terminal/CLI Web Text A filtered extract of terminal and command-line content from two large web-text corpora, designed for upsampling agentic-adjacent data during pretraining. Subsets Subset Rows Tokens Size Quality clean (default) 2.33M 4.6B 11 GB ~98% terminal content unfiltered 61.3M 359B 962 GB ~15% terminal content from datasets import load_dataset # Load the clean subset (default) ds = load_dataset("AdaMLLab/WebTerminal") # Load the… See the full description on the dataset page: https://huggingface.co/datasets/AdaMLLab/WebTerminal.
Terminal/CLI Web Text
A filtered extract of terminal and command-line content from two large web-text corpora, designed for upsampling agentic-adjacent data during pretraining.
Subsets
from datasets import load_dataset
# Load the clean subset (default)
ds = load_dataset("AdaMLLab/WebTerminal")
# Load the unfiltered subset
ds = load_dataset("AdaMLLab/WebTerminal", "unfiltered")Sources
- DCLM (
Zyphra/dclm-dedup) - FineWeb (
Salesforce/fineweb_deduplicated)
How it was built
v0.1 Unfiltered
- Fast filter: skip any document that doesn't contain obvious CLI indicators (
$,sudo,pip install, ``bash,root@`, etc.) - Score: remaining docs are scored (0-34) across five signals, each with a per-match point value and a cap:
Documents scoring >=5 are kept.
- Dedup: exact dedup across both datasets using xxhash64 on full text. Removed 1,168 duplicates.
v0.2 Clean
The unfiltered subset is ~84-86% noise at lower score levels (5-12), which make up 93% of the data. The root cause: v0.1's scoring uses context-blind keyword matching, CLI command names like find, make, cat appear in normal English prose, bare $ matches currency amounts, and indented Python/SQL code gets scored as terminal content.
v0.2 applies a three-stage structural filter over the unfiltered data:
- Context-aware: instead of matching bare
$, requires$ sudo,$ git,$ docker, etc. (dollar sign + space + known command). Eliminates ~87% of documents immediately. - Validation regex: confirms a genuine structural terminal pattern exists, shell prompts followed by real commands,
user@host:~$patterns, Python REPL>>>, tracebacks, ``bash` code blocks, Unix file permission listings, man page headers, shebangs. - Weighted structural scoring (
term_score_v2): each pattern has a weight (1-3) and occurrences are capped. Documents needterm_score_v2 >= 3to be kept.
No indentation-based scoring. No context-blind command substring matching.
Result: 3.8% of the unfiltered data survives, from 61.3M rows down to 2.33M rows. Quality jumps from ~15% to ~98% terminal/CLI content.
Schema
Clean subset
Unfiltered subset
Stats
Clean (v0.2)
- 2,334,414 rows | 4.6B tokens (Llama-3.2-1B tokenizer) | 11 GB
- 62 parquet files, ~169-185 MB each, snappy compressed
Unfiltered (v0.1)
- 61,341,278 rows | 359B tokens | 962 GB
- 4,187 parquet files, ~180-240 MB each, snappy compressed
Use case
Upsampling agentic-adjacent data during pretraining. The clean subset is recommended for most use cases. The unfiltered subset is available for researchers who want to apply their own filtering.
