PluginBench
MCP Server
Active
MIT

io.github.andrea9293/mcp-documentation-server MCP Server

io.github.andrea9293/mcp-documentation-server

Local-first document storage and semantic search with a built-in web dashboard—no cloud DB required.

What is the io.github.andrea9293/mcp-documentation-server MCP server?

The MCP Documentation Server is a local-first document management and semantic search server for AI coding agents. It lets agents add, search, and manage a knowledge base of text, markdown, and PDF documents using a local Orama vector database and Transformers.js embeddings, with no external cloud database required. It also ships a built-in web dashboard (port 3080) and mirrors every MCP tool as a REST API.

MCP Documentation Server gives AI coding agents a self-contained knowledge base: documents (.txt, .md, .pdf) are chunked using a parent-child strategy and embedded locally via Transformers.js, then stored in an on-disk Orama vector database. Agents can add, list, retrieve, and delete documents, process uploaded files, and run hybrid full-text + vector search across the whole library or within a single document, optionally pulling in surrounding context chunks. It runs entirely offline by default, includes a web UI for browsing and uploading documents, exposes every tool as a REST API to avoid loading MCP schemas into the agent's context, and optionally supports Gemini-powered AI search when an API key is provided.

How to install io.github.andrea9293/mcp-documentation-server

Copy-paste configuration for popular MCP clients.

transport: stdio
Config generated by PluginBench — verify against the source before use.
Claude Desktop
~/Library/Application Support/Claude/claude_desktop_config.json
{
  "mcpServers": {
    "mcp-documentation-server": {
      "command": "npx",
      "args": [
        "-y",
        "@andrea9293/mcp-documentation-server"
      ]
    }
  }
}
Cursor
~/.cursor/mcp.json
{
  "mcpServers": {
    "mcp-documentation-server": {
      "command": "npx",
      "args": [
        "-y",
        "@andrea9293/mcp-documentation-server"
      ]
    }
  }
}
Windsurf
~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "mcp-documentation-server": {
      "command": "npx",
      "args": [
        "-y",
        "@andrea9293/mcp-documentation-server"
      ]
    }
  }
}
VS Code
.vscode/mcp.json
{
  "servers": {
    "mcp-documentation-server": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@andrea9293/mcp-documentation-server"
      ]
    }
  }
}
Claude Code
claude mcp add mcp-documentation-server -- npx -y @andrea9293/mcp-documentation-server

Tools & capabilities

Tools this server exposes to the agent.

  • add_documentAdd a document (title, content, optional metadata)
  • list_documentsList all documents with metadata and content preview
  • get_documentRetrieve the full content of a document by ID
  • delete_documentRemove a document, its chunks, database entries, and associated files
  • process_uploadsProcess all files in the uploads folder (chunking + embeddings)
  • get_uploads_pathReturns the absolute path to the uploads folder
  • list_uploads_filesLists files in the uploads folder with size and format info
  • get_ui_urlReturns the Web UI URL, useful to open the dashboard or locate the uploads folder from the browser
  • search_documentsSemantic vector search within a specific document
  • search_all_documentsHybrid (full-text + vector) cross-document search
  • get_context_windowReturns a window of chunks around a given chunk index
  • search_documents_with_aiAI-powered search using Gemini (requires GEMINI_API_KEY)

Use cases

  • Build a local, offline-searchable knowledge base for a project's documentation
  • Drag-and-drop upload of .txt/.md/.pdf files and query them semantically from an AI agent
  • Give an LLM broader context by fetching neighboring chunks around a matched search result
  • Search across an entire document library or within a single document using hybrid full-text + vector search
  • Use Gemini-powered AI search for deeper document analysis when an API key is configured

io.github.andrea9293/mcp-documentation-server MCP server FAQ

What does the MCP Documentation Server do?

It provides local document management and semantic search for AI coding agents: adding, listing, retrieving, and deleting documents, processing uploaded files, and running hybrid (full-text + vector) search, all backed by a local Orama vector database and local embeddings — no cloud database required.

Is it free to use?

Yes, it's free and open source (MIT license) and runs fully offline using local embeddings. Optional Gemini-powered AI search requires bringing your own Google Gemini API key.

How do I install it in Cursor or Claude?

Add it as an MCP server using npx: configure your client's mcpServers with command 'npx' and args ['-y', '@andrea9293/mcp-documentation-server']. No cloning or manual build is required.

What authentication is required?

None for core functionality — it runs fully offline. Setting GEMINI_API_KEY as an environment variable is optional and only needed to enable the search_documents_with_ai tool.

Does it include a user interface?

Yes, a full web dashboard starts automatically on port 3080 alongside the MCP server, letting you browse, search, upload, and manage documents from the browser, and every MCP tool is also exposed as a REST API.

What file types can it process?

