Class BetaResponseTextConfig.Builder
-
- All Implemented Interfaces:
public final class BetaResponseTextConfig.BuilderA builder for BetaResponseTextConfig.
-
-
Method Summary
-
-
Method Detail
-
format
final BetaResponseTextConfig.Builder format(BetaResponseFormatTextConfig format)
An object specifying the format that the model must output.
Configuring
{ "type": "json_schema" }enables Structured Outputs, which ensures the model will match your supplied JSON schema. Learn more in the Structured Outputs guide.The default format is
{ "type": "text" }with no additional options.Not recommended for gpt-4o and newer models:
Setting to
{ "type": "json_object" }enables the older JSON mode, which ensures the message the model generates is valid JSON. Usingjson_schemais preferred for models that support it.
-
format
final BetaResponseTextConfig.Builder format(JsonField<BetaResponseFormatTextConfig> format)
Sets Builder.format to an arbitrary JSON value.
You should usually call Builder.format with a well-typed BetaResponseFormatTextConfig value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
format
final BetaResponseTextConfig.Builder format(BetaResponseFormatTextJsonSchemaConfig jsonSchema)
Alias for calling format with
BetaResponseFormatTextConfig.ofJsonSchema(jsonSchema).
-
formatText
final BetaResponseTextConfig.Builder formatText()
Alias for calling format with
BetaResponseFormatTextConfig.ofText().
-
formatJsonObject
final BetaResponseTextConfig.Builder formatJsonObject()
Alias for calling format with
BetaResponseFormatTextConfig.ofJsonObject().
-
verbosity
final BetaResponseTextConfig.Builder verbosity(BetaResponseTextConfig.Verbosity verbosity)
Constrains the verbosity of the model's response. Lower values will result in more concise responses, while higher values will result in more verbose responses. Currently supported values are
low,medium, andhigh.
-
verbosity
final BetaResponseTextConfig.Builder verbosity(Optional<BetaResponseTextConfig.Verbosity> verbosity)
Alias for calling Builder.verbosity with
verbosity.orElse(null).
-
verbosity
final BetaResponseTextConfig.Builder verbosity(JsonField<BetaResponseTextConfig.Verbosity> verbosity)
Sets Builder.verbosity to an arbitrary JSON value.
You should usually call Builder.verbosity with a well-typed Verbosity value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
additionalProperties
final BetaResponseTextConfig.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final BetaResponseTextConfig.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final BetaResponseTextConfig.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final BetaResponseTextConfig.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final BetaResponseTextConfig.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final BetaResponseTextConfig build()
Returns an immutable instance of BetaResponseTextConfig.
Further updates to this Builder will not mutate the returned instance.
-
-
-
-