3.1 KiB
kind, description
| kind | description |
|---|---|
| upgrade-guide | Tool execution modes move from dsh-tools configuration into explicit executor plugins. |
Mount a tool executor
English | 中文
Change
@deepseek-ai/dsh-tools keeps tool registration and executor selection, but rejects the removed mode and maxParallelSubCalls configuration fields at load time. Native and PTC execution require @deepseek-ai/dsh-tool-executor-native or @deepseek-ai/dsh-tool-executor-ptc. Shipped profiles mount an executor; custom compositions must add one. The existing dsh-agent-tool-presentation selector remains supported but is deprecated. Enabled tool-executor-native and tool-executor-ptc rows are required at startup; invalid executor configuration now stops startup. Web, headless, and SDK no longer read DSH_TOOLS_MODE; all inherit native execution from base.
Migration
-
Keep the
dsh-toolsrow and remove its execution configuration. Mount one native or PTC executor in the intended deployment or preset scope. For shipped profile patches, target the executor row instead of thetoolsrow. -
Move
maxParallelSubCallsto the PTC executor configuration and mount a compatiblectx.ptcRuntimeprovider. The executor declares this service as a required injection; a missing runtime stops startup, and unloading the runtime withdraws the executor.agent-loop.maxParallelToolCallsand saved overrides stay in place with default10. The loop forwards the current limit to each batch; live edits apply to the next batch instead of the next tool group. -
Custom executors implement
describeandexecute. Programmatic callers pass rawcallsandsignal, optionalagent, and optionallog: { turn, step }; read single-call outcomes fromresults. Omitlogoutside a committed model step. -
Import PTC SDK renderers and
CodeRunFailedErrorfrom@deepseek-ai/dsh-tool-executor-ptc. Run a task with the selected interaction mode and confirm its tool results appear in the Session. -
Import
ToolExecutionPipelineandexecuteToolBatchfrom@deepseek-ai/dsh-tools/pipeline. Complete calls, including single calls, use batches; custom schedulers callprepare,dispatch, andcompletedirectly. Add@deepseek-ai/dsh-tool-testkitas a development dependency for tool fixtures and import them from that package. Neither is exported by the tool registry entry. -
Import shared dispatch events and the
ptc-modemessage-source declaration from@deepseek-ai/dsh-tool-executor-ptc/types; Client code uses its/clientre-export. Host policy extensions useimport typefrom@deepseek-ai/dsh-tool-executor-ptcforPtcDispatchLogandtools/ptc-dispatch-log. -
Remove
DSH_TOOLS_MODEfrom launch environments. For PTC, save the following asptc.ymland pass it with--patch; native execution needs no overlay. The same patch works with--profile weband--profile sdk; TypeScript and Python SDK clients pass its path throughpatches. Confirm that the model receives onlyrun_codein PTC mode.
- id: tool-executor-native
disabled: true
- id: tool-executor-ptc
disabled: false
dsh --profile headless --patch ./ptc.yml "task"