Skip to main content

Module embedding_cache

Module embedding_cache 

Source
Expand description

LRU embedding cache with memory-bounded eviction and per-model invalidation.

Structsยง

CacheEntry
A single cached embedding entry.
CacheKey
Cache key: content hash + model identifier.
CacheStats
Cache statistics snapshot.
EmbeddingCache
LRU embedding cache with a fixed entry-count capacity.
MemoryBoundedCache
An EmbeddingCache variant that evicts entries when total memory exceeds a byte limit.