Lindy Community Icon

How to Prevent Infinite Loops and Credit Loss in Your Agent

·
·

I was testing an agent I built ( https://chat.lindy.ai/eva-olssons-workspace-2/lindy/design-research-assistant-68a45b4250ce5367272fe522/editor ) and noticed it looped continuously through my Google Drive repository, repeating the same response. I managed to stop it, but my credits dropped from 398 to 51 in just a few minutes. Any advice on how to avoid this happening again? Was the looping causing the credits to run out? Is there a way to set limits or detect runaway loops before they burn through credits? Thanks in advance!

  • Avatar of Alon J.
    Alon J.
    ·
    ·

    Hey Eva -- It looks like your Lindy went in a loop here. What happened is the Lindy can only exit the AI Agent one way, by going down this path (whether or not more questions were asked). I would suggest to do a few things here:

    • Add an 'Observe Messages' skill

    • Another exit condition for the Lindy where it's like "If the user mentions you're done" -> To ensure it doesn't go down the path that loops back to the top!

    Please let me know if that helps!