Skip to main content
Glama

repo-map-mcp

MCP-сервер, который поддерживает самообновляющийся пофайловый JSON-индекс репозитория (каталог, имя файла, описание, имена функций, временные метки), чтобы агент мог запросить «что здесь, вероятно, релевантно», вместо того чтобы выполнять grep/чтение всего дерева.

Исследование файлов и аннотация путей вычисляются локально; описание и назначение файла задаются агентом, который обеспечивает даже лучший контекст.

Установка

uv sync

Related MCP server: Moxie Docs MCP

Инструменты

  • index_repository(root_path, force=False) — проходит по root_path (учитывая .gitignore и прописанные исключения), хеширует каждый файл, повторно разбирает имена функций для изменённых файлов, обновляет индекс на диске by <root_path>/.repo-index/index.json. Возращает краткую строку.

  • get_repo_map(root_path, dir_prefix=None) — возвraщает JSON-индекс, опционно ограниченный подкаталогом.

  • search_files(root_path, query) — поиск по подстроке в имени файла, описании и именах функций.

  • get_stale_files(root_path) — возвращает файлы, у которых становлен флаг descriptionStale, вмеsteee с их именами функций, чтобы вызвающий агент мог написать описание, не открвая файл.

  • set_description(root_path, path, description) — возвращает описание февраля and сброшsocket the stale flag.

Поддерживаемые языки для извлечения функций (через tree-sitter): Python, JavaScript, TypeScript, TSX, Java, Rust. Прочие типы файлов по-прежнему индексируются, со funcs: [].

Требования

  • Python

  • uv

Запуск

uv run repo-map-mcp

Работает на stdio — добавьте его в конфигурацию MCP-клиента (например, Claude Code), указав command на uv run repo-map-mcp (рабочая директория — этапка, или используйте абсолютный пути).

Тест

uv run pytest -q
uv run python3 scripts/smoke_client.py   # end-to-end tool call smoke test

Available Tools

5 tools
get_repo_mapA

Return the JSON repo index for root_path, optionally scoped to dir_prefix. Call this before exploring.

Inputs: root_path (required), dir_prefix. Returns: result

get_stale_filesB

Return files in root_path's index whose description is stale (funcs changed), with their funcs.

Inputs: root_path (required). Returns: result

index_repositoryB

Walk root_path, hash/parse changed files, update the .repo-index/index.json map. Returns a summary.

Inputs: root_path (required), force. Returns: result

search_filesA

Substring search over fileName/description/funcs in the repo index for root_path.

Inputs: query (required), root_path (required). Returns: result

set_descriptionB

Write a one-line description for path in root_path's index and clear its stale flag.

Inputs: path (required), root_path (required), description (required). Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.8/5.0

    Scored across 5 tools

    Disambiguation5/5

    Each tool has a distinct responsibility: setting descriptions, indexing, fetching the map, searching, and retrieving stale files. No overlap or ambiguity exists between them.

    Naming Consistency5/5

    All tools follow a consistent snake_case verb_noun pattern (set_description, index_repository, get_repo_map, search_files, get_stale_files). Predictable and uniform.

    Tool Count5/5

    5 tools is a well-scoped size for a focused repository indexing server. Each tool earns its place with a clear role, no redundancy.

    Completeness5/5

    The tool surface covers the core workflow: indexing, description management, retrieval, search, and staleness detection. No obvious gaps; the lifecycle is fully addressed.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables AI agents to intelligently navigate and understand codebases by providing instant file descriptions, semantic search, and context-aware recommendations, eliminating the need to repeatedly scan files.
      135 PyPI
      23
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables LLM agents to efficiently understand and navigate a codebase by providing semantic search over symbols and a reference graph, replacing expensive grep/glob calls with structured tools like definition lookup, caller/callee queries, and change-impact analysis.
      4
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables agentic coding tools to maintain a living, in-repo model of intent, architecture, and code, with deterministic indexing, bidirectional linking, and continuous drift detection for task-scoped context and reconciliation.
      MIT