Evaluating LLM Systems
LLM evaluation is the process of measuring whether your AI system is actually doing what you want. Without systematic evaluation, you are shipping blind.
Why evaluation is hard
Unlike traditional software, LLM outputs are not deterministic or binary. There is no single "right answer" for most natural language tasks. Evaluation requires defining what "good" means for your specific use case — which varies substantially between a customer support bot, a document summariser, and a code assistant.
Types of evaluation
Human evaluation — human raters score outputs against defined criteria (accuracy, helpfulness, tone). Expensive, slow, but authoritative. Use for calibrating automated evaluators.
LLM-as-judge — using a more capable model to evaluate outputs from a deployed model at scale. Fast and cheap. Correlates well with human ratings when the judge model is calibrated. Risks: bias toward verbose outputs, sycophancy, and inconsistency.
Reference-based — comparing outputs to gold-standard reference answers using metrics like BLEU, ROUGE, or semantic similarity. Works for tasks with clear correct answers; less useful for open-ended generation.
Building an evaluation set
An evaluation set should cover: typical cases, edge cases, known failure modes, and adversarial inputs. Start small (50-100 examples), validate that the set reflects real usage, and expand as you learn more about where the system fails. Track performance against the eval set with every significant system change.
Shipping without an eval set is the LLM equivalent of deploying untested code. It feels faster — until you discover what broke in production.