Class CreateEvalCompletionsRunDataSource.SamplingParams
-
- All Implemented Interfaces:
public final class CreateEvalCompletionsRunDataSource.SamplingParams
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classCreateEvalCompletionsRunDataSource.SamplingParams.BuilderA builder for SamplingParams.
public final classCreateEvalCompletionsRunDataSource.SamplingParams.ResponseFormatAn object specifying the format that the model must output.
Setting to
{ "type": "json_schema", "json_schema": {...} }enables Structured Outputs which ensures the model will match your supplied JSON schema. Learn more in the Structured Outputs guide.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.
-
Method Summary
Modifier and Type Method Description final Optional<Long>maxCompletionTokens()The maximum number of tokens in the generated output. final Optional<ReasoningEffort>reasoningEffort()Constrains effort on reasoning for reasoning models. final Optional<CreateEvalCompletionsRunDataSource.SamplingParams.ResponseFormat>responseFormat()An object specifying the format that the model must output. final Optional<Long>seed()A seed value to initialize the randomness, during sampling. final Optional<Double>temperature()A higher temperature increases randomness in the outputs. final Optional<List<ChatCompletionFunctionTool>>tools()A list of tools the model may call. final Optional<Double>topP()An alternative to temperature for nucleus sampling; 1.0 includes all tokens. final JsonField<Long>_maxCompletionTokens()Returns the raw JSON value of maxCompletionTokens. final JsonField<ReasoningEffort>_reasoningEffort()Returns the raw JSON value of reasoningEffort. final JsonField<CreateEvalCompletionsRunDataSource.SamplingParams.ResponseFormat>_responseFormat()Returns the raw JSON value of responseFormat. final JsonField<Long>_seed()Returns the raw JSON value of seed. final JsonField<Double>_temperature()Returns the raw JSON value of temperature. final JsonField<List<ChatCompletionFunctionTool>>_tools()Returns the raw JSON value of tools. final JsonField<Double>_topP()Returns the raw JSON value of topP. final Map<String, JsonValue>_additionalProperties()final CreateEvalCompletionsRunDataSource.SamplingParams.BuildertoBuilder()final CreateEvalCompletionsRunDataSource.SamplingParamsvalidate()final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static CreateEvalCompletionsRunDataSource.SamplingParams.Builderbuilder()Returns a mutable builder for constructing an instance of SamplingParams. -
-
Method Detail
-
maxCompletionTokens
final Optional<Long> maxCompletionTokens()
The maximum number of tokens in the generated output.
-
reasoningEffort
final Optional<ReasoningEffort> reasoningEffort()
Constrains effort on reasoning for reasoning models. Currently supported values are
minimal,low,medium, andhigh. Reducing reasoning effort can result in faster responses and fewer tokens used on reasoning in a response.
-
responseFormat
final Optional<CreateEvalCompletionsRunDataSource.SamplingParams.ResponseFormat> responseFormat()
An object specifying the format that the model must output.
Setting to
{ "type": "json_schema", "json_schema": {...} }enables Structured Outputs which ensures the model will match your supplied JSON schema. Learn more in the Structured Outputs guide.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.
-
temperature
final Optional<Double> temperature()
A higher temperature increases randomness in the outputs.
-
tools
final Optional<List<ChatCompletionFunctionTool>> tools()
A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.
-
topP
final Optional<Double> topP()
An alternative to temperature for nucleus sampling; 1.0 includes all tokens.
-
_maxCompletionTokens
final JsonField<Long> _maxCompletionTokens()
Returns the raw JSON value of maxCompletionTokens.
Unlike maxCompletionTokens, this method doesn't throw if the JSON field has an unexpected type.
-
_reasoningEffort
final JsonField<ReasoningEffort> _reasoningEffort()
Returns the raw JSON value of reasoningEffort.
Unlike reasoningEffort, this method doesn't throw if the JSON field has an unexpected type.
-
_responseFormat
final JsonField<CreateEvalCompletionsRunDataSource.SamplingParams.ResponseFormat> _responseFormat()
Returns the raw JSON value of responseFormat.
Unlike responseFormat, this method doesn't throw if the JSON field has an unexpected type.
-
_seed
final JsonField<Long> _seed()
Returns the raw JSON value of seed.
Unlike seed, this method doesn't throw if the JSON field has an unexpected type.
-
_temperature
final JsonField<Double> _temperature()
Returns the raw JSON value of temperature.
Unlike temperature, this method doesn't throw if the JSON field has an unexpected type.
-
_tools
final JsonField<List<ChatCompletionFunctionTool>> _tools()
Returns the raw JSON value of tools.
Unlike tools, this method doesn't throw if the JSON field has an unexpected type.
-
_topP
final JsonField<Double> _topP()
Returns the raw JSON value of topP.
Unlike topP, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final CreateEvalCompletionsRunDataSource.SamplingParams.Builder toBuilder()
-
validate
final CreateEvalCompletionsRunDataSource.SamplingParams validate()
-
builder
final static CreateEvalCompletionsRunDataSource.SamplingParams.Builder builder()
Returns a mutable builder for constructing an instance of SamplingParams.
-
-
-
-