public static class FunctionDefinition.Builder extends Object
Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
FunctionDefinition |
build() |
FunctionDefinition.Builder |
copy(FunctionDefinition model) |
FunctionDefinition.Builder |
description(String description)
A description of what the function does, used by the model to choose when and how to call
the function.
|
FunctionDefinition.Builder |
name(String name)
The name of the function to be called.
|
FunctionDefinition.Builder |
parameters(Object parameters)
The parameters the functions accepts, described as a JSON Schema object.
|
public FunctionDefinition.Builder name(String name)
The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.
name
- the value to setpublic FunctionDefinition.Builder description(String description)
A description of what the function does, used by the model to choose when and how to call the function.
description
- the value to setpublic FunctionDefinition.Builder parameters(Object parameters)
The parameters the functions accepts, described as a JSON Schema object. Omitting parameters defines a function with an empty parameter list.
parameters
- the value to setpublic FunctionDefinition build()
public FunctionDefinition.Builder copy(FunctionDefinition model)
Copyright © 2016–2025. All rights reserved.