AI / Claude Sonnet5 Interview questions
How does prompt caching behavior change when migrating to Claude Sonnet 5?
Prompt caching itself remains a supported feature on Sonnet 5, carried over unchanged from Sonnet 4.6 as part of the broader feature parity between the two versions.
What does change is the underlying token counts: because Sonnet 5's new tokenizer maps the same text to a different number of tokens than Sonnet 4.6's tokenizer did, cached token counts for a given prompt will differ between the two models even if the prompt text itself is byte-for-byte identical.
The practical implication is that cache breakpoints and minimum-length thresholds sized against Sonnet 4.6 token counts need to be re-verified against Sonnet 5's actual token counts, rather than assumed to carry over directly, since a prompt's token length relative to any caching threshold can shift purely from the tokenizer change.
More Related questions...