Review requirements, plans, or specs with role-specific lenses. Use when the user wants to improve an existing planning document.
safe_auto fixes, and routes remaining findings through a four-option interaction (per-finding walk-through, auto-resolve with best judgment, Append-to-Open-Questions, Report-only) for user decision.AskUserQuestion is a deferred tool — its schema is not available at session start. At the start of Interactive-mode work (before the routing question, per-finding walk-through questions, bulk-preview Proceed/Cancel, and Phase 5 terminal question), call ToolSearch with query select:AskUserQuestion to load the schema. Load it once, eagerly, at the top of the Interactive flow — do not wait for the first question site. On Codex, Gemini, and Pi this preload is not required.ToolSearch returns no match, the tool call explicitly fails, or the runtime mode does not expose it (e.g., Codex edit modes where request_user_input is unavailable). A pending schema load is not a fallback trigger; call ToolSearch first per the pre-load rule. In genuine-fallback cases, present options as a numbered list and wait for the user's reply — never silently skip the question. Rendering a question as narrative text because the tool feels inconvenient, because the model is in report-formatting mode, or because the instruction was buried in a long skill is a bug. A question that calls for a user decision must either fire the tool or fall back loudly.mode:headless. Arguments may contain a document path, mode:headless, or both. Tokens starting with mode: are flags, not file paths — strip them from the arguments and use the remaining token (if any) as the document path for Phase 1.mode:headless is present, set headless mode for the rest of the workflow.safe_auto fixes are applied silently (same as interactive)gated_auto, manual, and FYI findings are returned as structured text for the caller to handle — no blocking-question prompts, no interactive routingmode:headless in the skill arguments, e.g.:Skill("ce-doc-review", "mode:headless docs/plans/my-plan.md")
mode:headless is not present, the skill runs in its default interactive mode with the routing question, walk-through, and bulk-preview behaviors documented in references/walkthrough.md and references/bulk-preview.md.docs/brainstorms/ or docs/plans/ using a file-search/glob tool (e.g., Glob in Claude Code).docs/plans/ should still classify as requirements, and a plan-shaped doc under docs/brainstorms/ should still classify as plan. The reviewers below operate differently depending on this classification, so misclassifying a plan-shaped doc as a requirements doc (or vice versa) produces noisy or under-scrutinized findings.artifact_contract: ce-unified-plan/v1 plus artifact_readiness: requirements-only -> classify as unified-requirements. Review the Product Contract only; the absence of Planning Contract, Implementation Units, Verification Contract, or Definition of Done is expected and must not be flagged.artifact_contract: ce-unified-plan/v1 plus artifact_readiness: implementation-ready -> classify as unified-plan. Review Product Contract and Planning Contract with different lenses, then review Implementation Units/Verification/DoD for execution completeness..html) are read/reviewed in report-only mode. Do not apply markdown mutation paths to HTML. If a caller requested mutation/autofix behavior, skip with the existing markdown-only message or return report-only findings.active, in_progress, completed, done) are a document-contract finding, not an execution state to honor.requirements signals (what-to-build documents):actors:, flows:, acceptance_examples:, or status: carrying brainstorm-shaped valuesAcceptance Examples, Actors, Key Flows, User Flows, Outstanding Questions, Resolve Before PlanningR1, R2, A1, F1, AE1 — requirement, actor, flow, and acceptance-example IDsplan signals (how-to-build documents):type: feat|fix|refactor, origin: docs/brainstorms/..., or product_contract_source: ce-brainstorm|ce-plan-bootstrap|legacy-requirementsImplementation Units, Output Structure, Key Technical Decisions, Risks & Dependencies, System-Wide ImpactU1, U2 — implementation unit IDsGoal, Files, Approach, Test scenarios, Verificationdocs/brainstorms/ → requirements, docs/plans/ → plan unless unified metadata says otherwise. When neither path location applies, treat the dominant content shape as authoritative; if shape is genuinely ambiguous, default to requirements (the more conservative classification — it activates fewer plan-specific feasibility checks).{document_type} slot in the subagent template. Personas read this and adapt their analysis accordingly.origin: requirements doc and no product_contract_source: ce-brainstorm or legacy-requirements) -- premise wasn't validated upstreamorigin: docs/brainstorms/..., product_contract_source: ce-brainstorm, and product_contract_source: legacy-requirements. A direct product_contract_source: ce-plan-bootstrap plan is greenfield and does not suppress premise-level techniques by itself. The plan's structural decisions (more units, more rationale) are not by themselves adversarial signal -- those are the plan doing its job.Reviewing with:
- coherence-reviewer (always-on)
- feasibility-reviewer (always-on)
- scope-guardian-reviewer -- plan has 12 requirements across 3 priority levels
- security-lens-reviewer -- plan adds API endpoints with auth flow
coherence-reviewerfeasibility-reviewerproduct-lens-reviewerdesign-lens-reviewersecurity-lens-reviewerscope-guardian-revieweradversarial-document-reviewerAgent in Claude Code, spawn_agent in Codex) where available; otherwise run the work inline or serially. Omit the mode parameter so the user's configured permission settings apply. Respect the current harness's active-subagent limit: queue selected reviewers, dispatch only as many as the harness accepts, and fill freed slots as reviewers complete. Treat active-agent/thread/concurrency-limit spawn errors as backpressure, not reviewer failure: leave the reviewer queued and retry after a slot frees. Record a reviewer as failed only after a successful dispatch times out/fails, or when dispatch fails for a non-capacity reason.references/personas/<reviewer-name>.md and pass its full content as {persona_file}. Do not dispatch standalone agents by type/name and do not rely on platform-level custom-agent registration.coherence-reviewer: cheapest capable extraction/reasoning tier.design-lens-reviewer, security-lens-reviewer, scope-guardian-reviewer: platform mid-tier model.feasibility-reviewer, product-lens-reviewer, adversarial-document-reviewer: inherit the parent model unless the harness has an established high-capability review tier.| Variable | Value |
|---|---|
{persona_file} | Full content of the selected local prompt asset from references/personas/ |
{schema} | Content of the findings schema included below |
{document_type} | "requirements", "plan", "unified-requirements", or "unified-plan" from Phase 1 classification |
{document_path} | Path to the document |
{origin_path} | Upstream Product Contract provenance extracted once during Phase 1: prefer the document's origin: frontmatter field when present; otherwise use product_contract_source:<value> when present; otherwise use none. Personas that adapt on origin/provenance (product-lens, adversarial, scope-guardian) read this slot to gate technique suppression — they do NOT re-parse frontmatter themselves. |
{document_content} | Reviewer-specific section slice. For unified artifacts, pass metadata, Goal Capsule, and only the relevant slice: product-lens/adversarial/scope reviewers get Product Contract; feasibility/coherence reviewers also get Planning Contract and active Implementation Units/Verification/DoD when artifact_readiness: implementation-ready. For legacy documents, pass the full document. |
{decision_primer} | Cumulative prior-round decisions in the current session, or an empty <prior-decisions> block on round 1. See "Decision primer" below. |
{document_content} slot above) are the default.
Escalate to a broader slice only when the reviewer needs cross-section
traceability that the initial slice cannot assess.{decision_primer} to:<prior-decisions>
Round 1 — no prior decisions.
</prior-decisions>
<prior-decisions>
Round 1 — applied (N entries):
- {section}: "{title}" ({reviewer}, {confidence})
Evidence: "{evidence_snippet}"
Round 1 — rejected (M entries):
- {section}: "{title}" — Skipped because {reason}
Evidence: "{evidence_snippet}"
- {section}: "{title}" — Deferred to Open Questions because {reason or "no reason provided"}
Evidence: "{evidence_snippet}"
- {section}: "{title}" — Acknowledged without applying because {reason or "no suggested_fix — user acknowledged"}
Evidence: "{evidence_snippet}"
Round 2 — applied (N entries):
...
</prior-decisions>
Evidence: line because synthesis R29 (rejected-finding suppression) and R30 (fix-landed verification) both use an evidence-substring overlap check as part of their matching predicate — without the evidence snippet in the primer, the orchestrator cannot compute the >50% overlap test and has to fall back to fingerprint-only matching, which either re-surfaces rejected findings or suppresses too aggressively. The {evidence_snippet} is the first evidence quote from the finding, truncated to the first ~120 characters (preserving whole words at the boundary) and with internal quotes escaped. If a finding has multiple evidence entries, use the first one; the rest live in the run artifact and are not needed for the overlap check.suggested_fix, chose not to defer or skip explicitly, and recorded acknowledgement instead; for round-to-round suppression that is semantically equivalent to Skip). Applied findings stay on the applied list so round-N+1 personas can verify fixes landed (see R30 in references/synthesis-and-presentation.md).references/synthesis-and-presentation.md for the synthesis pipeline (validate, anchor-based gate, dedup, cross-persona agreement promotion, resolve contradictions, auto-promotion, route by three tiers with FYI subsection), safe_auto fix application, headless-envelope output, and the handoff to the routing question.references/walkthrough.md. For the bulk-action preview used by best-judgment routing, Append-to-Open-Questions, and walk-through Auto-resolve with best judgment on the rest, read references/bulk-preview.md. Do not load these files before agent dispatch completes.references/personas/. Read only the prompt files selected for the current review.