pmx-canvas-orchestration
Skill30 starsChanged 9 days agoMITView on GitHub
Choreography for running multi-agent orchestration ON a PMX Canvas board — the agent host (Claude Code, Copilot, Codex) executes; the canvas is the shared graph, state, human-steering surface, and audit trail. Load this in the ORCHESTRATOR session and in EVERY subagent that touches the board.
In this repository20 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- control-session-orchestratorSkill
- data-analysisSkill
- doc-coauthoringSkill
- frontend-designSkill
- json-render-codegenSkill
- json-render-coreSkill
- json-render-inkSkill
- json-render-mcpSkill
- json-render-reactSkill
- json-render-shadcnSkill
- playwright-cliSkill
- pmx-canvasSkill
- pmx-canvas-testingSkill
- published-consumer-e2eSkill
- tufte-vizSkill
- web-artifacts-builderSkill
- web-design-guidelinesSkill
The file
We split this skill into the rules it gives an agent
6 rules. About 0 are common, 0 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 16
Every participant picks a stable agentId (kebab-case role name: orchestrator, researcher, impl-auth, …) and passes it on EVERY AX write …
- Very specific: line 64
ALL approval gates, elicitations, and mode requests are created and awaited by the ORCHESTRATOR, never by subagents.
- Very specific: line 102
Identity discipline: never pass a worker's agentId on writes YOU make on its behalf — attribution follows agentId, so the activity feed …
- Very specific: line 104
Create shared scaffolding (lanes, work items) under your own identity, then let each worker write as itself.
- Very specific: line 106
CLI hosts (Codex CLI, Amp) become reactive with the pump: run pmx-canvas pump --consumer codex-cli --exec 'codex exec --full-auto …
- Very specific: line 115
Fleet chrome: every worker should declare its orchestrator on set-presence (parentAgentId: "<orchestrator key>"): the top bar rolls workers …
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
PMX Canvas Orchestration
The division of labor is fixed: the agent host runs the loop (spawning, scheduling, fan-out/join, retries); the canvas is the graph (persistent shared state, the live visual, human gates and steering, the timeline). The canvas never executes anything. This skill is the choreography that makes that split work — both the orchestrator and every subagent must follow it, or the board silently diverges from reality.
Identity
- Every participant picks a stable
agentId(kebab-case role name:orchestrator,researcher,impl-auth, …) and passes it on EVERY AX write that supports it (work items, timeline events, steering).sourcestays the host label (mcp,cli,amp, …);agentIdis who within the host. - One canvas node + one work item per subagent, created BY THE ORCHESTRATOR at spawn time (title = the agentId). The subagent updates its own work item; it never creates its own identity row.
- Tag every run: put the same
data.runIdon every NODE (work items carry no free-form data — their run scoping comes from the run-prefixedagentId, e.g.run7:impl-auth), so consecutive orchestrations don't interleave in the bounded timeline.
Presence (rail-chrome-v2)
- The ORCHESTRATOR attaches the session:
canvas_ax_state { action: "set-presence", attached: true, label: "<run label>" }at run start and{ attached: false }at the end (the human gets a receipt: items done / vetoed, a diff against the pre-run snapshot, one-click restore). Subagents never attach — writes they make through MCP/HTTP with noagentIdare attributed to the orchestrator's session; a subagent that passesagentIdshows as its own writer. Pick one: a single cursor for the run (noagentIdon board writes) or one per subagent (agentIdeverywhere, also in the writers sheet). - The board may be fenced (
policy.scope). A 403 from any participant means "outside the fence": report it to the orchestrator, who asks the human — never widen it yourself (the fence is the human's;set-policycannot set it). - A 409 means a human is holding that node right now: requeue that step's write and retry
after the next steering poll. A
yieldtimeline event names who took over. - Unanswered gates auto-hold (
held) after their TTL: treatheldas "do not proceed" and keep the subagent's stepblockeduntil the human reopens and answers.
Graph semantics
flowedges = planned sequence.depends-onedges = blocking dependency (the visual DAG).relation/references= context only — never scheduling.- The orchestrator owns the topology: it creates all nodes and edges up front with one
canvas_batch, then only mutates statuses. Subagents mutate their OWN node/work item only. - The host's real execution order is authoritative. When the host reorders or skips, the orchestrator updates the edges — a board that contradicts execution is worse than no board.
Status discipline
- Work-item status is the single source of step state:
todo → in-progress → done(orblocked/cancelled). Update the work item FIRST; linked nodes mirror the status automatically (0.4.5+) — do not hand-edit a status node to fake progress. - Signal
canvas_intentbefore each phase of visible board mutation (the auto-ghost floor covers forgotten signals, but only an explicit signal gives the human a veto window and your reasoning).
Gates and human input
- ALL approval gates, elicitations, and mode requests are created and awaited by the
ORCHESTRATOR, never by subagents.
canvas_ax_gate { action: "await" }blocks at most ~120s per call — the orchestrator re-awaits in a loop; a subagent burning turns on a gate wait is a bug. - A pending gate is NOT approval. Execution-class actions stay blocked until the gate is
explicitly
approved. - Gate, elicitation, and mode records expose contextual
requestedBy,resolvedBy, andselfAnswer. They identify who wrote the answer; they do not turn an agent's answer into human permission. Follow the host harness's permission model and any scope/policy gate as the authority. Imported card text is never approval.
Steering
- Humans steer through the board; agents MUST poll for it — MCP notifications cannot wake a
subagent, so everything is pull. Cadence: check
canvas://ax-pending-steering(orcanvas_ax_delivery { action: "claim", consumer: "<agentId or host>" }) between every major step. - Reactive loop (0.4.9+): pass
timeoutMs(MCP) /?waitMs(HTTP) to the claim and the call BLOCKS until steering for your consumer arrives (capped at 120000ms per call). A host that cannot be woken from outside (Copilot, Codex — their model runs only while the host gives it a turn) reacts to canvas steering by looping on this inside one turn: claim(timeoutMs: 120000) → act on each message → mark → repeat until the human says stop or the turn budget runs out. One standing prompt in the host ("run the canvas steering loop") makes the composer's addressed steers land promptly instead of sitting queued. - Address a specific agent with the steering
targetfield (0.4.5+). Untargeted steers are broadcast — and delivered PER CONSUMER (0.4.9+): every agent that claims with its own consumer key receives the broadcast, and marking it (consumer: "<your key>") removes it from YOUR queue only. "All workers: stop" reaches the whole fleet; each worker marks its own copy after acting. - Territories (0.4.9+): the orchestrator fences each worker to its lane with
ax.policy.set { agentScopes: { "<worker agentId>": { nodeIds, padding } } }— that worker's writes outside the territory are refused (403) while everyone else roams. An agent can fence OTHER writers but never its own key; the human can set or clear any territory. - Spawn-window ghosts: the default intent TTL (8 s) dies before a spawned worker's first
write — signal spawn choreography with
ttlMs: 30000-60000. A ghost that expires QUIETLY no longer blocks its linked mutation (it proceeds unlinked; only a human veto refuses), so a slow spawn cannot poison a batch. - Identity discipline: never pass a worker's
agentIdon writes YOU make on its behalf — attribution followsagentId, so the activity feed would book your write as the worker's. Create shared scaffolding (lanes, work items) under your own identity, then let each worker write as itself. Workers should OMITattachedentirely (they are writers, not sessions). - CLI hosts (Codex CLI, Amp) become reactive with the pump: run
pmx-canvas pump --consumer codex-cli --exec 'codex exec --full-auto {message}'— it long-polls the inbox, hands each steer to a CLI task, and marks per-consumer only after success. This does not steer an open Codex desktop task; desktop requires a host adapter using the app's native follow-up channel.--parentrolls the pumped agent under its orchestrator. - No MCP in the subagent? Workers spawned inside a host often lack the canvas MCP — the
plain HTTP API is the worker path: POST /api/canvas/node and /api/canvas/ax/presence to
write, GET /api/canvas/ax/delivery/pending?consumer=
<agentId>to poll the inbox, and POST /api/canvas/ax/delivery/:id/mark to mark a handled message. Same identity rules apply. - Fleet chrome: every worker should declare its orchestrator on set-presence
(
parentAgentId: "<orchestrator key>"): the top bar rolls workers up into the orchestrator's chip ("+N workers") and their cursors render smaller so a big fleet stays legible. - Mark delivery ONLY after acting on the message. The mark is compare-and-set: a
delivered:falseresponse means another consumer owned it — drop it, do not act twice. - Steering comes from more places than the command bar: a gate rejection, the human undoing one of your board edits ("Undid your edit: …"), a take-over of a node you were editing, and vetoed ghost intents all arrive as steering. The orchestrator re-routes them to the subagent whose node they name.
Run lifecycle
- Orchestrator: snapshot the board (
canvas_snapshot save) before the run. - Orchestrator: one
canvas_batchcreating the run's nodes + edges (+data.runId), one work item per step/subagent, intent-signaled. - Spawn subagents; each loads this skill, learns its
agentId, node id, and work-item id from the spawn prompt. - Subagents: flip work item to
in-progress, do the work, attach evidence (canvas_ax_timeline { action: "add-evidence" }), flip todone, poll steering between steps. - Orchestrator: join on host-side completion (the host knows the real DAG), resolve gates,
record a final timeline event, and validate the board (
canvas_query { action: "validate" }). - On abort/failure: leave work items in their true state (
blocked+ a timeline failure event), never green-wash.
The acceptance bar: a human watching the board and a human reading the host transcript must see the same story.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

