+
    ~j-                      a  0 t $ ^ RIHt ^ RIHtHt ^ RIHt ^RIH	t	 ^RI
Ht ^RIHtHt ^RIHt  ! R R	]4      t]R<,          ],          t  ! R
 R]RR7      tRRRRRRRR/tR]R&    ! R R]RR7      tRRRRRRR^ RRRR R!R=/tR]R"&    ! R# R$]RR7      tRRR%RR&R'R(^/tR$]R)&    ! R* R+]RR7      tR,R-R.R-/tR+]R/&    ! R0 R1]RR7      tR>R2 R3 lltR>R4 R5 lltR>R6 R7 lltR>R8 R9 llt ]]]]]]]]]]]3R: R; llt!R-# )?    )annotations)LiteralProtocol)	TypedDict)LanguageCode)ChatContext)	NOT_GIVEN
NotGivenOris_givenc                  n    ] tR t^t]R R l4       t]R R l4       tR R ltR R ltR	R
/R R llt	Rt
R
# )_TurnDetectorc                   V ^8  d   QhRR/#    returnstr )formats   "n/Users/mitch_tango/dev/rabbit-r1-livekit/agent/.venv/lib/python3.14/site-packages/livekit/agents/voice/turn.py__annotate___TurnDetector.__annotate__   s      s     c                	    R # unknownr   selfs   &r   model_TurnDetector.model       r   c                   V ^8  d   QhRR/# r   r   )r   s   "r   r   r      s      # r   c                	    R # r   r   r   s   &r   provider_TurnDetector.provider   r!   r   c                    V ^8  d   QhRRRR/# )r   languageLanguageCode | Noner   float | Noner   )r   s   "r   r   r      s    ZZ1DZZr   c                	   "   R # 5iNr   r   r'   s   &&r   unlikely_threshold _TurnDetector.unlikely_threshold   s     WZ   c                    V ^8  d   QhRRRR/# )r   r'   r(   r   boolr   )r   s   "r   r   r      s    QQ0CQQr   c                	   "   R # 5ir+   r   r,   s   &&r   supports_language_TurnDetector.supports_language   s     cr/   timeoutNc               $    V ^8  d   QhRRRRRR/# )r   chat_ctxr   r5   r)   r   floatr   )r   s   "r   r   r      s$      #1=	r   c               	   "   R # 5ir+   r   )r   r7   r5   s   &&$r   predict_end_of_turn!_TurnDetector.predict_end_of_turn   s     r/   r   )__name__
__module____qualname____firstlineno__propertyr   r$   r-   r3   r:   __static_attributes__r   r   r   r   r      sC        [Q@D r   r   c                  J    ] tR t^/t$ RtR]R&    R]R&    R]R&    R]R&   RtR	# )
EndpointingOptionszConfiguration for endpointing.

All keys are optional. Missing keys inherit from the session default
(at the ``Agent`` level) or use the documented defaults
(at the ``AgentSession`` level).
zLiteral['fixed', 'dynamic']moder8   	min_delay	max_delayalphar   Nr<   r=   r>   r?   __doc____annotations__rA   r   r   r   rC   rC   /   s3     &%r2LCr   rC   F)totalrD   fixedrE   g      ?rF   g      @rG   g?_ENDPOINTING_DEFAULTSc                  z    ] tR t^Mt$ RtR]R&    R]R&    R]R&    R]R&    R	]R
&    R]R&    R]R&    R]R&   RtR# )InterruptionOptionsa  Configuration for interruption handling.

All keys are optional. Missing keys inherit from the session default
(at the ``Agent`` level) or use the documented defaults
(at the ``AgentSession`` level).

``mode`` absent means the session picks the best available strategy.
r1   enabledzLiteral['adaptive', 'vad']rD    discard_audio_if_uninterruptibler8   min_durationint	min_wordsresume_false_interruptionr)   false_interruption_timeoutz"float | tuple[float, float] | Nonebackchannel_boundaryr   NrH   r   r   r   rO   rO   M   s`     MB
$$! '+**N## ,,D<<r   rO   rP   TrQ   rR   rT   rU   rV   g       @rW   _INTERRUPTION_DEFAULTSc                  J    ] tR t^t$ RtR]R&    R]R&    R]R&    R]R&   R	tR
# )PreemptiveGenerationOptionsz(Configuration for preemptive generation.r1   rP   preemptive_ttsr8   max_speech_durationrS   max_retriesr   NrH   r   r   r   rZ   rZ      s3    2MI6 /
 Fr   rZ   r[   r\   g      $@r]   _PREEMPTIVE_GENERATION_DEFAULTSc                  2    ] tR t^t$ RtR]R&    R]R&   RtR# )UserTurnLimitOptionsa  Configuration for detecting when a user has been speaking too long
without the agent successfully responding.

The framework tracks accumulated word count and wall-clock duration
across consecutive user turns. Counters only reset when the agent
transitions to ``speaking`` state (i.e., produces audio output).

