Which of these are real train/test leakage modes for an instruction-tuning project?
Same topic, related formats. Practice these next.
Same topic, related formats. Practice these next.
Leakage is any path that lets train and eval secretly share information. Paraphrase duplicates, pretraining contamination, shared-document chunks, and teacher equals judge all qualify; file format and shuffle do not.
Imagine a teacher grading a take-home exam. Leakage is anything that lets a student see the answer key before grading. If the practice sheet and the real exam reword the same question, the student looks brilliant but learned nothing. If the exam was already printed in the textbook everyone read, scores soar for free. If the same person who wrote the practice answers also grades the exam, they reward their own style. All three inflate the score without real skill. But the color of the paper, or the order pages were stapled, changes nothing. Those are the trick choices: they sound technical, yet they never move answers from one place to another.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example.
Everything important, quickly.
5 min: the boundary-crossing test + paraphrase duplicates + pretraining contamination + shared-document chunks + teacher equals judge + why format and shuffle are decoys.
| Option | Real leakage? | Why |
|---|---|---|
| Paraphrased duplicates across splits | Yes | Same task, different wording; defeats exact-match dedup |
| Benchmark in base pretraining | Yes | Leak into pretraining; inflates the reported delta |
| Teacher family equals judge family | Yes | Judge rewards its own house style; eval-side bias |
| Same JSONL file format | No | Storage choice; moves no information across splits |
| Shared-document chunks across splits | Yes | Document-specific knowledge crosses the boundary |
| shuffle=True on the training set | No | Reorders batches; eval set is never trained on |
Real products, models, and research that use this idea.
What an interviewer would ask next. Try answering before peeking at the approach.
Red flags and common mistakes that signal junior thinking. Click to expand.
Relying on exact-match dedup and assuming the splits are clean. Paraphrased duplicates and shared-document chunks slip straight through string matching and quietly inflate the eval.
The night-before-the-interview bullets. Scan these on the way to the call.
Primary sources. Skim if you want the original framing.