Scaling Up: Parallel Issues with Herdr, DAG Plans & Autonomous Copilot#

Once Steps 1 through 5 click (scoping in words, proving behavior with deterministic CI, and reading code once at PR time), watching one terminal work through one issue at a time quickly becomes the bottleneck.

Running 3 or 4 issues in parallel without chaos comes down to a simple layout: you open one main Herdr window at the root of your repository, and a Coordinator session inside that window spins up isolated worker worktrees grouped together right underneath your repo in the left sidebar, each covering a separate issue that can safely run in parallel.

Five bundled pieces in agentic-code (herdr, work-herd, pr-autopilot, waiter, and last-look) power that loop alongside github-issues, jira-issues, and local-issues:

  1. One Main Repo Window + Grouped Workers (herdr skill): You stay in one Herdr window rooted in your main checkout. Parallel worker worktrees nest directly underneath that parent repo in the sidebar (working, blocked, done, idle) with --no-focus so nothing steals your cursor or opens extra desktop windows.
  2. Herdr DAG Planning & Ground-Truth Coordinator (work-herd skill): Inspects your shortlisted GitHub issues, Jira tickets, or local issues, builds an issue dependency and hotspot DAG (dependency order with no collisions) before spawning workers, double-checks workers' "DONE" claims, and refills open slots as you merge PRs.
  3. Autonomous Copilot Convergence (pr-autopilot + waiter): Each worker drives its own PR through GitHub Actions CI and GitHub Copilot reviews to merge-ready without human babysitting (and without ever running gh pr merge).
  4. One-PR-at-a-Time Human Merge Walkthrough (last-look skill): When a wave finishes and 3 or 4 PRs are ready at once, /last-look briefs strictly one PR per turn in plain English (what changes, prod vs. test size, post-review drift, 1 to 2 core files to eyeball, and a live 3-way conflict check) and re-checks the next PR after each merge.
Herdr Window (Left Sidebar)
└── my-service                  [Coordinator: root checkout on main]
    ├── #101 expiring-links     [working]   feat/101-expiring-links (worktree)
    ├── #102 portable-go-ci     [working]   feat/102-portable-go-ci (worktree)
    └── #103 powershell-tabs    [done]      feat/103-powershell-tabs (worktree)
01 // MAIN REPO WINDOW (COORDINATOR + work-herd SKILL) Shortlist Sprint / Topic Issues -> temp/plans/<repo>-herd.md Filters GitHub or Jira tickets around your focus area, then maps dependencies + hotspot files into a conflict-free Issue DAG.
WORKER 01 // READY Worktree #101 Plan -> TDD -> finish-issue -> PR -> pr-autopilot
WORKER 02 // READY Worktree #102 Plan -> TDD -> finish-issue -> PR -> pr-autopilot
QUEUED IN DAG #104 (Blocked on #101) Auto-fills Worker 01's slot once you merge #101.
INTERRUPT 01 // DONE /last-look Merge Queue Walks you through ready PRs 1 at a time, cleans worktrees on merge, and refills the DAG slot.
INTERRUPT 02 // BLOCKED Design or Approval Call Sidebar highlights blocked when a worker hits an API or scope choice.
INTERRUPT 03 // STALEMATE 3-Strike Circuit Breaker Stops after 3 failed attempts instead of burning tokens or Copilot quota.

1. One-Time Herdr Integration Setup#

Herdr ships its own version-matched CLI skill inside the herdr binary (paired with the work-herd orchestration skill):

# Install Herdr state-tracking hooks for OpenCode (also supports antigravity-cli, claude, codex, copilot)
herdr integration install opencode
herdr integration status

# Inspect Herdr's built-in CLI mechanics guide
herdr --skill

Built-in safety gate (HERDR_ENV=1): Every pane inside Herdr sets HERDR_ENV=1. Both herdr --skill and work-herd verify HERDR_ENV=1 before running session commands so an external terminal never mutates your workspace by mistake.


2. Narrow the Candidate List, Then Build a Herdr DAG Plan#

Real repositories often have hundreds or thousands of open tickets, and four green PRs that all touch the same shared file turn into three rebase conflicts the moment the first PR merges.

Give your Coordinator session inside Herdr a focus filter (next-sprint priorities, a subsystem you care about, a GitHub label or milestone, or your open Jira sprint tickets) so github-issues or jira-issues shortlists the right candidates first and work-herd builds the DAG plan:

