You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Agent stuck in an infinite loop [Minimax-2.7, any mode] #19267
When asking a simple question using Minimax-2.7 using any mode, the session gets infinitely compacted, and the agent is stuck in an infinite loop.
From what I tested, it also happens with Minimax-2.5, on any sort of project.
Plugins
No response
OpenCode version
1.3.2
Steps to reproduce
Have Context7 installed.
Use the minimax provider.
Clone this repository
In plan mode, using MiniMax-M2.7, prompt "@general In this repo, we're using express, use Context7 to give me doc relative to the version of express we're using"
I also noticed this issue, I'm using minimax 2.7 from minimax.io and minimax 2.7 high speed, I noticed the high speed model does this more often but both of them do it
Sharing my experience with infinite compaction on m2.7
I greeted the agent in opencode then it got automatically compacted over and over
I tested with kimi and got
In my case, somehow opencode loaded up all skills (from project and claude global), instead of using it per manual invocation like many other IDE.
For your case, maybe you can do the same check with a bigger context model and ask what the initial context is filled with.
@manugerahgunawan thanks for your feedback : I have the same problem, it loads all of my MCPs and skills, which fills up the whole context and causes an infinite compaction
Activity
github-actions commentedon Mar 26, 2026
This issue might be a duplicate of existing issues. Please check:
Please review these issues and comment if yours is distinct, so we can avoid duplicating effort.
buithehien1991 commentedon Mar 26, 2026
+1
Ownistic commentedon Apr 11, 2026
I also noticed this issue, I'm using minimax 2.7 from minimax.io and minimax 2.7 high speed, I noticed the high speed model does this more often but both of them do it
neuhaus commentedon May 1, 2026
That's not an opencode bug, that's an issue with the LLM or more likely the LLM provider because they did a bad job.
manugerahgunawan commentedon May 13, 2026
Sharing my experience with infinite compaction on m2.7

I greeted the agent in opencode then it got automatically compacted over and over
I tested with kimi and got

In my case, somehow opencode loaded up all skills (from project and claude global), instead of using it per manual invocation like many other IDE.
For your case, maybe you can do the same check with a bigger context model and ask what the initial context is filled with.
gregoire-galadrim commentedon May 20, 2026
@manugerahgunawan thanks for your feedback : I have the same problem, it loads all of my MCPs and skills, which fills up the whole context and causes an infinite compaction
MassEast commentedon May 21, 2026
Putting the below into my
settings.jsonhelpedgithub-actions commentedon Jul 21, 2026
To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.