toolExecutionConfig

fun toolExecutionConfig(toolExecutionConfig: ToolExecutionConfig)

Sets the tool execution config.

Parameters

toolExecutionConfig

The config to use.


fun toolExecutionConfig(autoExecute: Boolean = true, returnErrorsToAI: Boolean = true, maxConcurrency: Int = 5, executionDispatcher: CoroutineDispatcher = Dispatchers.IO, onToolCall: ToolExecutionCallback? = null)

Sets the tool execution config with individual parameters.

Parameters

autoExecute

If true, automatically executes tools.

returnErrorsToAI

If true, returns tool errors to the model.

maxConcurrency

Maximum number of concurrent tool executions.

executionDispatcher

Dispatcher used for tool execution.

onToolCall

Callback invoked when a tool is called.