package com.correx.core.talkie.model

/**
 * Describes the event or condition that prompted a narration inference call.
 *
 * The trigger is stored verbatim in [TalkieNarrationEvent.trigger] so it can be
 * replayed and displayed without re-querying the environment.
 */
data class NarrationTrigger(
    /** Short label identifying the trigger kind (e.g. "stage_completed", "tool_executed"). */
    val kind: String,
    /** Human-readable instruction injected as the final context entry for this narration. */
    val instruction: String,
    /**
     * Stage the triggering event belongs to. Carried on the trigger because the router
     * projection's currentStageId is already cleared (workflow terminal events) or not yet
     * written when the narrator fires — reading it back from state races the reducer.
     */
    val stageId: String? = null,
)
