~95% on SimpleQA (e.g. Qwen3.6-27B on a 3090). Supports all local and cloud LLMs (llama.cpp, Ollama, Google, ...). 10+ search engines - arXiv, PubMed, your private documents. Everything Local & Encrypted.
Python academiaanthropicarxivbravedeep-researchencryptionhome-automationhomeserverlocallocal-deep-researchlocal-llmmistralollamaopenaipubmedresearchresearch-toolretrieval-augmented-generationsearxngself-hosted
if the filter doesnt work it should return no response
LearningCircuit30bfd1ff02e0
diff --git a/src/local_deep_research/web_search_engines/search_engine_base.py b/src/local_deep_research/web_search_engines/search_engine_base.pyindex b2984eb094..1644741a74 100644--- a/src/local_deep_research/web_search_engines/search_engine_base.py+++ b/src/local_deep_research/web_search_engines/search_engine_base.py@@ -166,15 +166,15 @@ If no results seem relevant to the query, return an empty array: []"""# Validate that ranked_indices is a list of integersif not isinstance(ranked_indices, list):logger.warning(- "LLM response is not a list, returning original results"+ "LLM response is not a list, returning empty results")- return previews[: min(5, len(previews))]+ return []if not all(isinstance(idx, int) for idx in ranked_indices):logger.warning(- "LLM response contains non-integer indices, returning original results"+ "LLM response contains non-integer indices, returning empty results")- return previews[: min(5, len(previews))]+ return []# Return the results in ranked orderranked_results = []@@ -184,13 +184,6 @@ If no results seem relevant to the query, return an empty array: []"""else:logger.warning(f"Index {idx} out of range, skipping")- # If we filtered out all results, return at least some of the originals- if not ranked_results and previews:- logger.info(- "Filtering removed all results, returning top 3 originals instead"- )- return previews[: min(3, len(previews))]-# Limit to max_filtered_results if specifiedif (self.max_filtered_results@@ -206,7 +199,7 @@ If no results seem relevant to the query, return an empty array: []"""except json.JSONDecodeError as e:logger.warning(f"Failed to parse JSON from LLM response: {e}")logger.debug(f"Problematic JSON text: {array_text}")- return previews[: min(5, len(previews))]+ return []else:logger.warning("Could not find JSON array in response, returning original previews"