AI agent evaluation metrics show whether an agent gives reliable answers and completes its assigned work. For an analytics agent, the core check is whether a business question produces the expected result from governed metrics, under the asker's permissions. This guide focuses on agents that answer questions about business data; teams evaluating agents in other workflows will need task-specific measures too.
AI agent evaluation metrics for analytics agents
A single accuracy rate is a useful summary, but it cannot explain what failed. A query can return the wrong total, use the wrong time period, expose rows the asker should not see, or stop before completing the task. Those failures call for different fixes, so choose metrics that make them visible.
Answer accuracy against a trusted result
For a known-answer case, define the expected result before running the agent. A basic case accuracy rate is the number of passing cases divided by the number of cases run. Write down what a pass means: which metric, filters, dimensions, time range, and result values must match.
Exact equality is appropriate for some outputs. Numeric results may need a tolerance for rounding, while tabular results may need comparison that ignores row order or column aliases. Pick those rules before seeing the score. Otherwise a team can unintentionally tune the evaluator to make a regression look like a pass.
The expected answer also needs a stable meaning. If “revenue” changes between gross and net revenue, a passing case can still test the wrong business question. Keep the metric definition and the data snapshot or time window with the case, and review them when the model changes. The semantic-layer guide for AI agents explains why those definitions need to be governed before the agent queries them.
Accuracy by question type
Keep the overall rate, then break it down by the questions people actually ask: totals, time comparisons, filtered segments, multi-step analysis, and empty-result cases. A high overall number can be driven by many easy questions while a smaller but important category remains unreliable.
Use representative examples from internal analytics and customer-facing embedded workflows when both are part of the product. Include ambiguous wording, boundary dates, and questions that depend on a subtle join. Record failures by category so a change to the model, instructions, or agent can be compared against the same cases.
Permission correctness
Correctness includes who is allowed to see the result. Run cases under representative roles and tenant contexts, and include questions whose expected outcome is restricted or empty. Measure unauthorized disclosures separately from answer accuracy. A permission failure should not be diluted by dozens of correct answers elsewhere in the suite.
For analytics, the strongest check tests permissions where the query is built. The agentic analytics overview describes how a governed model carries the asker's context into the query. Evaluation cases can then verify allowed access and denied access as distinct outcomes.
Task completion and unsupported questions
Some agents do more than return a number. They may need to compare periods, explain a movement from queryable dimensions, or produce a saved report. Define the expected end state for each workflow and count completion only when the required result or artifact is present and correct. Tool calls by themselves do not prove that the user got what they asked for.
Also test questions the model cannot answer from the available data. A useful agent should say when a metric is missing or the request is outside its scope, rather than inventing a value. Track unsupported-question handling separately: a false answer on an unanswerable case is different from a reasonable abstention on an answerable one.
Latency and cost per successful task
Measure how long a completed task takes and what it costs to run. Report latency at the task level, including any query or agent steps the user waits for, and calculate cost per successful task rather than cost per prompt alone. Set budgets from the product's response expectations; a fast answer that is wrong does not count as a successful run.
Turn evaluation metrics into a release check
Start with real questions, then add cases for the failures the team cannot afford. Each case should include the asker's context, the expected result, the relevant metric definition, and any allowed tolerance. Keep some representative cases out of prompt tuning so the release suite still checks generalization instead of memorized examples.
Run the same suite against a known baseline and a proposed change. Compare overall accuracy and each important slice, then apply release gates to the failures with the highest impact. For example, a team might require no permission violations, no regression in a critical question category, and latency below a product-defined budget. Those gates should be explicit before a release candidate is evaluated.
Refresh cases when production questions reveal a new ambiguity or when a metric definition changes. Keep the original failure and its corrected case in the suite. Over time, the test set becomes a record of what the agent must get right, not a score chosen for a launch report.
How Cube Evals fits into analytics evaluation
The feature pairs each natural-language question with SQL or a certified query as ground truth. Teams run a selected agent against a question set on a branch and get a pass or fail for each question plus the run's accuracy rate. The Evals product page describes the release workflow; the launch article explains the result comparison.
The default exact grader compares result sets deterministically. It ignores row ordering and column aliases, tolerates numeric differences to four significant figures, and ignores extra columns. An optional AI grader can recheck deterministic failures when the question leaves some details open; it judges result data, not the agent's prose. Teams can read the Evals documentation for case authoring and running a suite.
An eval run also reports median response time and total tokens when those values are available. Use them to relate answer quality to speed and model usage, then apply your provider's pricing if you need a cost estimate. The feature focuses on question-level results, so measure full task completion, access-control failures, and other production outcomes alongside it.
An evaluation score is useful when it points to an actionable failure. Keep the measure tied to a verified business question, preserve the asker's permissions in the case, and review the failures before merging a change. That gives teams a repeatable way to decide whether an analytics agent is ready for the work people will ask it to do.
Frequently asked questions
- What metrics should I use to evaluate an AI agent?
- For an analytics agent, measure answer accuracy against verified results, accuracy by question type, permission correctness, task completion, abstention on unsupported questions, latency, and cost per successful task. Keep each measure visible so a good average cannot hide a serious failure.
- How do you calculate AI agent answer accuracy?
- Divide the number of passing evaluation cases by the number of cases run, after defining what counts as a pass. For analytics, compare the returned result with a trusted answer and set an explicit numeric tolerance where exact equality is not appropriate.
- Is answer accuracy enough to evaluate an analytics agent?
- No single accuracy rate covers every production risk. Track permission failures separately, then measure task completion, unsupported-question handling, latency, and cost so each release decision reflects the system's actual job.
- How can I test whether an AI agent follows data permissions?
- Run cases under representative user, role, and tenant contexts, including questions that should return restricted or empty results. Record any unauthorized data exposure as a separate failure with its own release gate.
- What is the difference between AI agent evaluation metrics and LLM metrics?
- LLM metrics often measure generated text, while agent metrics can cover the full task: tool choices, data access, final results, and whether the requested work was completed. Analytics teams should anchor the final-answer check to a verified business result and the permissions of the person asking.
- How do I measure AI agent task completion?
- Write down the expected end state for each task, such as returning a requested metric breakdown or saving a reviewed analytics artifact. Count a case as complete only when the result meets that specification, rather than when the agent merely makes a tool call.
- How does Cube Evals measure agent accuracy?
- Cube Evals pairs a natural-language question with SQL or a certified query as ground truth and reports a pass rate with per-question results. The default exact grader compares result sets deterministically; an optional AI grader can recheck deterministic failures when a question leaves details open.