google-agents-cli-eval

Runs and grades agent evaluations with datasets, metrics, and LLM-as-judge scoring.

Updated Dec 9, 2025
One-click install
npx skills add https://github.com/Aki2022/skills --skill google-agents-cli-eval-aki2022
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: google-agents-cli-eval
Source: https://github.com/Aki2022/skills/tree/main/google-agents-cli-eval
Command: npx skills add https://github.com/Aki2022/skills --skill google-agents-cli-eval-aki2022

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Building a reliable agent requires knowing whether it actually works, and ad-hoc manual testing cannot catch regressions, hallucinations, or broken tool usage at scale. This Skill provides a structured evaluation methodology — the Quality Flywheel — for running agents over datasets, grading traces with built-in or custom metrics, analyzing failures, and iterating on fixes. ## Core Features & Use Cases - Eval execution loop: Run agents-cli eval run (or decoupled eval generate + eval grade) to execute an agent over a JSON EvaluationDataset and produce timestamped JSON/HTML score reports. - Metrics selection and custom metrics: Choose from built-in metrics like multi_turn_task_success, final_response_quality, hallucination, and safety, or define custom LLM-as-judge (prompt_template) and Python (custom_function) metrics in eval_config.yaml. - Failure analysis and optimization: Use eval compare to verify fixes without regressions, eval analyze for LLM-based failure clustering, and eval optimize for GEPA prompt tuning. - Use Case: After scaffolding an ADK agent, run agents-cli eval run against tests/eval/datasets/basic-dataset.json, inspect the failing multi_turn_tool_use_quality scores in the HTML report, fix the tool descriptions, and confirm improvement with eval compare. ## Quick Start Ask the assistant to run an evaluation of your agent with agents-cli eval run and show the scores table for every case.

Frequently Asked Questions about google-agents-cli-eval

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I evaluate my ADK agent with agents-cli?

Run `agents-cli eval run` from the project root; it executes the agent over the dataset in tests/eval/datasets/ and grades traces using metrics from tests/eval/eval_config.yaml. Results are written as timestamped JSON and HTML files in artifacts/grade_results/.

How do I write a custom LLM-as-judge metric for agent evaluation?

Add an entry under custom_metrics in eval_config.yaml with a name and a prompt_template referencing {prompt}, {response}, and {agent_data}, then list the metric name in metrics_to_run. The judge returns a JSON score and explanation.

Which eval metrics support multi-turn agent traces?

Only multi_turn_task_success, multi_turn_trajectory_quality, and multi_turn_tool_use_quality accept multi-turn traces. Every other built-in metric returns a 400 error when given a trace with two or more turns.

Why does multi_turn_tool_use_quality fail for agents using google_search?

google_search is a model-internal grounding feature that never appears as a function_call in the trace, so the evaluator flags an unexpected tool call it cannot see. Use final_response_quality instead for agents whose only tool is google_search.

Can I run agent evaluations without a GCP project or region?

Yes. Custom metrics with a custom_function default to local in-process execution, requiring no GCP project or region. Managed built-in metrics and remote execution require a configured GCP project and an eval-supported region.

Why do my agent eval scores fluctuate between runs?

Score fluctuation comes from non-deterministic model behavior. Set temperature=0 on the agent, use rubric-based metrics, or increase judge_model_sampling_count to stabilize scores across runs.