Give me a shortlist of GitHub issues to tackle in the next sprint (or issues related to CLI output and error handling), then come up with a Herdr plan once I confirm the list.

(Tracking stories in Jira or already know the exact tickets? Point at them directly:)

Look at my open Jira tickets in PROJ for the current sprint (or GitHub issues #101 through #105) and come up with a Herdr plan.

Once the shortlist is set, work-herd inspects those tickets against the codebase and writes a disposable, git-ignored plan doc (temp/plans/<repo>-herd.md) mapping out:

  1. Logical dependencies: for example, #104 needs the new interface introduced by #101.
  2. Hotspot file edges: if both #101 and #105 edit the same root registration table or actions.yaml, work-herd adds a DAG edge (#101 -> #105) or assigns the shared table edit to one PR so concurrent branches never collide.
  3. Wave lineup & automatic slot refilling: Wave 1 fills up to your concurrency cap (default: 4 workers). As soon as you merge #101, the coordinator tears down #101's worktree and immediately provisions #104 into the open slot.
Wave 1 (Ready Now, non-overlapping packages):
  - #101 (internal/shortener)   --> unblocks #104
  - #102 (ci/go-ci)             --> independent
  - #103 (docs/reference)       --> independent

Wave 2 (Queued in DAG):
  - #104 (cmd/shorty flags)     [blocked on #101: uses new Store option]
  - #105 (internal/shortener)   [blocked on #101: hotspot shortener.go]

Once the DAG looks right, tell the coordinator: "Looks good, kick off Wave 1."


3. Why Autonomous Copilot (pr-autopilot + waiter) Makes This Work#

If four workers stopped the moment they ran gh pr create, you would still spend the afternoon manually babysitting CI runs and GitHub Copilot comments across four tabs. Instead, each worker's template (work-herd/worker-prompt.md) automatically hands its new PR to pr-autopilot:

  • Zero context-window poll spam (waiter subagent): Waiting 4 minutes for CI or Copilot runs inside a cheap 1-line waiter subagent (Slot 3 utility model) rather than dumping per-minute status JSON into the worker's context.
  • Reads all 4 PR surfaces: Checks paginated GraphQL reviewThreads, collapsed <details> findings inside Copilot's review body, general PR comments, and gh pr checks, while guarding against Copilot "insufficient remaining quota" comments posing as clean reviews.
  • Protects Copilot quota (review_on_push: false): Replies and resolves nits via GraphQL without pushing, batches mechanical code fixes into one verified push + PR body sync, and waits for 100% green CI before requesting a Copilot delta re-review.
  • Confirms review drain before reporting DONE: Checks the GitHub issue timeline to prove no trailing review_requested or copilot_work_started event is still running.

4. Coordinator Ground-Truth Check & One-at-a-Time Merge Walkthrough (last-look)#

Across real multi-agent runs, workers occasionally claim "DONE" prematurely (for example, missing a page-2 comment or reporting before a check finishes). Before notifying you, the work-herd coordinator re-verifies live GitHub ground truth (headRefOid, 0 unresolved GraphQL threads, 0 open review body findings, green CI, and drained Copilot timeline) and sends you the full clickable PR URL.

When several PRs finish around the same time, reviewing four walls of test files back-to-back causes review fatigue. Ask your coordinator:

Walk me through the ready PRs to merge.

(Or run /last-look.) The last-look skill steps through your merge queue strictly one PR per turn:

  1. Verifies live merge readiness: Fetches the PR ref and runs a fresh read-only 3-way merge check (git merge-tree --write-tree <pr_head> origin/main), separates production LOC from test/doc LOC, checks whether post-review commits fixed real bugs or added bloat, verifies the squash-commit PR_TITLE and PR_BODY, and links the 1 to 2 core files worth reading on GitHub.
  2. Waits for your call on that single PR: Reply merged once you click Merge on GitHub (or trim <X>, hold, or next).
  3. Cleans up & re-checks the next PR against updated main: Confirming MERGED on GitHub, it tears down the merged worktree, fast-forwards local main, provisions any newly unblocked Wave 2 ticket in your Herdr DAG, and re-runs git merge-tree on the next ready PR against the freshly updated main before presenting its brief.