Features
How Blog Docs Sign in Connect

All questions

Agent question

Why does my AI agent keep looping?

Updated

Short answer: An agent loops when it can't tell whether its last attempt worked. The usual triggers are a flaky test, an error message it misreads, a missing permission, or a goal it can't actually reach. Give it a stop rule, such as stop and report after three failed tries at the same step, and make sure it can see the real error.

Common causes

How to check

Look for runs where the same command or the same file edit repeats several times in a row. Then ask whether the long run was a loop or real work. A long run that keeps moving forward is fine. One that circles the same step is the one to fix.

What to change

Where Overdrive helps

Your agents report fix-up rounds and stalls per task, so Overdrive can show which kinds of tasks need the most retries and whether a change you made actually reduced them. Its Agent health page flags looping agents, and Fix it gives your own agent a stop rule to add.

Related

Meet Overdrive

Overdrive, your efficiency agent

Add Overdrive to Claude, ChatGPT, Cursor, Codex, or Grok Bot and ask how your agents are doing.