Uh oh!
There was an error while loading. Please reload this page.
fix(opencode): inherit thinking level (variant) in task tool subtasks - #20811
fix(opencode): inherit thinking level (variant) in task tool subtasks#20811jbmml wants to merge 1 commit into
Conversation
The task tool was not passing the parent session's thinking level to spawned subtasks. The variant field was available on the assistant message but was not forwarded to SessionPrompt.prompt(), causing all subtasks to use the default thinking level. Fixesanomalyco#20810 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The following comment was made by an LLM, it may be inaccurate: Potential duplicate PRs found:
You should check #20742 first since it appears to be a recent fix for the same issue that PR #20811 is addressing. |
jbmml
commented
Apr 3, 2026
Closing in favor of #20742 which is a more comprehensive fix covering the same issue across ACP, message schema, prompt, task, and tests. Our PR only addressed the task.ts path. |
Issue for this PR
Fixes#20810
Type of change
What does this PR do?
The task tool spawns subtasks via
SessionPrompt.prompt()but doesn't pass the parent session's thinking level (variant). The variant is already on the assistant message (msg.info.variant) andPromptInputalready accepts it — this just wires them together.The internal subtask path in
prompt.ts(line 572) already does this correctly (variant: lastUser.variant). This PR makes the external task tool path consistent.How did you verify your code works?
MessageV2.Assistant(line 445) →msg.info.variant(task.ts line 105) →SessionPrompt.prompt()→PromptInput.variant(prompt.ts line 1753)PromptInputalready accepts and usesvariant(prompt.ts line 968)Checklist