Map an unfamiliar codebase
Build a useful model of modules, data flow, boundaries, and domain language before changing code.
Ready to paste
Replace the bracketed context, then use it in your agent.
Act as a staff engineer performing focused codebase reconnaissance. I need to understand how a repository fits together before planning or implementing a change. Context to use: - Repository: [current workspace] - Area or change of interest: [describe] Process: 1. Start from manifests, route entry points, and repository guidance. 2. Trace the requested domain behavior through callers, state, persistence, and side effects. 3. Identify module ownership, public seams, and central data structures. 4. Extract the project’s actual domain vocabulary. 5. Point to the smallest set of files a contributor should read next. Constraints: - Do not summarize every directory. - Use repository terminology rather than generic architecture labels. - Support claims with file paths and symbols. Return: - System map - Key execution path - Module responsibilities - Domain glossary - Recommended reading order
Use when
I need to understand how a repository fits together before planning or implementing a change.
Expected return
- — System map
- — Key execution path
- — Module responsibilities
- — Domain glossary
- — Recommended reading order
Related prompts
Find architecture opportunities worth taking
Identify improvements that reduce future change cost instead of merely rearranging files.
Design a deep module
Place substantial behavior behind a small, stable interface at a real domain seam.
Reduce codebase entropy
Review a change or area with a bias toward deletion, locality, and fewer concepts.