by nkapila6
Provides local RAG‑style web search capabilities for LLMs by fetching DuckDuckGo results, generating embeddings with MediaPipe, ranking relevance, and returning extracted markdown content without external APIs.
Mcp Local Rag enables an LLM to perform live web searches, compute semantic similarity between the query and fetched results, and retrieve concise markdown excerpts from the top‑ranked pages. It runs entirely locally and communicates via the Model Context Protocol (MCP).
mcp-local-rag server.uv and run the command shown in the configuration snippet.ghcr.io/nkapila6/mcp-local-rag:latest and execute the provided docker run command.mcp-local-rag tool. The server performs the search, processes the results, and returns the markdown context to the model, which then generates the final response.Q: Do I need an API key? A: No. All operations run locally using public DuckDuckGo search and open‑source embedding models.
Q: Which LLM clients are compatible? A: Any client that implements the MCP tool‑calling interface, e.g., Claude Desktop, Cursor, Goose, and others.
Q: Can I adjust the number of search results or the embedding model?
A: Yes. The source code is configurable; modify the search_limit or replace the MediaPipe embedder with another model as needed.
Q: How is the returned context formatted? A: The server extracts the main textual content from each URL and converts it to markdown before sending it back to the LLM.
Q: Is Docker required?
A: Docker is optional but recommended for reproducible environments. The uvx method works directly on a machine with Python 3.10+ and uv installed.
"primitive" RAG-like web search model context protocol (MCP) server that runs locally. ✨ no APIs ✨
Locate your MCP config path here or check your MCP client settings.
uvxThis is the easiest and quickest method. You need to install uv for this to work. Add this to your MCP server configuration:
{
"mcpServers": {
"mcp-local-rag":{
"command": "uvx",
"args": [
"--python=3.10",
"--from",
"git+https://github.com/nkapila6/mcp-local-rag",
"mcp-local-rag"
]
}
}
}
Ensure you have Docker installed. Add this to your MCP server configuration:
{
"mcpServers": {
"mcp-local-rag": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"--init",
"-e",
"DOCKER_CONTAINER=true",
"ghcr.io/nkapila6/mcp-local-rag:latest"
]
}
}
}
MseeP does security audits on every MCP server, you can see the security audit of this MCP server by clicking here.
The MCP server should work with any MCP client that supports tool calling. Has been tested on the below clients.
When an LLM (like Claude) is asked a question requiring recent web information, it will trigger mcp-local-rag.
When asked to fetch/lookup/search the web, the model prompts you to use MCP server for the chat.
In the example, have asked it about Google's latest Gemma models released yesterday. This is new info that Claude is not aware about.
mcp-local-rag performs a live web search, extracts context, and sends it back to the model—giving it fresh knowledge:
Have ideas or want to improve this project? Issues and pull requests are welcome!
This project is licensed under the MIT License.
Please log in to share your review and rating for this MCP.
{
"mcpServers": {
"mcp-local-rag": {
"command": "uvx",
"args": [
"--python=3.10",
"--from",
"git+https://github.com/nkapila6/mcp-local-rag",
"mcp-local-rag"
],
"env": {}
}
}
}claude mcp add mcp-local-rag uvx --python=3.10 --from git+https://github.com/nkapila6/mcp-local-rag mcp-local-ragExplore related MCPs that share similar capabilities and solve comparable challenges
by exa-labs
Provides real-time web search capabilities to AI assistants via a Model Context Protocol server, enabling safe and controlled access to the Exa AI Search API.
by perplexityai
Enables Claude and other MCP‑compatible applications to perform real‑time web searches through the Perplexity (Sonar) API without leaving the MCP ecosystem.
by MicrosoftDocs
Provides semantic search and fetch capabilities for Microsoft official documentation, returning content in markdown format via a lightweight streamable HTTP transport for AI agents and development tools.
by elastic
Enables natural‑language interaction with Elasticsearch indices via the Model Context Protocol, exposing tools for listing indices, fetching mappings, performing searches, running ES|QL queries, and retrieving shard information.
by graphlit
Enables integration between MCP clients and the Graphlit platform, providing ingestion, extraction, retrieval, and RAG capabilities across a wide range of data sources and connectors.
by mamertofabian
Fast cross‑platform file searching leveraging the Everything SDK on Windows, Spotlight on macOS, and locate/plocate on Linux.
by cr7258
Provides Elasticsearch and OpenSearch interaction via Model Context Protocol, enabling document search, index management, cluster monitoring, and alias operations.
by kagisearch
Provides web search and video summarization capabilities through the Model Context Protocol, enabling AI assistants like Claude to perform queries and summarizations.
by liuyoshio
Provides natural‑language search and recommendation for Model Context Protocol servers, delivering rich metadata and real‑time updates.