FORGE Execute Task
Execute one governed task with minimal context. A checkpoint is not complete until its review gates have run and outcomes are recorded.
Use When
- the user asks to start, build, implement, or continue governed work
- bounded FORGE tasks exist locally or in the configured tracker, or
forge-build routes here
Do Not Use When
- the repo needs
forge-bootstrap; the user only wants review/evaluation/planning; or the work cannot be bounded to one checkpoint
Default Reads
docs/forge/CONTEXT.md (if present), docs/forge/AI.md, the task index (TASKS.index.yaml, else TASKS.yaml or the configured tracker), exactly one selected task, and the files in its file_scope. Read other docs (TEAM, ARCHITECTURE, SETUP, checklists, EVALUATION) only when a step needs them.
Workflow
- Confirm branch safety, worktree state, and project-local prerequisites.
- Parse
AI.md for collaboration_mode, task_source, solo_branch_flow, execution_mode, repo_flavor, security_profile, and context profile.
- Select or claim exactly one task; read only that task's details.
- When memory docs exist, read
MEMORY.index.yaml + the relevant topic before the alignment check.
- Start with declared
file_scope; note why before any expansion.
- Check branch, team, architecture, contract, and security constraints.
- Implement the smallest safe change; run relevant checks.
- Run the review gates via
forge-review (critique always; security per surface/profile; evaluation full when EVALUATION.md exists, else recorded in-task). Record gates: critique: pass|fail · security: pass|n/a|escalated · evaluation: pass|handoff-required|fail.
- Record a memory entry only when a reusable lesson exists:
memory: entry|no-relevant-lesson|store-unavailable.
- Update task state and evidence.
- Commit per project policy (Conventional Commit, no AI attribution).
- Stop or continue per
execution_mode; requires_independent_review always stops.
forge_next_gate.py <task-file> (in <skill-root>/assets/scripts/) prints the next required gate.
Output — at each activation/resume read ../references/checkpoint-output.md once; this rule holds even if that read is skipped. Follow progress_policy (default compact): do NOT announce routine reads, edits, commands, checks, or tool/skill choices; host cadence is a heartbeat floor, not narration license. Emit one line per checkpoint (TASK-<id> complete|blocked|handoff-required | …), blockers state check+evidence+need, one terminal Done: … Refs: … Remaining: …. No per-task recaps.
Task sources — local: TASKS.index.yaml plus docs/forge/tasks/<id>.yaml, else TASKS.yaml. github/gitlab: issues are authoritative; local task files are planning snapshots. external: only the configured MCP, CLI, or human-provided reference.
Scope Rules
- Implement only the selected task; honor
file_scope and contract_files.
- If
application_docs: true, update only the human-facing docs triggered by the task.
- In team mode, claim before implementation and reconcile before state transitions.
- In solo governed mode, never work on or promote to
release_branch without human instruction.
Hard Stops
Stop when:
- task scope is unclear, or required FORGE docs, task source, auth, or operator identity are missing
- branch policy or task claim conflicts, or task state cannot be reconciled
- the task would exceed declared
file_scope without justified expansion
- an integration-boundary change lacks the relevant contract file, or another active task owns it
- architecture or security uncertainty is unresolved
- checks fail without a user-approved exception
- a review gate fails or records
escalated / handoff-required
- independent review is required and the same agent is being asked to complete it
- solo governed mode would merge or promote into
release_branch without human instruction
- commit history would include AI attribution or agent branding
Rationalizations To Reject
| Rationalization |
FORGE response |
| "This is small enough to skip task state." |
Small work still needs bounded scope and a checkpoint. |
| "I can touch nearby files while I am here." |
Only selected task scope is allowed. |
| "I will update docs after code works." |
Triggered docs and contracts move with the task. |
| "Gates can run at the end of the session." |
Gates run per checkpoint, before the commit. |
| "The scanner will catch it." |
Security uncertainty requires explicit review or escalation. |
Evidence Required
- selected task id/issue; changed files + scope-expansion notes; validation run or blocker
gates: outcomes for the checkpoint (critique, security, evaluation, memory)
- updated task source when state changes
- required docs/contracts/ADRs/XPDs when triggered; Conventional Commit (solo) or PR/MR-ready state (team)
On-demand references: ../references/execution-modes.md, ../references/team-mode.md, ../references/repo-flavors.md, ../references/application-docs.md.
1---2name: forge-execute-task3description: Execute one bounded FORGE task from repository-local governance docs. The primitive behind `forge-build`. Use when reading `docs/forge/` state, selecting the next incomplete task, enforcing task scope, implementing, running review gates, and stopping on ambiguity or failed gates.4---56# FORGE Execute Task78Execute one governed task with minimal context. A checkpoint is not complete until its review gates have run and outcomes are recorded.910## Use When1112- the user asks to start, build, implement, or continue governed work13- bounded FORGE tasks exist locally or in the configured tracker, or `forge-build` routes here1415## Do Not Use When1617- the repo needs `forge-bootstrap`; the user only wants review/evaluation/planning; or the work cannot be bounded to one checkpoint1819## Default Reads2021`docs/forge/CONTEXT.md` (if present), `docs/forge/AI.md`, the task index (`TASKS.index.yaml`, else `TASKS.yaml` or the configured tracker), exactly one selected task, and the files in its `file_scope`. Read other docs (TEAM, ARCHITECTURE, SETUP, checklists, EVALUATION) only when a step needs them.2223## Workflow24251. Confirm branch safety, worktree state, and project-local prerequisites.262. Parse `AI.md` for `collaboration_mode`, `task_source`, `solo_branch_flow`, `execution_mode`, `repo_flavor`, `security_profile`, and context profile.273. Select or claim exactly one task; read only that task's details.284. When memory docs exist, read `MEMORY.index.yaml` + the relevant topic before the alignment check.295. Start with declared `file_scope`; note why before any expansion.306. Check branch, team, architecture, contract, and security constraints.317. Implement the smallest safe change; run relevant checks.328. Run the review gates via `forge-review` (critique always; security per surface/profile; evaluation full when `EVALUATION.md` exists, else recorded in-task). Record `gates:` `critique: pass|fail` · `security: pass|n/a|escalated` · `evaluation: pass|handoff-required|fail`.339. Record a memory entry only when a reusable lesson exists: `memory: entry|no-relevant-lesson|store-unavailable`.3410. Update task state and evidence.3511. Commit per project policy (Conventional Commit, no AI attribution).3612. Stop or continue per `execution_mode`; `requires_independent_review` always stops.3738`forge_next_gate.py <task-file>` (in `<skill-root>/assets/scripts/`) prints the next required gate.3940Output — at each activation/resume read `../references/checkpoint-output.md` once; this rule holds even if that read is skipped. Follow `progress_policy` (default `compact`): do NOT announce routine reads, edits, commands, checks, or tool/skill choices; host cadence is a heartbeat floor, not narration license. Emit one line per checkpoint (`TASK-<id> complete|blocked|handoff-required | …`), blockers state check+evidence+need, one terminal `Done: … Refs: … Remaining: …`. No per-task recaps.4142Task sources — `local`: `TASKS.index.yaml` plus `docs/forge/tasks/<id>.yaml`, else `TASKS.yaml`. `github`/`gitlab`: issues are authoritative; local task files are planning snapshots. `external`: only the configured MCP, CLI, or human-provided reference.4344## Scope Rules4546- Implement only the selected task; honor `file_scope` and `contract_files`.47- If `application_docs: true`, update only the human-facing docs triggered by the task.48- In team mode, claim before implementation and reconcile before state transitions.49- In solo governed mode, never work on or promote to `release_branch` without human instruction.5051## Hard Stops5253Stop when:5455- task scope is unclear, or required FORGE docs, task source, auth, or operator identity are missing56- branch policy or task claim conflicts, or task state cannot be reconciled57- the task would exceed declared `file_scope` without justified expansion58- an integration-boundary change lacks the relevant contract file, or another active task owns it59- architecture or security uncertainty is unresolved60- checks fail without a user-approved exception61- a review gate fails or records `escalated` / `handoff-required`62- independent review is required and the same agent is being asked to complete it63- solo governed mode would merge or promote into `release_branch` without human instruction64- commit history would include AI attribution or agent branding6566## Rationalizations To Reject6768| Rationalization | FORGE response |69|---|---|70| "This is small enough to skip task state." | Small work still needs bounded scope and a checkpoint. |71| "I can touch nearby files while I am here." | Only selected task scope is allowed. |72| "I will update docs after code works." | Triggered docs and contracts move with the task. |73| "Gates can run at the end of the session." | Gates run per checkpoint, before the commit. |74| "The scanner will catch it." | Security uncertainty requires explicit review or escalation. |7576## Evidence Required7778- selected task id/issue; changed files + scope-expansion notes; validation run or blocker79- `gates:` outcomes for the checkpoint (critique, security, evaluation, memory)80- updated task source when state changes81- required docs/contracts/ADRs/XPDs when triggered; Conventional Commit (solo) or PR/MR-ready state (team)8283On-demand references: `../references/execution-modes.md`, `../references/team-mode.md`, `../references/repo-flavors.md`, `../references/application-docs.md`.