Skip to main content

Module inference_cache

Module inference_cache 

Source
Expand description

Inference Cache with Invalidation

Memoization cache for inference results, keyed by (goal_term_hash, kb_version) → bindings. Supports LRU eviction and monotonic-version-based invalidation.

Structs§

CacheStats
Summary statistics for the cache.
CachedResult
One cached inference result.
InferenceCache
Memoization cache for inference results. Keyed by (goal_term_hash, kb_version) → bindings.
InferenceCacheKey
Cache key: combination of goal hash and KB version.

Functions§

hash_goal
Compute the FNV-1a hash for a serialised goal term.