Skip to content

fix: don't claim main model summarized after dual compaction failure#19

Merged
morganlinton merged 2 commits into
GetSmallAI:mainfrom
nelopuchades:fix/compaction-failure-notice
Jul 17, 2026
Merged

fix: don't claim main model summarized after dual compaction failure#19
morganlinton merged 2 commits into
GetSmallAI:mainfrom
nelopuchades:fix/compaction-failure-notice

Conversation

@nelopuchades

@nelopuchades nelopuchades commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Summary

  • When a dedicated compaction model fails (or is unavailable) and the main-model fallback also fails, the harness still deterministic-trims older turns.
  • The compaction notice no longer claims the transcript was "summarized with" the main model in that case.
  • Warnings are set only after the final outcome is known, so a failed main retry cannot leave a misleading "summarized with {main}" label.

Test plan

  • cargo test compaction_
  • cargo clippy --all-targets -- -D warnings
  • cargo fmt --all -- --check
  • Regression: dedicated model fails + main fails → notice says "trimmed deterministically", not "summarized with"
  • Regression: unavailable compaction model + main fails → same correct notice

When the compaction model fails (or is unavailable) and the main-model
retry also fails, the harness still deterministic-trims, but the notice
must not say "summarized with {main}". Set warnings only after the final
outcome so a failed fallback never mislabels a trim as a summary.

@morganlinton morganlinton left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good — warnings are applied only after the final compaction outcome, so dual failure no longer mislabels a deterministic trim as “summarized with {main}”. Nice regression coverage.

@morganlinton
morganlinton merged commit 0d66f20 into GetSmallAI:main Jul 17, 2026
5 checks passed
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.

2 participants