Task, Tool and Planning Metrics

Measure what the agent achieved first, then how it got there, how often it can repeat it and what it cost.

BeginnerIntermediateExpert · 13 min read · Last updated:

In short

Start with task success, judged by what changed in the world. Add tool and planning measures to explain failures, grounding for factual claims, consistency across repeated trials, safety violations as a separate count and cost and time per successful task. Report each by slice, with the number of trials.

What you will learn: precise definitions for outcome, tool, planning, grounding, consistency and efficiency metrics, how to compute them from traces and how to avoid misleading numbers.
Prerequisites: Agent Evaluation Framework and The Agent Loop: Observe, Reason, Plan, Act, Reflect.

Versions used

The example runs in November 2026 with Python 3.13 and only the standard library. The eight trials and their prices are invented.

Beginner Did it do the job?

Four questions, in order

OutcomeWas the goal met without breaking a rule?
BehaviorWere the tools, arguments and steps right?
ConsistencyDoes it succeed every time or only sometimes?
EfficiencyHow long did it take and what did it cost?

Work from the top down. A fast, cheap, tidy run that cancels the wrong order has failed. Behavior metrics are mainly diagnostic: they tell you why outcomes moved. Release decisions should rest on outcomes and safety, supported by the rest.

Task success and completion

A task is one situation with a goal. A trial is one attempt at it. Task success rate is the share of trials that met every required condition. Where possible, inspect the outcome, meaning the final state of the environment, rather than the agent's own report. A message saying "your booking is confirmed" is a claim; a booking record is evidence.

MetricDefinitionNotes
Task success rateTrials meeting all criteria ÷ trialsThe headline measure
Completion rateRuns that reached a final state ÷ runsFinishing is not the same as succeeding
False success rateRuns that claimed success but failed ÷ claimed successesMeasures how far the agent can be believed
Escalation rateRuns handed to a person ÷ runsSplit into correct and unnecessary handovers
Abandonment rateUsers who left before completion ÷ conversationsAn online measure with many possible causes
Partial creditWeighted share of subgoals metShows progress on long tasks
Partial credit can flatter

An agent that completes nine of ten steps in a money transfer has not done 90 percent of a transfer. Use partial credit to study progress, and keep a strict all-or-nothing measure for decisions.

Write each metric down precisely

Two teams can both report "accuracy" and mean different things. For every metric, record:

  1. The unit: a trial, a task, a tool call or a user.
  2. The numerator and denominator.
  3. What happens to errors, timeouts and refusals. Dropping them raises the score.
  4. The grader that decides, and its version.
  5. The direction that is better and the threshold that triggers action.

A timeout that never reaches the grader should normally count as a failure. If you exclude it, say so and report the count beside the score.

Intermediate Why did it succeed or fail?

Tool selection and execution

MetricQuestionComputation
Tool precisionWere the calls appropriate?Calls to expected tools ÷ all calls
Required call recallDid needed calls happen?Required calls made ÷ required calls
Argument accuracyWere the values right?Calls with correct arguments ÷ correctly named calls
Schema validityDid calls match the contract?Valid calls ÷ proposed calls
Execution successDid the tool work?Successful executions ÷ executions
Recovery rateAfter an error, did the run still succeed?Successful runs with errors ÷ runs with errors
Unnecessary call rateWas effort wasted?Calls not needed ÷ all calls

Keep model faults and system faults apart. A valid call that fails because a service is down says nothing about tool selection. Several different calls can also be acceptable, so list alternatives in the expected data or grade the outcome.

Planning quality and step efficiency

Planning is harder to score than tool use because good plans can differ. Combine simple counts from the trace with a rubric for what counts cannot see.

MeasureWhat it revealsCaution
Steps per successful taskDirectnessFewer is not better if checks are skipped
Step efficiencyReference steps ÷ actual stepsThe reference path is one option, not the only one
Repeated call rateLoops and forgotten resultsSome polling is legitimate
Replan rateHow often the plan changedHigh after tool errors may be healthy
Invalid step rateActions impossible in the current stateNeeds state-aware checks
Stop correctnessStopped when done, blocked or out of budgetJudge early and late stops separately

A plan rubric can ask: were prerequisites handled in the right order, were assumptions checked, was a needed question asked, and did the agent verify the result? See How Agents Reason and Decompose Tasks and Agent Decisions: Confidence, Stopping, Loops and Budgets.

Groundedness, faithfulness and citations

These measures ask whether statements are supported by the evidence the agent had. Support and truth are different: an answer can faithfully repeat a document that is wrong.

MetricDefinition
Claim support rateFactual claims supported by supplied evidence ÷ factual claims
Citation precisionCitations that support their sentence ÷ citations given
Citation coverageClaims needing a source that have one ÷ claims needing a source
Answer correctnessClaims that agree with trusted ground truth ÷ claims checked
Abstention qualityCorrect "I cannot tell" answers when evidence is missing