Both thresholds default to ``None`` (disabled). Set at least one to
enable the feature.
z
int | None	max_wordsr)   max_durationr   NrH   r   r   r   r`   r`      s!    	 ' 6r   r`   ra   Nrb   _USER_TURN_LIMIT_DEFAULTSc                  V    ] tR t^t$ RtR]R&    R]R&    R]R&    R]R	&    R
]R&   RtR# )TurnHandlingOptionsa^  Configuration for the turn handling system.

Can be passed as a plain dict::

    AgentSession(
        turn_handling={
            "endpointing": {"min_delay": 0.3},
            "interruption": {"enabled": False},
            "preemptive_generation": {"preemptive_tts": True},
        },
    )

All keys are optional and default to sensible values.
zTurnDetectionMode | Noneturn_detectionrC   endpointingrO   interruptionrZ   preemptive_generationr`   user_turn_limitr   NrH   r   r   r   re   re      s8     -,.##Z%%U66U))Mr   re   c                    V ^8  d   QhRRRR/# )r   configz"PreemptiveGenerationOptions | Noner   rZ   r   )r   s   "r   r   r      s      X X.X Xr   c                N    V f   \        R/ \        B # \        R/ / \        CV CB # z"Fill in defaults for missing keys.r   )rZ   r^   rl   s   &r   _resolve_preemptive_generationrp      s2     ~*M-LMM&W)V,K)Vv)VWWr   c                    V ^8  d   QhRRRR/# )r   rl   zEndpointingOptions | Noner   rC   r   )r   s   "r   r   r      s      E E!: EFX Er   c                N    V f   \        R/ \        B # \        R/ / \        CV CB # rn   )rC   rM   ro   s   &r   _resolve_endpointingrs      s0    ~!:$9::D C#8 CF CDDr   c                    V ^8  d   QhRRRR/# )r   rl   zInterruptionOptions | Noner   rO   r   )r   s   "r   r   r      s      G G&GGr   c                N    V f   \        R/ \        B # \        R/ / \        CV CB # )zJFill in defaults for missing keys (``mode`` stays absent if not provided).r   )rO   rX   ro   s   &r   _resolve_interruptionrv      s2     ~"<%;<<F!E$:!Ef!EFFr   c                    V ^8  d   QhRRRR/# )r   rl   zUserTurnLimitOptions | Noner   r`   r   )r   s   "r   r   r      s      K K'KKr   c                N    V f   \        R/ \        B # \        R/ / \        CV CB # rn   )r`   rc   ro   s   &r   _resolve_user_turn_limitry      s2     ~#@&?@@J"I%>"I&"IJJr   c               H    V ^8  d   QhRRRRRRRRRR	R
RRRRR	RR	RRRR	RR/# )r   min_endpointing_delayzNotGivenOr[float]max_endpointing_delayrV   zNotGivenOr[float | None]rf   z$NotGivenOr[TurnDetectionMode | None]rQ   zNotGivenOr[bool]min_interruption_durationmin_interruption_wordszNotGivenOr[int]allow_interruptionsrU    agent_false_interruption_timeoutri   r   re   r   )r   s   "r   r   r      s     3 3,3,3 !93 9	3
 '73  13 ,3 *3  03 '?3 ,3 3r   c                   \        V	4      '       d   T	p/ p/ p\        V 4      '       d   WR&   \        V4      '       d   WR&   V'       d   WR&   / pVRJ d   RVR&   \        V4      '       d   WMR&   \        V4      '       d   W]R&   \        V4      '       d   WmR&   \        V4      '       d   W-R	&   \        V4      '       d   WR
&   V'       d   WR&   \        V4      '       d   W;R&   \        V
4      '       d   RV
/VR&   V# )z>Build a TurnHandlingOptions from deprecated keyword arguments.rE   rF   rg   FrP   rQ   rR   rT   rV   rU   rh   rf   ri   r   )r{   r|   rV   rf   rQ   r}   r~   r   rU   r   ri   resultendpointing_optsrh   s   &&&&&&&&&&&   r   _migrate_turn_handlingr      s    011%E""$F ,.%&&(=%%&&(=% 0} )+Le#"'Y011;[78)**'@^$&''$:[!*++5O12)**4M01!-~#1 %&&+46K*L&'Mr   )sttvadrealtime_llmmanual)g      ?g      @r+   )"__conditional_annotations__
__future__r   typingr   r   typing_extensionsr   r'   r   llmr   typesr	   r
   utilsr   r   TurnDetectionModerC   rM   rJ   rO   rX   rZ   r^   r`   rc   re   rp   rs   rv   ry   r   )r   s   @r   <module>r      su   " " $ ' #  ) H $ BCmS C% C. GS	- ) %)5 %R t&C # / + F)5 F. te41	@ !< 69E 60 D3 / N)5 N:XEGK 09/8;D;D9B3<.7,52;AJ.73 3r   