import { L as LogicalTraceEvent, a as LogicalProjectionDiagnostic } from './index-EQihlEei.cjs'; export { B as BaselineRegressionRuleOptions, C as ControlStage, D as DecisionRuleOptions, G as GuardrailRuleOptions, b as LlmUsageRuleOptions, M as MaxStepDurationRuleOptions, O as ObservedOutcomeRuleOptions, R as RecoverySameArgumentsMode, c as RecoverySideEffectClass, d as RetrievalRuleOptions, e as RunDepthRuleOptions, f as RunDurationRuleOptions, g as RunEventCountRuleOptions, h as RunStatusRuleOptions, i as RunTraceChecksOptions, S as SafetyFindingCategory, j as SafetyFindingConfidence, k as SafetyOversizedAttributeRuleOptions, l as SafetyRawContentRuleOptions, m as SafetyRedactionRuleOptions, n as SafetySecretPattern, o as SafetySecretPatternRuleOptions, p as StallDetectionRuleOptions, q as StepOrderingEndpoint, r as StepOrderingKind, s as StepOrderingRuleOptions, t as StructureIncompleteRuleOptions, u as StructureOrphanRuleOptions, v as StructureParallelWidthRuleOptions, w as StructureRelationshipRuleOptions, T as ToolArgumentCheck, x as ToolArgumentOccurrence, y as ToolArgumentOperator, z as ToolFailureRuleOptions, A as ToolOrderingRuleOptions, E as ToolUsageRuleOptions, F as TraceCheckContext, H as TraceCheckDiagnostic, I as TraceCheckDiagnosticCode, J as TraceCheckEvidence, K as TraceCheckFacts, N as TraceCheckFinding, P as TraceCheckFindingStatus, Q as TraceCheckInput, U as TraceCheckResult, V as TraceCheckRule, W as TraceCheckRuleCategory, X as TraceCheckRuleExecution, Y as TraceCheckRuleExecutionStatus, Z as TraceCheckSeverity, _ as TraceCheckStatus, $ as TraceCheckSummary, a0 as TraceContract, a1 as TraceContractAlternativeBranch, a2 as TraceContractAlternatives, a3 as TraceContractBody, a4 as TraceContractControlRules, a5 as TraceContractInput, a6 as TraceContractLintDiagnostic, a7 as TraceContractLlmRules, a8 as TraceContractObservationProvenance, a9 as TraceContractObservationRules, aa as TraceContractRecoveryOperation, ab as TraceContractRecoveryRetryableErrors, ac as TraceContractRecoverySuccessfulResultDependency, ad as TraceContractRetryRules, ae as TraceContractRunRules, af as TraceContractScope, ag as TraceContractStepKind, ah as TraceContractStepOrderRelation, ai as TraceContractStepRef, aj as TraceContractStepRules, ak as TraceContractToolRules, al as TraceSignalRuleOptions, am as createBaselineRegressionRule, an as createDecisionRule, ao as createGuardrailRule, ap as createLlmUsageRule, aq as createMaxStepDurationRule, ar as createObservedOutcomeRule, as as createRequireCompletedRule, at as createRetrievalRule, au as createRunDepthRule, av as createRunDurationRule, aw as createRunEventCountRule, ax as createRunStatusRule, ay as createSafetyOversizedAttributeRule, az as createSafetyRawContentRule, aA as createSafetyRedactionRule, aB as createSafetySecretPatternRule, aC as createStallDetectionRule, aD as createStepOrderingRule, aE as createStructureCycleRule, aF as createStructureIncompleteRule, aG as createStructureOrphanRule, aH as createStructureParallelWidthRule, aI as createStructureRelationshipRule, aJ as createToolFailureRule, aK as createToolOrderingRule, aL as createToolUsageRule, aM as defineTraceContract, aN as evaluateToolArgumentValue, aO as evaluateTraceContract, aP as evaluateTraceContractRead, aQ as explainTraceContract, aR as extractToolArgumentPayload, aS as lintTraceContract, aT as projectLogicalEvents, aU as resolveCanonicalToolName, aV as resolveJsonPointer, aW as resolveTraceContractScope, aX as runTraceChecks, aY as workflowMetadataForRun } from './index-EQihlEei.cjs'; export { b as ATTRIBUTION_CONFIDENCES, c as ATTRIBUTION_CONFIDENCE_RANK, A as AttributionConfidence, i as isAttributionConfidence } from './inspect-event-ClM5Z8om.cjs'; export { P as PROGRAMMATIC_DIAGNOSTIC_SPECS, a as ProgrammaticDiagnosticCode, b as ProgrammaticDiagnosticSpec, f as formatProgrammaticDiagnostic } from './programmatic-gZTWLObB.cjs'; import { g as TraceReadResult } from './index-Cdww9h50.cjs'; import { P as PersistedInspectEvent } from './persisted-inspect-event-q2ViiBW6.cjs'; import './types-BA_IOdg4.cjs'; import './types-bwL8cBv5.cjs'; import './log-config-CyRGaaWd.cjs'; /** * Read-time derived failure roles for TraceFacts (6.19). * * Failure roles classify recorded error events using explicit or conservatively * correlated retry/recovery relationships. They never rewrite persisted status. * * @experimental Available through `agent-inspect/checks`. */ /** * Derived classification of a recorded failure. * * @experimental */ type DerivedFailureRole = "transient" | "recovered" | "terminal" | "unknown"; /** * Confidence for a derived failure classification. * * @experimental */ type DerivedFailureConfidence = "explicit" | "correlated" | "unknown"; /** * One derived failure fact over a logical error event. * * @experimental */ interface DerivedFailureFact { readonly eventId: string; readonly runId: string; readonly name: string; readonly kind: LogicalTraceEvent["kind"]; readonly role: DerivedFailureRole; readonly confidence: DerivedFailureConfidence; readonly basis: readonly string[]; readonly recoveryEventIds: readonly string[]; readonly retryRunIds: readonly string[]; } /** * Bounded role counts for MCP / Evidence parity. * * @experimental */ interface FailureRoleCounts { readonly transient: number; readonly recovered: number; readonly terminal: number; readonly unknown: number; } /** * Derive conservative failure roles over logical events. * * @experimental */ declare function deriveFailureFacts(logicalEvents: readonly LogicalTraceEvent[]): { failureFacts: readonly DerivedFailureFact[]; failuresByRole: ReadonlyMap; failureRoleCounts: FailureRoleCounts; }; /** * Read-time typed relationship facts (6.22). * * Facts never rewrite parent hierarchy. Confidence is explicit or correlated only — * never inferred from timestamps alone. * * @experimental Available through `agent-inspect/checks`. */ type TraceRelationshipType = "parent-child" | "source-lineage" | "attempt-of" | "retry-of" | "fallback-of" | "remediation-of" | "evidence-for" | "accepted-by" | "supersedes"; type TraceRelationshipConfidence = "explicit" | "correlated" | "unknown"; /** * Bounded relationship edge derived at read time. * * @experimental */ interface TraceRelationship { type: TraceRelationshipType; fromEventId: string; toEventId?: string; externalRef?: string; confidence: TraceRelationshipConfidence; basis: readonly string[]; } interface TraceRelationshipDiagnostic { code: string; message: string; eventId?: string; } /** * Derive typed relationship facts from persisted events without mutating hierarchy. */ declare function deriveRelationshipFacts(events: readonly PersistedInspectEvent[]): { relationships: readonly TraceRelationship[]; diagnostics: readonly TraceRelationshipDiagnostic[]; }; /** * Shared semantic parity summary over logical lifecycle projection. * * @experimental Available through `agent-inspect/checks`; formal TraceFacts in 6.13. */ /** * Bounded semantic counts shared by check / contract / MCP / Evidence consumers. * * @experimental */ interface SemanticParitySummary { readonly rawEventCount: number; readonly logicalEventCount: number; readonly runningLogicalCount: number; readonly finishedToolNames: readonly string[]; readonly finishedToolCount: number; readonly pairedCount: number; readonly parentRemapCount: number; readonly diagnostics: readonly LogicalProjectionDiagnostic[]; /** * Bounded derived failure role counts (6.19+). Additive; older readers ignore. * * @experimental */ readonly failureRoleCounts?: FailureRoleCounts; } /** * Summarize logical projection for cross-surface parity assertions. * * @experimental */ declare function summarizeSemanticParity(events: readonly PersistedInspectEvent[]): SemanticParitySummary; /** * Experimental TraceFacts foundation (6.13): indexes over logical events. * * Extends the 6.12.2 projection rather than introducing a parallel evaluator. * * @experimental */ interface TraceFacts { readonly rawEvents: readonly PersistedInspectEvent[]; readonly logicalEvents: readonly LogicalTraceEvent[]; readonly diagnostics: readonly LogicalProjectionDiagnostic[]; readonly toolsByName: ReadonlyMap; readonly llmEvents: readonly LogicalTraceEvent[]; readonly outcomeEvents: readonly LogicalTraceEvent[]; readonly summary: SemanticParitySummary; /** * Read-time derived failure classifications. Does not rewrite persisted status. * * @experimental Additive in 6.19. */ readonly failureFacts: readonly DerivedFailureFact[]; /** * Derived failure facts grouped by role. * * @experimental Additive in 6.19. */ readonly failuresByRole: ReadonlyMap; /** * Read-time typed relationship facts. Does not rewrite parent hierarchy. * * @experimental Additive in 6.22. */ readonly relationships: readonly TraceRelationship[]; /** * Diagnostics for unsupported or unresolved relationships. * * @experimental Additive in 6.22. */ readonly relationshipDiagnostics: readonly TraceRelationshipDiagnostic[]; } /** * Build TraceFacts from a TraceReadResult or normalized persisted events. * * @experimental */ declare function buildTraceFacts(input: TraceReadResult): TraceFacts; declare function buildTraceFacts(input: readonly PersistedInspectEvent[]): TraceFacts; export { type DerivedFailureConfidence, type DerivedFailureFact, type DerivedFailureRole, type FailureRoleCounts, LogicalProjectionDiagnostic, LogicalTraceEvent, type SemanticParitySummary, type TraceFacts, type TraceRelationship, type TraceRelationshipConfidence, type TraceRelationshipDiagnostic, type TraceRelationshipType, buildTraceFacts, deriveFailureFacts, deriveRelationshipFacts, summarizeSemanticParity };