From 5cf66770bc08dcd68c48bcd26ad857d0851e6151 Mon Sep 17 00:00:00 2001 From: 0xZensh Date: Wed, 29 Jan 2025 11:30:03 +0800 Subject: [PATCH] chore: optimize KnowledgeStore when bootstrap --- agents/anda_bot/nitro_enclave/amd64.Dockerfile | 2 +- agents/anda_bot/src/main.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/agents/anda_bot/nitro_enclave/amd64.Dockerfile b/agents/anda_bot/nitro_enclave/amd64.Dockerfile index 5d44e7a..84e7f11 100644 --- a/agents/anda_bot/nitro_enclave/amd64.Dockerfile +++ b/agents/anda_bot/nitro_enclave/amd64.Dockerfile @@ -26,7 +26,7 @@ RUN mv linux-amd64/dnsproxy ./ && chmod +x dnsproxy RUN wget -O ic_tee_nitro_gateway https://github.com/ldclabs/ic-tee/releases/download/v0.2.11/ic_tee_nitro_gateway RUN chmod +x ic_tee_nitro_gateway -RUN wget -O anda_bot https://github.com/ldclabs/anda/releases/download/v0.3.3/anda_bot +RUN wget -O anda_bot https://github.com/ldclabs/anda/releases/download/v0.3.4/anda_bot RUN chmod +x anda_bot FROM --platform=linux/amd64 debian:bookworm-slim AS runtime diff --git a/agents/anda_bot/src/main.rs b/agents/anda_bot/src/main.rs index 212fbcc..adb220c 100644 --- a/agents/anda_bot/src/main.rs +++ b/agents/anda_bot/src/main.rs @@ -355,7 +355,7 @@ async fn connect_knowledge_store( let ks = KnowledgeStore::init(&mut store, namespace, model.ndims() as u16, Some(1024 * 10)).await?; log::info!(target: LOG_TARGET, "knowledge_store ks: {:?}", ks.name()); - ks.create_index().await?; + ks.optimize().await?; Ok(ks) }