The SDK records real runs; the evalshift capture command group turns them into golden suite cases that run can score. The two never call each other — the SDK writes capture files, the CLI reads them.
Captures live under <base>/captures/<suite>/ and promoted cases under <base>/suites/<suite>/, where base follows the SDK convention ($EVALSHIFT_DIR, else .evalshift).
## capture list
See what the SDK has recorded: a table of capture id, suite, created-at, tool-call and event counts, and whether each was already promoted. --json emits the same rows plus code_version and input_hash for tooling.
# everything the SDK has recorded (optionally for one suite) evalshift capture list evalshift capture list support_agent # machine-readable (adds code_version + input_hash) evalshift capture list --json
## capture promote
Turn one capture into a golden case. By default the case id is the capture id (--as renames it), and the recorded tool calls become the expected trace. The command prints the suites: block to paste into evalshift.yaml and the exact run invocation.
evalshift capture promote cap_a1b2c3 --as refund_happy_path # it writes the golden case and prints exactly how to wire it: # suites: # support_agent: # source: captured # path: .evalshift/suites/support_agent/golden.jsonl # # then: evalshift run --suite-name support_agent
### Matching strictness
- +
--strict-args— require exact tool-argument matches (default is a looser compare). - +
--names-only— match tool names only; ignore arguments. - +
--tool-count— also pin the expected number of tool calls. - +
--input-var— template-variable name for a bare-string model input (defaultinput). - +
--tag— attach an extra tag (repeatable);--suiterestricts the capture search;--force/-foverwrites an existing case.
## capture clean
Prune capture files once you’re done with them. By default it removes only promoted captures (the case already lives in the suite); --all removes every capture for the scope. --yes / -y skips the confirm.
# prune only captures you've already promoted (the default) evalshift capture clean --promoted # wipe everything for a suite, promoted or not evalshift capture clean support_agent --all --yes
clean only ever deletes files under captures/. The golden cases it produced under suites/ are never touched.## capture diff
Compare two captures’ tool-call traces — which tools fired, with what args, in what order. Useful before promoting to confirm a capture is the run you mean to pin.
# compare two captures' tool-call traces evalshift capture diff cap_a1b2c3 cap_d4e5f6
## The end-to-end loop
Capture a real run with the SDK, promote it into a captured suite, then run migrations against it like any other suite — verdicts, baselines, and policy gating all apply. Your golden cases now come from production behavior instead of hand-authored JSONL.