Skip to content

Agent Commands

Agents communicate via structured commands embedded in their output. Commands use ⟦⟦ ⟧⟧ bracket syntax with JSON payloads, detected by the CommandDispatcher.

Command Format

⟦⟦ COMMAND_NAME {"key": "value", ...} ⟧⟧

Commands without parameters can omit the JSON payload:

⟦⟦ COMMAND_NAME ⟧⟧

Quick Reference

CommandCategoryDescription
AGENT_MESSAGECommunicationSend a message to an agent by ID or role
BROADCASTCommunicationSend a message to all agents in the crew
INTERRUPTCommunicationInterrupt an agent with an urgent message
DIRECT_MESSAGECommunicationQueue a non-interrupting message for an agent
TELEGRAM_REPLYCommunicationReply to a Telegram message
TELEGRAM_SENDCommunicationSend a message to the bound Telegram chat
CREATE_GROUPGroupsCreate a chat group
GROUP_MESSAGEGroupsSend a message to a group
ADD_TO_GROUPGroupsAdd members to a group
REMOVE_FROM_GROUPGroupsRemove members from a group
QUERY_GROUPSGroupsList all groups you belong to
REACTGroupsAdd or remove an emoji reaction on a group message
CREATE_AGENTAgent LifecycleSpawn a new agent with a role and task
DELEGATEAgent LifecycleDelegate a task to an existing agent
TERMINATE_AGENTAgent LifecycleStop an agent (last resort)
CANCEL_DELEGATIONAgent LifecycleCancel an active delegation
SPAWN_AGENTAgent LifecycleRequest the lead to create an agent (non-lead only)
DECLARE_TASKSTask DAGDeclare a batch of tasks with dependencies
ADD_TASKTask DAGAdd a single task to the DAG
COMPLETE_TASKTask DAGMark a task as done
TASK_STATUSTask DAGView the task DAG status and progress
ASSIGN_TASKTask DAGAssign a task to a specific agent
REASSIGN_TASKTask DAGReassign a running task to a different agent
ADD_DEPENDENCYTask DAGAdd a dependency between tasks
FORCE_READYTask DAGForce a task to ready status
PAUSE_TASKTask DAGPause a pending or ready task
RESUME_TASKTask DAGResume a paused task
RETRY_TASKTask DAGRetry a failed task
REOPEN_TASKTask DAGReopen a completed task
SKIP_TASKTask DAGSkip a task and unblock dependents
CANCEL_TASKTask DAGCancel a task
RESET_DAGTask DAGClear all tasks and start fresh
LOCK_FILECoordinationAcquire a file lock
UNLOCK_FILECoordinationRelease a file lock
COMMITCoordinationCommit locked files to git
ACTIVITYCoordinationLog an activity entry
DECISIONCoordinationRecord an architectural decision
PROGRESSCoordinationReport progress on current work
QUERY_CREWSystemGet current crew status
QUERY_PEERSSystemList peer agents for direct messaging
HALT_HEARTBEATSystemStop heartbeat reminders
RESUME_HEARTBEATSystemResume heartbeat reminders
REQUEST_LIMIT_CHANGESystemRequest a change to concurrency limits
QUERY_PROVIDERSSystemGet available providers, models, and ranking
SET_TIMERTimersSet a reminder timer
CANCEL_TIMERTimersCancel a timer
LIST_TIMERSTimersList active timers
ACQUIRE_CAPABILITYCapabilitiesAcquire a capability beyond your role
RELEASE_CAPABILITYCapabilitiesRelease an acquired capability
LIST_CAPABILITIESCapabilitiesList available and acquired capabilities
LIST_TEMPLATESTemplatesList all available workflow templates
APPLY_TEMPLATETemplatesInstantiate a workflow template into the DAG
DECOMPOSE_TASKTemplatesDecompose a task description into sub-tasks

Communication

AGENT_MESSAGE

Send a direct message to another agent. Resolves targets by agent ID, ID prefix, role ID, or role name.

⟦⟦ AGENT_MESSAGE {"to": "a1b2c3", "content": "Can you review my approach?"} ⟧⟧
FieldRequiredDescription
toTarget agent ID, ID prefix, or role name
contentMessage content