It supports .txt, .md, and .pdf files, which can be dropped into the uploads folder and processed with the process_uploads tool (chunking plus embedding generation).

README (reference)

Source of truth, from the repository.

MCP Registry npm version GitHub Stars License: MIT Ask DeepWiki

Donate with PayPal "Buy Me A Coffee"

MCP Documentation Server

Local-first document management and semantic search for AI coding agents. No external databases, no cloud APIs, no vendor lock-in.

Unlike other MCP servers that are CLI-only, this one ships with a full web dashboard — browse, search, upload, and manage your knowledge base from your browser. Every MCP tool is also exposed as a REST API, giving AI agents a lean, schema-free interface.

  • 🏠 Runs fully offline — Orama vector DB with local AI embeddings (Transformers.js)
  • 🌐 Built-in Web UI — starts automatically on port 3080 alongside the MCP server
  • 🔍 Hybrid search — full-text + vector similarity with parent-child chunking
  • 🤖 Optional AI search — Google Gemini for advanced document analysis (bring your own key)
  • 📁 Drag & drop uploads.txt, .md, .pdf support
  • 📦 Published on the MCP Registry — installable via npx, no clone needed

Quick Start

{
  "mcpServers": {
    "documentation": {
      "command": "npx",
      "args": ["-y", "@andrea9293/mcp-documentation-server"]
    }
  }
}

Open your browser at http://localhost:3080 — the web UI starts automatically.

🤖 Agent Skill (REST API) — recommended for AI agents

Every MCP tool is also accessible via the REST API on http://127.0.0.1:3080/api/. This is the recommended way to interact from AI agents (Claude Code, OpenCode, Gemini CLI, Cursor) because it avoids loading MCP tool schemas into the conversation context — only the response JSON enters.

curl -s http://127.0.0.1:3080/api/config
curl -s http://127.0.0.1:3080/api/documents
curl -s -X POST http://127.0.0.1:3080/api/search-all \
  -H "Content-Type: application/json" \
  -d '{"query": "your search", "limit": 5}'

A ready-to-use skill is included at skills/documentation-server/SKILL.md — it teaches your agent every endpoint with examples. Install it:

npx skills add https://github.com/andrea9293/mcp-documentation-server --skill documentation-server

Basic workflow

  1. Add documents using add_document or place .txt / .md / .pdf files in the uploads folder and call process_uploads.
  2. Search across everything with search_all_documents, or within a single document with search_documents.
  3. Use get_context_window to fetch neighboring chunks and give the LLM broader context.

Web UI

The web interface starts automatically on port 3080 when the MCP server launches. From the web UI you can:

  • 📊 Dashboard — overview of all documents and stats
  • 📄 Documents — browse, view, and delete documents
  • Add Document — create documents with title, content, and metadata
  • 🔍 Search All — semantic search across all documents
  • 🎯 Search in Doc — search within a specific document
  • 🤖 AI Search — Gemini-powered analysis (if GEMINI_API_KEY is set)
  • 📁 Upload Files — drag & drop files and process them into the knowledge base
  • 🪟 Context Window — explore chunks around a specific index

Configure an MCP client

Minimal

{
  "mcpServers": {
    "documentation": {
      "command": "npx",
      "args": ["-y", "@andrea9293/mcp-documentation-server"]
    }
  }
}

With environment variables (all optional)

{
  "mcpServers": {
    "documentation": {
      "command": "npx",
      "args": ["-y", "@andrea9293/mcp-documentation-server"],
      "env": {
        "MCP_BASE_DIR": "/path/to/workspace",
        "GEMINI_API_KEY": "your-api-key-here",
        "MCP_EMBEDDING_MODEL": "Xenova/all-MiniLM-L6-v2",
        "START_WEB_UI": "true",
        "WEB_HOST": "127.0.0.1",
        "WEB_PORT": "3080"
      }
    }
  }
}

All environment variables are optional. Without GEMINI_API_KEY, only the local embedding-based search tools are available.

MCP Tools

The server registers the following tools (all validated with Zod schemas):

📄 Document Management

ToolDescription
add_documentAdd a document (title, content, optional metadata)
list_documentsList all documents with metadata and content preview
get_documentRetrieve the full content of a document by ID
delete_documentRemove a document, its chunks, database entries, and associated files

📁 File Processing

