Add agent rehearsal harness, findings, and per-run evidence for split-loop-with-lambda
Six scripted pi sub-agent runs (3 tool regimes × 2 models) rehearsed the exercise; deterministic gate = solution test + approved file. Key results: mandated CLI triples cost on the strong model (4:06 vs 0:39, PASS both); weak model fails only under the mandate (A+Q), passes when free or optional. Drift documented with code: scorer.updateSelection left inside the extracted method (A+Q, C+Q). Harness in tools/rehearse; summary in rehearsal-findings.md; per-run evidence in rehearsal-runs/; cheat sheet in rehearse-with-agent.md corrected (lambda-typed parameters unsupported).
This commit is contained in:
@@ -70,5 +70,11 @@ file dropped in: it must pass deterministically.
|
||||
| introduce lambda | none — manual edit |
|
||||
| slide statement | none — manual edit |
|
||||
| extract method | `java-refactor extract` |
|
||||
| add lambda parameter | `java-refactor introduce-param` / `change-method-signature` |
|
||||
| add lambda parameter | none — manual edit (`introduce-param` / `change-method-signature` cannot introduce a lambda expression as a parameter: `introduce-param` on the lambda inlines it into the call site, referencing the private `scorer` field from outside the class → does not compile. Lambdas are only handled as rewrite *targets* — method references get converted to lambdas at call sites — never as the subject of an operation) |
|
||||
| move method to another class (step 4, not in scope) | `java-refactor move-method` (call sites not rewritten) |
|
||||
|
||||
Rehearsal evidence (2026-09-27, see `rehearsal-findings.md`): with the CLI
|
||||
merely *available* (not mandated) plus a 6-line subcommand intro, glm-5.3-flash
|
||||
passed in 2:37 / 23 turns — using `extract` (dry-run → apply) for step 2 and
|
||||
editing manually for steps 1 and 3, with no tool-shopping detour. Mandating the
|
||||
CLI (variant A) tripled the turns of plain editing (B) on this 55-line file.
|
||||
|
||||
Reference in New Issue
Block a user