How zhidian-cmd/deep_search works
Deep Search MCP is a single-entry research pipeline: an MCP caller submits a query, the skill orchestrates search, page retrieval, quality/relevance filtering, deduplication, and a cited-source response with durable archives. Search aggregation is delegated to a Go CLI, while Python ranks and processes results. Separate branches support PDF preservation, cross-call deduplication, adaptive fetch-quality learning, and an engine/key GUI. Relationships follow the README’s documented workflow and sampled caller code; unsampled implementation details are not inferred.
Main entry points: skill.py Pipeline orchestrator · web_fetch.py Fetch manager · search.py Search bridge · server.py MCP tool
Components 20
MCP and orchestration
- MCP tool
server.py - Pipeline orchestrator
skill.py - Runtime settings
config.py
Search and ranking
- Search bridge
search_engine/search.py - Metasearch CLI
- Search providers
- Result ranker
search_engine/ranking_meta/rank.py - Engine key GUI
search_engine/gui.py
Fetch and quality
- Fetch manager
web_fetch.py - Content filters
filters.py - Filter signals
filters_keywords.py - Adaptive learning
filters_learn.py
State and delivery
- Cross-round ledger
ledger.py - Content dedup
skill.py - PDF preservation
web_fetch.py - Text and URL helpers
helpers.py - Markdown archive
config.py - Sources and answer
server.py
Other components
- Research caller
- Web pages
Connections 21
- Research caller → MCP tool: submits query
README.md - MCP tool → Pipeline orchestrator: invokes
README.md - Pipeline orchestrator → Runtime settings: configures
skill.py - Pipeline orchestrator → Search bridge: requests results
README.md - Search bridge → Metasearch CLI: runs search
search_engine/search.py - Metasearch CLI → Search providers: aggregates queries
README.md - Search bridge → Result ranker: ranks results
search_engine/search.py - Engine key GUI → Search bridge: runs test search
search_engine/gui.py - Pipeline orchestrator → Fetch manager: fetches candidates
README.md - Fetch manager → Web pages: retrieves pages
README.md - Fetch manager → Content filters: scores content
README.md - Content filters → Filter signals: uses signals
filters.py - Fetch manager → Adaptive learning: records outcomes
web_fetch.py - Pipeline orchestrator → Content filters: checks relevance
skill.py - Pipeline orchestrator → Cross-round ledger: checks and records
README.md - Pipeline orchestrator → Content dedup: merges similar content
README.md - Fetch manager → PDF preservation: saves PDF files
README.md - Pipeline orchestrator → Text and URL helpers: formats archive text
- Pipeline orchestrator → Markdown archive: writes archive
README.md - Pipeline orchestrator → Sources and answer: assembles answer
README.md - MCP tool → Research caller: returns result
server.py