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.
Ask for a plan before code
card 1 of 6
400 lines built on two quick guesses
builds on: Why agents fill gaps with plausible guesses
You ask the agent to "cache product lookups, they're slow". Twenty minutes later it reports success: tests green, 9 files changed, a new third-party caching package and a cache wrapper of its own. Your codebase already has a cache helper, and prices must never be more than a minute stale. You now face 400 lines built on two guesses you would have rejected in seconds.
Terms on this card
- the agent
- The AI coding system doing the work: a chat assistant, IDE agent or terminal agent.
- green
- A test or check that passes.
- 400
- HTTP status code 'Bad Request': the server rejects the request because its input is invalid.
- helper
- A small function that does one common job, such as formatting or checking a value, so other code can call it instead of repeating it.
- tests green
- All tests pass.
Lesson goal: Have the agent explore and propose a plan, listing the files it will touch, its approach and its assumptions, before it edits anything. Correct wrong assumptions at the plan stage, where they are cheap to fix. ·
the whole lesson