~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
fix: improve embedding test UX - move to top and add LLM hint on failure (#2269)
LearningCircuit332fa5b37af5
diff --git a/src/local_deep_research/research_library/routes/rag_routes.py b/src/local_deep_research/research_library/routes/rag_routes.pyindex 1aae834468..e56b7eb82d 100644--- a/src/local_deep_research/research_library/routes/rag_routes.py+++ b/src/local_deep_research/research_library/routes/rag_routes.py@@ -499,7 +499,44 @@ def test_embedding():)except Exception as e:- return handle_api_error("testing embedding", e)+ logger.exception("Error during testing embedding")+ error_str = str(e).lower()++ # Detect common signs that an LLM was selected instead of an embedding model+ llm_hints = [+ "does not support",+ "not an embedding",+ "generate embedding",+ "invalid model",+ "not found",+ "expected float",+ "could not convert",+ "list index out of range",+ "object is not subscriptable",+ "not iterable",+ "json",+ "chat",+ "completion",+ ]+ is_likely_llm = any(hint in error_str for hint in llm_hints)++ if is_likely_llm:+ user_message = (+ f"Embedding test failed for model '{model}'. "+ "This is most likely because an LLM (language model) was selected "+ "instead of an embedding model. Please choose a dedicated embedding "+ "model (e.g. nomic-embed-text, mxbai-embed-large, "+ "all-MiniLM-L6-v2)."+ )+ else:+ user_message = (+ f"Embedding test failed for model '{model}'. "+ "If you are unsure whether the selected model supports embeddings, "+ "try a dedicated embedding model instead (e.g. nomic-embed-text, "+ "mxbai-embed-large, all-MiniLM-L6-v2)."+ )++ return jsonify({"success": False, "error": user_message}), 500@rag_bp.route("/api/rag/models", methods=["GET"])diff --git a/src/local_deep_research/web/templates/pages/embedding_settings.html b/src/local_deep_research/web/templates/pages/embedding_settings.htmlindex 5159f88ee0..17add847e5 100644--- a/src/local_deep_research/web/templates/pages/embedding_settings.html+++ b/src/local_deep_research/web/templates/pages/embedding_settings.html@@ -39,6 +39,24 @@</div></div>+ <!-- Test Panel -->+ <div class="ldr-rag-operations-panel">+ <h2><i class="fas fa-vial"></i> Test Configuration</h2>+ <p class="ldr-text-muted" style="margin-bottom: 15px;">+ Test the currently selected embedding model to ensure it's working correctly.+ </p>++ <div class="ldr-operations-grid">+ <button class="ldr-btn ldr-btn-success ldr-btn-lg" onclick="testConfiguration()" id="test-config-btn">+ <i class="fas fa-play"></i> Test Embedding Model+ </button>+ </div>++ <div id="test-result" style="margin-top: 15px; display: none;">+ <!-- Test results will appear here -->+ </div>+ </div>+<!-- Configuration Panel --><div class="ldr-rag-config-panel"><h2><i class="fas fa-cog"></i> Configuration</h2>@@ -176,24 +194,6 @@</div></div></div>-- <!-- Test Panel -->- <div class="ldr-rag-operations-panel">- <h2><i class="fas fa-vial"></i> Test Configuration</h2>- <p class="ldr-text-muted" style="margin-bottom: 15px;">- Test the currently selected embedding model to ensure it's working correctly.- </p>-- <div class="ldr-operations-grid">- <button class="ldr-btn ldr-btn-success ldr-btn-lg" onclick="testConfiguration()" id="test-config-btn">- <i class="fas fa-play"></i> Test Embedding Model- </button>- </div>-- <div id="test-result" style="margin-top: 15px; display: none;">- <!-- Test results will appear here -->- </div>- </div></div>