
    %Gg2                        d Z ddlmZ ddlmZmZmZmZmZmZm	Z	m
Z
mZ eeeef      Z	 ed   Z	 ed   Z	 ed   Z	 ed   Z	 ed   Z	 ed	   Z	 ed
   Z	 ed   Z	 ed   Z	 ed   Z	  G d de
d      Z G d de
      Z G d de
      Zeeef   Z G d de
      Z G d de      Z G d de      Z G d de
d      Z  G d de
      Z! G d  d!e
      Z" G d" d#e
      Z# G d$ d%e
      Z$ G d& d'e
      Z% G d( d)e
      Z& G d* d+e
      Z' G d, d-e
      Z( G d. d/e
      Z) G d0 d1e(d      Z* G d2 d3e
      Z+ G d4 d5e      Z, G d6 d7e
      Z- G d8 d9e
d      Z.y:);z3Data models for interacting with the LangGraph API.    )datetime)	AnyDictLiteral
NamedTupleOptionalSequenceTuple	TypedDictUnion)pendingerrorsuccesstimeoutinterrupted)idlebusyr   r   )valuesmessagesupdateseventsdebugcustomzmessages-tuple)cancelcontinue)reject	interruptrollbackenqueue)raise
do_nothing)deletekeep*)creater   )r   r   c                   D    e Zd ZU dZee   ed<   	 eed<   	 eee	f   ed<   y)Configz!Configuration options for a call.tagsrecursion_limitconfigurableN)
__name__
__module____qualname____doc__liststr__annotations__intdictr        q/home/kushmeetdev/apache_webroot/langgraph_flaskproject/venv/lib/python3.12/site-packages/langgraph_sdk/schema.pyr'   r'   c   s5    +
s)O
  sCx. r5   r'   F)totalc                   V    e Zd ZU dZeed<   	 eed<   	 ee   ed<   	 eeeef      ed<   y)
Checkpointz1Represents a checkpoint in the execution process.	thread_idcheckpoint_nscheckpoint_idcheckpoint_mapN	r+   r,   r-   r.   r0   r1   r   r3   r   r4   r5   r6   r9   r9   z   s9    ;NKLC= ?T#s(^,,Br5   r9   c                   d    e Zd ZU dZeed<   	 ee   ed<   	 ee   ed<   	 ee   ed<   	 ee   ed<   y)GraphSchemaz0Defines the structure and properties of a graph.graph_idinput_schemaoutput_schemastate_schemaconfig_schemaN)r+   r,   r-   r.   r0   r1   r   r3   r4   r5   r6   r@   r@      sI    :M4. =D>!=4. =D>!=r5   r@   c                   v    e Zd ZU dZeed<   	 eed<   	 eed<   	 eed<   	 eed<   	 e	ed<   	 eed<   	 e
e   ed	<   y
)AssistantBasezBase model for an assistant.assistant_idrA   config
created_atmetadataversionnamedescriptionN)r+   r,   r-   r.   r0   r1   r'   r   Jsonr2   r   r4   r5   r6   rG   rG      sL    &"MN-N!L&
I##*r5   rG   c                       e Zd ZdZy)AssistantVersionz.Represents a specific version of an assistant.N)r+   r,   r-   r.   r4   r5   r6   rQ   rQ      s    8r5   rQ   c                       e Zd ZU dZeed<   y)	Assistantz3Represents an assistant with additional properties.
updated_atN)r+   r,   r-   r.   r   r1   r4   r5   r6   rS   rS      s    =2r5   rS   c                   R    e Zd ZU dZeed<   	 ed   ed<   	 eed<   	 ee	e
      ed<   y)	Interruptz1Represents an interruption in the execution flow.valueduringwhen	resumablensN)r+   r,   r-   r.   r   r1   r   boolr   r/   r0   r4   r5   r6   rV   rV      s5    ;J2
