Parallel Execution Optimizer

affaan-m/ECC/pi/core/skills/parallel-execution-optimizer

作者 affaan-mef648e01899ba3e8dc6371642deaaf64b4477775MIT275K 個星標收錄於 2026年10月9日更新於 2026年10月9日儲存庫4 天前更新

Speed up a task by turning it into a dependency graph of parallel lanes with a lane matrix, batched reads and checks, write surfaces isolated by file, worktree, branch, or service, and a final verification table. Use when the user wants a task done much faster through parallel work, concurrent agents, batched tool calls, isolated worktrees, or many independent verification lanes without losing correctness.

AI 產生的概覽

把任務拆成平行通道的相依圖,隔離寫入面,並以驗證表收尾。

功能
此技能提供一套加速工作的方法:先明確目標與完成訊號,再把工作拆分為標記為平行、循序或受閘控的通道。它讓代理建立通道矩陣,涵蓋寫入面、風險與驗證方式,批次執行彼此獨立的讀取與檢查,並依檔案、工作樹、分支、服務或資料集隔離寫入。最後輸出結構化的平行執行結果與驗證表,而不是籠統的速度宣稱。
適用情境
當速度來自同時進行彼此獨立的工作時使用,例如儲存庫檢查、檔案讀取、API 或瀏覽器檢查、建置與測試通道、部署回讀,或多工作樹實作。也適用於涉及並行代理、批次工具呼叫或多個獨立驗證通道的需求。
執行需求
僅為指令,不隨附指令碼。所述流程假定代理具備 Read、Write、Edit、Bash、Grep、Glob 等工具,並可能涉及工作樹、分支、服務或遠端部署。

Parallel Execution Optimizer

Use this skill when speed comes from doing independent work at the same time: repo inspection, file reads, API checks, browser checks, build/test lanes, deploy readbacks, or multi-worktree implementation passes.

Core Pattern

Turn urgency into a dependency graph before acting.

  1. Define the objective and done signal.
  2. Split work into lanes.
  3. Mark each lane as parallel, sequential, or gated.
  4. Run independent reads/checks together.
  5. Keep writes isolated by file, worktree, branch, service, or dataset.
  6. Merge only after evidence shows the lanes are compatible.
  7. End with a verification table, not a vague speed claim.

Lane Matrix

Before a large push, write a compact matrix:

text
Lane | Can run in parallel? | Write surface | Risk | VerificationRepo scan | yes | none | low | rg/git status outputsBackend patch | maybe | src/api | medium | unit testsFrontend patch | maybe | app/components | medium | browser screenshotDeploy readback | after build | remote service | high | live URL + logs

Only run lanes in parallel when their write surfaces do not collide.

Execution Rules

  • Batch file reads, searches, status checks, and metadata queries.
  • Use isolated worktrees for large unrelated implementation lanes.
  • Start long-running tests, builds, backfills, and deploys in separate sessions, then poll them deliberately.
  • If a lane discovers a blocker that changes the plan, pause dependent lanes and update the matrix.
  • Never let a background process outlive the turn unless the user explicitly asked for a continuing service.
  • Do not parallelize destructive commands, migrations, writes to the same table, or live customer-impacting deploys without an explicit gate.

Output Shape

Use this when reporting:

text
Parallel execution result:- Lanes run: 5- Lanes completed: 4- Blocked lane: deploy readback, waiting on DNS propagation- Fast path found: batched repo scan + focused tests- Verification: lint pass, unit pass, live smoke pass

Failure Modes

  • More concurrency that creates conflicting edits.
  • Benchmarking the tool instead of the task.
  • Treating "fast" as done before correctness is proven.
  • Forgetting to poll running sessions.
  • Hiding skipped checks behind a success summary.

來源與署名

來源:affaan-m/ECC位於pi/core/skills/parallel-execution-optimizer提交ef648e0

授權條款: MIT

內容歸原作者所有。SourceWeft 從公開儲存庫中收錄這些內容。

檢舉或申請下架