@garygentry/feature-forge 0.3.0 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/adapters/claude/.feature-forge-bundle.json +1 -1
- package/adapters/claude/agents/forge-verifier.md +1 -1
- package/adapters/claude/references/epic-manifest-schema.json +6 -1
- package/adapters/claude/references/forge-config-schema.json +1 -1
- package/adapters/claude/references/pipeline-state-schema.json +5 -3
- package/adapters/claude/references/shared-conventions.md +125 -12
- package/adapters/claude/references/stage-exit-protocol.md +358 -144
- package/adapters/claude/references/vendor-construct-inventory.md +1 -1
- package/adapters/claude/scripts/epic-manifest.py +459 -90
- package/adapters/claude/scripts/forge-bootstrap.py +57 -5
- package/adapters/claude/scripts/forge-session.py +4346 -201
- package/adapters/claude/scripts/validate-traceability.py +92 -6
- package/adapters/claude/skills/forge/SKILL.md +18 -11
- package/adapters/claude/skills/forge/references/pipeline-state-schema.json +5 -3
- package/adapters/claude/skills/forge/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge/references/stage-exit-protocol.md +358 -144
- package/adapters/claude/skills/forge-0-epic/SKILL.md +8 -3
- package/adapters/claude/skills/forge-0-epic/references/edit-mode.md +24 -24
- package/adapters/claude/skills/forge-0-epic/references/pipeline-state-schema.json +5 -3
- package/adapters/claude/skills/forge-0-epic/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-0-epic/references/stage-exit-protocol.md +358 -144
- package/adapters/claude/skills/forge-1-prd/SKILL.md +39 -11
- package/adapters/claude/skills/forge-1-prd/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-1-prd/references/stage-exit-protocol.md +358 -144
- package/adapters/claude/skills/forge-2-tech/SKILL.md +38 -10
- package/adapters/claude/skills/forge-2-tech/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-2-tech/references/stage-exit-protocol.md +358 -144
- package/adapters/claude/skills/forge-3-specs/SKILL.md +28 -9
- package/adapters/claude/skills/forge-3-specs/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-3-specs/references/spec-archetypes.md +9 -0
- package/adapters/claude/skills/forge-3-specs/references/stage-exit-protocol.md +358 -144
- package/adapters/claude/skills/forge-4-backlog/SKILL.md +39 -10
- package/adapters/claude/skills/forge-4-backlog/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-4-backlog/references/stage-exit-protocol.md +358 -144
- package/adapters/claude/skills/forge-5-loop/SKILL.md +65 -67
- package/adapters/claude/skills/forge-5-loop/references/agent-selection.md +116 -0
- package/adapters/claude/skills/forge-5-loop/references/result-reporting.md +70 -31
- package/adapters/claude/skills/forge-5-loop/references/runner-contract.md +18 -109
- package/adapters/claude/skills/forge-5-loop/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-5-loop/references/stage-exit-protocol.md +358 -144
- package/adapters/claude/skills/forge-6-docs/SKILL.md +59 -9
- package/adapters/claude/skills/forge-6-docs/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-6-docs/references/stage-exit-protocol.md +472 -0
- package/adapters/claude/skills/forge-fix/SKILL.md +85 -33
- package/adapters/claude/skills/forge-fix/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-fix/references/stage-exit-protocol.md +358 -144
- package/adapters/claude/skills/forge-guide/references/forge-config-schema.json +1 -1
- package/adapters/claude/skills/forge-guide/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-verify/SKILL.md +86 -44
- package/adapters/claude/skills/forge-verify/references/findings-template.md +147 -0
- package/adapters/claude/skills/forge-verify/references/shared-conventions.md +125 -12
- package/adapters/claude/skills/forge-verify/references/stage-exit-protocol.md +472 -0
- package/adapters/claude/skills/forge-verify/references/verification-checklists/backlog.md +97 -0
- package/adapters/claude/skills/forge-verify/references/verification-checklists/epic.md +80 -0
- package/adapters/claude/skills/forge-verify/references/verification-checklists/impl.md +48 -0
- package/adapters/claude/skills/forge-verify/references/verification-checklists/prd.md +31 -0
- package/adapters/claude/skills/forge-verify/references/verification-checklists/specs.md +66 -0
- package/adapters/claude/skills/forge-verify/references/verification-checklists/tech.md +35 -0
- package/adapters/codex/.feature-forge-bundle.json +1 -1
- package/adapters/codex/agents/forge-verifier.toml +1 -1
- package/adapters/codex/references/epic-manifest-schema.json +6 -1
- package/adapters/codex/references/forge-config-schema.json +1 -1
- package/adapters/codex/references/pipeline-state-schema.json +5 -3
- package/adapters/codex/references/shared-conventions.md +125 -12
- package/adapters/codex/references/stage-exit-protocol.md +358 -144
- package/adapters/codex/references/vendor-construct-inventory.md +1 -1
- package/adapters/codex/scripts/epic-manifest.py +459 -90
- package/adapters/codex/scripts/forge-bootstrap.py +57 -5
- package/adapters/codex/scripts/forge-session.py +4346 -201
- package/adapters/codex/scripts/validate-traceability.py +92 -6
- package/adapters/codex/skills/forge/SKILL.md +18 -11
- package/adapters/codex/skills/forge/references/pipeline-state-schema.json +5 -3
- package/adapters/codex/skills/forge/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge/references/stage-exit-protocol.md +358 -144
- package/adapters/codex/skills/forge-0-epic/SKILL.md +8 -3
- package/adapters/codex/skills/forge-0-epic/references/edit-mode.md +24 -24
- package/adapters/codex/skills/forge-0-epic/references/pipeline-state-schema.json +5 -3
- package/adapters/codex/skills/forge-0-epic/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-0-epic/references/stage-exit-protocol.md +358 -144
- package/adapters/codex/skills/forge-1-prd/SKILL.md +39 -11
- package/adapters/codex/skills/forge-1-prd/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-1-prd/references/stage-exit-protocol.md +358 -144
- package/adapters/codex/skills/forge-2-tech/SKILL.md +38 -10
- package/adapters/codex/skills/forge-2-tech/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-2-tech/references/stage-exit-protocol.md +358 -144
- package/adapters/codex/skills/forge-3-specs/SKILL.md +28 -9
- package/adapters/codex/skills/forge-3-specs/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-3-specs/references/spec-archetypes.md +9 -0
- package/adapters/codex/skills/forge-3-specs/references/stage-exit-protocol.md +358 -144
- package/adapters/codex/skills/forge-4-backlog/SKILL.md +39 -10
- package/adapters/codex/skills/forge-4-backlog/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-4-backlog/references/stage-exit-protocol.md +358 -144
- package/adapters/codex/skills/forge-5-loop/SKILL.md +65 -67
- package/adapters/codex/skills/forge-5-loop/references/agent-selection.md +116 -0
- package/adapters/codex/skills/forge-5-loop/references/result-reporting.md +70 -31
- package/adapters/codex/skills/forge-5-loop/references/runner-contract.md +18 -109
- package/adapters/codex/skills/forge-5-loop/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-5-loop/references/stage-exit-protocol.md +358 -144
- package/adapters/codex/skills/forge-6-docs/SKILL.md +59 -9
- package/adapters/codex/skills/forge-6-docs/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-6-docs/references/stage-exit-protocol.md +472 -0
- package/adapters/codex/skills/forge-fix/SKILL.md +84 -32
- package/adapters/codex/skills/forge-fix/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-fix/references/stage-exit-protocol.md +358 -144
- package/adapters/codex/skills/forge-guide/references/forge-config-schema.json +1 -1
- package/adapters/codex/skills/forge-guide/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-verify/SKILL.md +85 -43
- package/adapters/codex/skills/forge-verify/references/findings-template.md +147 -0
- package/adapters/codex/skills/forge-verify/references/shared-conventions.md +125 -12
- package/adapters/codex/skills/forge-verify/references/stage-exit-protocol.md +472 -0
- package/adapters/codex/skills/forge-verify/references/verification-checklists/backlog.md +97 -0
- package/adapters/codex/skills/forge-verify/references/verification-checklists/epic.md +80 -0
- package/adapters/codex/skills/forge-verify/references/verification-checklists/impl.md +48 -0
- package/adapters/codex/skills/forge-verify/references/verification-checklists/prd.md +31 -0
- package/adapters/codex/skills/forge-verify/references/verification-checklists/specs.md +66 -0
- package/adapters/codex/skills/forge-verify/references/verification-checklists/tech.md +35 -0
- package/adapters/copilot/.feature-forge-bundle.json +1 -1
- package/adapters/copilot/agents/forge-verifier.md +1 -1
- package/adapters/copilot/references/epic-manifest-schema.json +6 -1
- package/adapters/copilot/references/forge-config-schema.json +1 -1
- package/adapters/copilot/references/pipeline-state-schema.json +5 -3
- package/adapters/copilot/references/shared-conventions.md +125 -12
- package/adapters/copilot/references/stage-exit-protocol.md +358 -144
- package/adapters/copilot/references/vendor-construct-inventory.md +1 -1
- package/adapters/copilot/scripts/epic-manifest.py +459 -90
- package/adapters/copilot/scripts/forge-bootstrap.py +57 -5
- package/adapters/copilot/scripts/forge-session.py +4346 -201
- package/adapters/copilot/scripts/validate-traceability.py +92 -6
- package/adapters/copilot/skills/forge/forge.md +18 -11
- package/adapters/copilot/skills/forge/references/pipeline-state-schema.json +5 -3
- package/adapters/copilot/skills/forge/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge/references/stage-exit-protocol.md +358 -144
- package/adapters/copilot/skills/forge-0-epic/forge-0-epic.md +8 -3
- package/adapters/copilot/skills/forge-0-epic/references/edit-mode.md +24 -24
- package/adapters/copilot/skills/forge-0-epic/references/pipeline-state-schema.json +5 -3
- package/adapters/copilot/skills/forge-0-epic/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-0-epic/references/stage-exit-protocol.md +358 -144
- package/adapters/copilot/skills/forge-1-prd/forge-1-prd.md +39 -11
- package/adapters/copilot/skills/forge-1-prd/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-1-prd/references/stage-exit-protocol.md +358 -144
- package/adapters/copilot/skills/forge-2-tech/forge-2-tech.md +38 -10
- package/adapters/copilot/skills/forge-2-tech/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-2-tech/references/stage-exit-protocol.md +358 -144
- package/adapters/copilot/skills/forge-3-specs/forge-3-specs.md +28 -9
- package/adapters/copilot/skills/forge-3-specs/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-3-specs/references/spec-archetypes.md +9 -0
- package/adapters/copilot/skills/forge-3-specs/references/stage-exit-protocol.md +358 -144
- package/adapters/copilot/skills/forge-4-backlog/forge-4-backlog.md +39 -10
- package/adapters/copilot/skills/forge-4-backlog/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-4-backlog/references/stage-exit-protocol.md +358 -144
- package/adapters/copilot/skills/forge-5-loop/forge-5-loop.md +65 -67
- package/adapters/copilot/skills/forge-5-loop/references/agent-selection.md +116 -0
- package/adapters/copilot/skills/forge-5-loop/references/result-reporting.md +70 -31
- package/adapters/copilot/skills/forge-5-loop/references/runner-contract.md +18 -109
- package/adapters/copilot/skills/forge-5-loop/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-5-loop/references/stage-exit-protocol.md +358 -144
- package/adapters/copilot/skills/forge-6-docs/forge-6-docs.md +59 -9
- package/adapters/copilot/skills/forge-6-docs/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-6-docs/references/stage-exit-protocol.md +472 -0
- package/adapters/copilot/skills/forge-fix/forge-fix.md +84 -32
- package/adapters/copilot/skills/forge-fix/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-fix/references/stage-exit-protocol.md +358 -144
- package/adapters/copilot/skills/forge-guide/references/forge-config-schema.json +1 -1
- package/adapters/copilot/skills/forge-guide/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-verify/forge-verify.md +85 -43
- package/adapters/copilot/skills/forge-verify/references/findings-template.md +147 -0
- package/adapters/copilot/skills/forge-verify/references/shared-conventions.md +125 -12
- package/adapters/copilot/skills/forge-verify/references/stage-exit-protocol.md +472 -0
- package/adapters/copilot/skills/forge-verify/references/verification-checklists/backlog.md +97 -0
- package/adapters/copilot/skills/forge-verify/references/verification-checklists/epic.md +80 -0
- package/adapters/copilot/skills/forge-verify/references/verification-checklists/impl.md +48 -0
- package/adapters/copilot/skills/forge-verify/references/verification-checklists/prd.md +31 -0
- package/adapters/copilot/skills/forge-verify/references/verification-checklists/specs.md +66 -0
- package/adapters/copilot/skills/forge-verify/references/verification-checklists/tech.md +35 -0
- package/adapters/cursor/.feature-forge-bundle.json +1 -1
- package/adapters/cursor/agents/forge-verifier.mdc +1 -1
- package/adapters/cursor/references/epic-manifest-schema.json +6 -1
- package/adapters/cursor/references/forge-config-schema.json +1 -1
- package/adapters/cursor/references/pipeline-state-schema.json +5 -3
- package/adapters/cursor/references/shared-conventions.md +125 -12
- package/adapters/cursor/references/stage-exit-protocol.md +358 -144
- package/adapters/cursor/references/vendor-construct-inventory.md +1 -1
- package/adapters/cursor/scripts/epic-manifest.py +459 -90
- package/adapters/cursor/scripts/forge-bootstrap.py +57 -5
- package/adapters/cursor/scripts/forge-session.py +4346 -201
- package/adapters/cursor/scripts/validate-traceability.py +92 -6
- package/adapters/cursor/skills/forge/forge.mdc +18 -11
- package/adapters/cursor/skills/forge/references/pipeline-state-schema.json +5 -3
- package/adapters/cursor/skills/forge/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge/references/stage-exit-protocol.md +358 -144
- package/adapters/cursor/skills/forge-0-epic/forge-0-epic.mdc +8 -3
- package/adapters/cursor/skills/forge-0-epic/references/edit-mode.md +24 -24
- package/adapters/cursor/skills/forge-0-epic/references/pipeline-state-schema.json +5 -3
- package/adapters/cursor/skills/forge-0-epic/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-0-epic/references/stage-exit-protocol.md +358 -144
- package/adapters/cursor/skills/forge-1-prd/forge-1-prd.mdc +39 -11
- package/adapters/cursor/skills/forge-1-prd/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-1-prd/references/stage-exit-protocol.md +358 -144
- package/adapters/cursor/skills/forge-2-tech/forge-2-tech.mdc +38 -10
- package/adapters/cursor/skills/forge-2-tech/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-2-tech/references/stage-exit-protocol.md +358 -144
- package/adapters/cursor/skills/forge-3-specs/forge-3-specs.mdc +28 -9
- package/adapters/cursor/skills/forge-3-specs/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-3-specs/references/spec-archetypes.md +9 -0
- package/adapters/cursor/skills/forge-3-specs/references/stage-exit-protocol.md +358 -144
- package/adapters/cursor/skills/forge-4-backlog/forge-4-backlog.mdc +39 -10
- package/adapters/cursor/skills/forge-4-backlog/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-4-backlog/references/stage-exit-protocol.md +358 -144
- package/adapters/cursor/skills/forge-5-loop/forge-5-loop.mdc +65 -67
- package/adapters/cursor/skills/forge-5-loop/references/agent-selection.md +116 -0
- package/adapters/cursor/skills/forge-5-loop/references/result-reporting.md +70 -31
- package/adapters/cursor/skills/forge-5-loop/references/runner-contract.md +18 -109
- package/adapters/cursor/skills/forge-5-loop/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-5-loop/references/stage-exit-protocol.md +358 -144
- package/adapters/cursor/skills/forge-6-docs/forge-6-docs.mdc +59 -9
- package/adapters/cursor/skills/forge-6-docs/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-6-docs/references/stage-exit-protocol.md +472 -0
- package/adapters/cursor/skills/forge-fix/forge-fix.mdc +84 -32
- package/adapters/cursor/skills/forge-fix/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-fix/references/stage-exit-protocol.md +358 -144
- package/adapters/cursor/skills/forge-guide/references/forge-config-schema.json +1 -1
- package/adapters/cursor/skills/forge-guide/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-verify/forge-verify.mdc +85 -43
- package/adapters/cursor/skills/forge-verify/references/findings-template.md +147 -0
- package/adapters/cursor/skills/forge-verify/references/shared-conventions.md +125 -12
- package/adapters/cursor/skills/forge-verify/references/stage-exit-protocol.md +472 -0
- package/adapters/cursor/skills/forge-verify/references/verification-checklists/backlog.md +97 -0
- package/adapters/cursor/skills/forge-verify/references/verification-checklists/epic.md +80 -0
- package/adapters/cursor/skills/forge-verify/references/verification-checklists/impl.md +48 -0
- package/adapters/cursor/skills/forge-verify/references/verification-checklists/prd.md +31 -0
- package/adapters/cursor/skills/forge-verify/references/verification-checklists/specs.md +66 -0
- package/adapters/cursor/skills/forge-verify/references/verification-checklists/tech.md +35 -0
- package/adapters/gemini/.feature-forge-bundle.json +1 -1
- package/adapters/gemini/agents/forge-verifier.md +1 -1
- package/adapters/gemini/gemini-extension.json +1 -1
- package/adapters/gemini/references/epic-manifest-schema.json +6 -1
- package/adapters/gemini/references/forge-config-schema.json +1 -1
- package/adapters/gemini/references/pipeline-state-schema.json +5 -3
- package/adapters/gemini/references/shared-conventions.md +125 -12
- package/adapters/gemini/references/stage-exit-protocol.md +358 -144
- package/adapters/gemini/references/vendor-construct-inventory.md +1 -1
- package/adapters/gemini/scripts/epic-manifest.py +459 -90
- package/adapters/gemini/scripts/forge-bootstrap.py +57 -5
- package/adapters/gemini/scripts/forge-session.py +4346 -201
- package/adapters/gemini/scripts/validate-traceability.py +92 -6
- package/adapters/gemini/skills/forge/forge.md +18 -11
- package/adapters/gemini/skills/forge/references/pipeline-state-schema.json +5 -3
- package/adapters/gemini/skills/forge/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge/references/stage-exit-protocol.md +358 -144
- package/adapters/gemini/skills/forge-0-epic/forge-0-epic.md +8 -3
- package/adapters/gemini/skills/forge-0-epic/references/edit-mode.md +24 -24
- package/adapters/gemini/skills/forge-0-epic/references/pipeline-state-schema.json +5 -3
- package/adapters/gemini/skills/forge-0-epic/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-0-epic/references/stage-exit-protocol.md +358 -144
- package/adapters/gemini/skills/forge-1-prd/forge-1-prd.md +39 -11
- package/adapters/gemini/skills/forge-1-prd/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-1-prd/references/stage-exit-protocol.md +358 -144
- package/adapters/gemini/skills/forge-2-tech/forge-2-tech.md +38 -10
- package/adapters/gemini/skills/forge-2-tech/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-2-tech/references/stage-exit-protocol.md +358 -144
- package/adapters/gemini/skills/forge-3-specs/forge-3-specs.md +28 -9
- package/adapters/gemini/skills/forge-3-specs/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-3-specs/references/spec-archetypes.md +9 -0
- package/adapters/gemini/skills/forge-3-specs/references/stage-exit-protocol.md +358 -144
- package/adapters/gemini/skills/forge-4-backlog/forge-4-backlog.md +39 -10
- package/adapters/gemini/skills/forge-4-backlog/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-4-backlog/references/stage-exit-protocol.md +358 -144
- package/adapters/gemini/skills/forge-5-loop/forge-5-loop.md +65 -67
- package/adapters/gemini/skills/forge-5-loop/references/agent-selection.md +116 -0
- package/adapters/gemini/skills/forge-5-loop/references/result-reporting.md +70 -31
- package/adapters/gemini/skills/forge-5-loop/references/runner-contract.md +18 -109
- package/adapters/gemini/skills/forge-5-loop/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-5-loop/references/stage-exit-protocol.md +358 -144
- package/adapters/gemini/skills/forge-6-docs/forge-6-docs.md +59 -9
- package/adapters/gemini/skills/forge-6-docs/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-6-docs/references/stage-exit-protocol.md +472 -0
- package/adapters/gemini/skills/forge-fix/forge-fix.md +84 -32
- package/adapters/gemini/skills/forge-fix/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-fix/references/stage-exit-protocol.md +358 -144
- package/adapters/gemini/skills/forge-guide/references/forge-config-schema.json +1 -1
- package/adapters/gemini/skills/forge-guide/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-verify/forge-verify.md +85 -43
- package/adapters/gemini/skills/forge-verify/references/findings-template.md +147 -0
- package/adapters/gemini/skills/forge-verify/references/shared-conventions.md +125 -12
- package/adapters/gemini/skills/forge-verify/references/stage-exit-protocol.md +472 -0
- package/adapters/gemini/skills/forge-verify/references/verification-checklists/backlog.md +97 -0
- package/adapters/gemini/skills/forge-verify/references/verification-checklists/epic.md +80 -0
- package/adapters/gemini/skills/forge-verify/references/verification-checklists/impl.md +48 -0
- package/adapters/gemini/skills/forge-verify/references/verification-checklists/prd.md +31 -0
- package/adapters/gemini/skills/forge-verify/references/verification-checklists/specs.md +66 -0
- package/adapters/gemini/skills/forge-verify/references/verification-checklists/tech.md +35 -0
- package/adapters/pi/.feature-forge-bundle.json +1 -1
- package/adapters/pi/agents/forge-verifier.md +1 -1
- package/adapters/pi/references/epic-manifest-schema.json +6 -1
- package/adapters/pi/references/forge-config-schema.json +1 -1
- package/adapters/pi/references/pipeline-state-schema.json +5 -3
- package/adapters/pi/references/shared-conventions.md +125 -12
- package/adapters/pi/references/stage-exit-protocol.md +358 -144
- package/adapters/pi/references/vendor-construct-inventory.md +1 -1
- package/adapters/pi/scripts/epic-manifest.py +459 -90
- package/adapters/pi/scripts/forge-bootstrap.py +57 -5
- package/adapters/pi/scripts/forge-session.py +4346 -201
- package/adapters/pi/scripts/validate-traceability.py +92 -6
- package/adapters/pi/skills/forge/SKILL.md +18 -11
- package/adapters/pi/skills/forge/references/pipeline-state-schema.json +5 -3
- package/adapters/pi/skills/forge/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge/references/stage-exit-protocol.md +358 -144
- package/adapters/pi/skills/forge-0-epic/SKILL.md +8 -3
- package/adapters/pi/skills/forge-0-epic/references/edit-mode.md +24 -24
- package/adapters/pi/skills/forge-0-epic/references/pipeline-state-schema.json +5 -3
- package/adapters/pi/skills/forge-0-epic/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-0-epic/references/stage-exit-protocol.md +358 -144
- package/adapters/pi/skills/forge-1-prd/SKILL.md +39 -11
- package/adapters/pi/skills/forge-1-prd/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-1-prd/references/stage-exit-protocol.md +358 -144
- package/adapters/pi/skills/forge-2-tech/SKILL.md +38 -10
- package/adapters/pi/skills/forge-2-tech/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-2-tech/references/stage-exit-protocol.md +358 -144
- package/adapters/pi/skills/forge-3-specs/SKILL.md +28 -9
- package/adapters/pi/skills/forge-3-specs/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-3-specs/references/spec-archetypes.md +9 -0
- package/adapters/pi/skills/forge-3-specs/references/stage-exit-protocol.md +358 -144
- package/adapters/pi/skills/forge-4-backlog/SKILL.md +39 -10
- package/adapters/pi/skills/forge-4-backlog/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-4-backlog/references/stage-exit-protocol.md +358 -144
- package/adapters/pi/skills/forge-5-loop/SKILL.md +65 -67
- package/adapters/pi/skills/forge-5-loop/references/agent-selection.md +116 -0
- package/adapters/pi/skills/forge-5-loop/references/result-reporting.md +70 -31
- package/adapters/pi/skills/forge-5-loop/references/runner-contract.md +18 -109
- package/adapters/pi/skills/forge-5-loop/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-5-loop/references/stage-exit-protocol.md +358 -144
- package/adapters/pi/skills/forge-6-docs/SKILL.md +59 -9
- package/adapters/pi/skills/forge-6-docs/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-6-docs/references/stage-exit-protocol.md +472 -0
- package/adapters/pi/skills/forge-fix/SKILL.md +84 -32
- package/adapters/pi/skills/forge-fix/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-fix/references/stage-exit-protocol.md +358 -144
- package/adapters/pi/skills/forge-guide/references/forge-config-schema.json +1 -1
- package/adapters/pi/skills/forge-guide/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-verify/SKILL.md +85 -43
- package/adapters/pi/skills/forge-verify/references/findings-template.md +147 -0
- package/adapters/pi/skills/forge-verify/references/shared-conventions.md +125 -12
- package/adapters/pi/skills/forge-verify/references/stage-exit-protocol.md +472 -0
- package/adapters/pi/skills/forge-verify/references/verification-checklists/backlog.md +97 -0
- package/adapters/pi/skills/forge-verify/references/verification-checklists/epic.md +80 -0
- package/adapters/pi/skills/forge-verify/references/verification-checklists/impl.md +48 -0
- package/adapters/pi/skills/forge-verify/references/verification-checklists/prd.md +31 -0
- package/adapters/pi/skills/forge-verify/references/verification-checklists/specs.md +66 -0
- package/adapters/pi/skills/forge-verify/references/verification-checklists/tech.md +35 -0
- package/package.json +1 -1
- package/adapters/claude/skills/forge-1-prd/references/pipeline-state-schema.json +0 -191
- package/adapters/claude/skills/forge-2-tech/references/pipeline-state-schema.json +0 -191
- package/adapters/claude/skills/forge-3-specs/references/pipeline-state-schema.json +0 -191
- package/adapters/claude/skills/forge-4-backlog/references/forge-config-schema.json +0 -236
- package/adapters/claude/skills/forge-4-backlog/references/pipeline-state-schema.json +0 -191
- package/adapters/claude/skills/forge-5-loop/references/forge-config-schema.json +0 -236
- package/adapters/claude/skills/forge-6-docs/references/pipeline-state-schema.json +0 -191
- package/adapters/claude/skills/forge-verify/references/pipeline-state-schema.json +0 -191
- package/adapters/claude/skills/forge-verify/references/verification-checklists.md +0 -477
- package/adapters/codex/skills/forge-1-prd/references/pipeline-state-schema.json +0 -191
- package/adapters/codex/skills/forge-2-tech/references/pipeline-state-schema.json +0 -191
- package/adapters/codex/skills/forge-3-specs/references/pipeline-state-schema.json +0 -191
- package/adapters/codex/skills/forge-4-backlog/references/forge-config-schema.json +0 -236
- package/adapters/codex/skills/forge-4-backlog/references/pipeline-state-schema.json +0 -191
- package/adapters/codex/skills/forge-5-loop/references/forge-config-schema.json +0 -236
- package/adapters/codex/skills/forge-6-docs/references/pipeline-state-schema.json +0 -191
- package/adapters/codex/skills/forge-verify/references/pipeline-state-schema.json +0 -191
- package/adapters/codex/skills/forge-verify/references/verification-checklists.md +0 -477
- package/adapters/copilot/skills/forge-1-prd/references/pipeline-state-schema.json +0 -191
- package/adapters/copilot/skills/forge-2-tech/references/pipeline-state-schema.json +0 -191
- package/adapters/copilot/skills/forge-3-specs/references/pipeline-state-schema.json +0 -191
- package/adapters/copilot/skills/forge-4-backlog/references/forge-config-schema.json +0 -236
- package/adapters/copilot/skills/forge-4-backlog/references/pipeline-state-schema.json +0 -191
- package/adapters/copilot/skills/forge-5-loop/references/forge-config-schema.json +0 -236
- package/adapters/copilot/skills/forge-6-docs/references/pipeline-state-schema.json +0 -191
- package/adapters/copilot/skills/forge-verify/references/pipeline-state-schema.json +0 -191
- package/adapters/copilot/skills/forge-verify/references/verification-checklists.md +0 -477
- package/adapters/cursor/skills/forge-1-prd/references/pipeline-state-schema.json +0 -191
- package/adapters/cursor/skills/forge-2-tech/references/pipeline-state-schema.json +0 -191
- package/adapters/cursor/skills/forge-3-specs/references/pipeline-state-schema.json +0 -191
- package/adapters/cursor/skills/forge-4-backlog/references/forge-config-schema.json +0 -236
- package/adapters/cursor/skills/forge-4-backlog/references/pipeline-state-schema.json +0 -191
- package/adapters/cursor/skills/forge-5-loop/references/forge-config-schema.json +0 -236
- package/adapters/cursor/skills/forge-6-docs/references/pipeline-state-schema.json +0 -191
- package/adapters/cursor/skills/forge-verify/references/pipeline-state-schema.json +0 -191
- package/adapters/cursor/skills/forge-verify/references/verification-checklists.md +0 -477
- package/adapters/gemini/skills/forge-1-prd/references/pipeline-state-schema.json +0 -191
- package/adapters/gemini/skills/forge-2-tech/references/pipeline-state-schema.json +0 -191
- package/adapters/gemini/skills/forge-3-specs/references/pipeline-state-schema.json +0 -191
- package/adapters/gemini/skills/forge-4-backlog/references/forge-config-schema.json +0 -236
- package/adapters/gemini/skills/forge-4-backlog/references/pipeline-state-schema.json +0 -191
- package/adapters/gemini/skills/forge-5-loop/references/forge-config-schema.json +0 -236
- package/adapters/gemini/skills/forge-6-docs/references/pipeline-state-schema.json +0 -191
- package/adapters/gemini/skills/forge-verify/references/pipeline-state-schema.json +0 -191
- package/adapters/gemini/skills/forge-verify/references/verification-checklists.md +0 -477
- package/adapters/pi/skills/forge-1-prd/references/pipeline-state-schema.json +0 -191
- package/adapters/pi/skills/forge-2-tech/references/pipeline-state-schema.json +0 -191
- package/adapters/pi/skills/forge-3-specs/references/pipeline-state-schema.json +0 -191
- package/adapters/pi/skills/forge-4-backlog/references/forge-config-schema.json +0 -236
- package/adapters/pi/skills/forge-4-backlog/references/pipeline-state-schema.json +0 -191
- package/adapters/pi/skills/forge-5-loop/references/forge-config-schema.json +0 -236
- package/adapters/pi/skills/forge-6-docs/references/pipeline-state-schema.json +0 -191
- package/adapters/pi/skills/forge-verify/references/pipeline-state-schema.json +0 -191
- package/adapters/pi/skills/forge-verify/references/verification-checklists.md +0 -477
|
@@ -133,6 +133,8 @@ mkdir -p "<specsDir>"
|
|
|
133
133
|
If the host is Claude (the `AskUserQuestion` tool is available), also ensure the Claude-framed variant:
|
|
134
134
|
|
|
135
135
|
```bash
|
|
136
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
137
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
136
138
|
[ -f "<specsDir>/CLAUDE.md" ] || cp "$R/references/templates/specs-hygiene/CLAUDE.md" "<specsDir>/CLAUDE.md"
|
|
137
139
|
```
|
|
138
140
|
|
|
@@ -183,7 +185,49 @@ If the helper is unavailable (a non-Claude host without the resolver), skip this
|
|
|
183
185
|
|
|
184
186
|
## Pipeline State Protocol
|
|
185
187
|
|
|
186
|
-
|
|
188
|
+
Pipeline state is written by the `state-*` verbs of `scripts/forge-session.py` — never by hand. Each verb writes `{resolvedFeatureDir}/.pipeline-state.json` atomically, conforms to `references/pipeline-state-schema.json` by construction, and refreshes `updatedAt` for you, so no stage needs to read the schema in order to author state.
|
|
189
|
+
|
|
190
|
+
**Epic members MUST pass `--epic`.** Every `state-*` verb takes an optional `--epic "{epic}"`, and it is **required** whenever the feature is an epic member (its resolved directory is `{specsDir}/{epic}/{feature}/`, i.e. its state carries an `epic` back-pointer) — append it to **every** `state-*` call in this file and in every skill body, exactly as the `state-ecr` calls already do. Omit it only for a standalone feature. Without it the verb resolves the bare name itself and, mirroring `epic-manifest.py resolve`, refuses with exit 2 whenever more than one directory carries a state file rather than guessing which feature to write — so a same-named standalone feature can never be mutated in a member's place.
|
|
191
|
+
|
|
192
|
+
If a `state-*` verb exits 2, surface the plain `Error:` line from stderr verbatim, do **not** proceed to the next step of the surrounding protocol, and do **not** hand-author the JSON as a workaround. The stage remains resumable because the entry stamp is already on disk — re-run the verb once the cause is fixed.
|
|
193
|
+
|
|
194
|
+
**The eight `state-*` verbs.** `state-enter` (Stage-Entry Guard), `state-artifact` (incremental artifact tracking), `state-complete` (Git Commit Protocol), `state-branch` (Branch Setup and Branch Reconciliation), `state-note` (the Immediate Downstream Note below, and the optional completion note at stage closure), `state-decision` (deferred decisions), `state-ecr` (epic change requests), and `state-verify` (one `forge-verify-*` verification transition — below). The `--epic` member requirement and the exit-2 failure protocol above apply to **every** one of them, `state-verify` included; no verify entry is ever hand-authored.
|
|
195
|
+
|
|
196
|
+
### `state-verify` — verification results and provenance
|
|
197
|
+
|
|
198
|
+
`state-verify` writes exactly one `stages.forge-verify-{token}` entry — the verification result for the production stage named by `--stage` — plus the top-level `updatedAt`, and nothing else. `--stage` takes the **served production stage** (`forge-0-epic` through `forge-5-loop`; `forge-6-docs` has no verification token and is rejected). Add `--epic "{epic}"` when the feature is an epic member — required, per the member rule above. Result mode passes `--status` (`auto-verify-pending`, `passed`, `findings-reported`, `findings-applied`, or `skipped`) with whatever `--findings-file`, `--findings-count`, and `--verified-stage-version` that status requires; contradictory metadata is refused before any write. `passed` may additionally carry `--findings-file` + `--findings-count` together for an **advisory-only** report (`inconsistency`/`improvement` findings only, per forge-verify's severity floor) — the stage resolves without a fix round and the report stays attached:
|
|
199
|
+
|
|
200
|
+
**`auto-verify-pending` is not a skill-facing status.** It is written by `stage-exit`'s scheduling boundary, which records the debt automatically when auto-verify is effective for a stage. The value is accepted on this CLI so the entry stays inspectable and repairable, not so a skill can hand-schedule verification: no skill body and no reference passes it, and none should. Every other status in the list is the recorded *result* of a verification that ran (or was explicitly skipped); this one records that one was *owed*.
|
|
201
|
+
|
|
202
|
+
```bash
|
|
203
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
204
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
205
|
+
python3 "$R/scripts/forge-session.py" state-verify \
|
|
206
|
+
--feature "{feature}" --stage "{served-production-stage}" --status "<status>" \
|
|
207
|
+
--specs-dir "{specsDir}"
|
|
208
|
+
```
|
|
209
|
+
|
|
210
|
+
Provenance follows the same two-commit sequence as `state-complete`: the result transition above writes `commitHash: null`, Commit 1 records the findings document and the state, and a second `state-verify` call records the full 40-hex hash of Commit 1 and touches nothing else (never `--amend`; an abbreviated hash is refused rather than expanded). Add `--epic "{epic}"` for an epic member — required, per the member rule above:
|
|
211
|
+
|
|
212
|
+
```bash
|
|
213
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
214
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
215
|
+
python3 "$R/scripts/forge-session.py" state-verify \
|
|
216
|
+
--feature "{feature}" --stage "{served-production-stage}" \
|
|
217
|
+
--commit-hash "$(git rev-parse HEAD)" --specs-dir "{specsDir}"
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
Epic-scoped verification is the single exception to the member rule: with `--stage forge-0-epic`, `--feature` names the **epic** and `--epic` must be absent or exactly equal to it. That call writes `{specsDir}/{epic}/.epic-state.json` and never a member's `.pipeline-state.json`, and its freshness version is the epic manifest's `revision`, never a member's stage version:
|
|
221
|
+
|
|
222
|
+
```bash
|
|
223
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
224
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
225
|
+
python3 "$R/scripts/forge-session.py" state-verify \
|
|
226
|
+
--feature "{epic}" --stage forge-0-epic --status "<status>" \
|
|
227
|
+
--specs-dir "{specsDir}"
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
On exit 2 the verification result is **not** recorded: surface the `Error:` line verbatim, name the feature (and epic), and do not claim the verification was persisted or advance past it.
|
|
187
231
|
|
|
188
232
|
### Staleness Detection (Read-Time)
|
|
189
233
|
|
|
@@ -193,6 +237,31 @@ When loading upstream artifacts as prerequisites, check `basedOnVersions` in the
|
|
|
193
237
|
|
|
194
238
|
Frame the choice with its cost: re-running re-derives this stage from the current upstream (safest, but discards any hand-edits to this stage's artifacts); proceeding stale is faster but risks baking outdated assumptions into everything downstream. Recommend re-running unless the user knows the upstream change doesn't affect this stage.
|
|
195
239
|
|
|
240
|
+
## Immediate Downstream Note (Parking Lot)
|
|
241
|
+
|
|
242
|
+
When an interview raises a concern that belongs to a *later stage of this same feature*, acknowledge it and persist it **immediately, at the moment it is raised** — not at stage closure — by running `state-note` with a concise one-line statement of the concern. Add `--epic "{epic}"` when this feature is an epic member — required, per the Pipeline State Protocol above; omitting it for a member is an error and must never be allowed to fall back to a same-named flat feature.
|
|
243
|
+
|
|
244
|
+
```bash
|
|
245
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
246
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
247
|
+
python3 "$R/scripts/forge-session.py" state-note \
|
|
248
|
+
--feature "{feature}" --note "<concise downstream concern>" \
|
|
249
|
+
--specs-dir "{specsDir}"
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
`state-note` **overwrites** the single top-level `notes` string — it does not append. To preserve an earlier note, read the current `notes` value out of the feature's `.pipeline-state.json` first and pass one combined concise string in a single `--note`; never edit or round-trip the JSON by hand. This interview-time call is separate from the optional completion note offered at stage closure and must not be deferred until then — a session that ends before closure would otherwise lose the concern entirely.
|
|
253
|
+
|
|
254
|
+
On `UsageError`/exit 2, surface the `Error:` line verbatim together with the named feature (and epic) and the recovery instruction, and **stop claiming the concern was recorded** — it was not. Epic *decomposition* changes are not notes: they go through `state-ecr` into `epicChangeRequests`, never into `notes`.
|
|
255
|
+
|
|
256
|
+
## Verify Capability
|
|
257
|
+
|
|
258
|
+
Skills that close a stage pass `--verify-capability interactive|manual` to `stage-exit`. The full determination rule, the Standard Verify Gate, and the recovery path live in `references/stage-exit-protocol.md`; the two facts that are most often gotten wrong:
|
|
259
|
+
|
|
260
|
+
- **Dispatch capability is *permitted* dispatch, not a listed tool.** The question is "**may I dispatch `forge-verifier` right now**", not "is a subagent-dispatch tool in my tool surface". A session can carry a standing host instruction against dispatching subagents unless the user asked; such instructions are injected by the harness, sit outside this project's control, and outrank skill prose. Classify on permission, up front.
|
|
261
|
+
- **A consent requirement is `interactive`, not `manual`.** When dispatch is barred only *unless the user asked* and a question mechanism is available, pass `interactive`: the gate's own affirmative choice supplies the missing user request. Pass `manual` only when there is **no** question mechanism **and** **no** permitted dispatch.
|
|
262
|
+
|
|
263
|
+
A bar on unsolicited dispatch is never grounds to skip verification, and never grounds to fence the production successor while verification is unresolved. On the `runInStageVerify: true` path the emitted `verifyGate` stays `none`: reuse the Standard Verify Gate block for consent with **choice 2 omitted** (auto-verify is already effective, so "enable auto-verify going forward" is a no-op), leaving exactly two choices: *Verify now* (recommended) and *Skip for now*. The clean-room `forge-verifier` is **dispatched on the affirmative choice**, never merely printed for the user to run later; *Skip for now* is persisted as an explicit `skipped` before any advancing block.
|
|
264
|
+
|
|
196
265
|
## Branch Setup
|
|
197
266
|
|
|
198
267
|
Invoke this block at the **very start** of a pipeline entry point — `forge-1-prd` (standalone feature) and `forge-0-epic` (epic) — **before** any directory resolution or interview, so the rest of the run lands on the intended branch. `{label}` is the feature name (forge-1-prd) or epic name (forge-0-epic); `{scope}` is `feature` or `epic` correspondingly.
|
|
@@ -214,7 +283,16 @@ Invoke this block at the **very start** of a pipeline entry point — `forge-1-p
|
|
|
214
283
|
- **Create** → `git switch -c {branchPrefix}{label}` (or `git checkout -b` if `switch` is unavailable). If the branch already exists, `git switch {branchPrefix}{label}`.
|
|
215
284
|
- **Stay** → proceed on the default branch; note that subsequent commits (and any `forge-5-loop` run) will land directly on `{defaultBranch}`.
|
|
216
285
|
|
|
217
|
-
**Record the branch.** After this block resolves,
|
|
286
|
+
**Record the branch.** After this block resolves, record the resulting branch name in the feature's top-level `branch` field by running `state-branch` (create/update it when the state file is first written for this stage). Emit the call **once the feature directory exists** — i.e. after Feature Directory Resolution and the Entry Stamp, **not** at this block: Branch Setup runs at the very start of the entry point, before any directory resolution, and a brand-new standalone feature may have no directory yet. Add `--epic "{epic}"` to the call when this feature is an epic member — required, per the Pipeline State Protocol.
|
|
287
|
+
|
|
288
|
+
```bash
|
|
289
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
290
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
291
|
+
python3 "$R/scripts/forge-session.py" state-branch \
|
|
292
|
+
--feature "{feature}" --branch "<name>" --specs-dir "{specsDir}"
|
|
293
|
+
```
|
|
294
|
+
|
|
295
|
+
Downstream stages and `forge-5-loop` read it to detect drift back onto the default branch.
|
|
218
296
|
|
|
219
297
|
## Branch Reconciliation
|
|
220
298
|
|
|
@@ -227,10 +305,19 @@ python3 "$R/scripts/forge-session.py" reconcile-branch --feature "{feature}" --s
|
|
|
227
305
|
```
|
|
228
306
|
|
|
229
307
|
Act on the emitted `action` (source of truth is where the state actually resolves, not the recorded field):
|
|
230
|
-
- **`adopt-current`** — you are on a non-default topic branch where the state resolves, and the recorded `branch` differs (a stale/imposed value).
|
|
308
|
+
- **`adopt-current`** — you are on a non-default topic branch where the state resolves, and the recorded `branch` differs (a stale/imposed value). Run `state-branch` (below) to write `newBranch` into the state `branch` field, with a **visible one-line note** ("recorded branch was `{stateBranch}`; work is on `{currentBranch}` — updating to match") — never silently, and **never push the user back** to the recorded branch (offer that only as a plain alternative).
|
|
231
309
|
- **`warn-drift`** — you are on the **default** branch and the state records a topic branch. Via `AskUserQuestion`, strongly recommend creating/switching to `{branchPrefix}{feature}` (then record it), still allowing **proceed on the default branch**. Never hard-stop.
|
|
232
310
|
- **`none`** / **`not-resolved`** — nothing to do; proceed.
|
|
233
311
|
|
|
312
|
+
The `adopt-current` write, with the portable plugin-root prelude. Add `--epic "{epic}"` when this feature is an epic member — required, per the Pipeline State Protocol:
|
|
313
|
+
|
|
314
|
+
```bash
|
|
315
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
316
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
317
|
+
python3 "$R/scripts/forge-session.py" state-branch \
|
|
318
|
+
--feature "{feature}" --branch "{newBranch}" --specs-dir "{specsDir}"
|
|
319
|
+
```
|
|
320
|
+
|
|
234
321
|
If the helper is unavailable (non-Claude host without the resolver), fall back to the manual check: current branch differs from recorded → adopt the current branch unless it is the default, in which case recommend creating `{branchPrefix}{feature}`.
|
|
235
322
|
|
|
236
323
|
## Git Commit Protocol
|
|
@@ -240,14 +327,29 @@ When `gitCommitAfterStage` is true, follow this exact order to avoid state incon
|
|
|
240
327
|
**Why two commits.** The stage's `.pipeline-state.json` is itself part of the staged commit, but the stage's `commitHash` cannot be known until *after* that commit is made. Recording it *inside* the same commit is a chicken-and-egg with no single-commit solution. Resolve it with a **deterministic two-commit sequence**, and **never** with `git commit --amend`: amending rewrites HEAD, so a hash captured before the amend points at an orphaned commit that is not in the final history (the exact defect this protocol exists to prevent).
|
|
241
328
|
|
|
242
329
|
1. **Stage specific files only:** `git add {specsDir}/{feature}/` — never use `git add -A` or `git add .`
|
|
243
|
-
2. **Commit 1 — artifacts + state, hash not yet known:**
|
|
244
|
-
3. **If Commit 1 succeeds — Commit 2 records the hash:** Capture the hash of Commit 1 (`git rev-parse HEAD`)
|
|
245
|
-
4. **If Commit 1 fails:** do NOT update pipeline state to complete. Report the error to the user and leave state as `in-progress` so the stage can be resumed. Common failure causes:
|
|
330
|
+
2. **Commit 1 — artifacts + state, hash not yet known:** Run `state-complete --feature {feature} --stage {stage} --version N …` (which sets this stage's `status: "complete"`, `completedAt`, `version`, `basedOnVersions`, `artifacts` and `commitHash: null`, and applies the downstream staleness cascade), then `git commit -m "{commitPrefix}({feature}): <action>"`. This is the stage's **artifact commit**; its hash is the provenance hash callers rely on.
|
|
331
|
+
3. **If Commit 1 succeeds — Commit 2 records the hash:** Capture the hash of Commit 1 (`git rev-parse HEAD`) by running `state-complete --feature {feature} --stage {stage} --version N --commit-hash $(git rev-parse HEAD)`, which writes it into this stage's `commitHash` and touches nothing else, then commit only that one-line change: `git add {specsDir}/{feature}/.pipeline-state.json && git commit -m "{commitPrefix}({feature}): record stage commit hash"`. The stored `commitHash` now points at the artifact commit (Commit 1) — never at Commit 2, and never at an orphaned amend. The working tree is clean afterward, so the next stage's dirty-tree check passes.
|
|
332
|
+
4. **If Commit 1 fails:** do NOT update pipeline state to complete. Report the error to the user and leave state as `in-progress` so the stage can be resumed. Do that with `state-complete --feature {feature} --stage {stage} --version N --resumable`, which records **only** `status` — no `completedAt`, no version bump, no `basedOnVersions`/`artifacts`, no `commitHash` reset, and no staleness cascade, so the stage stays resumable. (`--version` is still REQUIRED by argparse and must be passed even though `--resumable` does not write it; omitting it makes the recovery command exit 2 every time.) Common failure causes:
|
|
246
333
|
- **Pre-commit hook failure:** Report the hook output. Never use `--no-verify` to bypass. Help the user fix the underlying issue.
|
|
247
334
|
- **Merge conflicts:** Report conflicting files. Suggest resolution steps appropriate to the conflict.
|
|
248
|
-
- **Nothing to commit:** If all artifacts were already committed, this is fine — mark the stage `complete`, leave `commitHash` at its existing value (or `null` if there was never an artifact commit), and skip Commit 2. There is no new artifact commit to record.
|
|
335
|
+
- **Nothing to commit:** If all artifacts were already committed, this is fine — mark the stage `complete`, leave `commitHash` at its existing value (or `null` if there was never an artifact commit), and skip Commit 2. Pass `--preserve-commit-hash` on the Commit-1 `state-complete` call so the recorded hash is left alone instead of being reset to `null`. There is no new artifact commit to record.
|
|
249
336
|
5. **Never** use `git add -A`, `--amend`, `--no-verify`, or `--force` flags
|
|
250
337
|
|
|
338
|
+
The two `state-complete` calls, with the portable plugin-root prelude. Add `--epic "{epic}"` to each when this feature is an epic member — required, per the Pipeline State Protocol:
|
|
339
|
+
|
|
340
|
+
```bash
|
|
341
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
342
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
343
|
+
# Commit 1 — before `git commit`
|
|
344
|
+
python3 "$R/scripts/forge-session.py" state-complete \
|
|
345
|
+
--feature "{feature}" --stage "{stage}" --version {n} \
|
|
346
|
+
--based-on "<upstream>=<n>" --artifact "<file>" --specs-dir "{specsDir}"
|
|
347
|
+
# Commit 2 — after Commit 1 lands, so its hash exists
|
|
348
|
+
python3 "$R/scripts/forge-session.py" state-complete \
|
|
349
|
+
--feature "{feature}" --stage "{stage}" --version {n} \
|
|
350
|
+
--commit-hash "$(git rev-parse HEAD)" --specs-dir "{specsDir}"
|
|
351
|
+
```
|
|
352
|
+
|
|
251
353
|
## Stage-Entry Guard
|
|
252
354
|
|
|
253
355
|
Invoke this block at the **start of an authoring stage** (`forge-1-prd`..`forge-4-backlog`), **after** Feature Directory Resolution and **before** any interview or (re-)authoring. It prevents a re-entered stage — an injected skill body or a re-invoked `Skill` — from blindly re-running the interview over an in-progress or already-complete draft. `{stage}` is the invoking skill's id (e.g. `forge-2-tech`).
|
|
@@ -263,16 +365,27 @@ Invoke this block at the **start of an authoring stage** (`forge-1-prd`..`forge-
|
|
|
263
365
|
|
|
264
366
|
3. **Re-authoring** (`status: "complete"` or `"stale"`) — a finished draft exists. Warn via `AskUserQuestion` before overwriting: "A completed {stage} artifact already exists for '{feature}' (v{n}{, marked stale}). Continuing will create a new version. Proceed?" On confirm, proceed to the Entry Stamp and author a new version (the version increments at exit, per that stage's Update-Pipeline-State step).
|
|
265
367
|
|
|
266
|
-
**Entry Stamp** (fresh, restart, and re-author paths — NOT the resume path). Before authoring, write
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
368
|
+
**Entry Stamp** (fresh, restart, and re-author paths — NOT the resume path). Before authoring, record the entry stamp by running `state-enter` — one atomic write that sets `stages.{stage}.status` → `"in-progress"`, `stages.{stage}.startedAt` → current ISO-8601 UTC timestamp, top-level `currentStage` → `"{stage}"` (where the pipeline IS, per O1), and refreshes `updatedAt`. Add `--epic "{epic}"` when this feature is an epic member — required, per the Pipeline State Protocol:
|
|
369
|
+
|
|
370
|
+
```bash
|
|
371
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
372
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
373
|
+
python3 "$R/scripts/forge-session.py" state-enter \
|
|
374
|
+
--feature "{feature}" --stage "{stage}" --specs-dir "{specsDir}"
|
|
375
|
+
```
|
|
270
376
|
|
|
271
377
|
This write is **left uncommitted**: it is staged and committed as part of this stage's existing exit commit (Git Commit Protocol), so no extra commit is needed at entry. If the run is interrupted after the stamp but before the exit commit, the marker survives on disk (uncommitted) and the next entry classifies as **Interrupted** — which is exactly the intent.
|
|
272
378
|
|
|
273
379
|
**Force Mode.** When `--force` is passed, skip the interactive gate: do not prompt for resume-vs-restart or the re-author warning. Treat entry as a fresh restart — apply the Entry Stamp and author. (`--force` already skips prerequisite checks; here it likewise bypasses the self-stage gate. Existing on-disk artifacts are still loaded per Force Mode.)
|
|
274
380
|
|
|
275
|
-
**Incremental artifact tracking:** When a stage writes multiple files (e.g. forge-3-specs writing a suite of spec documents),
|
|
381
|
+
**Incremental artifact tracking:** When a stage writes multiple files (e.g. forge-3-specs writing a suite of spec documents), run `state-artifact --feature {feature} --stage {stage} --path <file>` after writing each file — not just at stage completion. This is what makes the Interrupted inventory above precise about which files were successfully written. Add `--epic "{epic}"` when this feature is an epic member — required, per the Pipeline State Protocol.
|
|
382
|
+
|
|
383
|
+
```bash
|
|
384
|
+
R="$(bash -c 'for d in "${CLAUDE_PLUGIN_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
385
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
386
|
+
python3 "$R/scripts/forge-session.py" state-artifact \
|
|
387
|
+
--feature "{feature}" --stage "{stage}" --path "<file>" --specs-dir "{specsDir}"
|
|
388
|
+
```
|
|
276
389
|
|
|
277
390
|
## Stage-Completion Re-check
|
|
278
391
|
|
|
@@ -26,21 +26,23 @@ This skill is delegated to the `forge-verifier` subagent via the host's subagent
|
|
|
26
26
|
|
|
27
27
|
Pick based on how many checks the mode carries (see the per-mode totals in Step 3):
|
|
28
28
|
|
|
29
|
-
- **Small modes (prd
|
|
29
|
+
- **Small modes (prd 15, tech 17): single verifier.** Use the host's subagent mechanism once with
|
|
30
30
|
`the forge-verifier custom agent`, passing the feature name and mode. It runs all
|
|
31
31
|
checks and returns findings.
|
|
32
|
-
- **Large modes (specs
|
|
32
|
+
- **Large modes (specs 38, backlog 27, impl 23): parallel dimensioned fan-out.**
|
|
33
33
|
Split the mode's checklist into **dimension groups** and dispatch **one
|
|
34
34
|
`forge-verifier` per group, in parallel — a single message with multiple subagent
|
|
35
35
|
calls** (the `superpowers:dispatching-parallel-agents` pattern). Each instance owns a
|
|
36
36
|
disjoint slice of CHECK-IDs, so it verifies deeper over a narrower scope and they all
|
|
37
|
-
run concurrently. Suggested groups (map to the category clusters in
|
|
38
|
-
|
|
39
|
-
- **specs
|
|
37
|
+
run concurrently. Suggested groups (map to the category clusters in that mode's own
|
|
38
|
+
checklist file):
|
|
39
|
+
- **specs** (`references/verification-checklists/specs.md`): (1) types/contracts,
|
|
40
|
+
(2) architecture/layout, (3) cross-reference &
|
|
40
41
|
traceability, (4) testing strategy, (5) integration.
|
|
41
|
-
- **backlog
|
|
42
|
+
- **backlog** (`references/verification-checklists/backlog.md`): (1) item scoping &
|
|
43
|
+
acceptance criteria, (2) dependency/ordering sanity,
|
|
42
44
|
(3) spec coverage & traceability, (4) schema/enum correctness.
|
|
43
|
-
- **impl
|
|
45
|
+
- **impl** (`references/verification-checklists/impl.md`): (1) requirement coverage vs specs, (2) integration correctness,
|
|
44
46
|
(3) testing, (4) code-quality/conventions, (5) runnability (owns CHECK-I21/I22 —
|
|
45
47
|
the smoke command and the non-test-caller heuristic).
|
|
46
48
|
|
|
@@ -97,7 +99,7 @@ any work:
|
|
|
97
99
|
> `CLEAN_ROOM_UNAVAILABLE: forge-verifier subagent not dispatchable — verify not run.`
|
|
98
100
|
|
|
99
101
|
Do not analyze artifacts, do not write a findings document, and do not touch pipeline
|
|
100
|
-
state. The navigator detects this sentinel and degrades to its manual verify gate (Tier
|
|
102
|
+
state. This is an **operational failure, not a user skip** — close through Step 7 with `--outcome failed`; as a nested owner that call writes no state and prints no terminal block, so the sentinel is your structured result. The navigator detects this sentinel and degrades to its manual verify gate (Tier
|
|
101
103
|
2/3), so verify state stays outstanding and the stage is never marked verified on false
|
|
102
104
|
assurance. **Manual / interactive invocation** (the normal `/feature-forge:forge-verify`
|
|
103
105
|
path, no require-clean signal) keeps the inline fallback above unchanged.
|
|
@@ -108,6 +110,8 @@ Read and follow `references/shared-conventions.md` for feature name validation,
|
|
|
108
110
|
|
|
109
111
|
Resolve the feature directory via the **Feature Directory Resolution** block in `references/shared-conventions.md` (so a standalone feature resolves to its flat `{specsDir}/{feature}/` path exactly as today, and an epic member resolves to its nested `{specsDir}/{epic}/{feature}/` path). Use the resulting `{resolvedFeatureDir}` everywhere this skill reads or writes a per-feature artifact or state file — the `{specsDir}/{feature}/…` forms below are shorthand for the resolved path, not a literal flat layout. This does not apply to **epic mode**, whose paths are epic-scoped (`{specsDir}/{epic}/…`) by design.
|
|
110
112
|
|
|
113
|
+
Determine branch ownership **at entry**, from the literal `owner: nested` / `owner: direct` token in the dispatching prompt (absent the token you are `direct`), and preserve that value unchanged through any re-verify — see Step 7, which passes it through as `--owner`.
|
|
114
|
+
|
|
111
115
|
**Turn structure reminder:** Output analysis/context as text, then route ALL questions through the host's question mechanism. Never embed questions in text output — the user will not be prompted and the session will stall.
|
|
112
116
|
|
|
113
117
|
## Step 1: Read Configuration and Determine Mode
|
|
@@ -116,7 +120,9 @@ Read `{resolvedFeatureDir}/.pipeline-state.json` to understand current pipeline
|
|
|
116
120
|
|
|
117
121
|
### Mode Selection
|
|
118
122
|
|
|
119
|
-
|
|
123
|
+
An explicit `--served-stage <production-stage>` argument on this invocation is authoritative — it is what the scripted exit and forge-fix pass when they route back here (the fix rejoin fences `/feature-forge:forge-verify {feature} --served-stage {stage}`). Map it to the mode directly (`forge-0-epic`→epic, `forge-1-prd`→prd, `forge-2-tech`→tech, `forge-3-specs`→specs, `forge-4-backlog`→backlog, `forge-5-loop`→impl) and skip auto-detection.
|
|
124
|
+
|
|
125
|
+
Otherwise, if a stage is specified as a second argument (e.g., `/feature-forge:forge-verify auth specs`), use that mode. Otherwise, auto-detect based on pipeline state:
|
|
120
126
|
|
|
121
127
|
- **epic mode**: Explicit via `/feature-forge:forge-verify {epic} epic`, or auto-detected when the named argument resolves to an **epic directory** — i.e. `{specsDir}/{name}/epic-manifest.json` exists (an epic root holds `epic-manifest.json` but no `.pipeline-state.json` of its own). When the argument is an epic, prefer epic mode over feature-mode resolution.
|
|
122
128
|
- **prd mode**: If `forge-1-prd` is complete but `forge-verify-prd` is not `passed` or `findings-applied`
|
|
@@ -125,7 +131,7 @@ If a stage is specified as a second argument (e.g., `/feature-forge:forge-verify
|
|
|
125
131
|
- **backlog mode**: If `forge-4-backlog` is complete but `forge-verify-backlog` is not `passed` or `findings-applied`
|
|
126
132
|
- **impl mode**: If user explicitly requests or if implementation code exists for this feature
|
|
127
133
|
|
|
128
|
-
If ambiguous, use the host's question mechanism to ask which stage to verify.
|
|
134
|
+
If ambiguous, use the host's question mechanism to ask which stage to verify — **before any write**. Serialize the resolved mode as `--verify-mode` at Step 7: that mode, never conversational context and never `currentStage`, determines the served production stage.
|
|
129
135
|
|
|
130
136
|
## Step 2: Load All Relevant Artifacts
|
|
131
137
|
|
|
@@ -160,11 +166,11 @@ Load into context ALL artifacts for this feature based on mode:
|
|
|
160
166
|
|
|
161
167
|
## Step 3: Run Verification Checklists
|
|
162
168
|
|
|
163
|
-
Read `references/verification-checklists.md` for the detailed checklists
|
|
169
|
+
Read `references/verification-checklists/{mode}.md` for the detailed checklist for the mode being verified — one of `references/verification-checklists/prd.md`, `references/verification-checklists/tech.md`, `references/verification-checklists/specs.md`, `references/verification-checklists/backlog.md`, `references/verification-checklists/impl.md`, `references/verification-checklists/epic.md`. Read only that mode's file. Execute every check. Do not skip checks because things "look fine." **Exception — a re-verify is scoped, not a fresh sweep:** when the served stage's verify entry is `findings-applied`, follow "Re-verify scope and convergence" in `references/stage-exit-protocol.md` — confirm the prior report's findings against their acceptance evidence and examine the fix's own delta; only an unresolved prior finding or a new blocking defect the fix itself introduced may block, every other observation is advisory, and a finding with a recorded decision is never re-filed. The orchestrator-only **Findings Document Template (Step 4)**, worked **Example Findings (Step 4)**, and **Epic Mode State Write Detail (Step 6)** sections live in `references/findings-template.md`, read later by the parent role at Steps 4/6.
|
|
164
170
|
|
|
165
|
-
Each check in
|
|
171
|
+
Each check in that mode checklist has a unique ID (CHECK-P01, CHECK-T01, CHECK-S01, CHECK-B01, etc.). As you execute each check, record its ID and result (pass/fail/not-applicable). After completing all checks, report the total: "Executed N of M checks. Results: X pass, Y fail, Z not-applicable." If your count is significantly below the expected total for the mode (prd: 15 checks, tech: 17 checks, specs: 38 checks, backlog: 27 checks, impl: 23 checks, epic: 10 checks), you likely skipped checks — go back and complete them.
|
|
166
172
|
|
|
167
|
-
**Epic mode dispatch.** Epic mode is a small (
|
|
173
|
+
**Epic mode dispatch.** Epic mode is a small (10-check) checklist, so per the single-vs-parallel rule above, dispatch a **single `forge-verifier`** via the host's subagent mechanism, passing the epic name and `mode=epic`. The verifier runs CHECK-E01..E10 from the `## Epic Mode Checklist` in `references/verification-checklists/epic.md` (E01/E02/E03/E08 are delegated to `epic-manifest.py validate`/`check-name`; E04–E07, E09, and E10 are verifier judgment) and returns its findings.
|
|
168
174
|
|
|
169
175
|
### Important: Be Specific, Not General
|
|
170
176
|
|
|
@@ -173,7 +179,13 @@ GOOD finding: "PRD.md REQ-ERR-04 requires rate limit retry behavior, but spec 03
|
|
|
173
179
|
|
|
174
180
|
Every finding must include:
|
|
175
181
|
1. A unique ID (V-001, V-002, etc.)
|
|
176
|
-
2. Severity: `gap` (missing requirement coverage), `inconsistency` (contradictory specs), `improvement` (not wrong but could be better), `error` (factually incorrect)
|
|
182
|
+
2. Severity: `gap` (missing requirement coverage), `inconsistency` (contradictory specs), `improvement` (not wrong but could be better), `error` (factually incorrect **with a behavioral, CLI-output, or decision-bearing consequence**)
|
|
183
|
+
|
|
184
|
+
**Severity floor (anti-churn).** An inaccuracy confined to comments, docstrings, or test narration — prose no runtime path executes and no decision consumes — caps at `inconsistency`, never `error`. It is worth recording, but a wrong sentence beside correct code does not block a stage the way wrong behavior does. **Routing consequence:** `error` and `gap` are the two **blocking** severities; `inconsistency` and `improvement` are **advisory**. A report with at least one blocking finding records `findings-reported` and routes to forge-fix. A report whose findings are all advisory records `passed` **with the report still attached** (Step 6) and the pipeline advances — an advisory-only report never fences a fix round. A **meta-guard** (a test protecting other tests or prose) is judged against its declared protection set: guard-incompleteness against a declared non-goal is never a finding (`references/stage-exit-protocol.md` § Re-verify scope).
|
|
185
|
+
|
|
186
|
+
**A checklist item with no PRD position behind it is a PRD gap, not a design to invent.** Several checks are deliberately conditional — `CHECK-S27` ("Concurrent access scenarios are addressed **if relevant**") is the clearest, and the same shape appears for performance, observability, and security checks that defer to the PRD. When such a check fires and the PRD takes **no position** on the concern, the finding is that the *requirements* are silent. Report it as an `improvement` (or a `gap` against the PRD, in `prd` mode) whose suggested fix is to **record the position** — including "out of scope, single writer assumed", which is a complete answer. Do **not** specify a mechanism to satisfy the check: a verifier that answers an open requirements question by designing a protocol converts a one-sentence PRD amendment into a foundational change that no requirement asked for, at the stage where it is least visible. Precedent both ways: `epic-orchestration` V-008 raised `CHECK-S27` against a PRD that *had* scoped concurrency out and correctly cost one sentence at `improvement`; `stage-exit-coverage` V-006 raised the same check against a silent PRD, was filed as a `gap`, and induced a full locking protocol that was later removed.
|
|
187
|
+
|
|
188
|
+
Relatedly, **do not let `improvement` fall out of use.** A report containing only `gap`/`error`/`inconsistency` usually means observations that should have been `improvement` were promoted into must-fix findings. If a finding would not block implementation, it is an `improvement` — say so.
|
|
177
189
|
3. Exact location (file + section)
|
|
178
190
|
4. What's wrong
|
|
179
191
|
5. Suggested fix (specific enough that a fresh agent can apply it)
|
|
@@ -182,13 +194,13 @@ Every finding must include:
|
|
|
182
194
|
|
|
183
195
|
## Step 4: Write Findings Document
|
|
184
196
|
|
|
185
|
-
Ensure the `.verification/` subdirectory exists, then write findings to `{resolvedFeatureDir}/.verification/VERIFY-{mode}-{YYYY-MM-DD}.md`.
|
|
197
|
+
Ensure the `.verification/` subdirectory exists, then write findings to `{resolvedFeatureDir}/.verification/VERIFY-{mode}-{YYYY-MM-DD}.md`. **Never overwrite an existing report:** if that name already exists (an earlier round the same day), write `VERIFY-{mode}-{YYYY-MM-DD}-round{N}.md` with the smallest `N ≥ 2` not yet on disk — each round's report and Fix Progress is an audit record later rounds and the round ledger (`references/stage-exit-protocol.md` § Escalation) read.
|
|
186
198
|
|
|
187
|
-
**For epic mode**, the target is `{specsDir}/{epic}/.verification/VERIFY-epic-{YYYY-MM-DD}.md` (the same format, with `{mode}=epic`).
|
|
199
|
+
**For epic mode**, the target is `{specsDir}/{epic}/.verification/VERIFY-epic-{YYYY-MM-DD}.md` (the same format and the same no-overwrite round rule, with `{mode}=epic`).
|
|
188
200
|
|
|
189
201
|
The full findings-document template (report header, `V-NNN` finding shape, and the
|
|
190
202
|
Fix Execution Plan layout) and the worked **Example Findings** (gap / inconsistency /
|
|
191
|
-
improvement) live in `references/
|
|
203
|
+
improvement) live in `references/findings-template.md` under the **Findings
|
|
192
204
|
Document Template (Step 4)** and **Example Findings (Step 4)** sections — follow that
|
|
193
205
|
template verbatim when writing the document.
|
|
194
206
|
|
|
@@ -207,43 +219,73 @@ When building the Fix Execution Plan:
|
|
|
207
219
|
**If not in plan mode:** Output the following as text:
|
|
208
220
|
"Findings and fix plan written to `{findings-file}`."
|
|
209
221
|
|
|
210
|
-
|
|
222
|
+
**Advisory-only reports skip the question.** When the report contains no blocking finding (`error`/`gap`), there is nothing to route to forge-fix: do not present the fix options below — state that the report is advisory-only, record `passed` with the report attached (Step 6), and continue; the advisories stay discoverable in the findings document for whoever next touches the artifact. Otherwise (at least one blocking finding), use the host's question mechanism to ask how to proceed — **unless this report closes the SECOND consecutive `reverify-findings` for this served stage** (count the round-discriminated reports in `.verification/`), in which case follow "Escalation (the round ledger)" in `references/stage-exit-protocol.md` instead: present the digest and recommend explicit acceptance of the residual findings, never another fix pass. Otherwise follow the **Decision Support** protocol in `references/shared-conventions.md`: recommend a path based on the findings and give each option a one-line trade-off. Let the severity and volume of findings drive the recommendation — e.g. recommend (b) **Apply fixes now** when findings are clear-cut and mechanical; recommend (a) **Review first** when findings involve design judgment or you flagged low-confidence items; recommend (c) **plan-mode workflow** when the fixes are large or interdependent enough to warrant a reviewed plan. Present:
|
|
211
223
|
- **(a) Review the findings first** — read `{findings-file}` and decide per-finding; safest, but you act on nothing until you return.
|
|
212
|
-
- **(b) Run `/feature-forge:forge-fix {feature}` now** — applies the fix plan immediately; fastest, best when findings are unambiguous.
|
|
224
|
+
- **(b) Run `/feature-forge:forge-fix {feature} --served-stage {servedStage}` now** — applies the fix plan immediately; fastest, best when findings are unambiguous.
|
|
213
225
|
- **(c) Enter plan mode and re-run `/feature-forge:forge-verify {feature}`** — produces a reviewable plan before any edits; best for large or risky fix sets.
|
|
214
226
|
|
|
215
227
|
Do NOT embed this question in your text output.
|
|
216
228
|
|
|
217
|
-
## Step 6:
|
|
229
|
+
## Step 6: Record the Result Through `state-verify`
|
|
218
230
|
|
|
219
|
-
|
|
231
|
+
Never hand-author a verify entry. Every `stages.forge-verify-*` transition is written by the `state-verify` verb described in the **Pipeline State Protocol** in `references/shared-conventions.md`, which owns its full flag surface, its status matrix, and the exit-2 failure protocol. Write `findings-reported` when the report lists at least one **blocking** finding (`error`/`gap`); write `passed` when it lists none — including an **advisory-only** report (`inconsistency`/`improvement` findings only), which records `passed` with the report still attached: pass `--findings-file` and `--findings-count` alongside `--status passed` so the advisories remain discoverable without blocking the stage. (One exception routes blocking findings to `passed`: residual findings the user explicitly accepted at the round-ledger escalation — recorded first as a `state-decision`, then `passed` with the report attached, per "Escalation" in `references/stage-exit-protocol.md`.) Never write `findings-applied` here — that belongs to the fix pass. `--stage` names the **served production stage** (Step 1's mode, mapped through the served-stage mapping in Step 7), `--findings-file` is the report path **relative to** the feature directory (the Step 4 filename, round discriminator included), and `--verified-stage-version` is that production stage entry's current `version`, so a later revision of the artifact makes this verification read stale and re-fires. Add `--epic "{epic}"` when the feature is an epic member — required, per the Pipeline State Protocol; omitting it for a member is an error and must never fall back to a same-named flat feature.
|
|
220
232
|
|
|
221
|
-
|
|
222
|
-
-
|
|
223
|
-
|
|
224
|
-
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
233
|
+
```bash
|
|
234
|
+
R="$(bash -c 'for d in "${FEATURE_FORGE_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
235
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
236
|
+
python3 "$R/scripts/forge-session.py" state-verify \
|
|
237
|
+
--feature "{feature}" --stage "{servedStage}" --status "{passed|findings-reported}" \
|
|
238
|
+
--findings-file "{relative findings path}" --findings-count {n} \
|
|
239
|
+
--verified-stage-version {version} --specs-dir "{specsDir}"
|
|
240
|
+
```
|
|
241
|
+
|
|
242
|
+
**Two-commit provenance — never `--amend`.** The write above records `commitHash: null`. Commit 1 records the findings document and the state together (Git Commit Protocol, `references/shared-conventions.md`). Then record the provenance of that commit in Commit 2, passing the **full 40-character** hash of Commit 1 — an abbreviation is refused rather than expanded, and this call touches nothing but `commitHash`. Add `--epic "{epic}"` when the feature is an epic member — required, per the Pipeline State Protocol.
|
|
243
|
+
|
|
244
|
+
```bash
|
|
245
|
+
R="$(bash -c 'for d in "${FEATURE_FORGE_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
246
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
247
|
+
python3 "$R/scripts/forge-session.py" state-verify \
|
|
248
|
+
--feature "{feature}" --stage "{servedStage}" \
|
|
249
|
+
--commit-hash "$(git rev-parse HEAD)" --specs-dir "{specsDir}"
|
|
250
|
+
```
|
|
231
251
|
|
|
232
|
-
|
|
252
|
+
On exit 2 **nothing was recorded**: surface the `Error:` line verbatim together with the named feature (and epic), do not claim the result was persisted, and close the stage with `--outcome failed` in Step 7 — the verify entry is unchanged, so no success block may be printed.
|
|
233
253
|
|
|
234
254
|
### Epic mode state (`.epic-state.json`)
|
|
235
255
|
|
|
236
|
-
Epic mode is **epic-scoped**, not per-feature:
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
`
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
(
|
|
245
|
-
|
|
246
|
-
|
|
256
|
+
Epic mode is **epic-scoped**, not per-feature: `--stage forge-0-epic` writes `{specsDir}/{epic}/.epic-state.json` and **never** any member's `.pipeline-state.json`. It is the one exception to the member rule — `--feature` names the **epic**, and `--epic` must be absent or exactly equal to it — and its `--verified-stage-version` is the epic manifest's `revision`, never a member's stage version. The exact call and the minimal written shape live in `references/findings-template.md` under the **Epic Mode State Write Detail (Step 6)** section. Follow it verbatim.
|
|
257
|
+
|
|
258
|
+
## Step 7: Close the Stage
|
|
259
|
+
|
|
260
|
+
**Ownership.** Read branch ownership from the literal `owner: nested` / `owner: direct` token in the prompt that dispatched you. **Absent the token you are `direct`** — a user-typed `/feature-forge:forge-verify` is the only path that carries no dispatcher. Never infer ownership from how the invocation happened to be phrased; judge the token, not the wording. Pass the resolved value straight through as `--owner`, and preserve it through any re-verify. As a **nested** owner you return your structured result (mode, served stage, outcome, findings file, findings count) to the caller and print **no terminal block at all** — the outer authoring stage is the sole terminal owner. As a **direct** owner you print the script's NEXT-STEPS block verbatim as your absolute final output, with nothing after its sentinel line. `references/stage-exit-protocol.md` § "Branch ownership: the `owner:` token" owns this rule.
|
|
261
|
+
|
|
262
|
+
**Served stage.** Pass `--verify-mode` carrying Step 1's explicit or auto-detected mode (`epic`, `prd`, `tech`, `specs`, `backlog`, `impl`); the script maps it to the served production stage. When the caller already owns a stage and states it, additionally pass that value as `--served-stage` — if the two disagree the script fails closed rather than guessing. Derive the served stage **only** from that mode argument or from authoritative pipeline state: conversational context and `currentStage` are never valid inference sources.
|
|
263
|
+
|
|
264
|
+
**Capability.** Pass `--verify-capability interactive` only when **both** a question mechanism equivalent to the host's question mechanism is available **and** a clean-room `forge-verifier` may actually be dispatched right now. Clause (b) tests **permitted dispatch, not a listed tool**: a session that may dispatch only when the user asked, but does have a question mechanism, is `interactive` — the gate's affirmative choice supplies the request. Reserve `manual` for **no** question mechanism **and** **no** permitted dispatch. An auto-verify directive under a no-unsolicited-dispatch bar is presented through the gate and dispatched on the affirmative choice — never skipped, and never resolved by advancing to the production successor.
|
|
265
|
+
|
|
266
|
+
**Outcome.** Invoke the exit **exactly once**, with the `--outcome` this run's result maps to:
|
|
267
|
+
|
|
268
|
+
| This run's result | `--outcome` |
|
|
269
|
+
|---|---|
|
|
270
|
+
| Zero findings — the artifacts are clean | `passed` |
|
|
271
|
+
| Advisory-only report (no `error`/`gap`) — recorded `passed` with the report attached | `passed` |
|
|
272
|
+
| A report with at least one blocking finding (`error`/`gap`) was written | `findings` |
|
|
273
|
+
| The user explicitly chose to defer pipeline action **and** that skip was persisted via `state-verify --status skipped` | `skipped` |
|
|
274
|
+
| A dispatch, a check, or a state write failed and needs intervention | `failed` |
|
|
275
|
+
|
|
276
|
+
Merely **presenting** blocking findings is `findings`, not `skipped` — all three Step 5 options are `findings`, including (a) "review the findings first", which defers *your* next action rather than the pipeline's. `skipped` is available only for an explicit user deferral of **pipeline action** whose skip has already been persisted. A `CLEAN_ROOM_UNAVAILABLE` sentinel or a non-answer from an advertised dispatch is an operational failure, not a user skip: it is `failed`. A state-write failure is `failed`, and no success block may be printed after one.
|
|
277
|
+
|
|
278
|
+
Add `--epic "{epic}"` when the feature is an epic member, and `--served-stage "{servedStage}"` when the caller supplied one. Pass no other flags.
|
|
279
|
+
|
|
280
|
+
**Close this stage with the Scripted Stage Exit** (contract: `references/stage-exit-protocol.md`; do not improvise a "Next steps" list). Run:
|
|
281
|
+
|
|
282
|
+
```bash
|
|
283
|
+
R="$(bash -c 'for d in "${FEATURE_FORGE_ROOT:-}" "$HOME"/.claude/skills/feature-forge "$HOME"/.claude/plugins/cache/*/feature-forge/* "$HOME"/.claude/plugins/*/feature-forge "$HOME"/.agents/skills/feature-forge ./.agents/skills/feature-forge; do [ -x "$d/scripts/forge-root.sh" ] && exec "$d/scripts/forge-root.sh"; done')"
|
|
284
|
+
[ -n "$R" ] || { echo "feature-forge: cannot locate plugin root" >&2; exit 1; }
|
|
285
|
+
python3 "$R/scripts/forge-session.py" stage-exit --feature "{feature}" --stage forge-verify --owner "{owner}" --outcome "{VerifyOutcome}" --verify-mode "{mode}" --specs-dir "{specsDir}" --host generic --verify-capability "{verify-capability}"
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
Obey the DIRECTIVES it prints, in the consumption order this protocol fixes: surface `invalidAutoVerifyKeys` and every `warnings` entry first; `runInStageVerify: true` → run the in-stage clean-room verify chain now (honoring `autoFixEligible`, and asking through the Standard Verify Gate first when you may not dispatch unsolicited); `verifyGate: "standard"` → present the Standard Verify Gate; `verifyGate: "manual-print"` → print the `verifyCommand` for the user and do **not** dispatch inline. Then, and only when `terminalOwnedBy` is `"self"`, **print the NEXT-STEPS block verbatim as your absolute last output — nothing after its sentinel line.** A `terminalOwnedBy: "outer"` payload carries `nextSteps: null`: return your structured result to the caller and print no terminal block at all.
|
|
247
289
|
|
|
248
290
|
## Gotchas
|
|
249
291
|
|