Felipe Cardoso
6be8e2e88d
feat(memory): implement caching layer for memory operations (#98)
Add comprehensive caching layer for the Agent Memory System:
- HotMemoryCache: LRU cache for frequently accessed memories
- Python 3.12 type parameter syntax
- Thread-safe operations with RLock
- TTL-based expiration
- Access count tracking for hot memory identification
- Scoped invalidation by type, scope, or pattern
- EmbeddingCache: Cache embeddings by content hash
- Content-hash based deduplication
- Optional Redis backing for persistence
- LRU eviction with configurable max size
- CachedEmbeddingGenerator wrapper for transparent caching
- CacheManager: Unified cache management
- Coordinates hot cache, embedding cache, and retrieval cache
- Centralized invalidation across all caches
- Aggregated statistics and hit rate tracking
- Automatic cleanup scheduling
- Cache warmup support
Performance targets:
- Cache hit rate > 80% for hot memories
- Cache operations < 1ms (memory), < 5ms (Redis)
83 new tests with comprehensive coverage.
2026-01-05 04:04:13 +01:00
..
2026-01-05 03:49:22 +01:00
2026-01-03 17:55:34 +01:00
2026-01-05 04:04:13 +01:00
2026-01-04 19:41:54 +01:00
2025-11-25 00:37:23 +01:00
2025-11-10 11:55:15 +01:00
2025-11-10 11:55:15 +01:00
2026-01-03 01:35:18 +01:00
2025-11-26 13:23:44 +01:00
2026-01-03 01:35:18 +01:00
2025-11-10 11:55:15 +01:00