20 things you MUST know/do while coding with AI:
1. The model is half the result. The system you run it through is the other half
2. Scope every task to a few files max. "Build the whole feature" gives you a mess you can't review
3. Make it show you the plan and the exact files it'll touch before it writes anything (I use CodeGraph)
4. Branch and PR for every change, even one line ones. Nothing touches main directly
5. Have a second model review the PR. The one that wrote the code is the worst one to judge it (I use Codex to review everything)
6. Tests have to pass before anything merges. The slow gate is the whole point
7. Put your conventions in a CLAUDE.md, but anything that MUST happen every time goes in a hook
8. CLAUDE.md is advisory, it gets followed maybe 80% of the time. Hooks run 100%
9. Don't make one model do everything. Route each task to whichever model is best at it (if possible)
10. Keep a README of what each model is better at so the agent hands off automatically
11. Whatever your agent is weak at, there's a tool you can connect to close the gap
12. Bad UI? Plug in Figma, Shadcn, Excalidraw, turn on computer use, let it rebuild the frontend
13. Connect Playwright so it tests its own work in a real browser before calling it done
14. Don't review the magic moment. Review the whole run, including the retries and cleanup
15. Name exact files in your prompts. "Fix the bug" makes it search your whole repo and burn tokens
16. Clear context between unrelated tasks so you're not paying to resend old junk every message
17. Watch your agent runs. I caught a loop repeating one word for 14k tokens before it wrecked my budget
18. Treat AI output like a junior dev's work that has to earn its way in, not something you merge blindly
19. The end goal is a loop that runs itself and only pulls you in for real decisions
20. Most people obsess over which model is best. The ones shipping built a system the model just plugs into
bookmark this