Unit 8 of 10 · about 5 hours · measure

Prompt perturbations and failure slices, paired uncertainty and multiple comparisons

The Classical ML unit on paired bootstrap, permutation tests and multiplicity supplied the statistical tools. Language-model evaluations add repeated generations, translated questions and prompt searches that can quietly change the sampling unit.

You'll be able to

  • Measure a predeclared prompt-format and failure-slice sweep with shared item identities and fixed generation settings.
  • Compute paired standard errors at the question level and account for shared-source or translated-item clusters.
  • Report practical effect thresholds, comparison families and selection history without turning exploratory slices into confirmatory findings.

Covers

Prompt variants, perturbations, domains, languages and failure slicesPaired uncertainty, multiple comparisons and practical effect size
1

Read

In this order, only the parts listed

0 of 3 done

  1. Sclar et al.: meaning-preserving format perturbationsQuantifying Language Models' Sensitivity to Spurious Features in Prompt Design (Sclar et al., 2023)

    Sections 3.1, Grammar of Plausible Prompt Formats; 3.2, Measuring Sensitivity; and 4.2, prompt-format performance spread

    Run three declared formats on your existing small item set. Do not implement the large bandit search or treat the paper's spread as a local target.

  2. Miller: question units, pairing and powerAdding Error Bars to Evals: A Statistical Approach to Language Model Evaluations (Miller, 2024)

    Sections 2.1 and 2.2, independent and clustered questions; Section 4, especially Equation 7 for paired differences and Equation 8 for clusters; Section 5, Power analysis

    Use the equations, not the arithmetic in Section 4.2's uniform-score example: with both variances 1/12 and covariance 1/24, the difference variance is 1/12, not 1/9. The relative reduction from 1/6 is one half.

  3. Pointwise versus multiplicity-corrected intervalsChatbot Arena: An Open Platform for Evaluating LLMs by Human Preference (Chiang et al., 2024)

    Appendix A, Confidence Interval Simulation Study, especially Figure 13's multiplicity-corrected intervals

    Connect this to the Math Foundations unit on bootstrap, permutation tests and multiple comparisons. Do not repeat the full ranking simulation.

2

Focus on

  • Declare format variants, slices, primary contrast and minimum useful effect before the final run. Check that paraphrases, option permutations and translated items preserve the task and gold mapping.
  • For independent question-level differences , use . Average repeated generations within question first; translated variants and shared passages may need cluster-level uncertainty.
  • Pairing preserves covariance; it narrows uncertainty when covariance is positive, not universally. Keep pairs together in the bootstrap and keep source clusters together when resampling clusters.
  • Show slice support, invalid counts, paired effect and uncertainty. Apply the earlier Holm procedure to the predeclared confirmatory family; label discovered slices exploratory and require fresh confirmation. More sampled answers do not replace more independent questions.
Common mistakes · 3
  • Counting every generation, translation and format variant as an independent question.
  • Selecting the best prompt or worst slice on final items and reporting an unadjusted interval as confirmatory evidence.
  • Reading a wide interval that includes zero as proof of equivalence. Compare its bounds with the predeclared practical margin.
3

Try it yourself

Closed-book, before checking anything

Closed-book, compute paired uncertainty for fixed synthetic correctness vectors A [1, 1, 1, 0, 0] and B [0, 1, 1, 0, 0]. The mean A-minus-B difference is 0.2 and its sample-standard-deviation-over-square-root-count SE is 0.2. Treating the two vectors as independent gives approximately 0.346410. Verify both in NumPy float64 with ddof=1. This five-item calculation checks arithmetic, not normal-interval coverage. Then run the predeclared three-format sweep and retain the complete item-by-format table.
4

Quiz yourself

Answer first, then mark it. Missed ones go to Review.

0 got · 0 missed

  1. 1.Can pairing increase the standard error?Answer

    Yes. The difference variance subtracts twice the covariance. Negative covariance increases it relative to an independent calculation; positive covariance reduces it.

  2. 2.Do item-level error bars include checkpoint-training seed variation?Answer

    No. They describe the stated question or cluster sampling process and possibly generation randomness. Training-run variation needs independently trained runs and a separate analysis.

  3. 3.What does a slice with only three questions establish?Answer

    It can supply concrete failure examples but usually weak population-rate evidence. Report the count and uncertainty, and confirm a general claim with more independent items.

You're done when

You reproduce the fixed-vector SEs, preserve pairing and cluster membership, and report every format and slice with its support, selection status and practical effect threshold.

Only when you can do this without notes.

Leads to

Notes

Resources · 3 for this unit, 15 more in the section

