RAG Chatbot MCP Server
Uses Ollama to run local LLM and embedding models for the RAG chatbot, enabling fully local document question answering without API keys.
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., "@RAG Chatbot MCP Serverask: What are the key points from the meeting notes?"
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.
RAG Chatbot
A small numpy-based vector index (vector_store.py) over your own documents — no compiled/native
dependencies beyond numpy, so it needs no admin rights to install. The LLM/embeddings backend is
pluggable via config.LLM_PROVIDER: "ollama" (100% local, no API key) or "gemini" (Google's
cloud API, needs a free key).
Setup
Provider: Gemini (config.py → LLM_PROVIDER = "gemini", the current default)
Get a free API key from Google AI Studio.
Set it as an environment variable (don't paste it into files or commit it):
# macOS/Linux
export GOOGLE_API_KEY="your-key-here"# Windows PowerShell
$env:GOOGLE_API_KEY = "your-key-here"Provider: Ollama (set LLM_PROVIDER = "ollama" in config.py)
Install Ollama and pull the models used:
ollama pull nomic-embed-text
ollama pull llama3.1Then, for either provider, install Python dependencies:
pip install -r requirements.txtRelated MCP server: vectorise-mcp
Usage — CLI
Drop your files (
.pdf,.txt,.md,.docx,.csv,.xlsx) into thedocs/folder.Build the index:
python ingest.pyChat:
python chat.pyType exit to quit.
Usage — Web app (frontend + backend)
Runs a FastAPI backend that serves a JSON API and a static chat UI, all on one port.
python -m uvicorn server:app --reload --port 8000Open http://localhost:8000 in a browser. From there you can:
Upload files (drag/select, click Upload)
Click Rebuild Index to (re)embed everything currently in
docs/Chat in the main panel — answers include source file names
API endpoints, if you want to script against it directly:
GET /api/status— index/model infoPOST /api/upload— multipart file upload, saved intodocs/POST /api/ingest— rebuilds the index fromdocs/POST /api/chat—{"question": "..."}→{"answer": "...", "sources": [...]}
Usage — MCP server
Exposes the document index as MCP tools (ask, search, rebuild_index, status) so any
MCP client (Claude Desktop, Claude Code, etc.) can query your docs. Runs over stdio - the
client launches it as a subprocess, no port involved.
Add it to your MCP client config, e.g. Claude Desktop's claude_desktop_config.json:
{
"mcpServers": {
"rag-chatbot": {
"command": "python",
"args": ["C:/Users/Nikita_Admin/Desktop/mcm/rag-chatbot/mcp_server.py"]
}
}
}For Claude Code, run:
claude mcp add rag-chatbot -- python C:/Users/Nikita_Admin/Desktop/mcm/rag-chatbot/mcp_server.pyRestart the client afterward. The index must already exist (python ingest.py), or call the
rebuild_index tool from within the chat once files are in docs/.
Notes
Re-run
python ingest.pyafter adding/changing files indocs/. It rebuildsindex.npzfrom scratch each time.Change models or chunking behavior in
config.py.Larger/more capable local models (e.g.
llama3.1:70b,mixtral) give better answers but need more RAM/VRAM — swapLLM_MODELinconfig.py.The vector index is a single
index.npzfile (numpy arrays + JSON), fine for personal/small document sets. For large corpora, swapvector_store.pyfor a proper vector DB.
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-qualityDmaintenanceIndexes local files (PDF, TXT, CSV, Markdown) with embeddings for semantic search. Provides both CLI and MCP server interfaces so Claude Desktop can search and read your local documents.Last updatedMIT
- Alicense-qualityCmaintenanceLocal MCP server that indexes folders of documents into a hybrid vector + keyword search index for Claude Desktop, with support for PDFs, Office files, and images via OCR.Last updatedMIT
- FlicenseCqualityCmaintenanceProvides RAG tools with local vector retrieval and web fallback using Firecrawl, enabling document ingestion and querying through MCP stdio transport.Last updated3
- Flicense-qualityCmaintenanceProvides a local MCP server for Claude Code to retrieve relevant documentation slices from a repository's auto-generated reference docs using hybrid search (vector + BM25).Last updated
Related MCP Connectors
Local-first RAG engine with MCP server for AI agent integration.
Serve a folder of Markdown notes as an MCP server: hybrid search, reading, and sourced answers.
Agent-native MCP server over the public saagarpatel.dev corpus. Read-only, stateless.
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/ansh-7666/AI-Based-Chatbot'
If you have feedback or need assistance with the MCP directory API, please join our Discord server