Coding agents usually do not drift because they are incapable. They drift because the task leaves too much room for interpretation.
A request like “clean up authentication” sounds clear to a human who already knows the codebase. To an agent, it can mean anything from renaming one helper to replacing the entire authentication stack.
The fix is not a longer prompt. It is a brief with four explicit parts:
Outcome
Context






