Book a demo

What are agent evals? AI agent evaluation explained

On this page
  1. Short answer
  2. What an eval checks
  3. Three kinds of grader
  4. Trials, pass@k and pass^k
  5. Capability vs regression evals
  6. Offline and online evals
  7. Evaluation metrics
  8. Evals in the release gate
  9. Questions
  10. Related reading
  11. Sources
Short answer

Agent evals are repeatable tests that give an AI agent realistic tasks and score what it does against a pass mark. A good eval checks the final result and the steps the agent took to reach it: the tools it called, the data it touched and when it asked a person. Run evals before release, then again after every change to the model, the prompt or the tools, so a regression shows up in testing.

Key takeaways

  • An agent eval scores the outcome in the real system, beyond the agent's own report of success.
  • Agents vary from run to run, so give each task several trials.
  • Combine code, model and human graders, and calibrate the model graders against people.
  • Record the pass mark before testing and make it part of the release gate.

Agent evals check the outcome and the path to it

Anthropic's engineering team defines an eval as a test that gives an AI system an input and grades its output. It names four parts of an agent eval. A task is one test with defined inputs and success criteria. A trial is one attempt at the task. A grader scores part of the agent's performance, and the transcript records everything the agent did in that trial.

The outcome is the state of the system when the trial ends. In Anthropic's flight-booking example, the agent can write "your flight has been booked" in its transcript. The outcome is whether a reservation now exists in the database. Your eval should check the database as well as the agent's answer.

Most eval suites combine code, model and human graders

Anthropic groups graders into three kinds, and each one catches different failures.

  • Code graders check facts: an exact string, a passing unit test, whether a record exists, which tools the agent called. They are fast, cheap and reproducible, though they can fail a valid answer phrased in an unexpected way.
  • Model graders, often called LLM-as-judge, score open-ended work against a rubric, such as whether a reply follows policy. They handle nuance, cost more than code and vary between runs, so calibrate them against human reviewers.
  • Human graders review samples and edge cases. Subject experts give the most trusted judgment, at the slowest pace.

For coding agents, Anthropic says teams typically rely on unit tests for correctness and an LLM rubric for overall quality, adding other graders only when needed. A guardian agent applies a similar judging step at run time, reviewing other agents' actions as they happen.

Every task needs several trials, because agents vary between runs

Run the same task twice and an agent may take different steps, passing once and failing the next time. So run each task several times and look at the pattern. Two measures help you read it.

MeasureWhat it tells youUse it when
pass@kThe chance that at least one of k attempts succeedsOne good answer is enough, such as a coding assistant that can retry
pass^kThe chance that all k attempts succeedThe agent must behave the same way every time, such as refunds or customer replies

Anthropic's worked example shows how far the two can drift apart. An agent that succeeds 75% of the time on each trial passes all three of three trials only about 42% of the time.

Capability evals and regression evals answer different questions

Capability evals ask what the agent can do well, so they should start with a low pass rate on tasks it still struggles with. Regression evals ask whether the agent still handles everything it used to, so they should pass close to 100% of the time.

Take a hypothetical refunds agent. Your team swaps its model for a cheaper version, and the demo looks fine. The new model skips the approval step for refunds under a set amount, and the team had no regression test for that step. Finance finds the unapproved refunds at month-end reconciliation, weeks after the change.

A regression test that asserts every refund has an approval record would have failed on the first run after the swap. Write a regression test for each control the agent must respect, including risks from the OWASP Top 10 for Agentic Applications such as tool misuse and memory poisoning.

Offline evals run before release, and production monitoring takes over after

Anthropic describes automated evals as the first line of defense before launch and in CI/CD, running on every agent change and model upgrade. After launch, production monitoring catches drift and real-world failures the test set missed. Anthropic recommends combining the two, with periodic human review to keep graders calibrated.

Feed one into the other. When a production failure shows up in your bug tracker or support queue, turn it into a new eval task. Anthropic suggests 20 to 50 simple tasks drawn from real failures as a starting point.

AI agent evaluation metrics cover outcome, path, cost and safety

