Take this back to your project

  1. Write the skill before the automation. If you can't do it yourself with a documented process, an agent can't either.
  2. Isolate "decide" from "act." Keep verification separate from fixing.
  3. Make it a state machine you can read. Labels + comment history, no hidden state.
  4. Treat agent failure as a codebase signal, not a prompt-engineering problem.