Also in this section

  • CS336 2026 - EvaluationStanford University · primary

    Step through the Lecture 12 trace (perplexity, knowledge, instruction, agent, reasoning and safety benchmarks, validity). Rebuild conditional perplexity, multiple-choice scoring and one generation evaluator, then fix prompt, decoding, item and inference-compute versions before any comparison.

  • Language Model Evaluation HarnessEleutherAI · required

    Follow docs/new_task_guide.md to write one local JSON task (dataset_path: json) with explicit output_type, prompt, choices, filters and metrics, and run it with --log_samples to keep per-sample outputs. Pin the harness version (0.4.13 was checked). should_decontaminate only marks a query; it does not search any training corpus.

  • Lessons from the Trenches on Reproducible Evaluation of Language Models (Biderman et al., 2024)EleutherAI · required

    Read Section 2.3 (why implementations of the same benchmark disagree), Section 3 (share exact prompts, code and model outputs) and Section 4 (uncertainty). Section 4.3 notes that its bootstrapped standard error covers resampling the questions, not training seeds.

  • Judging LLM-as-a-Judge with MT-Bench and Chatbot Arena (Zheng et al., 2023)LMSYS · required

    Read Section 3 (position, verbosity and self-enhancement bias and their mitigations) and Section 4.2 (agreement with humans). Swapping order reduces position bias but does not prove the judge correct.

  • Evaluating Large Language Models Trained on Code, Section 2 (Chen et al., 2021)OpenAI · support

    Read Section 2, Figure 3 and Appendix A for the unbiased pass@k estimator 1 - comb(n-c, k)/comb(n, k) and its stable implementation. Never report k larger than n, and run generated code only in a sandbox.

  • Length-Controlled AlpacaEval: A Simple Way to Debias Automatic Evaluators (Dubois et al., 2024)Stanford University · support

    Read Section 3: a regression that asks what the preference would be at equal length. Dividing a score by length is not this method, and length control leaves style biases.

  • Proving Test Set Contamination in Black Box Language Models (Oren et al., 2023)Stanford University · support

    Read Sections 2 and 3 (compare canonical-order likelihood with shuffled orders) and Section 6 (limits). It needs log probabilities and exchangeable examples, and it does not replace direct overlap checks.

  • ARENA 3.1 Intro to Evals and 3.3 Running Evals with InspectARENA · support

    Do 3.1 by hand (threat model, specification and 20 questions for one property) and 3.3 against a local model (Inspect dataset, solvers, scorers, choice shuffling). 3.1 and 3.2 assume a paid OpenAI API for generation; skip those calls rather than buying credit.

  • Build a Reasoning Model (From Scratch), Chapter 3 and Appendix FSebastian Raschka / Manning · support

    Use Chapter 3 (pp. 57-93: boxed-answer extraction, normalization, equivalence checks and grading on a MATH subset) as the first verifier you can break on purpose, and Appendix F for evaluation approaches.

  • Tulu 3, Sections 3.2 and 7 (decontamination and the evaluation framework)Allen Institute for AI · support

    Read Section 3.2 (prompt decontamination) and Sections 7.1 to 7.4 (OLMES, the development and unseen suites, how design decisions were evaluated) as a case of separating development from held-out evaluation.

  • Holistic Evaluation of Language ModelsStanford CRFM · required

    Read Sections 2 to 4 (scenarios and the seven metrics) and Section 7 (adaptation via prompting) to define capability, robustness, fairness, toxicity and efficiency as separate evidence. HELM entered maintenance mode on 2026-06-01, so treat the framework as methodology and do not run a second full evaluation stack.

  • Modern LLM Notebook - EvaluationWalking Labs · support

    Use notebooks-en/part3-inference/25-evaluation.ipynb for the framework map and judge examples. Its judge cells need an OpenAI-compatible endpoint, so point them at a local model or read them only, then add position and response-length counterexamples.

  • TensorTonic - Evaluation SetTensorTonic · support

    Solve Compute Conditional Perplexity (cs336-l12-conditional-perplexity), Score Multiple-Choice Continuations (cs336-l12-multiple-choice-likelihood), Fit Elo Ratings from Pairwise Votes (cs336-l12-pairwise-elo-fit) and Remove Response-Length Bias from Judge Scores (cs336-l12-judge-length-debiasing). Add all four to evaluator unit tests. Public test cases check the listed edge cases, not gradients or the hidden grader, so keep your own tests beside each solution.

  • InspectUK AI Security Institute · support

    Implement one small Inspect task on a local Hugging Face model with a deterministic scorer and one model-graded scorer. For greedy decoding pass do_sample=False in the model arguments; temperature=0 fails. Keep the .eval logs and compare the model grader against a trusted subset before using it for a claim.

  • LLM Research Track CheckpointRoadmap-Final · support

    Use the evaluation and compare sections as a closed-note audit after the harness exposes at least three instrument failures.