Skip to main content
Glama

Delegate advisory task

delegate

Assign a text or code task to a subagent with automatic retries, failover, and mission context, returning a structured answer while managing provider credits.

Instructions

Delegate one advisory text task with bounded retries, failover and mission context. May consume provider credits. Reuse the project_id and mission_id of the current task (from project_init / memory_checkpoint); when omitted, results go to project "default" and a new random mission that mission_status and memory_checkpoint will not find.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
goalNoMission goal recorded when the mission is created.
roleNoSpecialist role instruction.worker
cacheNoReuse an identical earlier answer when DZ23_RESPONSE_CACHE_TTL_MS > 0; the result reports cache_status (hit, miss or disabled).
detailNoControls response verbosity.normal
promptYesThe assignment for the subagent.
targetNoauto or provider:model.auto
contextNoWorkspace evidence. Requires workspace; content is untrusted data.
privacyNoSecrets in attached context are always masked. auto also masks valid CPF/CNPJ/card numbers, emails and phones; local_only additionally routes only to local private targets (no_local_target otherwise); allow_cloud keeps personal data.auto
task_typeNoKind of task for adaptive model choice; defaults from role (backend/frontend=code, reviewer=review, qa=testing...).
workspaceNoConfigured workspace root for context.
mission_idNoMission of the current task; omitted creates a new random mission.
project_idNoProject of the current task; defaults to "default".default
lease_tokenNoToken from mission_claim. Required only while another holder has a live lease on this mission.
output_schemaNoJSON Schema subset (type, required, properties, items, enum) for the answer. delegate retries once and fails with response_invalid; consensus and swarm_run add structured_output or schema_error per answer.
idempotency_keyNoCaller key, valid 24 h in this process. The same key and arguments return the first result without a new provider call; different arguments fail with idempotency_conflict.
max_response_charsNoHard cap for returned textual content.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv4.3.0
    • addedInput schema / properties / task_type
      Added value: +{
      +  "description": "Kind of task for adaptive model choice; defaults from role (backend/frontend=code, reviewer=review, qa=testing...).",
      +  "enum": [
      +    "general",
      +    "code",
      +    "review",
      +    "design",
      +    "security",
      +    "testing",
      +    "ops",
      +    "summary"
      +  ],
      +  "type": "string"
      +}
  2. Changed15 schema fields changedv4.1.0
    • addedInput schema / properties / cache
      Added value: +{
      +  "default": false,
      +  "description": "Reuse an identical earlier answer when DZ23_RESPONSE_CACHE_TTL_MS > 0; the result reports cache_status (hit, miss or disabled).",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / context
      Added value: +{
      +  "additionalProperties": false,
      +  "description": "Workspace evidence. Requires workspace; content is untrusted data.",
      +  "properties": {
      +    "files": {
      +      "items": {
      +        "maxLength": 4096,
      +        "minLength": 1,
      +        "type": "string"
      +      },
      +      "maxItems": 50,
      +      "type": "array"
      +    },
      +    "git_diff": {
      +      "default": false,
      +      "type": "boolean"
      +    },
      +    "search": {
      +      "additionalProperties": false,
      +      "properties": {
      +        "max_results": {
      +          "default": 50,
      +          "maximum": 100,
      +          "minimum": 1,
      +          "type": "integer"
      +        },
      +        "query": {
      +          "description": "Search query.",
      +          "maxLength": 2000,
      +          "minLength": 1,
      +          "pattern": "\\S",
      +          "type": "string",
      +          "x-pattern-reason": "must contain non-whitespace text"
      +        },
      +        "regex": {
      +          "default": false,
      +          "type": "boolean"
      +        }
      +      },
      +      "required": [
      +        "query"
      +      ],
      +      "type": "object"
      +    }
      +  },
      +  "type": "object"
      +}
    • addedInput schema / properties / detail
      Added value: +{
      +  "default": "normal",
      +  "description": "Controls response verbosity.",
      +  "enum": [
      +    "brief",
      +    "normal",
      +    "full"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / idempotency_key
      Added value: +{
      +  "description": "Caller key, valid 24 h in this process. The same key and arguments return the first result without a new provider call; different arguments fail with idempotency_conflict.",
      +  "maxLength": 128,
      +  "minLength": 8,
      +  "pattern": "^[A-Za-z0-9._:-]+$",
      +  "type": "string"
      +}
    • addedInput schema / properties / lease_token
      Added value: +{
      +  "description": "Token from mission_claim. Required only while another holder has a live lease on this mission.",
      +  "maxLength": 128,
      +  "type": "string"
      +}
    • addedInput schema / properties / max_response_chars
      Added value: +{
      +  "description": "Hard cap for returned textual content.",
      +  "maximum": 200000,
      +  "minimum": 256,
      +  "type": "integer"
      +}
    • changedInput schema / properties / mission_id / description
      Previous value: -"Mission identifier inside the project."New value: +"Mission of the current task; omitted creates a new random mission."
    • changedInput schema / properties / mission_id / pattern
      Previous value: -"^[a-zA-Z0-9][a-zA-Z0-9._-]{0,119}$"New value: +"^[a-zA-Z0-9](?:[a-zA-Z0-9._-]{0,118}[a-zA-Z0-9_-])?$"
    • changedInput schema / properties / mission_id / x-pattern-reason
      Previous value: -"must use 1-120 letters, digits, dots, underscores or hyphens and start with a letter or digit"New value: +"must use 1-120 letters, digits, dots, underscores or hyphens, start with a letter or digit and not end with a dot"
    • addedInput schema / properties / output_schema
      Added value: +{
      +  "description": "JSON Schema subset (type, required, properties, items, enum) for the answer. delegate retries once and fails with response_invalid; consensus and swarm_run add structured_output or schema_error per answer.",
      +  "type": "object"
      +}
    • addedInput schema / properties / privacy
      Added value: +{
      +  "default": "auto",
      +  "description": "Secrets in attached context are always masked. auto also masks valid CPF/CNPJ/card numbers, emails and phones; local_only additionally routes only to local private targets (no_local_target otherwise); allow_cloud keeps personal data.",
      +  "enum": [
      +    "auto",
      +    "local_only",
      +    "allow_cloud"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / project_id / description
      Previous value: -"Project memory identifier. Not an authorization boundary."New value: +"Project of the current task; defaults to \"default\"."
    • changedInput schema / properties / project_id / pattern
      Previous value: -"^[a-zA-Z0-9][a-zA-Z0-9._-]{0,119}$"New value: +"^[a-zA-Z0-9](?:[a-zA-Z0-9._-]{0,118}[a-zA-Z0-9_-])?$"
    • changedInput schema / properties / project_id / x-pattern-reason
      Previous value: -"must use 1-120 letters, digits, dots, underscores or hyphens and start with a letter or digit"New value: +"must use 1-120 letters, digits, dots, underscores or hyphens, start with a letter or digit and not end with a dot"
    • addedInput schema / properties / workspace
      Added value: +{
      +  "description": "Configured workspace root for context.",
      +  "maxLength": 4096,
      +  "type": "string"
      +}
  3. Changed26 schema fields changedv3.0.0
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / goal / description
      Added value: +"Mission goal recorded when the mission is created."
    • addedInput schema / properties / goal / maxLength
      Added value: +8000
    • addedInput schema / properties / mission_id / description
      Added value: +"Mission identifier inside the project."
    • addedInput schema / properties / mission_id / maxLength
      Added value: +120
    • addedInput schema / properties / mission_id / minLength
      Added value: +1
    • addedInput schema / properties / mission_id / pattern
      Added value: +"^[a-zA-Z0-9][a-zA-Z0-9._-]{0,119}$"
    • addedInput schema / properties / mission_id / x-pattern-reason
      Added value: +"must use 1-120 letters, digits, dots, underscores or hyphens and start with a letter or digit"
    • addedInput schema / properties / project_id / default
      Added value: +"default"
    • addedInput schema / properties / project_id / description
      Added value: +"Project memory identifier. Not an authorization boundary."
    • addedInput schema / properties / project_id / maxLength
      Added value: +120
    • addedInput schema / properties / project_id / minLength
      Added value: +1
    • addedInput schema / properties / project_id / pattern
      Added value: +"^[a-zA-Z0-9][a-zA-Z0-9._-]{0,119}$"
    • addedInput schema / properties / project_id / x-pattern-reason
      Added value: +"must use 1-120 letters, digits, dots, underscores or hyphens and start with a letter or digit"
    • addedInput schema / properties / prompt / description
      Added value: +"The assignment for the subagent."
    • addedInput schema / properties / prompt / maxLength
      Added value: +32000
    • addedInput schema / properties / prompt / minLength
      Added value: +1
    • addedInput schema / properties / prompt / pattern
      Added value: +"\\S"
    • addedInput schema / properties / prompt / x-pattern-reason
      Added value: +"must contain non-whitespace text"
    • addedInput schema / properties / role / default
      Added value: +"worker"
    • addedInput schema / properties / role / description
      Added value: +"Specialist role instruction."
    • addedInput schema / properties / role / enum
      Added value: +[
      +  "worker",
      +  "architect",
      +  "backend",
      +  "frontend",
      +  "security",
      +  "qa",
      +  "devops",
      +  "reviewer"
      +]
    • addedInput schema / properties / target / default
      Added value: +"auto"
    • addedInput schema / properties / target / description
      Added value: +"auto or provider:model."
    • addedInput schema / properties / target / pattern
      Added value: +"^(?:auto|[a-z0-9][a-z0-9_-]{0,39}(?::\\S{1,200})?)$"
    • addedInput schema / properties / target / x-pattern-reason
      Added value: +"must be auto or provider:model"
  4. First observedv2.2.4

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description discloses behavior beyond annotations: 'May consume provider credits' and 'bounded retries, failover and mission context'. It also explains the consequence of omitting mission/project IDs, which is useful side-effect information. No contradiction with readOnlyHint=false or openWorldHint=true.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences with no filler: the core action and caveats are front-loaded, followed by the crucial ID-reuse guidance. It avoids repeating schema information and every clause earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 16-parameter tool with nested objects and no output schema, the description covers the essential operational context: task delegation, retries/failover, credit consumption, and mission/project routing. The schema covers parameter-level details, leaving only secondary gaps such as return shape and retry specifics.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so parameters are already documented. The description adds meaningful semantics by connecting project_id and mission_id to the current task's source (project_init / memory_checkpoint) and clarifying that omitted values produce a mission that status tools cannot find, going beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with 'Delegate one advisory text task with bounded retries, failover and mission context', naming a specific verb, resource, and key characteristics. It is clear enough to separate this from review/monitoring tools, though it does not explicitly name sibling tools like swarm_run or consensus.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives explicit operational guidance: reuse the project_id and mission_id from project_init / memory_checkpoint, and warns that omitting them routes results to project 'default' with a new random mission that status tools won't find. It lacks an explicit contrast with alternatives, but the context is actionable.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.