Skip to content
Agent Orchestration
Skill

/map-codebase

Derives the tech-stack doc from scratch by scanning the codebase — analyzes stack, architecture, and gray areas (error handling, API shapes) and persists findings into specs/tech-architecture/tech-stack.md. Run when the tech doc doesn't exist yet; use survey-context to consume

From plugin
bigpowers
29280 skills1 hook1 MCP

Claude Code

$ npx -y skills add danielvm-git/bigpowers --skill map-codebase --agent claude-code

SKILL.md

map-codebase.SKILL.md
name: map-codebase
model: sonnet
effort: standard
description: "Derives the tech-stack doc from scratch by scanning the codebase — analyzes stack, architecture, and gray areas (error handling, API shapes) and persists findings into specs/tech-architecture/tech-stack.md. Run when the tech doc doesn't exist yet; use survey-context to consume it once it does."

Map Codebase

Perform a deep architectural and structural analysis of the codebase. Unlike `survey-context` which identifies "where we are", `map-codebase` identifies "what we are dealing with" and "how things are done".

> **Use this vs survey-context:** `map-codebase` BUILDS the tech-stack doc by scanning the codebase from scratch. `survey-context` READS existing specs/tech-architecture docs without re-deriving them. Run `map-codebase` when `specs/tech-architecture/tech-stack.md` doesn't exist yet; run `survey-context` when it does.

> **HARD GATE** — Cold analysis only. Do NOT assume architectural patterns without reading the code. If the codebase structure surprises you, call out the delta.

Process

1. Identify Core Stack & Dependencies

  • Scan `package.json`, `Cargo.toml`, `requirements.txt`, etc.
  • Identify primary framework, runtime, and critical libraries (ORM, Auth, State, UI).
  • Note version constraints and any deprecated or unusual dependencies.

2. Map High-Level Architecture

  • Identify the entry points (CLI, Web, API).
  • Map the primary data flow (e.g., Controller → Service → Repository).
  • Identify where business logic lives vs. where I/O lives.
  • Look for established patterns (e.g., hexagonal, layered, feature-folders).

3. Analyze "Gray Areas" (The "How")

Search for patterns and anti-patterns in these categories:

  • **Error Handling:** Are exceptions caught early or bubbled? Is there a global error handler? Are error messages structured?
  • **API Shapes:** Is it REST, GraphQL, or RPC? What is the casing (camelCase, snake_case)? How are responses structured?
  • **Type Safety:** Is it strictly typed? Are there many `any` or `unsafe` blocks? Are interfaces used for DIP?
  • **Observability:** Is there structured logging? Are there health checks? Where do logs go?
  • **Testing:** What is the test coverage strategy? Are mocks used? Where do tests live?

4. Identify Planning "Signals"

Look for signals that will influence upcoming plans:

  • **Consistency Gaps:** "Half the project uses async/await, the other half uses Promises."
  • **Debt Hotspots:** "The `AuthManager` is 1500 lines and handles both JWT and session logic."
  • **Integration Points:** "We need to talk to the Stripe API, but there's no wrapper yet."
  • **Conventions:** "The team always uses functional components over classes."

5. Persist to specs/tech-architecture/tech-stack.md

Compile all findings into `specs/tech-architecture/tech-stack.md`. This file serves as the project's "Long-Term Memory".

# Project Context

## Stack
- [Framework/Language]
- [Key Libraries]

## Architecture
- [Pattern Description]
- [Data Flow]

## Conventions (Observed)
- [Error Handling Pattern]
- [API Design]
- [Type System]

## Signals / Active Considerations
- [Gap 1]
- [Hotspot 2]

When to Use

  • When first joining a project.
  • Before a major refactor or architectural change.
  • When `survey-context` reveals a lack of domain knowledge.
  • To refresh `specs/tech-architecture/tech-stack.md` after significant changes.
Read more
@danielvm-git
Ships withbigpowers

Agent skills synthesizing 17 years of software engineering discipline — from Clean Code to AI-native architecture — into a single, prescriptive methodology for solo developers.

29280 skills1 MCP
Get the whole plugin

Stars on GitHub

Momentum

stars in total
292
Star history of danielvm-git/bigpowers on GitHub, a chart by star-history.com

Other skills on bigpowers.

align-grid

align-grid

Build editorial/magazine/report webpages on a GENUINE Müller-Brockmann modular grid (International Typographic Style) — not a…

assess-impact

assess-impact

Analyze the blast radius of a proposed change before any code is written. Maps dependents, affected stories, and test coverage.…

audit-code

audit-code

Self-review checklist for the coding agent to run before dispatching a reviewer. Checks CONVENTIONS.md compliance, Boy Scout…

audit-plan

audit-plan

Evaluate an incoming project plan against bigpowers principles and conventions, surface gaps, and produce a READY/NOT READY…

build-epic

build-epic

Eight-step epic build cycle — reads state.yaml, execution-status.yaml, and one epic capsule; updates status via bp-yaml-set or…

change-request

change-request

Add a new requirement or reorder epics by WSJF against specs/release-plan.yaml and epic capsule directories. Modes Add and…

More skills from other plugins.

1password

1password

Set up and use 1Password CLI for sign-in, desktop integration, and reading or injecting secrets.

openclaw6d395k
@steipete@steipeteInstall Skill
jira-tickets

jira-tickets

Read and update Jira tickets through Orca's saved Jira connections. Use when a task comes from Jira or the user asks for Jira…

orca4d128k
@stablyai@stablyaiInstall Skill
agentmail

agentmail

Use your assigned AgentMail inbox to read email tasks, explicitly send or reply, and check delivery. Provided automatically by…

paperclip5d114k
@paperclipai@paperclipaiInstall Skill
adr-create

adr-create

Create a new Architecture Decision Record with sequential numbering and AgentDB registration

@ruvnet@ruvnetInstall Skill

Questions about map-codebase.

Which coding agents can use map-codebase?
map-codebase installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.