All documentation

Improve / guide 21

Prompt caching and reuse

Reduce repeated prompt work while keeping versions and trace context visible.

Copy or share.

Prompt caching and reuse

Caching can reduce repeated prompt resolution or provider work, but it must not hide which prompt version a run used. Keep the version identifier on the generation span even when the content comes from a cache.

Measure cache behavior beside quality, cost, and latency. Invalidate or bypass cached content when promoting a new environment label or investigating a suspected prompt regression.