Why instructions matter
An AI coding agent does exactly what its context tells it — no more. Good project instructions are how you steer it toward your conventions and away from the patterns you've rejected.
The difference between a useful agent and a frustrating one is usually the quality of its instructions, not the model.
Be specific and imperative
Write directives, not vibes. 'Use the existing API client in lib/http for all requests' beats 'follow good practices'. Use clear MUST/avoid language and concrete names.
Specificity removes guesswork. The more precise the instruction, the less the agent improvises in directions you don't want.
Encode constraints and anti-patterns
Spell out the hard rules: 'never call the payments API directly', 'all timestamps are UTC', 'don't add new dependencies without flagging it'. Agents won't infer your non-negotiables.
Listing the anti-patterns you've already rejected is as valuable as listing what to do — it stops the agent rediscovering bad ideas.
Show, don't just tell
Include short examples of the conventions you want — a sample component, a preferred error-handling shape, a commit-message format. Examples communicate faster than prose.
One good example often replaces a paragraph of description and leaves far less room for misinterpretation.
Persist and maintain
Put the instructions in a project file the agent reads every session, not in a prompt you retype. That's the only way they survive across sessions and teammates.
Review them like code and keep them current; outdated instructions are worse than none because the agent follows them with confidence.