Class CreateTuningJobConfig.Builder
- Enclosing class:
- CreateTuningJobConfig
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract CreateTuningJobConfig.BuilderadapterSize(AdapterSize adapterSize) Setter for adapterSize.adapterSize(AdapterSize.Known knownType) Setter for adapterSize given a known enum.adapterSize(String adapterSize) Setter for adapterSize given a string.abstract CreateTuningJobConfig.BuilderSetter for batchSize.abstract CreateTuningJobConfig.BuilderSetter for beta.abstract CreateTuningJobConfigbuild()Clears the value of adapterSize field.Clears the value of batchSize field.Clears the value of beta field.Clears the value of description field.Clears the value of epochCount field.Clears the value of evaluationConfig field.Clears the value of exportLastCheckpointOnly field.Clears the value of httpOptions field.Clears the value of labels field.Clears the value of learningRate field.Clears the value of learningRateMultiplier field.Clears the value of method field.Clears the value of preTunedModelCheckpointId field.Clears the value of tunedModelDisplayName field.Clears the value of validationDataset field.abstract CreateTuningJobConfig.Builderdescription(String description) Setter for description.abstract CreateTuningJobConfig.BuilderepochCount(Integer epochCount) Setter for epochCount.abstract CreateTuningJobConfig.BuilderevaluationConfig(EvaluationConfig evaluationConfig) Setter for evaluationConfig.evaluationConfig(EvaluationConfig.Builder evaluationConfigBuilder) Setter for evaluationConfig builder.abstract CreateTuningJobConfig.BuilderexportLastCheckpointOnly(boolean exportLastCheckpointOnly) Setter for exportLastCheckpointOnly.abstract CreateTuningJobConfig.BuilderhttpOptions(HttpOptions httpOptions) Setter for httpOptions.httpOptions(HttpOptions.Builder httpOptionsBuilder) Setter for httpOptions builder.abstract CreateTuningJobConfig.BuilderSetter for labels.abstract CreateTuningJobConfig.BuilderlearningRate(Float learningRate) Setter for learningRate.abstract CreateTuningJobConfig.BuilderlearningRateMultiplier(Float learningRateMultiplier) Setter for learningRateMultiplier.abstract CreateTuningJobConfig.Buildermethod(TuningMethod method) Setter for method.method(TuningMethod.Known knownType) Setter for method given a known enum.Setter for method given a string.abstract CreateTuningJobConfig.BuilderpreTunedModelCheckpointId(String preTunedModelCheckpointId) Setter for preTunedModelCheckpointId.abstract CreateTuningJobConfig.BuildertunedModelDisplayName(String tunedModelDisplayName) Setter for tunedModelDisplayName.abstract CreateTuningJobConfig.BuildervalidationDataset(TuningValidationDataset validationDataset) Setter for validationDataset.validationDataset(TuningValidationDataset.Builder validationDatasetBuilder) Setter for validationDataset builder.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
httpOptions
Setter for httpOptions.httpOptions: Used to override HTTP request options.
-
httpOptions
@CanIgnoreReturnValue public CreateTuningJobConfig.Builder httpOptions(HttpOptions.Builder httpOptionsBuilder) Setter for httpOptions builder.httpOptions: Used to override HTTP request options.
-
clearHttpOptions
Clears the value of httpOptions field. -
method
Setter for method.method: The method to use for tuning (SUPERVISED_FINE_TUNING or PREFERENCE_TUNING). If not set, the default method (SFT) will be used.
-
clearMethod
Clears the value of method field. -
method
Setter for method given a known enum.method: The method to use for tuning (SUPERVISED_FINE_TUNING or PREFERENCE_TUNING). If not set, the default method (SFT) will be used.
-
method
Setter for method given a string.method: The method to use for tuning (SUPERVISED_FINE_TUNING or PREFERENCE_TUNING). If not set, the default method (SFT) will be used.
-
validationDataset
public abstract CreateTuningJobConfig.Builder validationDataset(TuningValidationDataset validationDataset) Setter for validationDataset.validationDataset: Validation dataset for tuning. The dataset must be formatted as a JSONL file.
-
validationDataset
@CanIgnoreReturnValue public CreateTuningJobConfig.Builder validationDataset(TuningValidationDataset.Builder validationDatasetBuilder) Setter for validationDataset builder.validationDataset: Validation dataset for tuning. The dataset must be formatted as a JSONL file.
-
clearValidationDataset
Clears the value of validationDataset field. -
tunedModelDisplayName
Setter for tunedModelDisplayName.tunedModelDisplayName: The display name of the tuned Model. The name can be up to 128 characters long and can consist of any UTF-8 characters.
-
clearTunedModelDisplayName
Clears the value of tunedModelDisplayName field. -
description
Setter for description.description: The description of the TuningJob
-
clearDescription
Clears the value of description field. -
epochCount
Setter for epochCount.epochCount: Number of complete passes the model makes over the entire training dataset during training.
-
clearEpochCount
Clears the value of epochCount field. -
learningRateMultiplier
Setter for learningRateMultiplier.learningRateMultiplier: Multiplier for adjusting the default learning rate.
-
clearLearningRateMultiplier
Clears the value of learningRateMultiplier field. -
exportLastCheckpointOnly
public abstract CreateTuningJobConfig.Builder exportLastCheckpointOnly(boolean exportLastCheckpointOnly) Setter for exportLastCheckpointOnly.exportLastCheckpointOnly: If set to true, disable intermediate checkpoints and only the last checkpoint will be exported. Otherwise, enable intermediate checkpoints.
-
clearExportLastCheckpointOnly
Clears the value of exportLastCheckpointOnly field. -
preTunedModelCheckpointId
public abstract CreateTuningJobConfig.Builder preTunedModelCheckpointId(String preTunedModelCheckpointId) Setter for preTunedModelCheckpointId.preTunedModelCheckpointId: The optional checkpoint id of the pre-tuned model to use for tuning, if applicable.
-
clearPreTunedModelCheckpointId
Clears the value of preTunedModelCheckpointId field. -
adapterSize
Setter for adapterSize.adapterSize: Adapter size for tuning.
-
clearAdapterSize
Clears the value of adapterSize field. -
adapterSize
Setter for adapterSize given a known enum.adapterSize: Adapter size for tuning.
-
adapterSize
Setter for adapterSize given a string.adapterSize: Adapter size for tuning.
-
batchSize
Setter for batchSize.batchSize: The batch size hyperparameter for tuning. If not set, a default of 4 or 16 will be used based on the number of training examples.
-
clearBatchSize
Clears the value of batchSize field. -
learningRate
Setter for learningRate.learningRate: The learning rate hyperparameter for tuning. If not set, a default of 0.001 or 0.0002 will be calculated based on the number of training examples.
-
clearLearningRate
Clears the value of learningRate field. -
evaluationConfig
Setter for evaluationConfig.evaluationConfig: Evaluation config for the tuning job.
-
evaluationConfig
@CanIgnoreReturnValue public CreateTuningJobConfig.Builder evaluationConfig(EvaluationConfig.Builder evaluationConfigBuilder) Setter for evaluationConfig builder.evaluationConfig: Evaluation config for the tuning job.
-
clearEvaluationConfig
Clears the value of evaluationConfig field. -
labels
Setter for labels.labels: Optional. The labels with user-defined metadata to organize TuningJob and generated resources such as Model and Endpoint. Label keys and values can be no longer than 64 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. See https://goo.gl/xmQnxf for more information and examples of labels.
-
clearLabels
Clears the value of labels field. -
beta
Setter for beta.beta: Weight for KL Divergence regularization, Preference Optimization tuning only.
-
clearBeta
Clears the value of beta field. -
build
-