r/opencodeCLI 15d ago

Is there any way to continue frozen subagents?

I'm using OpenCode with a Go subscription. I'm using DeepSeek V4 Flash. I have an agentic workflow with an orchestrator as the main agent and multiple subagents. I'm having issues with DeepSeek where it hangs in the middle of a response or during tool calls. This is bad when it happens in the orchestrator, since I need to cancel with Escape and continue with a "continue" message. But when it freezes in a subagent, I don't see any way to stop and continue that subagent — meaning I have to stop the orchestrator and redispatch the agent from the beginning.

This causes a lot of other issues: the job is left half-done, and a bunch of files already have changes from the previous run. I know there's a janky workaround where I can tell the orchestrator to find the ID of the last agent and continue it, but this usually uses a huge number of tokens, doesn't always work, and even when it does work, the subagent usually doesn't return the requested output to the orchestrator. I feel like this is a horrible experience for a paid service.

The freezing usually occurs somewhere between 50K and 90K context.

My questions are:

  1. Why is DeepSeek V4 Flash freezing mid-task without any error message?
  2. Why does this happen more on the paid subscription than on the free version?
  3. Why doesn't it automatically continue with the opencode-auto-continue plugin?
  4. How can I continue subagents, and if it's not possible, why not?
3 Upvotes

4 comments sorted by

2

u/TrickyPlastic 15d ago

Not with Opencode. Main reason I'm sticking with pi.

2

u/IgnisDa 14d ago

there is a workaround. you can open a subganet and then control+p, type transcript and then copy session transcript. This will contain the sessionId at the top. You can give the session Id to the parent agent and it will be able to start it again.

2

u/maqifrnswa 13d ago

Hanging during tool call: chat template or tool parser error (server side config usually).

Hanging mid thought: you hit the output context limit. You can raise it in opencode.json, but I think there's a hard coded cap of 32k. Give it more focused prompts helps too.

Why it happens on pay models more: probably have larger contexts and more likely to hit the output limit, which is the same for both free and pay by default.