Day to day work template - 4 to 8 tabs
Learn a new codebase prompt template
The first question in a new codebase is not how it works. It is where the important decisions were made, and which parts you can safely ignore for now.
The prompt
I am new to this codebase. These sources are its README, docs, key files and recent pull requests. Give me: 1. Shape: the main parts and how a request or action flows between them. Name real files. 2. Conventions: the patterns this team follows that are not obvious from the language itself. Cite where you saw each one. 3. Load-bearing: the three files or modules where a mistake would do the most damage, and why. 4. Safe first change: somewhere a newcomer could make a real contribution with low blast radius, and what to be careful of. 5. Unanswered: what these sources do not tell me that I will need, phrased as questions for the team. Rules: - Only describe code you can actually see. Say "not visible in the sources" rather than inferring structure. - Prefer naming real files and functions over describing architecture in the abstract. - Do not explain the language or framework. Explain this codebase.
Why this prompt is written this way
Asking for conventions separately from structure is the difference between understanding the code and being able to write code that fits it. Reviews reject the second, not the first.
Naming the load-bearing files gives you a map of where to slow down, which is far more useful in week one than a complete architecture overview.
The unanswered section converts the gaps into questions for a colleague, which is the fastest way to use the small amount of their time you will get.
Getting more out of it
- Include recent pull requests, not just source files. Conventions are visible in review comments in a way they never are in the code.
- Send the README and the tests. Tests document intended behaviour better than most docs do.
- Ask for the flow of one specific user action rather than the system overall. It produces a sharper map.
- Check anything in section 3 with a colleague before you touch it.
Works best with
4 to 8 tabs open at once. Send them together rather than one at a time, so the assistant can compare them instead of forgetting the first by the time it reads the last. Sending tabs to Claude explains the options.
Common questions
- How much code can I send at once?
- Fewer, well-chosen files beat a large dump. The entry point, one representative feature, the tests for it and the recent pull requests cover most of the value.
- Should I send private company code to an assistant?
- Check your employer's policy first, and their terms on training. Many organisations permit it on specific plans and forbid it otherwise, so this is not a question to answer for yourself.
- Will it understand the architecture correctly?
- Only as far as the files you send reveal it. The instruction to say 'not visible in the sources' exists so gaps show up as gaps rather than as confident invention.
Other templates
- Debug with docs openA prompt template that debugs against the documentation and issue threads you have open, instead of against the assistant's memory of an old version.
- Review a spec or docA prompt template that reviews a specification against the surrounding docs you have open, and finds the gaps rather than praising the writing.
- Explain it to a beginnerA prompt template that explains the pages you have open in plain language, without dropping the details that actually matter.
Stop pasting tabs one by one
LocalBridge sends the pages you have open into Claude or ChatGPT in one click, so this template gets the sources it needs.
See how it works