description: "The deployment default model selection for users and maintainers choosing, configuring, or debugging which model freshly created agents start on."
English | 中文
dsh-agent-default-model supplies the deployment's default model selection — provider, model, and optional reasoning effort — that agent entry points apply when a fresh session has no selection of its own. Direct entry points such as dsh --profile headless and Host-backed entry points read ctx.agentDefaultModel instead of owning parallel defaults, so one composition entry controls which model new agents start on. A mounted settings provider layers the user's choice over the composition entry, and a saved change is visible on the next read. It is one process-wide default: per-session model selection remains the entry point's responsibility. Choose it when you want a single place to set the model new agents use.
Mount this package wherever agents are created without an explicit model route. The service answers one question — which model should a fresh agent use? — so entry points that create agents consult it instead of re-implementing a default.
The composition entry is the base of the default: it requires a provider and model and stays usable without any settings provider.
- name: '@deepseek-ai/dsh-agent-default-model'
config:
provider: deepseek
model: deepseek-chat
| Field | Default | Meaning |
|---|---|---|
provider |
required | Registered provider route for fresh agents |
model |
required | Provider-owned model id for fresh agents |
The generated configuration catalog is the exhaustive source for every accepted field. reasoningEffort is deliberately not a config field: it belongs to the settings layer, so a complete saved selection can clear an effort when the next selected model has none, while a composition value would be inherited again.
currentSelection() returns a detached { provider, model, reasoningEffort? } for a newly created agent; saveSelection() stores the complete selection for later agents.
const selection = ctx.agentDefaultModel.currentSelection()
await ctx.agentDefaultModel.saveSelection({ provider, model, reasoningEffort: 'high' })
Without a settings provider, saveSelection() is a no-op and the composition entry remains current. The service does not validate catalog membership: a provider route may serve an unadvertised model, and the consumer that opens a model request owns availability diagnostics.
The package-level contract is enough for most consumers; read these when you need the surrounding domain.
Agent handle and AgentOptions route selection.Indirectly, through the ModelSelection the service supplies to an entry point; request assembly and the provider adapters own the model-visible request.
Changing the default affects only agents that subsequently resolve from it. An existing session whose request log already names a selection keeps that selection, so this service does not invalidate its established prefix.
These limits define the service's scope. They are current package constraints, not a task backlog.
saveSelection() cannot keep a selection for a later agent when no settings provider is mounted.