Skip to content

Prerequisite Gate

Before any task prefix runs (except management_status: and state:), the agent checks that upstream inputs and outputs exist.


What gets checked

  1. Required inputs — every entry in dept.yaml → inputs with required: true must exist in ../nepwalk-docs/.
  2. Prerequisite outputs — every entry in dept.yaml → outputs with required_before_work: true must exist and have status:draft.

What happens on failure

WARNING: prerequisites incomplete.
  [ ] docs/management/mvp/v1/PRD_v1.md (missing)
  [ ] docs/management/mvp/v1/SRS_v1.md (status: missing)
Proceed anyway? (yes / no)
  • no → stop. Fix the upstream doc first.
  • yes → continue, with a note added to PROJECT_STATE.md so the override is visible.

Why we have the gate

Skipping upstream docs produces specs that contradict each other. The gate keeps the doc chain coherent: PRD informed by idea, SRS informed by PRD, tasks informed by SRS.


When to override

Override only when the upstream doc is intentionally pending (e.g. parallel drafting) and you accept that the current doc may need rewrites once upstream lands. Record the reason in PROJECT_STATE.md → OPEN QUESTIONS.