Creative Genius Creative Genius
Lesson 3 of 4 · 16 min read

Stop Conditions: Don't Burn $1000 in 3 Minutes

An unbounded agent loop is how startups die. Here's how to bound them.

Every agent loop needs hard limits:

  • Max iterations. 8–12 for most workflows. Abort and fail loudly past that.
  • Max tokens. Sum input + output across the loop. Stop at $X budget per request.
  • Max wall time. A 10-minute agent is almost always broken.
  • Repetition detection. If the agent calls the same tool with the same args 3+ times in a row, abort.
← Tool Use Fundamentals Observability Is Not Optional →