Labsco
MCP SERVER

Repo Map

by pdavis68

Hand a model a ranked outline of a repository — function prototypes and variables for the files in play, plus the related files it should have asked about — built to a token budget you set.

Code Intelligence & Repository IndexingVerified
Summary
The model gets an outline of the repository that fits the context window by design.

Both tools answer the same underlying question — what else should I be looking at — from opposite ends: repo_map ranks neighbouring files around the ones you name, and search_identifiers finds a name with its line and context, split into definitions and references. token_limit and max_context_window are the arguments that matter, because the map is built to a budget instead of being truncated after the fact. Two tools is the entire surface, which places this underneath a coding assistant rather than in place of one.

What it is

A repository-mapping server that builds a ranked outline of a codebase around a set of files, with an identifier search across the same tree.

What you get
  • A map of named files as function prototypes and variables rather than bodies, with related files pulled in at a small ranking boost
  • A budget you control: token_limit and max_context_window bound the map so it fits the window it is going into, and exclude_unranked drops what did not earn a place
  • Ranking steered by the conversation itself — mentioned_files and mentioned_idents push the map toward what is actually being discussed
  • Identifier search returning file, line number and surrounding context, separable into definitions and references
  • force_refresh for when the tree has moved under a cached map
Requirements

`uv` with a Python available, and the repository on local disk: both tools take a project_root and expect the filenames you pass to be relative to it.

Setup effort

One command — uvx --from repomapper repomap-mcp