Agent Delegation
هذا المحتوى غير متوفر بلغتك بعد.
Agent Delegation
Section titled “Agent Delegation”Schedule AI agents to run on a cron schedule or delegate subtasks from one agent to another. Requires the claw plugin (ɳClaw bundle, $0.99/mo).
What It Does
Section titled “What It Does”Agent delegation lets one agent hand off a bounded task to a subagent with an inherited, never-escalated permission scope. At P95, the primary entry point is cron-triggered agents: schedule any agent to run automatically using a standard cron expression.
The full multi-agent runtime (A→B during a conversation, result routing, agent memory sharing) ships in v1.2.
Requirements
Section titled “Requirements”- claw plugin installed and licensed
- cron plugin installed
PLUGIN_CLAW_INTERNAL_URLset (or defaulthttp://plugin-claw:3710reachable)
Schedule an Agent via Cron
Section titled “Schedule an Agent via Cron”nself cron add \ --agent assistant \ --context '{"task":"send morning briefing"}' \ --schedule "0 9 * * *" \ --name "morning-briefing"--agent: agent ID to invoke--context: JSON context forwarded to the agent--schedule: standard 5-field cron expression (timezone via--timezone America/New_York)- The job owner’s RBAC scope is inherited by the subagent automatically
Permission Inheritance
Section titled “Permission Inheritance”A delegated agent inherits the job owner’s permissions. It cannot escalate, if a requested tool is not in the owner’s ACL, the delegation is rejected before the job is enqueued.
Owner has: [email.read, calendar.list, notes.write]Agent requests: [email.read, calendar.list] ← OKAgent requests: [finance.transfer] ← Rejected: ErrPermissionEscalationFailure Handling
Section titled “Failure Handling”| Situation | Default behavior |
|---|---|
| Agent times out (default 120s) | Return partial result to caller |
| 3 consecutive failures in 60s | Circuit breaker opens for 30s |
| Sensitive tool invoked | Pause and surface approval in nclaw UI |
Override the timeout globally via CRON_AGENT_TIMEOUT_SECS.
Override failure behavior per-deploy in plugin.yaml:
agent_delegation: timeout_seconds: 300 on_failure: escalate_human # return_partial | escalate_human | abort human_handoff_tools: - email.send - finance.transferHow It Works
Section titled “How It Works”When a cron job with delivery: agent fires, the cron scheduler calls the claw plugin’s
internal /internal/agent/handoff endpoint. The claw plugin writes the handoff envelope to
np_agent_handoffs with status: queued. The v1.2 runtime will dequeue and execute it.
Coming in v1.2
Section titled “Coming in v1.2”- In-conversation A→B delegation (agent delegates a subtask mid-reasoning-loop)
- Result routing back to the calling agent
- Agent memory sharing between delegating and delegated agents
- Admin UI showing the handoff queue