Run the graph with a single input and config.
invoke(
self,
input: InputT | Command | None,
config: RunnableConfig | None = None,
*,
context: ContextT | None = None,
stream_mode: StreamMode = 'values',
print_mode: StreamMode | Sequence[StreamMode] = (),
output_keys: str | Sequence[str] | None = None,
interrupt_before: All | Sequence[str] | None = None,
interrupt_after: All | Sequence[str] | None = None,
durability: Durability | None = None,
**kwargs: Any = {}
) -> dict[str, Any] | Any| Name | Type | Description |
|---|---|---|
input* | InputT | Command | None | The input data for the graph. It can be a dictionary or any other type. |
config | RunnableConfig | None | Default: NoneThe configuration for the graph run. |
context | ContextT | None | Default: NoneThe static context to use for the run. |
stream_mode | StreamMode | Default: 'values'The stream mode for the graph run. |
print_mode | StreamMode | Sequence[StreamMode] | Default: ()Accepts the same values as Does not affect the output of the graph in any way. |
output_keys | str | Sequence[str] | None | Default: NoneThe output keys to retrieve from the graph run. |
interrupt_before | All | Sequence[str] | None | Default: NoneThe nodes to interrupt the graph run before. |
interrupt_after | All | Sequence[str] | None | Default: NoneThe nodes to interrupt the graph run after. |
durability | Durability | None | Default: NoneThe durability mode for the graph execution, defaults to Options are:
|
**kwargs | Any | Default: {}Additional keyword arguments to pass to the graph run. |