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 Teams: support preset selection in spawn_teammate
#12016
In DSH 0.2.1-rc.5, spawn_teammate does not expose preset selection:
teammates inherit the lead's composition. Allowing an independent preset would
let members of the same team use different tools and skills.
The underlying SubagentStartRequest already supports agentPreset.
Proposed change
Add an optional agentPreset parameter to the spawn_teammate schema and SpawnTeammateRequest, then forward it as request.agentPreset when calling subagents.startActivation.
Example of the proposed API:
spawn_teammate({name: "reviewer",description: "Code review",prompt: "Review the changes and report your findings",context: "fresh",agentPreset: "code-review"});
Expected behavior
An explicitly selected preset supplies the teammate's tools and skills before
its first turn.
The preset survives subsequent messages, automatic cold resume, and DSH restarts.
Omitting the parameter preserves the current inheritance of the lead's composition.
Empty or unknown preset IDs, and an independent preset combined with fork,
are rejected before adding the teammate to the roster.
Cover these cases with regression tests and document the parameter in the
Agent Teams documentation.
Workarounds and limitations
agentPresets.select() during agent/created. The intended preset applies
before the first turn, but the next send_message after the live child is
released restores the lead's preset. In rc.5, agent-preset/selected is recorded
after subagent/descriptor, while restoration recognizes an independent
selection only when it precedes the descriptor. No process restart is needed
to reproduce this.
Calling select() again during resume. This fails with agent-preset/locked
(This session has already started), because the session has already run a turn.
Calling mount() during resume. A local scenario with separate MCP servers
and a follow-up passed, but the method's documented contract expects an
unpublished Agent in a setup callback. During agent/created, the Agent has
already been published. This workaround depends on lifecycle ordering and needs
explicit restoration of the persisted selection. A full DSH restart was not
tested for this workaround.
A local tool/service patch. Forwarding agentPreset into startActivation
passed a scenario with separate MCP servers, messaging, and automatic cold resume.
However, this requires maintaining modified copies of the official modules
across SDK updates.
These checks used rc.5, the actual Agent Teams runtime, and two local stdio MCP
servers. The proposed parameter would use the existing native preset-selection
mechanism at creation time, without late switching or custom restoration logic.
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.
In DSH
0.2.1-rc.5,spawn_teammatedoes not expose preset selection:teammates inherit the lead's composition. Allowing an independent preset would
let members of the same team use different tools and skills.
The underlying
SubagentStartRequestalready supportsagentPreset.Proposed change
Add an optional
agentPresetparameter to thespawn_teammateschema andSpawnTeammateRequest, then forward it asrequest.agentPresetwhen callingsubagents.startActivation.Example of the proposed API:
Expected behavior
its first turn.
fork,are rejected before adding the teammate to the roster.
Cover these cases with regression tests and document the parameter in the
Agent Teams documentation.
Workarounds and limitations
agentPresets.select()duringagent/created. The intended preset appliesbefore the first turn, but the next
send_messageafter the live child isreleased restores the lead's preset. In rc.5,
agent-preset/selectedis recordedafter
subagent/descriptor, while restoration recognizes an independentselection only when it precedes the descriptor. No process restart is needed
to reproduce this.
select()again during resume. This fails withagent-preset/locked(
This session has already started), because the session has already run a turn.mount()during resume. A local scenario with separate MCP serversand a follow-up passed, but the method's documented contract expects an
unpublished Agent in a setup callback. During
agent/created, the Agent hasalready been published. This workaround depends on lifecycle ordering and needs
explicit restoration of the persisted selection. A full DSH restart was not
tested for this workaround.
agentPresetintostartActivationpassed a scenario with separate MCP servers, messaging, and automatic cold resume.
However, this requires maintaining modified copies of the official modules
across SDK updates.
These checks used rc.5, the actual Agent Teams runtime, and two local stdio MCP
servers. The proposed parameter would use the existing native preset-selection
mechanism at creation time, without late switching or custom restoration logic.
All reactions