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
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
背景与动机
子代理(subagent)spawn 时目前没有独立的模型配置入口:
resolveChildAgentOptions()(dsh-subagent/lib/index.js)把父会话的{provider, model, maxTokens}直接继承给子代理,spawn 请求侧只有 workflow 的agent(prompt, {provider, model})能显式覆盖,而subagent工具的 schema 只暴露 description/prompt/run_in_background。典型场景:长会话用快模型(如 deepseek-v4-flash)做主线,但大批量派工/复核子代理希望走另一个模型(如 kimi-coding/k3)——目前只能整条会话换模型,代价太大。
提案:新增
agent-child-model设置分节配置面(照抄
agent-default-model的分层模式,最小增量)解析优先级(first hit wins,全部向后兼容)
agentOptions(workflowagent()的 provider/model;subagent工具建议新增同名可选参数直通)agent-child-model(本配置项){provider, model}实现落点(按现有架构惯例)
dsh-agent-child-model:结构上复制dsh-agent-default-model(组合配置基座 + 设置提供方叠加 +currentSelection()/saveSelection())。resolveChildAgentOptions()在...requested与父继承之间插入一层 childDefault(由新插件经 ctx 提供)。subagent工具 schema 增加可选provider/model(直通 requested,与 workflowagent()对齐)。agentModel字段(数据已在,只差展示)。明确边界(一期不做)
agentModel沿用(会话一致性优先),除非 resume 时显式覆盖。设计理由
DSH 的风格是「组合配置基座 + 设置提供方叠加 + 显式请求直通」三层,
agent-default-model已证明这个模式。子代理模型是同一问题的孪生("无会话级选择时的默认值" vs "有父会话时的覆盖值"),用同一模式新增一个分节,认知成本与实现成本都最低,且不动任何存量行为(不配置 = 现状继承)。——本建议由 DSH 实际使用中整理(长会话 flash 主线 + 批量建卡子代理派工场景实测)。
All reactions