(function () { const text = (value) => String(value ?? '').slice(0, 4000).replace(/[&<>"']/g, (character) => ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''' })[character]); const value = (input) => text(typeof input === 'object' ? JSON.stringify(input) : input); function frozen(snapshot) { if (!snapshot) return '
Frozen-input evidence not recorded.
'; if (snapshot.unavailable) return 'Frozen-input evidence unreadable.
'; return `Frozen input commit ${text(snapshot.commit)}
Input digest ${text(snapshot.digest ?? snapshot.inputDigest)}
Copy strategy: ${text(snapshot.copyStrategy ?? 'not recorded')}. Recorded capture, not a new integrity check.
`; } function phase(label, observation) { if (!observation) return `${label}: not recorded.
`; const entries = Object.entries(observation.report?.conditions ?? {}).slice(0, 100); return `${text(observation.reason)}
` : ''}Recorded check evidence. Running records do not prove a live executor; interrupted runs need review, not automatic rerun.
${pending.map((item) => `Preparation ${text(item.id)} · ${text(item.createdAt)}
${frozen(item.snapshot)} ${item.state === 'abandoned' ? `${item.recovery?.cleanupStatus === 'completed' ? 'Captured-input cleanup completed (recorded).' : item.recovery?.cleanupStatus === 'pending' ? 'Captured-input cleanup pending. Owner review is required.' : 'Captured-input cleanup unconfirmed. Inspect the recovery record before acting.'}
${item.recovery?.recordedAt ? `Recovery recorded ${text(item.recovery.recordedAt)}
` : ''} ${item.recovery?.cleanupReason ? `Cleanup reason: ${text(item.recovery.cleanupReason)}
` : ''}Stopped executors: ${item.recovery?.stoppedExecutors === 'owner-attested' ? 'owner-attested, not independently verified descendant termination' : 'unconfirmed'}. Recovery does not release resource leases or create a check pass. Use the owner-confirmed CLI recovery workflow; this view does not recover or rerun work.
` : ''}Commit ${text(receipt.commit)} · ${text(receipt.finishedAt)}
Qualification invalid: ${text(receipt.invalidReason)}
` : ''}${frozen(receipt.snapshot)} ${receipt.conditions ? (receipt.conditions.unavailable ? 'Condition evidence unreadable.
' : `Conditions are project-reported pre/post observations, not independent sensor truth or continuous monitoring.
${phase('Before measurement', receipt.conditions.before)}${phase('After measurement', receipt.conditions.after)}`) : 'No condition observations recorded; this is not proof that runtime conditions were verified.
'}No exact-commit check receipts.
'} ${checks.coverage ? `${text(checks.coverage)}
` : ''}`; } globalThis.TorchCheckEvidence = Object.freeze({ render }); })();