orchestrate
Use only when the user explicitly types `/orchestrate <goal>` to decompose a large task, spawn a tree of parallel cloud-agent workers/subplanners/verifiers via the Cursor SDK, and collect structured handoffs; do not invoke autonomously.
- License 许可
- MIT
- 最近更新
- 2026-11-14
- Stars
- ★ 0
- Forks
- 1
01 前言 Front Matter
- name
- orchestrate
- description
- Use only when the user explicitly types `/orchestrate <goal>` to decompose a large task, spawn a tree of parallel cloud-agent workers/subplanners/verifiers via the Cursor SDK, and collect structured handoffs; do not invoke autonomously.
- disable-model-invocation
- true
02 资源文件 78
- 参考文档prompts/andon-block.md665 B
- 参考文档prompts/empty-error-handoff.md206 B
- 参考文档prompts/failure-handoff.md554 B
- 参考文档prompts/finished-no-handoff.md735 B
- 参考文档prompts/loop-hygiene.md1.8 KB
- 参考文档prompts/root.md670 B
- 参考文档prompts/slack-block.md1.5 KB
- 参考文档prompts/subplanner.md3.0 KB
- 参考文档prompts/verifier.md3.9 KB
- 参考文档prompts/worker.md3.0 KB
- 参考文档references/dispatcher.md3.2 KB
- 参考文档references/handoffs.md11.2 KB
- 参考文档references/planner.md9.2 KB
- 参考文档references/spawning.md7.8 KB
- 参考文档schemas/plan.schema.json22.0 KB
- 参考文档schemas/state.schema.json7.4 KB
- 脚本scripts/__tests__/agent-manager-slack-mirror.test.ts19.9 KB
- 脚本scripts/__tests__/andon-root-cache.test.ts12.2 KB
- 脚本scripts/__tests__/checkpoint-restart.test.ts6.2 KB
- 脚本scripts/__tests__/comment-cli.test.ts7.5 KB
- 脚本scripts/__tests__/comment-retry-queue.test.ts11.9 KB
- 脚本scripts/__tests__/exit-on-error.test.ts5.0 KB
- 脚本scripts/__tests__/failure-handoff.test.ts6.6 KB
- 脚本scripts/__tests__/handoff-branch-parser.test.ts3.8 KB
- 脚本scripts/__tests__/handoff-verification-parser.test.ts4.1 KB
- 脚本scripts/__tests__/handoff-verification-record.test.ts5.4 KB
- 脚本scripts/__tests__/kickoff-dedupe.test.ts5.2 KB
- 脚本scripts/__tests__/measurements-compare.test.ts6.1 KB
- 脚本scripts/__tests__/measurements-mismatch.test.ts9.1 KB
- 脚本scripts/__tests__/measurements-parser.test.ts3.1 KB
- 脚本scripts/__tests__/models-catalog.test.ts3.6 KB
- 脚本scripts/__tests__/operator-boundary.test.ts3.3 KB
- 脚本scripts/__tests__/probe-models.test.ts2.0 KB
- 脚本scripts/__tests__/prompt-plan-validation.test.ts2.6 KB
- 脚本scripts/__tests__/redact-body.test.ts1.6 KB
- 脚本scripts/__tests__/schemas.test.ts8.5 KB
- 脚本scripts/__tests__/slack-adapter.test.ts9.7 KB
- 脚本scripts/__tests__/slack-channel-boundary.test.ts2.5 KB
- 脚本scripts/__tests__/slack-message-format.test.ts2.6 KB
- 脚本scripts/__tests__/slack-prompt-shape.test.ts6.8 KB
- 脚本scripts/__tests__/support/slack-web-api-mock.ts2.1 KB
- 脚本scripts/__tests__/verifier-startingref-reconcile.test.ts8.6 KB
- 脚本scripts/__tests__/wait-handoff-failure.test.ts9.6 KB
- 脚本scripts/__tests__/watchdog-inspect.test.ts2.8 KB
- 脚本scripts/__tests__/worker-branch-discipline.test.ts3.9 KB
- 脚本scripts/adapters/index.ts370 B
- 脚本scripts/adapters/README.md1.2 KB
- 脚本scripts/adapters/slack/client.ts446 B
- 脚本scripts/adapters/slack/index.ts8.2 KB
- 脚本scripts/adapters/types.ts1.8 KB
- 脚本scripts/biome.json503 B
- 脚本scripts/bun.lock39.0 KB
- 脚本scripts/cli.ts73 B
- 脚本scripts/cli/andon.ts3.8 KB
- 脚本scripts/cli/comments.ts10.0 KB
- 脚本scripts/cli/forensics.ts5.3 KB
- 脚本scripts/cli/index.ts958 B
- 脚本scripts/cli/inspect.ts7.6 KB
- 脚本scripts/cli/task.ts20.2 KB
- 脚本scripts/cli/util.ts17.1 KB
- 脚本scripts/core/agent-manager.ts67.3 KB
- 脚本scripts/core/andon.ts7.3 KB
- 脚本scripts/core/branches.ts1.1 KB
- 脚本scripts/core/comment-retry-queue.ts9.7 KB
- 脚本scripts/core/failure-handoff.ts6.4 KB
- 脚本scripts/core/handoff.ts7.4 KB
- 脚本scripts/core/loop.ts10.1 KB
- 脚本scripts/core/prompts.ts10.2 KB
- 脚本scripts/core/redact-body.ts2.1 KB
- 脚本scripts/errors.ts117 B
- 脚本scripts/measurements.ts12.5 KB
- 脚本scripts/models.ts6.9 KB
- 脚本scripts/package.json763 B
- 脚本scripts/schemas.ts20.6 KB
- 脚本scripts/tools/generate-json-schemas.ts1.5 KB
- 脚本scripts/tools/nudge-root.ts6.6 KB
- 脚本scripts/tools/probe-models.ts2.6 KB
- 脚本scripts/tsconfig.json362 B
03 SKILL.md 正文
Orchestrate
An explicit /orchestrate <goal> fans out a large task across parallel Cursor cloud agents. Workers don't talk to each other; they talk up through structured handoffs. The spawn, wait, and handoff loop lives in scripts/cli.ts. The planner writes plan.json, the script executes it, and the planner reads handoffs to decide what comes next. Long-running agent loops drift; a script with a JSON state file keeps its footing.
Required reading: the cursor-sdk skill (cursor/plugins/cursor-sdk). Spawning, auth, and the error taxonomy live there. Don't reimplement what that skill already documents.
Setup
CURSOR_API_KEYmust be a personal/user key. Create it from Cursor Dashboard > Integrations, then readcursor-sdkAuth before using it.SLACK_BOT_TOKENis optional. When set, pass--slack-channel <id>tokickoffor the firstrun --root, or setSLACK_CHANNEL_ID. The script stores the channel inplan.slackChannel, posts the kickoff thread there, mirrors task status, and reads Andon reactions. When the token is unset, the script logs once and runs without Slack visibility; correctness does not change.
Core principles
These rules make the tree self-converging without global coordination.
- Planners own scopes and publish tasks. They do no coding. Writing
plan.json, reading handoffs, and deciding what's next are planner work. Editing files, runninggit merge, and fixing conflicts inline are not. If a planner feels the urge to code, it publishes a task for a worker instead. - Planners don't know who picks up their tasks. The script routes each task to a cloud agent. The planner's mental model stays at the task level.
- Workers are isolated. One task, one clone of the repo, no channel to any other agent. One handoff when done.
- Subplanners are recursive planners. A planner publishes a "subplan this slice" task; the subplanner fully owns that slice and hands back an aggregated handoff.
- Continuous motion via handoffs. A planner that thought it was done can receive a late handoff and replan. No "finished" state until the planner decides to stop publishing.
- Propagation, not synchronization. No cross-talk between siblings. No shared state between levels. Each level sees only its children's handoffs.
Node types
| Node | Runs the loop? | Scope | Output |
|---|---|---|---|
| Planner | yes | Entire user goal | User-facing message + optional PR |
| Subplanner (↻) | yes | One slice of parent's scope | Handoff to parent |
| Worker | no | One concrete task | Handoff to spawning planner |
| Verifier | no | One target's acceptance criteria | Verdict handoff to spawning planner |
| Git | n/a | Shared medium | Branches (code) + handoffs/ (meaning) |
Role
Two roles, one skill. Read your role's reference file and skip the other.
Dispatcher. You're in a local IDE session and the user typed /orchestrate <goal>. Your job is to kick off a cloud root planner and return its URL. See references/dispatcher.md. One-shot; you are not the planner.
Planner (root or sub). You were spawned with a structured prompt that opens with "You are the root planner for:" or "You are a subplanner for:". Or the user chose to run the planning loop locally. You own a scope, publish tasks, read handoffs, decide what's next. See references/planner.md.
disable-model-invocation: true means this skill loads only on explicit invocation.
04 同仓库更多 Skills
X MCP guide
ALWAYS read this before using any X tool (the X plugin, any X MCP, or Grok Bot's built-in public X reads) and again on any X error. X tools are included in Grok Bot at no cost: never estimate costs, check credits, or tell the user to buy credits. tools=0 / user-X-* not found is a setup failure, not a paywall. Covers Spaces, communities, and Lists (reads and list writes), X Chat (XChat, inbox, DMs, unread, message requests, Chat PIN, juicebox, xchat_lite: clone xchat-grokbot-helper yourself and decrypt locally), scheduled X calls (schedule_call, list_scheduled_calls and the other call tools), and livestreams (stream sources, broadcasts, scheduled broadcasts, broadcast chat, moderators, mutes). Chat, call, livestream, Spaces, or Lists tools missing while other X tools work: reconnect the X plugin.
X Money guide
Read this before the first X Money action in a session and again on any X Money error, refusal, or missing capability. Covers the approval rule for every action that moves money (always ask, every time, no exceptions), how the connection works (connection code plus passkey in the X app), how to guide the user through connect, reconnect, and revoke at x.com/i/money/settings/connections, and what each failure message means.
google-slides
Build and edit Google Slides through the google-slides MCP tools - slides, grids of cards and columns, text boxes, shapes, images, tables, styling, layout inspection, and per-slide PNG rendering. Use when creating a deck, laying out slide elements, matching a template, or verifying how a slide looks.
google-sheets
Build and edit Google Sheets with the google-sheets tools - values, formatting, charts, conditional formatting, structure, validation, named and protected ranges. Use when creating a spreadsheet or dashboard, formatting cells, adding or fixing charts, or reorganizing tabs and rows.
google-drive
Work with Google Drive through its MCP tools - search, read, create, organize, share, comment, and export files. Use when creating files in specific folders, moving or renaming, converting Markdown/CSV into Docs/Sheets, managing comments, or exporting a rendered PDF.
google-docs
Author and edit Google Docs with the google-docs tools - structured writing, character and paragraph styling, lists, tables, images, headers/footers. Use when creating a formatted document, editing document content, or applying styles.