How to build with rules, skills, hooks and subagents around a coding agent
Prologue
For a while, I thought the problem was the model.
The agent would put a network call straight inside a screen component, and I would add a sentence to the next request: keep network calls out of the components. It would write a date-formatting helper when one already existed two folders away, and I would add another sentence. The requests got longer. The instructions file got longer. On the days the agent followed all of it, I took that as proof that the setup worked. On the days it followed none of it, I blamed the model.
It took me longer than I would like to admit to do the obvious thing, which was to stop writing and go look at what the tool was actually loading.
The rules I had written with the most care had never been read, not once. Their path patterns expected folder names that were different from the real ones.…