Scoring these usually means splitting an answer into claims and judging each, by people or a calibrated model grader (LLM Judges, Human Review and Ratings). Measure retrieval separately so you know whether the evidence ever arrived (RAG Evaluation, Grounding and Debugging).

Safety and policy measures

Report these on their own line. Do not average them into a quality score, because ten good answers do not cancel one data leak.

  • Forbidden action attempts and, separately, completed forbidden actions.
  • Required approvals skipped.
  • Harmful compliance: requests that should have been refused but were carried out.
  • Over-refusal: permitted requests that were declined.
  • Sensitive data exposure in outputs, logs or tool arguments.

An attempt that a control blocked is still worth counting. It shows how much you depend on that control (Safety, Robustness and Adversarial Testing).

Expert Consistency, efficiency and trust in numbers

Consistency: pass@k and pass^k

Two metrics answer opposite questions about k attempts. pass@k is the chance that at least one succeeds, which suits settings where you can check results and keep a good one. pass^k, introduced in the tau-bench paper, is the chance that all k succeed, which suits services where each user gets one attempt and expects it to work.

If attempts were independent and each succeeded 75 percent of the time, three in a row would succeed about 42 percent of the time. When you estimate from a finite set of trials without assuming a rate, the tau-bench authors count combinations: with c successes in n trials, the estimate is the number of ways to choose k successes from c, divided by the ways to choose k trials from n, then averaged across tasks.

Compute metrics from traces

"""Compute agent metrics from recorded trials (invented data)."""
from math import comb

# Each trial: task, goal met, tool calls as (name, arguments), cost in USD.
EXPECTED = {
    "refund": [("get_order", {"id": "A1"}), ("refund", {"id": "A1", "amount": 20})],
    "status": [("get_order", {"id": "B2"})],
}
ok_refund = EXPECTED["refund"]
ok_status = EXPECTED["status"]
TRIALS = [
    ("refund", True, ok_refund, 0.04),
    ("refund", True, [ok_refund[0], ok_refund[0], ok_refund[1]], 0.06),
    ("refund", False, [ok_refund[0], ("refund", {"id": "A1", "amount": 200})], 0.05),
    ("refund", True, ok_refund, 0.04),
    ("status", True, ok_status, 0.01),
    ("status", True, ok_status, 0.01),
    ("status", True, ok_status + [("list_orders", {})], 0.02),
    ("status", True, ok_status, 0.01),
]


def key(call):
    return call[0], tuple(sorted(call[1].items()))


def pass_k(successes, trials, k):
    """Unbiased estimate that all k independent attempts succeed."""
    return comb(successes, k) / comb(trials, k)


def report(trials):
    called = right_name = right_args = needed = found = repeats = 0
    for task, _, calls, _ in trials:
        want = EXPECTED[task]
        want_names = {c[0] for c in want}
        want_keys = {key(c) for c in want}
        called += len(calls)
        right_name += sum(c[0] in want_names for c in calls)
        right_args += sum(key(c) in want_keys for c in calls)
        repeats += len(calls) - len({key(c) for c in calls})
        needed += len(want_keys)
        found += len(want_keys & {key(c) for c in calls})
    wins = sum(t[1] for t in trials)
    spend = sum(t[3] for t in trials)
    print(f"task success        {wins}/{len(trials)} = {wins / len(trials):.1%}")
    print(f"tool name precision {right_name / called:.1%}")
    print(f"argument accuracy   {right_args / right_name:.1%} of correctly named calls")
    print(f"required call recall {found / needed:.1%}")
    print(f"repeated calls      {repeats / called:.1%}")
    print(f"cost per success    ${spend / wins:.4f}")
    print()
    for task in EXPECTED:
        rows = [t[1] for t in trials if t[0] == task]
        c, n = sum(rows), len(rows)
        print(f"{task}: pass^1={pass_k(c, n, 1):.2f}  pass^3={pass_k(c, n, 3):.2f}")


if __name__ == "__main__":
    report(TRIALS)

Output:

task success        7/8 = 87.5%
tool name precision 92.9%
argument accuracy   92.3% of correctly named calls
required call recall 91.7%
repeated calls      7.1%
cost per success    $0.0343

refund: pass^1=0.75  pass^3=0.25
status: pass^1=1.00  pass^3=1.00

Success looks respectable at 87.5 percent, yet the refund task succeeds three times in a row in only an estimated 25 percent of samples. That differs from the 42 percent above because it is estimated from just four trials, where one failure weighs heavily. The failing trial also shows why argument accuracy matters: the tool was right and the amount was ten times too large. A real system should block that call in code, whatever the metric later says.

