FALL_BACK_TO_COMPUTE

Swallow the embedder's exception and call compute as if the lookup had missed.

"Never fail a getOrPut that could have just called the model." With this policy a SemanticCache.getOrPut degrades to an uncached model call while the embedder is unavailable, so the feature the cache fronts keeps working. The trade-off is explicit: the computed answer cannot be written back — there is no embedding to key it by — so nothing is cached until the embedder recovers, and the failure is invisible unless you are watching a CacheListener or the embedder's own instrumentation.

Properties

Link copied to clipboard
Link copied to clipboard