Monitoring and Observability for Production AI Agents

Step-level tracing and continuous evaluation expose agent failures that uptime dashboards miss.

· 9 min read
Cover illustration for “Monitoring and Observability for Production AI Agents”
AI Production Readiness · November 11, 2026 · 9 min read · 1,984 words

Monitoring an AI agent in production takes more than traditional application performance monitoring. Agents can get every technical operation right and still get the wrong result. Operations need step-level tracing across tool calls, reasoning steps, and decision points, combined with continuous evaluation, cost attribution, and audit logs. Together, these make semantic failures visible before they compound.

Why traditional APM cannot see inside a running agent

An agent handles customer requests overnight, and support tickets come in hours later. It has confidently taken wrong actions, but there is no trace of why. The service itself appears healthy. Latency, throughput, error rates, and HTTP status codes describe successful execution. Traditional APM cannot encode “technically fine, substantively incorrect.”

This blindness follows from three broken assumptions. The same input can produce different execution paths, failures can occur without exceptions, and the decisive behavior happens inside the run. Aggregating unlike runs can therefore produce averages that describe no meaningful execution. A health check reporting “up” cannot distinguish a correct run from one that called three unnecessary tools and hallucinated a fact.

What non-determinism actually does to production agent behavior

Temperature, retrieval results, and tool availability can change an agent’s path between consecutive runs of the same prompt. One reference trace is therefore insufficient. Operators need the distribution of behaviors across many runs to distinguish normal variance from a regression. The consequences of a different tool sequence need to be visible so operators can assess it.

Errors also propagate through the agent’s working context. A wrong retrieval changes the plan, a bad tool argument corrupts the result, and a sub-agent handoff loses context that later steps need. Malformed tool output can poison working memory even when every operation that follows succeeds at a technical level. Observability must therefore capture process as well as outcome, including the recorded reasoning, tools considered and invoked, arguments, responses, token consumption, and latency at each hop.

The four things an agent observability stack must capture

A stack audit begins with four required components. Structural traces must represent each run as a tree of nested spans covering model calls, tool calls, reasoning steps, retries, inputs, outputs, latency, and cost. In multi-agent systems, they must identify which agent handled each step and where coordination failed. Evaluations must then score production behavior continuously, including tool selection, reasoning coherence, retrieval faithfulness, and step-level correctness. Final-answer accuracy alone leaves intermediate failures unmeasured.

Cost attribution must break token spend down by run, agent, user, and workflow. This exposes expensive behavior that otherwise disappears inside a total bill. Audit logs must preserve actions and human review decisions for incident reconstruction, regulatory review, and future evaluation cases. Input/output drift detection and tool-call pattern anomaly detection round out this coverage by showing when data changes or behavior is unusual. Without ongoing evaluations, even detailed instrumentation remains primarily a trace viewer.

Step-level tracing: what it records, how it is structured, and why the span is the unit of analysis

A span is a recorded step with its inputs, outputs, latency, cost, and version attached. It is the minimum useful unit of diagnosis. A complete trace connects every tool call and its arguments, sub-agent handoff, LLM call, retry, and token expenditure. This lets an operator find the first wrong step as well as inspect the final wrong answer.

Configuration belongs in that record because behavior depends on it. Planners, routers, tools, and sub-agents can each have their own prompts, while model parameters can alter execution. Recording prompt versions and model configurations connects a behavioral change to the configuration that produced it. Step-level latency exposes bottlenecks that successful HTTP responses conceal, while completion rates and hallucination detection address outcomes that API success codes cannot describe.

Offline tests catch regressions before release, while production traces show the conditions an agent faces once it is deployed. Risky or failed traces can then become saved evaluation cases. This trace-to-dataset loop gives future releases a regression test for the failure that required manual investigation.

OpenTelemetry GenAI conventions as the emerging shared language for agent telemetry

OpenTelemetry GenAI semantic conventions provide a shared vocabulary that separates instrumentation from a single vendor. They cover six layers, including client model-call spans, agent and workflow spans, MCP conventions, semantic events, metrics, and provider-specific attributes. Two recommended histograms are gen_ai.client.operation.duration, measured in seconds, and gen_ai.client.token.usage, measured in tokens with input and output breakdowns.

The tool layer is becoming more explicit. MCP tracing, added in OTel v1.39, enriches existing execute_tool spans. However, as of v1.41, all gen_ai.* attributes have Development stability badges, so names can change without a major version bump. Teams adopting the conventions must plan for iteration.

OTel-native instrumentation makes telemetry portable when a vendor changes pricing or is acquired. A proprietary SDK can tie instrumentation more closely to its platform. The choice therefore affects the cost of changing platforms.

What to actually alert on: cost, tool-call patterns, and quality drift

Agent alerts should look for semantic failure signals. When cost per run rises above the P99 of its historical distribution, it can be a sign of runaway loops, prompt injection, or context blowouts. A hard daily spend cap per workflow provides containment because one runaway loop can consume a month’s budget overnight. Tool-call counts above P99 point to another symptom, an agent repeating actions because it is looping or confused about its goal.

Quality requires a separate alerting path. Falling rolling evaluation scores can show that quality is getting worse even when cost and latency are in their usual ranges. Input/output drift detection exposes changes in the conditions under which the agent operates, including inputs that differ meaningfully from those received a week earlier. Prompt injection patterns and timeout spikes extend this coverage to manipulation and degradation under load. These signals show which runs need a closer look, but more work is needed to find the root cause.

The incident response loop that turns a trace into a fix

