Benchmark Leakage in LLMs: Can We Still Trust Leaderboard Scores?

    This article examines how test set leakage is undermining the reliability of large language model (LLM) benchmark scores. It describes a case in which a base model reproduced an entire coding benchmark, explains how contaminated data can enter training and evaluation, and compares model rankings before and after memorized problems are removed. It closes with proposed approaches to leakage-resistant evaluation, including dynamic and private test sets, perturbed variants, perplexity-based checks, and multi-dimensional testing.

    In AI, the capabilities of large language models depend heavily on public standardized test sets. However, as training data grows explosively, test set leakage has become a serious problem. High scores on leaderboards increasingly fail to reflect what models can actually do. This raises a critical question for the industry: if a model relies on memorization rather than reasoning to answer questions, can we still trust its benchmark scores?

    1. Starting With a Coding Problem the Model Recited

    To test whether large language models truly have generalizable reasoning ability, researchers ran an revealing experiment. They selected a widely used code evaluation benchmark. The benchmark contains over one hundred programming problems and is one of the standard exams for measuring code generation ability.

    In the test, the researchers gave a newly released base model only Problem 66 from the benchmark. The model produced the correct answer. However, it did not stop there. It went on to generate the full text of Problem 67, including the problem statement, the input and output examples, and the official reference solution, word for word. It even reproduced a typo that the original author had made. It then continued with Problems 68, 69, and 70, in the same order as the original test.

    The researchers had not provided any of these later problems. With no context beyond the first prompt, the model generated the rest of the test from memory. This was not problem solving. It was recitation of the test set. After systematically testing the entire question set, the researchers found that the model could reproduce more than 96% of the problems, including both the questions and their answers. On the standard evaluation, the model scored a perfect 100 on this benchmark. The score clearly overstated its real ability.

    2. How Models Learn and How Data Contamination Happens

    To understand how serious test set leakage is, it helps to first look at how LLMs are trained. Their development generally has three core stages:

    1. Pretraining: The model reads a very large body of text, much like a huge library. Developers feed it large volumes of web pages, books, papers, and open-source code, often including public web crawl data such as Common Crawl. The output of this stage is a base model. It has broad knowledge and has learned the statistical patterns of language, but it does not yet reliably follow human instructions. If test questions and answers were published online and included in the pretraining corpus, the model would memorize them as if they were general knowledge.
    2. Post-training: The model learns to follow instructions through methods such as supervised fine-tuning (SFT) and reinforcement learning from human feedback (RLHF). These steps teach it to understand instructions, write code, and reason through problems. If a training data vendor packages test set items as question-answer pairs during this stage, the model can learn to match the standard answers directly, which leads to deeper memorization.
    3. Benchmark evaluation: This is the final exam. The industry scores models using public standardized tests, and the score tables in major vendor announcements come from these tests. The problem is that the tests are public. Once the questions and answers appear in material the model has already read or been trained on, the test no longer measures reasoning.

    Data contamination can range from mild to severe. In the mild case, a model trains on many similar questions and learns the patterns of a particular problem type. In the severe case, the model receives the original test itself and memorizes both the questions and the answers. It then retrieves them during evaluation instead of reasoning through them.

    Over the past period, both pretraining and post-training have shown the same trend across the industry. A growing share of high scores comes from models that have seen the test, rather than from genuine gains in capability.

    Take code evaluation as an example. After decontaminating several test sets, meaning the researchers removed the scores for problems that a model could reproduce verbatim, the rankings shifted dramatically. The base model mentioned earlier dropped from a score of 100 to 3.66 on coding after its recited problems were excluded. The same pattern appeared more broadly. Over the past month, four models that had ranked near the top saw their average rankings fall from first to last once their memorization-based scores were removed.

    By contrast, an open-source model and a closed-source model rarely reproduced the test set. This suggests their training data was relatively clean. In the “clean score” rankings that excluded recited problems, these models moved to the top. The result shows that a model can achieve high scores without memorization. It also shows that scores built on leaked data are likely to fail when a model faces new real-world problems.

    4. Solutions: Building Leakage-Resistant Evaluation

    Test set leakage misleads users about what models can do, and it also slows progress in the underlying technology. To restore confidence in benchmark scores, the industry needs leakage-resistant evaluation systems, built with both technical methods and changes to how evaluations are run.

    1. Dynamic generation and private closed-book tests
      Static public test sets will inevitably become contaminated. Future evaluations should shift toward dynamic generation, in which more capable models or human experts create new problems in real time. Organizations should also build private test sets, similar to closed-book exams, held by independent third-party evaluators. These sets would not disclose any problem details publicly. Models would answer through an API, which blocks the flow of test data into training sets at the source.

    2. Perturbed variants and equivalent transformations
      Publicly released baseline tests can still be used if their problems are modified. Examiners can adjust parameters, apply logically equivalent transformations, or refactor code to create variant problems. If a model has only memorized the original answers, its output on slightly changed problems will likely be wrong or off-topic. This method can help distinguish logical reasoning from pattern matching.

    3. Multi-dimensional cross-validation and perplexity detection
      Before an evaluation, teams can estimate whether leakage has occurred by measuring a model’s perplexity on test set data. If the model assigns unusually high probability to a specific text, that text has likely appeared in its training data. Evaluators should also reduce the weight given to any single leaderboard. Instead, they should add tests based on real business scenarios, long-tail instructions, and multi-turn dialogue, and cross-check the results across dimensions.

    Conclusion

    Test set leakage is a growing problem for both open-source and closed-source LLMs. When memorization replaces reasoning, leaderboards become a numbers game. Developers and enterprise users selecting a model should avoid relying on scores alone. They should instead assess how well a model generalizes to real, complex business scenarios. Only by building stricter, dynamic, and leakage-resistant evaluation standards can the LLM industry return to its core goal of improving capability.