Openclaude context looping issues #2015
|
Does anyone know why OpenClaude starts hallucinating and repeating the same task multiple times? Just to clarify, I don't believe this is an issue with the provider/model itself, but rather a problem specific to OpenClaude. I use Mino with opencode, which never hallucinates, yet I consistently encounter these issues with OpenClaude. How can I fix this? also note: i am using latest openclaude with nodejs version 24 LTS |
Replies: 1 comment
|
This is a common issue with OpenClaude and usually comes down to the system prompt or tool configuration. Since you confirmed other clients (opencode) work fine with the same model, the problem is specific to how OpenClaude manages the agent loop. Most likely causes and fixes1. Check your system prompt for tool usage instructionsOpenClaude's default behavior can be too aggressive with tool calls. If the system prompt says something like "use tools to solve the task," the agent may enter a loop: call tool → get result → call tool again → repeat. Fix: Add explicit stop conditions to your system prompt: 2. Check
|
This is a common issue with OpenClaude and usually comes down to the system prompt or tool configuration. Since you confirmed other clients (opencode) work fine with the same model, the problem is specific to how OpenClaude manages the agent loop.
Most likely causes and fixes
1. Check your system prompt for tool usage instructions
OpenClaude's default behavior can be too aggressive with tool calls. If the system prompt says something like "use tools to solve the task," the agent may enter a loop: call tool → get result → call tool again → repeat.
Fix: Add explicit stop conditions to your system prompt: