Task Router for Openclaw

A distributed task queue and agent coordinator designed for complex multi-agent systems to manage routing, load balancing, and task lifecycles.

capt-marbles
v1.0.0
Feb 17, 2026
0
1.9k
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install task-router-skill

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install task-router-skill using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is Task Router?

The Task Router skill serves as the backbone for sophisticated multi-agent environments, providing a robust distributed task queue. It enables seamless coordination between specialized agents by matching tasks to specific capabilities, ensuring that every piece of work is handled by the most qualified resource available. As a foundational component among Openclaw Skills, it handles everything from simple asynchronous handoffs to complex, multi-step autonomous workflows.

Beyond simple routing, this skill manages the entire task lifecycle, including load balancing, health monitoring, and dead-letter queueing. By decoupling task creation from execution, it allows developers to build highly scalable and resilient AI systems where agents can work independently without blocking main user sessions.

Task Router Use Cases

  • Programmatic task creation from heartbeats to trigger automated background research or data analysis.
  • Routing complex work to specialized agents based on specific capabilities like image generation, web search, or coding.
  • Managing multi-step workflows where the output of one task serves as the required input for the next.
  • Coordinating asynchronous agent work to prevent blocking the main session during long-running operations.
  • Implementing load balancing across multiple agent instances to optimize system throughput and performance.

How Task Router Works

  1. Agents register themselves with the router, specifying their unique capabilities, emojis, and maximum concurrent task limits.
  2. Tasks are enqueued via the CLI or programmatic API, including specific metadata like priority, TTL, and dependencies.
  3. The router cycle, typically triggered via a heartbeat integration, analyzes pending tasks and matches them to available agents using configurable strategies.
  4. Once assigned, agents acknowledge and execute the tasks, transitioning through states from assigned to running and finally complete.
  5. Upon completion or failure, the router handles the final state transition, triggers notifications, or moves exhausted tasks to the dead-letter queue for manual review.

Task Router Setup

Install the skill using the standard hub command:

# Install the skill
clawhub install task-router

# Register a specialized agent
task agent register watson --capabilities "research analysis" --max-concurrent 3

# Verify the router status
task router status

Ensure your environment supports sessions_send and sessions_spawn for full agent coordination within the Openclaw Skills ecosystem.

Task Router Data Schema & Taxonomy

The skill organizes its state and configuration within the ~/.openclaw/task-router/ directory using a clear taxonomy:

Path Purpose
config.yaml Global router settings, strategy definitions, and timeout thresholds.
agents.yaml Registry of active agents, their capabilities, and real-time health statistics.
queue/ Sub-directories (pending, active, completed, failed) storing task state files.
dead-letter/ Storage for tasks that have exhausted all retries and require manual intervention.
logs/ Detailed logs of routing decisions and agent pings for troubleshooting.

Task Router Advanced Features

  • Pluggable routing strategies including round-robin, least-loaded, fastest-response, and priority-first.
  • Comprehensive programmatic TypeScript SDK for building custom automation and complex Openclaw Skills integrations.
  • Task dependency management allowing for parallel execution or sequential chaining of agent actions.
  • Automated health monitoring that reassigns tasks if an agent fails a heartbeat check.
  • Detailed dead-letter queue management for auditing, retrying, or archiving failed high-priority tasks.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*