Repository navigation
Lookback: count positions the way Bedrock does now (0.4.1) - #2
Merged
Merged
Conversation
Bedrock changed how far back a cache point finds the previous entry. Measured live on Oct 30 2026 (Sonnet 4.6 and 5.5, Converse and InvokeModel): a group of tool calls side by side counts as one position, so do their results, thinking blocks don't count, and a checkpoint block always counts on its own; 21 positions still hit, 22 miss. On Oct 7 every block counted, so many parallel tool calls lost the cache; they no longer do. - diff: lookback-exceeded now counts positions (new scripts/live_lookback_positions.py checks the count against live Bedrock: 52/52 on Sonnet 4.6, 24/24 on Sonnet 5.5) - guides: Strands, LangChain and LiteLLM re-run live (15/15, 10/10, 14/14); the parallel tool call findings now show the old and new numbers; the Strands hook and the LiteLLM helper for wide tool rounds are no longer needed and are removed - homepage, README, llms.txt and the checker updated to match; live_test.py lookback case uses sequential tool calls
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bedrock changed how far back a cache point finds the previous entry. Measured live on Oct 30 2026 (Sonnet 4.6 and 5.5, Converse and InvokeModel): a group of tool calls side by side counts as one position, so do their results, thinking blocks don't count, and a checkpoint block always counts on its own. 21 positions still hit, 22 miss. On Oct 7 every block counted, so many parallel tool calls lost the cache; they no longer do.
diff:lookback-exceededcounts positions.scripts/live_lookback_positions.pychecks the count against live Bedrock (52/52 on Sonnet 4.6, 24/24 on Sonnet 5.5).live_test.pylookback case uses sequential tool calls (11/11 live).