### Description 核心问题:task 工具创建子 agent session 时不读取 agent.md frontmatter 的 model 字段,而是继承 primary agent 的 model。导致 per-agent model 配置完全失效。 复现步骤: 配置 supervisor.md model: provider/GLM-5.2,data-engineer.md model: provider/Qwen3.8-27B opencode debug agent data-engineer 确认配置被正确解析(modelID=Qwen3.8-27B) supervisor 通过 task 工具派发 data-engineer 检查 workspace dat 的 workspace:model-selection,子 session 实际用 GLM-5.2 根因:task 工具创建新 session 时不传递 agent 配置的 model,继承父 session model 选择。 期望行为:task 工具应使用子 agent 配置的 model,仅在未配置时回退到父 session model。 证据文件:opencode.workspace.<hash>.dat 中的 workspace:model-selection 字段 环境影响:无法为不同专业 agent 分配不同模型(如推理模型给 supervisor、代码生成模型给 simulation-agent) ### Plugins _No response_ ### OpenCode version OpenCode v1.16.42 ### Steps to reproduce _No response_ ### Screenshot and/or share link _No response_ ### Operating System _No response_ ### Terminal _No response_
Activity
github-actions commentedon Aug 24, 2026
This issue might be a duplicate of existing issues. Please check:
Please review those issues to see if your report is already tracked there.
thdxr commentedon Oct 11, 2026
Thanks for the report! OpenCode 2.0 is now out and development is focused on V2, so we're closing issues filed against OpenCode 1. Please upgrade (
opencode upgrade --major, details: https://anoma.ly/notes/opencode-2-0), and if this is still relevant on 2.0, reopen this issue or open a new one with your 2.0 version.— from 𝕺𝖕𝖊𝖓𝕮𝖔𝖉𝖊