Local FAISS MCP Server
概要
作者による説明(英語の原文)
Local FAISS vector database for RAG with document ingestion, semantic search, and MCP prompts.
PopNx MCPの3つの柱
この3つを1つのスコアにまとめることはしません。意見、測定、人気はそれぞれ別のものだからです。
- 利用者の声iレビューはまだありませんレビューは今後のステップで、アカウント機能と一緒に始まります
- 私たちの基本チェックi1項目中1項目に合格公開情報からチェック。コードはまだスキャンしていません
- 利用状況iとても新しい↓ 39/週 · ★ –
できること
このサーバーのやさしい解説はまだ書いていません。以下はレジストリから読み取った事実です。
- 接続方法: パソコンで動く
- トランスポート: stdio
- カテゴリ: 検索・AIの記憶
インストール
使っているAIアプリを選んで、設定をコピーしてください。
インストールの前に
- 基本チェック:1項目中1項目に合格
- あなたのパソコンで、あなたのユーザーと同じ権限(ファイル、ネットワーク、アプリ)で動きます。
- レジストリには、入力が必要なキーは載っていません。
必要なもの
- PyPIPythonのuvのインストール(uvxコマンドに必要)
どのアプリを使っていますか?
上でアプリを選んでください。選んだアプリを覚えておくので、次からはボタンに「…にインストール」と表示されます。
Claude Desktop → Settings → Developer → Edit Config を開き、claude_desktop_config.json にこれを貼り付けます
{
"mcpServers": {
"local-faiss": {
"command": "uvx",
"args": [
"local-faiss-mcp"
]
}
}
}ターミナルでこれを実行します
claude mcp add local-faiss -- uvx local-faiss-mcpまたは、設定を自分でコピーする
プロジェクトの .cursor/mcp.json、または ~/.cursor/mcp.json に貼り付けます
{
"mcpServers": {
"local-faiss": {
"command": "uvx",
"args": [
"local-faiss-mcp"
]
}
}
}ブラウザがアプリを開いてよいか確認し、そのあとアプリが設定を表示して確認を求めます。キーの値は空欄のままなので、自分で入力してください。
または、設定を自分でコピーする
プロジェクトの .vscode/mcp.json に貼り付けます
{
"servers": {
"local-faiss": {
"type": "stdio",
"command": "uvx",
"args": [
"local-faiss-mcp"
]
}
}
}ブラウザがアプリを開いてよいか確認し、そのあとアプリが設定を表示して確認を求めます。キーの値は空欄のままなので、自分で入力してください。
これはパソコンで動くサーバーですが、ChatGPTがつなげるのはインターネット上のサーバーだけです。ほかのアプリを選んでください。
選んだアプリは、この端末のCookieに保存されます。アカウントは不要です。
この設定は、作者のレジストリ登録情報から作成しています。READMEと違う場合は、READMEに従ってください。
できること
パソコンで動くサーバーです。インストールすると、ツール一覧がAIアプリに表示されます。
基本チェックi
誰でも見られる情報をチェックしており、コードは読んでいません。当てはまらない項目は数に入れていません。 · 2026年11月8日にチェック
- ✓ 合格
作者とリポジトリが一致
レジストリ名は、リポジトリを所有するGitHubアカウント nonatofabio で確認済みです
- … 未チェック
今もメンテナンスされている
このリポジトリはまだGitHubから読み取っていません
- … 未チェック
ライセンスがある
このリポジトリはまだGitHubから読み取っていません
- – 対象外
エンドポイントが応答する
これはパソコンで動くため、インターネット上のエンドポイントはありません
- – 対象外
OAuthでサインイン
パソコンで動き、代わりにローカルの設定を使います
- … 未チェック
ツールの説明に隠れた指示がない
パソコンで動くサーバーです。ツール一覧を読み取れるのは、インターネット上のエンドポイントがある場合だけです
検索・AIの記憶のほかのサーバーとの比較i
- このカテゴリのほかの5716件のうち0%よりスターが多い
- このカテゴリのほかの5716件のうち1%より最近レジストリに公開
- 基本チェックの結果が、このカテゴリのほかの5716件のうち100%と同じかそれ以上
レジストリでこのカテゴリにある有効なすべてのサーバーと比較しています。スターは、公開者がリポジトリの所有者である場合だけ数えます。
よくある質問
Local FAISS MCP Serverは安全ですか?
当てはまる基本チェック1項目のうち1項目に合格しました。コードは読んでいません。キーやトークンを追加する前に、サーバーがどんなアクセスを求めているかを確認し、必要な権限だけを持つキーを使ってください。
どんなキーやコードが必要ですか?
レジストリには必須のキーは載っていません。ただし、最初に使うときにサインインを求めるサーバーもあります。
パソコンで動きますか、それともクラウドですか?
あなたのパソコンで動きます。必要なときにAIアプリが起動し、データは作者のサーバーを通りません(サーバー自体がオンラインサービスを呼び出す場合を除きます)。
今もメンテナンスされていますか?
GitHubリポジトリの最終更新は–、最新バージョン(0.2.0-rc.3)がレジストリに届いたのは11 か月前です。
どのアプリで使えますか?
Claude Desktop、Claude Code、Cursor、VS CodeなどのMCP対応アプリで使えます。パソコンにPython (uv)も必要です。
代わりに使えるものは?
同じカテゴリには:Context7, Codebase Memory, Exa
代わりの候補
同じカテゴリで、ほかの作者が作ったサーバー。スターの多い順。
カードの見方:↓ 週あたりのダウンロードi★ GitHubスターi3つの柱:レビュー · チェック · 利用状況i更新=最新バージョンをレジストリに公開した日i
Codebase Memory
Codebase knowledge graph for AI agents — 162 languages, sub-ms queries, 99% fewer tokens.
Exa
Connect AI agents to Exa for web search, content fetching, and multi-step research.
作者のREADME
READMEを開く
作者のリポジトリから書かれたとおりにコピーしたものです。PopNx MCPは内容を確認・推奨していません。HTML、画像、スクリプトは取り除いています。リンクはこのサイトの外へ移動します。
Local FAISS MCP Server
A Model Context Protocol (MCP) server that provides local vector database functionality using FAISS for Retrieval-Augmented Generation (RAG) applications.
Features
Core Capabilities
- Local Vector Storage: Uses FAISS for efficient similarity search without external dependencies
- Document Ingestion: Automatically chunks and embeds documents for storage
- Semantic Search: Query documents using natural language with sentence embeddings
- Persistent Storage: Indexes and metadata are saved to disk
- MCP Compatible: Works with any MCP-compatible AI agent or client
v0.2.0 Highlights
- CLI Tool:
local-faisscommand for standalone indexing and search - Document Formats: Native PDF/TXT/MD support, DOCX/HTML/EPUB with pandoc
- Re-ranking: Two-stage retrieve and rerank for better results
- Custom Embeddings: Choose any Hugging Face embedding model
- MCP Prompts: Built-in prompts for answer extraction and summarization
Quickstart
# Install
pip install local-faiss-mcp
Index documents
local-faiss index document.pdf
Search
local-faiss search "What is this document about?"
Or use with Claude Code - configure MCP client (see Configuration) and try:
Use the ingest_document tool with: ./path/to/document.pdf
Then use query_rag_store to search for: "How does FAISS perform similarity search?"
Claude will retrieve relevant document chunks from your vector store and use them to answer your question.
Installation
⚡️ Upgrading? Run pip install --upgrade local-faiss-mcp
From PyPI (Recommended)
pip install local-faiss-mcp
Optional: Extended Format Support
For DOCX, HTML, EPUB, and 40+ additional formats, install pandoc:
# macOS
brew install pandoc
Linux
sudo apt install pandoc
Or download from: https://pandoc.org/installing.html
Note: PDF, TXT, and MD work without pandoc.
From Source
git clone https://github.com/nonatofabio/local_faiss_mcp.git
cd local_faiss_mcp pip install -e .
Usage
Running the Server
After installation, you can run the server in three ways:
1. Using the installed command (easiest):
local-faiss-mcp --index-dir /path/to/index/directory
2. As a Python module:
python -m local_faiss_mcp --index-dir /path/to/index/directory
3. For development/testing:
python local_faiss_mcp/server.py --index-dir /path/to/index/directory
Command-line Arguments:
--index-dir: Directory to store FAISS index and metadata files (default: current directory)--embed: Hugging Face embedding model name (default:all-MiniLM-L6-v2)--rerank: Enable re-ranking with specified cross-encoder model (default:BAAI/bge-reranker-base)
Using a Custom Embedding Model:
# Use a larger, more accurate model
local-faiss-mcp --index-dir ./.vector_store --embed all-mpnet-base-v2
Use a multilingual model
local-faiss-mcp --index-dir ./.vector_store --embed paraphrase-multilingual-MiniLM-L12-v2
Use any Hugging Face sentence-transformers model
local-faiss-mcp --index-dir ./.vector_store --embed sentence-transformers/model-name
Using Re-ranking for Better Results:
Re-ranking uses a cross-encoder model to reorder FAISS results for improved relevance. This two-stage "retrieve and rerank" approach is common in production search systems.
# Enable re-ranking with default model (BAAI/bge-reranker-base)
local-faiss-mcp --index-dir ./.vector_store --rerank
Use a specific re-ranking model
local-faiss-mcp --index-dir ./.vector_store --rerank cross-encoder/ms-marco-MiniLM-L-6-v2
Combine custom embedding and re-ranking
local-faiss-mcp --index-dir ./.vector_store --embed all-mpnet-base-v2 --rerank BAAI/bge-reranker-base
How Re-ranking Works:
- FAISS retrieves top candidates (10x more than requested)
- Cross-encoder scores each candidate against the query
- Results are re-sorted by relevance score
- Top-k most relevant results are returned
Popular re-ranking models:
BAAI/bge-reranker-base- Good balance (default)cross-encoder/ms-marco-MiniLM-L-6-v2- Fast and efficientcross-encoder/ms-marco-TinyBERT-L-2-v2- Very fast, smaller model
The server will:
- Create the index directory if it doesn't exist
- Load existing FAISS index from
{index-dir}/faiss.index(or create a new one) - Load document metadata from
{index-dir}/metadata.json(or create new) - Listen for MCP tool calls via stdin/stdout
Available Tools
The server provides two tools for document management:
1. ingest_document
Ingest a document into the vector store.
Parameters:
document(required): Text content OR file path to ingestsource(optional): Identifier for the document source (default: "unknown")
Auto-detection: If document looks like a file path, it will be automatically parsed.
Supported formats:
- Native: TXT, MD, PDF
- With pandoc: DOCX, ODT, HTML, RTF, EPUB, and 40+ formats
Examples:
{
"document": "FAISS is a library for efficient similarity search...", "source": "faiss_docs.txt" }
{
"document": "./documents/research_paper.pdf" }
2. query_rag_store
Query the vector store for relevant document chunks.
Parameters:
query(required): The search query texttop_k(optional): Number of results to return (default: 3)
Example:
{
"query": "How does FAISS perform similarity search?", "top_k": 5 }
Available Prompts
The server provides MCP prompts to help extract answers and summarize information from retrieved documents:
1. extract-answer
Extract the most relevant answer from retrieved document chunks with proper citations.
Arguments:
query(required): The original user query or questionchunks(required): Retrieved document chunks as JSON array with fields:text,source,distance
Use Case: After querying the RAG store, use this prompt to get a well-formatted answer that cites sources and explains relevance.
Example workflow in Claude:
- Use
query_rag_storetool to retrieve relevant chunks - Use
extract-answerprompt with the query and results - Get a comprehensive answer with citations
2. summarize-documents
Create a focused summary from multiple document chunks.
Arguments:
topic(required): The topic or theme to summarizechunks(required): Document chunks to summarize as JSON arraymax_length(optional): Maximum summary length in words (default: 200)
Use Case: Synthesize information from multiple retrieved documents into a concise summary.
Example Usage:
In Claude Code, after retrieving documents with query_rag_store, you can use the prompts like:
Use the extract-answer prompt with:
- query: "What is FAISS?"
- chunks: [the JSON results from query_rag_store]
The prompts will guide the LLM to provide structured, citation-backed answers based on your vector store data.
Command-Line Interface
The local-faiss CLI provides standalone document indexing and search capabilities.
Index Command
Index documents from the command line:
# Index single file
local-faiss index document.pdf
Index multiple files
local-faiss index doc1.pdf doc2.txt doc3.md
Index all files in folder
local-faiss index documents/
Index recursively
local-faiss index -r documents/
Index with glob pattern
local-faiss index "docs/**/*.pdf"
Configuration: The CLI automatically uses MCP configuration from:
./.mcp.json(local/project-specific)~/.claude/.mcp.json(Claude Code config)~/.mcp.json(fallback)
If no config exists, creates ./.mcp.json with default settings (./.vector_store).
Supported formats:
- Native: TXT, MD, PDF (always available)
- With pandoc: DOCX, ODT, HTML, RTF, EPUB, etc.
- Install:
brew install pandoc(macOS) orapt install pandoc(Linux)
Search Command
Search the indexed documents:
# Basic search
local-faiss search "What is FAISS?"
Get more results
local-faiss search -k 5 "similarity search algorithms"
Results show:
- Source file path
- FAISS distance score
- Re-rank score (if enabled in MCP config)
- Text preview (first 300 characters)
CLI Features
- ✅ Incremental indexing: Adds to existing index, doesn't overwrite
- ✅ Progress output: Shows indexing progress for each file
- ✅ Shared config: Uses same settings as MCP server
- ✅ Auto-detection: Supports glob patterns and recursive folders
- ✅ Format support: Handles PDF, TXT, MD natively; DOCX+ with pandoc
Configuration with MCP Clients
Claude Code
Add this server to your Claude Code MCP configuration (.mcp.json):
User-wide configuration (~/.claude/.mcp.json):
{
"mcpServers": { "local-faiss-mcp": { "command": "local-faiss-mcp" } } }
With custom index directory:
{
"mcpServers": { "local-faiss-mcp": { "command": "local-faiss-mcp", "args": [ "--index-dir", "/home/user/vector_indexes/my_project" ] } } }
With custom embedding model:
{
"mcpServers": { "local-faiss-mcp": { "command": "local-faiss-mcp", "args": [ "--index-dir", "./.vector_store", "--embed", "all-mpnet-base-v2" ] } } }
With re-ranking enabled:
{
"mcpServers": { "local-faiss-mcp": { "command": "local-faiss-mcp", "args": [ "--index-dir", "./.vector_store", "--rerank" ] } } }
Full configuration with embedding and re-ranking:
{
"mcpServers": { "local-faiss-mcp": { "command": "local-faiss-mcp", "args": [ "--index-dir", "./.vector_store", "--embed", "all-mpnet-base-v2", "--rerank", "BAAI/bge-reranker-base" ] } } }
Project-specific configuration (./.mcp.json in your project):
{
"mcpServers": { "local-faiss-mcp": { "command": "local-faiss-mcp", "args": [ "--index-dir", "./.vector_store" ] } } }
Alternative: Using Python module (if the command isn't in PATH):
{
"mcpServers": { "local-faiss-mcp": { "command": "python", "args": ["-m", "local_faiss_mcp", "--index-dir", "./.vector_store"] } } }
Claude Desktop
Add this server to your Claude Desktop configuration:
{
"mcpServers": { "local-faiss-mcp": { "command": "local-faiss-mcp", "args": ["--index-dir", "/path/to/index/directory"] } } }
Architecture
- Embedding Model: Configurable via
--embedflag (default:all-MiniLM-L6-v2with 384 dimensions) - Supports any Hugging Face sentence-transformers model
- Automatically detects embedding dimensions
- Model choice persisted with the index
- Index Type: FAISS IndexFlatL2 for exact L2 distance search
- Chunking: Documents are split into ~500 word chunks with 50 word overlap
- Storage: Index saved as
faiss.index, metadata saved asmetadata.json
Choosing an Embedding Model
Different models offer different trade-offs:
| Model | Dimensions | Speed | Quality | Use Case |
|---|
| all-MiniLM-L6-v2
冒頭だけを表示しています。続きはリポジトリで読めます