Back to blogDeutsche Version
AI Automation

AI Agent Evaluation in Production: Cost, Accuracy, and Escalation Rate

AI agent evaluation should measure cost per completed task, tool-call accuracy, escalation rate, correction rate, latency, audit completeness, and production feedback loops—not only model accuracy.

9 min readUpdated
AI agent evaluation dashboard showing cost, accuracy, escalation rate, audit logs, and risk markers for production automation

BLUF

AI agent evaluation in production should not start with a model leaderboard. It should start with the business workflow: what the agent is allowed to do, what a correct outcome looks like, how much each task costs, when the system escalates to a human, and which traces become regression tests. The useful metrics are not only model accuracy. They are cost per completed task, tool-call accuracy, escalation rate, latency, correction rate, and the quality of the audit trail.

For B2B teams, this is the difference between a demo and an operational system. A chatbot can be judged by answer quality. An AI agent must be judged by the actions it takes, the tools it calls, the evidence it uses, the errors it avoids, and the cases it safely refuses or escalates.

Why production agent evaluation is different

Classic LLM evaluation often asks: did the model produce a good answer? Production agent evaluation asks a harder question: did the system complete the workflow safely, cheaply, and with enough evidence to trust or audit the result?

An agentic workflow can include retrieval, tool calls, CRM updates, ticket routing, email drafting, approval gates, database reads, and human review. A single final answer does not reveal whether the intermediate steps were correct. The agent may produce a plausible summary while calling the wrong tool, using stale context, skipping an approval step, or consuming five times the expected tokens.

This is why production evaluation needs traces. LangSmith separates offline evaluation before deployment from online evaluation on production traces. Offline evals use curated datasets and reference outputs. Online evals monitor live runs and threads for quality patterns, safety issues, anomalies, and feedback loops. That distinction maps well to enterprise operations: test before release, monitor after release, then convert failures into new regression cases.

The metric stack that matters

MetricWhat it tells youWhy it matters in production
---------
Task success rateWhether the workflow completed the intended jobBetter than generic answer quality for agents
Tool-call accuracyWhether the agent selected the right tool and argumentsWrong tool calls create operational risk
Cost per completed taskToken, model, API, and infrastructure cost per successful outcomeA system can be accurate but economically unusable
Escalation rateHow often the agent hands off to a humanToo low can mean hidden risk; too high can mean poor automation
Correction rateHow often humans edit or reverse the agent outputMeasures trust and operational load
LatencyTime from request to usable resultCritical for support, operations, and incident workflows
Refusal / safe-stop rateHow often the system declines unsafe or uncertain actionsImportant for governed workflows
Audit completenessWhether traces, evidence, reviewer, and decisions are loggedRequired for debugging and compliance preparation

The goal is not to optimize every metric at once. Lower escalation can increase risk. Higher accuracy can increase cost. Faster responses can reduce evidence quality. The evaluation system should make these trade-offs visible.

Offline vs online evals

Offline evals are for pre-deployment confidence. They use curated examples, historical traces, synthetic cases, and reference outputs. They are useful for regression tests, prompt comparisons, tool schema changes, RAG retrieval changes, and model upgrades.

Online evals are for production monitoring. They run on real traces, often without reference outputs. They detect drift, unsafe outputs, failed tool calls, unusually expensive runs, latency spikes, and recurring edge cases. Good online evals do not replace human review; they route the right traces into annotation queues and offline datasets.

Evaluation modeBest useDataTypical evaluator
------------
Offline evalPre-release regressionCurated examples and expected outputsCode rules, human labels, LLM-as-judge, pairwise comparison
Online evalProduction monitoringLive traces without reference outputSafety rules, format checks, cost thresholds, reference-free quality checks
Human reviewAmbiguous or high-risk casesEvidence packet and traceStructured annotation, approval, rejection, correction
BacktestingValidate new version on old casesHistorical production tracesRegression score and failure replay

Cost per task: the ignored metric

Many teams track token usage but not cost per useful outcome. That hides the real economics. If an agent costs €0.40 per run but only completes 40% of tasks without human correction, the cost per successful automated task is closer to €1.00 before staff review time is included.

A practical formula:

ComponentExample measurement
------
Model costtokens in/out per run
Tool/API costsearch, OCR, CRM, vector DB, external APIs
Infrastructure costqueue, workers, storage, observability
Human review costminutes per approval or correction
Failure costrework, duplicate tickets, wrong actions, SLA impact

The useful KPI is not "cost per LLM call". It is:

Cost per completed task = total workflow cost / number of accepted successful outcomes

That number lets leadership compare agent automation against manual processing, classic workflow automation, and partial-assist tools.

Accuracy is not one number

For agents, accuracy has layers.

