Definition
Plain language
The version of a program everyone agrees is correct, used as the standard to compare against.
As stated in the literature
A canonical known-good solution used as the oracle for computing expected outputs and for gating or repairing authored test suites.
Also called: reference solution, reference implementations, reference solutions, reference run
Why it matters: A known-good version turns test authoring from a guessing exercise into a mechanical one, and can also be used to throw out or fix tests that the correct code fails.
For example, if you already have a working sorting function, you run each test input through it and record what it returns as the expected answer.
Heard on the show
“The reference implementation is research-grade PyTorch that wasn't built to be served.”Episode 027 — When AI Agents Build the Serving Stack: A Bet on Bespoke Infrastructure