Uh oh!
There was an error while loading. Please reload this page.
fix: add prompt caching to session compaction - Issue #10342 - #10380
fix: add prompt caching to session compaction - Issue #10342#10380Luckybalabala wants to merge 1 commit into
Conversation
The following comment was made by an LLM, it may be inaccurate: Based on my search, I found related PRs that touch on session compaction, but none appear to be direct duplicates of PR #10380: Related but not duplicates:
Conclusion: |
9859412 to
7ff669aCompare7ff669a to
73f68a1Comparef1ae801 to
08fa7f7CompareClosing this pull request because it has had no updates for more than 60 days. If you plan to continue working on it, feel free to reopen or open a new PR. |
Problem
Session compaction sent an empty
system: []array, missing the ~90% cost savings from prompt caching.Solution
Added system prompts to compaction processor:
Impact
Technical Details
The
SystemPrompt.environment()andSystemPrompt.custom()methods return prompts that support Claude's prompt caching feature:Testing
Fixes#10342 - Major cost optimization for long sessions