About this tool
Split a JSONL dataset into train, validation and test sets with a fixed seed for a reproducible, shuffled split.
This tool splits a JSONL dataset into train, validation and test files using a seeded Fisher–Yates shuffle, so the same seed always reproduces the exact same split. Split sizes are apportioned with the largest-remainder method, so the three counts always add up to the full record count. It is built for anyone preparing fine-tuning or evaluation data who wants a reproducible split without writing a script.
Open Dataset Train Test Splitter on AltFTool — it loads instantly in your browser.
Paste your code or data sample into the workspace.
Pick the format, conversion, or analysis you need.
Copy the polished result straight back into your project.
A seeded mulberry32 PRNG drives the shuffle — same data plus same seed equals byte-identical output files.
Largest-remainder apportionment guarantees train + validation + test equals the total, even for awkward percentages.
Parsing, shuffling and file generation all happen in the browser; the dataset is never uploaded.
80/10/10 is the common default for datasets of a few thousand records or more; 70/15/15 gives more evaluation signal for smaller sets. For very large datasets (millions of rows), validation and test sets of a fixed few thousand records each are usually enough, so the ratio can be far more train-heavy.
A seed makes the shuffle deterministic, so anyone can regenerate the identical split from the same data. Without it, every run produces a different partition and metrics from different runs are not comparable, because each model would be evaluated on different held-out examples.
Almost always yes. Datasets are often ordered by source, date or label, and an unshuffled split then concentrates one kind of record in the test set, biasing the evaluation. The main exception is time-series data, where you should split chronologically instead to avoid training on the future — turn shuffling off for that case.
JSONL (JSON Lines) is a text file with one complete JSON object per line and no commas between lines. Most fine-tuning APIs, including OpenAI's and many open-source trainers, expect this layout — for example one {"messages": [...]} or {"prompt": ..., "completion": ...} object per line. This tool treats every non-empty line as one record and can skip lines that do not parse.