Latency, cost and throughput

MetricReport asWhy
End-to-end latencyMedian and 95th percentileAverages hide slow tails
Time to first useful outputPercentilesWhat users feel in interactive work
Model and tool timePer stepShows where to optimize
Tokens per taskInput, cached and outputMain cost driver for many agents
Cost per successful taskAll spend ÷ successesCounts the price of failures
Human minutes per taskReview and correction timeOften larger than model cost
ThroughputSuccessful tasks per hour at a stated loadCapacity planning

Dividing total spend by successes means a cheaper model that fails often can turn out more expensive. Agent Cost Model and Token Economics explains the full calculation, and What to Measure: Metrics, Dashboards and SLOs shows how to watch these in production.

Aggregate without hiding problems

  • Slice first. Show results by task type, language, risk level and tool.
  • Choose the average. Averaging by task gives each task equal weight; pooling trials favors tasks you ran more often.
  • Show counts. "100 percent" on three trials is weak evidence.
  • Add intervals so readers see the uncertainty (Continuous Evaluation, Statistics and Scorecards).
  • List the worst failures beside the summary.
An average that misleads

Suppose 90 easy tasks all pass and 8 of 10 high-risk tasks fail. The overall rate is 92 percent. The high-risk rate is 20 percent. Only the second number should drive the release decision.

When a metric becomes a target

If you rewardYou may getPair it with
High completion rateConfident answers instead of escalationVerified success and false success rate
Low escalationRisky autonomySafety violations and complaint rate
Few stepsSkipped verificationRequired-check coverage
Low costWeaker results and more reworkCost per success and human minutes
Low over-refusalHarmful complianceBoth refusal measures together
Grader scoreOutput shaped to please the graderHuman samples and environment checks

Metrics for multi-agent and long-running work

Score the whole system on the same outcome measures as a single agent, so the comparison is fair. Then add handoffs per task, repeated or conflicting work, messages per success, time waiting for other agents and which component caused each failure. For long tasks, add checkpoints reached, recovery after interruption and the share of runs that needed a person partway through. More agents must earn their extra cost in the outcome numbers (Single-Agent vs Multi-Agent Systems).

Choose a small set

A dashboard with forty measures gets ignored. Pick a headline outcome, two or three safety counts, two diagnostic measures for your known weak points and cost and latency per success. Review the set each quarter: add a measure when a failure slips past, and drop one that has never informed a decision.

Agent typeHeadlineUseful companions
SupportVerified resolutionCorrect escalation, policy violations
CodingTests and review passedReverted changes, review minutes
ResearchCorrect, supported findingsCitation precision, missed key sources
Data analysisResult matches trusted queryUnsafe query attempts, clarification rate
OperationsCorrect state changeDuplicate actions, rollback rate

Always compare with a baseline

A number on its own rarely supports a decision. Measure the same tasks with the alternatives that matter, using the same graders and the same rules for failures.

BaselineWhat the comparison tells you
The current manual processWhether the agent is worth using at all, including error rates people already make
A fixed workflow or rulesWhether autonomy adds value over ordinary software
The released agent versionWhether a change is an improvement or a regression
A smaller or cheaper modelWhat the extra cost buys
A do-nothing or always-escalate policyThe floor; a metric that this policy wins is badly designed

The last row is a quick test of your measures. If an agent that always hands work to a person scores well on safety and cost, you also need a measure of useful work completed. If an agent that always says it succeeded scores well, the grader is trusting words instead of checking outcomes.

Common mistakes

MistakeBetter approach
Trusting the agent's success messageCheck the system of record
Dropping timeouts from the denominatorCount them or report them beside the score
One trial per taskRepeat important cases and report consistency
Requiring one exact tool sequenceGrade outcomes and truly required steps
Blending safety into one quality scoreReport violations separately with zero or tight limits
Cost per requestCost per successful task

Metrics checklist

  • Every metric has a unit, numerator, denominator and owner.
  • Task success is checked against environment state where possible.
  • Errors, timeouts and refusals have a stated treatment.
  • Tool and planning measures explain outcome changes.
  • Safety violations are counted separately.
  • Important tasks run several times and consistency is reported.
  • Results are sliced and shown with counts and uncertainty.
  • Cost and latency are reported per successful task and by percentile.

Frequently asked questions

What is a good task success rate?

It depends on the harm and cost of failure, so set the target from your process and compare with the current alternative.

Should the agent be scored on its reasoning text?

Use it for diagnosis, but base scores on outcomes and actions because the written reasoning may not reflect what drove them.

How many trials per task are needed?

Enough to separate the difference you care about from chance, with more for rare or serious failures.

Can one score summarize an agent?

A composite can help ranking, but keep the parts visible and never let it offset safety failures.

References and further reading

Next steps