mcp-retrieval-engine
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
mcp-retrieval-engine
A production-ready Model Context Protocol (MCP) server implementing a local RAG (Retrieval-Augmented Generation) pipeline. This project enables AI agents to securely search and retrieve information from local document repositories with high semantic accuracy.
Overview
Unlike standard chatbots, this system bridges the "context gap" by allowing LLMs to dynamically query private files. By using the MCP standard, the AI can decide when it needs to "look up" information in your local database before answering.
Key Features
Semantic Search: Uses
all-MiniLM-L6-v2embeddings to find information based on meaning, not just keywords.Agentic Integration: Fully compatible with MCP-native clients like Claude Desktop and Cursor.
Local-First Privacy: All document indexing and vector searches are performed on-device via ChromaDB.
Multi-Format Support: Native parsing for PDF, TXT, and Markdown files.
Related MCP server: Personal Semantic Search MCP
Architecture & Algorithm
The system operates in two distinct phases:
Ingestion: Documents are loaded, split into 500-character chunks using Recursive Character Splitting, and converted into 384-dimensional vectors.
Retrieval: When a tool is called, the system performs a Cosine Similarity search between the user's query vector and the document vectors stored in the local database.
Tech Stack
Layer | Technology |
Language | Python 3.10+ |
Protocol | FastMCP (Model Context Protocol SDK) |
Orchestration | LangChain |
Vector DB | ChromaDB (Persistent) |
Embeddings | Sentence-Transformers |
Project Structure
mcp-retrieval-engine/
├── data/ # Raw document storage (.pdf, .txt, .md)
├── chroma_db/ # Persistent vector database
├── src/
│ ├── main.py # MCP Server entry point and tool definitions
│ └── processor.py # RAG Engine: Chunking and Retrieval logic
└── pyproject.toml # Dependency management via uv
Getting Started
1. Installation
Ensure you have uv installed, then sync the environment:
uv sync
2. Ingesting Data
Place your documents in the /data directory and run the indexing tool through the MCP Inspector:
mcp inspector src/main.py
3. Claude Desktop Integration
Add the following to your claude_desktop_config.json:
{
"mcpServers": {
"local-retriever": {
"command": "python",
"args": ["/absolute/path/to/src/main.py"]
}
}
}
Impact
This project demonstrates the ability to build AI Infrastructure that solves data privacy and context window limitations in enterprise and academic workflows.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Private, multimodal knowledge store for agents: hybrid search with cited, provenance-backed results.
Ingest, manage, and retrieve documents for RAG-powered AI applications
Universal persistent memory and knowledge retrieval layer for AI agents and LLMs.
Persistent memory and knowledge management for AI agents with semantic search and 50+ tools.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables AI assistants to search and query PDF documents through a local RAG system with vector embeddings. Provides semantic document search capabilities while keeping all data stored locally without external dependencies.-
- FlicenseNot gradedqualityDmaintenanceEnables semantic search over local notes and documents using natural language queries. Supports multiple file types (Markdown, Python, HTML, JSON, CSV, text) with fast local embeddings and persistent ChromaDB vector storage.1-
- FlicenseNot gradedqualityDmaintenanceEnables semantic search across documents and code repositories using RAG (Retrieval-Augmented Generation) with vector embeddings. Automatically indexes PDF documents and performs relevance-scored lookups through ChromaDB and sentence transformers.-
- AlicenseNot gradedqualityDmaintenanceProvides token-efficient semantic search and document retrieval by indexing PDFs, text, and markdown files into local notebooks using ChromaDB. It enables AI agents to query relevant passages from large documents through local embedding models like Hugging Face or Ollama.1MIT