Skip to content

agent-core: the wrap-up at max_steps is the only behavior; delete mask-breakeven - #244

Merged
jaredLunde merged 1 commit into
mainfrom
jared/wrap-up-and-mask
Oct 12, 2026
Merged

jaredLunde merged 1 commit into
mainfrom
jared/wrap-up-and-mask

Conversation

@jaredLunde

Copy link
Copy Markdown
Contributor

Two decisions from the re-tests of #232 and #234.

Wrap-up at max_steps: shipped as the only behavior

At a max_steps ceiling the model now always gets WRAP_UP_STEPS (5) more steps, with a tighter instruction: no new code and no finishing a change in progress; fix or revert only a file that no longer parses or imports; run the test suite once; summarize. A model that stops within the grant ends the run normally; one that uses it up still gets Error::MaxSteps naming the configured ceiling. --max-steps-wrap-up and StepBudget/with_step_budget are deleted; AgentEvent::StepBudget becomes WrapUp { steps }.

Why the tighter text: in round 1 one sqlparse run kept implementing stubs during the grant (def process, __repr__) and ended with 171 regressions; those edits were new work, not repairs.

Re-test, Luna, sqlparse + marshmallow at --max-steps 60, 3 runs a side:

control wrap-up
Broken-tree endings (regressions > 0) 0/6 0/6
Ended with an honest summary 0/6 (silent cut-off) 6/6
Mean fixed fraction 0.679 0.634
$ 0.300 0.298

The grant made no source edit in 5 of 6 runs (compile check and/or one full test run, then the summary) and one targeted fix in the sixth, so it did not lower any run's fixed fraction; the arms' mean gap comes from the 60 steps before the ceiling, where both arms run the same code.

mask-breakeven: deleted

Haiku, sqlparse + marshmallow, 4 runs a side:

control mask-breakeven
Mean fixed fraction (paired) 0.971 0.898
Compactions 21 27
Masking passes 10 2
$ 1.444 1.313

A paired drop past the 0.03 bar. The rule's counterfactual was wrong: a masking pass runs only at the trigger, so skipping it means summarizing now (a whole-prefix rewrite plus lost verbatim context), not saving the rewrite. One run's post-compaction context collapsed and it quit at 20%. Pricing the real alternative would converge on always masking, i.e. the control. Deleted with growth_per_turn and mask_net_saving; mask-breakeven is an unknown candidate now.

state/tail stay: the in-flight summary eval builds on them.

🤖 Generated with Claude Code

https://claude.ai/code/session_01JimHGjsfk2Ktm5GxyZJKKk

@jaredLunde
jaredLunde enabled auto-merge October 12, 2026 11:41
@jaredLunde
jaredLunde added this pull request to the merge queue Oct 12, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Oct 12, 2026
…k-breakeven

Wrap-up (#232's --max-steps-wrap-up, re-tested with a tighter text):
at a max_steps ceiling the model now always gets WRAP_UP_STEPS (5)
more steps, told to stop cleanly: no new code and no finishing a
change in progress, fix or revert only a file that no longer parses or
imports, run the test suite once, summarize. A model that stops within
the grant ends the run normally; one that uses it up still gets
Error::MaxSteps naming the configured ceiling.

- Luna, sqlparse + marshmallow at --max-steps 60, 3 runs a side: 6/6
  wrap-up runs ended with an honest summary (control: 6 silent
  cut-offs), 0 broken trees on either side, $0.298 vs $0.300. The grant
  made no source edit in 5 of 6 runs and one targeted fix in the sixth;
  the arms' mean fixed fraction (0.634 vs 0.679) differs by what
  happened before the ceiling.
- The old text ("fix or revert anything broken, start no new work") let
  a run keep implementing stubs during the grant and end with 171
  regressions; the new one forbids continuing the task.

Deleted: StepBudget, Agent::with_step_budget, --max-steps-wrap-up (an
unknown argument now). AgentEvent::StepBudget becomes WrapUp { steps }.

mask-breakeven (#234): Haiku sqlparse + marshmallow, 4 runs a side,
mean fixed fraction 0.971 -> 0.898 (a paired drop past the 0.03 bar),
compactions 21 -> 27, masks 10 -> 2, $ -9%. Its counterfactual was
wrong: a pass runs only at the trigger, so skipping it means
summarizing now, not saving the rewrite; one run's post-compaction
context collapsed and it quit at 20%. Deleted with growth_per_turn and
mask_net_saving; mask-breakeven is an unknown candidate now.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JimHGjsfk2Ktm5GxyZJKKk
@jaredLunde
jaredLunde enabled auto-merge October 12, 2026 12:07
@jaredLunde
jaredLunde force-pushed the jared/wrap-up-and-mask branch from fda1e03 to e60cf2c Compare October 12, 2026 12:07
@jaredLunde
jaredLunde added this pull request to the merge queue Oct 12, 2026
Merged via the queue into main with commit f4ffd04 Oct 12, 2026
13 checks passed
@jaredLunde
jaredLunde deleted the jared/wrap-up-and-mask branch October 12, 2026 12:33
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