Skip to content

fix(orchestrate): harden orchestrate-dispatch self-containment prompt + docs - #289

Merged
Data-Wise merged 1 commit into
devfrom
feature/orchestrate-dispatch-hardening
Jul 15, 2026
Merged

fix(orchestrate): harden orchestrate-dispatch self-containment prompt + docs#289
Data-Wise merged 1 commit into
devfrom
feature/orchestrate-dispatch-hardening

Conversation

@Data-Wise

Copy link
Copy Markdown
Owner

Summary

Grounded, adversarially-reviewed fix to skills/orchestration/plan-orchestrator/SKILL.md's orchestrate-dispatch mode. Originated from this session's own live use of the mode (dispatching background agents to implement #287/#288) surfacing three undocumented gaps.

Changes (all 4 audited by a read-only background agent before implementation — 3 of 4 needed revision from the original proposal)

  1. Self-containment prompt gains a required absolute-path prefix. The Agent tool has no cwd parameter (confirmed: ~/projects/dev-tools/CLAUDE.md line 42), so the previously-documented minimal prompt ("Read ORCHESTRATE-<topic>.md in full, then execute it.") left a dispatched agent with no way to locate the worktree. Audit caught: an earlier draft's over-broad "confinement" clause would have contradicted this same skill's own Cross-Repo Detection feature — dropped.
  2. New model-tier guidance, cross-referenced against workflow-engine/SKILL.md's existing per-stage Model Routing rule rather than standing alone (audit found the original draft gave opposite, unreconciled advice for the same class of judgment call).
  3. EnterWorktree documented as the Desktop-app-native alternative to cd <worktree> && claude — but only in the STOP-new-session Session Instructions template. Audit found the original draft's placement in orchestrate-dispatch mode's own intro was wrong: that mode dispatches a background agent; an interactive cwd switch there would undermine the mode's own 2-concurrent-dispatch capability.
  4. Resumability wording changed from a literal-string claim ("stays exactly X") to "identical between initial and resumed dispatch", since X now includes a path.

Test plan

  • Read-only adversarial audit dispatched (background agent) against the proposal before any file was touched — full findings in commit message
  • Markdown lint clean (pre-commit hook)
  • N/A — prose/protocol change to a skill definition, no executable test surface beyond the skill's own documented behavior

🤖 Generated with Claude Code

… + docs

Adversarially audited before implementation (background agent, read-only
review of the proposal). Three of four proposed changes needed revision
before landing:

- Self-containment prompt gains a required absolute-path prefix (Agent
  tool has no cwd param) but drops an over-broad confinement clause that
  would have contradicted this skill's own Cross-Repo Detection feature.
- New model-tier guidance reconciled against workflow-engine/SKILL.md's
  existing per-stage Model Routing rule (opposite instruction, different
  scope) with an explicit cross-reference instead of standing alone.
- EnterWorktree guidance applied only to the STOP-new-session Session
  Instructions template, not to orchestrate-dispatch's intro — that mode
  dispatches a background Agent and doesn't need an interactive cwd
  switch; adding it there would have undermined the mode's own
  2-concurrent-dispatch capability.
- Resumability wording changed from a literal-string claim ("stays
  exactly X") to "identical between initial and resumed dispatch", since
  X now includes a path.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@Data-Wise
Data-Wise merged commit ac3db30 into dev Jul 15, 2026
2 checks passed
Data-Wise added a commit that referenced this pull request Jul 15, 2026
All three guard-hardening PRs merged to dev with green CI:
#287 (cd-target resolution), #288 (guards.json lock, no CHANGELOG
conflict with #287 despite both touching it), #289 (orchestrate-dispatch
hardening). Worktrees removed, local branches deleted via safe `-d`
(squash-merge content recognized without needing force).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@Data-Wise
Data-Wise deleted the feature/orchestrate-dispatch-hardening branch July 24, 2026 17:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant