Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Subagents

A subagent is a separate Veyyon session started by your session to execute one scoped assignment and return a result. The parent starts it with the task tool. Because each subagent runs in its own context window, broad file exploration and multi-step edits stay out of your main conversation history.

Subagent policy is configured in /settings → Subagents (subagent.*); /settings subagents opens that tab directly. Helper models used by built-in features (advisor, plan, vision, commit, title, memory, autoThinking, unexpectedStop, speech, completion) are configured in /settings → Model → Helpers (agent.helpers). /subagents opens the live dashboard for subagents running or asleep in the current session and does not edit settings.

Default configuration

On a stock profile, delegation is preferred, deep is available for autonomous delegation, and the remaining bundled subagents run when mentioned:

subagent:
  delegation: preferred
Bundled subagentDefault availabilityCapability marksRole on the cost ladder
deepauto (Automatic)reads · runs · edits · spawnsEnd-to-end worker for multi-file or ambiguous tasks that require investigation, edits, and verification.
quickmention (On mention)reads · runs · editsContained edit or verification pass when the target files and approach are already known.
scoutmention (On mention)readsRead-only codebase reconnaissance and symbol lookup.
reviewermention (On mention)reads · runsDiff and code review with command execution and no file edits.
librarianmention (On mention)reads · runsMulti-repository and documentation research without file edits.
designermention (On mention)reads · runs · editsUI layout, styling, and accessibility implementation and review.

With only deep set to auto, the task tool description includes one subagent by default instead of every specialist. You invoke any mention subagent for one turn by writing @quick, @scout, @reviewer, @librarian, or @designer in your prompt, or by running a slash command such as /review that grants reviewer for that turn.

Delegation strength

subagent.delegation (How Much to Delegate under Delegation) controls how strongly the system prompt instructs the model to delegate to auto subagents:

ValueLabel in SettingsEffect
allowedOptionalThe task tool is available; the system prompt does not push for delegation.
preferredEncouragedDefault. The system prompt instructs the model to delegate substantial eligible work.
requiredExpectedSame as preferred, plus a first-turn reminder.

subagent.enabled (Use Subagents, default true) is the master toggle. Setting subagent.enabled: false removes the task tool and all delegation instructions from the session.

A subagent definition is routing and tool-selection configuration, not a security boundary. Use the sandbox to restrict filesystem or process access.

Availability and @ mentions

subagent.agents stores per-subagent overrides keyed by subagent name. In /settings → Subagents, the Manage Subagents row opens the roster, where every discovered subagent appears with its availability, resolved model, and capability marks (reads, runs, edits, spawns). Press Space on a subagent row to cycle availability, or press Enter to open the subagent’s page (summary, file path, Availability, Model, Effort, Model for Subagents It Spawns, tools, output fields, prompt preview, e to edit in $EDITOR, d to duplicate as a user subagent). Select + New subagent… to generate and save a new user subagent in ~/.veyyon/subagents/<name>.md (see Writing a subagent).

AvailabilityLabel in SettingsEffect
autoAutomaticListed in task; the model may spawn it on its own, and @ mentions or commands also start it. Default for deep.
mentionOn mentionOmitted from task until @<agent> in your message or a command grant enables it for that turn. Default for all other bundled, user, and plugin subagents.
offOffBlocked everywhere. Neither the model, an @ mention, nor a command can spawn it.

Writing @<agent> in a message grants that subagent for the turn that message starts and appends a hidden turn notice with the subagent’s summary and capability marks. Writing @<model>[:<effort>] after an @<agent> mention in the same sentence binds that model (from subagent.modelShortcuts, an exact provider/model id, or a catalog match) and optional effort to that subagent for the turn:

@reviewer @strong check the migration diff for data loss

Plain prose without @ (“use the scout subagent”) does not grant a mention subagent; if scout is mention, that spawn attempt fails and states the setting or @scout syntax needed to run it.

Loading subagent definitions

subagent.loading (Subagent Descriptions under Delegation in /settings → Subagents) controls how much text each auto subagent contributes to the task tool description:

ValueLabel in Settingstask tool description content
fullFullDefault. Full description and read-only/command marker for each auto subagent.
summaryOne line eachOne line per auto subagent (name, capability marks, summary). Mentioning a subagent injects its full description for that turn.

When a spawned subagent starts, it always loads its full system prompt, skills, and rules.

Choosing models and effort

A subagent’s model resolves from the first layer below that specifies one:

  1. A model passed on the task call or bound by an @ mention in your message (governed by subagent.modelChoice).
  2. The subagent’s lane in subagent.agents.<name>.model for a direct spawn, or the matching nested level under subagent.agents.<name>.agents (Its Own Subagents on the subagent’s page) for a deeper spawn.
  3. Default Subagent Model (subagent.defaultModel).
  4. The subagent definition’s model: frontmatter.
  5. The spawning session’s live model.

Setting inherit on a lane or on subagent.defaultModel selects the spawning session’s live model, overriding any model: in the subagent’s frontmatter.

Effort resolves in the same order: effort on the task call or @ mention, the subagent’s lane thinkingLevel, Default Subagent Effort (subagent.defaultEffort), the definition’s thinkingLevel: frontmatter, and finally the spawning session’s live effort clamped to the levels the resolved model supports. An explicit :<effort> suffix on the winning model selector takes precedence over every separate effort setting.

