Workflow traces: record per-agent `model` and `effort` (override + resolved) in the per-agent progress records

Status Open
Maintainer reply None cached
Activity 0 comments · opened Sep 9, 2026

Feature request

The Workflow tool's agent(prompt, opts) accepts per-call model and effort overrides, but the persisted run trace's per-agent records (workflowProgress[] / the run's wf_<runId>.json) do not record either — neither the override passed nor the resolved value the agent actually ran with.

Measured motivation (one team's adjudication harness, 2026-09-02 → 09-07 window): 91 orchestration scripts pinned effort: 'high' per agent and 718 agent runs executed; 0 of 718 trace records carry the effort or model the agent ran with. The only model attribution available is (a) session-level metadata, which breaks on per-agent overrides and on model_refusal_fallback substitutions, and (b) label-string conventions baked into prompts — we are currently running a paired verify-model A/B where the arm key is a verify:A: / verify:B: label prefix, which any label edit silently breaks.

Ask: per agent record, persist

  • model: the resolved model id the agent ran on (post-fallback, so a model_refusal_fallback substitution is visible per agent), and
  • effort: the resolved reasoning effort,
  • optionally a flag or the raw override value distinguishing "inherited from session" from "overridden by the script".

This makes per-agent cost/latency attribution and model A/Bs first-class trace reads instead of label archaeology.

View original on GitHub ↗