# stage triage ```output { timeline, hypotheses, evidence_plan, access_constraints, evidence_round: 0, max_evidence_rounds } Preserve the incident description and available evidence. ``` ```prompt Extract the incident description, time window, evidence, and access constraints from the user's runtime prompt. Return blocked if essential scope is missing. Initialize evidence_round=0 and max_evidence_rounds=2 unless a lower budget is requested; preserve these fields and the original request in the output. Scope symptoms, affected users, timing, and recent changes. Separate confirmed facts from assumptions and plan read-only evidence collection. Respect access constraints; return blocked if safe investigation is not possible. Do not restart services, deploy fixes, change configuration, or mutate production data. ``` ```edges success -> collector blocked -> #failure error -> #failure ``` ```configs provider=opencode-go model=deepseek-v4.1-flash retries=0 ``` # stage collector ```output { evidence_bundle, collection_commands, observations, missing_evidence, evidence_round, max_evidence_rounds } Preserve prior evidence, timeline, and hypotheses. ``` ```prompt Collect authorized logs, traces, metrics, and relevant source/config snapshots using read-only operations. Redact secrets and personal data. Record commands, timestamps, and failures without inventing observations. Before collecting, return exhausted if evidence_round is already at the budget; otherwise increment it for this pass. Do not execute unsafe reproduction steps against production. ``` ```edges success -> diagnostician exhausted -> #failure error -> #failure ``` ```configs provider=opencode-go model=deepseek-v4.1-flash retries=0 ``` # stage diagnostician ```output { root_cause?, supporting_evidence, alternative_explanations, confidence, requested_evidence?, remediation_plan } Preserve evidence counters and access constraints for another collection pass. ``` ```prompt Test hypotheses against the collected evidence. Reproduce only in an authorized isolated environment, if available. Return needs_evidence with a precise request when another collection pass can resolve uncertainty. Otherwise return success to report either a supported diagnosis or explicitly inconclusive findings. Suggest remediation and validation steps, but do not apply changes. ``` ```edges success -> report needs_evidence -> collector error -> #failure ``` ```configs provider=opencode-go model=deepseek-v4.1-flash retries=0 ``` # stage report ```output { incident_report, evidence_references, unresolved_questions, proposed_next_steps } ``` ```prompt Produce a concise incident report distinguishing confirmed facts, inferred causes, and unknowns. Link evidence and propose a separate, authorized fix workflow. Return success only for an evidence-supported root cause; return inconclusive when uncertainty remains. An inconclusive diagnosis must not look like a successful resolution. Do not perform remediation or claim the incident has been fixed. ``` ```edges success -> #success inconclusive -> #failure error -> #failure ``` ```configs provider=opencode-go model=deepseek-v4.1-flash retries=0 ```