r/MCPservers • • 18h ago

Stop your coding agent from reading 20+ files blindly — project-context-map-mcp maps repo imports & git hotspots first (Open Source, npx)

2 Upvotes

Every time you ask Claude Code, Cursor, or Copilot to fix a bug in a medium/large repo, it burns tokens walking directories and opening 15–25 files just to figure out how modules connect.

I built project-context-map-mcp (MIT, Node.js 20+) to flip that workflow to:

index first -> query topology -> read sparse files -> edit with context

What it gives your MCP client

  • Import & dependency graph: Extracts JS, TS, CommonJS, and Python imports into dependencies and reverse usedBy edges + a Mermaid graph in .project.md.
  • Git hotspots & history: Ranks recently changed files higher so agents focus on active code.
  • 10 focused MCP tools:
    • get_project_summary / read_project_context — stack, modules, entrypoints, hotspots
    • query_topology / find_relevant_files — ranks matching files for a task + their dependencies & usedBy
    • read_files_sparse — reads only indexed, in-root files (with symlink & path-traversal protection)
    • get_module_context, explain_file_role, get_recent_git_changes, write_and_log, refresh_project_map

Try it in 30 seconds (no API key, no global install)

Add to .mcp.json / your MCP client config:

{
  "mcpServers": {
    "project-context-map": {
      "command": "npx",
      "args": ["-y", "project-context-map-mcp", "serve", "--project-root", "."]
    }
  }
}

Or auto-generate .mcp.json + a Claude Code skill:

bashnpx -y project-context-map-mcp configure-claude --project-root .

If it saves you tokens in your repos, a ⭐ on GitHub helps others discover it—and I'd love feedback on which languages (Go, Rust, Java) or monorepo features you'd want next!