Local FAISS MCP Server — Claude Code MCP server for local RAG
An MCP server that keeps documents in a local FAISS vector index and answers queries by meaning. Useful when you want RAG without shipping files to a hosted service.
claude mcp add local-faiss-mcp -- uvx local-faiss-mcpWhat Local FAISS MCP Server does
Documents go in through the ingest_document tool: the server splits them into chunks, embeds each one and writes the vectors to a FAISS index. query_rag_store takes a plain-language question and returns the closest chunks with their sources. Everything persists on disk as {index-dir}/faiss.index plus {index-dir}/metadata.json, so a restart does not wipe your store.
A local-faiss CLI covers indexing and searching straight from the shell. Pick an embedding model with --embed; the default is all-MiniLM-L6-v2. Adding --rerank turns on a two-stage search — FAISS pulls extra candidates, a cross-encoder rescores them, and the default model is BAAI/bge-reranker-base. Two MCP prompts ship with it: extract-answer for cited answers and summarize-documents for a summary across retrieved chunks.
PDF, TXT and MD parse out of the box. DOCX, HTML, EPUB and other formats need pandoc installed — without it those files simply will not load. Python 3.10 or newer is required.
What it helps with
- pull one passage out of a pile of PDFs without scrolling through them
- build a document index that never leaves your machine
- get answers that point back to the exact source fragment
- wire document search into an agent over MCP
- reindex a folder of files from the terminal in one go
Example prompts for the agent
- Ingest
./docs/report.pdfwithingest_document - Use
query_rag_storeto find how FAISS does similarity search - Run the
extract-answerprompt over the retrieved chunks and cite the sources
How to install Local FAISS MCP Server
Platform CLI
claude mcp add local-faiss-mcp -- uvx local-faiss-mcpuvx runs the command named after the package; if the README names another one, use uvx --from local-faiss-mcp <command>
Platform CLI
codex mcp add local-faiss-mcp-server -- uvx local-faiss-mcpuvx runs the command named after the package; if the README names another one, use uvx --from local-faiss-mcp <command>
Config file
{
"mcpServers": {
"local-faiss-mcp-server": {
"command": "uvx",
"args": [
"local-faiss-mcp"
]
}
}
}uvx runs the command named after the package; if the README names another one, use uvx --from local-faiss-mcp <command>
Config file
{
"servers": {
"local-faiss-mcp-server": {
"type": "stdio",
"command": "uvx",
"args": [
"local-faiss-mcp"
]
}
}
}uvx runs the command named after the package; if the README names another one, use uvx --from local-faiss-mcp <command>
Platform CLI
gemini mcp add local-faiss-mcp-server uvx local-faiss-mcpuvx runs the command named after the package; if the README names another one, use uvx --from local-faiss-mcp <command>
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about Local FAISS MCP Server
How do I install Local FAISS MCP Server in Claude Code?
Run claude mcp add local-faiss-mcp -- uvx local-faiss-mcp. The tools become available in your session right after.
What does Local FAISS MCP Server do?
It stores documents in a local FAISS vector index and answers natural-language queries with matching chunks. No external service is involved.
Which document formats does it support?
PDF, TXT and MD work as-is. DOCX, HTML, EPUB and other formats require pandoc to be installed.