gsd-map-codebase

gsd-map-codebase is a skill for Claude Code, Codex from ChianW/C31. It costs 65 tokens per session (1,172 once invoked), scanned A, original, MIT.

A codebase mapping tool that studies an existing software project and records its structure, technologies, coding conventions, and possible problem areas in Markdown files.

In plain words
What is it for?
Use it to understand a legacy project, prepare a refactor or migration, or help a new contributor get oriented.
Why use it?
It gives you a shared reference before you change unfamiliar or poorly documented code, so you do not have to rediscover how the project works from scratch.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to understand a legacy project, prepare a refactor or migration, or help a new contributor get oriented.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/chianw/c31/gsd-map-codebase
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add ChianW/C31 --skill gsd-map-codebase
Clone the repo
git clone --depth 1 https://github.com/ChianW/C31

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for gsd-map-codebase

README.md
[![agentmods](https://agentmods.dev/badge/skills/chianw/c31/gsd-map-codebase/github.svg)](https://agentmods.dev/skills/chianw/c31/gsd-map-codebase)
Your own site
<a href="https://agentmods.dev/skills/chianw/c31/gsd-map-codebase"><img src="https://agentmods.dev/badge/skills/chianw/c31/gsd-map-codebase/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for gsd-map-codebase

Your own site · 80×15
<a href="https://agentmods.dev/skills/chianw/c31/gsd-map-codebase"><img src="https://agentmods.dev/badge/skills/chianw/c31/gsd-map-codebase.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 65 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,172 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00065 $0.01172
Opus 5.5 $0.00026 $0.00469
Sonnet 5.5 $0.00013 $0.00234
Haiku 4.5 $0.00006 $0.00117

Measured 1mo ago against content hash 65258ae13e0a, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

gsd-map-codebase scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/utils/gsd-map-codebase/SKILL.md · 133 lines

How it starts

The opening of the file, as written. The whole thing — 133 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Multilingual Triggers

Language Trigger phrases
EN gsd-map-codebase
ZH 分析代码库, 代码库分析
JA コードベース分析

Output language: Respond automatically in the user's conversation language.

Map an Existing Codebase

Produce a durable reference of an existing codebase so future work doesn't start from zero context. The output is a set of Markdown files in memory/.planning/codebase/.

When to Use

  • User says "map this codebase", "analyze the repo", "what's in this project?"
  • Before planning a refactor, migration, or major feature on a legacy codebase
  • After inheriting a project with no documentation
  • When onboarding a new contributor who needs orientation

Execution Flow

Phase 1: Scan

  1. Directory structure — Run find . -maxdepth 3 -type f (or deeper as needed). Ignore node_modules/, .git/, dist/, build/, __pycache__/, .venv/.
  2. Tech stack markers — Look for:
    • package.json, requirements.txt, go.mod, Cargo.toml, Gemfile, etc.
    • Dockerfile, docker-compose.yml, k8s/, helm/
    • Config files (vite.config.*, webpack.config.*, tsconfig.json, etc.)
  3. Architecture signals — Count of services/modules, entry points, API definitions, database schema files, message queue configs, event bus usage.

Phase 2: Detect

Tech Stack (for STACK.md)

  • Primary language(s) and versions
  • Framework(s) and runtime
  • Build tools and package managers
  • Database(s), caches, message queues
  • Deployment / CI platform(s)
  • Testing frameworks

Architecture (for ARCHITECTURE.md)

  • Pattern: monolith, modular monolith, microservices, serverless, etc.
  • Communication style: REST, GraphQL, gRPC, events, message bus
  • Data flow: where is state, where is compute, what is the boundary
  • Key entry points and hot paths

Conventions (for CONVENTIONS.md)

  • Naming: files, classes, functions, variables, branches
  • Folder structure: by feature, by layer, by domain
  • Import / module organization
  • Code style (formatter, linter config if detectable)
  • Commit message style if visible in git log

Read the full file on GitHub · 133 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 133 lines · 65 tokens per session scan A 65258ae13e0a

Subscribe to this mod's changes

gsd-map-codebase is a skill published in the GitHub repository ChianW/C31 (1 stars, last pushed 1mo ago), licensed MIT. It adds 65 tokens to every session and 1,172 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

diag-harness

Kernel-version skew check (ADR-027). Reports manifest surface + manifest kernel + installed kernel + verdict (match/patch-diff/minor-diff/major-diff). Exits 1 on minor/major skew with a copy-pasteable npm install @metaharness/[email protected] next step. Exits 2 if no .harness/manifest.json at path.

ruvnet/metaharness · 85 tokens

agent-performance-optimizer

Agent skill for performance-optimizer - invoke with $agent-performance-optimizer.

ruvnet/ruflo · 19 tokens

agent-refinement

Agent skill for refinement - invoke with $agent-refinement.

ruvnet/ruflo · 15 tokens

compare-harnesses

Diff two scaffolded harnesses (ADR-031). Reports manifest meta drift + host list + per-file fingerprint changes (added/removed/changed). Exits 0 IDENTICAL, 1 DRIFT, 2 missing manifest. Use --bundle for the ADR-031 schema-1 JSON envelope.

ruvnet/metaharness · 66 tokens

create-harness

Scaffold your own focused AI agent harness — pick host (Claude Code, Codex, pi.dev, Hermes), template, agents, skills, and ship a npm-publishable harness with its own npx CLI. Use when a user asks to "create my own agent harness", "scaffold a harness", "make a custom Claude Code plugin like ruflo", or "build a…

ruvnet/metaharness · 89 tokens

oia-manifest

Emit .harness/oia-manifest.json declaring layer alignment with the OIA v0.1 9-layer reference architecture. Self-describes the harness's MCP wiring, witness signing, audit log, identity posture (always 'none' at v0.1). --check verifies an existing manifest, --dry-run prints without writing, --json emits to stdout.

ruvnet/metaharness · 79 tokens