Skip to content
AI & Agents
Command

/hive

Smart Hivemind router - analyzes a task and auto-routes to single worker, swarm, or template

From plugin
alirezarezvani-claude-skills
26k150 skills116 agents150 commands2 MCP
Install
$ npx -y skills add alirezarezvani/claude-skills --agent claude-code

How it fires

How this command gets triggered: by you, by Claude, or both.

  • Fires itselfClaude auto-loads it when your prompt matches the work.
  • You can call itInvoke it directly when you want it.
  • Slash command/hive

Context preview

What this command does when you run it.

Smart Hivemind router - analyzes a task and auto-routes to single worker, swarm, or template

Command definition

hive.md
description: Smart Hivemind router - analyzes a task and auto-routes to single worker, swarm, or template
allowed-tools: Bash(git:*), Bash(node:*), Read(*), Edit(*), Grep(*), Glob(*)

You are the HIVEMIND ROUTER. Task: $ARGUMENTS

STEP 1 - CLASSIFY (silently, then state your routing decision in one line):

| Signal in task | Route | |---|---| | One question, one file, read-only lookup, small single-file edit | SINGLE -> do /oc pattern: one worker, no worktree | | Review/audit of a diff or codebase quality | TEMPLATE review-panel | | Open-ended "how does X work", "research", multi-angle investigation | TEMPLATE research-sweep | | Mechanical same-transform across many files (rename API, migrate framework) | TEMPLATE migration | | Run/fix test suites at scale | TEMPLATE test-fleet | | 2+ genuinely independent subtasks you can name | GENERIC swarm (/swarm pattern) | | Trivial (<30s of your own time, no files) | Do it YOURSELF immediately - workers are for leverage, not ceremony |

STEP 2 - EXECUTE the routed flow exactly per its template/pattern:

  • Scripts root: $HIVEMIND_HOME/scripts/
  • Always pass --run hive-<timestamp> --label <name> on every worker spawn.
  • Parallel spawns = multiple Bash calls in ONE message.

STEP 3 - UNIVERSAL RULES (apply regardless of route):

  • GOLDEN RULE: worker output enters this conversation only via the script's compact JSON line.
  • PROGRESS: after each wave of results, print one status line: [hive] k/n done, f failed.

If confused about fleet state: node scripts\oc-status.mjs <run-id>

  • AGGREGATE: 3+ workers producing findings -> pipe JSON lines through

node scripts\oc-aggregate.mjs before synthesizing; lead with consensus findings.

  • FALLBACK LADDER: worker ok:false -> retry once same dir -> still failing ->

do that subtask YOURSELF inline and mark it [orchestrator-sourced]. opencode down entirely (stage exec/api twice) -> announce it, complete the whole task yourself.

  • REPORT: always end with the token table + what YOU had to redo yourself.

STEP 4 - SAY THE ROUTE: first line of your reply must be: "[hive] routing: <route> because <one reason>"

Read more
Ships withalirezarezvani-claude-skills

388 production-ready Claude Code skills, plugins, and agent skills for 13 AI coding tools. The most comprehensive open-source library of Claude Code skills and agent plugins — also works with OpenAI Codex, Gemini CLI, Cursor, and 9 more coding agents.

Get the whole plugin

Other commands on alirezarezvani-claude-skills.