LLM Evals Explained

A language model always produces an answer. It will summarize, code, translate, or reason on demand and never simply say it has nothing to give. This is exactly why evaluating LLMs (LLM evals) is a discipline rather than an afterthought: without measurement, you cannot tell a working system from a confidently broken one. LLM evals are how you know whether a prompt change helped, whether a new model is actually better, and whether the agent you are about to ship is safe enough to release. They are the quality gate of the entire field, and the teams that build them well ship better AI systems faster than those that rely on vibes.

Understanding LLM evals means understanding three things: what an evaluation actually is, the different ways to score outputs, and the special challenges that arise when the system being evaluated is an agent rather than a single model response.

What an LLM eval actually is

At its core, an LLM eval is three things: a set of test inputs, the outputs the system produces for them, and a scoring method that turns those outputs into a signal. That is it. The inputs should be representative of real usage: not toy examples, but the kinds of questions or tasks the system will actually face. The scoring method is the hard part, because there is usually no single correct answer the way there is for addition. A summary can be good in many ways and bad in many ways. So LLM evals lean on methods that can handle open-ended outputs, which is what makes them a distinct discipline from traditional software testing.

Three ways to score outputs

The scoring methods fall into three families, and most real systems use a mix.

Human evaluation

People rate the outputs on dimensions like helpfulness, accuracy, and safety. This is the gold standard for quality because humans are still the best judge of whether an output is actually good. It is also slow and expensive, which is why it is usually reserved for final validation and for building the benchmark sets that automated methods are checked against. You cannot run human evals on every prompt change, so it anchors the system rather than driving iteration.

Automated and heuristic metrics

These are cheap, deterministic checks. For tasks with known answers (math, factual questions, code with tests) you can grade outputs automatically: exact match, code that passes a test suite, a number within tolerance. For code, the pass@k metric checks whether the model produces a correct solution within k attempts. These metrics are fast and trustworthy when they apply, but they only apply when there is a checkable answer, which excludes much of what LLMs do.

LLM-as-judge

For open-ended outputs without a single right answer, a second, strong model scores the output against a rubric. This is the workhorse of modern LLM evals because it scales like an automated metric while handling the open-ended cases humans would otherwise grade. It comes with its own problems: the judge model has biases (it may prefer longer answers, or outputs from its own family), it can be inconsistent across runs, and it is only as good as the rubric you give it. Good LLM-as-judge setups calibrate the judge against human ratings first, so you know the automated score tracks real quality.

Benchmarks versus application evals

It helps to separate two scales of LLM evals. Benchmarks are standardized suites (general-knowledge questions, reasoning puzzles, coding problems) used to compare models on broad capability. They are useful for picking a model but tell you little about how it performs on your specific task. Application evals are the eval set you build for your own system: real or realistic inputs drawn from your actual use case, scored on the dimensions that matter to your users. Application evals are what tell you whether your system works; benchmarks are what tell you which model to start from. Teams that rely only on benchmarks ship systems whose real-world quality is a mystery.

The metrics that matter for open-ended tasks

For tasks without a single right answer, LLM evals measure a few recurring qualities. Faithfulness asks whether every claim in the output is supported by the source material: the central metric for RAG and summarization. Answer relevance asks whether the output actually addresses the question. Context precision and recall measure whether the right information was retrieved and ranked well. For code, functional correctness via test cases dominates. For agents, trajectory quality measures whether the steps the agent took were sensible, not just whether the final answer was right. These dimensions are usually scored by an LLM judge against a rubric and tracked as numbers over time.

Building your own eval set

The highest-leverage activity in applied LLM evals is building an evaluation set for your own system. Collect real inputs from usage, edge cases, and adversarial examples. For each, define what a good output looks like, ideally with a rubric a judge can apply. Start small (fifty well-chosen examples beat five hundred noisy ones) and grow it as you learn where the system fails. Run every prompt, model, or retrieval change against this set and track the scores. This turns improvement from guesswork into measurement, and it is the single practice that separates teams that ship reliable AI from teams that ship demos.

Evaluating agents is harder

Single-response LLM evals are hard enough; agent evals add a dimension. An agent’s output is not just a final answer but a trajectory: a sequence of tool calls, intermediate reasoning, and observations. Two agents can reach the same correct answer with very different paths, one efficient and one wasteful. So agent evals measure not only outcome correctness but trajectory quality: did the agent call the right tools, avoid loops, stay within budget, ask for help when stuck? Evaluating the trajectory catches failure modes (runaway loops, redundant tool calls, lost goals) that outcome-only evals miss. It is also more expensive, because judging a multi-step trajectory takes more judge calls than judging one answer.

Common pitfalls

  • Overfitting to the eval set. If you tune prompts against a small set until it scores perfectly, you may have learned the set rather than improved the system. Hold out examples and refresh the set periodically.
  • Uncalibrated LLM judges. A judge that has not been checked against human ratings may be systematically wrong. Calibrate before you trust it.
  • Measuring only the easy dimension. Accuracy is measurable; safety and helpfulness are what users feel. Make sure your LLM evals cover the dimensions that actually matter, not just the ones that are easy to score.
  • No evals at all. The biggest pitfall is shipping without measurement. A rough eval set run on every change beats a perfect eval set you never built.

Pro Tips

Build your own application eval set early. A small, curated set of real inputs with a scoring rubric is the highest-leverage thing you can build. It turns every future change from a guess into a measurement.

Calibrate your LLM judge against humans. Before trusting automated scores, confirm the judge tracks human judgment on a sample. An uncalibrated judge gives you confident wrong numbers.

Evaluate the trajectory, not just the outcome, for agents. Outcome-only agent evals hide the loops, waste, and near-misses. Judge the path the agent took, and you catch failure modes before users do.

Further reading

LLM evals are the quality gate underneath every applied system: RAG, agents, coding assistants. For the retrieval-specific metrics, see how RAG works; for the trajectory-eval challenge, see agent design. The teams that win at applied AI are the ones that measure relentlessly, and LLM evals are how they do it. The vocabulary of this discipline, from benchmarks to LLM judges, is gathered in lesson 12 of the AI glossary.