Implement an n-gram/embedding contamination detector that flags eval items overlapping a t

Evaluation: Benchmarks, Judges & Uncertainty4 / 4

Chapter 154 / 4

Evaluation: Benchmarks, Judges & Uncertainty

Implement an n-gram/embedding contamination detector that flags eval items overlapping a t

Super-hard

Implement an n-gram/embedding contamination detector that flags eval items overlapping a training corpus and reports a contamination-adjusted score.

Target interface
shingles(text, k=8)

Implement the function/class skeleton in the editor. Any correct approach is accepted.

Hints0 / 2
Reference solution
Your own code stays in the editor.