A Model Context Protocol (MCP) server that provides Retrieval-Augmented Generation (RAG) capabilities over the Epstein Files dataset from HuggingFace.
- 🔍 Semantic search over 20K+ Epstein Files documents
- 🚀 Runs entirely on CPU and RAM
- 💾 Vector storage on NVME via Qdrant Docker
- 🎯 Uses
all-MiniLM-L6-v2embedding model - 📦 Zero local files needed - run directly via
uv
- Docker - for running Qdrant
- UV - Python package manager
Install UV:
curl -LsSf https://astral.sh/uv/install.sh | sh# Create storage directory on your NVME
mkdir -p /path/to/nvme/qdrant_storage
# Run Qdrant
docker run -d \
--name qdrant \
-p 6333:6333 \
-p 6334:6334 \
-v /path/to/nvme/qdrant_storage:/qdrant/storage \
qdrant/qdrantAdd this to your MCP servers configuration (e.g., Claude Desktop config):
{
"mcpServers": {
"epstein-rag": {
"command": "uvx",
"args": [
"--from",
"git+https://github.com/justinlime/epstein-rag-mcp.git",
"epstein-rag-mcp"
],
"env": {
"QDRANT_HOST": "localhost",
"QDRANT_PORT": "6333"
}
}
}
}That's it! The server will automatically:
- Download and install dependencies
- Load the embedding model
- Fetch the dataset from HuggingFace (first run only)
- Create embeddings and index them in Qdrant
- Be ready to answer queries
Once configured, your LLM can use the search_epstein_files tool:
Example queries:
- "Find documents mentioning flight logs"
- "Search for references to specific individuals"
- "What documents discuss financial transactions?"
QDRANT_HOST- Qdrant server host (default:localhost)QDRANT_PORT- Qdrant server port (default:6333)
The first time you run the server, it will:
- Download the
all-MiniLM-L6-v2model (~80MB) - Fetch the Epstein Files dataset from HuggingFace (~100MB)
- Generate embeddings for all documents (10-30 minutes on CPU)
- Index them in Qdrant
Subsequent runs will be instant as the data is persisted in Qdrant.
git clone https://github.com/yourusername/epstein-rag-mcp.git
cd epstein-rag-mcp
uv pip install -e .uv run epstein-rag-mcp# View logs
docker logs qdrant
# Stop Qdrant
docker stop qdrant
# Start Qdrant
docker start qdrant
# Access web UI
# Open http://localhost:6333/dashboardMake sure the Docker container is running:
docker ps | grep qdrantChange the port mapping:
docker run -d --name qdrant -p 6335:6333 ...Then update QDRANT_PORT to 6335 in your config.
This is normal on CPU. The first run can take 10-30 minutes depending on your hardware. Reduce BATCH_SIZE in the code if you run out of memory.
┌─────────────┐
│ LLM Client │
└──────┬──────┘
│ MCP Protocol
│
┌──────▼──────────────────┐
│ epstein-rag-mcp │
│ ┌──────────────────┐ │
│ │ Sentence │ │
│ │ Transformer │ │
│ │ (all-MiniLM-L6) │ │
│ └─────────┬────────┘ │
│ │ │
│ ┌─────────▼────────┐ │
│ │ Dataset Loader │ │
│ │ (HuggingFace) │ │
│ └──────────────────┘ │
└────────┬─────────────────┘
│
┌────▼─────┐
│ Qdrant │
│ Docker │
└────┬─────┘
│
┌────▼─────┐
│ NVME │
└──────────┘
MIT
Contributions welcome! Please open an issue or PR.
- Dataset: tensonaut/EPSTEIN_FILES_20K
- Embedding Model: sentence-transformers/all-MiniLM-L6-v2
- Vector Store: Qdrant