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: increase default local context window to 18432 for langgraph-agent (#3342)

LearningCircuitaa89ccdd5e5d
diff --git a/src/local_deep_research/defaults/default_settings.json b/src/local_deep_research/defaults/default_settings.json
index 17dc84e23d..54a229e262 100644
--- a/src/local_deep_research/defaults/default_settings.json
+++ b/src/local_deep_research/defaults/default_settings.json
@@ -452,7 +452,7 @@
},
"llm.local_context_window_size": {
"category": "llm_parameters",
- "description": "Context window size in tokens for local LLMs (Ollama, LlamaCpp, LM Studio). Default is 8192 tokens. Increase if your model and hardware support larger contexts.",
+ "description": "Context window size in tokens for local LLMs (Ollama, LlamaCpp, LM Studio). The default of 18432 tokens is recommended for the langgraph-agent strategy which needs space for tool call history. If you have limited VRAM, reduce this and switch to the source-based strategy instead.",
"editable": true,
"max_value": 131072.0,
"min_value": 512.0,
@@ -461,7 +461,7 @@
"step": 512.0,
"type": "LLM",
"ui_element": "number",
- "value": 8192,
+ "value": 18432,
"visible": true
},
"llm.supports_max_tokens": {
diff --git a/src/local_deep_research/web/warning_checks/hardware.py b/src/local_deep_research/web/warning_checks/hardware.py
index 034e7e9a3a..a6f65f30cd 100644
--- a/src/local_deep_research/web/warning_checks/hardware.py
+++ b/src/local_deep_research/web/warning_checks/hardware.py
@@ -25,9 +25,10 @@ def check_high_context(
"icon": "⚠️",
"title": "High Context Warning",
"message": (
- f"Context size ({local_context:,} tokens) may cause memory issues "
- f"with {provider}. Increase VRAM or reduce context size if you "
- f"experience slowdowns."
+ f"Context size ({local_context:,} tokens) requires sufficient VRAM. "
+ f"This is recommended for the langgraph-agent strategy. "
+ f"If you experience slowdowns, reduce context size in settings "
+ f"and switch to the source-based strategy instead."
),
"dismissKey": "app.warnings.dismiss_high_context",
}
diff --git a/tests/settings/golden_master_settings.json b/tests/settings/golden_master_settings.json
index cd57c962e0..b6f4d16ad7 100644
--- a/tests/settings/golden_master_settings.json
+++ b/tests/settings/golden_master_settings.json
@@ -1007,7 +1007,7 @@
},
"llm.local_context_window_size": {
"category": "llm_parameters",
- "description": "Context window size in tokens for local LLMs (Ollama, LlamaCpp, LM Studio). Default is 8192 tokens. Increase if your model and hardware support larger contexts.",
+ "description": "Context window size in tokens for local LLMs (Ollama, LlamaCpp, LM Studio). The default of 18432 tokens is recommended for the langgraph-agent strategy which needs space for tool call history. If you have limited VRAM, reduce this and switch to the source-based strategy instead.",
"editable": true,
"max_value": 131072.0,
"min_value": 512.0,
@@ -1016,7 +1016,7 @@
"step": 512.0,
"type": "LLM",
"ui_element": "number",
- "value": 8192,
+ "value": 18432,
"visible": true
},
"llm.max_tokens": {