Track metrics that point at a cause, and cut each one per tool or per execution path (the tools and model calls in one run, in order). The set is the Exception rate and the Misstep rate per tool, the share of runs on each execution path, the loop rate, whether the task was resolved, your own evals, cost and latency per run, and what users did after the run. Then compare each one before and after every model upgrade or commit, because a total across all runs can stay flat while one tool breaks. Kubit computes most of them from Polaris, its in-house small language model, which labels and scores every span of your agent traces.

Key facts

  • A Misstep leaves no error on the span. OpenTelemetry's GenAI conventions, still in development, record error.type on a tool call only if the operation ended in an error (OpenTelemetry). A call that returned OK with the wrong argument looks like any other success

  • Token counts are already on the span. The same conventions recommend gen_ai.usage.input_tokens and gen_ai.usage.output_tokens on each model call, which is what cost per run is built from (OpenTelemetry)

  • Sampling is the documented default for LLM judges. Databricks' MLflow docs recommend a sample rate of 0.05 to 0.2 for expensive judges (Databricks docs), and Langfuse puts a typical LLM-as-a-judge evaluation at $0.01 to $0.10 per assessment (Langfuse docs).

  • Polaris labels and scores every span in under 100ms, with no additional LLM cost or sampling. Polaris is up to 98% lower cost and ~15x faster than a frontier LLM judge, with comparable accuracy on public agent benchmarks (Polaris)

Which agent metrics should you track, and how do you compute them?

Ten agent metrics to track in production, grouped by what they answer

The table groups ten metrics by what they answer, and each one is worth cutting per tool or per path before you read it.

Metric

What it tells you

How to compute it

What it points at

Exception rate per tool

How often calls to a tool fail outright

Calls to the tool with an error status or error.type, divided by all calls to that tool

A broken dependency behind that tool, such as a timeout or a changed API

Misstep rate per tool

How often a call returned OK and still did the wrong thing

Calls to the tool with a Misstep label, such as wrong_tool or malformed_args, divided by all calls to it

The prompt or tool description that steers the agent into that call

Runs per execution path

Which paths your traffic takes, and how many runs take each one

Group traces by their ordered list of steps and count each group

A new path after a change, or a path that ends in an Exception or a Misstep

Loop rate

How often a run repeats the same tool

Runs with a Warning label such as loop_detected, or with one tool called back to back past a limit you set, divided by all runs

A tool result the agent can't use, so it asks again

Task resolved rate

Whether the agent finished what the user asked

Conversations scored yes on Task resolved, divided by all conversations scored

The paths and tools that end in unfinished conversations

Your own eval rates

Whether runs follow the rules only your product has

Runs scored yes on your eval (or each score, for a choice or a score), divided by runs scored

The exact rule that broke, such as a refund the plan doesn't allow

Cost per run

What one run spends on model calls

Input and output tokens summed across the trace's model calls, times your model's price

Paths that call the model more often than the task needs

Latency per run

How long the user waited

Trace end time minus start time, read as a median and a high percentile per path

A slow tool or a loop on one path

Re-prompt rate

Whether the user had to ask again

Sessions where the user repeated the request, such as a repeated_prompts Behavior label, divided by sessions

Replies the user didn't accept, even on runs scored as resolved

Outcome after the run

What the user did in your product next

Runs followed by a product event, such as a support ticket or a cancellation, within a window you pick, divided by runs

Agent behavior that ends with a ticket or a lost customer

How do you track agent failures per tool?

Start with two rates per tool, because they catch different failures. The Exception rate counts calls that failed, such as a timeout or a 500 response. Those show in your error logs, and most tracing tools chart them already.

The Misstep rate counts calls that ran, often with an OK status, and did the wrong thing, such as calling the wrong tool or passing a malformed argument. Nothing in the span records a Misstep, so something has to read the call and label it. Polaris gives every span one of five annotation types, and Misstep is one of them, with labels such as wrong_tool and malformed_args (Concepts). The longer comparison is in Misstep vs Exception.

