module-batch

Orchestrates parallel multi-module code changes using isolated git worktrees and subagents.

1|Updated Sep 11, 2026
One-click install
npx skills add https://github.com/lldwb/lldwb-claude-skills --skill module-batch-lldwb
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: module-batch
Source: https://github.com/lldwb/lldwb-claude-skills/tree/main/skills/module-batch
Command: npx skills add https://github.com/lldwb/lldwb-claude-skills --skill module-batch-lldwb

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Applying the same change across many modules serially is slow and error-prone, and parallel edits often collide on shared files or silently skip tests. This Skill coordinates multi-module batch changes by giving each module its own git worktree, branch, and subagent, then merging everything back with evidence-based verification. ## Core Features & Use Cases - Worktree-isolated parallel execution: One module = one worktree = one subagent = one branch, so units never interfere with each other. - Separation of orchestration, execution, and review: The main agent only dispatches and merges; independent read-only review subagents audit each change adversarially, and separate fix subagents apply minimal corrections. - Failure containment and reporting: Failures never block other units—retries are capped at 2, unresolved items are flagged for manual intervention, and a closing report compares pre/post failure sets to prove behavior was not broken. - Use Case: You need to migrate 12 service modules to a new logging framework. The Skill creates 12 worktrees, runs 12 subagents in parallel with test commands and acceptance gates, reviews each change, merges branches back (taking the union on shared-file conflicts), and produces a closing report. ## Quick Start Ask the agent to use module-batch to apply the same refactoring task across these module paths in parallel, specifying the test command and acceptance gate for each module.

Frequently Asked Questions about module-batch

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run the same code change across multiple modules in parallel?

Provide the main branch, a default task description, and the list of module paths. The Skill creates one git worktree and subagent per module, runs them in parallel with your test command and acceptance gate, then merges all branches back.

How does git worktree isolation prevent conflicts in batch refactoring?

Each module gets its own worktree directory and branch checked out from the main branch, so concurrent edits never touch the same working directory. Before merging, the Skill diffs changed files across branches and resolves shared-file conflicts by taking the union of changes.

What happens when one module fails during a parallel batch task?

A single unit's failure does not affect other units. The subagent is retried up to 2 times; if it still fails, the module is recorded as needing manual intervention and the remaining units continue to completion.

When should I use refactor instead of module-batch?

Use refactor alone for a single unit that does not need parallel execution, since it defines the contract and test baseline. Use module-batch when multiple modules need the same change with worktree isolation; the two combine for multi-module refactoring.

Why must each subagent prompt include test commands and acceptance gates?

Subagents start with a fresh context and will trim the task on their own if completion criteria are undefined, typically skipping tests. The task description must state the core change, test command, failure tolerance terms, and acceptance gate to be verifiable.