Self-evolving Context Database for AI Agents. Unify Agent Memory, Knowledge RAG and Skills.
Python agent-contextagent-memoryagent-pluginsagentic-ragcontext-databasedsh-pluginknowledge-basememorymemory-managementself-evolvingvector-database
fix(retrieve): apply threshold filter to initial candidates in HierarchicalRetriever (#1797)
Monday5154644c010c
diff --git a/openviking/retrieve/hierarchical_retriever.py b/openviking/retrieve/hierarchical_retriever.pyindex bdcde7a0c..99bf684fb 100644--- a/openviking/retrieve/hierarchical_retriever.py+++ b/openviking/retrieve/hierarchical_retriever.py@@ -402,6 +402,11 @@ class HierarchicalRetriever:# 只添加 level 2 的文件if r.get("level", 2) == 2:score = r.get("_score", 0.0)+ if not passes_threshold(score):+ logger.debug(+ f"[RecursiveSearch] Initial candidate URI {uri} score {score:.4f} did not pass threshold {effective_threshold}"+ )+ continuer["_final_score"] = scorecollected_by_uri[uri] = rlogger.debug(