Your AI Product Needs Evals
- Source
- hamel.dev
- Author
- Hamel Husain
- Date

Context
An AI evaluator needs testing against human judgments before its scores become useful evidence. In Your AI Product Needs Evals, AI product consultant Hamel Husain describes collecting human decisions and explanations, then adjusting an automated judge to match the relevant quality standard.
A high agreement rate can still conceal poor error detection when failures are rare. Husain recommends checking precision and recall separately: how often flagged failures are real, and how many actual failures the judge catches. Continued human sampling then checks whether that holds. This gives teams a way to assess the measurement tool itself before relying on it to judge product changes.
- Teams stall at the demo because they only invest in changing behavior, prompting and , and skip the other two loops: measuring quality and inspecting traces to debug. Iteration speed is what compounds.
- Three levels of eval, ordered by cost: assertions on every code change, model and human review on a cadence, A/B tests only after significant product changes. Clear most of level one before climbing.
- unit tests are just assertions, and they pay off outside the test suite. The same assertion can trigger an automatic retry at , with its error message telling the model how to course-correct.
- Write assertions per feature and scenario rather than in general. A listing-search feature splits into one-result, many-results, and no-results cases, each with a concrete check like len(listings) == 0.
- Generate test inputs synthetically instead of waiting for production data: ask an LLM for 50 paired instructions, one that creates a contact and one that looks it up, so the round trip itself is the assertion.
- alignment — The work of making AI systems actually pursue what their builders and users intend, rather than something subtly or dangerously different.
- LLM — A large language model — the neural network behind tools like Claude and ChatGPT, trained on huge amounts of text to predict what comes next.
- fine-tuning — Taking a trained model and training it a bit more on your own examples so it gets better at one specific job.
- inference — Running a trained model to get answers — the phase where AI is actually used, as opposed to trained.
“I’ve found that unsuccessful products almost always share a common root cause: a failure to create robust evaluation systems.”
“If you streamline your evaluation process, all other activities become easy.”
“One signal you are writing good tests and assertions is when the model struggles to pass them - these failure modes become problems you can solve with techniques like fine-tuning later on.”
“99% of the labor involved with fine-tuning is assembling high-quality data that covers your AI product’s surface area.”
“Evaluation systems create a flywheel that allows you to iterate very quickly. It’s almost always where people get stuck when building AI products.”
Checking sign-in…
Loading comments…






