tool
function tool<TParameters, Context, Result>(options): FunctionTool<Context, TParameters, Result>
Exposes a function to the agent as a tool to be called
Type Parameters
Section titled “Type Parameters”Type Parameter | Default type |
---|---|
|
|
|
|
|
|
Parameters
Section titled “Parameters”Parameter | Type | Description |
---|---|---|
|
|
The options for the tool |
Returns
Section titled “Returns”FunctionTool
<Context
, TParameters
, Result
>
A new tool