home / mcp / pocketmcp server

PocketMCP Server

Lightweight, local-first MCP Server with Web UI and API

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "kailash-sankar-pocketmcp": {
      "url": "http://localhost:8001/mcp",
      "headers": {
        "MODEL_ID": "Xenova/all-MiniLM-L6-v2",
        "TRANSPORT": "stdio",
        "WATCH_DIR": "./kb",
        "CHUNK_SIZE": "1000",
        "SQLITE_PATH": "./data/index.db"
      }
    }
  }
}

PocketMCP is a compact, local-first MCP server that watches your folders, processes documents into semantic chunks, and stores vectors locally for fast, offline semantic search. It integrates with common MCP clients like VS Code and Cursor, and runs efficiently on modest hardware without external dependencies after the initial model download.

How to use

You interact with PocketMCP through MCP clients or a web tester to run semantic searches and manage documents. Start the MCP server in development mode to get the web UI and API for validation, then switch to production mode for a server-only setup. In both modes you can keep your content in a local directory, let the server watch it, and query your indexed documents for meaningful results.

How to install

Prerequisites: you need Node.js and a package manager. The project uses pnpm for managing workspace components.

# Install Node.js if you don't have it (visit nodejs.org to download)
# Then install pnpm globally if needed
npm i -g pnpm

# Clone or download PocketMCP and navigate into it
cd PocketMCP

# Install workspace dependencies
pnpm install

# Set up environment variables and local config (optional but recommended)
pnpm setup
# Or manually copy: cp .env.sample .env

Additional sections

Configuration and operation details are provided to help you tune how PocketMCP watches content, chunks text, and stores embeddings. You can run in development mode to test the full web interface and API, or in production mode to run the MCP server with no extra UI.

Available tools

search

Semantic search for similar content using vector embeddings and optional filters.

upsert_documents

Insert or update documents with text, title, and metadata into the vector store.

delete_documents

Remove documents by internal IDs or external IDs from the vector store.

list_documents

List documents with pagination and metadata.

chunk_view

Inspect individual chunks with text and metadata for debugging.

health_check

Query the system health to verify API and MCP server readiness.