[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M786V9179RXBTQ4Y5DM2RH3N":3,"skill-same:01M786V9179RXBTQ4Y5DM2RH3N":74},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":28,"commitSha":29,"skillDirectory":30,"forksCount":14,"repositoryHtmlUrl":31,"repositoryHomepageUrl":6,"ownerHtmlUrl":32,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":33,"install":34,"resources":47},"01M786V9179RXBTQ4Y5DM2RH3N","sp-review",null,"Use when sp-implement has completed and the integrated product must be started, exercised, repaired, and proven usable from real entrypoints before human acceptance.","chenziyang110\u002Flaunchdeck","chenziyang110","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F43693913?v=4","01M7863EBWK1D0P6A29YGEMAS4","Robin11","01M7863ECM1VB6RXDMHTW90D2T",0,"MIT","https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.codex\u002Fskills\u002Fsp-review\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: \"sp-review\"\ndescription: \"Use when sp-implement has completed and the integrated product must be started, exercised, repaired, and proven usable from real entrypoints before human acceptance.\"\ncompatibility: \"Requires spec-kit project structure with .specify\u002F directory\"\nmetadata:\n  author: \"github-spec-kit\"\n  source: \"templates\u002Fcommands\u002Freview.md\"\n---\n## Invocation Syntax\n\n- In this integration, invoke workflow skills with `$sp-plan`-style syntax.\n- References such as `\u002Fsp.plan`, `\u002Fsp.tasks`, or `next_command: \u002Fsp.plan` are canonical workflow-state identifiers and handoff values.\n- Preserve those canonical state tokens exactly in artifacts and workflow state; do not rewrite them to this integration's invocation syntax.\n\n\n\n## Workflow Contract Summary\n\n- **When to use**: `implementation-handoff.json` exists, the deterministic workflow runtime is ready to transition from `implement` to `review`, and the integrated product needs system-level verification and repair.\n- **Primary objective**: Review the implemented software as an operable product, find broken startup, interaction, registration, and end-to-end wiring, repair understood in-scope defects, and revalidate the exact affected paths.\n- **Primary outputs**: A fresh approved `review-state.json`, integrated evidence under `review-evidence\u002F`, resolved or routed findings, and a final implementation summary plus Review-to-Accept handoff bound to the reviewed implementation fingerprint and runtime identity basis.\n- **Default handoff**: Continue the Leader-owned Review Universe through independent audit, Fix, join, and revalidation waves while the shared validation-epoch budget remains; approve only from fresh integrated proof, block when the third epoch fails, hand only proven truth gaps upstream, then hand human product acceptance to \u002Fsp.accept and stop.\n- **Execution note**: This summary is routing metadata only. Follow the full contract below end-to-end rather than inferring behavior from the description alone.\n\n## Blocked Exit Contract\n\nIf blocked after safe recovery, read and follow\n`.specify\u002Ftemplates\u002Fworkflow-blocker-template.md` and its JSON schema. Never\nreturn only an error or “ask a human”; preserve state and keep agent-capable\nrepair agent-owned. Set `human_action_required: true` only for authority,\ncredentials, protected systems, human decisions\u002Freviews, or physical access.\nTailor steps, expected results, failure paths, evidence, and resume action to\nCI, visual review, or product decisions. Never claim completion.\n\nFor a feature runtime blocker, do not invent `resume_argv` or overwrite an\nexisting blocker. The CLI returns a read-only `show_argv` and structured\n`resolution_action`; `next_argv` stays empty while evidence is missing. After\nthe criteria are proven, attach sanitized evidence using the action's declared\ninput and execute its base argv. It restores the same owner and keeps the full\nblocker audit.\n\n## User Input\n\n```text\n$ARGUMENTS\n```\n\nYou **MUST** consider the user input before proceeding (if not empty).\n\n## Objective\n\nProve that the integrated implementation is an operable product from its official real entrypoints, repair bounded implementation defects, and preserve enough evidence to resume or make the final review claim honestly.\n\n\n## Codex Project Cognition Advisory Gate\n\n**Crucial First Step**: You MUST use project cognition compass first: run `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe compass --intent implement '--query=\"$ARGUMENTS\"' --format json` before any system review, repair, or revalidation actions. Read and carry `epistemic_contract`; require `graph_role=route_candidate_only`, `fact_source_of_truth=live_repository`, `live_verification_required=true`, `graph_only_claims_allowed=false`, and `unverified_claim_action=withhold`. The contract cannot authorize source changes and cannot prove current behavior; contradictory live evidence overrides the route candidate. Graph claims are indexed assertions; even `verified_in_graph_generation` is only an active graph-generation state, not current repository truth. Graph claims cannot authorize source changes and cannot set workflow `claim_ready=true`; bounded live evidence and the separate workflow final-claim gate remain required. Read top-level `minimal_live_reads` first, then use lane-level `first_pass_paths` reasons, `verification_hints`, `followup_surfaces`, and `before_fix_claim`; treat `coverage_diagnostics` as confidence and closeout signals, never as route candidates. Treat `expansion_ref` as a normal continuation path and run `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe expand --id '\u003Cid>' --section '\u003Csection>' --format json` only when coverage state or live evidence requires more map detail. Do not infer final edit scope from `minimal_live_reads` or `first_pass_paths`. Readiness values are `query_ready`, `review`, `needs_rebuild`, `blocked`, and `unsupported_runtime`. When `compass_state=needs_semantic_intake`, write `semantic_intake` from project vocabulary and rerun compass with `--semantic-intake-file`, or use the advanced `lexicon -> semantic_intake -> query` path when explicit concept decisions are needed. Preserve advanced routing through `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe query --intent implement --query-plan '\"\u003Cquery_plan_json>\"' --format json` for precision cases.\n- Read and carry `epistemic_contract`; require `graph_role=route_candidate_only`, `fact_source_of_truth=live_repository`, `live_verification_required=true`, `graph_only_claims_allowed=false`, and `unverified_claim_action=withhold`. The contract cannot authorize source changes and cannot prove current behavior; contradictory live evidence overrides the route candidate. Graph claims are indexed assertions; even `verified_in_graph_generation` is only an active graph-generation state, not current repository truth. Graph claims cannot authorize source changes and cannot set workflow `claim_ready=true`; bounded live evidence and the separate workflow final-claim gate remain required.\n- Route every Compass packet by `recommended_next_action.action_id`, never by readiness alone. `query_ready` reads top-level `minimal_live_reads` first and then lane-level `first_pass_paths`; `review` permits only returned `minimal_live_reads` plus `coverage_diagnostics`; `needs_rebuild` may carry a resumable non-rebuild action such as `complete_scan_packets`, which must be preserved. Only `action_id=project_cognition.rebuild` may consume `rebuild_reasons[]` and the canonical Classic steps in `recommended_next_action.workflow_routes.classic.steps`; `action_id=project_cognition.repair_status` must run its returned `argv`. `blocked` reports the runtime issue as advisory map state and continues with live repository evidence unless the user's request is to repair cognition; `unsupported_runtime` continues with live evidence and records that compass intake was unavailable. If `baseline_kind=greenfield_empty`, continue with workflow artifacts and live requirements instead of inferring rebuild from absent graph paths.\n- Use `map-update` for ordinary existing-baseline gaps. If `baseline_kind=greenfield_empty`, do not recommend map-scan -> map-build solely because the graph has no paths; continue with workflow artifacts and live requirements. Use `map-scan -> map-build` only for brownfield first\u002Fmissing\u002Funusable baseline, schema failure, schema v1 or old broad-schema rebuild-required readiness, zero active-generation `path_index` rows outside `greenfield_empty`, missing or invalid `alias_index`, `explicit_rebuild_requested`, or `baseline_identity_invalid`.\n- Treat the project cognition compass packet as advisory navigation for brownfield context; do not fall back to chat memory or ad hoc repository instincts when compass-backed runtime coverage should guide the route.\n- Treat this as advisory navigation, not a hard gate; continue with live repository evidence when the bundle is weak, stale, or missing, and use map maintenance only when it is actually useful.\n- Mutation closeout is separate from entry routing: entry stale may continue, but workflow-owned mutation closeout is not an external map-maintenance handoff. If the workflow changes source\u002Fruntime truth-owning surfaces, shared surfaces, command\u002Froute\u002Fcontract boundaries, verification entry points, runtime assumptions, or other project-related behavior surfaces, final state must run inline project cognition update from changed paths, affected surfaces, and verification evidence.\n- Inline project cognition update uses `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe delta append --help` followed by `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe update --delta-session '\"$DELTA_SESSION_ID\"' --reason workflow-finalize --format json` when a delta session exists, or `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe update --payload-file '\".specify\u002Fproject-cognition\u002Fupdates\u002F\u003Cupdate-id>.json\"' --reason workflow-finalize --format json` when no delta session exists.\n- The payload-file path must include changed_paths, behavior_surfaces, generated_surfaces, state_contracts, verification, known_unknowns, and confidence_notes so the update is equivalent to `sp-map-update`, not just a path stamp; `verification_evidence` and `generated_surface_notes` are accepted compatibility aliases.\n- Use `known_unknowns` only for blockers that make the cognition update unsafe to trust. If unrelated dirty or untracked working-tree paths were excluded by explicit workflow-owned paths, record that as `confidence_notes` or `boundary.initial_dirty_paths`, not as blocking `known_unknowns`.\n- clean closeout keys on `result_state`, not `update_id`, `last_update_id`, or freshness alone. Treat `ready` and `no_op` as clean, `partial_refresh` as recorded but not fully clean, `needs_rebuild` as a map-scan\u002Fmap-build route, `blocked` as blocked, and `recorded` as legacy recorded-only output that is never clean completion.\n- Use `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe mark-dirty --reason '\"\u003Creason>\"' --format json` only when inline update cannot complete. Dirty only when inline update cannot complete.\n- `sp-map-update` is for manual\u002Fexternal maintenance and follow-up repair after user edits, interrupted workflows, or explicit operator map-maintenance requests. It is not routine cleanup for changes this workflow just made.\n- A project-cognition compass intake is not complete when it returns JSON. It is complete only when readiness drives routing, `minimal_live_reads` constrains inspection, lane-level `first_pass_paths` reasons are considered, and relevant facts are carried into the next workflow artifact or execution state.\n- Carry forward the selected user journeys, official entrypoints, affected runtime surfaces, minimal live reads, validation routes, and evidence gaps into `review-state.json` or the just-in-time review packet.\n\n## Process\n\n## Intake And Runtime Ownership\n\n- Resolve exactly one feature and inspect `workflow show` before mutation. Transition from completed `implement` to `review` with the runtime-returned revision; do not hand-edit `workflow-runtime.json`.\n- Run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review prepare --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --format json`. Treat `implementation-handoff.json` as the implementation-to-review source contract and `review-state.json` as Review's resumable truth. When `accept route-repair` reopens Review, preparation creates a new cycle bound to the prior approved Review digest and routed acceptance finding; never edit or reapprove the old cycle.\n- The Leader owns `review-state.json`, the official runtime instances, ports, test data, finding lifecycle, repair acceptance, and final verdict.\n- Continue the validation-epoch ledger shared across Implement and Review. Do\n  not reset it on Review entry, resume, or repair-cycle creation. The combined\n  flow permits at most three heavyweight epochs bound to source fingerprints.\n- The canonical ledger is\n  `implementation-review\u002Fvalidation-runs.json`. Before Review work run\n  `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify implement validation-status --feature-dir '\u003Cfeature-dir>' --format json`.\n  Before the Leader starts a delivery scenario wave, run\n  `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify implement validation-start --feature-dir '\u003Cfeature-dir>' --stage review --purpose delivery --command '''\u003Ccmd>''' '[--command' '''\u003Ccmd2>''' ']' '[--task-id' 'T001]' '[--task-id' 'T002]' '[--fingerprint' '\u003Csha>]' --format json`;\n  omit `--fingerprint` to bind the current implementation snapshot. Afterward run\n  `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify implement validation-finish --feature-dir '\u003Cfeature-dir>' --run-id '\u003CVn>' --status '\u003Cpassed|failed>' --evidence-ref '\u003Cref>' '[--evidence-ref' '\u003Cref2>]' --summary '''\u003Ctext>''' --format json`.\n  Use the runtime-returned ids and budget; never hand-edit the file.\n- On resume, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review resume-audit --feature-dir '\u003Cfeature-dir>' --format json` when available. Continue from the exact scenario\u002Ffinding cursor and invalidate evidence whose implementation fingerprint, source revision, or Review cycle is stale. Repair-cycle evidence belongs under `review-evidence\u002Fcycle-\u003Cn>\u002F` and packet\u002Fresults under `review-results\u002Fcycle-\u003Cn>\u002F`; an earlier cycle cannot close the current one.\n\n## System Review Loop\n\n1. Compile the Review Universe and use independent coverage discovery to reconcile authoritative obligations with actual consumer and runtime surfaces.\n2. Open the next Leader-owned validation epoch, start each official entrypoint,\n   then run a read-only Review\u002FAudit wave whose workers inspect assigned coverage\n   slices and return evidence\u002Ffindings without edits. All commands, scenarios,\n   and captures against that fingerprint share the one epoch.\n3. The Leader joins all audit packets, rejects stale or incomplete results, resolves coverage gaps, and freezes the accepted finding set.\n4. Run a separate Fix wave for accepted findings only when another validation\n   epoch remains. Fix workers receive isolated write scopes, run cheap task\n   checks, return test impact, and may change implementation\u002Ftests but never\n   upstream truth or execute heavyweight gates.\n5. Join and inspect every repair, then open the next remaining epoch, restart the\n   real product, and run an independent revalidation wave. The repair author must\n   not verify its own finding.\n6. Continue only while budget remains. A source change invalidates prior proof\n   and requires another epoch for approval. Never retry a failed command against\n   the unchanged fingerprint. The third failed epoch blocks with exact evidence\n   and recovery criteria; never start a fourth validation epoch.\n\nUI-bearing scenarios require real-entrypoint `structure_snapshot`, `visual_capture`, and `runtime_diagnostics` evidence with `evidence_scope: integrated`. Group the viewport\u002Fstate matrix by integrated surface and source fingerprint; do not run the full viewport\u002Fstate capture loop per Txx. Validate interaction, navigation, loading, empty, error, permission, persistence\u002Freload, responsive, keyboard\u002Ffocus, console, network, and runtime states when applicable. Automated behavior checks remain distinct from visual and interaction acceptance.\n\n## Delegation\n\n- The Leader orchestrates subagents across the Review\u002FAudit wave, Fix wave, and independent revalidation wave; direct execution is reserved for compact, tightly coupled steps.\n- Audit workers are read-only. Fix workers receive finding-bound, non-overlapping write scopes. Revalidation workers are read-only and independent from the repair author.\n- Compile each `SystemReviewPacket` just in time from current state and live code. Never dispatch a raw checklist or the entire feature package.\n- Serialize paths sharing one browser session, database state, service instance, port, or write set. Integrate worker results before accepting a repair.\n- A worker result is evidence only. A worker cannot declare coverage complete or the whole system approved; the Leader owns all joins, zero-uncovered coverage, repair acceptance, and the final verdict after an integrated restart and required regression.\n- Workers do not open validation epochs. The Leader may coordinate read-only\n  observation slices inside one already-open epoch, but must not let scenario,\n  worker, or Txx boundaries multiply heavyweight runs.\n\n## Output Contract\n\n- Keep `review-state.json` fresh and schema-valid with scenario results, findings, repair\u002Frevalidation evidence, cursor, blockers, and next action.\n- Store evidence under `review-evidence\u002F` and reference it compactly from state; do not paste large logs or screenshots into agent state.\n- Before the handoff, verify that `human_acceptance_obligations` and `human_acceptance_scenarios` still cover the frozen Human Acceptance Universe for every new or changed requirement with zero uncovered required obligations. Create `reviewed_runtime_targets` covering every required human scenario, with immutable official entrypoint, environment\u002Finstance\u002Fconfiguration, final snapshot, applicable artifact\u002Fdeployment\u002Fversion identity, linked Review scenarios, and existing fresh ready evidence. For each target, write the exact runtime identity JSON projection under `review-evidence\u002F` and, for repair cycle 2+, under `review-evidence\u002Fcycle-\u003Cn>\u002F`; record its feature-relative `identity_evidence_ref` and byte-exact `identity_evidence_sha256`. A `build` or `deployment` target also requires an existing feature-relative product\u002Fbuild `artifact_ref`, created before the final fingerprint, included in the implementation snapshot, outside `review-evidence\u002F`, `review-results\u002F`, and every other snapshot-excluded path, whose current bytes match `artifact_sha256`. Bind the exact target list with `final.runtime_targets_sha256`. Accept receives these targets, preserves both identity-evidence fields read-only, and may add only session readiness\u002Factions.\n- After the final integrated restart, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review validate --feature-dir '\u003Cfeature-dir>' --format json`, bind its `current_fingerprint` to `final.reviewed_snapshot_sha256`, and only then set Review `status: approved`. Run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review closeout --feature-dir '\u003Cfeature-dir>' --format json` only after all required scenarios pass, all required evidence is integrated and fresh, and blocking findings are zero.\n- On successful Review closeout, update Review-owned rich state truthfully, execute the returned revision-bound `workflow complete-stage` argv separately, hand off to `$sp-accept`, and stop. The Review-to-Accept handoff carries obligations, human scenarios, immutable reviewed targets, and their digest; it does not prefill human PASS. After an acceptance repair, Acceptance reruns every frozen scenario and preserves no old PASS. Do not enter acceptance in this invocation.\n\n## Guardrails\n\n- `sp-review` is not permission to change approved product scope or upstream truth. Every approved-scope defect stays in Review regardless of repair size, including missing code, task omission, and unknown root cause; use a diagnostic packet before a Fix packet when needed.\n- Review remains the stage owner through diagnosis, repair, and revalidation. Only a proven requirement truth, design truth, or architecture truth gap may produce an upstream handoff; missing code is not an upstream truth gap.\n- Keep the existing event-triggered task review embedded in `sp-implement`; do not duplicate its task lifecycle ledger here.\n- Do not claim success because the build passes, tasks are checked, files exist, or a worker says PASS.\n- Do not let a passive testing skill, worker, resume, or completion claim start an\n  extra epoch. Review must consume only the remaining shared budget.\n- Do not push, deploy, modify protected systems, use real customer data, or perform external writes without explicit authority. Use isolated test data and the shared blocker contract for genuine external boundaries.\n\n## Senior Consequence Analysis Gate\n\nRun this gate whenever the request, artifact set, defect, or planned change can affect lifecycle operations, running objects, concurrent work, destructive behavior, shared state, downstream consumers, compatibility, security-sensitive behavior, or multiple plausible product behaviors.\n\nAlso trigger it for a new or changed entry point over an existing operation, a direct\u002Fbackground\u002Fheadless\u002Fsystem entry point, or a changed consumer or interaction owner. Build the result inventory from current result\u002Ferror definitions, existing consumers, state transitions, tests, and UI\u002Fwindow\u002Frequest\u002Fretry owners. Reusing an executor proves operation reuse; it does not prove that the new consumer preserves every terminal, recoverable, partial, cancelled, or user-input-required outcome.\n\nProject cognition first. Use the project cognition runtime to identify ownership, consumers, state surfaces, change-propagation facts, verification routes, conflicts, known unknowns, and coverage gaps. Senior consequence analysis second. Turn those facts into explicit product and implementation obligations instead of treating the graph as the decision-maker.\n\nProject cognition readiness provides navigation state; route recovery by `recommended_next_action.action_id`. If readiness is `query_ready`, read top-level `minimal_live_reads` first, then use lane-level `first_pass_paths` reasons. If readiness is `review`, inspect the returned `minimal_live_reads` before continuing and treat `coverage_diagnostics` as confidence and closeout signals. If readiness is `needs_rebuild`, preserve resumable non-rebuild actions such as `complete_scan_packets`; only `action_id=project_cognition.rebuild` may consume `rebuild_reasons[]` and `recommended_next_action.workflow_routes.classic.steps` as a rebuild handoff. That rebuild route remains reserved for brownfield first\u002Fmissing\u002Funusable baseline, schema failure, schema v1 or old broad-schema rebuild-required readiness, zero active-generation `path_index` rows outside `greenfield_empty`, missing or invalid `alias_index`, `explicit_rebuild_requested`, or `baseline_identity_invalid`. If readiness is `blocked`, report the blocked state and continue with live repository evidence unless the user's actual request is to fix cognition runtime state. If readiness is `unsupported_runtime`, continue with live evidence and record that compass intake was unavailable. If `baseline_kind=greenfield_empty`, continue with workflow artifacts and live requirements; do not recommend map-scan -> map-build solely because the graph has no paths. Carry relevant project cognition facts, returned `minimal_live_reads`, inference notes, and coverage gaps into the workflow's artifacts or durable state, but back consequence claims with live code, tests, scripts, configuration, or authoritative docs. Mutation closeout is separate from entry routing: entry stale may continue, but that does not allow source\u002Fruntime mutation workflows to defer closeout. Workflow-owned mutation closeout is not an external map-maintenance handoff; after changing project-related files or behavior, the workflow must run inline project cognition update from its changed paths, affected surfaces, and verification evidence, with `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe mark-dirty` only as fallback when inline update cannot complete. `sp-map-update` is for manual\u002Fexternal maintenance and follow-up repair; it is external map maintenance, not routine closeout for this workflow's own changes. In shared routing summaries, sp-map-update is for manual\u002Fexternal maintenance and ordinary existing-baseline gaps.\n\nRequired output when the gate triggers:\n\n- **Affected Object Map**: name each object, record, worker, queue, artifact, command, API, file surface, user-visible state, or downstream consumer that can be affected.\n- **State-Behavior Matrix**: describe behavior for each important lifecycle state, including created, queued, running, paused, failed, cancelled, completed, resumed, archived, missing, stale, or partially refreshed states when relevant.\n- **Dependency Impact Table**: map direct dependencies, indirect consumers, shared state, compatibility surfaces, validation routes, and adjacent workflows that can break if semantics change.\n- **Recovery And Validation Contract**: state rollback, retry, idempotency, cleanup, migration, observability, and validation evidence required before handoff or completion.\n- **Coverage Gaps**: list what project cognition or live evidence cannot prove, who must resolve each gap, the latest safe resolve phase, the stop-and-reopen condition, and the routing decision: current workflow may continue with an assumption, must ask the user, must route to clarification or deep research, or must request map maintenance.\n- **Consequence Obligations**: assign stable `CA-###` IDs to every obligation that must survive downstream handoff, task generation, worker packets, verification, or debug closeout. Each `CA-###` must include claim, affected objects, owner workflow, latest resolve phase, status, and stop-and-reopen condition.\n- **Entrypoint Outcome Contract**: when the entry-point trigger applies, persist `entrypoint_outcome_contract` in `spec-contract.json`. Keep live-evidence-backed result inventory separate from product dispositions, and map every preserved or adapted outcome to acceptance refs and `CA-###` consequence refs. Plan and Tasks consume those CA refs through the existing consequence chain; do not create a parallel outcome ledger downstream.\n\nStand down only for docs-only wording changes, trivial isolated fixes, or local refactors that cannot affect lifecycle operations, running state, destructive operations, shared state, downstream consumers, compatibility, security, or multiple behavior choices. Record the no-trigger reason or stand-down reason in the workflow's durable artifact or closeout before skipping the required outputs.\n\nIf the gate triggers and the current workflow cannot preserve the required outputs, stop and route to the workflow that can. Do not mark ready, resolved, handoff-ready, planning-ready, or complete while triggered consequence obligations remain unresolved, unmapped, or unsupported by validation evidence.\n\n## Agent Phase Handoff\n\nPhase handoff is an agent-only control surface. Human-facing explanation belongs in the visible reply or in project documents that have independent review value; it must not be duplicated into a handoff.\n\n- The previous phase's canonical JSON contract is the next phase's primary input.\n- Use the compact transition shape from `.specify\u002Ftemplates\u002Fagent-phase-transition-schema.json`: `status`, `source_ref`, `semantic_delta`, `required_refs`, `blockers`, `next_action`, and recovery only when blocked.\n- Carry the minimum sufficient context: include a fact only when omitting it could change the next action, lose a requirement or obligation, force rediscovery, weaken verification, or prevent safe recovery.\n- Preserve decisions, acceptance criteria, evidence provenance, `MP-*`, `CA-###`, and stop\u002Freopen conditions by stable reference. Do not copy their full bodies into every downstream artifact.\n- Protected `MP-*` and `CA-###` obligations must not drop between phases. A downstream phase may resolve or reopen them, but may not silently omit them.\n- Carry the locked implementation-target reference. A cross-project transition must not silently point to the current repository when the confirmed target differs.\n- Consume project rules and Learning through `learning start --command \u003Cclassic-command-name> -> list -> show`; run selected `show_argv` only. Constitution remains at `.specify\u002Fmemory\u002Fconstitution.md`; never parse Learning storage.\n- Capture at owning closeout only when the lesson would change a future action; prefer `learning capture-auto`.\n- A rendered Markdown view is never an agent handoff authority. Do not require Markdown\u002FJSON companion agreement.\n- Revalidate upstream truth only when its revision changed, evidence became stale, live repository facts contradict it, or the current phase discovers a scope, boundary, feasibility, or risk change.\n- If `semantic_delta` is empty, do not repeat upstream questions, approach selection, or user confirmation.\n\n## Deterministic Workflow Runtime\n\nFor a feature-bearing `specify -> plan -> tasks -> implement -> review -> accept` stage,\nthe CLI owns phase order in `FEATURE_DIR\u002Fworkflow-runtime.json`. Do not author\nor advance `workflow-runtime.json` by hand. `workflow-state.md` remains the rich\nworkflow-owned evidence and resume surface for Learning, clarification,\nresearch, analysis, and profile-specific details; the phase runtime must not overwrite\nor parse it as its revision authority.\n\n- After `FEATURE_DIR` is known, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow show --feature-dir '\u003Cfeature-dir>' --format json`. If state is missing at the first feature stage, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow enter --command specify --feature-dir '\u003Cfeature-dir>' --format json`.\n- On entry to `plan`, `tasks`, `implement`, `review`, or `accept`, use the current revision with `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow transition --to '\u003Cthis-stage>' --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --format json` before writing that stage's artifacts. The command validates the completed source-stage artifacts and refuses skips, stale revisions, or incomplete handoffs with exit `10`.\n- After the owning stage finishes its artifact closeout, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow complete-stage --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --format json`. The runtime validates the stage artifacts, records non-terminal `status: completed`, and returns the one legal transition argv; do not edit phase state manually.\n- The destination command owns the returned transition. A completed stage recommends the next command but must not execute `workflow transition` to that next stage in the same invocation.\n- Use `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow next --feature-dir '\u003Cfeature-dir>' --format json` for the compact next action. While a stage is active its `next_argv` completes that stage; after completion it transitions to the successor. Execute only structured argv and do not reconstruct flags from prose.\n- When fresh evidence invalidates an earlier required stage, preserve the stale\n  artifacts for audit and reopen the highest invalid stage with\n  `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow reopen --to '\u003Cspecify|plan|tasks|implement|review>' --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --reason '\u003Ccompact-reason>' --evidence '\u003Csanitized-evidence>' --invalidated-artifacts '\u003Cartifact>' --format json`.\n  Repeat `--evidence` and `--invalidated-artifacts` as needed. The CLI permits\n  a strict backward move or reactivation of the same completed non-accept stage,\n  including `implement` and `review`; an active same-stage owner simply continues. Honor any\n  persisted blocker before retrying. Failed acceptance uses\n  `accept route-repair`, never generic reopen. Every non-human-access acceptance\n  failure first reopens Review; the Review Leader diagnoses it, dispatches an\n  independent Fix and revalidation cycle, and may reopen an upstream truth\n  owner only after proving that correct implementation is impossible under the\n  current requirement, design, or architecture truth. After any repair, rerun\n  the full frozen Human Acceptance Universe; preserve no stale human PASS.\n- After safe agent recovery is exhausted, persist the blocker through `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow block --input '\u003Cblocker-json-or->' --format json`. Obtain its exact input shape with `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify api schema workflow-block-input --format json`; the runtime rejects replacement of an unresolved blocker and returns the human tutorial, a safe read-only `show_argv`, and a structured `data.resolution_action`. While evidence is missing, `next_argv` is intentionally empty.\n- When the recorded unblock criteria are proven, append each sanitized evidence item to the runtime-returned `resolution_action.base_argv` using its declared `--resolution-evidence` required input, then execute that argv. This invokes `workflow resolve`, preserves the full prior blocker audit, and reactivates the same stage; do not reconstruct other flags or clear blocker state manually.\n- After explicit human acceptance, run the acceptance-owned `accept closeout` command and execute its successful response's `next_argv` verbatim. That revision-bound argv invokes `workflow closeout`; do not reconstruct it from prose or a remembered revision. It validates and snapshots acceptance evidence before marking the feature workflow complete.\n\nFor every blocked exit, including a pre-feature discussion that cannot use the\nfeature runtime yet, follow\n`.specify\u002Ftemplates\u002Fworkflow-blocker-template.md` and its schema. Report the\nexact cause, sanitized evidence, attempted recovery and result, affected scope,\nsmallest next action, observable unblock criteria, and exact resume point. Keep\nagent-capable repair agent-owned. When authority, credentials, a protected\nsystem, physical access, or human judgment is genuinely required, add the full\nHuman Action Guide: goal, prerequisites, safety notes, numbered exact actions,\nexpected result and safe failure branch for every action, independent\nverification, sanitized evidence to return, and the exact resume command.\n\n[AGENT] For project-cognition-backed semantic intake, routing, audit, resume, or final-claim gates, read `references\u002Fsemantic-work-contract.md`.\n\n## Main Flow\n\n1. Run `.specify\u002Fscripts\u002Fpowershell\u002Fcheck-prerequisites.ps1 -Json -RequireTasks -IncludeTasks` to resolve one implemented feature and inspect repository status. Initial Review transitions from validated `implement`; an acceptance repair arrives through CLI-owned `accept route-repair` with `review` already active. Run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review prepare --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --format json`; stop when the implementation handoff, fingerprint, prior approved Review digest, routed acceptance finding, or revision is missing, stale, or ambiguous. Acceptance repair must create the next immutable Review cycle rather than editing or reapproving the old cycle.\n2. Read `implementation-handoff.json`, current `review-state.json`, required acceptance refs, official entrypoints, and only the live source needed for the current scenario. Continue the validation-epoch ledger shared across Implement and Review; do not reset its consumed count on phase entry, resume, worker dispatch, or Review cycle creation. Treat this as the mandatory system review after implementation; retain the embedded task review inside `sp-implement` as a separate task-level control.\n3. Compile the bounded Review Universe from authoritative acceptance obligations, official entrypoints, changed consumer surfaces, runtime-discovered controls and registrations, and affected regression paths. Use independent coverage discovery so the handoff scenario matrix is a minimum rather than a blind spot; the Leader owns the zero-uncovered reconciliation. Before executing a heavyweight command or real scenario, open the next Leader-owned validation epoch against the current source fingerprint. The combined Implement\u002FReview workflow permits at most three; scenario slices within that epoch share it rather than incrementing the count.\n4. Start the software from every applicable official real entrypoint and wait for its declared ready signal. The Leader orchestrates subagents through an independent read-only Review\u002FAudit wave: compile just-in-time audit `SystemReviewPacket`s with disjoint coverage slices, join every result, reconcile duplicate or missing findings, and forbid audit workers from editing product code or declaring coverage complete. In an acceptance repair cycle, assign the routed observation to an accepted read-only diagnostic Review worker and store all new scenario evidence under `review-evidence\u002Fcycle-\u003Cn>\u002F` and all packet\u002Fresults under `review-results\u002Fcycle-\u003Cn>\u002F`; evidence from an earlier cycle cannot close the new one.\n5. Exercise real actions and observable results inside that epoch. Trace button, link, menu, form, command, route, handler, provider, factory, service, persistence or external dependency, and user feedback wiring where applicable. For UI scenarios capture integrated `structure_snapshot`, `visual_capture`, and `runtime_diagnostics` evidence from the real entrypoint once per applicable surface\u002Ffingerprint. Do not run the full viewport\u002Fstate capture loop per Txx.\n6. After the audit join, run an independent Fix wave only when a validation epoch remains. The Leader sends bounded Fix workers one or more accepted findings with authoritative expected behavior, isolated write scopes, forbidden truth artifacts, and exact regression obligations. Fix workers run cheap task checks and report test impact; they do not independently start heavyweight verification. Every approved-scope defect stays inside Review regardless of repair size: missing code, a task omission, incomplete tests, broken wiring, and an unknown root cause are not reasons to exit. Use a read-only diagnostic packet for an unknown root cause; Review remains the stage owner and then dispatches the repair itself. If the failed epoch consumed the final slot, preserve the findings and block without an unprovable repair.\n7. Join and inspect every repair result, then, only when budget remains, open the next validation epoch, restart the integrated product, and run an independent revalidation wave. A repair author must not verify its own finding; the Leader or a different read-only subagent reruns the exact failed journey, dependent scenarios, and credible regression set against the post-repair fingerprint. That bounded set attributes finding-level revalidation only: after any Fix, approval still requires every required Review scenario and all required evidence against the single final reviewed snapshot in that same epoch. No pre-Fix scenario evidence can satisfy approval. Record the complete accepted Fix-set digest plus an exact byte-bound full-matrix evidence manifest in the final revalidation; partial, missing, extra, or relabeled scenario evidence also blocks approval. The third failed epoch blocks with exact evidence and resume criteria; never start a fourth. Cycle 1 uses the same path, cycle-id, and byte-digest gates as later cycles.\n8. Only a proven upstream truth gap may stop Review: requirement truth that is missing or contradictory, design truth that is missing or contradictory, or architecture truth that must change before any correct implementation is possible. Missing code is not an upstream truth gap. After all packets joined and the Review Universe reports zero uncovered obligations and surfaces, create at least one `reviewed_runtime_targets` record for every required Human Acceptance scenario. Bind each target to its official entrypoint, final reviewed snapshot, exact environment\u002Finstance\u002Fconfiguration identity, applicable artifact\u002Fdeployment\u002Fversion identity, linked Review scenarios, and existing fresh ready-evidence refs. For every target, write an exact identity JSON projection under `review-evidence\u002F` (`review-evidence\u002Fcycle-\u003Cn>\u002F` in repair cycle 2+) and record its feature-relative `identity_evidence_ref` plus the SHA-256 of its current bytes as `identity_evidence_sha256`. This valid JSON has top-level `version` equal to `1`, `status` equal to `\"ready\"`, and a `target` object containing exactly `id`, `mode`, `entrypoint_id`, `environment_ref`, `instance_ref`, `configuration_ref`, `reviewed_snapshot_sha256`, `artifact_ref`, `artifact_sha256`, `deployment_id`, `observed_version`, `review_scenario_ids`, and `ready_evidence_refs`, with every value copied exactly from the reviewed target. For `build` and `deployment`, require `artifact_ref` to point to an existing feature-relative product\u002Fbuild file created before the final fingerprint, included in the implementation snapshot, and outside `review-evidence\u002F`, `review-results\u002F`, and every other snapshot-excluded path; `artifact_sha256` must match its current bytes. Compute the final target digest only after these fields are bound. Run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review validate --feature-dir '\u003Cfeature-dir>' --format json`, bind its current fingerprint, and approve only with fresh cycle-specific integrated evidence and zero blocking findings. Validate the frozen Human Acceptance Universe against the delivered new or changed requirement set. The Review-to-Accept handoff contains the obligations, scenarios, approved runtime targets, identity-evidence fields, and digest; Accept preserves the two identity-evidence fields read-only, may add only session readiness\u002Factions, and never prefills human PASS. Then run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review closeout --feature-dir '\u003Cfeature-dir>' --format json`, execute its returned `workflow complete-stage` argv separately, recommend `$sp-accept`, and stop. After an acceptance repair, every human scenario is reset and must be rerun; Review must not preserve a stale human PASS.\n\n### Inline Project Cognition Update\n\nWorkflow-owned mutation closeout is not an external map-maintenance handoff and is not external map maintenance. It is the workflow-local form of `$sp-map-update`. If this workflow changed project-related source, runtime, templates, generated assets, config, tests, state contracts, shared surfaces, or behavior-bearing docs, closeout MUST run inline project cognition update for the workflow-owned changed paths and affected surfaces before claiming clean completion.\n\nCall the planner first:\n\n```text\nC:\\Users\\11034\\.specify\\bin\\project-cognition.exe closeout-plan --workflow '\"$ACTIVE_WORKFLOW\"' --format json\n```\n\nWhen `DELTA_SESSION_ID` exists, pass it into the planner:\n\n```text\nC:\\Users\\11034\\.specify\\bin\\project-cognition.exe closeout-plan --workflow '\"$ACTIVE_WORKFLOW\"' --delta-session '\"$DELTA_SESSION_ID\"' --format json\n```\n\nConsume `workflow_canonical`, `update_mode`, `payload_draft`, `required_agent_fields`, `unknown_paths`, `unknown_path_dispositions`, `delta_append_draft`, display-only `delta_append_command`, `update_argv`, display-only `update_command`, and `recommended_next_command`.\n\nBefore running `update`, fill the fields listed in `required_agent_fields` from live evidence from this workflow. Supported agent-owned evidence fields include:\n\n- `verification`\n- `behavior_surfaces`\n- `generated_surfaces`\n- `state_contracts`\n- `known_unknowns`\n- `confidence_notes`\n- `user_decisions`\n- `boundary`\n\nIf a field appears in `required_agent_fields`, provide live-evidence-backed content for it. Fields not listed by `required_agent_fields`, such as `known_unknowns` and `boundary`, are populated only when live evidence supports them; do not invent them to satisfy the shape.\nUse `known_unknowns` only for blockers that make the cognition update unsafe to trust. If the working tree contains unrelated dirty\u002Funtracked paths and the workflow uses explicit workflow-owned paths, record that as `confidence_notes` or `boundary.initial_dirty_paths`, not as a blocking `known_unknowns` item.\n\nFor each `unknown_path_dispositions[]` item, set `agent_disposition` to exactly one allowed value:\n\n- `adoptable`: verified new path inside this workflow-owned scope; it may be recorded in changed\u002Fscope paths and verified adoptable paths do not become blocking `known_unknowns`.\n- `review_only`: path informed review but is not adopted into changed coverage.\n- `ignored`: path remains excluded and must not enter payloads, records, route indexes, evidence, aliases, or minimal live reads.\n- `blocking_known_unknown`: record it as a known unknown and report partial or blocked cognition closeout.\n\n`agent_disposition=adoptable` is an agent accounting decision, not proof that runtime indexing already succeeded. Runtime adoption still requires a usable active project-cognition DB, at least one passing verification evidence item, and no blocking `known_unknowns`. After `update_argv` runs, inspect `result_state`, `adopted_paths`, `review_paths`, `minimal_live_reads`, and `partial_refresh_reasons`; do not explain a remaining `partial_refresh` as \"path_index missing\" until those fields show which adoption gate failed.\n\nIf `update_mode=delta_session`, complete `delta_append_draft.argv_prefix` with agent-owned repeatable flags such as `--behavior-surface`, `--generated-surface`, `--verification`, and accepted `--known-unknown` values from `delta_append_draft.argv_placeholders`. Then append the delta event and run `update_argv`. `delta_append_command` and `update_command` are display-only placeholders, not execution strings.\n\nIf `update_mode=payload_file`, write the completed `payload_draft` to the planner's `payload_path`. Then run `update_argv`. `update_command` is a display-only placeholder, not an execution string.\n\nCompleted payload drafts preserve the planner-owned `changed_paths` and `scope_paths` and add agent-owned evidence fields before recording.\n\nStructured `update` invalidates related claims and returns their stable IDs in `affected_graph_claims`. This is separate from update readiness: generic workflow verification and `result_state=ready` must not re-promote stale or contradicted graph claims. Only when this workflow already has decisive claim-specific bounded live evidence for an exact returned claim ID may it submit semantic reconciliation intent and run:\n\n```text\nC:\\Users\\11034\\.specify\\bin\\project-cognition.exe claim-reconcile prepare --input '\u003Cintent.json>' --format json\nC:\\Users\\11034\\.specify\\bin\\project-cognition.exe claim-reconcile apply --input '\u003Cprepared_packet_path>' --format json\n```\n\nProvide only reconciliation intent: workflow, stable `claim_id`, reason, and evidence containing repository-relative `source_path`, bounded line `span`, and `supporting` or `contradicting` role. Add verification only when it is claim-specific. The runtime owns the contract version, active generation, expected state and revision, UTC observation and expiry, source kind, content hashes, repository snapshot, IDs, and prepared packet path. Do not author or edit those integrity fields; execute the returned `apply_argv` exactly. If no such evidence exists, leave the claim stale. If reconciliation returns ready, rerun Compass once so later routing consumes the current evidence basis; partial or blocked reconciliation remains withheld and follows `recommended_next_action`.\n\nFor compatibility with worker handoffs and delta packets, the runtime also accepts `verification_evidence` as an alias for `verification` and `generated_surface_notes` as an alias for `generated_surfaces`. Verification evidence may be an array of objects (`command`, `result`, `artifact`) or an array of command-result strings, but clean closeout still requires passing verification evidence; failed verification cannot produce a clean `ready` closeout.\n\nClean closeout keys on `result_state`, not `status=ok`, `update_id`, `last_update_id`, or freshness alone:\n\n- `ready` or `no_op`: project cognition closeout may be clean when ordinary verification also passed.\n- `partial_refresh`: useful update data was written, but the final workflow state must report partial cognition closeout, `partial_refresh_reasons`, and the returned `minimal_live_reads`. If `partial_refresh_reasons` includes `missing_passing_verification_result`, repair the payload or delta evidence and rerun `update_argv` before final closeout; do not route that to `sp-map-update`. If verified workflow-owned paths still remain in `review_paths` after the update, report implementation completion separately from project-cognition maintenance and name `$sp-map-update` as follow-up repair.\n- `needs_rebuild`: report the exact rebuild condition and route to `$sp-map-scan`, then `$sp-map-build`.\n- `blocked`: report the runtime or validation blocker and the exact recovery command.\n- `recorded`: legacy recorded-only output; treat it as partial or blocked, never as clean completion.\n\nNever run the `complete-refresh` or `clear-dirty` helper after `result_state=partial_refresh`, `needs_rebuild`, `blocked`, or legacy `recorded`; those helpers are only for states that the runtime and validation prove ready.\n\nDirty fallback command shape: `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe mark-dirty --reason '\"\u003Creason>\"' --format json`.\nUse `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe mark-dirty --reason '\"workflow-closeout-failed\"' --format json` only when inline update cannot complete: when the planner or update command is unavailable, cannot record useful update data, cannot identify workflow-owned scope, or cannot be trusted because verification\u002Fworkflow completion is not trustworthy. Dirty only when inline update cannot complete.\n\nsp-map-update is for manual\u002Fexternal maintenance and follow-up repair. `$sp-map-update` remains the external\u002Fmanual workflow for user edits, interrupted workflow repair, explicit map maintenance, and follow-up repair. It is not routine cleanup for changes this workflow just made. If `sp-map-update` already ran `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe update --reason map-update` for the same changed paths, do not run a second `workflow-finalize` closeout update for those paths.\n\n## Detailed References\n\nRead [Reference index](references\u002FINDEX.md) before applying detailed contracts.\n\n- [system scenario contract](references\u002Fsystem-scenario-contract.md)\n- [subagent review contract](references\u002Fsubagent-review-contract.md)\n- [repair and revalidation](references\u002Frepair-and-revalidation.md)\n- [final claim and handoff](references\u002Ffinal-claim-and-handoff.md)\n\n## Codex Subagent Dispatch Contract\n\n- Execution model: `subagents-first`\n- Dispatch shape: `one-subagent`, `parallel-subagents`, or `subagent-blocked`\n- Execution surface: `native-subagents`, `managed-team`, or `leader-inline`\n- Delegation surface contract: preserve the native dispatch, fallback, worker result contract, and handoff path below.\n- Native subagent capability discovery: Before recording `subagent-blocked`, confirm the current runtime exposes `spawn_agent`, `wait_agent`, and `close_agent`; if they are not visible, use the active tool discovery mechanism for multi-agent or subagent tools first.\n- Do not record `subagent-blocked` until this capability discovery step is complete and the exact unavailable or unsafe surface is recorded.\n- Native subagent dispatch: Dispatch bounded subagents through `spawn_agent`.\n- Join behavior: Rejoin with `wait_agent`, integrate, then `close_agent`. The Leader joins every Review, Fix, and independent revalidation result before the final verdict.\n- Managed-team fallback: The Review Leader must preserve separate audit, Fix, and independent revalidation waves. If no native subagent surface exists, record the coverage blocker rather than silently claiming zero uncovered.\n- Leader-inline fallback: record the reason before local execution.\n- Worker result contract: Three-wave Review result contract: read-only Review observations and findings, bounded Fix changed files and validation, then independent revalidation evidence; every result is joined by the Leader.\n- Result contract: Three-wave Review result contract: read-only Review observations and findings, bounded Fix changed files and validation, then independent revalidation evidence; every result is joined by the Leader.\n- Result handoff path: FEATURE_DIR\u002Freview-results\u002F\u003Clane-id>.json\n\n## Codex Subagent Result Contract\n\n- Worker result contract: preserve the shared `WorkerTaskResult` semantics even when the runtime calls lanes subagents.\n- Preferred result contract: Three-wave Review result contract: read-only Review observations and findings, bounded Fix changed files and validation, then independent revalidation evidence; every result is joined by the Leader.\n- Result file handoff path: FEATURE_DIR\u002Freview-results\u002F\u003Clane-id>.json\n- For filesystem handoffs, use `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify result path --help` with the concrete workflow identifiers such as `--feature-dir`\u002F`--task-id`, `--workspace`\u002F`--lane-id`, or `--session-slug`\u002F`--lane-id`.\n- The result-path command emits JSON and does not accept `--format`; do not append `--format`.\n- Normalize subagent-reported statuses like `DONE`, `DONE_WITH_CONCERNS`, `BLOCKED`, and `NEEDS_CONTEXT` into the shared `WorkerTaskResult` contract before the leader accepts the handoff.\n- Keep `reported_status` when normalization occurs so runtime-specific subagent language can be reconciled with canonical orchestration state.\n- Wait for every subagent's structured handoff before accepting the join point, closing the batch, or declaring completion.\n- Do not treat an idle subagent as done work; idle without a consumed handoff means the result channel is still unresolved.\n- Do not interrupt or shut down subagent work before the handoff has been written or explicitly reported as `BLOCKED` or `NEEDS_CONTEXT`.\n- Treat `DONE_WITH_CONCERNS` as completed work plus follow-up concerns, not as silent success.\n- Treat `NEEDS_CONTEXT` as a blocked handoff that must carry the missing context or failed assumption explicitly.\n","## Invocation Syntax\n\n- In this integration, invoke workflow skills with `$sp-plan`-style syntax.\n- References such as `\u002Fsp.plan`, `\u002Fsp.tasks`, or `next_command: \u002Fsp.plan` are canonical workflow-state identifiers and handoff values.\n- Preserve those canonical state tokens exactly in artifacts and workflow state; do not rewrite them to this integration's invocation syntax.\n\n\n\n## Workflow Contract Summary\n\n- **When to use**: `implementation-handoff.json` exists, the deterministic workflow runtime is ready to transition from `implement` to `review`, and the integrated product needs system-level verification and repair.\n- **Primary objective**: Review the implemented software as an operable product, find broken startup, interaction, registration, and end-to-end wiring, repair understood in-scope defects, and revalidate the exact affected paths.\n- **Primary outputs**: A fresh approved `review-state.json`, integrated evidence under `review-evidence\u002F`, resolved or routed findings, and a final implementation summary plus Review-to-Accept handoff bound to the reviewed implementation fingerprint and runtime identity basis.\n- **Default handoff**: Continue the Leader-owned Review Universe through independent audit, Fix, join, and revalidation waves while the shared validation-epoch budget remains; approve only from fresh integrated proof, block when the third epoch fails, hand only proven truth gaps upstream, then hand human product acceptance to \u002Fsp.accept and stop.\n- **Execution note**: This summary is routing metadata only. Follow the full contract below end-to-end rather than inferring behavior from the description alone.\n\n## Blocked Exit Contract\n\nIf blocked after safe recovery, read and follow\n`.specify\u002Ftemplates\u002Fworkflow-blocker-template.md` and its JSON schema. Never\nreturn only an error or “ask a human”; preserve state and keep agent-capable\nrepair agent-owned. Set `human_action_required: true` only for authority,\ncredentials, protected systems, human decisions\u002Freviews, or physical access.\nTailor steps, expected results, failure paths, evidence, and resume action to\nCI, visual review, or product decisions. Never claim completion.\n\nFor a feature runtime blocker, do not invent `resume_argv` or overwrite an\nexisting blocker. The CLI returns a read-only `show_argv` and structured\n`resolution_action`; `next_argv` stays empty while evidence is missing. After\nthe criteria are proven, attach sanitized evidence using the action's declared\ninput and execute its base argv. It restores the same owner and keeps the full\nblocker audit.\n\n## User Input\n\n```text\n$ARGUMENTS\n```\n\nYou **MUST** consider the user input before proceeding (if not empty).\n\n## Objective\n\nProve that the integrated implementation is an operable product from its official real entrypoints, repair bounded implementation defects, and preserve enough evidence to resume or make the final review claim honestly.\n\n\n## Codex Project Cognition Advisory Gate\n\n**Crucial First Step**: You MUST use project cognition compass first: run `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe compass --intent implement '--query=\"$ARGUMENTS\"' --format json` before any system review, repair, or revalidation actions. Read and carry `epistemic_contract`; require `graph_role=route_candidate_only`, `fact_source_of_truth=live_repository`, `live_verification_required=true`, `graph_only_claims_allowed=false`, and `unverified_claim_action=withhold`. The contract cannot authorize source changes and cannot prove current behavior; contradictory live evidence overrides the route candidate. Graph claims are indexed assertions; even `verified_in_graph_generation` is only an active graph-generation state, not current repository truth. Graph claims cannot authorize source changes and cannot set workflow `claim_ready=true`; bounded live evidence and the separate workflow final-claim gate remain required. Read top-level `minimal_live_reads` first, then use lane-level `first_pass_paths` reasons, `verification_hints`, `followup_surfaces`, and `before_fix_claim`; treat `coverage_diagnostics` as confidence and closeout signals, never as route candidates. Treat `expansion_ref` as a normal continuation path and run `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe expand --id '\u003Cid>' --section '\u003Csection>' --format json` only when coverage state or live evidence requires more map detail. Do not infer final edit scope from `minimal_live_reads` or `first_pass_paths`. Readiness values are `query_ready`, `review`, `needs_rebuild`, `blocked`, and `unsupported_runtime`. When `compass_state=needs_semantic_intake`, write `semantic_intake` from project vocabulary and rerun compass with `--semantic-intake-file`, or use the advanced `lexicon -> semantic_intake -> query` path when explicit concept decisions are needed. Preserve advanced routing through `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe query --intent implement --query-plan '\"\u003Cquery_plan_json>\"' --format json` for precision cases.\n- Read and carry `epistemic_contract`; require `graph_role=route_candidate_only`, `fact_source_of_truth=live_repository`, `live_verification_required=true`, `graph_only_claims_allowed=false`, and `unverified_claim_action=withhold`. The contract cannot authorize source changes and cannot prove current behavior; contradictory live evidence overrides the route candidate. Graph claims are indexed assertions; even `verified_in_graph_generation` is only an active graph-generation state, not current repository truth. Graph claims cannot authorize source changes and cannot set workflow `claim_ready=true`; bounded live evidence and the separate workflow final-claim gate remain required.\n- Route every Compass packet by `recommended_next_action.action_id`, never by readiness alone. `query_ready` reads top-level `minimal_live_reads` first and then lane-level `first_pass_paths`; `review` permits only returned `minimal_live_reads` plus `coverage_diagnostics`; `needs_rebuild` may carry a resumable non-rebuild action such as `complete_scan_packets`, which must be preserved. Only `action_id=project_cognition.rebuild` may consume `rebuild_reasons[]` and the canonical Classic steps in `recommended_next_action.workflow_routes.classic.steps`; `action_id=project_cognition.repair_status` must run its returned `argv`. `blocked` reports the runtime issue as advisory map state and continues with live repository evidence unless the user's request is to repair cognition; `unsupported_runtime` continues with live evidence and records that compass intake was unavailable. If `baseline_kind=greenfield_empty`, continue with workflow artifacts and live requirements instead of inferring rebuild from absent graph paths.\n- Use `map-update` for ordinary existing-baseline gaps. If `baseline_kind=greenfield_empty`, do not recommend map-scan -> map-build solely because the graph has no paths; continue with workflow artifacts and live requirements. Use `map-scan -> map-build` only for brownfield first\u002Fmissing\u002Funusable baseline, schema failure, schema v1 or old broad-schema rebuild-required readiness, zero active-generation `path_index` rows outside `greenfield_empty`, missing or invalid `alias_index`, `explicit_rebuild_requested`, or `baseline_identity_invalid`.\n- Treat the project cognition compass packet as advisory navigation for brownfield context; do not fall back to chat memory or ad hoc repository instincts when compass-backed runtime coverage should guide the route.\n- Treat this as advisory navigation, not a hard gate; continue with live repository evidence when the bundle is weak, stale, or missing, and use map maintenance only when it is actually useful.\n- Mutation closeout is separate from entry routing: entry stale may continue, but workflow-owned mutation closeout is not an external map-maintenance handoff. If the workflow changes source\u002Fruntime truth-owning surfaces, shared surfaces, command\u002Froute\u002Fcontract boundaries, verification entry points, runtime assumptions, or other project-related behavior surfaces, final state must run inline project cognition update from changed paths, affected surfaces, and verification evidence.\n- Inline project cognition update uses `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe delta append --help` followed by `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe update --delta-session '\"$DELTA_SESSION_ID\"' --reason workflow-finalize --format json` when a delta session exists, or `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe update --payload-file '\".specify\u002Fproject-cognition\u002Fupdates\u002F\u003Cupdate-id>.json\"' --reason workflow-finalize --format json` when no delta session exists.\n- The payload-file path must include changed_paths, behavior_surfaces, generated_surfaces, state_contracts, verification, known_unknowns, and confidence_notes so the update is equivalent to `sp-map-update`, not just a path stamp; `verification_evidence` and `generated_surface_notes` are accepted compatibility aliases.\n- Use `known_unknowns` only for blockers that make the cognition update unsafe to trust. If unrelated dirty or untracked working-tree paths were excluded by explicit workflow-owned paths, record that as `confidence_notes` or `boundary.initial_dirty_paths`, not as blocking `known_unknowns`.\n- clean closeout keys on `result_state`, not `update_id`, `last_update_id`, or freshness alone. Treat `ready` and `no_op` as clean, `partial_refresh` as recorded but not fully clean, `needs_rebuild` as a map-scan\u002Fmap-build route, `blocked` as blocked, and `recorded` as legacy recorded-only output that is never clean completion.\n- Use `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe mark-dirty --reason '\"\u003Creason>\"' --format json` only when inline update cannot complete. Dirty only when inline update cannot complete.\n- `sp-map-update` is for manual\u002Fexternal maintenance and follow-up repair after user edits, interrupted workflows, or explicit operator map-maintenance requests. It is not routine cleanup for changes this workflow just made.\n- A project-cognition compass intake is not complete when it returns JSON. It is complete only when readiness drives routing, `minimal_live_reads` constrains inspection, lane-level `first_pass_paths` reasons are considered, and relevant facts are carried into the next workflow artifact or execution state.\n- Carry forward the selected user journeys, official entrypoints, affected runtime surfaces, minimal live reads, validation routes, and evidence gaps into `review-state.json` or the just-in-time review packet.\n\n## Process\n\n## Intake And Runtime Ownership\n\n- Resolve exactly one feature and inspect `workflow show` before mutation. Transition from completed `implement` to `review` with the runtime-returned revision; do not hand-edit `workflow-runtime.json`.\n- Run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review prepare --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --format json`. Treat `implementation-handoff.json` as the implementation-to-review source contract and `review-state.json` as Review's resumable truth. When `accept route-repair` reopens Review, preparation creates a new cycle bound to the prior approved Review digest and routed acceptance finding; never edit or reapprove the old cycle.\n- The Leader owns `review-state.json`, the official runtime instances, ports, test data, finding lifecycle, repair acceptance, and final verdict.\n- Continue the validation-epoch ledger shared across Implement and Review. Do\n  not reset it on Review entry, resume, or repair-cycle creation. The combined\n  flow permits at most three heavyweight epochs bound to source fingerprints.\n- The canonical ledger is\n  `implementation-review\u002Fvalidation-runs.json`. Before Review work run\n  `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify implement validation-status --feature-dir '\u003Cfeature-dir>' --format json`.\n  Before the Leader starts a delivery scenario wave, run\n  `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify implement validation-start --feature-dir '\u003Cfeature-dir>' --stage review --purpose delivery --command '''\u003Ccmd>''' '[--command' '''\u003Ccmd2>''' ']' '[--task-id' 'T001]' '[--task-id' 'T002]' '[--fingerprint' '\u003Csha>]' --format json`;\n  omit `--fingerprint` to bind the current implementation snapshot. Afterward run\n  `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify implement validation-finish --feature-dir '\u003Cfeature-dir>' --run-id '\u003CVn>' --status '\u003Cpassed|failed>' --evidence-ref '\u003Cref>' '[--evidence-ref' '\u003Cref2>]' --summary '''\u003Ctext>''' --format json`.\n  Use the runtime-returned ids and budget; never hand-edit the file.\n- On resume, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review resume-audit --feature-dir '\u003Cfeature-dir>' --format json` when available. Continue from the exact scenario\u002Ffinding cursor and invalidate evidence whose implementation fingerprint, source revision, or Review cycle is stale. Repair-cycle evidence belongs under `review-evidence\u002Fcycle-\u003Cn>\u002F` and packet\u002Fresults under `review-results\u002Fcycle-\u003Cn>\u002F`; an earlier cycle cannot close the current one.\n\n## System Review Loop\n\n1. Compile the Review Universe and use independent coverage discovery to reconcile authoritative obligations with actual consumer and runtime surfaces.\n2. Open the next Leader-owned validation epoch, start each official entrypoint,\n   then run a read-only Review\u002FAudit wave whose workers inspect assigned coverage\n   slices and return evidence\u002Ffindings without edits. All commands, scenarios,\n   and captures against that fingerprint share the one epoch.\n3. The Leader joins all audit packets, rejects stale or incomplete results, resolves coverage gaps, and freezes the accepted finding set.\n4. Run a separate Fix wave for accepted findings only when another validation\n   epoch remains. Fix workers receive isolated write scopes, run cheap task\n   checks, return test impact, and may change implementation\u002Ftests but never\n   upstream truth or execute heavyweight gates.\n5. Join and inspect every repair, then open the next remaining epoch, restart the\n   real product, and run an independent revalidation wave. The repair author must\n   not verify its own finding.\n6. Continue only while budget remains. A source change invalidates prior proof\n   and requires another epoch for approval. Never retry a failed command against\n   the unchanged fingerprint. The third failed epoch blocks with exact evidence\n   and recovery criteria; never start a fourth validation epoch.\n\nUI-bearing scenarios require real-entrypoint `structure_snapshot`, `visual_capture`, and `runtime_diagnostics` evidence with `evidence_scope: integrated`. Group the viewport\u002Fstate matrix by integrated surface and source fingerprint; do not run the full viewport\u002Fstate capture loop per Txx. Validate interaction, navigation, loading, empty, error, permission, persistence\u002Freload, responsive, keyboard\u002Ffocus, console, network, and runtime states when applicable. Automated behavior checks remain distinct from visual and interaction acceptance.\n\n## Delegation\n\n- The Leader orchestrates subagents across the Review\u002FAudit wave, Fix wave, and independent revalidation wave; direct execution is reserved for compact, tightly coupled steps.\n- Audit workers are read-only. Fix workers receive finding-bound, non-overlapping write scopes. Revalidation workers are read-only and independent from the repair author.\n- Compile each `SystemReviewPacket` just in time from current state and live code. Never dispatch a raw checklist or the entire feature package.\n- Serialize paths sharing one browser session, database state, service instance, port, or write set. Integrate worker results before accepting a repair.\n- A worker result is evidence only. A worker cannot declare coverage complete or the whole system approved; the Leader owns all joins, zero-uncovered coverage, repair acceptance, and the final verdict after an integrated restart and required regression.\n- Workers do not open validation epochs. The Leader may coordinate read-only\n  observation slices inside one already-open epoch, but must not let scenario,\n  worker, or Txx boundaries multiply heavyweight runs.\n\n## Output Contract\n\n- Keep `review-state.json` fresh and schema-valid with scenario results, findings, repair\u002Frevalidation evidence, cursor, blockers, and next action.\n- Store evidence under `review-evidence\u002F` and reference it compactly from state; do not paste large logs or screenshots into agent state.\n- Before the handoff, verify that `human_acceptance_obligations` and `human_acceptance_scenarios` still cover the frozen Human Acceptance Universe for every new or changed requirement with zero uncovered required obligations. Create `reviewed_runtime_targets` covering every required human scenario, with immutable official entrypoint, environment\u002Finstance\u002Fconfiguration, final snapshot, applicable artifact\u002Fdeployment\u002Fversion identity, linked Review scenarios, and existing fresh ready evidence. For each target, write the exact runtime identity JSON projection under `review-evidence\u002F` and, for repair cycle 2+, under `review-evidence\u002Fcycle-\u003Cn>\u002F`; record its feature-relative `identity_evidence_ref` and byte-exact `identity_evidence_sha256`. A `build` or `deployment` target also requires an existing feature-relative product\u002Fbuild `artifact_ref`, created before the final fingerprint, included in the implementation snapshot, outside `review-evidence\u002F`, `review-results\u002F`, and every other snapshot-excluded path, whose current bytes match `artifact_sha256`. Bind the exact target list with `final.runtime_targets_sha256`. Accept receives these targets, preserves both identity-evidence fields read-only, and may add only session readiness\u002Factions.\n- After the final integrated restart, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review validate --feature-dir '\u003Cfeature-dir>' --format json`, bind its `current_fingerprint` to `final.reviewed_snapshot_sha256`, and only then set Review `status: approved`. Run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review closeout --feature-dir '\u003Cfeature-dir>' --format json` only after all required scenarios pass, all required evidence is integrated and fresh, and blocking findings are zero.\n- On successful Review closeout, update Review-owned rich state truthfully, execute the returned revision-bound `workflow complete-stage` argv separately, hand off to `$sp-accept`, and stop. The Review-to-Accept handoff carries obligations, human scenarios, immutable reviewed targets, and their digest; it does not prefill human PASS. After an acceptance repair, Acceptance reruns every frozen scenario and preserves no old PASS. Do not enter acceptance in this invocation.\n\n## Guardrails\n\n- `sp-review` is not permission to change approved product scope or upstream truth. Every approved-scope defect stays in Review regardless of repair size, including missing code, task omission, and unknown root cause; use a diagnostic packet before a Fix packet when needed.\n- Review remains the stage owner through diagnosis, repair, and revalidation. Only a proven requirement truth, design truth, or architecture truth gap may produce an upstream handoff; missing code is not an upstream truth gap.\n- Keep the existing event-triggered task review embedded in `sp-implement`; do not duplicate its task lifecycle ledger here.\n- Do not claim success because the build passes, tasks are checked, files exist, or a worker says PASS.\n- Do not let a passive testing skill, worker, resume, or completion claim start an\n  extra epoch. Review must consume only the remaining shared budget.\n- Do not push, deploy, modify protected systems, use real customer data, or perform external writes without explicit authority. Use isolated test data and the shared blocker contract for genuine external boundaries.\n\n## Senior Consequence Analysis Gate\n\nRun this gate whenever the request, artifact set, defect, or planned change can affect lifecycle operations, running objects, concurrent work, destructive behavior, shared state, downstream consumers, compatibility, security-sensitive behavior, or multiple plausible product behaviors.\n\nAlso trigger it for a new or changed entry point over an existing operation, a direct\u002Fbackground\u002Fheadless\u002Fsystem entry point, or a changed consumer or interaction owner. Build the result inventory from current result\u002Ferror definitions, existing consumers, state transitions, tests, and UI\u002Fwindow\u002Frequest\u002Fretry owners. Reusing an executor proves operation reuse; it does not prove that the new consumer preserves every terminal, recoverable, partial, cancelled, or user-input-required outcome.\n\nProject cognition first. Use the project cognition runtime to identify ownership, consumers, state surfaces, change-propagation facts, verification routes, conflicts, known unknowns, and coverage gaps. Senior consequence analysis second. Turn those facts into explicit product and implementation obligations instead of treating the graph as the decision-maker.\n\nProject cognition readiness provides navigation state; route recovery by `recommended_next_action.action_id`. If readiness is `query_ready`, read top-level `minimal_live_reads` first, then use lane-level `first_pass_paths` reasons. If readiness is `review`, inspect the returned `minimal_live_reads` before continuing and treat `coverage_diagnostics` as confidence and closeout signals. If readiness is `needs_rebuild`, preserve resumable non-rebuild actions such as `complete_scan_packets`; only `action_id=project_cognition.rebuild` may consume `rebuild_reasons[]` and `recommended_next_action.workflow_routes.classic.steps` as a rebuild handoff. That rebuild route remains reserved for brownfield first\u002Fmissing\u002Funusable baseline, schema failure, schema v1 or old broad-schema rebuild-required readiness, zero active-generation `path_index` rows outside `greenfield_empty`, missing or invalid `alias_index`, `explicit_rebuild_requested`, or `baseline_identity_invalid`. If readiness is `blocked`, report the blocked state and continue with live repository evidence unless the user's actual request is to fix cognition runtime state. If readiness is `unsupported_runtime`, continue with live evidence and record that compass intake was unavailable. If `baseline_kind=greenfield_empty`, continue with workflow artifacts and live requirements; do not recommend map-scan -> map-build solely because the graph has no paths. Carry relevant project cognition facts, returned `minimal_live_reads`, inference notes, and coverage gaps into the workflow's artifacts or durable state, but back consequence claims with live code, tests, scripts, configuration, or authoritative docs. Mutation closeout is separate from entry routing: entry stale may continue, but that does not allow source\u002Fruntime mutation workflows to defer closeout. Workflow-owned mutation closeout is not an external map-maintenance handoff; after changing project-related files or behavior, the workflow must run inline project cognition update from its changed paths, affected surfaces, and verification evidence, with `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe mark-dirty` only as fallback when inline update cannot complete. `sp-map-update` is for manual\u002Fexternal maintenance and follow-up repair; it is external map maintenance, not routine closeout for this workflow's own changes. In shared routing summaries, sp-map-update is for manual\u002Fexternal maintenance and ordinary existing-baseline gaps.\n\nRequired output when the gate triggers:\n\n- **Affected Object Map**: name each object, record, worker, queue, artifact, command, API, file surface, user-visible state, or downstream consumer that can be affected.\n- **State-Behavior Matrix**: describe behavior for each important lifecycle state, including created, queued, running, paused, failed, cancelled, completed, resumed, archived, missing, stale, or partially refreshed states when relevant.\n- **Dependency Impact Table**: map direct dependencies, indirect consumers, shared state, compatibility surfaces, validation routes, and adjacent workflows that can break if semantics change.\n- **Recovery And Validation Contract**: state rollback, retry, idempotency, cleanup, migration, observability, and validation evidence required before handoff or completion.\n- **Coverage Gaps**: list what project cognition or live evidence cannot prove, who must resolve each gap, the latest safe resolve phase, the stop-and-reopen condition, and the routing decision: current workflow may continue with an assumption, must ask the user, must route to clarification or deep research, or must request map maintenance.\n- **Consequence Obligations**: assign stable `CA-###` IDs to every obligation that must survive downstream handoff, task generation, worker packets, verification, or debug closeout. Each `CA-###` must include claim, affected objects, owner workflow, latest resolve phase, status, and stop-and-reopen condition.\n- **Entrypoint Outcome Contract**: when the entry-point trigger applies, persist `entrypoint_outcome_contract` in `spec-contract.json`. Keep live-evidence-backed result inventory separate from product dispositions, and map every preserved or adapted outcome to acceptance refs and `CA-###` consequence refs. Plan and Tasks consume those CA refs through the existing consequence chain; do not create a parallel outcome ledger downstream.\n\nStand down only for docs-only wording changes, trivial isolated fixes, or local refactors that cannot affect lifecycle operations, running state, destructive operations, shared state, downstream consumers, compatibility, security, or multiple behavior choices. Record the no-trigger reason or stand-down reason in the workflow's durable artifact or closeout before skipping the required outputs.\n\nIf the gate triggers and the current workflow cannot preserve the required outputs, stop and route to the workflow that can. Do not mark ready, resolved, handoff-ready, planning-ready, or complete while triggered consequence obligations remain unresolved, unmapped, or unsupported by validation evidence.\n\n## Agent Phase Handoff\n\nPhase handoff is an agent-only control surface. Human-facing explanation belongs in the visible reply or in project documents that have independent review value; it must not be duplicated into a handoff.\n\n- The previous phase's canonical JSON contract is the next phase's primary input.\n- Use the compact transition shape from `.specify\u002Ftemplates\u002Fagent-phase-transition-schema.json`: `status`, `source_ref`, `semantic_delta`, `required_refs`, `blockers`, `next_action`, and recovery only when blocked.\n- Carry the minimum sufficient context: include a fact only when omitting it could change the next action, lose a requirement or obligation, force rediscovery, weaken verification, or prevent safe recovery.\n- Preserve decisions, acceptance criteria, evidence provenance, `MP-*`, `CA-###`, and stop\u002Freopen conditions by stable reference. Do not copy their full bodies into every downstream artifact.\n- Protected `MP-*` and `CA-###` obligations must not drop between phases. A downstream phase may resolve or reopen them, but may not silently omit them.\n- Carry the locked implementation-target reference. A cross-project transition must not silently point to the current repository when the confirmed target differs.\n- Consume project rules and Learning through `learning start --command \u003Cclassic-command-name> -> list -> show`; run selected `show_argv` only. Constitution remains at `.specify\u002Fmemory\u002Fconstitution.md`; never parse Learning storage.\n- Capture at owning closeout only when the lesson would change a future action; prefer `learning capture-auto`.\n- A rendered Markdown view is never an agent handoff authority. Do not require Markdown\u002FJSON companion agreement.\n- Revalidate upstream truth only when its revision changed, evidence became stale, live repository facts contradict it, or the current phase discovers a scope, boundary, feasibility, or risk change.\n- If `semantic_delta` is empty, do not repeat upstream questions, approach selection, or user confirmation.\n\n## Deterministic Workflow Runtime\n\nFor a feature-bearing `specify -> plan -> tasks -> implement -> review -> accept` stage,\nthe CLI owns phase order in `FEATURE_DIR\u002Fworkflow-runtime.json`. Do not author\nor advance `workflow-runtime.json` by hand. `workflow-state.md` remains the rich\nworkflow-owned evidence and resume surface for Learning, clarification,\nresearch, analysis, and profile-specific details; the phase runtime must not overwrite\nor parse it as its revision authority.\n\n- After `FEATURE_DIR` is known, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow show --feature-dir '\u003Cfeature-dir>' --format json`. If state is missing at the first feature stage, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow enter --command specify --feature-dir '\u003Cfeature-dir>' --format json`.\n- On entry to `plan`, `tasks`, `implement`, `review`, or `accept`, use the current revision with `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow transition --to '\u003Cthis-stage>' --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --format json` before writing that stage's artifacts. The command validates the completed source-stage artifacts and refuses skips, stale revisions, or incomplete handoffs with exit `10`.\n- After the owning stage finishes its artifact closeout, run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow complete-stage --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --format json`. The runtime validates the stage artifacts, records non-terminal `status: completed`, and returns the one legal transition argv; do not edit phase state manually.\n- The destination command owns the returned transition. A completed stage recommends the next command but must not execute `workflow transition` to that next stage in the same invocation.\n- Use `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow next --feature-dir '\u003Cfeature-dir>' --format json` for the compact next action. While a stage is active its `next_argv` completes that stage; after completion it transitions to the successor. Execute only structured argv and do not reconstruct flags from prose.\n- When fresh evidence invalidates an earlier required stage, preserve the stale\n  artifacts for audit and reopen the highest invalid stage with\n  `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow reopen --to '\u003Cspecify|plan|tasks|implement|review>' --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --reason '\u003Ccompact-reason>' --evidence '\u003Csanitized-evidence>' --invalidated-artifacts '\u003Cartifact>' --format json`.\n  Repeat `--evidence` and `--invalidated-artifacts` as needed. The CLI permits\n  a strict backward move or reactivation of the same completed non-accept stage,\n  including `implement` and `review`; an active same-stage owner simply continues. Honor any\n  persisted blocker before retrying. Failed acceptance uses\n  `accept route-repair`, never generic reopen. Every non-human-access acceptance\n  failure first reopens Review; the Review Leader diagnoses it, dispatches an\n  independent Fix and revalidation cycle, and may reopen an upstream truth\n  owner only after proving that correct implementation is impossible under the\n  current requirement, design, or architecture truth. After any repair, rerun\n  the full frozen Human Acceptance Universe; preserve no stale human PASS.\n- After safe agent recovery is exhausted, persist the blocker through `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify workflow block --input '\u003Cblocker-json-or->' --format json`. Obtain its exact input shape with `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify api schema workflow-block-input --format json`; the runtime rejects replacement of an unresolved blocker and returns the human tutorial, a safe read-only `show_argv`, and a structured `data.resolution_action`. While evidence is missing, `next_argv` is intentionally empty.\n- When the recorded unblock criteria are proven, append each sanitized evidence item to the runtime-returned `resolution_action.base_argv` using its declared `--resolution-evidence` required input, then execute that argv. This invokes `workflow resolve`, preserves the full prior blocker audit, and reactivates the same stage; do not reconstruct other flags or clear blocker state manually.\n- After explicit human acceptance, run the acceptance-owned `accept closeout` command and execute its successful response's `next_argv` verbatim. That revision-bound argv invokes `workflow closeout`; do not reconstruct it from prose or a remembered revision. It validates and snapshots acceptance evidence before marking the feature workflow complete.\n\nFor every blocked exit, including a pre-feature discussion that cannot use the\nfeature runtime yet, follow\n`.specify\u002Ftemplates\u002Fworkflow-blocker-template.md` and its schema. Report the\nexact cause, sanitized evidence, attempted recovery and result, affected scope,\nsmallest next action, observable unblock criteria, and exact resume point. Keep\nagent-capable repair agent-owned. When authority, credentials, a protected\nsystem, physical access, or human judgment is genuinely required, add the full\nHuman Action Guide: goal, prerequisites, safety notes, numbered exact actions,\nexpected result and safe failure branch for every action, independent\nverification, sanitized evidence to return, and the exact resume command.\n\n[AGENT] For project-cognition-backed semantic intake, routing, audit, resume, or final-claim gates, read `references\u002Fsemantic-work-contract.md`.\n\n## Main Flow\n\n1. Run `.specify\u002Fscripts\u002Fpowershell\u002Fcheck-prerequisites.ps1 -Json -RequireTasks -IncludeTasks` to resolve one implemented feature and inspect repository status. Initial Review transitions from validated `implement`; an acceptance repair arrives through CLI-owned `accept route-repair` with `review` already active. Run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review prepare --feature-dir '\u003Cfeature-dir>' --expected-revision '\u003Crevision>' --format json`; stop when the implementation handoff, fingerprint, prior approved Review digest, routed acceptance finding, or revision is missing, stale, or ambiguous. Acceptance repair must create the next immutable Review cycle rather than editing or reapproving the old cycle.\n2. Read `implementation-handoff.json`, current `review-state.json`, required acceptance refs, official entrypoints, and only the live source needed for the current scenario. Continue the validation-epoch ledger shared across Implement and Review; do not reset its consumed count on phase entry, resume, worker dispatch, or Review cycle creation. Treat this as the mandatory system review after implementation; retain the embedded task review inside `sp-implement` as a separate task-level control.\n3. Compile the bounded Review Universe from authoritative acceptance obligations, official entrypoints, changed consumer surfaces, runtime-discovered controls and registrations, and affected regression paths. Use independent coverage discovery so the handoff scenario matrix is a minimum rather than a blind spot; the Leader owns the zero-uncovered reconciliation. Before executing a heavyweight command or real scenario, open the next Leader-owned validation epoch against the current source fingerprint. The combined Implement\u002FReview workflow permits at most three; scenario slices within that epoch share it rather than incrementing the count.\n4. Start the software from every applicable official real entrypoint and wait for its declared ready signal. The Leader orchestrates subagents through an independent read-only Review\u002FAudit wave: compile just-in-time audit `SystemReviewPacket`s with disjoint coverage slices, join every result, reconcile duplicate or missing findings, and forbid audit workers from editing product code or declaring coverage complete. In an acceptance repair cycle, assign the routed observation to an accepted read-only diagnostic Review worker and store all new scenario evidence under `review-evidence\u002Fcycle-\u003Cn>\u002F` and all packet\u002Fresults under `review-results\u002Fcycle-\u003Cn>\u002F`; evidence from an earlier cycle cannot close the new one.\n5. Exercise real actions and observable results inside that epoch. Trace button, link, menu, form, command, route, handler, provider, factory, service, persistence or external dependency, and user feedback wiring where applicable. For UI scenarios capture integrated `structure_snapshot`, `visual_capture`, and `runtime_diagnostics` evidence from the real entrypoint once per applicable surface\u002Ffingerprint. Do not run the full viewport\u002Fstate capture loop per Txx.\n6. After the audit join, run an independent Fix wave only when a validation epoch remains. The Leader sends bounded Fix workers one or more accepted findings with authoritative expected behavior, isolated write scopes, forbidden truth artifacts, and exact regression obligations. Fix workers run cheap task checks and report test impact; they do not independently start heavyweight verification. Every approved-scope defect stays inside Review regardless of repair size: missing code, a task omission, incomplete tests, broken wiring, and an unknown root cause are not reasons to exit. Use a read-only diagnostic packet for an unknown root cause; Review remains the stage owner and then dispatches the repair itself. If the failed epoch consumed the final slot, preserve the findings and block without an unprovable repair.\n7. Join and inspect every repair result, then, only when budget remains, open the next validation epoch, restart the integrated product, and run an independent revalidation wave. A repair author must not verify its own finding; the Leader or a different read-only subagent reruns the exact failed journey, dependent scenarios, and credible regression set against the post-repair fingerprint. That bounded set attributes finding-level revalidation only: after any Fix, approval still requires every required Review scenario and all required evidence against the single final reviewed snapshot in that same epoch. No pre-Fix scenario evidence can satisfy approval. Record the complete accepted Fix-set digest plus an exact byte-bound full-matrix evidence manifest in the final revalidation; partial, missing, extra, or relabeled scenario evidence also blocks approval. The third failed epoch blocks with exact evidence and resume criteria; never start a fourth. Cycle 1 uses the same path, cycle-id, and byte-digest gates as later cycles.\n8. Only a proven upstream truth gap may stop Review: requirement truth that is missing or contradictory, design truth that is missing or contradictory, or architecture truth that must change before any correct implementation is possible. Missing code is not an upstream truth gap. After all packets joined and the Review Universe reports zero uncovered obligations and surfaces, create at least one `reviewed_runtime_targets` record for every required Human Acceptance scenario. Bind each target to its official entrypoint, final reviewed snapshot, exact environment\u002Finstance\u002Fconfiguration identity, applicable artifact\u002Fdeployment\u002Fversion identity, linked Review scenarios, and existing fresh ready-evidence refs. For every target, write an exact identity JSON projection under `review-evidence\u002F` (`review-evidence\u002Fcycle-\u003Cn>\u002F` in repair cycle 2+) and record its feature-relative `identity_evidence_ref` plus the SHA-256 of its current bytes as `identity_evidence_sha256`. This valid JSON has top-level `version` equal to `1`, `status` equal to `\"ready\"`, and a `target` object containing exactly `id`, `mode`, `entrypoint_id`, `environment_ref`, `instance_ref`, `configuration_ref`, `reviewed_snapshot_sha256`, `artifact_ref`, `artifact_sha256`, `deployment_id`, `observed_version`, `review_scenario_ids`, and `ready_evidence_refs`, with every value copied exactly from the reviewed target. For `build` and `deployment`, require `artifact_ref` to point to an existing feature-relative product\u002Fbuild file created before the final fingerprint, included in the implementation snapshot, and outside `review-evidence\u002F`, `review-results\u002F`, and every other snapshot-excluded path; `artifact_sha256` must match its current bytes. Compute the final target digest only after these fields are bound. Run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review validate --feature-dir '\u003Cfeature-dir>' --format json`, bind its current fingerprint, and approve only with fresh cycle-specific integrated evidence and zero blocking findings. Validate the frozen Human Acceptance Universe against the delivered new or changed requirement set. The Review-to-Accept handoff contains the obligations, scenarios, approved runtime targets, identity-evidence fields, and digest; Accept preserves the two identity-evidence fields read-only, may add only session readiness\u002Factions, and never prefills human PASS. Then run `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify review closeout --feature-dir '\u003Cfeature-dir>' --format json`, execute its returned `workflow complete-stage` argv separately, recommend `$sp-accept`, and stop. After an acceptance repair, every human scenario is reset and must be rerun; Review must not preserve a stale human PASS.\n\n### Inline Project Cognition Update\n\nWorkflow-owned mutation closeout is not an external map-maintenance handoff and is not external map maintenance. It is the workflow-local form of `$sp-map-update`. If this workflow changed project-related source, runtime, templates, generated assets, config, tests, state contracts, shared surfaces, or behavior-bearing docs, closeout MUST run inline project cognition update for the workflow-owned changed paths and affected surfaces before claiming clean completion.\n\nCall the planner first:\n\n```text\nC:\\Users\\11034\\.specify\\bin\\project-cognition.exe closeout-plan --workflow '\"$ACTIVE_WORKFLOW\"' --format json\n```\n\nWhen `DELTA_SESSION_ID` exists, pass it into the planner:\n\n```text\nC:\\Users\\11034\\.specify\\bin\\project-cognition.exe closeout-plan --workflow '\"$ACTIVE_WORKFLOW\"' --delta-session '\"$DELTA_SESSION_ID\"' --format json\n```\n\nConsume `workflow_canonical`, `update_mode`, `payload_draft`, `required_agent_fields`, `unknown_paths`, `unknown_path_dispositions`, `delta_append_draft`, display-only `delta_append_command`, `update_argv`, display-only `update_command`, and `recommended_next_command`.\n\nBefore running `update`, fill the fields listed in `required_agent_fields` from live evidence from this workflow. Supported agent-owned evidence fields include:\n\n- `verification`\n- `behavior_surfaces`\n- `generated_surfaces`\n- `state_contracts`\n- `known_unknowns`\n- `confidence_notes`\n- `user_decisions`\n- `boundary`\n\nIf a field appears in `required_agent_fields`, provide live-evidence-backed content for it. Fields not listed by `required_agent_fields`, such as `known_unknowns` and `boundary`, are populated only when live evidence supports them; do not invent them to satisfy the shape.\nUse `known_unknowns` only for blockers that make the cognition update unsafe to trust. If the working tree contains unrelated dirty\u002Funtracked paths and the workflow uses explicit workflow-owned paths, record that as `confidence_notes` or `boundary.initial_dirty_paths`, not as a blocking `known_unknowns` item.\n\nFor each `unknown_path_dispositions[]` item, set `agent_disposition` to exactly one allowed value:\n\n- `adoptable`: verified new path inside this workflow-owned scope; it may be recorded in changed\u002Fscope paths and verified adoptable paths do not become blocking `known_unknowns`.\n- `review_only`: path informed review but is not adopted into changed coverage.\n- `ignored`: path remains excluded and must not enter payloads, records, route indexes, evidence, aliases, or minimal live reads.\n- `blocking_known_unknown`: record it as a known unknown and report partial or blocked cognition closeout.\n\n`agent_disposition=adoptable` is an agent accounting decision, not proof that runtime indexing already succeeded. Runtime adoption still requires a usable active project-cognition DB, at least one passing verification evidence item, and no blocking `known_unknowns`. After `update_argv` runs, inspect `result_state`, `adopted_paths`, `review_paths`, `minimal_live_reads`, and `partial_refresh_reasons`; do not explain a remaining `partial_refresh` as \"path_index missing\" until those fields show which adoption gate failed.\n\nIf `update_mode=delta_session`, complete `delta_append_draft.argv_prefix` with agent-owned repeatable flags such as `--behavior-surface`, `--generated-surface`, `--verification`, and accepted `--known-unknown` values from `delta_append_draft.argv_placeholders`. Then append the delta event and run `update_argv`. `delta_append_command` and `update_command` are display-only placeholders, not execution strings.\n\nIf `update_mode=payload_file`, write the completed `payload_draft` to the planner's `payload_path`. Then run `update_argv`. `update_command` is a display-only placeholder, not an execution string.\n\nCompleted payload drafts preserve the planner-owned `changed_paths` and `scope_paths` and add agent-owned evidence fields before recording.\n\nStructured `update` invalidates related claims and returns their stable IDs in `affected_graph_claims`. This is separate from update readiness: generic workflow verification and `result_state=ready` must not re-promote stale or contradicted graph claims. Only when this workflow already has decisive claim-specific bounded live evidence for an exact returned claim ID may it submit semantic reconciliation intent and run:\n\n```text\nC:\\Users\\11034\\.specify\\bin\\project-cognition.exe claim-reconcile prepare --input '\u003Cintent.json>' --format json\nC:\\Users\\11034\\.specify\\bin\\project-cognition.exe claim-reconcile apply --input '\u003Cprepared_packet_path>' --format json\n```\n\nProvide only reconciliation intent: workflow, stable `claim_id`, reason, and evidence containing repository-relative `source_path`, bounded line `span`, and `supporting` or `contradicting` role. Add verification only when it is claim-specific. The runtime owns the contract version, active generation, expected state and revision, UTC observation and expiry, source kind, content hashes, repository snapshot, IDs, and prepared packet path. Do not author or edit those integrity fields; execute the returned `apply_argv` exactly. If no such evidence exists, leave the claim stale. If reconciliation returns ready, rerun Compass once so later routing consumes the current evidence basis; partial or blocked reconciliation remains withheld and follows `recommended_next_action`.\n\nFor compatibility with worker handoffs and delta packets, the runtime also accepts `verification_evidence` as an alias for `verification` and `generated_surface_notes` as an alias for `generated_surfaces`. Verification evidence may be an array of objects (`command`, `result`, `artifact`) or an array of command-result strings, but clean closeout still requires passing verification evidence; failed verification cannot produce a clean `ready` closeout.\n\nClean closeout keys on `result_state`, not `status=ok`, `update_id`, `last_update_id`, or freshness alone:\n\n- `ready` or `no_op`: project cognition closeout may be clean when ordinary verification also passed.\n- `partial_refresh`: useful update data was written, but the final workflow state must report partial cognition closeout, `partial_refresh_reasons`, and the returned `minimal_live_reads`. If `partial_refresh_reasons` includes `missing_passing_verification_result`, repair the payload or delta evidence and rerun `update_argv` before final closeout; do not route that to `sp-map-update`. If verified workflow-owned paths still remain in `review_paths` after the update, report implementation completion separately from project-cognition maintenance and name `$sp-map-update` as follow-up repair.\n- `needs_rebuild`: report the exact rebuild condition and route to `$sp-map-scan`, then `$sp-map-build`.\n- `blocked`: report the runtime or validation blocker and the exact recovery command.\n- `recorded`: legacy recorded-only output; treat it as partial or blocked, never as clean completion.\n\nNever run the `complete-refresh` or `clear-dirty` helper after `result_state=partial_refresh`, `needs_rebuild`, `blocked`, or legacy `recorded`; those helpers are only for states that the runtime and validation prove ready.\n\nDirty fallback command shape: `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe mark-dirty --reason '\"\u003Creason>\"' --format json`.\nUse `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe mark-dirty --reason '\"workflow-closeout-failed\"' --format json` only when inline update cannot complete: when the planner or update command is unavailable, cannot record useful update data, cannot identify workflow-owned scope, or cannot be trusted because verification\u002Fworkflow completion is not trustworthy. Dirty only when inline update cannot complete.\n\nsp-map-update is for manual\u002Fexternal maintenance and follow-up repair. `$sp-map-update` remains the external\u002Fmanual workflow for user edits, interrupted workflow repair, explicit map maintenance, and follow-up repair. It is not routine cleanup for changes this workflow just made. If `sp-map-update` already ran `C:\\Users\\11034\\.specify\\bin\\project-cognition.exe update --reason map-update` for the same changed paths, do not run a second `workflow-finalize` closeout update for those paths.\n\n## Detailed References\n\nRead [Reference index](references\u002FINDEX.md) before applying detailed contracts.\n\n- [system scenario contract](references\u002Fsystem-scenario-contract.md)\n- [subagent review contract](references\u002Fsubagent-review-contract.md)\n- [repair and revalidation](references\u002Frepair-and-revalidation.md)\n- [final claim and handoff](references\u002Ffinal-claim-and-handoff.md)\n\n## Codex Subagent Dispatch Contract\n\n- Execution model: `subagents-first`\n- Dispatch shape: `one-subagent`, `parallel-subagents`, or `subagent-blocked`\n- Execution surface: `native-subagents`, `managed-team`, or `leader-inline`\n- Delegation surface contract: preserve the native dispatch, fallback, worker result contract, and handoff path below.\n- Native subagent capability discovery: Before recording `subagent-blocked`, confirm the current runtime exposes `spawn_agent`, `wait_agent`, and `close_agent`; if they are not visible, use the active tool discovery mechanism for multi-agent or subagent tools first.\n- Do not record `subagent-blocked` until this capability discovery step is complete and the exact unavailable or unsafe surface is recorded.\n- Native subagent dispatch: Dispatch bounded subagents through `spawn_agent`.\n- Join behavior: Rejoin with `wait_agent`, integrate, then `close_agent`. The Leader joins every Review, Fix, and independent revalidation result before the final verdict.\n- Managed-team fallback: The Review Leader must preserve separate audit, Fix, and independent revalidation waves. If no native subagent surface exists, record the coverage blocker rather than silently claiming zero uncovered.\n- Leader-inline fallback: record the reason before local execution.\n- Worker result contract: Three-wave Review result contract: read-only Review observations and findings, bounded Fix changed files and validation, then independent revalidation evidence; every result is joined by the Leader.\n- Result contract: Three-wave Review result contract: read-only Review observations and findings, bounded Fix changed files and validation, then independent revalidation evidence; every result is joined by the Leader.\n- Result handoff path: FEATURE_DIR\u002Freview-results\u002F\u003Clane-id>.json\n\n## Codex Subagent Result Contract\n\n- Worker result contract: preserve the shared `WorkerTaskResult` semantics even when the runtime calls lanes subagents.\n- Preferred result contract: Three-wave Review result contract: read-only Review observations and findings, bounded Fix changed files and validation, then independent revalidation evidence; every result is joined by the Leader.\n- Result file handoff path: FEATURE_DIR\u002Freview-results\u002F\u003Clane-id>.json\n- For filesystem handoffs, use `uvx --from git+https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Fspec-kit-plus.git@6fbbf08a0b6833bb783ec6b418d567776b197ae4 specify result path --help` with the concrete workflow identifiers such as `--feature-dir`\u002F`--task-id`, `--workspace`\u002F`--lane-id`, or `--session-slug`\u002F`--lane-id`.\n- The result-path command emits JSON and does not accept `--format`; do not append `--format`.\n- Normalize subagent-reported statuses like `DONE`, `DONE_WITH_CONCERNS`, `BLOCKED`, and `NEEDS_CONTEXT` into the shared `WorkerTaskResult` contract before the leader accepts the handoff.\n- Keep `reported_status` when normalization occurs so runtime-specific subagent language can be reconciled with canonical orchestration state.\n- Wait for every subagent's structured handoff before accepting the join point, closing the batch, or declaring completion.\n- Do not treat an idle subagent as done work; idle without a consumed handoff means the result channel is still unresolved.\n- Do not interrupt or shut down subagent work before the handoff has been written or explicitly reported as `BLOCKED` or `NEEDS_CONTEXT`.\n- Treat `DONE_WITH_CONCERNS` as completed work plus follow-up concerns, not as silent success.\n- Treat `NEEDS_CONTEXT` as a blocked handoff that must carry the missing context or failed assumption explicitly.\n",{"name":5,"metadata":24,"description":7,"compatibility":27},{"author":25,"source":26},"github-spec-kit","templates\u002Fcommands\u002Freview.md","Requires spec-kit project structure with .specify\u002F directory","main","021f5cbe02157229460a577e9a585f2da6d78cb0",".codex\u002Fskills\u002Fsp-review","https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck","https:\u002F\u002Fgithub.com\u002Fchenziyang110","2026-08-07 18:10:54",{"source":8,"skillName":5,"commands":35,"prompt":45,"zipAvailable":46},[36,39,42],{"tool":37,"command":38},"npx","npx skills add chenziyang110\u002Flaunchdeck --skill sp-review",{"tool":40,"command":41},"bunx","bunx skills add chenziyang110\u002Flaunchdeck --skill sp-review",{"tool":43,"command":44},"pnpm","pnpm dlx skills add chenziyang110\u002Flaunchdeck --skill sp-review","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.codex\u002Fskills\u002Fsp-review\u002FSKILL.md",true,[48,54,58,62,66,70],{"path":49,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":52,"sourceHtmlUrl":53},"references\u002Ffinal-claim-and-handoff.md","REFERENCE","参考文档",5413,"https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.codex\u002Fskills\u002Fsp-review\u002Freferences\u002Ffinal-claim-and-handoff.md",{"path":55,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":56,"sourceHtmlUrl":57},"references\u002FINDEX.md",1118,"https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.codex\u002Fskills\u002Fsp-review\u002Freferences\u002FINDEX.md",{"path":59,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":60,"sourceHtmlUrl":61},"references\u002Frepair-and-revalidation.md",5613,"https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.codex\u002Fskills\u002Fsp-review\u002Freferences\u002Frepair-and-revalidation.md",{"path":63,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":64,"sourceHtmlUrl":65},"references\u002Fsemantic-work-contract.md",32447,"https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.codex\u002Fskills\u002Fsp-review\u002Freferences\u002Fsemantic-work-contract.md",{"path":67,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":68,"sourceHtmlUrl":69},"references\u002Fsubagent-review-contract.md",3680,"https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.codex\u002Fskills\u002Fsp-review\u002Freferences\u002Fsubagent-review-contract.md",{"path":71,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":72,"sourceHtmlUrl":73},"references\u002Fsystem-scenario-contract.md",3163,"https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.codex\u002Fskills\u002Fsp-review\u002Freferences\u002Fsystem-scenario-contract.md",[75,82,88,94,101,110],{"skillNo":76,"name":77,"nameZh":6,"description":78,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":19},"01M7875F3HQ1GF5F6BR36KY3JE","launchdeck-agent","Codex host adapter contract fixture for Launchdeck.","https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002Ftest\u002Ffixtures\u002Fagent-hosts\u002Fcodex\u002Fskill\u002FSKILL.md",[],[],{"skillNo":83,"name":77,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":19},"01M7875DV2DQR33K1NFJHKAMZP","Claude host adapter contract fixture for Launchdeck.","https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002Ftest\u002Ffixtures\u002Fagent-hosts\u002Fclaude\u002Fskill\u002FSKILL.md",[],[],{"skillNo":89,"name":77,"nameZh":6,"description":90,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":91,"categories":92,"keywords":93,"publishedAt":19},"01M78759JQ7A6FQ8KDQTNYS3X9","Use this skill aggressively for local project lifecycle operations even when the user does not mention Launchdeck: start this project, run the dev server, dev, build, test, restart service, stop service, show logs, inspect ports, port is occupied, clean cache; and when the user explicitly asks to configure this local project for Launchdeck or create or generate a project-adapted `.launchdeck.yml`, including 为这个项目生成 Launchdeck 配置. Do not use for ordinary code edits, docs-only work, general explanations, API design discussion, or production deployment unless the user also asks to operate or configure a local project or service.","https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002Fagent\u002Finstaller-payload\u002Fskill\u002Flaunchdeck-agent\u002FSKILL.md",[],[],{"skillNo":95,"name":96,"nameZh":6,"description":97,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":98,"categories":99,"keywords":100,"publishedAt":19},"01M78753ZJQ7G2CZT1W1G8WRJV","zig-testing","Use ONLY when user explicitly requests Zig test code, built-in test runner configuration,\ntest failure diagnosis, or coverage for Zig projects.\n\nTriggers: \"write test zig\", \"zig test\", \"testing.allocator\", \"zig coverage\",\n\"comptime test\", \"zig expectError\", \"zig snapshot test\", \"zig fuzz\".\n\nDo NOT activate for: general Zig coding without test context, build.zig configuration\nfor non-test targets, Zig compiler errors, or Zig build system setup.","https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.specify\u002Ftemplates\u002Fpassive-skills\u002Fzig-testing\u002FSKILL.md",[],[],{"skillNo":102,"name":103,"nameZh":6,"description":104,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":105,"licenseFileUrl":106,"sourceHtmlUrl":107,"categories":108,"keywords":109,"publishedAt":19},"01M78750JXY4Z5D5W1EX3PQ31Z","webapp-testing","Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.specify\u002Ftemplates\u002Fpassive-skills\u002Fwebapp-testing\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.specify\u002Ftemplates\u002Fpassive-skills\u002Fwebapp-testing\u002FSKILL.md",[],[],{"skillNo":111,"name":112,"nameZh":6,"description":113,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":114,"categories":115,"keywords":116,"publishedAt":19},"01M7874X2T83EQQFRCEY5SJJVC","verification-before-completion","Use when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always","https:\u002F\u002Fgithub.com\u002Fchenziyang110\u002Flaunchdeck\u002Fblob\u002Fmain\u002F.specify\u002Ftemplates\u002Fpassive-skills\u002Fverification-before-completion\u002FSKILL.md",[],[]]