Invoke the assistant.
invoke(
self,
input: dict,
config: Optional[RunnableConfig] = None,
**kwargs: Any = {}
) -> OutputType| Name | Type | Description |
|---|---|---|
input* | dict | Runnable input dict that can have: content: User message when starting a new run. thread_id: Existing thread to use. run_id: Existing run to use. Should only be supplied when providing the tool output for a required action after an initial invocation. file_ids: (deprecated) File ids to include in new run. Use 'attachments' instead attachments: Assistant files to include in new run. (v2 API). message_metadata: Metadata to associate with new message. thread_metadata: Metadata to associate with new thread. Only relevant when new thread being created. instructions: Additional run instructions. model: Override Assistant model for this run. tools: Override Assistant tools for this run. tool_resources: Override Assistant tool resources for this run (v2 API). run_metadata: Metadata to associate with new run. |
config | Optional[RunnableConfig] | Default: NoneConfiguration for the run. |