Agent Evals

Suite, trace and report formats

All three formats are JSON, carry a schema field with a version, and are validated at runtime. Unsupported versions are rejected with a message naming the file.

Updated 2026-11-22. Examples use the synthetic editorial fixture in examples/agent-evals/editorial.

Suite: promptflow.agent-suite/v1

suite.json
{
  "schema": "promptflow.agent-suite/v1",
  "id": "editorial-agent",
  "defaults": { "assertions": [
    { "id": "allowed-tools", "type": "allowed_tools",
      "tools": ["fetch_sources", "draft_article", "publish_article"] },
    { "id": "approval-before-publish", "type": "approval_before",
      "tool": "publish_article", "targetArgument": "articleId" },
    { "id": "budget", "type": "limits", "severity": "advisory", "maxToolCalls": 6 }
  ] },
  "cases": [
    { "id": "standard-article", "input": { "articleId": "article-1042" }, "assertions": [] }
  ]
}
  • id values are stable identifiers: letters, digits, . _ : -, at most 128 characters. Case ids are unique in a suite; assertion ids are unique in a case, including the defaults.
  • defaults.assertions apply to every case.
  • input is passed to the runner and never shown in reports.
  • Optional pricing (inputPerMTokUsd, outputPerMTokUsd) enables a cost estimate. Without it, and without both token counts, no cost is shown.
  • output_schema supports type, properties, required, items, enum and min/max limits.

Trace: promptflow.agent-trace/v1

trace.json
{
  "schema": "promptflow.agent-trace/v1",
  "runId": "run-7f2", "caseId": "standard-article", "suiteId": "editorial-agent",
  "versions": { "agent": "2.0.0", "prompt": "editorial-prompt-7", "model": "…", "config": "…" },
  "complete": true,
  "events": [
    { "seq": 1, "type": "tool_call", "tool": "draft_article", "callId": "call-1",
      "arguments": { "articleId": "article-1042" } },
    { "seq": 2, "type": "tool_result", "callId": "call-1", "status": "ok" },
    { "seq": 3, "type": "approval", "action": "publish_article",
      "target": "article-1042", "decision": "granted", "source": "application" }
  ],
  "outcome": { "status": "published" },
  "output": { "title": "…", "references": [] },
  "metrics": { "durationMs": 1250, "inputTokens": 542, "outputTokens": 116 }
}
Event typeFields
tool_calltool, callId (unique), arguments
tool_resultcallId, status: ok, error or denied
approvalaction, target, decision, source
messagerole, text
stepname, status
errormessage
  • Every event may carry seq, id, at, parentId and stepId.
  • Order follows seq. Give every event a unique integer seq, or none. Mixed or repeated values are rejected as ambiguous.
  • Set complete: false for a run that was cut short. Checks that need the missing part then fail.
  • metrics are optional. Missing values are reported as unavailable.

Report: promptflow.agent-report/v1

A report records the mode, the suite id and definition hash, a summary, and for each case its status, versions, metrics, assertion results (status, expected, observed, reason, trace steps) and a redacted timeline. It also lists input file names with SHA-256 hashes and the command that reproduces it.

Limits

InputLimit
Suite file1 MB, 500 cases, 50 assertions per case
Trace file5 MB, 10,000 events
Report file10 MB
Nesting32 levels

Designed for later production use

The trace format already carries parent and step ids, versions, timing and token usage, so a sanitized production trace can be replayed against a suite today. Converters from OpenTelemetry GenAI spans and OpenInference, turning a failed run into a regression case, and hosted retention with access control and alerts are follow-up work. Hosted features will be built when pilot teams show they need them.

More on Agent Evals