From 266bbd23e35f36a26c6e0a9334ece19a89bb3e5c Mon Sep 17 00:00:00 2001 From: dawn <90008@klbr.net> Date: Sun, 28 Jun 2026 17:56:23 +0300 Subject: [PATCH] feat: use persistent data dir for global embed cache --- klbr-bench/src/longmemeval.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/klbr-bench/src/longmemeval.rs b/klbr-bench/src/longmemeval.rs index 6dcbd90..97313fe 100644 --- a/klbr-bench/src/longmemeval.rs +++ b/klbr-bench/src/longmemeval.rs @@ -2954,7 +2954,10 @@ struct GlobalEmbedCache { impl GlobalEmbedCache { fn new() -> Result { - let cache_path = "/tmp/klbr_embed_cache.db"; + let cache_path = "/home/mayer/.local/share/klbr/klbr_embed_cache.db"; + if let Some(parent) = Path::new(cache_path).parent() { + fs::create_dir_all(parent)?; + } let conn = rusqlite::Connection::open(cache_path)?; conn.execute( "CREATE TABLE IF NOT EXISTS cache ( -- 2.51.2