Problem
The self-build loop ships loop plumbing because its deterministic lane is empty (#355), and there is no path at all from what the operator writes in docs/PRD.md to implemented work. Today a human PRD edit either (a) blocks the loop ([prd-fresh] … operator mid-edit, skipping iteration, internal/loopdriver/run.go:232) or (b) is ignored: the only PRD→work parser (pipeline.ParseBacklogItems) is reachable only from devagent task --pick, which the loop never calls (internal/loopdriver/dispatch.go:474 passes --prompt).
Requested change
A PRD intake step: an operator-authored open checkbox in docs/PRD.md becomes a queue row the next iteration claims.
internal/prdintake: parse - [ ] … items (heading context + indented sub-bullets as acceptance criteria), skipping fenced code blocks and struck/completed lines; deterministic id PRD-<sha8> so re-runs dedupe against the existing queue store.
- Goal text must satisfy the dispatch contract (
Goal: prefix, ≤120 words, internal/loopdriver/dispatch.go:450); the section body rides along as the queue task-PRD sidecar so the worker reads the real spec, not just the bullet.
devagent prd-intake [--dry-run] [--json] [--max N] [--issues] prints what it queued.
- Loop wiring: intake runs at iteration head (after the PRD-currency gate, before
claimQueueTask), SELFBUILD_PRD_INTAKE=0 disables.
- Dispatch rider tells the worker to tick the source checkbox to
- [x] in the same PR, so a shipped item never re-enters the lane.
Acceptance
- A new
- [ ] bullet committed to docs/PRD.md is enqueued and claimed by the next devagent loop iteration; running intake twice enqueues once.
- [x], struck, and code-fence examples are never queued.
- Unit tests for the parser (context, nesting, fences, idempotent ids) and the ingest dedupe.
Problem
The self-build loop ships loop plumbing because its deterministic lane is empty (#355), and there is no path at all from what the operator writes in
docs/PRD.mdto implemented work. Today a human PRD edit either (a) blocks the loop ([prd-fresh] … operator mid-edit, skipping iteration,internal/loopdriver/run.go:232) or (b) is ignored: the only PRD→work parser (pipeline.ParseBacklogItems) is reachable only fromdevagent task --pick, which the loop never calls (internal/loopdriver/dispatch.go:474passes--prompt).Requested change
A PRD intake step: an operator-authored open checkbox in
docs/PRD.mdbecomes a queue row the next iteration claims.internal/prdintake: parse- [ ] …items (heading context + indented sub-bullets as acceptance criteria), skipping fenced code blocks and struck/completed lines; deterministic idPRD-<sha8>so re-runs dedupe against the existing queue store.Goal:prefix, ≤120 words,internal/loopdriver/dispatch.go:450); the section body rides along as the queue task-PRD sidecar so the worker reads the real spec, not just the bullet.devagent prd-intake [--dry-run] [--json] [--max N] [--issues]prints what it queued.claimQueueTask),SELFBUILD_PRD_INTAKE=0disables.- [x]in the same PR, so a shipped item never re-enters the lane.Acceptance
- [ ]bullet committed todocs/PRD.mdis enqueued and claimed by the nextdevagent loopiteration; running intake twice enqueues once.- [x], struck, and code-fence examples are never queued.