Back to Browse

Docs Ask MCP Server

by Alyiox
Developer ToolsLow Risk10.0MCP RegistryLocal
Free

Server data from the Official MCP Registry

Local RAG MCP for markdown documentation. Retrieval only; host synthesizes answers.

About

Local RAG MCP for markdown documentation. Retrieval only; host synthesizes answers.

Security Report

10.0
Low Risk10.0Low Risk

Valid MCP server (1 strong, 2 medium validity signals). No known CVEs in dependencies. Imported from the Official MCP Registry. 1 finding(s) downgraded by scanner intelligence.

12 files analyzed · 1 issue found

Security scores are indicators to help you make informed decisions, not guarantees. Always review permissions before connecting any MCP server.

Permissions Required

This plugin requests these system permissions. Most are normal for its category.

file_system

Check that this permission is expected for this type of plugin.

env_vars

Check that this permission is expected for this type of plugin.

Shell Command Execution

Runs commands on your machine. Be cautious — only use if you trust this plugin.

How to Install

Add this to your MCP configuration file:

{
  "mcpServers": {
    "io-github-alyiox-mcp-docs-ask": {
      "args": [
        "mcp-docs-ask"
      ],
      "command": "uvx"
    }
  }
}

Documentation

View on GitHub

From the project's GitHub README.

mcp-docs-ask

CI PyPI Python 3.13+ License: MIT

Local RAG MCP for documentation. Point source at any markdown repository (local path or git URL).

The server does retrieval only (no answer LLM). ask_docs returns grounded passages and citations; the MCP host (Cursor / Claude) synthesizes the answer.

Features

  • ask_docs retrieval with configurable path-based layer filters
  • list_docs discovery for configured docs collections and layer filters
  • reindex rebuilds the local vector index; for git URL sources it also fetches updates

Requirements

  • Python 3.13+
  • uv
  • git on PATH (only if source is a git URL)
  • Git credentials on the machine when source is a private git URL (gh auth login, HTTPS credential helper, or SSH). No tokens in config.
  • First run downloads the embedding model weights once (sentence-transformers)

Quick start

git clone git@github.com:alyiox/mcp-docs-ask.git
cd mcp-docs-ask
uv sync
mkdir -p ~/.config/mcp-docs-ask
cp config.example.json ~/.config/mcp-docs-ask/config.json
# Prefer a local checkout while developing:
#   set docs.<id>.source to your docs repo path
npx -y @modelcontextprotocol/inspector uv run mcp-docs-ask

Configuration

Config path: ~/.config/mcp-docs-ask/config.json

Windows: %USERPROFILE%\.config\mcp-docs-ask\config.json

{
  "docs": {
    "product": {
      "source": "https://github.com/example/docs.git",
      "desc": "Product guides and API reference",
      "ref": "main",
      "include": ["**/*.md"],
      "exclude": ["archive/**"],
      "layers": {
        "guides": {
          "desc": "How-to and onboarding guides",
          "include": ["docs/guides/**"]
        },
        "api": {
          "desc": "HTTP API reference",
          "include": ["docs/api/**"]
        }
      },
      "embedding_model": "sentence-transformers/all-MiniLM-L6-v2"
    },
    "team-notes": {
      "source": "/path/to/docs",
      "desc": "Internal team notes (local path; ref unused)",
      "include": ["**/*.md"],
      "exclude": ["archive/**"]
    }
  },
  "default": {
    "docs": "product",
    "embedding_model": "sentence-transformers/paraphrase-multilingual-MiniLM-L12-v2",
    "top_k": 8,
    "chunk_max_chars": 1500
  }
}

product is a git URL (ref applies). team-notes is a filesystem path (ref unused). Optional desc on each docs collection and layer helps agents pick the right target.

embedding_model, top_k, and chunk_max_chars resolve as: docs.<id>.Xdefault.X → built-in. Omit per-docs keys to inherit.

Embedding model recommendation

Any Hugging Face id loadable by sentence-transformers works. Pick by language mix:

Docs / queriesRecommended embedding_model
English-only (built-in when omitted)sentence-transformers/all-MiniLM-L6-v2
Chinese-onlyBAAI/bge-small-zh-v1.5
Multilingual (~50 langs)sentence-transformers/paraphrase-multilingual-MiniLM-L12-v2

Changing embedding_model requires a reindex (the on-disk index stores the model name).

FieldDescription
docs.<id>.sourceDocs repo root: local path or git URL
docs.<id>.descShort description for discovery (list_docs)
docs.<id>.refBranch / tag / SHA for git URL sources only (default main; ignored for local paths)
docs.<id>.includeGlobs relative to repo root (default **/*.md)
docs.<id>.excludeGlobs to skip
docs.<id>.layers.<name>.includePath globs for that layer (first match wins)
docs.<id>.layers.<name>.descShort layer description for discovery
docs.<id>.embedding_modelOptional override (see recommendation above)
docs.<id>.top_kOptional override for default retrieval count
docs.<id>.chunk_max_charsOptional override for max body chars per heading chunk
default.docsDefault docs collection id
default.embedding_modelDefault sentence-transformers model id
default.top_kDefault retrieval count
default.chunk_max_charsDefault max body chars per heading chunk

Omit layers (or set "layers": {}) for flat repos — everything is other and ask_docs uses layer=all. Configure any names you need for multi-tree docs. First match wins. Layer names are case-insensitive; all / other are reserved.

Cache layout:

  • Repos (git URL): ~/.cache/mcp-docs-ask/repos/<docs-id>/
  • Indexes: ~/.cache/mcp-docs-ask/indexes/<docs-id>/

Tools

ToolDescription
list_docsList configured docs collections and their layer filters
ask_docsRetrieve grounded passages + citations for a question
reindexSync git source (if URL) and rebuild the vector index

MCP host examples

Cursor

Add to .cursor/mcp.json:

{
  "mcpServers": {
    "docs-ask": {
      "command": "uvx",
      "args": ["mcp-docs-ask"]
    }
  }
}

Claude Code

Add to your Claude Code MCP config:

{
  "mcpServers": {
    "docs-ask": {
      "command": "uvx",
      "args": ["mcp-docs-ask"]
    }
  }
}

Codex

[mcp_servers.docs-ask]
command = "uvx"
args = ["mcp-docs-ask"]

OpenCode

{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "docs-ask": {
      "type": "local",
      "enabled": true,
      "command": ["uvx", "mcp-docs-ask"]
    }
  }
}

GitHub Copilot

{
  "inputs": [],
  "servers": {
    "docs-ask": {
      "type": "stdio",
      "command": "uvx",
      "args": ["mcp-docs-ask"]
    }
  }
}

Development

uv sync
uv run ruff check src/ tests/
uv run ruff format --check src/ tests/
uv run pyright
uv run pytest

Notes

  • Local path: ask_docs rebuilds the index automatically when file mtimes/sizes change (fingerprint check). You do not need reindex after editing local docs.
  • Git URL: ask_docs never fetches. Call reindex to git fetch the configured ref and rebuild.
  • Changing embedding_model invalidates the on-disk index (rebuild on next use / reindex).

Reviews

No reviews yet

Be the first to review this server!