Class: FunctionTool<T, R>
Simple Tool interface. Likely to change.
Type parameters
Name | Type |
---|---|
T | T |
R | extends JSONValue | Promise <JSONValue > |
Implements
BaseTool
<T
>
Constructors
constructor
• new FunctionTool<T
, R
>(_fn
, _metadata
): FunctionTool
<T
, R
>
Type parameters
Name | Type |
---|---|
T | T |
R | extends JSONValue | Promise <JSONValue > |
Parameters
Name | Type |
---|---|
_fn | (input : T ) => R |
_metadata | ToolMetadata <JSONSchemaType <T >> |