Verification and Evals|INEMA.CLUB-PRO

Lesson 7 · 18 min

Honest metrics: pass@k, pass^k, variance, SWE-bench, and METR

"Gets 90% right" can mean it gets it right almost every time, or that it gets it right at least once in three tries. For a loop that runs without you, only the first one will do. In this lesson you measure both on your golden set, see how much the number swings between rounds, and learn to read SWE-bench and the METR horizon without overstating them.

Start the lesson
An oscilloscope screen with overlapping curves, and next to it graph paper with scattered dots.

In this lesson you will

  1. 1pass@k (at least one hit) and pass^k (gets them all)
  2. 2Repeat the set and watch the number swing
  3. 3SWE-bench: passing the test is not being accepted
  4. 4METR horizon: what it measures and what it doesn't

Goal: measure pass@k and pass^k with repetitions, read the variance between rounds, and cite SWE-bench and the METR horizon without overstating them.

01The same agent, three different numbers

Click each step.

Click each block in the diagram to see what it does.

For an autonomous loop, report pass^k and the spread between rounds, not pass@k.

02Rehearsal: an agent with 25% noise

The fake triage agent, with TRIAGEM_RUIDO=0.25, gets the "urgente" case wrong in 25% of attempts (fixed draw, reproducible).

Terminal · 10 cases × 3 attempts
E=~/projetos/loop-r-eng-verificacao-v72/kit/evals; mkdir -p /tmp/ensaio-evals
TRIAGEM_RUIDO=0.25 python3 $E/rodar-evals.py --agente "python3 $E/agente-triagem-falso.py" \
  --k 3 --saida /tmp/ensaio-evals/k3.tsv > /dev/null
python3 $E/passk.py /tmp/ensaio-evals/k3.tsv
Example from the repository
10 casos × 3 tentativas
taxa por tentativa: 73%  (rodada 1: 70% · rodada 2: 80% · rodada 3: 70%; desvio 5 pontos)
pass@3: 90%  (ao menos 1 acerto)
pass^3: 50%  (acertou todas)
se fossem independentes, 73%^3 = 39%
instáveis: t01 t06 t08 t10

The same agent can be advertised as "90%" (pass@3) or described as "half the cases always come out right" (pass^3). Round 2 alone would say 80%; rounds 1 and 3, 70%.

03Benchmarks: what you can claim

Only what the primary source says, with a date.

1. Passes ≠ accepted

METR estimated that about half of the PRs that pass the SWE-bench Verified tests would not be accepted by the project's maintainers.

A green test measures what the test covers. Style, scope, and side effects are left out: that's the space for the skeptical evaluator and the human sample.

04Your agent with k = 3

Uses your subscription quota: 30 calls with the rehearsal set. Afterward, swap in your own set.

Terminal · real (continues from the previous block)
python3 $E/rodar-evals.py --agente 'claude -p --tools ""' --k 3 --saida /tmp/ensaio-evals/real-k3.tsv
python3 $E/passk.py /tmp/ensaio-evals/real-k3.tsv
Example from the repository
armadilha  3/3
bug        15/15
duvida     6/6
pedido     6/6
total      30/30 (100%)  → /tmp/ensaio-evals/real-k3.tsv
10 casos × 3 tentativas
taxa por tentativa: 100%  (rodada 1: 100% · rodada 2: 100% · rodada 3: 100%; desvio 0 pontos)
pass@3: 100%  (ao menos 1 acerto)
pass^3: 100%  (acertou todas)
se fossem independentes, 100%^3 = 100%
instáveis: nenhum

Claude Code 2.1.303, default subscription model, 4 min 20 s. With 10 easy cases, the real agent got all 30 attempts right: this set measures no variance at all. To see pass^k drop, the set needs hard cases (lesson 5). Your number will depend on your set.

05Practice

Rehearsal, your agent, and one honest sentence.

E19 · pass@3 versus pass^3

10 min

Run the rehearsal with 25% noise.

Done when: passk.py prints pass@3: 90%, pass^3: 50% and instáveis: t01 t06 t08 t10.

E20 · Your set with k = 3

20 min

Run your golden set (lesson 5) with --k 3 and your real agent. Write one line in progress.md or in the agent's README with the date, number of cases, pass^3 and the spread between rounds.

Done when: python3 $E/passk.py [your tsv] prints the lines pass@3:, pass^3: and instáveis:, and grep -c "pass^3" [file where you took notes] → 1 or more.

06Lesson quiz

Question 1 of 4

For a loop that runs unsupervised, which metric matters?skill

07In three sentences

pass^k for loopspass@k measures luck with choice; pass^k measures what happens when nobody chooses.
Noise before improvementRun more than once; a difference smaller than the swing between rounds is not a gain.
Benchmark with a date and a caveatPassing SWE-bench is not being accepted; METR horizon is human task time at 50%, and the series stopped in 2026.

Going further

Previous lessonNext lesson