Files
msd-core/.changeset/1143-claude-orchestration-capability.md
Tom Boucher e3262d94d3 feat(capabilities): add claude-orchestration capability (Workflow backend) (#1143)
Default-off, BETA, claude-only capability adopting Claude Code's Workflow tool
(/effort ultracode, Agent SDK >= v0.3.149) as an optional parallel-execution
backend for the GSD loop. Restores the wave parallelism + plan-checker + verifier
that #853 forces inline on Claude Code, and folds gsd-ultraplan-phase under one
runtime gate.

- Pure fail-closed core (src/claude-orchestration.cts): detectWorkflowBackend
  (gate ladder: enabled -> Claude -> backend != inline -> nested+background host
  -> valid Agent SDK -> SDK >= floor; every miss degrades to inline) and
  emitWorkflowScript (waves -> parallel() barriers, plans -> gsd-executor +
  worktree, files_modified overlap -> separate stages, resumeFromRunId, budget).
  All interpolated identifiers validated script-safe; briefs JSON-quoted.
- claude-orchestration command family (gsd-tools claude-orchestration
  detect-backend|emit-workflow) for orchestrator invocation.
- Two gated loop contributions at wired points (execute:wave:post, plan:post);
  federated config keys (enabled/execution_backend/min_agent_sdk_version).
- ADR-1143 implementation amendment; CONTEXT.md glossary entry; explanation doc.

On any runtime lacking the Workflow tool, behaviour is byte-identical to today.

closes #1143
2026-07-06 15:18:23 -04:00

1.6 KiB

type, pr
type pr
Added 0

A default-off, BETA, claude-only "Claude orchestration" capability — adopts Claude Code's Workflow tool (/effort ultracode, Agent SDK ≥ v0.3.149) as an optional parallel-execution backend for the GSD loop, restoring the wave parallelism + plan-checker + verifier that the #853 backgrounded-agent nesting limitation forces inline on Claude Code, and folding the existing gsd-ultraplan-phase plan-offload under the same runtime gate. When claude_orchestration.enabled is on AND the runtime is Claude AND the Workflow tool is detected AND the Agent SDK meets the floor (claude_orchestration.min_agent_sdk_version, default 0.3.149), execute-phase emits a generated Workflow script (waves → parallel() barriers, plans → agent({ agentType: 'gsd-executor', isolation: 'worktree' }), files_modified overlap → separate sequential stages, resumeFromRunId wired to the phase run id, shared budget pool) that composes the SAME executor agent + worktree isolation the inline path uses, so artifacts/commits are produced identically. Detection is pure and fail-closed (any miss → inline), so on any runtime lacking the Workflow tool behaviour is byte-identical to today. Adds a pure module gsd-core/bin/lib/claude-orchestration.cjs (detectWorkflowBackend, emitWorkflowScript), the capabilities/claude-orchestration/ declaration with two gated loop contributions (execute:wave:post, plan:post) and a claude-orchestration command family (gsd-tools claude-orchestration detect-backend|emit-workflow), federated config keys, and an ADR-1143 implementation amendment. (#1143)