subagent:
  defaultModel: openai/gpt-5
  defaultEffort: medium
  modelShortcuts:
    fast: anthropic/claude-haiku-4-5:low
    strong: anthropic/claude-opus-4-5:high
  modelChoice: shortcuts
  agents:
    reviewer:
      availability: mention
      model: strong

Model shortcuts and per-call model choice

Model Shortcuts (subagent.modelShortcuts) maps short names such as fast, strong, or local to model chains. Shortcut names work in @<shortcut> mentions, in subagent model settings, and in task calls.

Choosable Models (subagent.modelChoice) controls whether the parent model can pass model and effort arguments on task calls, and model on eval agent() calls:

  • off: model and effort are omitted from the task tool schema and from the eval agent() signature, and a call that passes them is rejected (models bound by your @ mentions still work for that turn).
  • shortcuts (default): model accepts keys defined in subagent.modelShortcuts.
  • any: model accepts any shortcut or provider/model selector.

Fallback chains

subagent.defaultModel, subagent.modelShortcuts.<name>, and subagent.agents.<name>.model accept a comma-separated string or a YAML list:

subagent:
  agents:
    reviewer:
      model:
        - anthropic/claude-opus-4-5
        - openai/gpt-5

The first entry is primary; remaining entries are runtime retry fallbacks if the active provider errors mid-run. If a configured selector matches no available model at spawn time, Veyyon rejects the spawn and states the setting to fix instead of silently falling through.

In the Subagents block above the composer, a subagent running on a fallback entry displays ↓ before its model badge.

Legacy settings migration

Legacy configurations migrate on load:

  • agent.agents.<name>.enabled: true becomes availability: auto; enabled: false becomes availability: off.
  • agent.agents.sonic renames to subagent.agents.quick.
  • The legacy config key agent.sharedModel: true copies agent.model and agent.thinkingLevel into subagent.defaultModel and subagent.defaultEffort and clears inactive per-subagent model and effort fields, saving a backup copy first. agent.sharedModel: false drops the inactive shared fields.

On the first interactive launch after migration, Veyyon displays a one-time summary card listing renamed entries, newly mentionable subagents, any cleared values with the backup file path, and Enter to open /settings → Subagents.

Watching a run

While spawns are running, the Subagents block renders above the composer with one row per subagent: rail, status mark, agent id, assignment label, and resolved model/effort badge.

Subagents
 ▏ ▪ DockerSecretHarness: Run the workspace tests in Docker · claude-opus-5 high
 ▏ ▪ SecretModeFlowUX: Review the secret mode flow · claude-opus-5 high
 ▏ ▪ SecretModularityAudit: Audit secrets subsystem modularity · gemini-3.7-flash med

The assignment label uses the spawn description, or a title generated via the title helper (agent.helpers.title, falling back to the session model). The model badge shows the resolved subagent.defaultModel or per-subagent model when set, or the inherited session model. Set subagent.showResolvedModelBadge: false to hide the badge.

When display.transitions is enabled, light animates down the rail while subagents run. At narrow terminal widths, the model badge drops first and the label truncates; rows never wrap. Up to eight rows render inline, with an overflow footer pointing to /subagents when more than eight subagents are active.

Limits and isolation

Remaining sections on /settings → Subagents control concurrency (subagent.maxConcurrency), nesting (subagent.maxNestedSpawnDepth), runtime and retry limits, request budgets, idle sleep (subagent.idleTtlMs), worktree isolation (subagent.isolation.*, see Safety), and inter-agent coordination (irc.timeoutMs).

Running, idle, asleep

A subagent has one of three states:

  • running: a turn is in flight.
  • idle: the turn finished and the session remains in memory.
  • asleep: the in-memory session was released and its transcript is on disk.

An idle subagent transitions to asleep after subagent.idleTtlMs (Sleep Idle Subagents After, default 5 minutes), releasing its session, MCP clients, and memory after flushing its transcript. Setting 0 (Never) keeps idle subagents in memory until exit.

Messaging or opening an asleep subagent wakes it from its on-disk transcript, except for isolated-worktree subagents whose temporary worktree was removed on completion (their transcripts remain readable via history://<id>).

Stopping a subagent

Pressing x in /subagents, calling job cancel, or stopping a subagent from collab aborts its active turn and puts both the subagent and any children it spawned to sleep.

Live subagent list

irc list returns all running and idle subagents plus the ten most recently active asleep subagents. Older asleep subagents remain addressable by id. /subagents lists every subagent in the session.

Idle timer rules

The idle timer counts from last activity and resets on wake. Viewing a subagent in /subagents defers sleep until Esc returns to the main session. Background jobs started by a subagent defer sleep in subagent.idleTtlMs increments until those jobs finish. If flushing the session to disk fails, the subagent stays in memory and retries on the next interval.

Nesting depth

subagent.maxNestedSpawnDepth defaults to 0 (Off), meaning direct children cannot spawn further subagents. 1 allows one nested level, and -1 allows unlimited nesting. Per-subagent overrides are configured at subagent.agents.<name>.maxNestedSpawnDepth or Its Own Subagents on the subagent’s page:

subagent:
  maxNestedSpawnDepth: 0
  agents:
    deep:
      maxNestedSpawnDepth: 1

Working directory isolation

Calling set_cwd inside a spawned subagent updates only that subagent’s working directory and system prompt without changing process.cwd() or any sibling session. Project settings and plugins remain those loaded for the host process.

The complete setting key table is in the settings reference.