BROADCAST

Send a message to all agents in the crew.

⟦⟦ BROADCAST {"content": "Switching to approach B for the API layer"} ⟧⟧
FieldRequiredDescription
contentBroadcast message content

INTERRUPT

Interrupt another agent's current work by injecting a priority message. The message is delivered immediately, unlike DIRECT_MESSAGE which queues.

⟦⟦ INTERRUPT {"to": "agent-id-prefix", "content": "Stop — requirements changed"} ⟧⟧
FieldRequiredDescription
toTarget agent ID, ID prefix, or role name
contentUrgent message content

DIRECT_MESSAGE

Queue a message to another agent without interrupting their current work. The message is delivered when the agent's current turn completes. Matches agents by ID prefix.

⟦⟦ DIRECT_MESSAGE {"to": "agent-id-prefix", "content": "Can you check the auth tests?"} ⟧⟧
FieldRequiredDescription
toTarget agent ID or ID prefix
contentMessage content

TELEGRAM_REPLY

Reply to a specific inbound Telegram message. Requires a Telegram integration to be configured.

⟦⟦ TELEGRAM_REPLY {"messageId": "12345", "content": "response text"} ⟧⟧
FieldRequiredDescription
messageIdTelegram message ID to reply to
contentReply text

Note: Telegram messages have a 30-minute TTL. Replies to expired messages will fail.

TELEGRAM_SEND

Send a message to the Telegram chat bound to the current project. Requires a Telegram integration to be configured.

⟦⟦ TELEGRAM_SEND {"content": "Build complete, all tests pass"} ⟧⟧
FieldRequiredDescription
contentMessage text to send

Groups

CREATE_GROUP

Create a chat group for focused discussion. Requires at least one of members or roles.

⟦⟦ CREATE_GROUP {"name": "api-design", "members": ["a1b2c3", "d4e5f6"]} ⟧⟧
FieldRequiredDescription
nameGroup name
members❌*Array of agent short IDs, full UUIDs, or role names
roles❌*Array of role names to include

* At least one of members or roles must be provided.

GROUP_MESSAGE

Send a message to all members of a chat group.

⟦⟦ GROUP_MESSAGE {"group": "backend-team", "content": "API design is finalized"} ⟧⟧
FieldRequiredDescription
groupGroup name
contentMessage content

ADD_TO_GROUP

Add members to an existing group.

⟦⟦ ADD_TO_GROUP {"group": "backend-team", "members": ["c9d0e1f2"]} ⟧⟧
FieldRequiredDescription
groupGroup name
membersArray of agent short IDs, full UUIDs, or role names

REMOVE_FROM_GROUP

Remove members from a group.

⟦⟦ REMOVE_FROM_GROUP {"group": "backend-team", "members": ["e5f6a7b8"]} ⟧⟧
FieldRequiredDescription
groupGroup name
membersArray of agent short IDs, full UUIDs, or role names

QUERY_GROUPS

List all groups the agent belongs to, with member info and recent messages. LIST_GROUPS is an alias for this command.

⟦⟦ QUERY_GROUPS ⟧⟧

No parameters.

REACT

Add or remove an emoji reaction on a group chat message. Toggle behavior: if the agent already reacted with that emoji, it is removed.

⟦⟦ REACT {"group": "backend-team", "emoji": "👍"} ⟧⟧
FieldRequiredDescription
groupGroup name
emojiSingle emoji character
messageIdTarget message ID (defaults to most recent)

Agent Lifecycle

CREATE_AGENT

Spawn a new agent with a specific role. Only the lead (or agents with the delegation capability) can use this.