Read both per tool. Say your agent calls 20 tools and a prompt change makes book_appointment pass the wrong date. If book_appointment is a small share of all calls, the Misstep rate across every tool moves by a fraction of a point, while the rate on that one tool goes from 2% to 9%.

In Kubit, the Labels column in Activity shows each trace's labels, and on a Sandbox or warehouse workspace you can filter by Misstep Label to pull every trace with, say, wrong_tool (Find Missteps that return OK).

How do you track execution paths and loops?

A per-tool rate names the tool, and the execution path shows where in the run the call came and what ran before it. An execution path is the ordered list of steps in one run. Two runs that called search_orders, then get_refund_policy, then the model share one path even if their inputs differ (Concepts).

Count runs per path and track the share each path gets over time. A change that makes the agent skip a tool shows up as one path losing runs and another gaining them, even when every call on both paths returns OK.

Loops are a path problem too. Flows keeps repeated consecutive calls as separate steps, so a run that calls search_orders three times in a row shows three search_orders steps, and Polaris marks loops with a Warning label such as loop_detected (Flows). A loop on one path adds latency and tokens to every run that takes it, so track the loop rate per path as well.

In Kubit, Flows draws every execution path in one Sankey with the number of traces that took it, so a failure that repeats a thousand times shows up as one path with a count of 1,000. See Why we group agent runs by execution path.

How do you know whether the agent finished the task?

A run can have no Exception and no Misstep and still leave the user's request unfinished, so you need outcome metrics on top of the failure rates. Task resolved is one of four built-in evals Polaris runs on every conversation, and it asks whether, by the end of the conversation, the assistant had completed the task the user asked for (Polaris). Track it as a rate per path, so a path that resolves far fewer conversations than the others points you at its steps.

Built-in evals check what most agents share, and your own evals add the rules only your product has, such as whether the agent promised a refund the plan doesn't allow, or whether the user asked for a person. You write the eval in your own words on the Polaris page and choose what it looks at, from the whole conversation down to each tool call (Add your own evals). Evals run on Polaris and are included in Agent Analytics at no extra cost, so each eval rate covers every run instead of a sample. When an eval keeps getting your cases wrong, see Fine-tuning vs threshold tuning for agent evals.

How do you track cost and latency per run?

Track cost and latency per run and per path, because a per-call average mixes cheap tool calls with expensive model calls and hides how many calls a run made. Cost per run is the input and output tokens summed across a trace's model calls, times your price per token. The OpenTelemetry GenAI conventions put those counts on each model call as gen_ai.usage.input_tokens and gen_ai.usage.output_tokens, so you can compute it from the spans you already send (OpenTelemetry). Latency per run is the time from the start of the trace to its end.

Read both as a median and a high percentile per path. Say one path in ten starts looping after a commit. Every run on that path gets slower and more expensive, and the average across all runs barely moves.

In Kubit, Activity lists latency and tokens on each trace, and Polaris labels a span with a Warning for high cost or high latency (Concepts). A path where Warnings collect on one step tells you which step to fix first.

How do you track what users did after a run?

The last group answers whether the run helped the user. Inside the conversation, look at whether the user had to ask again. Polaris's Behavior labels cover what the user and the agent said and meant, with labels such as repeated_prompts (Concepts). A rising re-prompt rate on runs that Task resolved scored as finished means the user didn't think so.

Outside the conversation, look at what the user did next in your product, such as opening a support ticket or cancelling. Kubit runs Product Analytics reports such as funnels and retention on agent traces and clickstream events, separately or joined (FAQ). That lets you ask which execution path leads to a completed task and which one leads to a ticket.

How do you compare metrics before and after a model upgrade or commit?

The same refund runs in the week before and the week after a model upgrade

Compare the same metric, cut the same way, in a window before the change and a window after it. Four habits keep the comparison honest:

  • Pick windows with the same traffic mix. A full week against the following week is safer than a Monday against a Friday, because the mix of requests changes which paths runs take

  • Compare per tool and per path. A model upgrade that makes the agent skip get_refund_policy shows up as runs moving between two paths, while the overall Task resolved rate may hold

  • Look at new paths first. A path that had no runs before the change and hundreds after it is the first place to open a trace

  • Turn the eval on before you ship. On an Agent workspace a new eval scores new conversations from then on and doesn't score earlier ones, so an eval added after the change has no before window. On a warehouse workspace you can label a past window of days from the Polaris page (Add your own evals)

