Loading...
Loading...
Create pull request from completed feature branch using GitHub-native stacked PRs. Use when the user says 'create PR', 'submit for review', 'synthesize', or runs /synthesize. Validates branch readiness, creates PR with structured description, and manages merge queue. Do NOT use before review phase completes. Not for draft PRs.
npx skill4agent add lvlup-sw/exarchos synthesizecreate_prmerge_prlist_prscheck_cighglabazNot to be confused with the integration merge. This skill callsto land a user-facing PR onmerge_prvia the VCS provider — a remote operation. The upstream sibling ismain(serialize_merge): the integration-merge path that holds a single-writer lease and composes a local@skills/merge-orchestrator/SKILL.mdof a subagent worktree branch onto the integration branch during thegit mergeHSM loop (rawdelegate → merge-pending → delegateis that composed executor / the non-integration path). Synthesize never invokesmerge_orchestrateorserialize_merge; merge-pending never invokesmerge_orchestrate.merge_pr
prepare_synthesisreviewreviewoneshotplanimplementingrequest_synthesizefinalize_oneshotsynthesize@skills/oneshot/SKILL.mdsynthesisPolicysynthesizesynthesizefinalize_oneshotRunbook: Follow the synthesis-flow runbook:If runbook unavailable, useexarchos_orchestrate({ action: "runbook", id: "synthesis-flow" })to retrieve action schemas:describeexarchos_orchestrate({ action: "describe", actions: ["prepare_synthesis"] })
prepare_synthesisexarchos:exarchos_orchestrate({
action: "prepare_synthesis",
featureId: "<id>"
})npm run test:run && npm run typecheckstate.verification.hasBenchmarkscode_qualitygate.executedreferences/synthesis-steps.mdreviewdelegateconfidenceLevel: 'actionable'suggestedActionreferences/pr-descriptions.md.exarchos/pr-template.md<type>: <what>cat > /tmp/pr-body.md <<'EOF'
## Summary
[2-3 sentences: what changed, why it matters]
## Changes
- **Component** -- Description of change
## Test Plan
[Testing approach and coverage]
---
**Results:** Tests X pass · Build 0 errors
**Design:** [doc](path)
**Related:** #issue
EOFexarchos:exarchos_orchestrate({
action: "validate_pr_body",
bodyFile: "/tmp/pr-body.md"
})create_pr// Create PR via VCS MCP action
exarchos_orchestrate({
action: "create_pr",
base: "<parent-branch>",
head: "<branch>",
title: "<type>: <what>",
body: "<pr-body>"
})
// Enable auto-merge
exarchos_orchestrate({
action: "merge_pr",
prId: "<number>",
strategy: "squash"
})verification.hasBenchmarksgh pr edit <number> --add-label has-benchmarksexarchos_orchestrate({ action: "list_prs", state: "open" })exarchos:exarchos_workflow({
action: "update", featureId: "<id>", updates: {
"artifacts": { "pr": ["<url1>", "<url2>"] },
"synthesis": { "mergeOrder": ["<branch1>", ...], "prUrl": ["<url1>", ...], "prFeedback": [] }
}
})references/merge-ordering.mdcleanupshepherd [PR_URL]rehydratestack.submittedexarchos:exarchos_event({ action: "append", stream: "<featureId>", event: {
type: "stack.submitted",
data: {
branches: ["task-001-branch", "task-002-branch"],
prNumbers: [101, 102]
}
}})exarchos:exarchos_event({ action: "append", stream: "<featureId>", event: {
type: "shepherd.iteration",
data: {
iteration: 1,
prsAssessed: 2,
fixesApplied: 0,
status: "all-green"
}
}})check-event-emissionsexarchos:exarchos_workflow({
action: "cleanup", featureId: "<id>", mergeVerified: true,
prUrl: ["<url>", ...], mergedBranches: ["<branch>", ...]
})git fetch --pruneWorktree GC cadence — after synthesize (INV-12). Once a workflow reaches synthesis its governed worktrees are no longer needed, so this is the point to reclaim them. Use the governed garbage-collectorrather than ad-hocprune_worktrees: dry-run first (the default — reports candidatesgit worktree remove
- reclaimable bytes, deletes nothing), then re-invoke with
to apply.dryRun: falsetypescriptexarchos:exarchos_orchestrate({ action: "prune_worktrees", repoRoot: "<repo-root>" }) // dry-run (default) exarchos:exarchos_orchestrate({ action: "prune_worktrees", repoRoot: "<repo-root>", dryRun: false }) // applyTheprojection surfaces this samenext_actionsdry-run affordance once the workflow is parked in synthesis. The full apply flow lands inprune_worktrees.@skills/cleanup/SKILL.md
create_prsynthesis.prUrlartifacts.prcreate_pr(head, base)PR_ALREADY_OWNEDcreate_prcompletedaction: "transition"target: "completed"updates.phasetransitionworkflow.transitioncompletedcleanupaction: "cleanup"git add <files> && git commit --amend--force-with-leasegit push --force-with-lease=<ref>:<expected-sha><expected-sha>assess_stackgit ls-remote --heads origin <ref>## Synthesis Complete
PR: [URL]
Tests: X pass | Build: 0 errors| Don't | Do Instead |
|---|---|
| Skip review phase | Always run |
| Force push stack branches | Use normal push |
| Delete worktrees before merge | Wait for merge confirmation |
| Create PR with failing tests | Ensure review phase passes first |
| Run readiness scripts manually | Use |
references/troubleshooting.md@skills/checkpoint/references/phase-transitions.mdsynthesizecompletedpr-url-existssynthesis.prUrlartifacts.prsetphaseexarchos_workflow({ action: "describe", actions: ["update", "init"] })exarchos_workflow({ action: "describe", playbook: "feature" })exarchos_orchestrate({ action: "describe", actions: ["prepare_synthesis"] })prepare_synthesisreferences/pr-descriptions.md