Sponsored by Deepsite.site

MCP Docs Search Server

Created By
RohitKrish468 months ago
This is a lightweight, plug-and-play MCP server that empowers any LLM to dynamically search and retrieve up-to-date documentation from popular AI libraries such as LangChain, LlamaIndex, and OpenAI.
Content

MCP Docs Search Server

A lightweight MCP server that searches and retrieves relevant documentation content from popular AI libraries like LangChain, LlamaIndex, and OpenAI using a combination of web search and content parsing.

This project allows Language Models to query and fetch up-to-date documentation content dynamically, acting as a bridge between LLMs and external doc sources.

Model Context Protocol (MCP)

The Model Context Protocol is an open standard that enables developers to build secure, two-way connections between their data sources and AI-powered tools. The architecture is straightforward: developers can either expose their data through MCP servers or build AI applications (MCP clients) that connect to these servers.

LLMs in Isolation

LLMs alone are limited — their true potential is unlocked when integrated with tools and services via frameworks like MCP.

LLM_on_its_own

  1. LLMs without tools, LLMs are static and have limited utility.

  2. With tools, they become interactive, but orchestration can be messy.

  3. With MCP, LLMs gain a scalable, plug-and-play interface to real-world services, making them much more practical and powerful in production environments.

MCP Ecosystem

The MCP Server acts as the translator/interface between LLMs and services.

MCP (Modular Capability Provider) standardizes how LLMs interact with external tools/services — promoting interoperability, modularity, and cleaner interfaces.

MCP_ecosystem

This structure decentralizes responsibility:

  1. Tool providers build and maintain their own MCP Server implementation.

  2. LLMs just need to speak the MCP protocol.

MCP

Purpose and Vision:

  • Standardize communication between LLMs and external tools

  • Avoid bespoke integrations

  • Encourage a scalable ecosystem of services (like a plugin architecture)

Features

Web Search Integration

Uses the Serper API to query Google and retrieve the top documentation pages related to a given search query.

Clean Content Extraction

Parses HTML content using BeautifulSoup to extract clean, human readable text stripping away unnecessary tags, ads, or navigation content.

Seamless LLM Tooling

Exposes a structured get_docs tool that can be used within LLM agents (e.g., Claude, GPT) to query specific libraries in real time.

Tool

get_docs(query: str, library: str)

This is the core tool provided by the MCP server. It accepts:

query: The search term or phrase.

library: One of langchain, llama-index, or openai.

Workflow

  1. Searches for relevant documentation pages
  2. Fetches and parses clean text content
  3. Sends the result back to the LLM for further reasoning and responses

Setup

  1. Clone the repository
git clone https://github.com/your-username/mcp-docs-search.git
cd mcp-docs-search
  1. Create a virtual Envoirment using uv and activate it
uv venv .venv

.\.venv\Scripts\activate
  1. Install dependencies
uv add "mcp[cli]" httpx
uv pip install beautifulsoup4
  1. Set your environment variables Create a .env file and add your Serper API key:
SERPER_API_KEY=your_serper_api_key

Claude Desktop Integration

To integrate this server as a tool within Claude Desktop:

Open Claude Desktop → File > Settings > Developer > Edit Config.

Update your claude_desktop_config.json to include the following:

{
    "mcpServers": {
        "documnetation": {
            "command": "uv",
            "args": [
                "--directory",
                "your_reository_where_the_repo_exists",
                "run",
                "main.py"
            ]

        }
    }
}

🔁 Important: Restart Claude Desktop after saving the config to load the new to

Once integrated successfully, you'll see your custom MCP tool appear within the Claude UI:

image

Use it to query docs in real time:

MCP_tool_working

Working_MCP

Debugging in Real Time

One can also debug the tool that we created using the following command.

Remember to install NodeJs18+

npx @modelcontextprotocol/inspector uv run main.py

and follow to the port where the connection is setup.

image

Supported Libraries / Docs

LangChain LlamaIndex OpenAI

More libraries can be easily added by updating the docs_urls dictionary.

Future Enhancements

  • Add support for additional libraries like HuggingFace, PyTorch, TensorFlow, etc.

  • Implement caching to reduce redundant fetches and improve performance.

  • Introduce a scoring/ranking mechanism based on relevance or token quality.

  • Unit testing and better exception handling for production readiness.

Recommend Servers
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
Tavily Mcp
DeepChatYour AI Partner on Desktop
Howtocook Mcp基于Anduin2017 / HowToCook (程序员在家做饭指南)的mcp server,帮你推荐菜谱、规划膳食,解决“今天吃什么“的世纪难题; Based on Anduin2017/HowToCook (Programmer's Guide to Cooking at Home), MCP Server helps you recommend recipes, plan meals, and solve the century old problem of "what to eat today"
AiimagemultistyleA Model Context Protocol (MCP) server for image generation and manipulation using fal.ai's Stable Diffusion model.
Zhipu Web SearchZhipu Web Search MCP Server is a search engine specifically designed for large models. It integrates four search engines, allowing users to flexibly compare and switch between them. Building upon the web crawling and ranking capabilities of traditional search engines, it enhances intent recognition capabilities, returning results more suitable for large model processing (such as webpage titles, URLs, summaries, site names, site icons, etc.). This helps AI applications achieve "dynamic knowledge acquisition" and "precise scenario adaptation" capabilities.
TimeA Model Context Protocol server that provides time and timezone conversion capabilities. This server enables LLMs to get current time information and perform timezone conversions using IANA timezone names, with automatic system timezone detection.
Amap Maps高德地图官方 MCP Server
Baidu Map百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
ChatWiseThe second fastest AI chatbot™
Context7Context7 MCP Server -- Up-to-date code documentation for LLMs and AI code editors
Serper MCP ServerA Serper MCP Server
Jina AI MCP ToolsA Model Context Protocol (MCP) server that integrates with Jina AI Search Foundation APIs.
MiniMax MCPOfficial MiniMax Model Context Protocol (MCP) server that enables interaction with powerful Text to Speech, image generation and video generation APIs.
BlenderBlenderMCP connects Blender to Claude AI through the Model Context Protocol (MCP), allowing Claude to directly interact with and control Blender. This integration enables prompt assisted 3D modeling, scene creation, and manipulation.
EdgeOne Pages MCPAn MCP service designed for deploying HTML content to EdgeOne Pages and obtaining an accessible public URL.
Playwright McpPlaywright MCP server
MCP AdvisorMCP Advisor & Installation - Use the right MCP server for your needs
CursorThe AI Code Editor
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
WindsurfThe new purpose-built IDE to harness magic