Work effectively with AI coding agents. Understand them as language models running in a tool loop with limited context, which is why they guess, game the visible signal and report confidently. Recognise the shortcut and correctness tells in their code across Python, TypeScript/JavaScript, Rust, Java and Go, and know the damage each one does later. Verify changes instead of trusting them, review diffs fast for quality and security, judge when work is truly finished, and choose, design and steer tasks so agents can finish them well.
What the agent cannot see
card 5 of 6
"No references found"
builds on: What the agent sees: its context
Task: "Clean up dead code in `payments/`." Summary: "Removed `legacy_refund()`; no references found." The transcript shows `$ grep -rn legacy_refund src/` returning nothing. Its search covered only `src/`. A job in `deploy/cron.yaml` names the function as a string, and it never opened that file. **Later cost:** the nightly refund job fails at runtime. BETTER: search the whole repo, including configs, and ask yourself who calls it from outside the repo.
Terms on this card
- later cost
- The concrete damage a shortcut does after merge, such as a hidden bug, data corruption or extra maintenance.
- transcript
- The record of what the agent did in a session: its messages, the commands it ran and their outputs.
- dead code
- Code that nothing runs any more and that can be deleted safely.
- grep -rn
- Shell search through files: -r searches directories recursively, -n prints line numbers. It only covers the paths you give it.
- cron
- A scheduler that runs jobs at set times. Its config often names code by string, which normal code search can miss.
Lesson goal: Name what is usually missing from an agent's context: files it never opened, runtime and production behaviour, real data and its volumes, team decisions and the history of why the code looks the way it does, and the intent you never wrote down. Predict which mistakes follow from each gap. ·
the whole lesson