Skip to main content

Design Philosophy

Every experiment tests a hypothesis about what makes agents better. The experiment driver makes the independent variables explicit:

Variant Ladders

The most informative experiments use a progressive variant ladder β€” each variant adds one thing to the previous: Each step isolates one variable. If variant 4 outperforms variant 3 with identical knowledge content, the structure is what matters β€” not just the knowledge.

Improvement Flywheel

Variant ladders can be pre-planned, but the most effective experiments use empirically motivated variants β€” each exists because the previous variant’s analysis revealed a specific gap. This follows the Improvement Flywheel methodology:

Iteration metadata

Each variant records what motivated it using IterationMetadata:
In the agent-experiment-template, this is configured in experiment-config.yaml:
This creates an audit trail: for every variant you can trace back to the observation that motivated it and verify whether the hypothesis held.

Intervention levers

The type of loss determines which lever to pull:

Comparison reporting

GrowthStoryReporter (in the template) generates a markdown comparison report across variants. It:
  • Shows per-judge score deltas, improvements, and regressions for each variant pair
  • Flags regressions with explicit warnings when any ScoreComparison.regressions() > 0
  • Includes iteration motivation (finding + hypothesis) before each variant’s scores when IterationMetadata is present
The report is written to analysis/comparison-report.md and provides the MEASURE output that feeds the next DIAGNOSE step.

Dataset Design

Item structure

Each item needs:
  • developerTask β€” what you’re asking the agent to do (natural language)
  • before/ β€” the starting state (real source code)
  • reference/ β€” the correct result (for judge comparison)
  • bucket β€” difficulty classification (A = easy, B = medium, C = hard)
  • knowledgeRefs β€” paths to relevant KB entries (relative to knowledgeBaseDir)

Buckets

Use buckets to stratify difficulty:

Filtering

Run subsets of the dataset:

ExperimentConfig Reference

Result Structure

Results are persisted by FileSystemResultStore:
Each result contains:
  • Experiment metadata (name, config, git version, timestamps)
  • Per-item results (agent output, jury verdict, tokens, cost, duration)
  • Aggregate statistics (pass rate, total cost, total duration)

Cross-Run Comparison

The comparison engine aligns items by ID across two experiments and reports per-item and aggregate deltas.

Building a Jury

Three-tier evaluation: deterministic, structural, semantic

API Reference

Full config, dataset format, invoker contract