ワンクリックで
forge-subagent
Use when executing plans through specialized subagents with evidence-gated review loops
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Use when executing plans through specialized subagents with evidence-gated review loops
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Use when work needs an explicit delivery contract, iterative repair, bounded autonomy, or resume-safe state
Use when a user asks to continue, resume, pick up prior loop work, or inspect previous loop state
Use when work needs codebase orientation, impact analysis, existing-pattern discovery, or risk scouting before planning or implementation
Use when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always
Use when implementation direction depends on unresolved product/design choices, multiple viable approaches, or owner approval on a design.
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes
| name | forge:subagent |
| hidden | true |
| description | Use when executing plans through specialized subagents with evidence-gated review loops |
Use fresh subagents to execute bounded tasks while Forge keeps the plan, state, and quality gates. Each subagent should receive a self-contained prompt and return a structured status.
Core principle: specialized subagent + bounded prompt + evidence-gated review = faster and safer delivery than context-heavy improvisation.
Use forge:subagent when:
Do not use it for one-line obvious fixes, or before the task boundary is clear.
Prefer specialized agents over general.
| Need | Preferred subagent |
|---|---|
| Root-cause analysis | Detective |
| TDD, regression, command-based verification | Tester |
| Bounded implementation or small refactor | Builder |
| Correctness / maintainability review | Reviewer |
| Security review | Guard |
| Schema / migration / query work | DBA |
| Performance analysis | Perf |
| Build / runtime / release concerns | Ops |
| No specialized fit | general |
Use general only when no specialized agent cleanly matches the work.
| Complexity | Controller action |
|---|---|
trivial | edit directly, run focused verification, record reason |
standard | dispatch one specialized subagent, then targeted review |
complex | dispatch specialized implementer, spec review, code-quality review, and re-review loop as needed |
Treat cross-module contracts, schema changes, security-sensitive work, and user-facing
flows as complex unless evidence proves otherwise.
Rule of thumb: parallelize analysis, serialize implementation.
Forge remains responsible for:
punchcardforge-checkThe task tool is not your task tracker. Use punchcard for T1/T1.1 work-items.
Every dispatched subagent prompt should contain:
Status, result, evidence, risks, next recommendationforge:tdd"Do not make the subagent discover the plan or intent from scratch if you already know it.
punchcard.forge-event event="subagent.run.started" with run_id or TID, agent, and a short task label.Status.forge-event event="subagent.run.completed" with status, agent, and concise risk/result metadata.- [ ] checkbox to - [x] and
append a line to the plan's ## Execution Progress section (see forge:plan's
"Living Plan Document" contract). The line MUST include: commit SHA, verify
verdict, ISO-8601 timestamp. If the task is iterating on a verify failure, leave
the checkbox - [ ] and append an iteration-N line to ## Loop Trace instead.Skipping the writeback is a false completion — the task is not "done" until the plan document reflects the verify-pass state.
Subagents must report one of:
DONEDONE_WITH_CONCERNSNEEDS_CONTEXTBLOCKEDDONEDONE_WITH_CONCERNSNEEDS_CONTEXTBLOCKEDforge:askNever force the same blocked subagent to retry with the same prompt.
Do not log full child prompts or large child output in forge-event; keep detailed state in forge-check, plan trace, or the subagent result.
Must use skill("forge:review") after every implementation task. Self-review is NOT sufficient.
Reviewer subagent)After implementation, dispatch a Reviewer subagent (via skill("forge:review") skill) to check:
fail or unverifiable item sends the task back for repairOnce the spec gate passes, the reviewer also checks:
If review finds issues, re-dispatch the implementer with exact failing claims and then re-review. Do not move on with open review findings.
Guard subagent)If the work touches auth, payment, PII, secrets, or access control, also dispatch a Guard subagent for security audit.
Subagent success does not equal task completion.
skill("forge:review") (Reviewer) checks code qualityskill("forge:verify") remains the final pass/fail authority for delivery claimsWhen edit attempts fail due to context mismatch, use this order:
Do not repeat the same failed edit pattern more than twice.
Use the OpenCode task tool exactly as supported:
task(
description: <3-5 word summary>,
prompt: <full prompt text>,
subagent_type: <agent name>,
task_id: <optional existing subagent session id starting with ses>,
background: <optional true/false>
)
background only for truly independent long-running worktask_id is an OpenCode session id, not a UUID and not a punchcard TID.
task_id entirely. Never invent one.task_id / session id returned by a previous
successful task result. Valid values always start with ses (e.g. ses_...).xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx) are invalid and will
fail with Expected a string starting with "ses".Never:
general when a specialized subagent fitstask with punchcardForge is the lead. Subagents are the team.
Delegate execution aggressively, but delegate with explicit boundaries, explicit evidence requirements, and explicit review gates.