feat(auto-compact): guarantee last message, chunked summarize, signal-if-too-big
- Always keep the CURRENT request (last message) intact and as the very last
message after compaction (the compacted history/summary precedes it).
- summarize strategy now CHUNKs the older history and summarizes map-reduce
(per-chunk then a combined pass) so the summarization prompt can't itself
overflow.
- If compaction still can't fit the window (e.g. a single huge final message),
return HTTP 400 "request too big for context" instead of failing mid-generation.
Co-Authored-By:
Claude Opus 4.8 <noreply@anthropic.com>
Showing
Please
register
or
sign in
to comment