import { type JsonObject } from '../depot/shape.js'; /** Depot's CLI appends this whenever a diagnosis or suggested fix is present; keep it verbatim. */ export declare const AI_DISCLOSURE = "This diagnosis is AI-generated and can make mistakes."; export interface EvidenceLine { stepId: string | undefined; lineNumber: number | undefined; content: string; contentTruncated: boolean; } export interface AttemptRef { attemptId: string | undefined; jobId: string | undefined; jobKey: string | undefined; attempt: number | undefined; attemptStatus: string | undefined; attemptConclusion: string | undefined; errorMessage: string | undefined; diagnosis: string | undefined; possibleFix: string | undefined; evidence: EvidenceLine[]; evidenceOmitted: number; } export interface FailureGroup { fingerprint: string | undefined; source: string | undefined; count: number | undefined; errorMessage: string | undefined; errorMessageTruncated: boolean; diagnosis: string | undefined; possibleFix: string | undefined; attempts: AttemptRef[]; omittedRepresentativeCount: number | undefined; } export interface DiagnosisContext { repo: string | undefined; ref: string | undefined; sha: string | undefined; trigger: string | undefined; runId: string | undefined; runStatus: string | undefined; workflowId: string | undefined; workflowName: string | undefined; workflowPath: string | undefined; workflowStatus: string | undefined; jobId: string | undefined; jobKey: string | undefined; jobDisplayName: string | undefined; jobStatus: string | undefined; jobConclusion: string | undefined; attemptId: string | undefined; attempt: number | undefined; attemptStatus: string | undefined; truncatedContextFields: string[]; } export interface NarrowerTarget { targetType: string | undefined; targetId: string | undefined; label: string | undefined; status: string | undefined; failedJobCount: number | undefined; nextStep: NextStep | undefined; } export interface NextStep { kind: string; label: string | undefined; tool: string | undefined; arguments: Record; } export interface DiagnosisTruncation { byDepot: boolean; byServer: boolean; omittedFailureGroups: number; omittedAttempts: number; notes: string[]; } export interface Diagnosis { state: string; emptyReason: string | undefined; target: { targetId: string | undefined; targetType: string | undefined; status: string | undefined; }; context: DiagnosisContext; failureGroups: FailureGroup[]; representativeAttempts: AttemptRef[]; narrowerTargets: NarrowerTarget[]; nextSteps: NextStep[]; truncation: DiagnosisTruncation; aiDisclosure: string | undefined; } export interface DiagnosisLimits { readonly maxFailureGroups: number; readonly maxEvidenceLines: number; } export declare function parseDiagnosis(response: JsonObject, limits: DiagnosisLimits): Diagnosis; //# sourceMappingURL=diagnosis.d.ts.map