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.
git clone --depth 1 https://github.com/luutuankiet/gsd-liteWrote 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.
[](https://agentmods.dev/commands/luutuankiet/gsd-lite/map-codebase)<a href="https://agentmods.dev/commands/luutuankiet/gsd-lite/map-codebase"><img src="https://agentmods.dev/badge/commands/luutuankiet/gsd-lite/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.
<a href="https://agentmods.dev/commands/luutuankiet/gsd-lite/map-codebase"><img src="https://agentmods.dev/badge/commands/luutuankiet/gsd-lite/map-codebase.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00023 | $0.00783 |
| Opus 5.5 | $0.00009 | $0.00313 |
| Sonnet 5.5 | $0.00005 | $0.00157 |
| Haiku 4.5 | $0.00002 | $0.00078 |
Grade A, and why
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.
How it starts
The opening of the file, as written. The whole thing — 105 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Map Codebase Workflow
[SYSTEM: MAP-CODEBASE MODE - Codebase Discovery]
Initialization Check
Check if ARCHITECTURE.md exists in gsd-lite/:
- If exists: Read it and propose to update/refresh
- If missing: Create fresh from mapping
Coaching Philosophy
You are a thinking partner. Discover the codebase through exploration, interpret patterns, and document findings. Ask user to clarify purpose when code is ambiguous.
First Turn Protocol
First turn sequence:
- Check if ARCHITECTURE.md exists (silently)
- TALK to user: "I'm going to map your codebase structure. What should I know before I start exploring?"
- Only begin mapping AFTER user provides context
Mapping Process
Step 1: Discover Project Structure
Use Bash and Glob to understand directory layout:
- Top-level structure
- Second level key subdirectories
- Build semantic understanding: entry points, core logic, infrastructure, support
Ask user if unclear: "I see directories [A], [B], [C]. Is [A] the main application code?"
Step 2: Identify Tech Stack
Read package manifests (package.json, pyproject.toml, go.mod, Cargo.toml, etc.). Extract:
- Runtime and version
- Language
- 2-5 key dependencies that define architecture (NOT utilities)
Ask user: "Which 3-5 dependencies are critical to how this system works?"
Step 3: Trace Data Flow
Read entry points. Follow the flow:
- Where does request/input arrive?
- What components process it?
- Where does data persist or transform?
- How does response/output return?
Use Mermaid diagrams for complex flows, text for simple ones.
Step 4: Document Entry Points
Identify the 3-5 files that give fastest path to understanding. Format as bulleted list with paths and descriptions.
Step 5: Write ARCHITECTURE.md
Write to gsd-lite/ARCHITECTURE.md, preserving the two-zone skeleton:
Architecture
Mapped: [today's date]
How To Read This File - bounded-read contract, agents start here
[keep the template's block verbatim - it is the read contract every future agent depends on]
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.
- 1mo ago First seen · 105 lines · 23 tokens per session scan A bb79be7e7b64
map-codebase is a command published in the GitHub repository luutuankiet/gsd-lite (3 stars, last pushed 2mo ago), licensed MIT. It adds 23 tokens to every session and 783 once invoked, about $0.0001 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.
Other commands, from other repositories
template
Manage issue templates for streamlined issue creation.
auto-browse
Auto-browse — learn, optimize, and graduate browser operations or web data-mining workflows.
doctor
Badi configuration validation. Checks all Badi components and produces a diagnostic report.
bug-check
Run automated tests and build checks first, then agent code review. For each bug found, propose or document a regression test.
swarm-status
Command documentation for swarm-status in category swarm.
ralph-help
Explain Ralph Loop plugin and available commands.