Skip to content

feat(bench): snapshot final tree of resolved tasks for DRA replay - #345

Merged
dahai80 merged 1 commit into
mainfrom
bench-dra-snapshots
Nov 26, 2026
Merged

dahai80 merged 1 commit into
mainfrom
bench-dra-snapshots

Conversation

@dahai80

@dahai80 dahai80 commented Nov 26, 2026

Copy link
Copy Markdown
Owner

Phase A of the DRA-lite over-edit experiment (method: Delta Residue Attribution, arXiv 2611.34875; design doc: code-research/docs/dra-lite-experiment-design.md, outside this repo).

Behind BENCH_DRA=1: on a resolved task, tar the workdir into the results dir before the rmSync cleanup. Phase B (separate PR) replays the transcript's Edit/Write units against the snapshot, reverts each cumulatively, and reruns the task verify to grade needed vs unneeded units.

Best-effort by design: snapshot failure logs a warning and never fails the run. tsc clean.

🤖 Generated with Claude Code

Behind BENCH_DRA=1: when a task resolves, tar the workdir into the
results dir before cleanup so the over-edit replay (Phase B, dra.ts,
design in code-research/docs/dra-lite-experiment-design.md) can
attribute each edit unit as needed/unneeded by reverting it and
rerunning the verify command. Best-effort: snapshot failure never
fails the run.

Co-Authored-By: Claude Code <[email protected]>
@dahai80
dahai80 merged commit a007ade into main Nov 26, 2026
1 check passed
@dahai80
dahai80 deleted the bench-dra-snapshots branch November 26, 2026 08:17
dahai80 added a commit that referenced this pull request Nov 26, 2026
The #345 snapshot block referenced configDir/outDir/taskId from the
main-loop finally, but those live inside runHarness — the first
BENCH_DRA=1 run crashed with ReferenceError after T01 (configDir is not
defined). Snapshot now runs at the end of runHarness, deriving the task
id from logPath and using cwd (the task workdir) directly; it captures
every task, and the replay filters by resolved status.

Found by the 2026-11-26T08-42-00Z run: T01 completed (525.7s,
silentRetry=0) and the run died in the finally block.

Co-Authored-By: Claude Code <[email protected]>
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