/forge:fg-runfrom forge
Runs a refined forge plan through the active host's execution adapter, with priority-sorted plan selection and re-run warnings. Use for 'forge run' or 'forge execute'.
Ships in forge. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
The second turn of the forge loop. It takes the .forge/plan.md that fg-ask refined and applies it through the active host's execution adapter. Claude Code uses a Dynamic Workflow; Codex uses bounded collaboration/subagent calls. The shared selection, state, integration, and verification rules below do not change by host.
Host contract: read ../../core/HOST.md, ../../core/EXECUTION.md, and the matching ../../hosts/<host>/execution.md before delegating. Delegation depends on the host's spawn_parallel capability (and spawn_role for project agent cards); the matching execution adapter also owns the concrete launch, blocking-collect, and cancellation tool names and says which resumable handle or handles it returns. The shared procedure below names only those host-neutral operations. If the host is unknown or delegation is unavailable, execute serially while preserving every state transition and verification gate.
Language: This skill file is authored in English, but you MUST write every message shown to the user — questions, menus, status/next-step lines, and handoff text — in the user's language (detect it from the user's own messages), never mirroring this file's English. All documents this skill generates for the user's project (plan, run notes, retros, CONTEXT.md entries, ADRs, handoff messages) are written in the user's language. Section headings defined in the format docs are canonical English names — when writing a document, render headings in the user's language; consumers match sections by meaning and position, not exact strings.
Explaining forge: forge's vocabulary is not the user's — verified: failed, unsealed tail, a pillar or gate name means nothing unread. Always, never gated on eco: gloss a forge-specific term on first use in a message (a few words, not a paragraph), put the purpose before the mechanism, and lead with the answer, closing on what it means for the user. A gloss is not filler — with eco on, ECO.md's terse rules govern form (length, padding) while these govern vocabulary, so terseness never deletes a gloss.
Evidence and candor: every claim you make about code, state, or results — in a message or in a document you write (plan, run notes, retro, ADR) — carries its evidence in the same sentence (a file:line, a command and its output) or a label: Measured (you checked it this session), Inferred (reasoned from what you checked), Guess (a prediction or an unseen cause), rendered in the user's language. A label is not a license to skip a check — if a cheap check would settle it, run it; never hand the user a check you could run. Agreement is not the default: when asked whether to do something, invited to add scope, or shown an approach, give your real judgment first — the strongest objection, and "don't do it" when that is true. Change a recommendation only for a new fact or argument, never for repetition; the decision stays the user's — state the objection once, then follow their call without re-arguing or silently deviating. Output a deterministic script printed is already measured and needs no label.
Forge root: every .forge/... path below is relative to the resolved forge root — .forge/ on the default branch, .forge/branch/<branch>/ (git-tracked) on any other branch. Resolve it per FORGE-ROOT.md in this directory before reading or writing state (ADR-0011).
.forge/plan.md is the "source of truth." This skill enforces that source of truth through a workflow, and records where the plan and the actual results diverged in .forge/run.md. That note becomes the retro input when fg-done seals the task. The point is not to touch the plan itself again, but to run it as planned and record the divergences.
A workflow spins up many subagents, so it burns a lot of tokens. Running the same plan twice by mistake is costly and has side effects (duplicate commits, duplicate migrations, etc.). So before entering execution, check the state first, and when the backlog holds several tasks, the user picks what to run.
1) Check the active slot. If .forge/plan.md (the active slot) already exists, there is a task in progress — skip the backlog and go straight to step 4 below (only one task is active at a time). But first look for .forge/running.md: if it exists and run.md does not, the plan reached its in-flight launch boundary (delegation may have started, but no result was collected) — take step 4a, never the normal start, because "plan.md with no run.md" is ambiguous on its own and re-running here is exactly the duplicate execution this guard exists to prevent. If any .forge/executed/*/STATUS.md carries verified: failed while the slot is occupied, note it in one line — its recovery waits until the slot frees (see step 5). Step 4 first separates an interrupted UAT (verification-only resume, no re-execution) from a genuine re-run before doing anything destructive.
2) If the active slot is empty, FIRST check for a parked failure, THEN scan the backlog. Before counting backlog candidates, scan .forge/executed/*/STATUS.md for verified: failed — a parked task whose UAT failed and is awaiting repair (fg-status/fg-done route such tasks here, and fg-run is the only stage that can recover them). If one or more exists, surface it as the top recovery candidate ahead of any new backlog work — a known-broken task shouldn't be stranded while new work starts. Offer to recover it now via the unpark procedure in step 5 (unpark → step 4's verified: failed branch → fix-and-re-run, or re-grill via fg-ask). Only when there is no failed parked task, or the user explicitly declines recovery to start something else, proceed to the backlog scan. Then gather unfinished candidates from .forge/backlog/*.md (= plans with no matching slug seal in .forge/done/ — a seal is a done/<date-slug>/STATUS.md marker with status: done, written when fg-done archives the task). Before presenting anything, give the user a one-line status summary derived from the file layout: "done X (from done/*/STATUS.md with status: done) · awaiting done Y (executed/, status: executed) · unexecuted Z (backlog/)" — so they see at a glance what has finished and what remains. Read each STATUS.md's status field to confirm the count (done = done/*/STATUS.md at status: done). Then, depending on the candidate count:
<!-- priority: high|medium|low --> marker (see PLAN-FORMAT.md) and order them high → medium → low; a plan with no marker is treated as medium; ties within the same priority use numeric part: N/M order, then slug alphabetical. Show each unfinished plan as #<task> [<priority>] <title> (stable task: number, or #—; include the one-line goal + slice count), with "Run all (N sequential)" last. The selection UI depends on count because AskUserQuestion accepts at most four options:
structured_choice capability; the plan options plus the final "Run all" option total at most four.all — Run all (N sequential), and ask the user to type a stable task number, slug, list number, or all. Do not truncate candidates to fit the dialog.
This is ordering only — there is no auto-selection; the user still picks. A direct reference such as "run #7" matches the plans' task: markers. The #<task> number is a stable identifier for selection, not the sort key. Keep the selection in conversation, outside the workflow.Part-plans (split tasks). If plans carry a <!-- part: N/M --> marker (a big task fg-ask split into an ordered series — see PLAN-FORMAT.md), append (part N/M) to their label and keep them in sequence order (ordered by the numeric N in their part: N/M markers — slug alphabetical misorders 10+ parts). Recommend completing them one at a time, in order, each as its own full execute → done loop. This is a soft order — do not block a later part because an earlier one isn't sealed; the user may still pick any item.
3) Promotion and ADR check. Move (promote) the chosen backlog file to .forge/plan.md — from this point it is in the normal starting state of "active plan present, no run," and joins the main body below. Right before starting, check that each ADR the plan's "Source of truth" cites (adr/<id>-*, any ID format in ADR-FORMAT.md) actually exists under the read overlay — the resolved root's adr/ plus, on a non-default branch, the top-level .forge/adr/ base (FORGE-ROOT.md, "Read overlay for permanent grilling fuel"; never retired/), so a branch plan citing a default-branch ADR is not falsely stale — if not, it is a stale-plan signal, so warn and ask once: "shall I supplement it via fg-ask, or proceed as is?" (this does not block). Then lint the promoted plan — bash "${PLUGIN_ROOT:-${CLAUDE_PLUGIN_ROOT}}/scripts/forge-plan-lint.sh" <plan> (no bash → node …/forge-plan-lint.js <plan>), which checks PLAN-FORMAT.md's language-neutral structure (slug, slices, depends, marker values, the fix-forward eval marker). Exit 1 blocks the launch: show the ERROR lines and do not build the workflow. fg-run does not edit the plan (it is fg-ask's), so the fix goes through fg-ask refining this active plan (allowed — there is no run.md yet), then fg-run again. Exit 0 with WARN lines → show them in one line and continue. Exit 2 (unreadable) → stop and report. Under an unattended drive a lint error is a human-needed wall (../fg-next/ALL-MODE.md, ../fg-loop/SKILL.md §4). Then run the plan's DoD commands once to take a DoD baseline — the pre-state at the moment execution starts. If it disagrees with the pre-state the plan recorded (fg-ask ran the same commands at authoring time — see PLAN-FORMAT.md's runnable-DoD rule), warn in one line and proceed: do not block, because another session may legitimately have done part of the work already (the same non-blocking discipline as the ADR check). A forward check that already passes here is the thing to look at before building the workflow.
4) Re-run guard — but first, the verification-resume check. If .forge/run.md already exists, the plan has run once. Before treating this as a re-run, read STATUS verified:, because the two cases need opposite handling:
verified: pending or missing → the run finished but its handoff UAT was never completed (e.g. the session ended before verification). This is not a re-run — take the verification-only resume: read plan.md/run.md/STATUS.md, run the UAT against the plan's goal (see "Verify before handing off (UAT)"), write the outcome into STATUS verified:. Then branch on that outcome: a sealable result (yes/skipped/n/a) hands off to fg-done; a failed result stops here and routes to fix-and-re-run or re-grill (it must never reach fg-done). Do not rebuild or re-execute the workflow during the resume itself — no new subagents, no duplicate commits/migrations/side effects. Close with the handoff table for whichever outcome occurred (see "Early-exit handoffs" below).verified: failed → the UAT already ran and found the result broken. This is not a confirmation re-run: either apply a fix and then deliberately re-run (a genuine re-run — write a fresh run.md and re-verify), or re-grill via fg-ask to rework the plan. Do not silently re-execute, and do not treat it as an interrupted UAT to merely re-confirm. Close with the handoff table naming that route (see "Early-exit handoffs" below).verified: is a sealable value (yes/skipped/n/a) → the run was already verified, so this is a genuine duplicate-run request. Announce the duplicate run and get user confirmation. Distinguish whether the user wants to "continue/retry" or merely wants to see the results. Do not overwrite without confirmation. However, if this is a re-run after plan.md was updated through an fg-ask re-grilling, this warning is the normal path — once the user approves, proceed with the updated plan and write a fresh run.md.4a) In-flight resume — running.md present, run.md absent. The in-flight marker .forge/running.md is written by §2 immediately before launch and deleted by §4 right after run.md lands; if it is still there without a run.md, a previous turn (or session) reached the launch boundary and never collected a durable result. This is not a normal start and not a re-run — nothing may be rebuilt silently. Read RECOVERY.md and follow its step 4a: it owns the slug match, the handle collection order (running / completed / uncollectable), the rebuild confirmation, and the cancellation procedure. Rationale: ADR 260909-150614.
5) Failed parked-task recovery (unpark). fg-run is the single owner of returning a failed task to execution — fg-done blocks failed, and fg-run otherwise reaches only the active slot/backlog, never executed/. So if a parked .forge/executed/<slug>/STATUS.md carries verified: failed, read RECOVERY.md and follow its step 5 before working on it: it owns the slot-free precondition, the unpark move, and the blocked-unpark report.
Early-exit handoffs. Every branch that ends the turn without handing off to the seal closes by rendering the handoff table (shape defined once in ../fg-next/HANDOFF.md), in statement form — never an AskUserQuestion (ADR-0015). The step-2 selection of a backlog task (2+ candidates) is not a handoff and keeps its menu. For the 0-candidates case, nothing is in progress: Next step is fg-ask and Alternative is omitted. For every other early exit — the verification-only resume, verified: failed, an in-flight wait or declined rebuild, a blocked unpark, a cancelled duplicate run — read RECOVERY.md's "Early-exit handoffs" for the per-branch cells.
fg-run start
│
▼
Active slot (.forge/plan.md) present?
│ yes ──▶ run.md present?
│ │ no ──▶ running.md present? (in-flight marker, step 4a)
│ │ │ no ──▶ Normal start: build the workflow
│ │ │ yes ──▶ marker slug matches plan slug?
│ │ │ no ──▶ report + delete orphan marker ──▶ normal start
│ │ │ yes ──▶ adapter blocking-collects recorded handle(s), in order:
│ │ • running ──▶ wait ──▶ §3 onward
│ │ • completed ──▶ collect ──▶ §3 onward
│ │ • unknown/uncollectable/error ──▶ show age + warn it may still run elsewhere
│ │ ├─ explicit rebuild ──▶ delete marker, normal start
│ │ ├─ explicit cancel ──▶ record failed run + STATUS, delete marker, failed route
│ │ └─ decline/young marker ──▶ wait/fg-status (handoff table)
│ │ yes ──▶ read STATUS verified: (re-run guard, step 4)
│ • pending/missing ──▶ Verification-only resume (run UAT, set verified, NO re-execution)
│ │ └─ UAT outcome: sealable (yes/skipped/n/a) ──▶ hand off to fg-done
│ │ failed ──▶ fix-and-re-run / re-grill (never fg-done)
│ • failed ──▶ fix-and-re-run, or re-grill via fg-ask (no silent re-exec)
│ • sealable (yes/skipped/n/a) ──▶ Duplicate-run warning
│ └─ approved ──▶ build workflow │ cancel ──▶ stop, point to fg-ask
│ no ──▶ executed/ has a verified: failed task? (step 2, before backlog)
│ │ yes ──▶ Unpark to active slot ──▶ step 4 failed branch (fix-and-re-run / re-grill)
│ │ no (or user declines) ──▶ Scan .forge/backlog/ → candidate count:
│ • 0 ──▶ stop, point to fg-ask
│ • 1 ──▶ promote backlog→plan.md (+ verify ADR exists) ──▶ build workflow
│ • 2–3 ──▶ AskUserQuestion (plans + final Run all, ≤4 options)
│ • 4+ ──▶ numbered text list (task/slug/list number/all)
│ └─ single choice ──▶ build workflow │ Run all ──▶ Run-all procedure (RUN-ALL.md)
Right before starting, if .forge/retro/ exists, pick only the most recent 3–5 retros from the same area as this plan's slug (overlapping slug stem/domain) and skim their "Do differently next time" and "Divergences" (same selection rule as fg-ask — do not read them all) — so the same traps (e.g. "this migration breaks if run in parallel") are folded into slice decomposition, wave layout, and cost estimation up front. If there are no relevant retros, skip this. Retros are only a reference for building the workflow, not the source of truth for cross-verification (the source of truth is plan/CONTEXT.md/ADR, unchanged — see section 3 below).
Prompt Claude to build a Dynamic Workflow. Put the workflow keyword in the prompt, or raise effort to ultracode. Do not improvise the tasks to run — the "Work slices" list in .forge/plan.md is the primary unit of work (format: PLAN-FORMAT.md). It is fine for the workflow to split slices finer for execution convenience, but it must not drop a slice or trespass on the plan's "Non-goals." Where a dependency is noted (depends: S1), bundle into a serial wave; where there is none, bundle as parallelizable, and write the orchestration script accordingly. If the slices section is missing entirely (only a goal, no work decomposition), do not invent one and run it — point to fg-ask.
TDD mode. If the active plan carries <!-- tdd: on --> (set by fg-ask from .forge/config.json; see PLAN-FORMAT.md), compose the workflow test-first: for each work slice, write a failing test that pins its completion criterion before the implementation, then implement until that test passes — and treat "the slice's test exists and passes" as part of its completion criterion in §3. Describe this test-first discipline in the orchestration script yourself; if a TDD capability is available (e.g. a superpowers:test-driven-development skill) you may lean on it, but never hard-depend on one. If tdd is off or absent, run normally — no behavior change.
Eco mode (delegated-agent efficiency). Read eco from the top-level .forge/config.json (a global exemption — never the branch root; treat as off if the file or key is absent). If true, two behaviors activate for all workflow/execution subagents: (1) model cap — cap the subagent model at sonnet (e.g. model: sonnet on agent calls): only ever lowers, never raises; explicit user model instruction wins; (2) Eco code-simplicity injection — prepend the full contents of ../fg-config/ECO.md to each subagent's prompt. Together these tier the loop as "strong = main session (design + grilling), efficient = delegated execution." Beyond the subagents, when eco is true the main session running this skill also adopts ECO.md's output discipline for its own execution/reporting/handoff prose (behavior 4 in fg-config) — this is the only carrier on the direct-execution path (a small task handled here without a workflow), where there are no subagents to receive the injection. Toggle via the fg-config utility; rationale in ADR-0014 (eco subagent model tiering). If eco is false or absent, no behavior change.
Domain agents (project .claude/agents/). If the project has domain agents under .claude/agents/ (e.g. produced by the fg-agents utility), the workflow may run a slice through the matching one instead of the default subagent: pass agentType: '<role>' on the agent() call, picking the role whose card description ("when to use") fits the slice. This is graceful and optional — if there are no domain agents, run exactly as before (default workflow subagents; no behavior change); if a project would clearly benefit from a specialized role and has none, you may note in one line that fg-agents can generate them (then the session must restart before they're dispatchable — fact 1 below) — a pointer, never a dependency. Two hard facts (ADR-0024): (1) only agents loaded at session start are dispatchable — .claude/agents/ is read once at startup, so a card created mid-session (e.g. by fg-agents just now) is NOT pickable until the session restarts; build against the agents present at this session's start, and if a needed card was just generated, tell the user to restart before it can be used. (2) the agents are the user project's, not forge's — fg-run only opens the call path, it does not define or require them (ADR-0013 non-conflict). Eco interaction: when eco is on, an agentType call is still capped at sonnet and still gets the ECO.md prepend like any delegated subagent — except when the role card declares its own model:, which is an explicit user choice and wins (eco only ever lowers). The existing script-approval gate (§2) is the safety net against dispatching an unrelated agent — the user sees "built the workflow with these agents, approve?".
Once the orchestration script is ready, get user approval first. After approval, run it as parallel delegated work while this session keeps responding and receives progress. Use the matching host adapter's progress surface when it has one.
Immediately before the first launch call, write the in-flight marker .forge/running.md (the active slot, next to plan.md), with workflow: pending; as launch calls return resumable handles, replace pending with the complete handle list accumulated so far before launching more work or doing anything else:
<!-- forge-running: {slug} -->
workflow: {`pending`, then the host's resumable handle(s) when available; Claude records the workflow Task ID}
started: {epoch seconds}
session: {this session's id}
Writing it before launch closes the crash window between starting side effects and recording their identity. Until run.md is written, delegated work may outlive this turn and otherwise leave the state on disk as "plan.md only", indistinguishable from a promoted-but-unrun plan; every reporter would then say "next: fg-run" and a re-entry would rebuild the workflow (ADR 260909-150614). The marker is what step 4a, fg-status's state machine, the session-start hook, fg-doctor (A10), fg-drop, and the sealing paths read instead.
Then do not end the turn — use the adapter's blocking-collect operation and wait here. Repeat collection as the adapter requires until the delegated work reports completion, then continue straight into §3 in the same turn. The marker is the safety net for the cases this cannot cover — the model yielding anyway, the session ending, or a host without a resumable handle — not a license to hand the wait to the user.
.forge/plan.md, CONTEXT.md, and the ADRs in .forge/adr/ are the source of truth. Pass the plan's Related ADRs into each workflow subagent's prompt as paths, resolved through the read overlay (FORGE-ROOT.md — a branch plan may cite a top-level ADR), so subagents build and judge against the decisions themselves rather than only the plan's paraphrase of them; none passes nothing. The workflow cross-verifies its output against this source of truth — it judges each slice's "completion criterion" against the actual output for satisfaction, rather than stopping at "it ran." This plan-verification always runs — it answers "did we build what the plan said," not "is the built code good." When the plan is in TDD mode (tdd: on), each slice's completion judgment additionally requires that its test exists and passes (see §1).
Conditional code review (quality, not just spec). For changes touching risky areas (auth, data mutations, public API/contracts, migrations) or sizable ones, add a review phase after implementation (before recording run.md); skip trivial/low-risk changes (same restraint as retro-skip). Compose it with the workflow's own adversarial-verify subagents (core Agent/Workflow, no external hard-dependency); fix real findings in-run and re-verify, and record any remaining critical findings in run.md as a divergence (it runs autonomously — no human input mid-run — surfacing at the handoff for the seal's retro / re-grilling). Rationale + full procedure: .forge/adr/0007-fg-run-conditional-code-review.md.
When execution finishes, note "the divergences between plan and reality" in .forge/run.md. Write down what went as planned, what missed, the on-the-spot decisions made along the way, and where it got stuck. This is the raw material for the retro fg-done decides at seal.
Record one line per work slice. Alongside the prose, run.md MUST carry a per-slice result line keyed to the plan's ## Work slices — the slice id, whether it landed, and the divergence in a few words:
- S1 {what it did} — ✅ as planned
- S2 {what it did} — ⚠ {the divergence, a few words}
This is not an eco-only concern: record it whether or not eco is on. It is the material guarantee for anything downstream that reports per-slice results — fg-done's seal summary already instructs "result per slice" (ADR-0032), and eco's summary table renders the slice rows (../fg-config/ECO.md), but a later seal may happen in a different session where free prose is all that remains. Without these lines a reader would have to invent results, which is exactly the "instruction prose out of step with the actual contract" failure a retro already caught (.forge/retro/2026-07-06-fg-done-seal-summary.md). Keep the lines short — the prose below them carries the reasoning.
Carry the failure history. On a fix-and-re-run, the fresh run.md starts with the previous run.md's ## Failed attempts section unchanged (see failed under "Verify before handing off"); never drop it, even when the new run passes.
Record handed-over rulings. When an unattended drive (fg-next all, fg-loop) delegated this run and handed over the soft decisions it took for the task, write them as one line each under run.md's ## Rulings section (shape and scope: ../fg-next/DRIVE.md Part 4). A run started by a human has no rulings section.
Persist future-work candidates. When the run identifies concrete work left for another task, append marked candidates as its final section using ../fg-learn/FOLLOWUPS-FORMAT.md. Reuse existing candidate IDs; do not invent work to fill a section. Every seal, including simple mode, collects these into the persistent ledger.
Also record each DoD item's baseline → after values. The baseline taken at promotion (step 3) paired with the value after execution is what makes the UAT's evidence checkable rather than asserted — 2 → 1 says more than 1, and ADR-0009's seal gate rests on exactly that evidence. One line per DoD item, and for an item that was already passing at baseline, say so (an unchanged regression guard is the expected result, not a missing check).
Right after writing run.md, delete .forge/running.md — the in-flight marker's job ends where the durable result begins; a leftover marker next to a run.md is what fg-doctor A10 flags. Cancellation and abort are not exceptions that delete only the marker: write run.md first with the stopped slice and observed side effects, write the companion STATUS below with verified: failed (aborted — <reason>), then delete the marker and take the failed branch. Then write a companion STATUS.md (in the user's language) to mark an ordinary completed run as executed — it travels alongside the plan/run files as a status marker, not a second ledger (the source of truth for state is still file location). In the single-task path, write it to .forge/STATUS.md (the active slot, next to plan.md/run.md). Content:
# STATUS — {title}
slug: {slug}
status: executed
executed: {YYYY-MM-DD}
verified: pending
retro: pending
The retro: field tracks the retro state of this task: pending at execution time, later either the retro path (.forge/retro/YYMMDD-HHMMSS-<slug>.md, filled by fg-done when sealing a retro'd task) or skipped (<reason>) when fg-done's retro judgment found nothing to learn (../fg-done/SKILL.md step 0b). fg-done later flips status to done and archives plan/run/STATUS together, accepting either a retro file or retro: skipped as satisfying its no-seal-without-retro guard. (The "Run all" path writes this STATUS to the active slot during execution+UAT too, then moves it into the per-task executed/<slug>/ folder only on a sealable outcome — see that section.)
Flow: build the workflow → approve the script → write running.md with workflow: pending → launch parallel execution → update workflow: with each returned resumable handle (Claude: workflow Task ID) → blocking-collect in this turn → cross-verify against the plan → record .forge/run.md → delete running.md → write .forge/STATUS.md (status: executed) → run the handoff UAT and set verified: (see "Verify before handing off") → only then point to the seal (fg-done)
If the user picks "Run all" from the selection menu, read RUN-ALL.md (skill-relative ./RUN-ALL.md) and follow it — the execute-only batch procedure: confirm/freeze the order → per-task sequential execute → UAT → park sealable into executed/ / leave failed in the active slot → fail-stop → batch handoff. It is split into that file — loaded only when "Run all" is actually chosen — for token efficiency on the common path; behavior is unchanged from when it lived inline. Run all is execute-only (it stops at the retro, parking each task in executed/); for the momentum superset that also drives verify → retro-skip → seal → promote-next, see fg-next all (../fg-next/SKILL.md / ADR-0010).
run.md — that conflicts with the re-run guard. Determine the split per the split rules in PLAN-FORMAT.md./command (slash command) for reuse..forge/config.json eco is on, workflow/execution subagents are capped at sonnet and receive Eco code-simplicity instructions (see §1) — it never changes this session's model, never raises a tier, and yields to an explicit user model instruction.After execution and before pointing to the seal, verify the result actually works — plan-verification (§3) confirmed "we built what the plan said"; this confirms "it actually achieves the goal." The Dynamic Workflow can't take human input mid-run, but this handoff is conversational, so do the UAT here: against the plan's goal / Definition of Done, show what to check and ask the human to confirm it works (or report what's off). Record the outcome in the active-slot .forge/STATUS.md verified: (the "Run all" path also writes to the active-slot STATUS during UAT, then moves plan/run/STATUS to .forge/executed/<slug>/ only on a sealable outcome — see that section):
Drive the named journey when a verification skill exists. If the plan's Definition of Done names a feature-map entry (verify-<app>: features/<feature>.md, PLAN-FORMAT.md) and .claude/skills/verify-<app>/ exists (built by fg-verify), the UAT reads that skill's files and follows them — Launch → Doctor → Drive the named entry → Evidence → Cleanup — instead of asking the human to check by hand. Reading the files, not invoking the skill, is what makes it usable in the same session it was built; a missing directory means no verification skill, so fall back to the ordinary UAT and say so. Evidence goes to a fresh per-attempt directory under .forge/verify/ — the layout and the self-ignore are defined once in FORGE-ROOT.md (<run> = this task's slug). Record the outcome by where the drive stopped, the discriminator being whether the skill's Doctor passed:
verified: pending and report the unmet prerequisite with the attempt's evidence path. It is never failed: nothing was learned about the work, and a failed would send a fix-and-re-run (or fg-loop's in-place repair) to change code that may be fine. In an unattended drive this is the existing unverifiable-UAT wall.failed (<what was observed>). Do not guess "stale map": the UAT cannot tell a broken app from a stale map. If the cause turns out to be the map, the fix-and-re-run updates that feature file — in a human-attended run only; an unattended repair never edits a feature file to make a journey pass.yes (verify-<app>: <feature> → <evidence dir>).Never weaken a journey or switch to a more convenient entry point to make it pass. Unattended drives (fg-next all, fg-loop) may take this path because the journey was named by the human at grilling and the skill drives an instance it started itself — but two cases are not theirs to decide, and both leave verified: pending (the unverifiable-UAT wall): the Doctor needs a human (above), or the named journey's side effects reach outside the instance this run started (a real message sent, a real payment, a shared or production system — the feature file's Gotchas or its side-effect proof says so). A plan without a feature-map DoD item runs the ordinary UAT unchanged (ADR 261025-090138).
Sealable outcomes:
yes (<evidence>) — confirmed working, carrying a one-line piece of evidence for how it was confirmed — the command run / the output observed (e.g. yes (npm test → 42 passing)), the same shape as the n/a/skipped reason. Don't lean on "the human said so" alone; record what was actually checked. In TDD mode the passing slice tests are that one-line evidence (e.g. yes (slice tests green)) — no separate manual check needed. Keep it to one line — lightweight evidence, not a full command-output dump.skipped (<reason>) — verifiable but the user chose to skip (a deliberate, auditable waiver).n/a (<reason>) — nothing runnable to verify (e.g. a docs-only change — many of forge's own tasks).Non-sealing outcome:
failed (<reason>) — the UAT ran and the result does not achieve the goal. This is distinct from pending (which means the UAT never happened): failed records that verification was done and the work is broken. Write it so the state is durable and recovery is unambiguous — do not leave it as pending (that would look like an interrupted handoff) and do not paper over it with a skipped waiver. A failed task does not seal; route it to a fix-in-follow-up (then re-run → fresh run.md → re-verify) or re-grill via fg-ask. A known-failed result has no waiver that seals it — do not convert it to skipped to slip it through. It becomes sealable only when a fresh fix-and-re-run re-verifies it to yes or n/a. Keep the failure history across re-runs (the idea is adapted from iha2/superlite's per-fix notes and its "a tier that fails twice escalates" rule): every failed outcome appends one line to run.md's ## Failed attempts section (keep this heading literally in English — the seal script reads it mechanically as a retro signal) — - <round>: <what failed> / <fix that was tried, or none yet> — and a fix-and-re-run that writes a fresh run.md carries that section over verbatim before adding its own line, so the record survives the rewrite. STATUS carries the count as fix-rounds: N — the number of fix-and-re-runs whose UAT came back failed (absent or 0 after the first failure; 1 after the first failed fix; and so on). It is a record, never a gate: sealing still depends only on verified: (ADR-0009), and fg-done archives the history with run.md as retro material. Advisory, not a hard rule: if the failure revealed a missing regression guard, consider promoting an eval (a persistent test) at retro time — PLAN-FORMAT.md's fix-forward eval rule binds only newly authored fix-forward plans, not this re-run of the same plan (ADR 260906-171420). Also advisory: when the cause is unclear, run fg-debug before fixing; it classifies the repro as persistent or one-off, cleans diagnostic artifacts, and returns the diagnosis package to this same active task's fix-and-re-run path rather than creating a new plan or using fg-quick.fg-done will not seal unless verified: is one of the sealable outcomes (yes/skipped/n/a) — pending and failed both block (no-seal-without-verification guard).
When execution finishes, render the handoff table — its shape is defined once in ../fg-next/HANDOFF.md (or ${PLUGIN_ROOT:-${CLAUDE_PLUGIN_ROOT}}/skills/fg-next/HANDOFF.md); reference it, never restate the layout here. Render it in the user's language. Everything below is either a gate that must clear before you render it, or the material its cells carry.
0. Verify first (mandatory gate). Before pointing to the seal — i.e. before the table is rendered at all — complete the UAT above and record verified: (yes/skipped/n/a) in STATUS. Do not route to fg-done while verified: is still pending — the loop order is run → verify → done (the retro is decided inside the seal). Only once verified: is set do you proceed below.
Simple mode: auto-seal instead of the seal handoff (ADR 260905-212045). Read simple from the top-level .forge/config.json (the same global-exemption read as eco; treat as false if the file or key is absent). If true and the UAT above recorded a sealable verified: (yes/skipped/n/a): invoke fg-done in this same turn as an unattended seal: its retro judgment (../fg-done/SKILL.md step 0b) skips the retro or writes an auto retro log, and asks no promotion question — promotion is deferred to fg-learn's batch promotion (ADR 261024-191024; the same unattended family as fg-next all / fg-loop). It is a delegated seal — keep it terse, never the explicit-single-seal summary chapter (ADR-0032); report the seal in one line (the eco summary table still applies when eco is on), then render the handoff table pointing at the next task (fg-run picks up the backlog; fg-ask when the backlog is empty). The verification gate is untouched (ADR-0009): on verified: pending or failed nothing is auto-sealed — those branches run exactly as with simple off. The divergence cases below apply only when simple is false or absent.
Eco: the eco summary table replaces the recap, not the handoff table. If eco is true in the top-level .forge/config.json (the same read as §1), replace the what-just-happened material below with the single-task eco summary table — its shape is defined once in ../fg-config/ECO.md (section "eco summary table"); reference it, do not restate the layout here. Nothing that material conveys may be dropped in the fold: the verified: value goes in the header (ADR-0009 — it is what tells the reader whether this can be sealed), the plan's Goal into ▸ Request, and the per-slice results from run.md's slice lines (§4) into ▸ Done. The handoff table still follows it — how the two combine is HANDOFF.md's "Interaction with eco" (follow it; do not restate it here), which is what keeps the next step in the same place whether eco is on or off. Either way it stays statement form: no menu, no AskUserQuestion, no "shall I proceed?" — ADR-0015's 2026-06-15 amendment governs the tables exactly as it governed the prose. If eco is false or absent, the material below fills the handoff table unchanged.
What I just did — one line on what the workflow changed, and that the plan-vs-actual divergences were written to .forge/run.md.
Optional adversarial review (before the seal). As a one-line pointer below the table (a cell stays one line, and this is not a menu option), mention that if the user wants a hostile second look before sealing, they can run an adversarial review — fg-adversarial-review (outside the loop, never required): it assumes the result is wrong and hunts for evidence across six lenses, and any fix-needed finding becomes a fix-forward plan to run again. This is a one-line statement-form pointer, not a menu option (ADR-0015 amended 2026-06-15 — the fg-run handoff is now statement form), and fg-next all/fg-loop always skip it. See ADR-0018.
The next step (statement form — no menu, no question; ADR-0015 amended 2026-06-15). Like every other loop handoff, fg-run just states where things stand and stops — the table is text output, never an AskUserQuestion menu. (A menu re-triggered on the unchanged active-slot state and looped; statement form removes that whole failure mode — ADR-0015's 2026-06-15 amendment.) The next step is the seal — fg-done, which also decides the retro: it writes a retro log when the run left something to learn and asks once only if a CONTEXT/ADR/eval promotion clears the bar (ADR 261024-191024). The triggers are /forge:fg-done, plus fg-next (one-shot) or fg-next all (drives to the wall).
Then stop — do not ask "shall I proceed?" and do not auto-invoke fg-done (chaining is fg-next's job — ADR-0015).
Divergence shapes the Alternative cell. Read the plan-vs-actual divergence in run.md and take the first case that applies:
Next step stays the seal (its retro judgment will write a log — a ⚠ slice line is one of its signals), and Alternative is the re-grill recommendation (fg-ask before sealing): plan and actual too far apart can mean the next work needs a fresh starting point.Next step is the seal and Alternative is omitted. A plan's <!-- retro-hint: optional --> no longer changes this table; fg-done reads it as a hint in its no-signal judgment (PLAN-FORMAT.md).Repeated failure changes the recommendation, not the gate. A failed outcome never reaches the retro cases above — its table is in RECOVERY.md's early-exit handoffs. There, read STATUS fix-rounds: below 2, Next step is fix-and-re-run and Alternative is re-grilling; at fix-rounds ≥ 2 (two fixes have already failed) a third blind fix is the wrong default, so Next step becomes finding the cause with fg-debug — or re-grilling with fg-ask when the failures point at the plan itself — and another fix-and-re-run moves to Alternative. Nothing is blocked; the human still decides.
Under fg-next. fg-run cannot detect its caller, so it just states the next step and fg-next (as orchestrator) acts on it. fg-next all drives through automatically (seal with fg-done's unattended retro judgment, ADR-0010); one-shot fg-next runs the stated next step (one step, then hands back). For an odd job that crept in mid-run, point the user to handle it directly rather than cramming it into the workflow.
.forge/run.md — the note of plan-vs-actual divergences (retro input). Lazy creation..forge/STATUS.md (status: executed) right after run.md — a companion marker fg-done reads; fg-done later flips it to status: done and archives it with plan/run..forge/backlog/<slug>.md → .forge/plan.md. On "Run all" (procedure in RUN-ALL.md), creates per-task .forge/executed/<slug>/{plan,run,STATUS}.md (awaiting the seal)./command if the job recurs..forge/plan.md it reads as input (the plan is fg-ask's property).Format reference: when you need to handle permanent docs, read ${PLUGIN_ROOT:-${CLAUDE_PLUGIN_ROOT}}/skills/fg-ask/CONTEXT-FORMAT.md, ${PLUGIN_ROOT:-${CLAUDE_PLUGIN_ROOT}}/skills/fg-ask/ADR-FORMAT.md (plugin environment), or the same files at the skill-relative path ../fg-ask/ to match the format. The source of the format docs is the single fg-ask copy; this skill does not copy them itself.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
forge, plan-execution, workflow, task-runner, plan-management
npx claudepluginhub gyuha/forge --plugin forge25 skills in this plugin
/fg-adversarial-reviewOptional adversarial review between fg-run and the seal (fg-done) — a reviewer assumes the result is WRONG and hunts for evidence across six lenses (failure points, hidden assumptions, misread requirements, security/perf/data-loss, unexpected misuse, weak decisions), fanning out as parallel subagents; fix-needed findings become a fix-forward plan on your approval. Outside the loop, never a seal gate, always skipped in fg-next all / fg-loop. Use in contexts like 'adversarial review', '적대적 리뷰', '이 결과 공격적으로 검토', '허점 찾아줘', 'red team this'./fg-agendaA decision queue for foggy work — outside the forge loop. Settles the destination with you, grills breadth-first to surface what must be decided, and keeps it in .forge/agenda.md (destination · decided · open questions · fog · out of scope), resolving one question at a time via fg-ask until the way is clear, then deleting itself. The agent finds the decisions; you answer them. Use in contexts like 'forge agenda', '의제', '결정 대기열', '뭘 결정해야 하는지 정리해줘', '어디서 시작할지 모르겠다'./fg-agentsGenerates a project's domain agents — conversational grilling derives the recurring roles, then writes standard Claude Code subagent cards to .claude/agents/<role>.md (each `description` carrying a "when to use" so fg-run can dispatch a matching role as agentType). Cards load only at session start, so RESTART the session after generating them before fg-run can use them. On-demand utility outside the loop. Use in contexts like 'forge agents', '도메인 에이전트 만들어', '에이전트 팀 구성', 'create project agents', 'domain agents', 'agent roles'.Other plugins' skills for the same job