pub fn compute_cache_key(
model: &str,
system: System<'_>,
tools: Option<&Value>,
) -> StringExpand description
Stable scope key for (model, system, tools).
Returns "{KEY_PREFIX}:{model}:sha256:{hex}". tools must be a JSON
array (or None); each element is canonicalized.
Everything after the last cache_control in system is dropped to
match Anthropic’s cached prefix. Tools always participate because
Anthropic includes them in the cached prefix.