pub fn with_memory_cache<T>(work: impl FnOnce() -> T) -> T
Retain prediction maps across sequential per-run searches on this thread. The guard restores the previous scope even on early return or panic.