agentleFS
Google CloudKnown publisherGoogleCloudPlatform/devrel-demos/ai-ml/dev-signal/.agent/skills/gcp-agent-tool-trajectory-evaluator/SKILL.md

gcp-agent-tool-trajectory-evaluator

Skill397 starsChanged 13 days agoApache-2.0View on GitHub

Provides custom Python metrics for configuring Vertex AI Gen AI Evaluation to measure Trajectory Precision, Recall, and Order Match.

The file

Files
SKILL.md

gcp-agent-tool-trajectory-evaluator

This skill provides the specialized Python logic needed to evaluate how an agent uses its tools. Grounded in evaluation_blog.md, it moves beyond "Did the tool run?" to "Were the tools used correctly and efficiently?"

Usage

Ask Antigravity to:

  • "Implement Trajectory Precision and Recall metrics"
  • "Set up an Order Match metric for my multi-step agent"
  • "Add a custom trajectory scorer to my Vertex AI evaluation"

Metric Definitions

  1. Trajectory Precision: Measures what percentage of called tools were actually specified in the reference.
  2. Trajectory Recall: Measures what percentage of required tools were successfully called by the agent.
  3. In-Order Match: Checks if the required tools were called in the correct sequence (even if other non-essential tools were called in between).

implementation Pattern

Refer to scripts/trajectory_metrics.py. These functions are designed to be serialized and passed to Vertex AI via CustomCodeExecutionSpec.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.