/** * The ReticleVerificationRun artifact — the stable, versioned contract a host platform (an OEM/design * partner) or CI consumes after Reticle verifies a generated/edited app. It is assembled from data Reticle * already produces (flow replay, asserts, evidence timeline, source mapping); this file only defines * the WIRE/DISK shape so it can be frozen under semver. Persisted at `.reticle/runs/.json` and * returned by the programmatic Replay/Verify API. * * Conventions match the rest of `@reticlehq/core`: enums are `as const` objects narrowed with * `z.nativeEnum`, timestamps are epoch-ms NUMBERS (the clock is injected — never read inside pure * logic), no `any` (opaque evidence is `z.unknown`), and every domain string is a named constant. */ import { z } from 'zod'; import { PredicateKind } from './consequence.js'; import { Verified } from './verified-constants.js'; /** Schema version stamped into every run file so a reader can reject/upgrade old artifacts. */ export declare const RUN_FILE_VERSION = 3; /** * A run's identity, branded so it can't be confused with another id (e.g. a flow name) that also feeds * path helpers. The schema brands on parse; mint a fresh one with asRunId at a trusted/validated point. */ export declare const RunIdSchema: z.ZodBranded; export type RunId = z.infer; /** Mint a RunId from a raw string — call only at a validated boundary (e.g. behind isValidRunId). */ export declare const asRunId: (value: string) => RunId; /** * Retention bound for .reticle/runs/ so disk stays bounded over a long-running pipeline. Pruned * oldest-first only once the count exceeds RUN_RETENTION + RUN_RETENTION_SLACK, then back down to * RUN_RETENTION — so the O(n) prune is amortized (≈ once per SLACK writes), not paid on every write. */ export declare const RUN_RETENTION = 500; export declare const RUN_RETENTION_SLACK = 100; /** Structured outcome when reading a run file fails (never thrown). Mirrors ProjectReadError. */ export declare const RunReadError: { readonly MISSING: "run-missing"; readonly MALFORMED: "run-malformed"; }; export type RunReadError = (typeof RunReadError)[keyof typeof RunReadError]; /** The overall verdict on a verification run. PARTIAL = some flows passed, some failed/were gated. */ export declare const VerdictStatus: { readonly PASS: "pass"; readonly FAIL: "fail"; readonly PARTIAL: "partial"; /** * Nothing was proved either way -- no flow and no check produced an outcome, so there is nothing * to pass and nothing to fail. * * This is deliberately NOT a pass. A run that checked nothing and a run that checked everything * successfully are different facts, and flattening them into one word is how a green light comes * to mean "we did not look". It matches how a single action is already judged, where "could not * tell" has always been its own answer. */ readonly UNKNOWN: "unknown"; }; export type VerdictStatus = (typeof VerdictStatus)[keyof typeof VerdictStatus]; /** Per-flow outcome inside a run. HEALED = a drifted anchor was consequence-verified and rebound. */ export declare const RunFlowStatus: { readonly PASS: "pass"; readonly FAIL: "fail"; readonly SKIPPED: "skipped"; readonly HEALED: "healed"; }; export type RunFlowStatus = (typeof RunFlowStatus)[keyof typeof RunFlowStatus]; /** * What one drive came to, and the only place that is decided. A check that came back no is the only * failure. Checks nobody could decide, or a goal the model judged missed with no check against it, * are NOT PROVED (`skipped`): undecided evidence calls for a better check, never a code change, and * a drive with nothing failed was reported "1 broken" before this rule was one rule. */ export declare function driveFlowStatus(checks: { held: number; failed: number; goalMet?: boolean | undefined; }): RunFlowStatus; /** * The kind of standalone assertion captured outside a flow. * * This is `PredicateKind` -- the vocabulary assertions are written in -- and not a second list: two * lists drift, and an artifact can only record what somebody can actually assert. Re-exported so * the places that read it from this file still can. */ export { PredicateKind }; /** * What a check came out as. * * `Verified` and not a second list. A binary one here would lose `unknown` and `no-fault` -- the * two the specification says make the other two mean anything -- at the moment the verdict is * written down. Re-exported so the places that read it from this file still can. */ export { Verified }; /** * A risk surface a changed file / observed behaviour touches. The governance seed: a host can gate * a deploy when a high-severity surface is hit. Mirrors the surfaces real AI-app-builder incidents * cluster around (production data loss, auth/payment/RLS mistakes). */ export declare const RiskSurface: { readonly AUTH: "auth"; readonly PAYMENT: "payment"; readonly DB: "db"; readonly MIGRATION: "migration"; readonly RLS: "rls"; readonly SECRETS: "secrets"; readonly DESTRUCTIVE: "destructive"; readonly EXTERNAL: "external"; }; export type RiskSurface = (typeof RiskSurface)[keyof typeof RiskSurface]; /** Severity of a flagged risk. */ export declare const RiskSeverity: { readonly LOW: "low"; readonly MEDIUM: "medium"; readonly HIGH: "high"; readonly CRITICAL: "critical"; }; export type RiskSeverity = (typeof RiskSeverity)[keyof typeof RiskSeverity]; /** What caused the run (so a host can distinguish an agent's inner loop from a CI gate). */ export declare const RunTrigger: { readonly EDIT: "edit"; readonly CI: "ci"; readonly MANUAL: "manual"; readonly OEM: "oem"; }; export type RunTrigger = (typeof RunTrigger)[keyof typeof RunTrigger]; /** How a changed file changed (drives the risk tagger). */ export declare const RunChangeKind: { readonly ADDED: "added"; readonly MODIFIED: "modified"; readonly DELETED: "deleted"; }; export type RunChangeKind = (typeof RunChangeKind)[keyof typeof RunChangeKind]; /** Who/what drove the run. */ export declare const RunAgentKind: { readonly CODING_AGENT: "coding-agent"; readonly OEM_PIPELINE: "oem-pipeline"; readonly HUMAN: "human"; }; export type RunAgentKind = (typeof RunAgentKind)[keyof typeof RunAgentKind]; /** The app framework, when known. */ export declare const RunFramework: { readonly REACT: "react"; readonly NEXT: "next"; readonly VITE: "vite"; readonly OTHER: "other"; }; export type RunFramework = (typeof RunFramework)[keyof typeof RunFramework]; /** Where the run executed. */ export declare const RunEnv: { readonly PREVIEW: "preview"; readonly CI: "ci"; readonly LOCAL: "local"; }; export type RunEnv = (typeof RunEnv)[keyof typeof RunEnv]; /** Verdict confidence. */ export declare const RunConfidence: { readonly HIGH: "high"; readonly MEDIUM: "medium"; readonly LOW: "low"; }; export type RunConfidence = (typeof RunConfidence)[keyof typeof RunConfidence]; /** * The data profile a run was produced under. DEV exposes dev-only fields (source file:line, raw * network bodies, full state dumps); PROD_PREVIEW redacts them. The artifact records which profile * produced it so a consumer can never mistake a redacted run for a complete one. */ export declare const RunProfile: { readonly DEV: "dev"; readonly PROD_PREVIEW: "prod-preview"; }; export type RunProfile = (typeof RunProfile)[keyof typeof RunProfile]; /** A source coordinate, when source mapping is available (DEV profile only). */ export declare const SourceLocationSchema: z.ZodObject<{ file: z.ZodString; line: z.ZodOptional; component: z.ZodOptional; }, "strip", z.ZodTypeAny, { file: string; component?: string | undefined; line?: number | undefined; }, { file: string; component?: string | undefined; line?: number | undefined; }>; export type SourceLocation = z.infer; /** A file the change set touched, with the risk surfaces it implicates. */ export declare const RunChangedFileSchema: z.ZodObject<{ path: z.ZodString; changeKind: z.ZodNativeEnum<{ readonly ADDED: "added"; readonly MODIFIED: "modified"; readonly DELETED: "deleted"; }>; risk: z.ZodDefault, "many">>; }, "strip", z.ZodTypeAny, { path: string; changeKind: "added" | "modified" | "deleted"; risk: ("auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external")[]; }, { path: string; changeKind: "added" | "modified" | "deleted"; risk?: ("auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external")[] | undefined; }>; export type RunChangedFile = z.infer; /** * How much of a replay a synced run carries, so a teammate can replay it from the cloud without the * artifact growing with the flow: past these, the per-step list stops and the recording is omitted * (said so by `recordingOmitted`), never cut mid-flow into a journey nobody drove. */ export declare const RUN_STEP_RESULTS_MAX = 200; export declare const RUN_TEXT_MAX = 300; export declare const RUN_RECORDING_MAX_BYTES: number; /** * Where a step screenshot's pixels came from. `browser` is a real screenshot (CDP, a leased page, or * the desktop shell's own window capture); `rendered` is the page drawn in-page by the SDK, which can * miss cross-origin images and fonts, so a reader is told it is approximate. */ export declare const ScreenshotSource: { readonly BROWSER: "browser"; readonly RENDERED: "rendered"; }; export type ScreenshotSource = (typeof ScreenshotSource)[keyof typeof ScreenshotSource]; /** How a step screenshot is taken and kept — shared by the daemon, the SDK and the platform. */ export declare const STEP_SCREENSHOT: { /** `.reticle/visual/runs//-.jpg` */ readonly RUNS_DIR: "runs"; /** One line per landed screenshot, beside the images: what the run artifact and the upload read. */ readonly MANIFEST_FILE: "shots.jsonl"; readonly JPEG_QUALITY: 0.7; readonly MAX_SIDE_PX: 1600; /** The platform refuses more than this for one run, so the daemon stops taking them there. */ readonly MAX_PER_RUN: 300; /** The platform refuses an image larger than this, decoded. */ readonly MAX_BYTES: number; }; /** One step's screenshot as a run artifact records it. `file` is relative to the run's directory. */ export declare const StepScreenshotSchema: z.ZodObject<{ file: z.ZodString; source: z.ZodNativeEnum<{ readonly BROWSER: "browser"; readonly RENDERED: "rendered"; }>; width: z.ZodNumber; height: z.ZodNumber; sha256: z.ZodString; }, "strip", z.ZodTypeAny, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }>; export type StepScreenshot = z.infer; /** Every screenshot a run took, in order — including the actions that produced no verdict. */ export declare const RunScreenshotSchema: z.ZodObject<{ file: z.ZodString; source: z.ZodNativeEnum<{ readonly BROWSER: "browser"; readonly RENDERED: "rendered"; }>; width: z.ZodNumber; height: z.ZodNumber; sha256: z.ZodString; } & { seq: z.ZodNumber; tool: z.ZodString; /** The flow step it belongs to, as `#`, when it was taken during a replay. */ step: z.ZodOptional; /** Taken for a call that produced a verdict — what lets the run pair it with its check. */ verdict: z.ZodOptional; /** The check this picture is of (see `RunCheck.checkId`), when it could be paired with one. */ checkId: z.ZodOptional; /** The journal action it was taken for: how a run pairs it with its check (`RunCheck.actionId`). */ actionId: z.ZodOptional; }, "strip", z.ZodTypeAny, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; seq: number; tool: string; step?: string | undefined; verdict?: boolean | undefined; checkId?: string | undefined; actionId?: string | undefined; }, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; seq: number; tool: string; step?: string | undefined; verdict?: boolean | undefined; checkId?: string | undefined; actionId?: string | undefined; }>; export type RunScreenshot = z.infer; /** One step of a replayed flow, as synced: its outcome and the pages it ran on and led to. */ export declare const RunStepResultSchema: z.ZodObject<{ step: z.ZodNumber; anchor: z.ZodString; ok: z.ZodBoolean; page: z.ZodOptional; endPage: z.ZodOptional; consequence: z.ZodOptional; error: z.ZodOptional; /** The drift's reason kind, when the step drifted. */ drift: z.ZodOptional; /** What the page looked like when this step's outcome was decided. */ screenshot: z.ZodOptional; width: z.ZodNumber; height: z.ZodNumber; sha256: z.ZodString; }, "strip", z.ZodTypeAny, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }>>; }, "strip", z.ZodTypeAny, { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }, { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }>; export type RunStepResult = z.infer; /** * The flow a run replayed, as recorded: enough to replay it again somewhere else. * * `steps` are FlowSteps, left opaque here: this module loads before the flow schema, and importing * it made a cycle that crashed the built CLI at startup while every source-level test passed. */ export declare const RunFlowRecordingSchema: z.ZodObject<{ startPath: z.ZodOptional; steps: z.ZodArray; }, "strip", z.ZodTypeAny, { steps: unknown[]; startPath?: string | undefined; }, { steps: unknown[]; startPath?: string | undefined; }>; /** A flow that was replayed as part of the run. */ export declare const RunFlowResultSchema: z.ZodObject<{ name: z.ZodString; /** The saved flow this replayed copy was generated from — see the flow file's `template`. */ template: z.ZodOptional; status: z.ZodNativeEnum<{ readonly PASS: "pass"; readonly FAIL: "fail"; readonly SKIPPED: "skipped"; readonly HEALED: "healed"; }>; steps: z.ZodNumber; durationMs: z.ZodNumber; oracle: z.ZodOptional; healed: z.ZodOptional>; evidenceRef: z.ZodOptional; failureReason: z.ZodOptional; /** Each step's result and page — see RUN_STEP_RESULTS_MAX. */ stepResults: z.ZodOptional; endPage: z.ZodOptional; consequence: z.ZodOptional; error: z.ZodOptional; /** The drift's reason kind, when the step drifted. */ drift: z.ZodOptional; /** What the page looked like when this step's outcome was decided. */ screenshot: z.ZodOptional; width: z.ZodNumber; height: z.ZodNumber; sha256: z.ZodString; }, "strip", z.ZodTypeAny, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }>>; }, "strip", z.ZodTypeAny, { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }, { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }>, "many">>; /** The flow as recorded, when it fits in RUN_RECORDING_MAX_BYTES. */ recording: z.ZodOptional; steps: z.ZodArray; }, "strip", z.ZodTypeAny, { steps: unknown[]; startPath?: string | undefined; }, { steps: unknown[]; startPath?: string | undefined; }>>; /** True when the recording was too large to carry. */ recordingOmitted: z.ZodOptional; }, "strip", z.ZodTypeAny, { status: "pass" | "fail" | "healed" | "skipped"; steps: number; name: string; durationMs: number; recording?: { steps: unknown[]; startPath?: string | undefined; } | undefined; healed?: { from: string; to: string; consequenceVerified: boolean; } | undefined; template?: string | undefined; oracle?: string | undefined; evidenceRef?: string | undefined; failureReason?: string | undefined; stepResults?: { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }[] | undefined; recordingOmitted?: boolean | undefined; }, { status: "pass" | "fail" | "healed" | "skipped"; steps: number; name: string; durationMs: number; recording?: { steps: unknown[]; startPath?: string | undefined; } | undefined; healed?: { from: string; to: string; consequenceVerified: boolean; } | undefined; template?: string | undefined; oracle?: string | undefined; evidenceRef?: string | undefined; failureReason?: string | undefined; stepResults?: { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }[] | undefined; recordingOmitted?: boolean | undefined; }>; export type RunFlowResult = z.infer; /** A standalone assertion not tied to a flow. `evidence` is opaque (narrowed per kind by the caller). */ export declare const RunCheckSchema: z.ZodObject<{ /** * Which source of truth answering this claim required. * * Optional, because a check folded from a journal written before the kind was recorded has none, * and the only alternatives are refusing the whole run or filling in a kind nobody observed. An * absent field says nobody wrote it down; a present one is what the predicate actually read. */ kind: z.ZodEffects>, "signal" | "net" | "state" | "element" | "text" | "route" | "console" | "animation" | "settled" | "compare" | "allOf" | "anyOf" | "not" | undefined, unknown>; predicate: z.ZodString; status: z.ZodEffects, "yes" | "no" | "unknown" | "no-fault", unknown>; evidence: z.ZodOptional; /** * Was this claim written down BEFORE the action, or after it? * * The difference between a check and a rationalisation. Afterwards, anything that happened can be * described as what you meant; a claim made in advance can only be met or missed. * * Optional, and absence is not `false`. `false` says the claim came afterwards. Absent says nobody * recorded which, and those are different facts about the evidence. */ declaredBeforeActing: z.ZodOptional; /** * What the check required and what it saw, in the engine's words, when it said — "an element * matching {"testid":"pay"} in state 'enabled'" and "present, visible, disabled". Without them an * issue a CI run found had no Expected or Actual to show. Optional: older runs carry neither. */ expected: z.ZodOptional; observed: z.ZodOptional; /** * What kind of evidence bought this answer. * * A green paid for with "something matching was on screen" is not the same green as one paid for * with "the request went out", and a report that flattens them lets the cheap one pass for the * dear one. Free-form because the grades belong to whoever produced the verdict. */ grade: z.ZodOptional; /** * What could not be seen while this was being checked. * * The property with no prior art: every other test report in existence is silent about its own * blind spots. An empty list means nothing was hidden; absence means nobody looked. */ couldNotSee: z.ZodOptional>; /** * Why the verdict came out this way, in the engine's vocabulary. * * Carried so a reader -- and the fold that looks for late answers -- can tell an outcome that * has not arrived from a capture that could not be read. Both are `unknown`, and only the * first is a question that waiting can settle. */ reason: z.ZodOptional; /** This check's own name, so a later verdict can cite it. See revision.ts. */ checkId: z.ZodOptional; /** The journal action that produced it, kept on this machine to pair it with its screenshot. */ actionId: z.ZodOptional; /** The declared intent this check was taken for, by id: what it proves, named rather than timed. */ intent: z.ZodOptional; /** What the page looked like when this check was decided. */ screenshot: z.ZodOptional; width: z.ZodNumber; height: z.ZodNumber; sha256: z.ZodString; }, "strip", z.ZodTypeAny, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }>>; /** * The earlier check this one corrects, as `#`. * * Present only on a correction, and the check it names is NOT edited: both stand, so a reader * can see that the first answer was given, when it changed, and why. */ supersedes: z.ZodOptional; }, "strip", z.ZodTypeAny, { status: "yes" | "no" | "unknown" | "no-fault"; predicate: string; kind?: "signal" | "net" | "state" | "element" | "text" | "route" | "console" | "animation" | "settled" | "compare" | "allOf" | "anyOf" | "not" | undefined; intent?: string | undefined; expected?: string | undefined; checkId?: string | undefined; actionId?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; evidence?: unknown; declaredBeforeActing?: boolean | undefined; observed?: string | undefined; grade?: string | undefined; couldNotSee?: string[] | undefined; reason?: string | undefined; supersedes?: string | undefined; }, { predicate: string; kind?: unknown; intent?: string | undefined; status?: unknown; expected?: string | undefined; checkId?: string | undefined; actionId?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; evidence?: unknown; declaredBeforeActing?: boolean | undefined; observed?: string | undefined; grade?: string | undefined; couldNotSee?: string[] | undefined; reason?: string | undefined; supersedes?: string | undefined; }>; export type RunCheck = z.infer; /** A flagged risk. `gated` = a policy gate tripped on this surface. */ export declare const RunRiskSchema: z.ZodObject<{ surface: z.ZodNativeEnum<{ readonly AUTH: "auth"; readonly PAYMENT: "payment"; readonly DB: "db"; readonly MIGRATION: "migration"; readonly RLS: "rls"; readonly SECRETS: "secrets"; readonly DESTRUCTIVE: "destructive"; readonly EXTERNAL: "external"; }>; severity: z.ZodNativeEnum<{ readonly LOW: "low"; readonly MEDIUM: "medium"; readonly HIGH: "high"; readonly CRITICAL: "critical"; }>; detail: z.ZodString; evidence: z.ZodOptional; line: z.ZodOptional; network: z.ZodOptional; }, "strip", z.ZodTypeAny, { network?: string | undefined; file?: string | undefined; line?: number | undefined; }, { network?: string | undefined; file?: string | undefined; line?: number | undefined; }>>; gated: z.ZodDefault; }, "strip", z.ZodTypeAny, { surface: "auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external"; severity: "low" | "medium" | "high" | "critical"; detail: string; gated: boolean; evidence?: { network?: string | undefined; file?: string | undefined; line?: number | undefined; } | undefined; }, { surface: "auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external"; severity: "low" | "medium" | "high" | "critical"; detail: string; evidence?: { network?: string | undefined; file?: string | undefined; line?: number | undefined; } | undefined; gated?: boolean | undefined; }>; export type RunRisk = z.infer; /** The cross-layer evidence behind the verdict. Raw bodies / full state appear only under DEV profile. */ export declare const VerificationEvidenceSchema: z.ZodObject<{ consoleErrors: z.ZodDefault, "many">>; networkAnomalies: z.ZodDefault; issue: z.ZodString; }, "strip", z.ZodTypeAny, { method: string; url: string; issue: string; status?: number | undefined; }, { method: string; url: string; issue: string; status?: number | undefined; }>, "many">>; stateAssertions: z.ZodDefault, "many">>; timeline: z.ZodDefault, "many">>; }, "strip", z.ZodTypeAny, { consoleErrors: { at: number; message: string; level: string; }[]; networkAnomalies: { method: string; url: string; issue: string; status?: number | undefined; }[]; stateAssertions: { ok: boolean; path: string; store: string; expected?: unknown; actual?: unknown; }[]; timeline: { kind: string; at: number; summary: string; }[]; }, { consoleErrors?: { at: number; message: string; level: string; }[] | undefined; networkAnomalies?: { method: string; url: string; issue: string; status?: number | undefined; }[] | undefined; stateAssertions?: { ok: boolean; path: string; store: string; expected?: unknown; actual?: unknown; }[] | undefined; timeline?: { kind: string; at: number; summary: string; }[] | undefined; }>; /** One paste-ready fix instruction for the host's coding agent. */ export declare const RepairPacketSchema: z.ZodObject<{ flow: z.ZodOptional; step: z.ZodOptional; expected: z.ZodString; actual: z.ZodString; sourceLocation: z.ZodOptional; component: z.ZodOptional; }, "strip", z.ZodTypeAny, { file: string; component?: string | undefined; line?: number | undefined; }, { file: string; component?: string | undefined; line?: number | undefined; }>>; suggestedPrompt: z.ZodString; }, "strip", z.ZodTypeAny, { expected: string; actual: string; suggestedPrompt: string; step?: number | undefined; flow?: string | undefined; sourceLocation?: { file: string; component?: string | undefined; line?: number | undefined; } | undefined; }, { expected: string; actual: string; suggestedPrompt: string; step?: number | undefined; flow?: string | undefined; sourceLocation?: { file: string; component?: string | undefined; line?: number | undefined; } | undefined; }>; export type RepairPacket = z.infer; /** The verdict block — what a deploy gate reads. */ export declare const RunVerdictSchema: z.ZodObject<{ status: z.ZodNativeEnum<{ readonly PASS: "pass"; readonly FAIL: "fail"; readonly PARTIAL: "partial"; /** * Nothing was proved either way -- no flow and no check produced an outcome, so there is nothing * to pass and nothing to fail. * * This is deliberately NOT a pass. A run that checked nothing and a run that checked everything * successfully are different facts, and flattening them into one word is how a green light comes * to mean "we did not look". It matches how a single action is already judged, where "could not * tell" has always been its own answer. */ readonly UNKNOWN: "unknown"; }>; reasons: z.ZodDefault>; confidence: z.ZodNativeEnum<{ readonly HIGH: "high"; readonly MEDIUM: "medium"; readonly LOW: "low"; }>; blockingRisks: z.ZodDefault; /** * Which check this verdict is about, so a later one can say it corrects this. * * Optional because a run's overall verdict is not about one check. A verdict with no check named * cannot be cited, and therefore cannot be corrected -- see revision.ts. */ checkId: z.ZodOptional; /** * The verdict this one replaces, written as `#`. * * Present only on a correction. The verdict it names is NOT edited: it stays exactly as it was * given, and this is a second, later answer that cites it. Rewriting the first in place would * erase the fact that it was ever given, and "we always knew" is the shape of the problem this * whole system exists to prevent. */ supersedes: z.ZodOptional; }, "strip", z.ZodTypeAny, { status: "pass" | "fail" | "unknown" | "partial"; reasons: string[]; confidence: "low" | "medium" | "high"; blockingRisks: number; checkId?: string | undefined; supersedes?: string | undefined; }, { status: "pass" | "fail" | "unknown" | "partial"; confidence: "low" | "medium" | "high"; checkId?: string | undefined; supersedes?: string | undefined; reasons?: string[] | undefined; blockingRisks?: number | undefined; }>; export type RunVerdict = z.infer; /** Optional tamper-evidence signature over the run (for audit; populated later). */ export declare const RunSignatureSchema: z.ZodObject<{ alg: z.ZodString; value: z.ZodString; signedAt: z.ZodNumber; }, "strip", z.ZodTypeAny, { value: string; alg: string; signedAt: number; }, { value: string; alg: string; signedAt: number; }>; /** * The top-level verification-run artifact. Stable contract — additive changes only within a * RUN_FILE_VERSION; a breaking change bumps it. Arrays default to empty so a minimal run (e.g. a * single smoke flow) still validates. Version 1 files are still read; see the note on the constant. */ export declare const ReticleVerificationRunSchema: z.ZodObject<{ schemaVersion: z.ZodUnion<[z.ZodLiteral<3>, z.ZodLiteral<2>, z.ZodLiteral<1>]>; runId: z.ZodBranded; createdAt: z.ZodNumber; durationMs: z.ZodNumber; profile: z.ZodNativeEnum<{ readonly DEV: "dev"; readonly PROD_PREVIEW: "prod-preview"; }>; project: z.ZodObject<{ name: z.ZodString; framework: z.ZodNativeEnum<{ readonly REACT: "react"; readonly NEXT: "next"; readonly VITE: "vite"; readonly OTHER: "other"; }>; commit: z.ZodOptional; env: z.ZodOptional>; previewUrl: z.ZodOptional; }, "strip", z.ZodTypeAny, { name: string; framework: "other" | "react" | "next" | "vite"; commit?: string | undefined; env?: "ci" | "preview" | "local" | undefined; previewUrl?: string | undefined; }, { name: string; framework: "other" | "react" | "next" | "vite"; commit?: string | undefined; env?: "ci" | "preview" | "local" | undefined; previewUrl?: string | undefined; }>; agent: z.ZodObject<{ id: z.ZodString; kind: z.ZodNativeEnum<{ readonly CODING_AGENT: "coding-agent"; readonly OEM_PIPELINE: "oem-pipeline"; readonly HUMAN: "human"; }>; model: z.ZodOptional; }, "strip", z.ZodTypeAny, { kind: "coding-agent" | "oem-pipeline" | "human"; id: string; model?: string | undefined; }, { kind: "coding-agent" | "oem-pipeline" | "human"; id: string; model?: string | undefined; }>; trigger: z.ZodObject<{ kind: z.ZodNativeEnum<{ readonly EDIT: "edit"; readonly CI: "ci"; readonly MANUAL: "manual"; readonly OEM: "oem"; }>; diffRef: z.ZodOptional; note: z.ZodOptional; }, "strip", z.ZodTypeAny, { kind: "manual" | "edit" | "ci" | "oem"; diffRef?: string | undefined; note?: string | undefined; }, { kind: "manual" | "edit" | "ci" | "oem"; diffRef?: string | undefined; note?: string | undefined; }>; /** * Which round of source edits this evidence belongs to. * * Evidence gathered before the change under test is true about the OLD code. Reporting it as true * about the new code is a false pass, and it is the kind nobody notices because everything looks * green. Absent when the run had no way to know. */ editEpoch: z.ZodOptional; /** * What was verified, in the protocol's own vocabulary. * * The artifact recorded the project, the agent, the trigger and the edit round, and never what * KIND of thing was on the other end -- so a run against a Tauri desktop app and one against a * web page were indistinguishable to every reader of this file. `surface` is the field that * separates them, and `instance` is the one that says which document the evidence belongs to, * which is the difference between evidence about this page and evidence that survived a * navigation. * * `SubjectRef` is the specification's, imported rather than restated. Optional because a run * assembled without a live session -- in CI, from flows alone -- genuinely does not know, and * an invented subject is worse than an absent one. */ subject: z.ZodOptional, z.ZodString]>; instance: z.ZodString; epoch: z.ZodOptional; locator: z.ZodOptional; revision: z.ZodOptional; }, "strip", z.ZodTypeAny, { surface: string; instance: string; epoch?: number | undefined; locator?: string | undefined; revision?: string | undefined; }, { surface: string; instance: string; epoch?: number | undefined; locator?: string | undefined; revision?: string | undefined; }>>; /** * The prompt this verification answered, when the agent relayed one. Loose here because this * schema loads with every page; its shape is `PromptContextSchema` in `@reticlehq/core/artifacts`, * which the daemon writes and reads it with. */ context: z.ZodOptional>; changedFiles: z.ZodDefault; risk: z.ZodDefault, "many">>; }, "strip", z.ZodTypeAny, { path: string; changeKind: "added" | "modified" | "deleted"; risk: ("auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external")[]; }, { path: string; changeKind: "added" | "modified" | "deleted"; risk?: ("auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external")[] | undefined; }>, "many">>; flows: z.ZodDefault; status: z.ZodNativeEnum<{ readonly PASS: "pass"; readonly FAIL: "fail"; readonly SKIPPED: "skipped"; readonly HEALED: "healed"; }>; steps: z.ZodNumber; durationMs: z.ZodNumber; oracle: z.ZodOptional; healed: z.ZodOptional>; evidenceRef: z.ZodOptional; failureReason: z.ZodOptional; /** Each step's result and page — see RUN_STEP_RESULTS_MAX. */ stepResults: z.ZodOptional; endPage: z.ZodOptional; consequence: z.ZodOptional; error: z.ZodOptional; /** The drift's reason kind, when the step drifted. */ drift: z.ZodOptional; /** What the page looked like when this step's outcome was decided. */ screenshot: z.ZodOptional; width: z.ZodNumber; height: z.ZodNumber; sha256: z.ZodString; }, "strip", z.ZodTypeAny, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }>>; }, "strip", z.ZodTypeAny, { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }, { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }>, "many">>; /** The flow as recorded, when it fits in RUN_RECORDING_MAX_BYTES. */ recording: z.ZodOptional; steps: z.ZodArray; }, "strip", z.ZodTypeAny, { steps: unknown[]; startPath?: string | undefined; }, { steps: unknown[]; startPath?: string | undefined; }>>; /** True when the recording was too large to carry. */ recordingOmitted: z.ZodOptional; }, "strip", z.ZodTypeAny, { status: "pass" | "fail" | "healed" | "skipped"; steps: number; name: string; durationMs: number; recording?: { steps: unknown[]; startPath?: string | undefined; } | undefined; healed?: { from: string; to: string; consequenceVerified: boolean; } | undefined; template?: string | undefined; oracle?: string | undefined; evidenceRef?: string | undefined; failureReason?: string | undefined; stepResults?: { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }[] | undefined; recordingOmitted?: boolean | undefined; }, { status: "pass" | "fail" | "healed" | "skipped"; steps: number; name: string; durationMs: number; recording?: { steps: unknown[]; startPath?: string | undefined; } | undefined; healed?: { from: string; to: string; consequenceVerified: boolean; } | undefined; template?: string | undefined; oracle?: string | undefined; evidenceRef?: string | undefined; failureReason?: string | undefined; stepResults?: { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }[] | undefined; recordingOmitted?: boolean | undefined; }>, "many">>; checks: z.ZodDefault>, "signal" | "net" | "state" | "element" | "text" | "route" | "console" | "animation" | "settled" | "compare" | "allOf" | "anyOf" | "not" | undefined, unknown>; predicate: z.ZodString; status: z.ZodEffects, "yes" | "no" | "unknown" | "no-fault", unknown>; evidence: z.ZodOptional; /** * Was this claim written down BEFORE the action, or after it? * * The difference between a check and a rationalisation. Afterwards, anything that happened can be * described as what you meant; a claim made in advance can only be met or missed. * * Optional, and absence is not `false`. `false` says the claim came afterwards. Absent says nobody * recorded which, and those are different facts about the evidence. */ declaredBeforeActing: z.ZodOptional; /** * What the check required and what it saw, in the engine's words, when it said — "an element * matching {"testid":"pay"} in state 'enabled'" and "present, visible, disabled". Without them an * issue a CI run found had no Expected or Actual to show. Optional: older runs carry neither. */ expected: z.ZodOptional; observed: z.ZodOptional; /** * What kind of evidence bought this answer. * * A green paid for with "something matching was on screen" is not the same green as one paid for * with "the request went out", and a report that flattens them lets the cheap one pass for the * dear one. Free-form because the grades belong to whoever produced the verdict. */ grade: z.ZodOptional; /** * What could not be seen while this was being checked. * * The property with no prior art: every other test report in existence is silent about its own * blind spots. An empty list means nothing was hidden; absence means nobody looked. */ couldNotSee: z.ZodOptional>; /** * Why the verdict came out this way, in the engine's vocabulary. * * Carried so a reader -- and the fold that looks for late answers -- can tell an outcome that * has not arrived from a capture that could not be read. Both are `unknown`, and only the * first is a question that waiting can settle. */ reason: z.ZodOptional; /** This check's own name, so a later verdict can cite it. See revision.ts. */ checkId: z.ZodOptional; /** The journal action that produced it, kept on this machine to pair it with its screenshot. */ actionId: z.ZodOptional; /** The declared intent this check was taken for, by id: what it proves, named rather than timed. */ intent: z.ZodOptional; /** What the page looked like when this check was decided. */ screenshot: z.ZodOptional; width: z.ZodNumber; height: z.ZodNumber; sha256: z.ZodString; }, "strip", z.ZodTypeAny, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; }>>; /** * The earlier check this one corrects, as `#`. * * Present only on a correction, and the check it names is NOT edited: both stand, so a reader * can see that the first answer was given, when it changed, and why. */ supersedes: z.ZodOptional; }, "strip", z.ZodTypeAny, { status: "yes" | "no" | "unknown" | "no-fault"; predicate: string; kind?: "signal" | "net" | "state" | "element" | "text" | "route" | "console" | "animation" | "settled" | "compare" | "allOf" | "anyOf" | "not" | undefined; intent?: string | undefined; expected?: string | undefined; checkId?: string | undefined; actionId?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; evidence?: unknown; declaredBeforeActing?: boolean | undefined; observed?: string | undefined; grade?: string | undefined; couldNotSee?: string[] | undefined; reason?: string | undefined; supersedes?: string | undefined; }, { predicate: string; kind?: unknown; intent?: string | undefined; status?: unknown; expected?: string | undefined; checkId?: string | undefined; actionId?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; evidence?: unknown; declaredBeforeActing?: boolean | undefined; observed?: string | undefined; grade?: string | undefined; couldNotSee?: string[] | undefined; reason?: string | undefined; supersedes?: string | undefined; }>, "many">>; risks: z.ZodDefault; severity: z.ZodNativeEnum<{ readonly LOW: "low"; readonly MEDIUM: "medium"; readonly HIGH: "high"; readonly CRITICAL: "critical"; }>; detail: z.ZodString; evidence: z.ZodOptional; line: z.ZodOptional; network: z.ZodOptional; }, "strip", z.ZodTypeAny, { network?: string | undefined; file?: string | undefined; line?: number | undefined; }, { network?: string | undefined; file?: string | undefined; line?: number | undefined; }>>; gated: z.ZodDefault; }, "strip", z.ZodTypeAny, { surface: "auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external"; severity: "low" | "medium" | "high" | "critical"; detail: string; gated: boolean; evidence?: { network?: string | undefined; file?: string | undefined; line?: number | undefined; } | undefined; }, { surface: "auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external"; severity: "low" | "medium" | "high" | "critical"; detail: string; evidence?: { network?: string | undefined; file?: string | undefined; line?: number | undefined; } | undefined; gated?: boolean | undefined; }>, "many">>; evidence: z.ZodObject<{ consoleErrors: z.ZodDefault, "many">>; networkAnomalies: z.ZodDefault; issue: z.ZodString; }, "strip", z.ZodTypeAny, { method: string; url: string; issue: string; status?: number | undefined; }, { method: string; url: string; issue: string; status?: number | undefined; }>, "many">>; stateAssertions: z.ZodDefault, "many">>; timeline: z.ZodDefault, "many">>; }, "strip", z.ZodTypeAny, { consoleErrors: { at: number; message: string; level: string; }[]; networkAnomalies: { method: string; url: string; issue: string; status?: number | undefined; }[]; stateAssertions: { ok: boolean; path: string; store: string; expected?: unknown; actual?: unknown; }[]; timeline: { kind: string; at: number; summary: string; }[]; }, { consoleErrors?: { at: number; message: string; level: string; }[] | undefined; networkAnomalies?: { method: string; url: string; issue: string; status?: number | undefined; }[] | undefined; stateAssertions?: { ok: boolean; path: string; store: string; expected?: unknown; actual?: unknown; }[] | undefined; timeline?: { kind: string; at: number; summary: string; }[] | undefined; }>; repair: z.ZodOptional; step: z.ZodOptional; expected: z.ZodString; actual: z.ZodString; sourceLocation: z.ZodOptional; component: z.ZodOptional; }, "strip", z.ZodTypeAny, { file: string; component?: string | undefined; line?: number | undefined; }, { file: string; component?: string | undefined; line?: number | undefined; }>>; suggestedPrompt: z.ZodString; }, "strip", z.ZodTypeAny, { expected: string; actual: string; suggestedPrompt: string; step?: number | undefined; flow?: string | undefined; sourceLocation?: { file: string; component?: string | undefined; line?: number | undefined; } | undefined; }, { expected: string; actual: string; suggestedPrompt: string; step?: number | undefined; flow?: string | undefined; sourceLocation?: { file: string; component?: string | undefined; line?: number | undefined; } | undefined; }>, "many">>; }, "strip", z.ZodTypeAny, { failurePackets: { expected: string; actual: string; suggestedPrompt: string; step?: number | undefined; flow?: string | undefined; sourceLocation?: { file: string; component?: string | undefined; line?: number | undefined; } | undefined; }[]; }, { failurePackets?: { expected: string; actual: string; suggestedPrompt: string; step?: number | undefined; flow?: string | undefined; sourceLocation?: { file: string; component?: string | undefined; line?: number | undefined; } | undefined; }[] | undefined; }>>; /** What the page looked like after each action, assert and replayed step. Absent on older runs. */ screenshots: z.ZodOptional; width: z.ZodNumber; height: z.ZodNumber; sha256: z.ZodString; } & { seq: z.ZodNumber; tool: z.ZodString; /** The flow step it belongs to, as `#`, when it was taken during a replay. */ step: z.ZodOptional; /** Taken for a call that produced a verdict — what lets the run pair it with its check. */ verdict: z.ZodOptional; /** The check this picture is of (see `RunCheck.checkId`), when it could be paired with one. */ checkId: z.ZodOptional; /** The journal action it was taken for: how a run pairs it with its check (`RunCheck.actionId`). */ actionId: z.ZodOptional; }, "strip", z.ZodTypeAny, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; seq: number; tool: string; step?: string | undefined; verdict?: boolean | undefined; checkId?: string | undefined; actionId?: string | undefined; }, { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; seq: number; tool: string; step?: string | undefined; verdict?: boolean | undefined; checkId?: string | undefined; actionId?: string | undefined; }>, "many">>; verdict: z.ZodObject<{ status: z.ZodNativeEnum<{ readonly PASS: "pass"; readonly FAIL: "fail"; readonly PARTIAL: "partial"; /** * Nothing was proved either way -- no flow and no check produced an outcome, so there is nothing * to pass and nothing to fail. * * This is deliberately NOT a pass. A run that checked nothing and a run that checked everything * successfully are different facts, and flattening them into one word is how a green light comes * to mean "we did not look". It matches how a single action is already judged, where "could not * tell" has always been its own answer. */ readonly UNKNOWN: "unknown"; }>; reasons: z.ZodDefault>; confidence: z.ZodNativeEnum<{ readonly HIGH: "high"; readonly MEDIUM: "medium"; readonly LOW: "low"; }>; blockingRisks: z.ZodDefault; /** * Which check this verdict is about, so a later one can say it corrects this. * * Optional because a run's overall verdict is not about one check. A verdict with no check named * cannot be cited, and therefore cannot be corrected -- see revision.ts. */ checkId: z.ZodOptional; /** * The verdict this one replaces, written as `#`. * * Present only on a correction. The verdict it names is NOT edited: it stays exactly as it was * given, and this is a second, later answer that cites it. Rewriting the first in place would * erase the fact that it was ever given, and "we always knew" is the shape of the problem this * whole system exists to prevent. */ supersedes: z.ZodOptional; }, "strip", z.ZodTypeAny, { status: "pass" | "fail" | "unknown" | "partial"; reasons: string[]; confidence: "low" | "medium" | "high"; blockingRisks: number; checkId?: string | undefined; supersedes?: string | undefined; }, { status: "pass" | "fail" | "unknown" | "partial"; confidence: "low" | "medium" | "high"; checkId?: string | undefined; supersedes?: string | undefined; reasons?: string[] | undefined; blockingRisks?: number | undefined; }>; signature: z.ZodOptional>; /** * On a Harness run: each goal the session's coding agent also judged, and how the two compare. * Optional and additive; an older platform strips it and keeps the body. */ disparity: z.ZodOptional; agent: z.ZodObject<{ verified: z.ZodNativeEnum<{ readonly YES: "yes"; readonly NO: "no"; readonly UNKNOWN: "unknown"; readonly NO_FAULT: "no-fault"; }>; claim: z.ZodString; }, "strip", z.ZodTypeAny, { verified: "yes" | "no" | "unknown" | "no-fault"; claim: string; }, { verified: "yes" | "no" | "unknown" | "no-fault"; claim: string; }>; harness: z.ZodObject<{ verified: z.ZodNativeEnum<{ readonly YES: "yes"; readonly NO: "no"; readonly UNKNOWN: "unknown"; readonly NO_FAULT: "no-fault"; }>; found: z.ZodBoolean; searched: z.ZodArray; gaveUpAt: z.ZodOptional; }, "strip", z.ZodTypeAny, { verified: "yes" | "no" | "unknown" | "no-fault"; found: boolean; searched: string[]; gaveUpAt?: string | undefined; }, { verified: "yes" | "no" | "unknown" | "no-fault"; found: boolean; searched: string[]; gaveUpAt?: string | undefined; }>; }, "strip", z.ZodTypeAny, { kind: "findable" | "discoverability" | "agent_assumption" | "defect"; goal: string; agent: { verified: "yes" | "no" | "unknown" | "no-fault"; claim: string; }; harness: { verified: "yes" | "no" | "unknown" | "no-fault"; found: boolean; searched: string[]; gaveUpAt?: string | undefined; }; }, { kind: "findable" | "discoverability" | "agent_assumption" | "defect"; goal: string; agent: { verified: "yes" | "no" | "unknown" | "no-fault"; claim: string; }; harness: { verified: "yes" | "no" | "unknown" | "no-fault"; found: boolean; searched: string[]; gaveUpAt?: string | undefined; }; }>, "many">>; /** * What the coding agent itself said the session showed (`reticle_session { end, claim }`), kept * beside the graded `verdict` so claimed-vs-graded can be compared. Never read as the verdict. */ agentClaim: z.ZodOptional>; }, "strip", z.ZodTypeAny, { flows: { status: "pass" | "fail" | "healed" | "skipped"; steps: number; name: string; durationMs: number; recording?: { steps: unknown[]; startPath?: string | undefined; } | undefined; healed?: { from: string; to: string; consequenceVerified: boolean; } | undefined; template?: string | undefined; oracle?: string | undefined; evidenceRef?: string | undefined; failureReason?: string | undefined; stepResults?: { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }[] | undefined; recordingOmitted?: boolean | undefined; }[]; agent: { kind: "coding-agent" | "oem-pipeline" | "human"; id: string; model?: string | undefined; }; verdict: { status: "pass" | "fail" | "unknown" | "partial"; reasons: string[]; confidence: "low" | "medium" | "high"; blockingRisks: number; checkId?: string | undefined; supersedes?: string | undefined; }; durationMs: number; evidence: { consoleErrors: { at: number; message: string; level: string; }[]; networkAnomalies: { method: string; url: string; issue: string; status?: number | undefined; }[]; stateAssertions: { ok: boolean; path: string; store: string; expected?: unknown; actual?: unknown; }[]; timeline: { kind: string; at: number; summary: string; }[]; }; schemaVersion: 1 | 2 | 3; runId: string & z.BRAND<"RunId">; createdAt: number; profile: "dev" | "prod-preview"; project: { name: string; framework: "other" | "react" | "next" | "vite"; commit?: string | undefined; env?: "ci" | "preview" | "local" | undefined; previewUrl?: string | undefined; }; trigger: { kind: "manual" | "edit" | "ci" | "oem"; diffRef?: string | undefined; note?: string | undefined; }; changedFiles: { path: string; changeKind: "added" | "modified" | "deleted"; risk: ("auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external")[]; }[]; checks: { status: "yes" | "no" | "unknown" | "no-fault"; predicate: string; kind?: "signal" | "net" | "state" | "element" | "text" | "route" | "console" | "animation" | "settled" | "compare" | "allOf" | "anyOf" | "not" | undefined; intent?: string | undefined; expected?: string | undefined; checkId?: string | undefined; actionId?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; evidence?: unknown; declaredBeforeActing?: boolean | undefined; observed?: string | undefined; grade?: string | undefined; couldNotSee?: string[] | undefined; reason?: string | undefined; supersedes?: string | undefined; }[]; risks: { surface: "auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external"; severity: "low" | "medium" | "high" | "critical"; detail: string; gated: boolean; evidence?: { network?: string | undefined; file?: string | undefined; line?: number | undefined; } | undefined; }[]; editEpoch?: number | undefined; subject?: { surface: string; instance: string; epoch?: number | undefined; locator?: string | undefined; revision?: string | undefined; } | undefined; context?: Record | undefined; repair?: { failurePackets: { expected: string; actual: string; suggestedPrompt: string; step?: number | undefined; flow?: string | undefined; sourceLocation?: { file: string; component?: string | undefined; line?: number | undefined; } | undefined; }[]; } | undefined; screenshots?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; seq: number; tool: string; step?: string | undefined; verdict?: boolean | undefined; checkId?: string | undefined; actionId?: string | undefined; }[] | undefined; signature?: { value: string; alg: string; signedAt: number; } | undefined; disparity?: { kind: "findable" | "discoverability" | "agent_assumption" | "defect"; goal: string; agent: { verified: "yes" | "no" | "unknown" | "no-fault"; claim: string; }; harness: { verified: "yes" | "no" | "unknown" | "no-fault"; found: boolean; searched: string[]; gaveUpAt?: string | undefined; }; }[] | undefined; agentClaim?: "pass" | "fail" | "unknown" | "partial" | undefined; }, { agent: { kind: "coding-agent" | "oem-pipeline" | "human"; id: string; model?: string | undefined; }; verdict: { status: "pass" | "fail" | "unknown" | "partial"; confidence: "low" | "medium" | "high"; checkId?: string | undefined; supersedes?: string | undefined; reasons?: string[] | undefined; blockingRisks?: number | undefined; }; durationMs: number; evidence: { consoleErrors?: { at: number; message: string; level: string; }[] | undefined; networkAnomalies?: { method: string; url: string; issue: string; status?: number | undefined; }[] | undefined; stateAssertions?: { ok: boolean; path: string; store: string; expected?: unknown; actual?: unknown; }[] | undefined; timeline?: { kind: string; at: number; summary: string; }[] | undefined; }; schemaVersion: 1 | 2 | 3; runId: string; createdAt: number; profile: "dev" | "prod-preview"; project: { name: string; framework: "other" | "react" | "next" | "vite"; commit?: string | undefined; env?: "ci" | "preview" | "local" | undefined; previewUrl?: string | undefined; }; trigger: { kind: "manual" | "edit" | "ci" | "oem"; diffRef?: string | undefined; note?: string | undefined; }; flows?: { status: "pass" | "fail" | "healed" | "skipped"; steps: number; name: string; durationMs: number; recording?: { steps: unknown[]; startPath?: string | undefined; } | undefined; healed?: { from: string; to: string; consequenceVerified: boolean; } | undefined; template?: string | undefined; oracle?: string | undefined; evidenceRef?: string | undefined; failureReason?: string | undefined; stepResults?: { ok: boolean; step: number; anchor: string; drift?: string | undefined; error?: string | undefined; page?: string | undefined; endPage?: string | undefined; consequence?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; }[] | undefined; recordingOmitted?: boolean | undefined; }[] | undefined; editEpoch?: number | undefined; subject?: { surface: string; instance: string; epoch?: number | undefined; locator?: string | undefined; revision?: string | undefined; } | undefined; context?: Record | undefined; changedFiles?: { path: string; changeKind: "added" | "modified" | "deleted"; risk?: ("auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external")[] | undefined; }[] | undefined; checks?: { predicate: string; kind?: unknown; intent?: string | undefined; status?: unknown; expected?: string | undefined; checkId?: string | undefined; actionId?: string | undefined; screenshot?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; } | undefined; evidence?: unknown; declaredBeforeActing?: boolean | undefined; observed?: string | undefined; grade?: string | undefined; couldNotSee?: string[] | undefined; reason?: string | undefined; supersedes?: string | undefined; }[] | undefined; risks?: { surface: "auth" | "payment" | "db" | "migration" | "rls" | "secrets" | "destructive" | "external"; severity: "low" | "medium" | "high" | "critical"; detail: string; evidence?: { network?: string | undefined; file?: string | undefined; line?: number | undefined; } | undefined; gated?: boolean | undefined; }[] | undefined; repair?: { failurePackets?: { expected: string; actual: string; suggestedPrompt: string; step?: number | undefined; flow?: string | undefined; sourceLocation?: { file: string; component?: string | undefined; line?: number | undefined; } | undefined; }[] | undefined; } | undefined; screenshots?: { file: string; source: "browser" | "rendered"; width: number; height: number; sha256: string; seq: number; tool: string; step?: string | undefined; verdict?: boolean | undefined; checkId?: string | undefined; actionId?: string | undefined; }[] | undefined; signature?: { value: string; alg: string; signedAt: number; } | undefined; disparity?: { kind: "findable" | "discoverability" | "agent_assumption" | "defect"; goal: string; agent: { verified: "yes" | "no" | "unknown" | "no-fault"; claim: string; }; harness: { verified: "yes" | "no" | "unknown" | "no-fault"; found: boolean; searched: string[]; gaveUpAt?: string | undefined; }; }[] | undefined; agentClaim?: "pass" | "fail" | "unknown" | "partial" | undefined; }>; export type ReticleVerificationRun = z.infer; export type VerificationEvidence = z.infer; export type RunSignature = z.infer;