Analyze Codebase
divar-ir/ai-doc-gen
Run a multi-agent deep analysis of a codebase, producing AI-readable analysis documents in .ai/docs/ covering structure, dependencies, data flow, request flow, and APIs.
Maps a codebase directory by directory and writes linked AGENTS.md files, each pointing to its parent, to document what each area contains.
$ npx skills add Yeachan-Heo/oh-my-claudecode --skill deepinit -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install Yeachan-Heo/oh-my-claudecode deepinit --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/Yeachan-Heo/oh-my-claudecode.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/deepinit .claude/skills/deepinit && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "deepinit" agent skill from https://github.com/Yeachan-Heo/oh-my-claudecode/tree/main/skills/deepinit into .claude/skills/deepinit/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deepinit", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/Yeachan-Heo/oh-my-claudecode/tree/main/skills/deepinitType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add Yeachan-Heo/oh-my-claudecode --skill deepinit -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install Yeachan-Heo/oh-my-claudecode deepinit --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Yeachan-Heo/oh-my-claudecode.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/deepinit .agents/skills/deepinit && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "deepinit" agent skill from https://github.com/Yeachan-Heo/oh-my-claudecode/tree/main/skills/deepinit into .agents/skills/deepinit/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deepinit", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add Yeachan-Heo/oh-my-claudecode --skill deepinit -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install Yeachan-Heo/oh-my-claudecode deepinit --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Yeachan-Heo/oh-my-claudecode.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/deepinit .cursor/skills/deepinit && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "deepinit" agent skill from https://github.com/Yeachan-Heo/oh-my-claudecode/tree/main/skills/deepinit into .cursor/skills/deepinit/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deepinit", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/Yeachan-Heo/oh-my-claudecode.git --path skills/deepinit--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add Yeachan-Heo/oh-my-claudecode --skill deepinit -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install Yeachan-Heo/oh-my-claudecode deepinit --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Yeachan-Heo/oh-my-claudecode.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/deepinit .gemini/skills/deepinit && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "deepinit" agent skill from https://github.com/Yeachan-Heo/oh-my-claudecode/tree/main/skills/deepinit into .gemini/skills/deepinit/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deepinit", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install Yeachan-Heo/oh-my-claudecode deepinitInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add Yeachan-Heo/oh-my-claudecode --skill deepinit -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/Yeachan-Heo/oh-my-claudecode.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/deepinit .github/skills/deepinit && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "deepinit" agent skill from https://github.com/Yeachan-Heo/oh-my-claudecode/tree/main/skills/deepinit into .github/skills/deepinit/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deepinit", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add Yeachan-Heo/oh-my-claudecode --skill deepinit -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install Yeachan-Heo/oh-my-claudecode deepinit --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Yeachan-Heo/oh-my-claudecode.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/deepinit .opencode/skills/deepinit && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "deepinit" agent skill from https://github.com/Yeachan-Heo/oh-my-claudecode/tree/main/skills/deepinit into .opencode/skills/deepinit/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deepinit", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
deepinitMaps a codebase directory by directory and writes linked AGENTS.md files, each pointing to its parent, to document what each area contains.
The skill creates hierarchical AGENTS.md documentation across a whole codebase so agents can learn what each directory contains, how components relate, any special instructions for that area, and its dependencies. Every file except the root begins with a visible parent-context line pointing to the parent AGENTS.md, written as prose rather than an HTML comment because Claude Code strips comments before memory reaches the model.
The workflow maps the directory tree with an explore subagent, excluding folders such as node_modules, .git and build output, builds a work plan by depth level, then generates files level by level so parent references are valid. A template defines each file's layout. The skill also explains a loading caveat: stock Claude Code does not load nested AGENTS.md files, so the hierarchy depends on oh-my-claudecode's hooks being active; otherwise a root CLAUDE.md symlink or an @AGENTS.md import is needed and nested files stay unread.
5 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit 454bae0. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md (its code samples are markdown and bash).
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Hierarchical AGENTS.md Generator loads about 2.3k tokens when it runs. Until then it costs about 20 tokens; SKILL.md has 594 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from Yeachan-Heo/oh-my-claudecode at commit 454bae0, republished under its MIT licence (© Yeachan-Heo). 594 words, ~2,345 tokens.
.claude/skills/deepinit/SKILL.md (or your agent's skills folder).Creates comprehensive, hierarchical AGENTS.md documentation across the entire codebase.
AGENTS.md files serve as AI-readable documentation that helps agents understand:
Every AGENTS.md (except root) includes a parent reference line:
**Parent context:** `../AGENTS.md`This MUST be visible prose, never an HTML comment. Claude Code strips HTML
comments before a memory file reaches the model, so <!-- Parent: ... -->,
<!-- Generated: ... --> and a commented MANUAL boundary are invisible to the
agent that is supposed to act on them.
This creates a navigable hierarchy:
/AGENTS.md ← Root (no parent line)
├── src/AGENTS.md ← **Parent context:** `../AGENTS.md`
│ ├── src/components/AGENTS.md ← **Parent context:** `../AGENTS.md`
│ └── src/utils/AGENTS.md ← **Parent context:** `../AGENTS.md`
└── docs/AGENTS.md ← **Parent context:** `../AGENTS.md`Stock Claude Code discovers nested CLAUDE.md by basename and never loads a
nested AGENTS.md; a root @AGENTS.md import does not reach subdirectories
either. The nested files generated here are delivered by OMC's PostToolUse
directory-context injector, which walks up from each accessed file and injects
the nearest AGENTS.md/README.md once per session.
That means the hierarchy requires OMC's hooks to be active. When OMC hooks are
disabled (DISABLE_OMC=1, OMC_SKIP_HOOKS=post-tool-use) or the plugin is not
registered, add a root-level CLAUDE.md symlink or @AGENTS.md import for the
root file and expect nested files to stay unread.
# {Directory Name}
**Parent context:** `{relative_path_to_parent}/AGENTS.md`
**Generated:** {timestamp} · **Updated:** {timestamp}
## Purpose
{One-paragraph description of what this directory contains and its role}
## Key Files
{List each significant file with a one-line description}
| File | Description |
|------|-------------|
| `file.ts` | Brief description of purpose |
## Subdirectories
{List each subdirectory with brief purpose}
| Directory | Purpose |
|-----------|---------|
| `subdir/` | What it contains (see `subdir/AGENTS.md`) |
## For AI Agents
### Working In This Directory
{Special instructions for AI agents modifying files here}
### Testing Requirements
{How to test changes in this directory}
### Common Patterns
{Code patterns or conventions used here}
## Dependencies
### Internal
{References to other parts of the codebase this depends on}
### External
{Key external packages/libraries used}
## Manual Notes
Notes under this heading are written by humans and preserved on regeneration.Task(subagent_type="explore", model="haiku",
prompt="List all directories recursively. Exclude: node_modules, .git, dist, build, __pycache__, .venv, coverage, .next, .nuxt")Generate todo items for each directory, organized by depth level:
Level 0: / (root)
Level 1: /src, /docs, /tests
Level 2: /src/components, /src/utils, /docs/api
...IMPORTANT: Generate parent levels before child levels to ensure parent references are valid.
For each directory:
When AGENTS.md already exists:
## Manual Notes heading and everything under it are preserved)After generation, run validation checks:
| Check | How to Verify | Corrective Action |
|---|---|---|
| Parent references resolve | Read each AGENTS.md, check the **Parent context:** path exists | Fix path or remove orphan |
| No orphaned AGENTS.md | Compare AGENTS.md locations to directory structure | Delete orphaned files |
| Completeness | List all directories, check for AGENTS.md | Generate missing files |
| Timestamps current | Check the **Generated:** / **Updated:** dates | Regenerate outdated files |
Validation script pattern:
# Find all AGENTS.md files
find . -name "AGENTS.md" -type f
# Check parent references
grep -r "\*\*Parent context:\*\*" --include="AGENTS.md" .| Task | Agent |
|---|---|
| Directory mapping | explore |
| File analysis | architect |
| Content generation | writer |
| AGENTS.md writes | writer |
When encountering empty or near-empty directories:
| Condition | Action |
|---|---|
| No files, no subdirectories | Skip - do not create AGENTS.md |
| No files, has subdirectories | Create minimal AGENTS.md with subdirectory listing only |
| Has only generated files (*.min.js, *.map) | Skip or minimal AGENTS.md |
| Has only config files | Create AGENTS.md describing configuration purpose |
Example minimal AGENTS.md for directory-only containers:
# {Directory Name}
**Parent context:** `../AGENTS.md`
## Purpose
Container directory for organizing related modules.
## Subdirectories
| Directory | Purpose |
|-----------|---------|
| `subdir/` | Description (see `subdir/AGENTS.md`) |# my-project
**Generated:** 2024-01-15 · **Updated:** 2024-01-15
## Purpose
A web application for managing user tasks with real-time collaboration features.
## Key Files
| File | Description |
|------|-------------|
| `package.json` | Project dependencies and scripts |
| `tsconfig.json` | TypeScript configuration |
| `.env.example` | Environment variable template |
## Subdirectories
| Directory | Purpose |
|-----------|---------|
| `src/` | Application source code (see `src/AGENTS.md`) |
| `docs/` | Documentation (see `docs/AGENTS.md`) |
| `tests/` | Test suites (see `tests/AGENTS.md`) |
## For AI Agents
### Working In This Directory
- Always install dependencies after modifying the project manifest
- Use TypeScript strict mode
- Follow ESLint rules
### Testing Requirements
- Run tests before committing
- Ensure >80% coverage
### Common Patterns
- Use barrel exports (index.ts)
- Prefer functional components
## Dependencies
### External
- React 18.x - UI framework
- TypeScript 5.x - Type safety
- Vite - Build tool
## Manual Notes
Custom project notes can be added under this heading.# components
**Parent context:** `../AGENTS.md`
**Generated:** 2024-01-15 · **Updated:** 2024-01-15
## Purpose
Reusable React components organized by feature and complexity.
## Key Files
| File | Description |
|------|-------------|
| `index.ts` | Barrel export for all components |
| `Button.tsx` | Primary button component |
| `Modal.tsx` | Modal dialog component |
## Subdirectories
| Directory | Purpose |
|-----------|---------|
| `forms/` | Form-related components (see `forms/AGENTS.md`) |
| `layout/` | Layout components (see `layout/AGENTS.md`) |
## For AI Agents
### Working In This Directory
- Each component has its own file
- Use CSS modules for styling
- Export via index.ts
### Testing Requirements
- Unit tests in `__tests__/` subdirectory
- Use React Testing Library
### Common Patterns
- Props interfaces defined above component
- Use forwardRef for DOM-exposing components
## Dependencies
### Internal
- `src/hooks/` - Custom hooks used by components
- `src/utils/` - Utility functions
### External
- `clsx` - Conditional class names
- `lucide-react` - Icons
## Manual NotesWhen running on an existing codebase with AGENTS.md files:
© Yeachan-Heo, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in skills/deepinit of Yeachan-Heo/oh-my-claudecode.
Open the folder on GitHubat commit 454bae0
Hierarchical AGENTS.md Generator next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Hierarchical AGENTS.md Generator this skillYeachan-Heo/oh-my-claudecode | 40k | — | ~2.3k | Automated safety check: Pass | MIT | |
| Analyze Codebasedivar-ir/ai-doc-gen | 766 | — | ~899 | Automated safety check: Pass | MIT | |
| Claude Project Bootstrapmp-web3/claude-starter-kit | 109 | — | ~1.9k | Automated safety check: Notes | MIT | |
| Init Deep AGENTS.md Generatorcode-yeongyu/oh-my-openagent | 70k | — | ~3.5k | Automated safety check: Pass | Custom licence | |
| Codebase Onboardingaffaan-m/ECC | 275k | 1 repos | ~1.1k | Automated safety check: Pass | MIT | |
| Codebase Onboardingaffaan-m/ECC | 275k | — | ~270 | Automated safety check: Pass | MIT |
divar-ir/ai-doc-gen
Run a multi-agent deep analysis of a codebase, producing AI-readable analysis documents in .ai/docs/ covering structure, dependencies, data flow, request flow, and APIs.
mp-web3/claude-starter-kit
Sets up a project for Claude Code by surveying it and writing a .claude folder with a short CLAUDE.md, a CODEBASE.md overview, module docs and optional skills and hooks.
code-yeongyu/oh-my-openagent
Generates a tree of AGENTS.md files for a repository, one at the root and more in complex subdirectories, so agents learn its structure and conventions.
affaan-m/ECC
分析一个陌生的代码库,并生成一个结构化的入门指南,包括架构图、关键入口点、规范和一个起始的CLAUDE.md文件。适用于加入新项目或首次在代码仓库中设置Claude Code时。
affaan-m/ECC
不慣れなコードベースを分析し、アーキテクチャマップ、主要なエントリポイント、規約、スターターCLAUDE.mdを含む構造化オンボーディングガイドを生成します。新しいプロジェクトに参加するか、リポでClaude Codeを初めてセットアップする場合に使用します。
affaan-m/ECC
Analyze an unfamiliar codebase and generate a structured onboarding guide with architecture map, key entry points, conventions, and a starter CLAUDE.md.
Yeachan-Heo/oh-my-claudecode
Takes a short product idea through requirements, design, planning, parallel implementation, QA cycles and multi-reviewer validation to produce working code.
Yeachan-Heo/oh-my-claudecode
Installs and configures the oh-my-claudecode heads-up display in the Claude Code statusline, with minimal, focused and full layouts.
Yeachan-Heo/oh-my-claudecode
Runs an autonomous improvement loop on a repository: agents propose and execute plans, a tournament picks the winner by benchmark, and each round is recorded and plotted.
Yeachan-Heo/oh-my-claudecode
Sends a question or task to another locally installed agent CLI, such as Codex or Gemini, through omc ask and saves the answer as a file.
Yeachan-Heo/oh-my-claudecode
Charts a foggy effort into a map of decision tickets on the repo's issue tracker and works through them one per session, producing decisions rather than deliverables.
Yeachan-Heo/oh-my-claudecode
Detects and gracefully cancels whichever OMC mode, autopilot, ralph, swarm, pipeline, or team, is currently active, then clears its state.
Categories
Maps a codebase directory by directory and writes linked AGENTS.md files, each pointing to its parent, to document what each area contains. md documentation across a whole codebase so agents can learn what each directory contains, how components relate, any special instructions for that area, and its dependencies.md, written as prose rather than an HTML comment because Claude Code strips comments before memory reaches the model.
Hierarchical AGENTS.md Generator fits situations like: initializing AI-readable documentation across a large codebase; creating nested AGENTS.md files that describe each directory; refreshing agent documentation after a big restructure.
Run `npx skills add Yeachan-Heo/oh-my-claudecode --skill deepinit -a claude-code`. Or copy the skill folder (skills/deepinit in Yeachan-Heo/oh-my-claudecode) into .claude/skills/deepinit in your project. Claude Code loads it when a task matches its description.
Run `npx skills add Yeachan-Heo/oh-my-claudecode --skill deepinit -a codex`. Or copy the skill folder (skills/deepinit in Yeachan-Heo/oh-my-claudecode) into .agents/skills/deepinit in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add Yeachan-Heo/oh-my-claudecode --skill deepinit -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/deepinit, .gemini/skills/deepinit, .github/skills/deepinit and .opencode/skills/deepinit in your project.
SKILL.md names no scripts, command-line tools or credentials: Hierarchical AGENTS.md Generator is instructions for the agent only. Our summary lists: oh-my-claudecode hooks, so that nested AGENTS.md files are actually loaded.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Hierarchical AGENTS.md Generator is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.3k tokens (SKILL.md is roughly 9.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Hierarchical AGENTS.md Generator: Analyze Codebase (divar-ir/ai-doc-gen, 766 stars), Claude Project Bootstrap (mp-web3/claude-starter-kit, 109 stars), Init Deep AGENTS.md Generator (code-yeongyu/oh-my-openagent, 70k stars) and Codebase Onboarding (affaan-m/ECC, 275k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
Yeachan-Heo (a GitHub user) maintains it in Yeachan-Heo/oh-my-claudecode, which has 39,662 GitHub stars. The repository holds 47 skills in this directory. The repository was last updated on October 7, 2026.
Source: Yeachan-Heo/oh-my-claudecode on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.