$npx -y skills add WILLOSCAR/research-units-pipeline-skills --skill deliverable-selfloopScore an existing reader-facing deliverable and emit a deterministic PASS/FAIL scorecard plus bounded repair plan; use after synthesis, not to rewrite content.
| 1 | # Deliverable Self-Loop |
| 2 | |
| 3 | Runs the final quality gate for a reader-facing deliverable and always writes a PASS/FAIL report. |
| 4 | |
| 5 | ## Inputs |
| 6 | |
| 7 | Primary input depends on the active pipeline contract: |
| 8 | - brief deliverable |
| 9 | - paper-review deliverable |
| 10 | - evidence-review deliverable |
| 11 | - idea memo bundle |
| 12 | - tutorial deliverable |
| 13 | |
| 14 | ## Output |
| 15 | |
| 16 | - `output/DELIVERABLE_SELFLOOP_TODO.md` |
| 17 | - for `research-brief`: `output/BRIEF_SCORECARD.md` and `output/BRIEF_SCORECARD.json` |
| 18 | - for `paper-review`: `output/REVIEW_SCORECARD.md` and `output/REVIEW_SCORECARD.json` |
| 19 | - for `idea-brainstorm`: `output/IDEA_SCORECARD.md` and `output/IDEA_SCORECARD.json` |
| 20 | - for `evidence-review`: `output/EVIDENCE_SCORECARD.md` and `output/EVIDENCE_SCORECARD.json` |
| 21 | |
| 22 | ## Dispatch rule |
| 23 | |
| 24 | The gate should dispatch by pipeline contract first: |
| 25 | - `quality_contract.deliverable_kind` |
| 26 | |
| 27 | Only fall back to legacy profile-name checks when contract metadata is missing. |
| 28 | |
| 29 | ## Script boundary |
| 30 | |
| 31 | `scripts/run.py` should: |
| 32 | - detect the active deliverable contract |
| 33 | - run the matching evaluator |
| 34 | - always write a report |
| 35 | |
| 36 | It should not mutate the deliverable itself. |
| 37 | |
| 38 | ## Acceptance |
| 39 | |
| 40 | - report exists |
| 41 | - report contains `- Status: PASS` or `- Status: FAIL` |
| 42 | - PASS only when the active deliverable satisfies its minimum section / artifact contract |
| 43 | - `research-brief` additionally requires valid core-set pointers and the configured score threshold |
| 44 | - `paper-review` additionally requires the configured score threshold and all critical rubric dimensions |
| 45 | - `idea-brainstorm` additionally requires traceable anchors, actionable lead directions, and the configured score threshold |
| 46 | - `evidence-review` additionally requires clause-linked screening, complete extraction rows, synthesis pointers, and the configured score threshold |
| 47 | |
| 48 | ## Non-goals |
| 49 | |
| 50 | - rewriting the deliverable |
| 51 | - choosing upstream fixes beyond pointing to the missing contract items |