Ai LocalBase
一个本地优先的AI知识库系统(RAG),用于把本地文档接入辅导搜索与大模型对话流程。目前支持md、txt、pdf(文本)、xlsx、cvs类型。支持mcp服务
What is Ai LocalBase?
Ai LocalBase is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to 一个本地优先的ai知识库系统(rag),用于把本地文档接入辅导搜索与大模型对话流程。目前支持md、txt、pdf(文本)、xlsx、cvs类型。支持mcp服务
一个本地优先的AI知识库系统(RAG),用于把本地文档接入辅导搜索与大模型对话流程。目前支持md、txt、pdf(文本)、xlsx、cvs类型。支持mcp服务
This server falls under the Knowledge & Memory category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- 一个本地优先的AI知识库系统(RAG),用于把本地文档接入辅导搜索与大模型对话流程。目前支持md、txt、pdf(文本)
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx ai-localbaseConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Ai LocalBase
AI LocalBase is a local-first RAG (Retrieval-Augmented Generation) knowledge base system that lets you ingest local documents — Markdown, plain text, PDF, Excel, and CSV files — and query them through semantic search and large language model conversations. It is built on Go (backend), React (frontend), and Qdrant (vector database), and exposes an MCP server endpoint so AI assistants like Claude can directly query your private knowledge base. The system supports both Ollama local models and OpenAI-compatible APIs, making it fully offline-capable for privacy-sensitive document collections.
Prerequisites
- Docker Desktop with Docker Compose v2+ installed (required for Qdrant vector database and full stack deployment)
- Go 1.21+ if running the backend outside Docker
- Node.js 18+ if running the frontend outside Docker
- An Ollama instance (http://localhost:11434) or an OpenAI-compatible API key for the LLM and embedding model
- An MCP-compatible client such as Claude Desktop to connect to the knowledge base
Clone the repository
Clone the AI LocalBase repository to your local machine.
git clone https://github.com/veyliss/ai-localbase.git
cd ai-localbaseConfigure environment variables
Copy the example environment file and configure it for your setup. Key variables include the Qdrant collection settings, whether to enable MCP (on by default), and your LLM provider credentials.
cp .env.example .env
# Edit .env and set:
# QDRANT_VECTOR_SIZE=1024 # must match embedding model dimensions
# QDRANT_COLLECTION_PREFIX=mydata
# ENABLE_MCP=true
# MCP_BASE_PATH=/mcp
# MCP_REQUESTS_PER_MINUTE=120Start the full stack with Docker Compose
Start Qdrant and the AI LocalBase backend and frontend using Docker Compose. For prebuilt images use the prod compose file.
docker compose up --buildUpload documents to the knowledge base
Open the frontend at http://localhost:3000 and use the upload interface to ingest your documents. Supported formats are .md, .txt, .pdf (text-based), .xlsx, and .csv. Documents are automatically chunked and embedded.
Add the MCP server to your AI client
Configure Claude Desktop to connect to the AI LocalBase MCP endpoint. The server uses Bearer token authentication; set the token you configured in .env.
{
"mcpServers": {
"ai-localbase": {
"url": "http://localhost:8080/mcp",
"headers": {
"Authorization": "Bearer your_mcp_token_here"
}
}
}
}Query your knowledge base through Claude
With the server connected, ask Claude questions about your uploaded documents. The MCP tools allow semantic search, document retrieval, and RAG-powered answers grounded in your local files.
Ai LocalBase Examples
Client configuration
Claude Desktop HTTP configuration for the AI LocalBase MCP endpoint with Bearer token authentication.
{
"mcpServers": {
"ai-localbase": {
"url": "http://localhost:8080/mcp",
"headers": {
"Authorization": "Bearer your_mcp_token_here"
}
}
}
}Prompts to try
Example prompts for querying your local knowledge base through Claude.
- "Search my knowledge base for documents about quarterly budget planning"
- "Summarize the key points from the PDF I uploaded about project requirements"
- "Find all spreadsheet data related to sales figures from Q3"
- "What does my internal documentation say about the deployment process?"Troubleshooting Ai LocalBase
QDRANT_VECTOR_SIZE mismatch causes embedding failures
The vector size in .env must exactly match the output dimensions of your embedding model. For bge-m3 use 1024, for nomic-embed-text use 768, for OpenAI text-embedding-3-small use 1536. If you change models, set QDRANT_COLLECTION_PREFIX to a new value to create a fresh collection and re-ingest documents.
MCP endpoint returns 401 Unauthorized
The AI LocalBase MCP server uses Bearer token authentication. Set the Authorization header in your MCP client config to 'Bearer <your_token>' where the token matches the one configured in your .env file under the MCP authentication settings.
Ollama embedding fails or is very slow
Ensure Ollama is running with 'ollama serve' and that the embedding model is pulled: 'ollama pull bge-m3' or 'ollama pull nomic-embed-text'. For large document batches, increase the MCP_REQUEST_TIMEOUT_SECONDS value in .env to avoid timeout errors during indexing.
Frequently Asked Questions about Ai LocalBase
What is Ai LocalBase?
Ai LocalBase is a Model Context Protocol (MCP) server that 一个本地优先的ai知识库系统(rag),用于把本地文档接入辅导搜索与大模型对话流程。目前支持md、txt、pdf(文本)、xlsx、cvs类型。支持mcp服务 It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Ai LocalBase?
Follow the installation instructions on the Ai LocalBase GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Ai LocalBase?
Ai LocalBase works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Ai LocalBase free to use?
Yes, Ai LocalBase is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
Ai LocalBase Alternatives — Similar Knowledge & Memory Servers
Looking for alternatives to Ai LocalBase? Here are other popular knowledge & memory servers you can use with Claude, Cursor, and VS Code.
MemPalace
★ 52.6kA local AI memory system that stores all conversations verbatim and organizes them into navigable structures. It provides 19 MCP tools for AI assistants to search and retrieve past decisions, debugging sessions, and architecture debates automatically
Kratos
★ 25.7k🏛️ Memory System for AI Coding Tools - Never explain your codebase again. MCP server with perfect project isolation, 95.8% context accuracy, and the Four Pillars Framework.
Context Mode
★ 15.4kAn MCP server that preserves LLM context by intercepting large data outputs and returning only concise summaries or relevant sections. It enables efficient sandboxed code execution, file processing, and documentation indexing across multiple programm
Memu
★ 13.7kMemory for 24/7 proactive agents like OpenClaw.
MemOS
★ 9.3kMemOS (Memory Operating System) is a memory management operating system designed for AI applications. Its goal is: to enable your AI system to have long-term memory like a human, not only remembering what users have said but also actively invoking, u
Everos
★ 5.4kBuild, evaluate, and integrate long-term memory for self-evolving agents.
Browse More Knowledge & Memory MCP Servers
Explore all knowledge & memory servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Ai LocalBase in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Ai LocalBase?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.