Skip to content

~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.

fix: hardcoded test override, mutable defaults, pdm.lock sync (#2945)

LearningCircuitc424026ed43f
diff --git a/src/local_deep_research/search_system_factory.py b/src/local_deep_research/search_system_factory.py
index b09e531d4a..fa498e85e3 100644
--- a/src/local_deep_research/search_system_factory.py
+++ b/src/local_deep_research/search_system_factory.py
@@ -898,7 +898,7 @@ def create_strategy(
search_original_query=kwargs.get("search_original_query", True),
max_topics=kwargs.get("max_topics", 5),
similarity_threshold=kwargs.get("similarity_threshold", 0.3),
- use_focused_iteration=True, # HARDCODED TO TRUE for testing - original: kwargs.get("use_focused_iteration", False)
+ use_focused_iteration=kwargs.get("use_focused_iteration", False),
enable_refinement=kwargs.get(
"enable_refinement", False
), # Disable refinement iterations for now
diff --git a/src/local_deep_research/utilities/es_utils.py b/src/local_deep_research/utilities/es_utils.py
index c73e6a2e43..1f031f6391 100644
--- a/src/local_deep_research/utilities/es_utils.py
+++ b/src/local_deep_research/utilities/es_utils.py
@@ -20,7 +20,7 @@ class ElasticsearchManager:
def __init__(
self,
- hosts: List[str] = ["http://localhost:9200"],
+ hosts: Optional[List[str]] = None,
username: Optional[str] = None,
password: Optional[str] = None,
api_key: Optional[str] = None,
@@ -36,6 +36,7 @@ class ElasticsearchManager:
api_key: Optional API key for authentication
cloud_id: Optional Elastic Cloud ID
"""
+ hosts = hosts or ["http://localhost:9200"]
# Initialize the Elasticsearch client
es_args: Dict[str, Any] = {}
@@ -333,7 +334,7 @@ class ElasticsearchManager:
self,
index_name: str,
directory_path: str,
- file_patterns: List[str] = ["*.txt", "*.pdf", "*.docx", "*.md"],
+ file_patterns: Optional[List[str]] = None,
content_field: str = "content",
title_field: str = "title",
extract_metadata: bool = True,
@@ -354,6 +355,7 @@ class ElasticsearchManager:
Returns:
int: Number of successfully indexed files
"""
+ file_patterns = file_patterns or ["*.txt", "*.pdf", "*.docx", "*.md"]
try:
# Find all matching files
all_files = []
diff --git a/src/local_deep_research/web_search_engines/engines/search_engine_elasticsearch.py b/src/local_deep_research/web_search_engines/engines/search_engine_elasticsearch.py
index 5a5a7d4c15..4ce6b5cc35 100644
--- a/src/local_deep_research/web_search_engines/engines/search_engine_elasticsearch.py
+++ b/src/local_deep_research/web_search_engines/engines/search_engine_elasticsearch.py
@@ -14,7 +14,7 @@ class ElasticsearchSearchEngine(BaseSearchEngine):
def __init__(
self,
- hosts: List[str] = ["http://localhost:9200"],
+ hosts: Optional[List[str]] = None,
index_name: str = "documents",
username: Optional[str] = None,
password: Optional[str] = None,