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.
npx skills add irfad7/claude-power-skills --skill codebase-insightgit clone --depth 1 https://github.com/irfad7/claude-power-skillsWrote 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/skills/irfad7/claude-power-skills/codebase-insight)<a href="https://agentmods.dev/skills/irfad7/claude-power-skills/codebase-insight"><img src="https://agentmods.dev/badge/skills/irfad7/claude-power-skills/codebase-insight.svg" alt="Measured on agentmods" 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.00098 | $0.02041 |
| Opus 5 | $0.00049 | $0.01020 |
| Sonnet 5 | $0.00020 | $0.00408 |
| Haiku 4.5 | $0.00010 | $0.00204 |
Grade A, and why
codebase-insight 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 8d 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 — 261 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Codebase Insight — Deep Analysis with Persistent Memory
You are a codebase archaeologist and cartographer. You read the entire codebase, understand how every piece connects, and produce a map that makes the system navigable for any developer — including future AI sessions.
Why This Exists
Every time you open a codebase, you start from zero. You re-read the same files, re-discover the same patterns, re-learn the same quirks. Codebase Insight fixes that by persisting the analysis to a file that future sessions can read immediately.
The Insight Protocol
Step 1: Full Codebase Scan
Read everything systematically. Don't sample — survey.
SCAN ORDER:
═══════════
1. Root files — README, package.json/manifest, config files
→ Project name, purpose, tech stack, dependencies
2. Directory structure — full tree, note patterns
→ Architecture style, organization principle
3. Entry points — main/index files, app bootstrap
→ How the application starts, what it initializes
4. Route/API layer — endpoints, handlers
→ What the system exposes, request/response shapes
5. Data layer — schemas, models, migrations, ORM config
→ What's stored, how it relates, what constraints exist
6. Business logic — services, utils, core modules
→ Where the real work happens, key algorithms
7. Infrastructure — CI/CD, Docker, deployment configs
→ How it's built, tested, deployed
8. Tests — test files, coverage config
→ What's tested, what's not, test patterns used
9. Git history — last 30 commits, active branches
→ Recent momentum, who's working on what
Step 2: Pattern Recognition
Identify the recurring patterns in the codebase:
PATTERN ANALYSIS:
═════════════════
Architecture Pattern: [Monolith / Microservices / Modular Monolith / Serverless / etc.]
Organization: [Feature-based / Layer-based / Domain-driven / Mixed]
Code Patterns:
- Error handling: [how errors flow — throws/returns/callbacks]
- Data fetching: [REST/GraphQL/tRPC, client-side/server-side]
- State management: [what holds state, how it flows]
- Authentication: [strategy, where checks happen]
- Validation: [where and how input is validated]
- Logging: [what's logged, what framework]
Naming Conventions:
- Files: [camelCase / kebab-case / PascalCase / snake_case]
- Functions: [pattern]
- Types: [prefix/suffix conventions]
- Database: [singular/plural, naming style]
Testing Patterns:
- Framework: [Jest/Vitest/Playwright/etc.]
- Style: [unit-heavy / integration-heavy / E2E-heavy]
- Mocking: [how external deps are mocked]
- Coverage: [approximate coverage level]
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.
- 8d ago First seen · 261 lines · 98 tokens per session scan A b2da7bcc50ae
codebase-insight is a skill published in the GitHub repository irfad7/claude-power-skills (4 stars, last pushed 1mo ago), licensed MIT. It adds 98 tokens to every session and 2,041 once invoked, about $0.0005 per session on Opus 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 skills, from other repositories
enterprise-compound
Use when verified enterprise work or a resolved debugging session should be captured as searchable institutional knowledge with prevention guidance.
error-experience-library
An error knowledge base that stores recurring error patterns, their causes, and the fixes that worked. It can search past entries and track whether each suggested fix succeeded.
token-optimization
Use when the user says 'token optimization', 'save tokens', 'context window', 'reduce tokens', 'token stack', or 'TokenStack', or asks about extending context window capacity. Covers TokenStack, the built-in compression proxy that shrinks Claude Code tool output before it reaches the Anthropic API. Do NOT use for…
state
Use when the user says 'update state', 'project state', 'where was I', or at session start to load current context.
grimoire
Use when the user says 'update context', 'update claude', 'save library', or after significant project changes.
report
Writes the session final report to a file, then prints only the path and a one-line summary. Fires when the prompt contains "Report per memstack:report", and also when the prompt begins with a standing trigger configured through MEMSTACKREPORTONTASKPROMPTS or MEMSTACKREPORTTRIGGERS. Dormant otherwise.