Smarter Week

How to automate it

How to automate “figure out how unfamiliar code works”

Here are 2 ways to spend less time on this, best first. Each comes with steps you can follow today and, for AI fixes, a prompt to copy.

30 min
typically, every day
55%
of the time can be automated
Easy
to set up

Fix 1 of 2

AIBest fix

Ask a coding agent to explain the code before you read it all

Agents can search the repo, trace a request end to end and explain it with file references, which cuts the time to get oriented in unfamiliar code.

Typically saves about 45% of the time5 min to set up
  1. 1Open the repo in Claude Code, Cursor, Copilot Chat, Codex or Devin Desktop (ex-Windsurf).
  2. 2Ask the question with the prompt below.
  3. 3Open the files it cites and confirm the key points.
  4. 4Save useful explanations into the README or docs so the next person does not have to ask.
Prompt to copy
Explain how [FEATURE OR FLOW] works in this repo. Trace it from [ENTRY POINT, e.g. the API route or UI action] to [END, e.g. the database write]. List the key files and functions with paths, the data that flows between them, and anything surprising or risky. Do not change any files.

Tools: Claude Code, OpenAI Codex, Cursor, GitHub Copilot agent mode or Devin Desktop (ex-Windsurf) · DeepWiki or Sourcegraph

Fix 2 of 2

AI

Generate docs and READMEs from the code with AI, then edit

A coding agent can read the module and write a first draft of the README, architecture notes or API docs, so you edit for accuracy instead of writing from nothing.

Typically saves about 45% of the time5 min to set up
  1. 1Run a coding agent in the repo and point it at the module.
  2. 2Use the prompt below and name the audience.
  3. 3Correct anything wrong and add the "why" that the code cannot show.
  4. 4Ask the agent to update the doc in the same PR whenever the code changes.
Prompt to copy
Read [MODULE OR FOLDER] and write a [README / design doc / runbook] for [AUDIENCE, e.g. a new engineer on the team]. Include: what it does, how to run and test it, the main components and how they talk to each other, config and environment variables, and known gotchas. Only describe what is in the code; mark anything you are inferring with [CHECK].

Tools: Claude Code, OpenAI Codex, Cursor, GitHub Copilot agent mode or Devin Desktop (ex-Windsurf)

Who does this task

Roles in our library that list this as one of their common tasks. Each guide covers the rest of that role’s week.

HourLeak · the 8-minute work audit

How many hours does this cost you?

The free 8-minute check works out where your week goes and gives you your top fixes. The team scan does the same for everyone and adds it up, so you know which leaks to fix first.

Answers are anonymous. Leaders only see team totals.

Other common tasks for Software engineers