Skip to main content
Glama

get_experiment_results

Read an experiment's results to compare candidate vs baseline metrics, inspect test cases, pipeline metrics, and session errors; locate regressions.

Instructions

Reads an Experiment's results: each Metric, candidate against baseline, then each test case.

Find an Experiment with list_experiments. metrics has one entry per Metric of the Metric Group, in its order: each side's value (or labels for a Label), delta and delta_pct of the candidate over the baseline, and how many Sessions errored, meaning the Evaluator's own code broke. A test case's value is the mean over its Sessions, and a Metric is averaged only over the paired_test_cases both sides have a value for, so check that count before trusting a delta. pipeline_metrics compares DURATION, TOKENS and COST the same way. Each test case lists the Sessions each side scored and, per Score Metric keyed {evaluator_id}:{metric_key}, each side's mean; that is where to look for the test cases behind a regression. Resolve evaluator ids to names with list_evaluators. Results are partial while status is REPLAYING or SCORING. :param experiment_id: The Experiment's id. :param max_test_cases: Most test cases to return; metrics still cover every test case. :returns: The results, or an error message.

The output is automatically stored and can be referenced in other functions. Returns a formatted preview with an object ID (e.g., @obj_123). Use the object store tools in combination with the object ID to view nested properties of the object. Use the returned object ID to pass this result to other functions.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
experiment_idYes
max_test_casesNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.33

TDQS

A4.3/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does so richly: it discloses that results are partial while status is REPLAYING or SCORING, that 'errored' means the Evaluator's own code broke, that Metrics are averaged only over paired_test_cases with values on both sides, and that pipeline_metrics compares duration/tokens/cost. These are exactly the semantic gotchas an agent could not infer from the bare schema.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core purpose, then structured into metrics/pipeline_metrics/test-case detail; nearly every sentence carries information. Minor deduction for the generic object-store boilerplate tail that is auto-injected and adds little selection value.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema and no annotations, the description thoroughly describes the return shape (per-side value/labels, delta, delta_pct, errored counts, per-Metric means, session listings) so an agent knows what it gets. Nothing material for correct invocation appears to be missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description must compensate, and it largely does: max_test_cases is explained precisely ('Most test cases to return; metrics still cover every test case'), which is a non-obvious interaction. experiment_id is only described as 'The Experiment's id,' which is thin but sufficient given the required string.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Reads an Experiment's results') and immediately enumerates the scope it covers: each Metric, candidate vs baseline, and each test case. It is clear and concrete, though it never explicitly distinguishes itself from the nearby sibling get_experiment_run, leaving that routing decision to the agent.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives actionable context: find the Experiment via list_experiments, resolve evaluator ids via list_evaluators, and check paired_test_cases counts before trusting a delta. It even points the agent at where to look for regressions. It stops short of explicit when-not-to-use or exclusion conditions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools