From 77d3aa24e2a1ae6278a279b28d42472a3ff2a0f4 Mon Sep 17 00:00:00 2001 From: Victor Kyriazakos Date: Mon, 14 Sep 2026 21:07:10 +0000 Subject: [PATCH] docs(bedrock): specify persisted URL for cache invalidation --- agent/model_metadata.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/agent/model_metadata.py b/agent/model_metadata.py index 84ccceaabd..26419717ad 100644 --- a/agent/model_metadata.py +++ b/agent/model_metadata.py @@ -1192,7 +1192,11 @@ def get_cached_context_length(model: str, base_url: str, *, bedrock_confirmed: b def _invalidate_cached_context_length(model: str, base_url: str) -> None: - """Drop a stale cache entry so it gets re-resolved on the next lookup.""" + """Drop a stale entry and its probe cooldown using the persisted cache URL. + + Bedrock callers without a runtime endpoint must pass ``bedrock://``, as + the resolver does; a blank URL addresses the distinct generic cache key. + """ key = _context_cache_key(model, base_url) document = _load_context_cache_document() cache = document.get("context_lengths") or {}