A production agent needs a documented response loop before an incident occurs. When a quality, cost, or tool-pattern threshold trips, the on-call engineer is paged. Triage then samples failed or anomalous traces from the alerting window to distinguish model regression, data problems, tool failures, prompt changes, and upstream service changes. A dashboard cannot make those distinctions without the underlying execution record.

Containment must already exist in the architecture. A feature flag should switch the workflow within seconds to a simpler agent, a hard-coded response, or human escalation. Root-cause analysis then uses the recorded reasoning and execution path to establish the agent’s apparent intent and the point where its process diverged. The fix is tested against the incident workload and a broader sample before full traffic resumes. Finally, the traces that required manual triage become regression cases for future deployments.

Legal workflows place the greatest emphasis on hallucination detection. An answer can be fluent and structurally complete while its citations fail to support its claims. Faithfulness and citation-grounding evaluations therefore need to run on every output. The failure cost makes statistical coverage alone inadequate.

Healthcare places process mapping before automation. PromptCare, a healthcare provider, automated patient onboarding after CIO Phil Merrell’s approach of mapping end-to-end workflows in detail. That mapping establishes what subsequent instrumentation must observe. Agents that handle eligibility, claims, and referrals also need audit logs that last so both operators and regulators can review what happened. A fast workflow is insufficient if its decisions cannot be reconstructed.

Siemens, in collaboration with Nvidia, deployed multi-agent systems at its Erlangen Electronics Factory for autonomous production scheduling optimization. The boundary for write actions on production PLCs is clear: they pass through a standard engineering review gate. Observability must record that boundary rather than treat engineering assistance as unrestricted real-time autonomy on the factory floor.

The six observability platforms production teams are using in 2026

Platform fit depends primarily on hosting constraints and evaluation depth. Tracing tools show what happened, evaluation tools score how well it went, and gateways route and monitor traffic. Hybrid platforms work with both classical ML and GenAI, while broad platforms link agents to the infrastructure monitoring already in place.

Langfuse suits teams that need to self-host for data residency. It is open source under the MIT license and combines hierarchical tracing, versioned prompt management, LLM-as-judge evaluations, experiments, a playground, and a native MCP server. Experiments can replay real inputs against a changed model or prompt. This gives tracing and release evaluation a shared workflow.

LangSmith is a close fit for LangGraph teams. Its native integration and LangSmith Studio’s interactive debugging support work within that ecosystem, although the platform also works with other frameworks. Braintrust instead fits CI-driven teams that run structured evaluation experiments on production data.

Confident AI emphasizes the connection between tracing and quality. It records tool calls, sub-agent handoffs, retrievals, LLM calls, and retries, with both agent-step and trace-level evaluation scores. Trace-to-dataset workflows turn those records into future CI and regression tests. Arize Phoenix / Arize AI provides another fit for teams with self-hosting requirements.

Splunk Agent Observability suits organizations that need agent behavior next to APM and infrastructure telemetry in Splunk Observability Cloud. It correlates tool calls, model calls, and retrieval steps with the infrastructure executing them. Splunk Luna has small language model evaluators built to give verdicts faster than a frontier judge with comparable accuracy. That reduces the evaluation cost pressure that can otherwise force production sampling.

The evaluation and enforcement layers are substantial. Nine agentic evaluators include Action Completion, Tool Selection Quality, and Reasoning Coherence, with additional RAG, safety, text-to-SQL, and custom evaluators. Runtime guardrails address PII leakage, prompt injection, and tool misuse before tool execution. Native and OTel/OpenInference support covers frameworks including LangChain, LangGraph, CrewAI, and OpenAI Agents SDK. Luna evaluators need the Enterprise tier, while custom code-based evaluators need an on-premises deployment.

Those features fit teams that need runtime enforcement as well as passive logging. Most tools limit monitoring to the agent itself. A stale table or broken pipeline can thus leave an agent trace that looks healthy even though the result is wrong.

Why the gap between piloting agents and running them in production is an observability problem, not a model problem

The pilot-to-production gap is better understood as a readiness problem than simply a model-capability problem. A large majority of enterprise agent pilots do not reach production, and only a fraction of those deployed successfully scale. When teams have no agreed evaluation criteria, gut feel or executive pressure drives the choice to deploy. Neither establishes whether semantic failures can be detected and contained.

Observability supplies the missing operational definition of readiness. It makes quality measurable, decisions reconstructable, costs attributable, and incidents actionable. Organizations still piloting AI also report much less confidence in passing an independent governance audit than organizations with fully integrated AI. That confidence gap is consistent with pilots demonstrating an agent while production deployments provide evidence of how it behaves. Deployment depends on whether the enterprise can operate the agent safely.

What an AI Operations Audit covers and when enterprises need one before deploying an agent

An AI Operations Audit assesses six operational domains before instrumentation and deployment. The business case establishes a valuable, bounded problem with clear success criteria. Data assessment tests whether inputs are usable, lawful, and reliable. Gartner reports that 60% of AI projects are abandoned for lack of AI-ready data through 2026. This is a readiness issue that agent traces alone cannot resolve.

Security assessment addresses access, secrets, and sensitive data. Governance assigns ownership of decisions, exceptions, and risk. Operations tests whether the system can be monitored, supported, and stopped, while measurement establishes whether value and failure can be assessed continuously. Each domain defines part of the evidence needed for a deployment decision.

Enterprises need this assessment before deploying an agent when those conditions remain undefined. Otherwise, teams may instrument what an agent does without first defining how it should work or who responds when it fails.

Sources

  1. The 2026 Guide To Agent Observability Tools

More in AI Production Readiness