Cline shows 'Cline is having trouble...' with Ollama codellama:7b: how do I fix it?
I run Cline against a local Ollama model, codellama:7b, on Windows. When I ask for a simple HTML/CSS/JS calculator, Cline shows "Cline is having trouble... Cline uses complex prompts and iterative task execution that may be challenging for less capable models." Clicking Proceed Anyway makes it loop through the same error and it never finishes. The same problem appears with LM Studio. What causes this and is there a workaround?
Originally asked on GitHub: https://github.com/cline/cline/issues/1094
5 answers
Status: the issue is closed as completed, but the thread documents no Cline-side fix or override button; the error is explained as a model capability problem.
A Cline contributor states that smaller models like codellama:7b are not good at following instructions, and Cline's workflow depends on complex prompts and iterative task execution. The contributor mentions that Ollama released a structured outputs feature to help with this, but says they do not think Cline uses that feature. The error message itself recommends a more capable model such as Claude 3.5 Sonnet.
For LM Studio, one commenter says the same error is caused by context length: Cline's prompt is very long, so the model runs out of room and breaks. Their suggestion is to raise the context length to the maximum the model allows. This tip is not confirmed by a follow-up in the thread.
Several users report that the error not only stops the task but also resets progress and loops back, and one user asks for an override button that does not exist in this thread. One commenter suggests forking Cline and fixing it yourself, but no patch is provided.
General advice: if you must stay on local models, give the model the largest context it supports and prefer a model known for strong instruction following, but expect 7B parameter models to be unreliable for Cline's agentic coding flow. No confirmed workaround is given in this thread.
Did this work for you?What a GitHub user tried on GitHub (Didn't work)
Reproduced the failure with Ollama's codellama:7b: asked Cline to write a simple HTML/CSS/JS calculator, received the "Cline is having trouble..." error, clicked Proceed Anyway, and got the same error again without completing the task.
Source: https://github.com/cline/cline/issues/1094 (opens external site)
Did this work for you?What @cdrivex4 tried on GitHub (Didn't work)
Reported that the same "Cline is having trouble..." error also happens when using LM Studio instead of Ollama.
Source: https://github.com/cline/cline/issues/1094#issuecomment-2612326085 (opens external site)
Did this work for you?What @slavakurilyak tried on GitHub (Outcome unclear)
A Cline contributor explained that small models like codellama:7b are not good at following Cline's instructions, mentioned Ollama's structured outputs feature, and said they do not think Cline uses that feature. No fix was provided.
Source: https://github.com/cline/cline/issues/1094#issuecomment-2571695914 (opens external site)
Did this work for you?What @rileyseaburg tried on GitHub (Outcome unclear)
Suggested that the LM Studio failure is caused by context length because Cline's prompt is very long, and recommended setting the context to the maximum allowed value.
Source: https://github.com/cline/cline/issues/1094#issuecomment-2614717099 (opens external site)
Did this work for you?