import { z } from "zod"; export declare const DiagnosticEventSchema: z.ZodObject<{ id: z.ZodString; sequence: z.ZodNumber; at: z.ZodNullable; type: z.ZodString; action: z.ZodNullable; correlationId: z.ZodNullable; attempt: z.ZodNullable; taskId: z.ZodNullable; status: z.ZodNullable; errorCode: z.ZodNullable; cleanupComplete: z.ZodNullable; }, z.core.$strict>; export declare const DiagnosticCallSchema: z.ZodObject<{ id: z.ZodString; kind: z.ZodString; status: z.ZodString; receiptId: z.ZodNullable; maximumUsd: z.ZodNullable; settledUsd: z.ZodNullable; model: z.ZodNullable; durationMs: z.ZodNullable; inputTokens: z.ZodNullable; outputTokens: z.ZodNullable; totalTokens: z.ZodNullable; }, z.core.$strict>; declare const Content: z.ZodObject<{ schemaVersion: z.ZodLiteral<"openpond.runDiagnostics.v1">; teamId: z.ZodString; runId: z.ZodString; location: z.ZodEnum<{ hosted: "hosted"; local: "local"; }>; manifestHash: z.ZodString; observedAt: z.ZodISODateTime; status: z.ZodString; startedAt: z.ZodNullable; completedAt: z.ZodNullable; error: z.ZodNullable; resultAvailable: z.ZodBoolean; parent: z.ZodNullable; heartbeatAt: z.ZodNullable; leaseExpiresAt: z.ZodNullable; releasedAt: z.ZodNullable; errorCode: z.ZodNullable; }, z.core.$strict>>; accounting: z.ZodObject<{ maximumUsd: z.ZodNullable; settledUsd: z.ZodNullable; outstandingUsd: z.ZodNullable; outstandingCount: z.ZodNullable; final: z.ZodBoolean; receiptCount: z.ZodNullable; }, z.core.$strict>; events: z.ZodArray; type: z.ZodString; action: z.ZodNullable; correlationId: z.ZodNullable; attempt: z.ZodNullable; taskId: z.ZodNullable; status: z.ZodNullable; errorCode: z.ZodNullable; cleanupComplete: z.ZodNullable; }, z.core.$strict>>; nextEventCursor: z.ZodNullable; eventCount: z.ZodNumber; calls: z.ZodArray; maximumUsd: z.ZodNullable; settledUsd: z.ZodNullable; model: z.ZodNullable; durationMs: z.ZodNullable; inputTokens: z.ZodNullable; outputTokens: z.ZodNullable; totalTokens: z.ZodNullable; }, z.core.$strict>>; nextCallCursor: z.ZodNullable; callCount: z.ZodNumber; limitations: z.ZodArray; }, z.core.$strict>; export declare const RunDiagnosticsSchema: z.ZodObject<{ schemaVersion: z.ZodLiteral<"openpond.runDiagnostics.v1">; teamId: z.ZodString; runId: z.ZodString; location: z.ZodEnum<{ hosted: "hosted"; local: "local"; }>; manifestHash: z.ZodString; observedAt: z.ZodISODateTime; status: z.ZodString; startedAt: z.ZodNullable; completedAt: z.ZodNullable; error: z.ZodNullable; resultAvailable: z.ZodBoolean; parent: z.ZodNullable; heartbeatAt: z.ZodNullable; leaseExpiresAt: z.ZodNullable; releasedAt: z.ZodNullable; errorCode: z.ZodNullable; }, z.core.$strict>>; accounting: z.ZodObject<{ maximumUsd: z.ZodNullable; settledUsd: z.ZodNullable; outstandingUsd: z.ZodNullable; outstandingCount: z.ZodNullable; final: z.ZodBoolean; receiptCount: z.ZodNullable; }, z.core.$strict>; events: z.ZodArray; type: z.ZodString; action: z.ZodNullable; correlationId: z.ZodNullable; attempt: z.ZodNullable; taskId: z.ZodNullable; status: z.ZodNullable; errorCode: z.ZodNullable; cleanupComplete: z.ZodNullable; }, z.core.$strict>>; nextEventCursor: z.ZodNullable; eventCount: z.ZodNumber; calls: z.ZodArray; maximumUsd: z.ZodNullable; settledUsd: z.ZodNullable; model: z.ZodNullable; durationMs: z.ZodNullable; inputTokens: z.ZodNullable; outputTokens: z.ZodNullable; totalTokens: z.ZodNullable; }, z.core.$strict>>; nextCallCursor: z.ZodNullable; callCount: z.ZodNumber; limitations: z.ZodArray; contentHash: z.ZodString; }, z.core.$strict>; export type RunDiagnostics = z.infer; export type DiagnosticEvent = z.infer; export type DiagnosticCall = z.infer; export declare const RunDiagnosticsQuerySchema: z.ZodObject<{ afterSequence: z.ZodOptional; afterCallId: z.ZodOptional; }, z.core.$strict>; export declare function sealRunDiagnostics(value: z.input): RunDiagnostics; export declare function verifyRunDiagnostics(raw: unknown, scope: { teamId: string; runId: string; manifestHash?: string; afterSequence?: number; afterCallId?: string; }): { schemaVersion: "openpond.runDiagnostics.v1"; teamId: string; runId: string; location: "hosted" | "local"; manifestHash: string; observedAt: string; status: string; startedAt: string | null; completedAt: string | null; error: string | null; resultAvailable: boolean; parent: { id: string; status: string; attempt: number | null; heartbeatAt: string | null; leaseExpiresAt: string | null; releasedAt: string | null; errorCode: string | null; } | null; accounting: { maximumUsd: number | null; settledUsd: number | null; outstandingUsd: number | null; outstandingCount: number | null; final: boolean; receiptCount: number | null; }; events: { id: string; sequence: number; at: string | null; type: string; action: string | null; correlationId: string | null; attempt: number | null; taskId: string | null; status: string | null; errorCode: string | null; cleanupComplete: boolean | null; }[]; nextEventCursor: number | null; eventCount: number; calls: { id: string; kind: string; status: string; receiptId: string | null; maximumUsd: number | null; settledUsd: number | null; model: string | null; durationMs: number | null; inputTokens: number | null; outputTokens: number | null; totalTokens: number | null; }[]; nextCallCursor: string | null; callCount: number; limitations: string[]; contentHash: string; }; /** Deliberately excludes prompt, output, arguments, messages and arbitrary metadata. */ export declare function diagnosticEvent(input: { id: string; sequence: number; at: string | null; type: string; payload: unknown; }): DiagnosticEvent; export type DiagnosticSpan = { id: string; label: string; taskId: string | null; startedAt: string | null; completedAt: string | null; durationMs: number | null; status: string; evidenceIds: string[]; }; /** Partial pages remain partial; unmatched endings are never invented starts. */ export declare function diagnosticSpans(events: DiagnosticEvent[]): DiagnosticSpan[]; export declare function diagnosticAnalysisPrompt(value: RunDiagnostics, events?: { id: string; sequence: number; at: string | null; type: string; action: string | null; correlationId: string | null; attempt: number | null; taskId: string | null; status: string | null; errorCode: string | null; cleanupComplete: boolean | null; }[], calls?: { id: string; kind: string; status: string; receiptId: string | null; maximumUsd: number | null; settledUsd: number | null; model: string | null; durationMs: number | null; inputTokens: number | null; outputTokens: number | null; totalTokens: number | null; }[]): string; /** Export only a stable technical reason; arbitrary exception text is not model context. */ export declare function diagnosticFailure(value: string | null | undefined): string | null; export {}; //# sourceMappingURL=run-diagnostics.d.ts.map