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.

5.2 KB
Raw Blame

PR #3147 — delete 3 dead strategy files + 4 orphaned test files

Components deleted in PR #3147 (see that PR for the full pre-deletion code — this file only summarises what was novel).

All three were unreachable from search_system_factory.py at deletion, with no consumers outside their own test files and the STRATEGY_IMPORTS list in tests/strategies/conftest.py.


Component: ImprovedEvidenceBasedStrategy

  • File deleted: src/local_deep_research/advanced_search_system/strategies/improved_evidence_based_strategy.py (782 LOC at deletion).
  • Reachability: not in search_system_factory.py; only referenced by its own two test files and STRATEGY_IMPORTS.
  • Closest reachable successor: EnhancedEvidenceBasedStrategy (src/local_deep_research/advanced_search_system/strategies/evidence_based_strategy_v2.py, factory key "evidence").

Useful ideas from the pre-deletion version

None uniquely interesting. Every distinctive mechanism had a more capable analog in v2 at deletion time — 4-stage discovery vs v2's 5-stage, binary failed-query blacklist vs v2's EMA pattern-success tracking, simple source-ratio diversity vs v2's entropy-based scoring, plain dict state vs v2's QueryPattern / SourceProfile dataclasses, naive re-search final verification vs v2's unused-source-driven verification.

Why deletion was safe

v2 was the factory's "evidence" target at deletion and is a strict functional superset. Last 12 months of git history on the Improved file showed lint sweeps and audit fixes only — no feature work.

Recovery path

Do not restore the file. If any piece of the v1-improved flow proves useful, add it as a method or option on EnhancedEvidenceBasedStrategy.


Component: LLMDrivenModularStrategy

  • File deleted: src/local_deep_research/advanced_search_system/strategies/llm_driven_modular_strategy.py (~820 LOC at deletion).
  • Reachability: not in search_system_factory.py; inner classes (CandidateConfidence, LLMConstraintProcessor, EarlyRejectionManager) were duplicated in ModularStrategy.
  • Closest reachable successor: ModularStrategy (src/local_deep_research/advanced_search_system/strategies/modular_strategy.py, factory keys "modular" / "modular-parallel"). The factory instantiates it with llm_constraint_processing=True by default, so "LLM-driven" behavior is already the production path.

Useful ideas from the pre-deletion version

  • 5-phase query generation — LLMDriven ran a 5-step pipeline (decompose → combinations → creative-angles → optimize → execute) with two extra LLM calls that ModularStrategy doesn't make. See generate_creative_search_angles() and optimize_search_combinations() in the pre-deletion file. The first asks the model for 30–40 alternate-angle queries (character / title / genre guessing, reverse searches) via a detective framing; the second reorganises generated queries into priority buckets (high_priority, systematic_granular, creative_angles, contextual_searches, fallback_broad) and de-dupes. Both are exploratory prompt-engineering tricks that were never validated against a benchmark; the extra cost was never shown to be worth it.
  • Divergent EarlyRejectionManager thresholds — LLMDriven rejected on negative > 0.7 OR positive < 0.1 (aggressive dual-check); ModularStrategy uses negative > 0.85 only (conservative single-check). ModularStrategy's threshold is the deliberate production default — it prefers not rejecting on absence-of-positive. Noted here so a future reader doesn't "fix" it by tightening.

Why deletion was safe

ModularStrategy subsumes LLMDriven on every axis except the two exploratory methods above: the shared inner classes are near-identical, ModularStrategy's explorer factory is more flexible than LLMDriven's hardcoded AdaptiveExplorer, and only ModularStrategy has search caching, background evaluation, and candidate recovery.

Recovery path

If the 5-phase generation becomes interesting for a real workload, reintroduce it as an optional mode on ModularStrategy (e.g. a llm_creative_angles=True flag) or as a new CuratedQueryExplorer variant. Do not resurrect the parallel strategy class.


Component: DirectSearchStrategy

  • File deleted: src/local_deep_research/advanced_search_system/strategies/direct_search_strategy.py (219 LOC at deletion).
  • Reachability: not in search_system_factory.py; no dedicated test file; only referenced in STRATEGY_IMPORTS.
  • Closest reachable successors: RapidSearchStrategy (factory key "rapid") and StandardSearchStrategy configured with iterations=1, questions_per_iteration=1 (factory key "standard").

Useful ideas from the pre-deletion version

None. The strategy was a strict degenerate case of StandardSearchStrategy reduced to one iteration with one question — same progress labels, same citation-handler call, same findings-repository shape.

Why deletion was safe

No unique logic, no dedicated tests, no external references. Any "single direct search" use case is already covered by an existing strategy configuration.

Recovery path

Do not restore. Configure RapidSearchStrategy or StandardSearchStrategy with minimal iteration settings instead.