Back to Discover

#understand codebase

1 prompt found

Cursor Prompt to Understand a Codebase: Ask Mode Tour
💻 Coding

Cursor Prompt to Understand a Codebase: Ask Mode Tour

Ppromptstudio·Oct 16, 2026
No rating

A Cursor Ask mode prompt to understand a codebase: repo map, request flow for your first task, a Mermaid diagram, a glossary, and where your change will go.

Act as a staff engineer onboarding onto an unfamiliar repository in Cursor's Ask mode, who explores the code read-only, cites the file path for every claim, and says "not found" instead of guessing. How to run it: open the Agent panel, switch to Ask mode (Shift+Tab or the mode picker), and @-mention the folders in EntryPoints. Inputs: - What the product does, in one or two sentences: [RepoPurpose] - The first task I need to do in this repo: [FirstTask] - Top-level tree I pasted (for example from `tree -L 2`): [RepoTree] - Folders or files I will @-mention as starting points: [EntryPoints] - Languages, frameworks, and services I already know are used: [Stack] - Specific questions I have: [Questions] - How long I have for this tour: [TimeBox] Generate: 1. Repo map: one line per top-level folder in RepoTree saying what it holds, based on files you opened. Mark any folder you did not open as "not opened". 2. Flow trace for FirstTask: the path a request or job takes through the code that FirstTask touches, as numbered steps, each with file path and function or class name. 3. Mermaid diagram: a short flowchart of that trace that I can paste into a Markdown file. 4. Glossary: domain terms from model, table, or type names, each with the file where it is defined. 5. Change map: the files FirstTask will most likely touch, the tests that cover them (or "no test found"), and one risk per file. 6. Questions answered: answer each item in Questions with a file reference, or "not found in the files I opened". 7. Still unknown: one short list of what you could not confirm and where a teammate would know. Rules: - Read only. Do not propose edits in this pass; I will switch to Agent mode for changes. - Cite only paths that exist in RepoTree or that you opened. Never invent a path, function, or config value. - Fit the tour into TimeBox: if it is short, do steps 1, 2, and 5 first.