⟦⟦ CREATE_AGENT {"role": "developer", "task": "Implement auth module", "model": "claude-sonnet-4.6"} ⟧⟧
FieldRequiredDescription
roleRole ID (developer, architect, etc.)
taskInitial task description
modelModel override (defaults to role's default)
providerProvider override (e.g. copilot, claude, gemini, codex)
contextAdditional context for the agent
dagTaskIdLink to a specific DAG task
dependsOnArray of DAG task IDs this work depends on
nameCustom agent name
sessionIdSession ID to resume

DELEGATE

Assign a task to an existing agent. Only the lead can use this. Automatically creates a delegation record and notifies the target agent.

⟦⟦ DELEGATE {"to": "a1b2c3", "task": "Write unit tests for auth", "context": "Focus on edge cases"} ⟧⟧
FieldRequiredDescription
toTarget agent ID or ID prefix
taskTask description
contextAdditional context
dagTaskIdLink to a specific DAG task
dependsOnArray of DAG task IDs this work depends on

TERMINATE_AGENT

Terminate an agent. Only the lead can use this, and only on agents in its own hierarchy. This is an absolute last resort — it destroys the agent's accumulated context.

⟦⟦ TERMINATE_AGENT {"agentId": "a1b2c3", "reason": "need slot for different role"} ⟧⟧
FieldRequiredDescription
agentIdTarget agent ID or ID prefix
reasonReason for termination

CANCEL_DELEGATION

Cancel an active delegation. Provide either agentId or delegationId.

⟦⟦ CANCEL_DELEGATION {"agentId": "agent-id-prefix"} ⟧⟧
FieldRequiredDescription
agentId❌*Agent ID to cancel delegation for
delegationId❌*Delegation ID to cancel

* At least one of agentId or delegationId must be provided.

SPAWN_AGENT

Requests the lead to create a new agent. This command is rejected for all agents — only the lead can create agents via CREATE_AGENT. Non-lead agents should use AGENT_MESSAGE to ask the lead for help.

⟦⟦ SPAWN_AGENT {"role": "developer", "task": "Help me fix the database migration"} ⟧⟧

Task DAG

Commands for managing the directed acyclic graph (DAG) of tasks. See Auto-DAG for details on the task lifecycle.

DECLARE_TASKS

Declare a batch of tasks with dependencies. Lead-only. This is the primary way to set up a project work plan.

⟦⟦ DECLARE_TASKS {"tasks": [{"taskId": "auth", "role": "developer", "description": "Build auth module", "dependsOn": []}, {"taskId": "api", "role": "developer", "description": "Build API layer", "dependsOn": ["auth"]}]} ⟧⟧
FieldRequiredDescription
tasksArray of task definitions (see below)

Each task in the array:

FieldRequiredDescription
taskIdUnique task ID (max 100 chars)
roleRole to assign (developer, architect, etc.)
descriptionTask description
dependsOnArray of task IDs this depends on
filesFiles to lock for this task
statusInitial status
priorityPriority level (number)

ADD_TASK

Add a single task to an existing DAG. Lead-only.

⟦⟦ ADD_TASK {"taskId": "new-task", "role": "developer", "description": "Implement caching", "dependsOn": ["auth"]} ⟧⟧
FieldRequiredDescription
taskIdUnique task ID
roleRole to assign
descriptionTask description
dependsOnArray of task IDs this depends on
filesFiles to lock for this task
statusInitial status
priorityPriority level (number)

COMPLETE_TASK

Mark a DAG task as done. Any agent can use this — non-lead agents relay completion to the parent lead's DAG with authorization validation.

⟦⟦ COMPLETE_TASK {"taskId": "task-id", "summary": "Auth module implemented with full test coverage"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID (auto-detected from agent's assignment if omitted)
summaryBrief summary of what was accomplished
statusCompletion status (defaults to "done")
outputAlias for summary — either field works

Security: When using an explicit taskId, the system verifies the calling agent is assigned to that task. Agents cannot complete tasks assigned to other agents. Fields are capped at 10K characters.

TASK_STATUS

View the current DAG state and progress summary. Any agent can use this (non-leads see their parent's DAG). QUERY_TASKS is an alias for this command.

⟦⟦ TASK_STATUS ⟧⟧

No parameters.

ASSIGN_TASK

Assign an existing ready DAG task to a specific agent and start it. Lead-only. Creates a delegation record and notifies the target agent.

⟦⟦ ASSIGN_TASK {"taskId": "task-id", "agentId": "agent-id-prefix"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID to assign
agentIdTarget agent ID or short ID prefix

REASSIGN_TASK

Reassign a running task from one agent to another. Lead-only. Notifies the old agent to stop, releases their file locks, and delegates to the new agent.

⟦⟦ REASSIGN_TASK {"taskId": "task-id", "agentId": "new-agent-id"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID to reassign
agentIdNew target agent ID or short ID prefix

ADD_DEPENDENCY

Add dependencies between DAG tasks. Any agent can use this (non-leads can only add dependencies to tasks assigned to them). Validates that tasks exist and the dependency doesn't create a cycle.

⟦⟦ ADD_DEPENDENCY {"taskId": "build-frontend", "dependsOn": ["design-api", "setup-db"]} ⟧⟧
FieldRequiredDescription
taskIdTask ID to add dependency to
dependsOnArray of task IDs this depends on (max 20)

FORCE_READY

Force a task to "ready" state, overriding dependency checks. Lead-only. The task must be in pending or blocked state.

⟦⟦ FORCE_READY {"taskId": "task-id"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID to force into ready state

PAUSE_TASK

Pause a pending or ready task. Lead-only.

⟦⟦ PAUSE_TASK {"taskId": "task-id"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID to pause

RESUME_TASK

Resume a paused task. Lead-only. Returns the task to its appropriate state (pending or ready) based on dependency status.

⟦⟦ RESUME_TASK {"taskId": "task-id"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID to resume

RETRY_TASK

Retry a failed task by resetting it to ready. Lead-only. Unblocks dependents.

⟦⟦ RETRY_TASK {"taskId": "task-id"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID to retry (must be in failed state)

REOPEN_TASK

Reopen a completed task. Lead-only. Warns if dependent tasks have already started or completed.

⟦⟦ REOPEN_TASK {"taskId": "task-id"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID to reopen (must be in done state)

SKIP_TASK

Skip a task and unblock its dependents. Lead-only. If the task was running, the assigned agent is notified to stop and its file locks are released.

⟦⟦ SKIP_TASK {"taskId": "task-id"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID to skip

CANCEL_TASK

Cancel a task. Lead-only.

⟦⟦ CANCEL_TASK {"taskId": "task-id"} ⟧⟧
FieldRequiredDescription
taskIdDAG task ID to cancel

RESET_DAG

Clear all tasks and start fresh. Lead-only. Archives all tasks and cancels active delegations.

⟦⟦ RESET_DAG ⟧⟧

No parameters.


Coordination

LOCK_FILE

Acquire a file lock to prevent concurrent edits. Locks have a 5-minute default TTL.

⟦⟦ LOCK_FILE {"filePath": "src/auth.ts", "reason": "implementing auth"} ⟧⟧
FieldRequiredDescription
filePathPath to the file to lock
reasonWhy you need this lock

UNLOCK_FILE

Release a file lock. Warns if the file has uncommitted changes and blocks release until committed.

⟦⟦ UNLOCK_FILE {"filePath": "src/auth.ts"} ⟧⟧
FieldRequiredDescription
filePathPath to the file to unlock

COMMIT

Commit changes to git. Auto-scopes to files the agent has locked. Can also specify files explicitly.

⟦⟦ COMMIT {"message": "feat: add input validation for all commands"} ⟧⟧
FieldRequiredDescription
messageCommit message (auto-generated if omitted)
filesSpecific files to commit (merged with locked files)

ACTIVITY

Log an activity entry to the crew activity ledger.

⟦⟦ ACTIVITY {"actionType": "file_edit", "summary": "Updated auth module"} ⟧⟧
FieldRequiredDescription
actionTypeActivity type (e.g. file_edit, milestone)
summaryActivity summary
detailsAdditional details (object)

DECISION

Record an architectural decision. Decisions with needsConfirmation: true appear in the dashboard for user review.

⟦⟦ DECISION {"title": "Use JWT for auth", "rationale": "Stateless, scalable", "needsConfirmation": true} ⟧⟧
FieldRequiredDescription
titleDecision title
rationaleReasoning behind the decision
needsConfirmationWhether human confirmation is needed (boolean)

PROGRESS

Report progress on current work. If a task DAG exists, DAG status is automatically appended.

⟦⟦ PROGRESS {"summary": "Auth module 60% complete", "percent": 60} ⟧⟧
FieldRequiredDescription
summaryProgress description
percentCompletion percentage (0–100)
statusStatus label

System

QUERY_CREW

Request the current crew manifest — team roster, agent statuses, file locks, and memory. The response is scoped to the requesting agent's project.

⟦⟦ QUERY_CREW ⟧⟧

No parameters.

QUERY_PEERS

Discover other active agents under the same lead, available for direct messaging.

⟦⟦ QUERY_PEERS ⟧⟧

No parameters.

HALT_HEARTBEAT

Stop the heartbeat monitor from sending idle nudges to the lead. Useful when performing a long operation. Use RESUME_HEARTBEAT to re-enable.

⟦⟦ HALT_HEARTBEAT ⟧⟧

No parameters.

RESUME_HEARTBEAT

Resume heartbeat idle nudges after they were stopped with HALT_HEARTBEAT.

⟦⟦ RESUME_HEARTBEAT ⟧⟧

No parameters.

REQUEST_LIMIT_CHANGE

Request a change to the agent concurrency limit. Lead-only. Requires user approval via the dashboard.

⟦⟦ REQUEST_LIMIT_CHANGE {"limit": 15, "reason": "Need more agents for parallel testing"} ⟧⟧
FieldRequiredDescription
limitRequested new concurrency limit (1–100)
reasonExplanation for the change request

QUERY_PROVIDERS

Get available providers, models, and ranking. Lead-only. Shows provider status (enabled, installed), default models, resume support, and project model configuration.

⟦⟦ QUERY_PROVIDERS ⟧⟧

No parameters.


Timers

SET_TIMER

Set a reminder that fires after a delay. Supports human-readable durations like "5m", "2h", "1d". Max 20 timers per agent.

⟦⟦ SET_TIMER {"label": "check-build", "delay": 300, "message": "Check if the build passed", "repeat": false} ⟧⟧
FieldRequiredDescription
labelTimer label/name
delayDelay in seconds or duration string (e.g. "5m", "2h"). Min 5s, max 24h
messageMessage to deliver when the timer fires
repeatWhether to repeat the timer (boolean, default false)

CANCEL_TIMER

Cancel an active timer. Provide either timerId or label.

⟦⟦ CANCEL_TIMER {"label": "check-build"} ⟧⟧
FieldRequiredDescription
timerId❌*Timer ID
label❌*Timer label

* At least one of timerId or label must be provided.

LIST_TIMERS

List all active timers. Leads and secretaries see all timers; other agents see only their own.

⟦⟦ LIST_TIMERS ⟧⟧

No parameters.


Capabilities

ACQUIRE_CAPABILITY

Temporarily gain a capability beyond the agent's core role. Available capabilities: code-review, architecture, delegation, testing, devops.

⟦⟦ ACQUIRE_CAPABILITY {"capability": "code-review", "reason": "found bug during development"} ⟧⟧
FieldRequiredDescription
capabilityCapability name to acquire
reasonWhy you need this capability

RELEASE_CAPABILITY

Release an acquired capability. In practice, capabilities are retained for the session and cleared on termination.

⟦⟦ RELEASE_CAPABILITY {"capability": "code-review"} ⟧⟧
FieldRequiredDescription
capabilityCapability name to release

LIST_CAPABILITIES

List all available capabilities and which ones the agent currently has.

⟦⟦ LIST_CAPABILITIES ⟧⟧

No parameters.


Templates

LIST_TEMPLATES

List all available workflow templates. Any agent can use this.

⟦⟦ LIST_TEMPLATES ⟧⟧

No parameters.

APPLY_TEMPLATE

Instantiate a workflow template into the current DAG. Lead-only. Creates all tasks defined in the template with their dependency relationships.

⟦⟦ APPLY_TEMPLATE {"template": "feature", "overrides": {"task-ref": {"title": "Custom title", "role": "developer"}}} ⟧⟧
FieldRequiredDescription
templateTemplate ID to instantiate
overridesMap of task refs to override fields (title, role)

DECOMPOSE_TASK

Decompose a task description into suggested sub-tasks using NL analysis. Useful for planning before creating a DAG.

⟦⟦ DECOMPOSE_TASK {"task": "Build a REST API with authentication and rate limiting"} ⟧⟧
FieldRequiredDescription
taskTask description to decompose
Documentation generated by AI

Documentation generated by AI