Tag
Prompt caching charges a premium to write and a discount to read, so it only pays past a break-even reuse count. Here is the formula, the usual bug, and a script that prints a verdict.