Skip to content

symfonic.platform.conversation_turn

conversation_turn

The selected-root conversation a running turn belongs to, for pause bindings.

A human_interaction binding resolves "what this run is" without arguments. The selected HTTP root binds the verified session and request scope here for exactly the turn it runs, so a deployment's binding can sign the conversation it was paused in. The root still checks the signed claims against its own session before it records or redeems the pause; this value is an input to the binding, never proof of ownership.

scope is None on roots that carry no framework scope object (the kernel native transport binds the session only). Readers must treat it as optional.

current_conversation_turn

current_conversation_turn() -> ConversationTurn | None

The selected-root turn running in this async context, if any.

Source code in src/symfonic/platform/conversation_turn.py
def current_conversation_turn() -> ConversationTurn | None:
    """The selected-root turn running in this async context, if any."""
    return _CURRENT.get()