An AI agent that does the right thing once has not proven much. Model output varies from run to run, a small change to a prompt can change behavior somewhere you were not looking, and a new model version can be better at one task and worse at another. Without a way to measure that, every change is a guess.
That way is an evaluation, or eval: a fixed set of tasks, each with a known right answer, that an agent must pass before it is trusted with real work. An eval answers two questions, not one. Is the result good enough? And is it worth what it costs? This article explains how we think about both, and the standard we have set for ourselves.
An eval is a test with a clear answer
Each case in an eval is a task on prepared data with an expected outcome. “Here are two customer records that describe the same company: the agent should propose a merge.” “Here is a record with a missing value: the agent should ask a person rather than guess.”
The important word is expected. If you cannot say in advance what the right outcome is, you cannot tell whether the agent got it.
Grade what the agent did, not what it said
A model can describe its work convincingly whether or not it did it. So our graders do not read the agent’s explanation. They read the record of what happened:
- The outcome. Did the run end where it should?
- The path. Did it go through the steps it should have, in order?
- The tools. Did it call the tools the task needs, and never the ones it must not touch?
- The evidence. Does its proposal point at the data that supports it?
- The budget. Did it stay within the time and cost the task allows?
Each of these is checked by a deterministic grader: the same run always gets the same grade. We deliberately do not use a second model to judge the first one’s free text. That would replace one uncertainty with another.
Once is not enough
Because model output is not deterministic, one passing run proves very little. Our standard is to run each case several times on a real model, and to require that:
- every critical case passes on every run, not on most of them;
- the overall pass rate stays above a set floor;
- every kind of task and every possible outcome has at least one case.
A critical case is one where getting it wrong would matter: changing data it should not, or skipping a person who should have decided.
Evaluate the model and the provider, not only the agent
An agent is a prompt, a set of tools and a model. Change any of the three and the behavior can change. A new model version, a different model from the same provider, or the same model reached through another provider is a change like any other, and it is evaluated like one.
So the same cases run on each model we consider, and we measure the model itself as well as the outcome:
- Valid output on the first try. How often the model returns the structured answer a step expects, without a retry.
- Errors and refusals. How often a call fails or the model declines a task it should do.
- Tokens and latency. How much input and output each step takes, and how long it waits.
Results only transfer to the model they were measured on. An agent that passes on one model says little about how it does on another, so an eval runs on the model the agent will actually use, and a change of model or provider means running it again before the agent is trusted on it.
Token economics: what a run is worth against what it costs
Quality is half of the question. Every run of an agent costs tokens, and tokens cost money. The other half is token economics: the value a run delivers against what it costs to get it. The measure that counts is the cost of a completed task, not the price of a token.
That changes what an eval measures. Beside the pass rate, each case records the tokens it used and what they cost, and each case has a budget. A run that reaches the right answer but goes far over its budget does not pass, because an agent that is right at any price is not ready for real work.
It also changes how we compare. Evaluation, for us, means comparison: when we change a prompt or a model, did runs succeed more often, cost less, or need less rework afterwards? Some answers are easy. A cheaper model that passes every critical case may be the right choice for a routine step. A more expensive one earns its place only where it measurably does better. A prompt that reaches the same result in fewer steps is an improvement even when the pass rate does not move.
The evals themselves follow the same rule. Running every case several times on a real model costs tokens too, so each proposed change first runs against a scripted stand-in for the model, which checks the harness and the graders at no cost, and the paid runs on real models are kept for the points where they decide something. The expected cost of an evaluation is known before it starts.
Real mistakes become new cases
When something goes wrong in real use, it becomes a new case, rebuilt on synthetic data, so the same mistake is caught every time after that.
A gate that can say no
An eval is only useful if a failure stops something. Ours are designed to run at two points: on every proposed change, where a failure blocks the change, and at release, where an agent is not switched on by default until it has a passing report.
The same thinking shapes the release tests we are building for the rest of the product. Matching quality will be measured against prepared datasets with known answers, and a drop below the expected result will fail the check. So will an unexplained improvement, because a result that suddenly gets better is as likely to be a broken measurement as a better product.
Where we are
We are applying this standard as we build the AI features in Masterly, starting with the first agents. It is the bar an agent has to clear before it is turned on, and we will write more as it is applied in practice.
The principle is simple, even when the work is not: if you cannot measure whether an agent did the right thing, and what it cost to do it, you should not let it do the thing.