A pass rate alone hides why an agent failed. Group your metrics by what they protect:

  • Outcome: did the task end in the right system state?
  • Path: did the agent use the expected tools and ask for approval where required?
  • Cost: how many tokens, tool calls and minutes did each trial take?
  • Safety: did the agent stay within its permissions and refuse unsafe instructions?

Evals belong in the release gate, with a pass mark someone signed

Whatever graders you use, the pass mark needs an owner. Write it down before the first test run and record who agreed to it. Then make the eval a gate: an agent that misses its pass mark stays out of production until it meets the mark, or until the owner accepts the gap in writing. That makes AI agent testing part of the same release process as the rest of your software.

TaskInputs and success criteriaWritten from a real job the agent must do.
  1. TrialsRun it several timesAgents vary between runs, so one pass proves little.
  2. GradersCode, model and peopleCheck the system state as well as the reply.
  3. ScoreCompare with the pass markThe mark was written and signed before the first run.
  • Meets the pass mark
    ReleaseApproved deployThe agent moves on to production.
  • Misses the pass mark
    HoldOwner decidesFix and retest, or accept the gap in writing.
Figure 1. An agent eval as a release gate. Teal marks what you write down before testing. Coral marks the owner's decision when an agent misses its pass mark.
Figure 1 as text
  1. Task: define the inputs and success criteria, based on a real job the agent must do.
  2. Trials: run the task several times, because agents vary between runs.
  3. Graders: code, model and human graders check the system state as well as the agent's reply.
  4. Score: compare the results with the pass mark, which was written and signed before the first run.
  5. If the agent meets the pass mark, it goes to an approved deploy and on to production.
  6. If it misses, the owner decides: fix the agent and retest, or accept the gap in writing.

Moring AI's agent orchestration builds that gate into the route to production. Every agent passes five stages: a manifest, onboarding checks, evaluation against a pass mark, an approved deploy and production.

For outside assurance, AIUC-1 certification adds independent red-team tests run by AIUC against the agent.

Frequently asked questions

What are agent evals?

Agent evals are repeatable tests that give an AI agent realistic tasks and score its behavior against a pass mark. Agent evals check the final state of the system and the steps the agent took, including tool calls and approvals. Teams run them before release and again after every change to the model, the prompt or the tools.

How do you write evals for an AI agent?

Start with 20 to 50 simple tasks drawn from real failures, such as bug reports and support tickets, as Anthropic suggests. Give each task clear inputs and success criteria that check the system's final state. Choose graders for each task: code checks for facts, a model grader for open-ended quality and human review for samples. Run every task several times, and record the pass mark before the first run.

How is evaluating AI agents different from testing a model?

A model test usually scores a single response. An agent eval scores a multi-step task: the tools the agent called, the data it changed and the final state of the system. Anthropic notes that evaluating an agent means evaluating the model and the harness around it together, because both shape what the agent does.

What is the difference between pass@k and pass^k?

Pass@k is the chance that at least one of k attempts at a task succeeds. Pass^k is the chance that all k attempts succeed. Pass@k suits tools where one good answer is enough, such as a coding assistant that can retry. Pass^k suits customer-facing or money-moving agents that must behave the same way every time.

What is an LLM-as-judge grader?

An LLM-as-judge grader is a language model that scores an agent's work against a rubric, for example whether a reply follows policy. LLM-as-judge graders handle open-ended output that code checks cannot score. Anthropic advises calibrating them against human experts and letting the judge answer "unknown" when it lacks the information to decide.

How often should you run agent evals?

Run the full agent eval suite before the first release. Run the regression suite again after every change to the model, the prompt, the tools or the data the agent reads. Regression evals should pass close to 100% of the time, so any drop points to something that broke and needs a look before release.

What is a good pass mark for an AI agent?

A good pass mark for an AI agent depends on what the agent can change. An agent that drafts internal notes can ship with a lower score than one that moves money or answers customers. Agree the pass mark before testing, record who agreed to it, and keep regression evals close to 100%.

How does Moring AI handle agent evals before production?

Moring AI puts evaluation inside the route every agent takes to production. Its agent orchestration runs five stages in order: a manifest, onboarding checks, evaluation against a pass mark, an approved deploy and production. Once the agent runs, the AI Control Plane keeps audit records of what it does.

Sources