LayerEvaluation question
------
Intent understandingDid the system classify the user/task correctly?
RetrievalDid it fetch the right documents or records?
Tool selectionDid it choose the right tool?
Tool argumentsDid it pass the right fields and constraints?
Reasoning pathDid the trace follow an acceptable workflow?
Final answerWas the response factually correct and useful?
Action outcomeDid the business system end up in the right state?

Ragas exposes agent-oriented metrics such as tool-call accuracy, tool-call F1, topic adherence, and agent goal accuracy. Those are useful categories because they evaluate the agent as a workflow actor, not only as a text generator.

Escalation rate: safety signal, not failure signal

Escalation is often misread as automation failure. In production AI systems, escalation is a control mechanism. A healthy agent escalates when evidence is missing, permissions are insufficient, a customer-impacting action is requested, or the confidence/cost/risk threshold is exceeded.

The dangerous pattern is not a high escalation rate. The dangerous pattern is an agent that rarely escalates but later creates hidden errors, wrong updates, or unreviewed customer impact.

Escalation patternInterpretationAction
---------
High escalation, high correction qualityGood safety, weak autonomyImprove retrieval, tool schemas, and examples
Low escalation, high downstream errorsHidden riskAdd approval gates and stricter thresholds
High escalation, low human correctionOver-cautious automationTune confidence thresholds
Rising escalation after deploymentDrift or workflow changeAdd failed traces to offline dataset

Logging and EU AI Act readiness

This is not legal advice. But engineering teams should design evaluation systems so that logs, human oversight, and documentation are not added as an afterthought.

EU AI Act Article 12 requires high-risk AI systems to technically allow automatic recording of events over the lifetime of the system. Article 14 addresses human oversight. Even when a specific enterprise workflow is not high-risk, the same engineering pattern is useful: record what happened, why the system acted, who reviewed it, and what evidence was available.

For production agents, log at least:

Log fieldWhy it matters
------
Run ID and timestampTraceability
User/request contextDebugging and replay
Retrieved evidenceExplainability and correction
Tool calls and argumentsOperational accountability
Model/version/promptRegression analysis
Cost and latencyOperational economics
Escalation reasonSafety and improvement loop
Human reviewer and decisionOversight record
Final outcomeSuccess/failure measurement

A practical 30-day implementation plan

Days 1-7: define success and failure

Pick one workflow. Do not start with all agents. Define successful outcomes, unacceptable actions, escalation criteria, target latency, and cost ceiling. Create 20-50 representative test cases from real operations.

Days 8-14: add traces and offline evals

Instrument the workflow so every run captures inputs, outputs, tool calls, evidence, latency, cost, and final outcome. Build offline evals for tool selection, output format, retrieval quality, and business outcome.

Days 15-21: add online monitoring

Add production monitors for high cost, repeated tool failure, missing evidence, long latency, policy violations, and escalation patterns. Sample live traces for human review.

Days 22-30: close the feedback loop

Move failed production traces into the offline dataset. Add regression tests before each prompt, model, or workflow change. Review cost per accepted successful task weekly. Keep the eval dashboard small enough that operations teams actually use it.

Dashboard sectionMinimum widgets
------
Qualitytask success, correction rate, evaluator pass rate
Riskescalations, refusals, policy violations, high-risk tool calls
Costcost per run, cost per accepted task, cost by tool/model
Latencyp50/p95 end-to-end latency, slow tool calls
Feedback loopnew failed traces, reviewed samples, regression cases added

A good dashboard should support operational decisions: ship, roll back, raise approval threshold, change retrieval, update the tool schema, or add more examples.

The implementation implication

Agent evaluation is not a reporting layer. It is part of the architecture. If traces, costs, escalation reasons, and human decisions are not captured during execution, they cannot be reconstructed reliably later.

For consulting and internal AI teams, the recommended sequence is:

1. Build the workflow with trace IDs from day one.

2. Define success metrics before changing models.

3. Start with offline evals on curated cases.

4. Add online evals for live monitoring.

5. Route ambiguous cases to human review.

6. Feed failures back into the regression dataset.

This is how AI agents move from impressive demos to systems that operations, compliance, and management can trust.

Sources

- LangSmith Evaluation: https://docs.langchain.com/langsmith/evaluation

- LangSmith Evaluation Concepts: https://docs.smith.langchain.com/evaluation

- Ragas Metrics for Agents and Tool Use: https://docs.ragas.io/en/stable/concepts/metrics/available_metrics/

- EU AI Act Article 12 — Record-Keeping: https://artificialintelligenceact.eu/article/12

- EU AI Act Article 14 — Human Oversight: https://artificialintelligenceact.eu/article/14

#ki-agents#eu-ai-act#human-in-the-loop#ai-evaluation

Building AI into your operations?

I help teams design and ship compliant AI automation — production agents with n8n and LangGraph, RAG systems, and the evals to keep them reliable.

A

Written by

Ade Christanto

AI Automation Specialist and former network engineer focused on practical AI implementation for German B2B and Mittelstand companies.