(
&O/c/r5   rV   c                   t    e Zd ZU dZeed<   	 eed<   	 eed<   	 eed<   	 eed<   	 eed<   	 e	ee
e   f   ed<   y	)
Threadz!Represents a conversation thread.r:   rJ   rT   rK   statusr   
interruptsN)r+   r,   r-   r.   r0   r1   r   rO   ThreadStatusr   r/   rV   r4   r5   r6   r^   r^      sO    +N*/NIL*S$y/)**5r5   r^   c                       e Zd ZU dZeed<   eed<   ee   ed<   ee   ed<   ee	   ed<   ed   ed<   ee
eef      ed	<   y
)
ThreadTaskz"Represents a task within a thread.idrM   r   r`   
checkpointThreadStatestateresultN)r+   r,   r-   r.   r0   r1   r   r/   rV   r9   r3   r   r4   r5   r6   rc   rc      sL    ,G
IC=Y$$M""T#s(^$$r5   rc   c                       e Zd ZU dZeee   eeef   f   e	d<   	 e
e   e	d<   	 ee	d<   	 ee	d<   	 ee   e	d<   	 ee   e	d<   	 e
e   e	d<   y	)
rf   z!Represents the state of a thread.r   nextre   rK   rJ   parent_checkpointtasksN)r+   r,   r-   r.   r   r/   r3   r0   r   r1   r	   r9   rO   r   rc   r4   r5   r6   rf   rf      sm    +$t*d38n,--
3-#N!%
++SJTr5   rf   c                       e Zd ZU dZeed<   y)ThreadUpdateStateResponsez7Represents the response from updating a thread's state.re   N)r+   r,   r-   r.   r9   r1   r4   r5   r6   rn   rn      s    A)r5   rn   c                   p    e Zd ZU dZeed<   	 eed<   	 eed<   	 eed<   	 eed<   	 eed<   	 eed<   	 e	ed	<   y
)Runz"Represents a single execution run.run_idr:   rH   rJ   rT   r_   rK   multitask_strategyN)
r+   r,   r-   r.   r0   r1   r   	RunStatusrO   MultitaskStrategyr4   r5   r6   rp   rp     sJ    ,KN3',kN))@r5   rp   c                   p    e Zd ZU dZeed<   	 ee   ed<   	 ee   ed<   	 eed<   	 eed<   	 eed<   	 eed<   y	)
CronzRepresents a scheduled task.cron_idr:   end_timeschedulerJ   rT   payloadN)	r+   r,   r-   r.   r0   r1   r   r   r3   r4   r5   r6   rv   rv     sJ    &L}x  0M+(-M6r5   rv   c                       e Zd ZU dZee   ed<   	 eed<   	 ee   ed<   	 ee   ed<   	 ee   ed<   	 ee   ed<   	 ee	e      ed<   	 ee	e      ed	<   	 ee   ed
<   	 ee
   ed<   y)	RunCreatez7Defines the parameters for initiating a background run.r:   rH   inputrK   rI   r<   interrupt_beforeinterrupt_afterwebhookrr   N)r+   r,   r-   r.   r   r0   r1   r3   r'   r/   rt   r4   r5   r6   r|   r|   .  s    A}U>D>)tn8V,C= 8tCy));d3i((:c]E !233Cr5   r|   c                   \    e Zd ZU dZee   ed<   	 eed<   	 eeef   ed<   	 e	ed<   	 e	ed<   y)ItemzyRepresents a single document or data entry in the graph's Store.

    Items are used to store cross-thread memories.
    	namespacekeyrW   rJ   rT   N)
r+   r,   r-   r.   r/   r0   r1   r3   r   r   r4   r5   r6   r   r   G  sE    
 CyX	H S>D27r5   r   c                   (    e Zd ZU dZeee      ed<   y)ListNamespaceResponsez*Response structure for listing namespaces.
namespacesN)r+   r,   r-   r.   r/   r0   r1   r4   r5   r6   r   r   \  s    4T#YJr5   r   c                   "    e Zd ZU dZee   ed<   y)
SearchItemzItem with an optional relevance score from search operations.

    Attributes:
        score (Optional[float]): Relevance/similarity score. Included when
            searching a compatible store with a natural language query.
    scoreN)r+   r,   r-   r.   r   floatr1   r4   r5   r6   r   r   c  s     E?r5   r   c                   "    e Zd ZU dZee   ed<   y)SearchItemsResponsez'Response structure for searching items.itemsN)r+   r,   r-   r.   r/   r   r1   r4   r5   r6   r   r   n  s    1
7r5   r   c                   (    e Zd ZU dZeed<   	 eed<   y)
StreamPartz'Represents a part of a stream response.eventdataN)r+   r,   r-   r.   r0   r1   r3   r4   r5   r6   r   r   u  s    1J1
J5r5   r   c                   8    e Zd ZU dZeed<   	 eeeef      ed<   y)SendzRepresents a message to be sent to a specific node in the graph.

    This type is used to explicitly send messages to nodes in the graph, typically
    used within Command objects to control graph execution flow.
    noder}   Nr>   r4   r5   r6   r   r   ~  s)     I=DcN##7r5   r   c                   t    e Zd ZU dZeeeeeeef      f   ed<   	 ee	ee
f   eeee
f      f   ed<   	 e
ed<   y)Commanda  Represents one or more commands to control graph execution flow and state.

    This type defines the control commands that can be returned by nodes to influence
    graph execution. It lets you navigate to other nodes, update graph state,
    and resume from interruptions.
    gotoupdateresumeN)r+   r,   r-   r.   r   r   r0   r	   r1   r3   r   r
   r4   r5   r6   r   r     sf     c8E$)$455
66 $sCx.(5c?";;<<
 Kr5   r   N)/r.   r   typingr   r   r   r   r   r	   r
   r   r   r3   r0   rO   rs   ra   
StreamModeDisconnectModert   OnConflictBehaviorOnCompletionBehaviorAllIfNotExistsCancelActionr'   r9   r@   	SubgraphsrG   rQ   rS   rV   r^   rc   rf   rn   rp   rv   r|   r   r   r   r   r   r   r   r4   r5   r6   <module>r      s   9 
 
 
 S#X jKL	 => R
 -. HI  23  /0  cl .() ./Ye .
C 
C=) =& k!"	+I +*	} 	3 3
0	 
06Y 6&	% 	%U) U(*	 *A) A*79 7&D	 D289 8*KI KU 8) 86 679 7iu r5   