Back to Blog
Product

From Solo Agents to Orchestrated Teams: Workflows, Schedules & Handoffs

Three new primitives turn Hivemind from a coordination layer into a full orchestration platform — without becoming an orchestrator.

GB

Gabriel Bram

February 23, 20265 min read

The Problem

You have three agents. One refactors auth, one builds payments, one writes tests. They coordinate through Hivemind events — publishing tasks, querying status, locking files. But what happens when agent A finishes and agent B needs to start? What about a nightly pipeline that runs tests, waits for approval, and deploys? What about passing work between agents with full context?

Events are the foundation, but multi-step sequencing, scheduled automation, and formal work transfers need dedicated primitives.

Three New Primitives

Hivemind now ships three orchestration primitives that compose on top of the event log:

Workflows
DAG pipelines with task, gate, condition & parallel nodes
Schedules
Cron-based triggers for workflows & events
Handoffs
Formal work transfers with context bundling

All three are available through the MCP tools, TypeScript/Python SDK, REST API, and dashboard.

DAG Workflows

A workflow is a directed acyclic graph of nodes and edges. Four node types cover the common patterns:

  • Task — publishes a task.created event for an agent to pick up
  • Gate — pauses until a human approves (via the approvals system)
  • Condition — branches based on previous node outputs
  • Parallel — fans out to run successor nodes concurrently
hivemind_workflow(action: "create", name: "Deploy Pipeline", nodes: [
  { nodeId: "test", type: "task", label: "Run Tests", config: { channel: "ci" } },
  { nodeId: "approve", type: "gate", label: "Human Approval" },
  { nodeId: "deploy", type: "task", label: "Deploy to Staging", config: { channel: "deploy" } }
], edges: [
  { from: "test", to: "approve" },
  { from: "approve", to: "deploy" }
])

When you run the workflow, the engine publishes task events, waits for completions, advances through gates, and handles failures. A cron job runs every minute to catch stuck nodes and enforce timeouts.

Cron Schedules

Schedules trigger workflows or emit events on a cron expression. Hivemind evaluates all active schedules every minute.

hivemind_schedule(action: "create", name: "Nightly Tests", cron_expression: "0 2 * * *", action_type: "run_workflow", workflow_id: "wf_xxx")

Or emit a standalone event:

hivemind_schedule(action: "create", name: "Hourly Health Check", cron_expression: "0 * * * *", action_type: "emit_event", emit_channel: "monitoring", emit_event_type: "schedule.health-check")

Agent Handoffs

When agent A finishes a piece of work and agent B needs to continue, a handoff bundles the context and creates a trackable request:

hivemind_handoff(action: "request", channel: "backend", target_agent: "agent-b", description: "Auth refactored, ready for API integration", context: { "files_changed": ["src/auth.ts"], "decisions": ["JWT to sessions"] })

The target agent can accept or reject. The dashboard tracks success rates, acceptance times, and volume per agent pair.

Dashboard Views

The dashboard includes dedicated pages for workflows and schedules with real-time status. Create workflows visually, monitor run progress node-by-node, toggle schedules, and review handoff metrics.

Getting Started

All three primitives are available now:

npm install @hivemindai/sdk-ts@latest

Or use the MCP tools directly — hivemind_workflow, hivemind_schedule, and hivemind_handoff are available in Claude Code and Cursor.

What's Next

These primitives are intentionally composable. A schedule can trigger a workflow, a workflow node can request a handoff, and a handoff acceptance can start another workflow. The event log ties everything together — every orchestration action is an event, queryable and auditable.

workflowsscheduleshandoffsorchestrationDAG