agentlens
Navigate and understand codebases using agentlens hierarchical documentation. Use when exploring new projects, finding modules, locating symbols in large files, finding TODOs/warnings, or understanding code structure.
When & Why to Use This Skill
AgentLens is a specialized codebase navigation skill designed to solve the complexity of understanding large-scale software projects. It addresses the 'information overload' problem by providing a hierarchical documentation framework (INDEX, MODULE, and outline maps), allowing developers and AI agents to grasp project structures, locate specific symbols, and identify technical debt without manually parsing thousands of lines of source code. This significantly enhances context management and speeds up the development lifecycle.
Use Cases
- Rapid Project Onboarding: Use the hierarchical INDEX.md to quickly understand the high-level architecture and module distribution of a new or unfamiliar codebase.
- Precise Symbol Discovery: Locate specific functions, classes, or variables within massive files using outline.md, avoiding the need to read through irrelevant code sections.
- Technical Debt & Rule Tracking: Consolidate and review all TODOs, warnings, and critical business rules across modules via memory.md before performing refactoring or feature updates.
- Dependency Mapping: Analyze file-level dependencies and import structures using imports.md to ensure architectural integrity and prevent circular dependencies.
| name | agentlens |
|---|---|
| description | Navigate and understand codebases using agentlens hierarchical documentation. Use when exploring new projects, finding modules, locating symbols in large files, finding TODOs/warnings, or understanding code structure. |
| short-description | Codebase navigation with agentlens |
| author | agentlens |
| version | "1.0" |
AgentLens - Codebase Navigation
Before Working on Any Codebase
Always start by reading .agentlens/INDEX.md for the project map.
Navigation Hierarchy
| Level | File | Purpose |
|---|---|---|
| L0 | INDEX.md |
Project overview, all modules listed |
| L1 | modules/{slug}/MODULE.md |
Module details, file list |
| L1 | modules/{slug}/outline.md |
Symbols in large files |
| L1 | modules/{slug}/memory.md |
TODOs, warnings, business rules |
| L1 | modules/{slug}/imports.md |
File dependencies |
| L2 | files/{slug}.md |
Deep docs for complex files |
Navigation Flow
INDEX.md → Find module → MODULE.md → outline.md/memory.md → Source file
When To Read What
| You Need | Read This |
|---|---|
| Project overview | .agentlens/INDEX.md |
| Find a module | INDEX.md, search module name |
| Understand a module | modules/{slug}/MODULE.md |
| Find function/class in large file | modules/{slug}/outline.md |
| Find TODOs, warnings, rules | modules/{slug}/memory.md |
| Understand file dependencies | modules/{slug}/imports.md |
Best Practices
- Don't read source files directly for large codebases - use outline.md first
- Check memory.md before modifying code to see warnings and TODOs
- Use outline.md to locate symbols, then read only the needed source sections
- Regenerate docs with
agentlenscommand if they seem stale
For detailed navigation patterns, see references/navigation.md For structure explanation, see references/structure.md