Say you switch models on a Tuesday. The Exception rate holds and Task resolved drops by one point. Cut per path, the share of refund runs that call get_refund_policy before replying falls from 60% to 35%, and the Misstep rate on issue_refund rises on the path that skips it.

In Kubit, Triggers compares a metric before and after a model upgrade or commit, or between user segments, and shows when it changes, such as the Misstep rate on book_appointment after a model upgrade (Triggers). When a metric moves, the /kubit-blame skill in Claude Code or Cursor maps the names and prompts in those traces to files in your repo and returns the top 5 suspect commits in the window (Find what changed before a pattern started).

What do totals across all runs hide?

A total averages over every tool and every path, so a change that hits one of them gets diluted by the rest. Four things go missing:

  • One broken tool among many. A tool that's a small share of calls can fail on most of its runs and barely move the overall rate

  • Runs moving between paths. If runs shift from a path that works to one that doesn't, and both carry similar volume, the total can look stable for days

  • Missteps counted as successes. A success rate built on status codes counts every Misstep as a success, because the call returned OK

  • A loop on one path. Average latency moves little when one path starts looping, even though every run on it is slower

Keep the totals on the dashboard as a check, and read the per-tool and per-path cuts first. The checklist form of this answer, with what to ask any tool before you pick it, is in How to choose an agent analytics tool.

How do you start?

  1. Get a week of your agent traces into Kubit, over OpenTelemetry or from the trace table in your warehouse

  2. Open Activity and check that the Labels column shows labels instead of Not analysed yet

  3. Open Flows and note your top execution paths and how many runs take each one

  4. Add the evals that carry your product's rules on the Polaris page, before your next model upgrade or commit

  5. After the change, compare the Misstep rate and Task resolved per tool and per path against the week before

Book a demo to see these metrics on your own agent runs.

Read next: How to choose an agent analytics tool · Misstep vs Exception · Fine-tuning vs threshold tuning for agent evals · Should you score every agent run or a sample?

FAQ

What AI agent metrics should I track in production?

Track the Exception rate and the Misstep rate per tool, runs per execution path, the loop rate, whether the task was resolved, your own evals, cost and latency per run, and what users did after the run. Cut each one per tool or per path, and compare it before and after every model upgrade or commit, because a total across all runs can stay flat while one tool breaks.

What's the difference between the Exception rate and the Misstep rate?

The Exception rate counts calls that failed, such as a timeout or a 500 response, and it shows in your error logs. The Misstep rate counts calls that ran, often with an OK status, and did the wrong thing, such as calling the wrong tool. Nothing in the span records a Misstep, so it needs a label from a model such as Polaris.

How do I compare agent metrics before and after a model upgrade?

Pick a window before the change and one after it with the same traffic mix, then compare each metric per tool and per execution path. Look first at paths that had no runs before the change. Turn on any new eval before you ship, so it has scores from the before window. In Kubit, Triggers compares a metric before and after a model upgrade or commit and shows when it changes.

How do I calculate the cost of an AI agent run?

Sum the input and output tokens across the model calls in one trace and multiply by your model's price per token. OpenTelemetry's GenAI conventions put the counts on each model call as gen_ai.usage.input_tokens and gen_ai.usage.output_tokens. Read cost per run as a median and a high percentile per execution path, so a loop on one path doesn't hide in the average.

Why don't totals across all agent runs show what broke?

A total averages over every tool and path, so a change that breaks one tool or moves runs onto a worse execution path gets diluted by the rest. A success rate built on status codes also counts every Misstep as a success. Cut each metric per tool and per execution path, and read the totals last.

Table of contents

Running agents in production?

The first cohort is closed. Join the waitlist for the next one. Your traces stay in your warehouse.

Summarize this post

Share