codebase-memory-mcp
Helps your agent explore unknown code, map architectures, and understand relationships between system parts. Useful for analyzing complexity and the impact of changes.
What it does
This tool helps you understand and navigate complex programming code. It maps out the code's structure, finds specific parts, and shows how they connect.
When to use it
- ✓When you encounter code you don't know.
- ✓To understand how an entire program is organized.
- ✓To find where a specific function is used or called.
Example of what to ask your AI
“Show me where the 'calculate_total' function is used in the 'ecommerce' project.”
Want more? Open the sections below.
How to use
The easiest way: copy the message below and paste it into Claude, ChatGPT, Cursor or any AI. It reads the skill and follows the instructions.
Skill link
Ready-to-paste message
How it works
It uses a 'map' of the code (called Codebase Memory) to find information. You ask something, it consults the map, and shows you the results, like a guide.
Installation
Easiest way: copy the skill link and paste it into Claude, ChatGPT or Cursor asking it to follow the instructions.
In the terminal (Claude Code, Codex, Cursor), in your project folder:
npx skills add github/awesome-copilot --skill codebase-memory-mcpOr download just the file:
curl -L https://raw.githubusercontent.com/github/awesome-copilot/main/skills/codebase-memory-mcp/SKILL.md -o SKILL.mdTechnical content (original SKILL.md)
Original text by the author, straight from GitHub.
Codebase Memory MCP
Use the configured Codebase Memory graph as a discovery accelerator, not as the sole source of truth. Confirm graph-derived conclusions with source snippets or local files before editing code or making strong claims.
Evidence Levels
- Scout — Provisional positive orientation only. Do not make absence, exhaustive, dead-code, or complete-impact claims.
- Verify — Default for task-directed work. Check freshness where material, exact source snippets, relevant traces, path coverage, and every result page needed by the claim.
- Auditor — Use for negative, exhaustive, security, dead-code, architecture-boundary, and complete-impact work. Require the current index generation, a bounded scope, complete result streams, coverage inspection, and source checks for gaps.
Match the evidence level to the claim. If Auditor evidence cannot be completed, state the bounded limitation instead of making an absolute claim.
Workflow
- Discover the Codebase Memory tools exposed by the current MCP client and use their callable schemas; clients may prefix or rename tools and expose different parameters.
- Call
list_projectsfirst. Select only the entry whose canonicalroot_pathmatches the live checkout, and retain both its exact project name and root for later calls. If no match appears andhas_moreis true, continue withoffset=next_offsetbefore concluding the index is absent. For an absent index, follow the authorization rule in Safety and Fallbacks or use rooted local exploration; never substitute a similarly named project. - Before branch-sensitive or edit-sensitive conclusions, use
index_statusand verify the actual version-control state. Usedetect_changesonly when its Git base and head are valid for the checkout. If it unexpectedly reports zero changes, or the checkout uses another VCS, inspect that VCS's status or diff before claiming no impact. - Use
get_architectureonce for unfamiliar structure. Requestclustersto discover de-facto module seams. Treatcyclesas an opt-in whole-call-graph scan:pathdoes not scope cycle detection, so verify relevant cycles before making module-local claims. - Use
search_graphfor definitions, implementations, routes, classes, interfaces, and related symbols. Prefer a BM25queryfor keyword discovery and a name or qualified-name pattern for known symbols. Usesemantic_queryfor vocabulary mismatch and verify matches with source snippets; similarity scores are not confidence probabilities. Narrow by label or path and set a result limit. Continue the main stream withoffset=next_offsetwhilehas_moreis true, not by adding the requested limit: output budgets can return fewer rows. Page semantic results independently withsemantic_offset=semantic_next_offsetwhilesemantic_has_moreis true. - Use
search_codeor normal repository search for literal strings, configuration keys, test identifiers, error messages, and non-code files. Do not turn a precise text lookup into a broad graph query. - After graph search, use
get_code_snippetwith the returned qualified name. For a File, Module, Class, or Interface node spanning more than 200 lines,source_mode="auto"returns an outline; continue members withmember_offset=next_member_offset. To read such a container's body, passsource_mode="full":start_lineandmax_linesalone do not switch off the outline. Withfull, page the body withstart_line/max_linesand continue fromnext_start_linewhilesource_clippedis true and a continuation is available. To list a file's declarations without reading it, useget_file_outline(file_path=...); this tool usesoffset += returnedwhilehas_moreis true. If source snippets are unavailable, open the local file before relying on the result. - Use
trace_pathfor callers, callees, dependency paths, data flow, cross-service paths, and impact analysis. Include tests when the claim covers them. Whenhas_moreand a continuation are present, passnext(tree output) ornext_cursor(json output) back ascursor, keeping traversal arguments unchanged; the output budget may increase.truncated=truealone does not promise another page: engine ceilings can yield a lower-bound total (gte) without a cursor. Withdirection="both"callers are paged after all callees, so page 1 can show zero callers whilecallers_totalis positive; askdirection="inbound"when the question is who calls a symbol.
…
FAQ
Can I trust its output 100%?
No, use it as a guide. Always confirm important information by looking at the original code before making changes.
Does it find all types of code?
It's best for programming code. For plain text or configuration files, other tools might be more direct.
What are 'evidence levels'?
These are confidence levels. 'Scout' is a quick look, 'Verify' is for checking details, and 'Auditor' is for deep and negative analyses (like finding unused code).
Details
Original description by the author
Use when exploring unfamiliar code, mapping architecture, finding symbols or relationships, tracing callers, callees, data flow or dependencies, assessing impact, auditing dead or complex code, or handling explicit Codebase Memory requests. Otherwise skip tasks confined to a supplied known file, tiny one-file check, exact literal, configuration value, error string, or non-code text.
repo: github/awesome-copilot
Popularity
- GitHub stars
- 40k
- Ranking position
- #5054
- License
- MIT
- Updated
- 10/15/2026
Comments
- …
More skills from this repository
acquire-codebase-knowledge
Helps your agent understand and document an existing code project. It's useful for onboarding new people or getting an overview of the architecture.
github/awesome-copilot
acreadiness-assess
Enables your agent to assess a project's readiness for AI and generate a report. It's useful for understanding how well a project is prepared to use AI tools.
github/awesome-copilot
acreadiness-generate-instructions
Helps your agent create instructions for AI tools based on an assessment. It's useful for improving how AI interacts with code and closing identified gaps.
github/awesome-copilot
acreadiness-policy
Enables your agent to help define or apply policies for AI project assessment. It's useful for standardizing how projects are evaluated and ensuring compliance.
github/awesome-copilot
Similar skills
benchmark-optimization-loop
Has your agent improve something's speed in a measured way. It tests multiple versions and chooses the fastest one that still works correctly.
affaan-m/ECC
change-impact
Helps your agent analyze the impact of code changes before making them. It compares the planned vs. actual results afterward, covering paths, data, tests, and documentation. Useful for risky or system-wide changes.
affaan-m/ECC
click-path-audit
Lets your agent trace all user buttons and interactions to find bugs. It finds issues where functions seem to work alone but fail together. Useful when bugs persist even after debugging.
affaan-m/ECC