MCP-RAG-Assistant
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP-RAG-AssistantWhat is gradient descent?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP-RAG-Assistant
A hybrid Retrieval-Augmented Generation pipeline that indexes documents and exposes them via an MCP (Model Context Protocol) server. Designed to feed relevant context to an external LLM (e.g., opencode CLI), acting as your intelligent knowledge assistant.
Comes pre-bundled with a curated corpus of 30 Data Science tutorials covering ML, Deep Learning, NLP, Computer Vision, and more — ready to index and query out of the box.
Architecture
Documents ──► Ingestion ──► ChromaDB (vector store)
│ │
Chunking Hybrid Search
Embeddings ┌────┴────┐
Vector BM25
└──┬───┘
RRF Fusion
│
Cross-encoder
│
Results ──► MCP Server ──► LLMRelated MCP server: RAG-MCP
Quickstart
Prerequisites
Python 3.11+
Virtual environment
Setup
# Create and activate virtual environment
python -m venv venv
# Windows
venv\Scripts\activate
# Linux / macOS
source venv/bin/activate
# Install dependencies
pip install -r requirements.txt
# (Optional) Install in dev mode for test dependencies
pip install -e .[dev]Index Documents
Place your documents in rag/documents/ (supports: .md, .txt, .pdf, .docx, .xlsx, .pptx, .html, images, and more).
# Index all documents
python -m rag ingest
# Or run the ingestion script directly
python rag/ingestion.pyExample output:
2026-07-28 [INFO] Indexing documents...
2026-07-28 [INFO] Processing Day 1.md
2026-07-28 [INFO] └─ 8 chunk(s)
2026-07-28 [INFO] Processing Day 2.md
2026-07-28 [INFO] └─ 6 chunk(s)
...
2026-07-28 [INFO] Indexing complete — 247 total chunk(s) in collectionNote: The first run will download the
all-MiniLM-L6-v2embedding model (~80 MB). Subsequent runs use only new/changed files.
Start the MCP Server
python mcp-servers/rag-mcp/server.pyThe MCP server exposes a search_company_knowledge tool that returns relevant context chunks for any natural-language question.
Search (Interactive)
python -m rag searchExample session:
RAG interactive search — type :q to quit.
query> What is the difference between AI and ML?
Artificial Intelligence (AI) is the broad field of creating machines that...
query> :qEvaluate Retrieval
python -m rag evaluate
# With cross-encoder reranking:
python -m rag evaluate --rerankExample output:
MRR = 0.8923
Recall@1 = 0.8276
Recall@3 = 0.9655
Recall@5 = 1.0000Run Tests
pytest
# With verbose output
pytest -v
# With coverage
pip install pytest-cov
pytest --cov=rag tests/Automated Startup
# Windows
start_rag.bat
# Linux / macOS
bash scripts/start.shBoth scripts activate the virtual environment, install/verify dependencies, index documents, and start the MCP server.
Project Structure
├── rag/ # Core RAG library
│ ├── __init__.py # Package init
│ ├── __main__.py # CLI entry point (python -m rag)
│ ├── settings.py # Central configuration
│ ├── ingestion.py # Document indexing pipeline
│ ├── retrieval.py # Hybrid search (vector + BM25 + reranker)
│ ├── evaluate.py # Retrieval evaluation (MRR, Recall@K)
│ ├── chroma_db/ # Persistent vector store (gitignored)
│ ├── documents/ # Place your documents here
│ │ └── 30 days md/ # Pre-bundled Data Science tutorials (29 Q&A test cases)
│ └── test_set.json # Curated Q&A test cases
├── mcp-servers/
│ └── rag-mcp/
│ └── server.py # MCP server exposing search tool
├── tests/ # Test suite (pytest)
│ ├── test_ingestion.py
│ ├── test_retrieval.py
│ └── test_evaluate.py
├── scripts/
│ └── start.sh # Linux/macOS startup script
├── start_rag.bat # Windows startup script
├── pyproject.toml # Project metadata & packaging
├── requirements.txt # Python dependencies
├── .gitignore
└── README.mdKey Features
Hybrid search: Semantic (vector) + keyword (BM25) fused via Reciprocal Rank Fusion
Cross-encoder reranker: Optional precision boost with
cross-encoder/ms-marco-MiniLM-L-6-v2Incremental indexing: Only processes new/changed files; prunes deleted file chunks
Multi-format support: Plain text (
.md,.txt,.py, etc.) + structured docs (.pdf,.docx,.xlsx, images) via DoclingMCP-native: Exposed as a standard MCP tool — works with any MCP host (IDEs, agents, CLIs)
Configurable: All tunable parameters in
rag/settings.pyEvaluation suite: 29 curated Q&A test cases with MRR and Recall@K metrics
Dependencies
Package | Purpose |
| Vector store |
| Embeddings & cross-encoder |
| Document parsing (PDF, DOCX, images) |
| Keyword search |
| Model Context Protocol server |
License
This project is licensed under the MIT License. See the LICENSE file for details.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Alicense-qualityDmaintenanceAn MCP server that indexes documents and serves relevant context to LLMs via Retrieval Augmented Generation (RAG).Last updated3736MIT
- Flicense-qualityDmaintenanceA Retrieval Augmented Generation MCP server that ingests documents into a local vector database and enables semantic search queries.Last updated9
- Alicense-qualityBmaintenanceMCP server for local RAG over personal notes, PDFs, and documents, enabling plain-English querying and hybrid search with multi-hop context expansion.Last updatedMIT
- AlicenseAqualityBmaintenanceAn MCP server that provides semantic search over a document corpus, enabling AI clients to retrieve and cite relevant chunks from indexed documents via RAG pipelines.Last updated4MIT
Related MCP Connectors
Apple Developer Documentation with Semantic Search, RAG, and AI reranking for MCP clients
Semantic search across 50,000+ food recipes with hybrid retrieval and reranking.
Remote ChromaDB vector database MCP server with streamable HTTP transport
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/mohankumar-dxplr/MCP-RAG-Assistant'
If you have feedback or need assistance with the MCP directory API, please join our Discord server