ToolDescription
process_uploadsProcess all files in the uploads folder (chunking + embeddings)
get_uploads_pathReturns the absolute path to the uploads folder
list_uploads_filesLists files in the uploads folder with size and format info
get_ui_urlReturns the Web UI URL (e.g. http://localhost:3080) — useful to open the dashboard or to locate the uploads folder from the browser

🔍 Search

ToolDescription
search_documentsSemantic vector search within a specific document
search_all_documentsHybrid (full-text + vector) cross-document search
get_context_windowReturns a window of chunks around a given chunk index
search_documents_with_ai🤖 AI-powered search using Gemini (requires GEMINI_API_KEY)

Configuration

Configure via environment variables or a .env file in the project root:

VariableDefaultDescription
MCP_BASE_DIR~/.mcp-documentation-serverBase directory for data storage
MCP_EMBEDDING_MODELXenova/all-MiniLM-L6-v2Embedding model name
GEMINI_API_KEYGoogle Gemini API key (enables search_documents_with_ai)
MCP_CACHE_ENABLEDtrueEnable/disable LRU embedding cache
START_WEB_UItrueSet to false to disable the built-in web interface
WEB_HOST127.0.0.1Bind address for the web UI (use 0.0.0.0 to expose on all interfaces)
WEB_PORT3080Port for the web UI
MCP_STREAMING_ENABLEDtrueEnable streaming reads for large files
MCP_STREAM_CHUNK_SIZE65536Streaming buffer size in bytes (64KB)
MCP_STREAM_FILE_SIZE_LIMIT10485760Threshold to switch to streaming (10MB)

Storage layout

~/.mcp-documentation-server/     # Or custom path via MCP_BASE_DIR
├── data/
│   ├── orama-chunks.msp         # Orama vector DB (child chunks + embeddings)
│   ├── orama-docs.msp           # Orama document DB (full content + metadata)
│   ├── orama-parents.msp        # Orama parent chunks DB (context sections)
│   ├── migration-complete.flag   # Written after legacy JSON migration
│   └── *.md                     # Markdown copies of documents
└── uploads/                     # Drop .txt, .md, .pdf files here

Embedding Models

Set via MCP_EMBEDDING_MODEL:

ModelDimensionsNotes
Xenova/all-MiniLM-L6-v2384Default — fast, good quality
Xenova/paraphrase-multilingual-mpnet-base-v2768Recommended — best quality, multilingual

Models are downloaded on first use (~80–420 MB). The vector dimension is determined automatically from the provider.

⚠️ Important: Changing the embedding model requires re-adding all documents — embeddings from different models are incompatible. The Orama database is recreated automatically when the dimension changes.

Architecture

Server (FastMCP, stdio)
  ├─ Web UI (Express, port 3080)
  │    └─ REST API → DocumentManager
  └─ MCP Tools
       └─ DocumentManager
            ├─ OramaStore          — Orama vector DB (chunks DB + docs DB + parents DB), persistence, migration
            ├─ IntelligentChunker  — Parent-child chunking (code, markdown, text, PDF)
            ├─ EmbeddingProvider   — Local embeddings via @xenova/transformers
            │    └─ EmbeddingCache — LRU in-memory cache
            └─ GeminiSearchService — Optional AI search via Google Gemini
  • OramaStore manages three Orama instances: one for document metadata/content, one for child chunks with vector embeddings, and one for parent chunks (context sections). All are persisted to binary files on disk and restored on startup.
  • IntelligentChunker implements the Parent-Child Chunking pattern: documents are first split into large parent chunks that preserve full context (sections, paragraphs), then each parent is further split into small child chunks for precise vector search. At query time, results are deduplicated by parent so that the LLM receives both the matched fragment and the broader context.
  • EmbeddingProvider lazily loads a Transformers.js model for local inference — no API calls needed.

Development

git clone https://github.com/andrea9293/mcp-documentation-server.git
cd mcp-documentation-server
npm install
npm run dev       # FastMCP dev mode with hot reload
npm run build     # TypeScript compilation
npm run inspect   # FastMCP web UI for interactive tool testing
npm start         # Direct tsx execution (MCP server + web UI)
npm run web       # Run only the web UI (development)
npm run web:build # Run only the web UI (compiled)

Contributing

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/name
  3. Follow Conventional Commits for messages
  4. Open a pull request

License

MIT — see LICENSE

Support


Star History

Star History Chart

Built with FastMCP, Orama, and TypeScript

Related MCP servers

Give your AI agent stealth web scraping with Cloudflare bypass and CSS selection, powered by Scrapling.

67k
Python
BSD-3-Clause
View repository →

Give your AI coding agent full control of a live Chrome browser for automation, debugging, and performance analysis.

45k
TypeScript
Apache-2.0
View repository →

Let AI agents manage your Puter files, websites, and serverless workers over MCP.

43k
TypeScript
AGPL-3.0
View repository →

Browser automation for AI agents via MCP, powering ByteDance's Agent TARS hybrid GUI/DOM browser control.

37k
TypeScript
Apache-2.0
View repository →

Run arbitrary shell commands from an MCP-connected AI agent.

37k
TypeScript
Apache-2.0
View repository →

Filesystem access MCP server from ByteDance's UI-TARS/Agent TARS ecosystem.

37k
TypeScript
Apache-2.0
View repository →