SafeToolFromCallable
data class SafeToolFromCallable<TResult>(val toolFunction: KFunction<TResult>, environment: AIAgentEnvironment)(source)
A wrapper class that creates a safer abstraction for executing a tool function alongside an associated environment. The tool function is backed by a callable in the form of a KFunction
and interacts with the AIAgentEnvironment
to perform operations and exchange data.
Parameters
TResult
The type of the result produced by the tool function.