ExecutionContext
Execution context for nodes containing state and runtime data.
Generic container that holds node state and additional context data for node execution. Provides dictionary-like access to context data while maintaining type safety for the node state.
Attributes
attribute
node_state= node_state
Functions
func
__init____init__(self, /, node_state, **kwargs) -> None
Initialize execution context with node state and additional data.
Args: node_state: Node-specific state object **kwargs: Additional context data as key-value pairs
Raises: AttributeError: If a key already exists in the context
param
selfparam
node_stateNS
param
kwargsAny
= {}
Returns
None
func
__getitem____getitem__(self, /, key) -> Any
Get context data by key.
Args: key: The key to retrieve from context
Returns: Value associated with the key
Raises: KeyError: If key is not found in context
param
selfparam
keystr
Returns
Any
func
__repr____repr__(self) -> str
Return string representation of the execution context.
Returns: String representation showing context ID, node state, and context data
param
selfReturns
str
Last updated on