Skip to content

[REFACTOR]: Add shared linear trace runner - #148

Draft
Spencer Schoenberg (spencrr) wants to merge 2 commits into
microsoft:mainfrom
spencrr:dev/spencrr/trace-runner
Draft

[REFACTOR]: Add shared linear trace runner#148
Spencer Schoenberg (spencrr) wants to merge 2 commits into
microsoft:mainfrom
spencrr:dev/spencrr/trace-runner

Conversation

@spencrr

@spencrr Spencer Schoenberg (spencrr) commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Description

Adds the internal linear trace runner used by attack and probe strategies. It keeps separate raw and annotated turn histories, records TraceEndReason, supports optional online stop checks, and reuses an identical online evaluation when it already covers the terminal trace.

The runner does not own session lifetime, polarity, cleanup, or exception conversion. Those remain strategy and BaseExecution responsibilities. Driver history receives a shallow copy, evaluator contexts contain annotation-free turns, and reused mutable evaluator evidence is copied defensively.

Depends on #146. Because the branches live on a fork, this PR temporarily includes the lower-layer diff and targets main; that diff disappears when #146 merges.

Breaking changes

None. No existing strategy consumes the runner in this layer.

Checklist

  • pre-commit run --all-files passes
  • Tests cover termination reasons, raw/annotated history, stop behavior, exact-context reuse, mutation guards, exceptions, and turn budgets
  • Documentation not required for the internal collaborator in this layer

Validation after reslicing: the full suite passes with 1,178 tests and 5 skips; all pre-commit checks pass.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant