Reviewer validation recovery¶
For review-inspection-schedule-wait-invalid, distinguish a real malformed wait from a host-rejected call that never executed. Current schedule validation admits a call with only the extra target argument when its matched receipt is the exact host unknown-field parse rejection and its next tool call is the canonical wait_agent retry with the same valid timeout. The rejected call supplies no scheduling opportunity or reviewer coverage; real waits, launch order, context delivery, joins and every required pass still need normal proof. Preserve both calls and outputs unchanged and reassemble authentic evidence with the compatible validator. A corrected reader can admit previously rejected valid provenance without rewriting history; an executed malformed wait, missing or changed retry, unknown error, denial or actual schedule mismatch remains rejected. Finish remaining authorized passes and producer completion rather than treating this deterministic admission defect as permanently missing independent coverage.
For review-inspection-dispatch-order-mismatch:
- Compare the generated queue and actual first-spawn order, preserve the rejected wave, and revalidate the retained source receipts. Historical launch order cannot be repaired by rewriting dispatch or provenance; this is not a supported
prepare-repairkind. - With verified source, do not recollect GitHub evidence solely for this failure: use Current parent fallback when independence is not required in the current user-authorized scope, including an explicit coverage waiver, then complete its nonapproval report and normal closing gates. Otherwise continue safe inspection and ask only for the concrete unmet independent-route decision.
- A mismatch not supported by the recorded calls remains a validator/host hypothesis to investigate, never permission to bypass admission. Actual source drift, denied capability and exhausted retry limits retain their existing stops.
For direct review-child-session-missing:<role>:<task_name>, zero child sessions match the prepared task identity; this is not evidence of duplicate sessions. Compare the expected name in dispatch.json with actual parent spawn arguments, receipts and child metadata before diagnosing the cause. A shortened or renamed task remains unbound: preserve the original records, never rewrite names or accept role-only matching. review-child-session-not-unique still rejects duplicate expected children; historical routes may also use it for missing children, so inspect the actual match count. When the existing parent fallback is permitted, execute it through its normal closing gates in this turn. Announcing a fallback is not executing it. Preserve all existing controlling stops, including missing decisions, unavailable prerequisites or capabilities, denials, unverified source, and exhausted recovery or recurrence limits; unfinished authorized work alone is not a stop.
For review-inspection-dispatch-interrupted, inspect the parent launch and tool-call receipts against the frozen queue and allocated slots. This error describes a parent scheduling interruption and does not by itself prove a child was interrupted. Preserve the rejected wave; do not use interrupted-dispatch repair unless the distinct child-abort and interrupt evidence required below is actually present. A parent tool call to retrieve a queued dispatch during a free-capacity launch is still rejected by the current scheduler; do not rewrite the trace or relabel it as an accepted child pass. When no supported native repair applies, revalidate the source and complete the separate permitted parent fallback if independence is not required; otherwise preserve the uncovered requirement and its exact blocker. For future waves, retrieve every generated call before the first spawn as directed in the skill.
For review-inspection-context-not-sent:<role>, explain: "The validator could not confirm that the specialist received the exact code and instructions prepared for this review. Its results cannot be accepted yet, but available code inspection can continue." Inspect retained context and safe provenance before attributing the rejection to encrypted logs or any other cause; if the cause is not established, say so. Other validation errors need their own evidence-backed explanation, not this diagnosis by default.
An agent-owned reader-command error, proved parent interruption before assessment or supported response representation mismatch is an internal protocol failure, not a PR source finding. Diagnose it against the original dispatch, child calls/results, terminal response or abort and parent receipts. Use the same run and current wave when the bounded helper proves recovery eligible; do not require a fresh complete PR review solely because that attempt was rejected.
Do not interrupt healthy ordered page reads because a future, unexecuted frame appears malformed. Compare the suspected frame with the frozen generated recipe; transfer that recipe verbatim and preserve unaffected reviewers and the complete pending roster. A suspected typo is not an executed reader failure, and opaque launch transport cannot prove its plaintext. Enforce actual deadlines and diagnosed failures without inventing missing evidence.
Keep generated page commands exact. Current schema-eight reads with the current reader admit only these bounded variations:
- The optional outer
max_output_tokenscomment may be omitted, including on the bounded failed-plan call and its immediate retry. The exact JavaScript body, explicit inner budget, command and complete returned source bytes remain mandatory. - A completed read may retain one extra failed call only when the verified reader proves the sole changed argument was a nonexistent plan path, its matching command receipt proves exit 1 before source loading, and the exact canonical read of that same page follows immediately. Every canonical page, ordered output and receipt remains mandatory.
- A completed read may also retain one nonexistent reader-file path in that same frame: only the reader argument changes, its absolute path keeps the expected reader basename, the matched Python cannot-open-file diagnostic names that path with exit 2, and the exact canonical same-page read follows immediately. The launcher, plan, role, attempt, page, budgets and JavaScript wrapper stay exact; no reader or source executes in the failed call. Changed launchers, other argument changes or unproved diagnostics remain rejected.
- A malformed JSON value in only the optional outer comment may retain its matched host parsing rejection when no command executed, the JavaScript body is exact, and the canonical same-page call follows immediately. The validator must independently establish invalid JSON and the supported host pre-execution diagnostic; valid JSON with unsupported fields, unknown errors, changed code or missing execution evidence remain rejected.
At most one incidental failed call is admissible per completed child: a proved missing-plan failure, missing-reader failure or malformed-comment rejection, never a combination or repeated failures. Optional comment omission may accompany any supported correction. The failed call never supplies coverage, authorizes another reviewer attempt, or admits other command changes; retain and disclose it. Resume ordinary assembly using unchanged evidence after a supported correction; every canonical source page and execution receipt remains mandatory.
Reviewer presentation follows Acceptance and recovery. Ordinary, main and batch text readers accept unambiguous equivalent Markdown: trailing whitespace, blank field separators, wrapped rationale, same-level ATX spacing/closing markers and valid JSON fence variants. Legacy rating/rationale pairs may also use labeled inline fields. Generated prompts use a consistent example format; that example is not a cosmetic acceptance gate. Shared extraction keeps admission, aggregate consumption and eligible repairs consistent while preserving original response bytes and opaque rationale text.
Required section/field identities, unique declarations, nonempty explanations, valid rating/readiness combinations, complete JSON inventories and factual/provenance bindings still govern admission. Headings or declarations inside fenced examples do not supply actual assessments; duplicate sections and conflicting or malformed fields remain invalid. Historical dispositions require their independent source witness and a nonempty explanation, not a minimum word count or prescribed prose prefix. The parent still checks whether cited evidence supports the conclusion; parsing cannot establish factual truth from wording alone. JSON and structured assessments keep their existing schema.
- Inspect
review_prepare.py prepare-repair --help, then run it with the retained wave, actual Codex home, affected role and supported kind. - a.
incomplete-dispatchrequires a proved incorrect reader command. It must be one of these cases:- A zero-source preassessment failure.
- An exact ordered successful page prefix followed by a proved missing-reader path failure. Its receipt may contain the exact whole diagnostic on stdout or stderr; mixed or extra output remains invalid.
- Exactly one duplicated-interpreter page call with its binary-script diagnostic and exit-1 command receipt. Retain the complete attempted page order and permit subsequent canonical reads; neither partial attempt satisfies source coverage.
- b. The replacement independently reads every page; preliminary source exposure never substitutes for that full assessment. Opaque paged dispatch transport uses exact parent-to-child delivery plus audited page commands and results, as normal admission does. The proved incomplete original may use
**Reviewer Assessment**; its rating and rationale still attest incomplete coverage. Completed replacement assessments retain the canonical heading and full-source requirements. - c.
closure-evidence-shaperequires otherwise admissible source evidence and only a list of nonempty closure strings where one string was required. - d.
assessment-formatrequires an otherwise valid current batch response with one canonical assessment heading and exactlyRating: <1-5> — <nonempty one-line explanation>. The helper derives only replacement of that separator with a newline andRationale:; the literal rating, explanation and all other response bytes stay unchanged. The missing label remains invalid until the exact generated correction passes the normal two-attempt representation-repair checks. Other malformed layouts and mixed errors do not qualify. - e.
finding-id-namespacecorrects exactly one supplied qualified source-origin ID copied into a reviewer-localid.- The admitted source ledger and exact frozen context witness must uniquely prove the original local ID and identical non-ID finding fields.
- The corrected ID must satisfy
[A-Za-z][A-Za-z0-9_-]{0,63}without collisions. The helper replaces only that JSON value token; all other response bytes remain exact. - Unknown or ambiguous origins, unsupported intermediate origins, duplicate keys, mixed errors and changed claims do not qualify. Ordinary ID validation remains strict.
- f. Unknown provenance, changed source, mixed/unrelated tools or altered source coordinates cannot qualify.
- g.
interrupted-dispatchapplies only to Code Review's current schema-eight native route with its pinned reader. Require authenticated original spawn and child delivery, one task turn, a genuineturn_abortedevent, and one matching parent interrupt call/result reportingprevious_status=running. Their child, turn and timing must agree. The child must have executed a nonempty exact ordered successful reader prefix shorter than the complete context, then been interrupted before any source-informed assessment or finding. Opening messages explicitly markedphase="commentary"may precede the first reader call only when both retained event order and timestamps place them after task start and strictly before that call; retain every host representation unchanged. This pre-source commentary supplies no finding, assessment or coverage. Missing phase, final output, and any assistant message after reading begins remain ineligible, including commentary. A reader failure, extra tool/activity, denied operation, completed task, missing or repeated abort, continued turn or changed source/card/model/effort makes this recovery ineligible. Never infer eligibility from parent-written status labels. The helper proves this boundary before generating one independent replacement that reads every page; the prefix supplies no accepted source coverage. - Preserve original
_a1launch/read/output/join evidence when present, its genuine abort/interrupt receipts when interrupted, and the frozen plan. An interrupted original has no fabricated final answer, output path, assessment or join. - a. Copy the helper's exact replacement arguments from
repair-dispatch.<role>.json; dispatch one generated_a2and join it. - b. Dispatch correction performs complete generated reads and a fresh independent assessment. Representation correction performs only the generated lossless transformation.
- c. Preserve every claim, severity, source coordinate, confidence and assessment.
- d. Finding IDs remain unchanged except for the single proven local-ID token in
finding-id-namespace; retain the original raw ID and immutable qualified origin witness. - e. No substantive reassessment or replacement of an unfavorable finding is permitted for representation repair.
- f. For
interrupted-dispatch, preserve unaffected sibling work and dispatch every pending original role in generated order before recovery preparation or replacement launch. The original allocation ends only after both abort and interrupt receipt; accepted source coverage and overlap use the complete replacement interval. Keep the ordinary two-attempt ceiling: another interruption cannot authorize a third attempt or erase an assessment. - Inspect the actual replacement response and update its assessment from evidence, then run normal
assembleorassemble-wave. Schema-eight admission validates both attempts and the correction; historical schema-seven retry rules stay strict. Keep valid sibling outputs and completed earlier waves. Resume by the frozen topology: - a. For
source-only, complete remaining source waves, runassemble-batches, then continue gates, validation, promotion and the completion checkpoint. - b. For historical inventories without
review_topology, resume required source waves, interaction review and consolidation before those same closing gates. - c. Do not create a rejected interaction or consolidation wave for source-only topology or skip a declared historical stage.
- d. Do not ask for permission already granted by the review request.
- A failed correction, denied capability, exhausted limit or unprovable source/provenance stops that repair route. Preserve its diagnostic and continue unrelated authorized inspection or the existing permitted parent fallback. Never relabel the failure transient, overwrite frozen artifacts, bypass a validator, or equate partial review with completed specialist coverage. Ask only for a genuinely missing decision after permitted continuation is exhausted. If repair is ineligible but source remains verified and the current scope does not require independence, immediately execute Current parent fallback through its completion checkpoint. The repair diagnostic alone is not a reason to stop the turn or ask the user to rerun; only an actual missing decision, denied capability or unverified source pauses its dependent work.
Continue permitted diagnosis and bounded internal repair under existing authorization.
- Do not ask for permission to correct agent-owned dispatch, assemble existing evidence, complete missing passes or finish the report.
- Modifying plugin implementation during a review is separate work: defer it and use the supported parent fallback unless that work was already requested.
- Only a genuinely missing decision about expanded scope or a sensitive/protected effect warrants a question; name that exact action and consequence, with separate canonical options
ApproveandDenyin the selected permitted native control.
Explain the branches before opening that necessary control:
- Approve: investigate the supported repair, apply it only within granted authority, then revalidate; do not promise success or bypass provenance checks. If it cannot be repaired, explain the remaining cause and available alternative.
- Deny or repair deferred: finish the available review and disclose the actual coverage limitation. Do not automatically start a fresh sequential review, substitute reviewer, or another repair request. Only a separately authorized parent inspection may continue. Preserve rejected attempts and frozen plans separately; create a separate fallback plan under the existing inspection route, perform substantive new parent inspection, and run normal completion checks. Never relabel rejected specialist work as parent evidence. A complete
TRIVIALorLOCALschema-five parent-only review may pass without required independence when every other gate passes; other multi-role substitutes cannot pass. - User explicitly required independent coverage: disclose any unmet requirement honestly. An explicit waiver of that coverage authorizes the separate revised-scope parent fallback and its normal gates. Declining or dismissing an optional repair does not itself waive required independence: deliver available findings with the limitation, mark the original review incomplete and do not repeat the request or invent a finding. Reuse a waiver already given for the same scope.
Before invoking this generated question, complete User Questions' native discovery checkpoint, including the current plugin's deferred ask_user in functions.exec ALL_TOOLS when exposed. Absence from the short tool list is not unavailability. Unknown async rendering is unsuitable. Record the selected route and its supporting evidence before invocation. The selected control owns the question and options; do not echo them in commentary or final output. A text-delivered async question remains pending without resubmission merely to change its appearance.
Without a missing decision, take the permitted continuation rather than ask for redundant approval. Optional repair refusal is distinct from denied runtime permission or a retry-limit stop; retain those boundaries. State exactly which acceptance condition remains unmet and what would satisfy it, rather than calling the entire review permanently blocked.