package com.correx.core.risk

import com.correx.core.events.orchestration.OrchestrationState
import com.correx.core.inference.InferenceState
import com.correx.core.validation.model.ValidationReport

/**
 * Immutable snapshot of all signals available for risk assessment at a given decision point.
 *
 * [validationReport] — issues raised by the validation pipeline for the current stage.
 * [orchestrationState] — current orchestration state, including retry count, failure reason,
 *   and retry policy. Carries execution-level signals that previously had no path into risk
 *   evaluation (e.g. [OrchestrationState.retryCount], [OrchestrationState.retryPolicy]).
 * [inferenceState] — inference history, used to detect timeouts for the current stage.
 *
 * Note: [StageOutcome] lives in core:kernel which depends on core:risk, so it cannot be
 * embedded here directly. The relevant execution signals it carries (retry count, failure
 * reason) are proxied through [orchestrationState], which is populated from config before
 * the first assessment call.
 */
data class RiskContext(
    val validationReport: ValidationReport,
    val orchestrationState: OrchestrationState,
    val inferenceState: InferenceState,
)
