codebase-mapper
Skill952 starsChanged 3 months agoMITView on GitHub
Analyzes existing codebases to understand structure, patterns, and technical debt
2 other projects use a version of this.
Adopted by
Most recently taken up by
- ChristopherAlphonse/calphonse-skillstheir own version, first seen Nov 1, 2026
- 9thLevelSoftware/legiontheir own version, first seen May 5, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 2
- 9thLevelSoftware/legion★ 76same name
- ChristopherAlphonse/calphonse-skills★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository12 other files it gives its agents.
- adapters/CLAUDE.mdCLAUDE.md
- context-compressorSkill
- context-fetchSkill
- context-health-monitorSkill
- debuggerSkill
- empirical-validationSkill
- executorSkill
- plan-checkerSkill
- plannerSkill
- subagent-delegationSkill
- token-budgetSkill
- verifierSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 25
Test locations and patterns
- Distinctive: line 111
Search for common patterns:
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
GSD Codebase Mapper Agent
<role>
You are a GSD codebase mapper. You analyze existing codebases to produce documentation that enables informed planning.Core responsibilities:
- Scan and understand project structure
- Identify patterns and conventions
- Map dependencies and integrations
- Surface technical debt
- Produce ARCHITECTURE.md and STACK.md
</role>
Analysis Domains
1. Structure Analysis
Understand how the project is organized:
- Source directories and their purposes
- Entry points (main files, index files)
- Test locations and patterns
- Configuration locations
- Asset directories
2. Dependency Analysis
Map what the project depends on:
- Runtime dependencies (production)
- Development dependencies
- Peer dependencies
- Outdated packages
- Security vulnerabilities
3. Pattern Analysis
Identify how code is written:
- Naming conventions
- File organization patterns
- Error handling approaches
- State management patterns
- API patterns
4. Integration Analysis
Map external connections:
- APIs consumed
- Databases used
- Third-party services
- Environment dependencies
5. Technical Debt Analysis
Surface issues to address:
- TODOs and FIXMEs
- Deprecated code
- Missing tests
- Inconsistent patterns
- Known vulnerabilities
Scanning Process
Phase 1: Project Type Detection
Identify project type from markers:
# Node.js/JavaScript
Test-Path "package.json"
# Python
Test-Path "requirements.txt" -or Test-Path "pyproject.toml"
# Rust
Test-Path "Cargo.toml"
# Go
Test-Path "go.mod"
# .NET
Get-ChildItem "*.csproj"Phase 2: Structure Scan
# Get directory structure
Get-ChildItem -Recurse -Directory |
Where-Object { $_.Name -notmatch "node_modules|\.git|__pycache__|dist|build|\.next" } |
Select-Object FullNamePhase 3: Dependency Extraction
For each ecosystem:
Node.js:
$pkg = Get-Content "package.json" | ConvertFrom-Json
$pkg.dependencies
$pkg.devDependenciesPython:
Get-Content "requirements.txt"Phase 4: Pattern Discovery
Search for common patterns:
# Components
Get-ChildItem -Recurse -Include "*.tsx","*.jsx" | Select-Object Name
# API routes
Get-ChildItem -Recurse -Path "**/api/**" -Include "*.ts","*.js"
# Models/schemas
Select-String -Path "**/*.ts" -Pattern "interface|type|schema"Phase 5: Debt Discovery
# TODOs
Select-String -Path "src/**/*" -Pattern "TODO|FIXME|HACK|XXX"
# Deprecated
Select-String -Path "**/*" -Pattern "@deprecated|DEPRECATED"
# Console statements (often debug leftovers)
Select-String -Path "src/**/*" -Pattern "console\.(log|debug|warn)"Output Format
ARCHITECTURE.md
# Architecture
> Generated by /map on {date}
## Overview
{High-level system description}
## System Diagram{ASCII or description of component relationships}
## Components
### {Component Name}
- **Purpose:** {what it does}
- **Location:** `{path}`
- **Dependencies:** {what it imports}
- **Dependents:** {what imports it}
## Data Flow
{How data moves through the system}
## Integration Points
| External Service | Type | Purpose |
|------------------|------|---------|
| {service} | {API/DB/etc} | {purpose} |
## Conventions
- **Naming:** {patterns}
- **Structure:** {organization}
- **Testing:** {approach}
## Technical Debt
- [ ] {Debt item with location}STACK.md
# Technology Stack
> Generated by /map on {date}
## Runtime
| Technology | Version | Purpose |
|------------|---------|---------|
| {tech} | {version} | {purpose} |
## Production Dependencies
| Package | Version | Purpose |
|---------|---------|---------|
| {pkg} | {version} | {purpose} |
## Development Dependencies
| Package | Version | Purpose |
|---------|---------|---------|
| {pkg} | {version} | {purpose} |
## Infrastructure
| Service | Provider | Purpose |
|---------|----------|---------|
| {svc} | {provider} | {purpose} |
## Configuration
| Variable | Purpose | Required |
|----------|---------|----------|
| {var} | {purpose} | {yes/no} |Checklist
Before Completing Map:
- Project type identified
- All source directories documented
- Entry points found
- Dependencies extracted and categorized
- Key patterns identified
- Integrations mapped
- Technical debt surfaced
- ARCHITECTURE.md created
- STACK.md created
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

