// Copyright 2025 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.35.2 // protoc v4.25.7 // source: google/cloud/aiplatform/v1/training_pipeline.proto package aiplatformpb import ( _ "google.golang.org/genproto/googleapis/api/annotations" status "google.golang.org/genproto/googleapis/rpc/status" protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoimpl "google.golang.org/protobuf/runtime/protoimpl" structpb "google.golang.org/protobuf/types/known/structpb" timestamppb "google.golang.org/protobuf/types/known/timestamppb" reflect "reflect" sync "sync" ) const ( // Verify that this generated code is sufficiently up-to-date. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) // Verify that runtime/protoimpl is sufficiently up-to-date. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) // The TrainingPipeline orchestrates tasks associated with training a Model. It // always executes the training task, and optionally may also // export data from Vertex AI's Dataset which becomes the training input, // [upload][google.cloud.aiplatform.v1.ModelService.UploadModel] the Model to // Vertex AI, and evaluate the Model. type TrainingPipeline struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields // Output only. Resource name of the TrainingPipeline. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Required. The user-defined name of this TrainingPipeline. DisplayName string `protobuf:"bytes,2,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"` // Specifies Vertex AI owned input data that may be used for training the // Model. The TrainingPipeline's // [training_task_definition][google.cloud.aiplatform.v1.TrainingPipeline.training_task_definition] // should make clear whether this config is used and if there are any special // requirements on how it should be filled. If nothing about this config is // mentioned in the // [training_task_definition][google.cloud.aiplatform.v1.TrainingPipeline.training_task_definition], // then it should be assumed that the TrainingPipeline does not depend on this // configuration. InputDataConfig *InputDataConfig `protobuf:"bytes,3,opt,name=input_data_config,json=inputDataConfig,proto3" json:"input_data_config,omitempty"` // Required. A Google Cloud Storage path to the YAML file that defines the // training task which is responsible for producing the model artifact, and // may also include additional auxiliary work. The definition files that can // be used here are found in // gs://google-cloud-aiplatform/schema/trainingjob/definition/. // Note: The URI given on output will be immutable and probably different, // including the URI scheme, than the one given on input. The output URI will // point to a location where the user only has a read access. TrainingTaskDefinition string `protobuf:"bytes,4,opt,name=training_task_definition,json=trainingTaskDefinition,proto3" json:"training_task_definition,omitempty"` // Required. The training task's parameter(s), as specified in the // [training_task_definition][google.cloud.aiplatform.v1.TrainingPipeline.training_task_definition]'s // `inputs`. TrainingTaskInputs *structpb.Value `protobuf:"bytes,5,opt,name=training_task_inputs,json=trainingTaskInputs,proto3" json:"training_task_inputs,omitempty"` // Output only. The metadata information as specified in the // [training_task_definition][google.cloud.aiplatform.v1.TrainingPipeline.training_task_definition]'s // `metadata`. This metadata is an auxiliary runtime and final information // about the training task. While the pipeline is running this information is // populated only at a best effort basis. Only present if the // pipeline's // [training_task_definition][google.cloud.aiplatform.v1.TrainingPipeline.training_task_definition] // contains `metadata` object. TrainingTaskMetadata *structpb.Value `protobuf:"bytes,6,opt,name=training_task_metadata,json=trainingTaskMetadata,proto3" json:"training_task_metadata,omitempty"` // Describes the Model that may be uploaded (via // [ModelService.UploadModel][google.cloud.aiplatform.v1.ModelService.UploadModel]) // by this TrainingPipeline. The TrainingPipeline's // [training_task_definition][google.cloud.aiplatform.v1.TrainingPipeline.training_task_definition] // should make clear whether this Model description should be populated, and // if there are any special requirements regarding how it should be filled. If // nothing is mentioned in the // [training_task_definition][google.cloud.aiplatform.v1.TrainingPipeline.training_task_definition], // then it should be assumed that this field should not be filled and the // training task either uploads the Model without a need of this information, // or that training task does not support uploading a Model as part of the // pipeline. When the Pipeline's state becomes `PIPELINE_STATE_SUCCEEDED` and // the trained Model had been uploaded into Vertex AI, then the // model_to_upload's resource [name][google.cloud.aiplatform.v1.Model.name] is // populated. The Model is always uploaded into the Project and Location in // which this pipeline is. ModelToUpload *Model `protobuf:"bytes,7,opt,name=model_to_upload,json=modelToUpload,proto3" json:"model_to_upload,omitempty"` // Optional. The ID to use for the uploaded Model, which will become the final // component of the model resource name. // // This value may be up to 63 characters, and valid characters are // `[a-z0-9_-]`. The first character cannot be a number or hyphen. ModelId string `protobuf:"bytes,22,opt,name=model_id,json=modelId,proto3" json:"model_id,omitempty"` // Optional. When specify this field, the `model_to_upload` will not be // uploaded as a new model, instead, it will become a new version of this // `parent_model`. ParentModel string `protobuf:"bytes,21,opt,name=parent_model,json=parentModel,proto3" json:"parent_model,omitempty"` // Output only. The detailed state of the pipeline. State PipelineState `protobuf:"varint,9,opt,name=state,proto3,enum=google.cloud.aiplatform.v1.PipelineState" json:"state,omitempty"` // Output only. Only populated when the pipeline's state is // `PIPELINE_STATE_FAILED` or `PIPELINE_STATE_CANCELLED`. Error *status.Status `protobuf:"bytes,10,opt,name=error,proto3" json:"error,omitempty"` // Output only. Time when the TrainingPipeline was created. CreateTime *timestamppb.Timestamp `protobuf:"bytes,11,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"` // Output only. Time when the TrainingPipeline for the first time entered the // `PIPELINE_STATE_RUNNING` state. StartTime *timestamppb.Timestamp `protobuf:"bytes,12,opt,name=start_time,json=startTime,proto3" json:"start_time,omitempty"` // Output only. Time when the TrainingPipeline entered any of the following // states: `PIPELINE_STATE_SUCCEEDED`, `PIPELINE_STATE_FAILED`, // `PIPELINE_STATE_CANCELLED`. EndTime *timestamppb.Timestamp `protobuf:"bytes,13,opt,name=end_time,json=endTime,proto3" json:"end_time,omitempty"` // Output only. Time when the TrainingPipeline was most recently updated. UpdateTime *timestamppb.Timestamp `protobuf:"bytes,14,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"` // The labels with user-defined metadata to organize TrainingPipelines. // // 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. Labels map[string]string `protobuf:"bytes,15,rep,name=labels,proto3" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // Customer-managed encryption key spec for a TrainingPipeline. If set, this // TrainingPipeline will be secured by this key. // // Note: Model trained by this TrainingPipeline is also secured by this key if // [model_to_upload][google.cloud.aiplatform.v1.TrainingPipeline.encryption_spec] // is not set separately. EncryptionSpec *EncryptionSpec `protobuf:"bytes,18,opt,name=encryption_spec,json=encryptionSpec,proto3" json:"encryption_spec,omitempty"` } func (x *TrainingPipeline) Reset() { *x = TrainingPipeline{} mi := &file_google_cloud_aiplatform_v1_training_pipeline_proto_msgTypes[0] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *TrainingPipeline) String() string { return protoimpl.X.MessageStringOf(x) } func (*TrainingPipeline) ProtoMessage() {} func (x *TrainingPipeline) ProtoReflect() protoreflect.Message { mi := &file_google_cloud_aiplatform_v1_training_pipeline_proto_msgTypes[0] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use TrainingPipeline.ProtoReflect.Descriptor instead. func (*TrainingPipeline) Descriptor() ([]byte, []int) { return file_google_cloud_aiplatform_v1_training_pipeline_proto_rawDescGZIP(), []int{0} } func (x *TrainingPipeline) GetName() string { if x != nil { return x.Name } return "" } func (x *TrainingPipeline) GetDisplayName() string { if x != nil { return x.DisplayName } return "" } func (x *TrainingPipeline) GetInputDataConfig() *InputDataConfig { if x != nil { return x.InputDataConfig } return nil } func (x *TrainingPipeline) GetTrainingTaskDefinition() string { if x != nil { return x.TrainingTaskDefinition } return "" } func (x *TrainingPipeline) GetTrainingTaskInputs() *structpb.Value { if x != nil { return x.TrainingTaskInputs } return nil } func (x *TrainingPipeline) GetTrainingTaskMetadata() *structpb.Value { if x != nil { return x.TrainingTaskMetadata } return nil } func (x *TrainingPipeline) GetModelToUpload() *Model { if x != nil { return x.ModelToUpload } return nil } func (x *TrainingPipeline) GetModelId() string { if x != nil { return x.ModelId } return "" } func (x *TrainingPipeline) GetParentModel() string { if x != nil { return x.ParentModel } return "" } func (x *TrainingPipeline) GetState() PipelineState { if x != nil { return x.State } return PipelineState_PIPELINE_STATE_UNSPECIFIED } func (x *TrainingPipeline) GetError() *status.Status { if x != nil { return x.Error } return nil } func (x *TrainingPipeline) GetCreateTime() *timestamppb.Timestamp { if x != nil { return x.CreateTime } return nil } func (x *TrainingPipeline) GetStartTime() *timestamppb.Timestamp { if x != nil { return x.StartTime } return nil } func (x *TrainingPipeline) GetEndTime() *timestamppb.Timestamp { if x != nil { return x.EndTime } return nil } func (x *TrainingPipeline) GetUpdateTime() *timestamppb.Timestamp { if x != nil { return x.UpdateTime } return nil } func (x *TrainingPipeline) GetLabels() map[string]string { if x != nil { return x.Labels } return nil } func (x *TrainingPipeline) GetEncryptionSpec() *EncryptionSpec { if x != nil { return x.EncryptionSpec } return nil } // Specifies Vertex AI owned input data to be used for training, and // possibly evaluating, the Model. type InputDataConfig struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields // The instructions how the input data should be split between the // training, validation and test sets. // If no split type is provided, the // [fraction_split][google.cloud.aiplatform.v1.InputDataConfig.fraction_split] // is used by default. // // Types that are assignable to Split: // // *InputDataConfig_FractionSplit // *InputDataConfig_FilterSplit // *InputDataConfig_PredefinedSplit // *InputDataConfig_TimestampSplit // *InputDataConfig_StratifiedSplit Split isInputDataConfig_Split `protobuf_oneof:"split"` // Only applicable to Custom and Hyperparameter Tuning TrainingPipelines. // // The destination of the training data to be written to. // // Supported destination file formats: // - For non-tabular data: "jsonl". // - For tabular data: "csv" and "bigquery". // // The following Vertex AI environment variables are passed to containers // or python modules of the training task when this field is set: // // * AIP_DATA_FORMAT : Exported data format. // * AIP_TRAINING_DATA_URI : Sharded exported training data uris. // * AIP_VALIDATION_DATA_URI : Sharded exported validation data uris. // * AIP_TEST_DATA_URI : Sharded exported test data uris. // // Types that are assignable to Destination: // // *InputDataConfig_GcsDestination // *InputDataConfig_BigqueryDestination Destination isInputDataConfig_Destination `protobuf_oneof:"destination"` // Required. The ID of the Dataset in the same Project and Location which data // will be used to train the Model. The Dataset must use schema compatible // with Model being trained, and what is compatible should be described in the // used TrainingPipeline's [training_task_definition] // [google.cloud.aiplatform.v1.TrainingPipeline.training_task_definition]. // For tabular Datasets, all their data is exported to training, to pick // and choose from. DatasetId string `protobuf:"bytes,1,opt,name=dataset_id,json=datasetId,proto3" json:"dataset_id,omitempty"` // Applicable only to Datasets that have DataItems and Annotations. // // A filter on Annotations of the Dataset. Only Annotations that both // match this filter and belong to DataItems not ignored by the split method // are used in respectively training, validation or test role, depending on // the role of the DataItem they are on (for the auto-assigned that role is // decided by Vertex AI). A filter with same syntax as the one used in // [ListAnnotations][google.cloud.aiplatform.v1.DatasetService.ListAnnotations] // may be used, but note here it filters across all Annotations of the // Dataset, and not just within a single DataItem. AnnotationsFilter string `protobuf:"bytes,6,opt,name=annotations_filter,json=annotationsFilter,proto3" json:"annotations_filter,omitempty"` // Applicable only to custom training with Datasets that have DataItems and // Annotations. // // Cloud Storage URI that points to a YAML file describing the annotation // schema. The schema is defined as an OpenAPI 3.0.2 [Schema // Object](https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.2.md#schemaObject). // The schema files that can be used here are found in // gs://google-cloud-aiplatform/schema/dataset/annotation/ , note that the // chosen schema must be consistent with // [metadata][google.cloud.aiplatform.v1.Dataset.metadata_schema_uri] of the // Dataset specified by // [dataset_id][google.cloud.aiplatform.v1.InputDataConfig.dataset_id]. // // Only Annotations that both match this schema and belong to DataItems not // ignored by the split method are used in respectively training, validation // or test role, depending on the role of the DataItem they are on. // // When used in conjunction with // [annotations_filter][google.cloud.aiplatform.v1.InputDataConfig.annotations_filter], // the Annotations used for training are filtered by both // [annotations_filter][google.cloud.aiplatform.v1.InputDataConfig.annotations_filter] // and // [annotation_schema_uri][google.cloud.aiplatform.v1.InputDataConfig.annotation_schema_uri]. AnnotationSchemaUri string `protobuf:"bytes,9,opt,name=annotation_schema_uri,json=annotationSchemaUri,proto3" json:"annotation_schema_uri,omitempty"` // Only applicable to Datasets that have SavedQueries. // // The ID of a SavedQuery (annotation set) under the Dataset specified by // [dataset_id][google.cloud.aiplatform.v1.InputDataConfig.dataset_id] used // for filtering Annotations for training. // // Only Annotations that are associated with this SavedQuery are used in // respectively training. When used in conjunction with // [annotations_filter][google.cloud.aiplatform.v1.InputDataConfig.annotations_filter], // the Annotations used for training are filtered by both // [saved_query_id][google.cloud.aiplatform.v1.InputDataConfig.saved_query_id] // and // [annotations_filter][google.cloud.aiplatform.v1.InputDataConfig.annotations_filter]. // // Only one of // [saved_query_id][google.cloud.aiplatform.v1.InputDataConfig.saved_query_id] // and // [annotation_schema_uri][google.cloud.aiplatform.v1.InputDataConfig.annotation_schema_uri] // should be specified as both of them represent the same thing: problem type. SavedQueryId string `protobuf:"bytes,7,opt,name=saved_query_id,json=savedQueryId,proto3" json:"saved_query_id,omitempty"` // Whether to persist the ML use assignment to data item system labels. PersistMlUseAssignment bool `protobuf:"varint,11,opt,name=persist_ml_use_assignment,json=persistMlUseAssignment,proto3" json:"persist_ml_use_assignment,omitempty"` } func (x *InputDataConfig) Reset() { *x = InputDataConfig{} mi := &file_google_cloud_aiplatform_v1_training_pipeline_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *InputDataConfig) String() string { return protoimpl.X.MessageStringOf(x) } func (*InputDataConfig) ProtoMessage() {} func (x *InputDataConfig) ProtoReflect() protoreflect.Message { mi := &file_google_cloud_aiplatform_v1_training_pipeline_proto_msgTypes[1] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use InputDataConfig.ProtoReflect.Descriptor instead. func (*InputDataConfig) Descriptor() ([]byte, []int) { return file_google_cloud_aiplatform_v1_training_pipeline_proto_rawDescGZIP(), []int{1} } func (m *InputDataConfig) GetSplit() isInputDataConfig_Split { if m != nil { return m.Split } return nil } func (x *InputDataConfig) GetFractionSplit() *FractionSplit { if x, ok := x.GetSplit().(*InputDataConfig_FractionSplit); ok { return x.FractionSplit } return nil } func (x *InputDataConfig) GetFilterSplit() *FilterSplit { if x, ok := x.GetSplit().(*InputDataConfig_FilterSplit); ok { return x.FilterSplit } return nil } func (x *InputDataConfig) GetPredefinedSplit() *PredefinedSplit { if x, ok := x.GetSplit().(*InputDataConfig_PredefinedSplit); ok { return x.PredefinedSplit } return nil } func (x *InputDataConfig) GetTimestampSplit() *TimestampSplit { if x, ok := x.GetSplit().(*InputDataConfig_TimestampSplit); ok { return x.TimestampSplit } return nil } func (x *InputDataConfig) GetStratifiedSplit() *StratifiedSplit { if x, ok := x.GetSplit().(*InputDataConfig_StratifiedSplit); ok { return x.StratifiedSplit } return nil } func (m *InputDataConfig) GetDestination() isInputDataConfig_Destination { if m != nil { return m.Destination } return nil } func (x *InputDataConfig) GetGcsDestination() *GcsDestination { if x, ok := x.GetDestination().(*InputDataConfig_GcsDestination); ok { return x.GcsDestination } return nil } func (x *InputDataConfig) GetBigqueryDestination() *BigQueryDestination { if x, ok := x.GetDestination().(*InputDataConfig_BigqueryDestination); ok { return x.BigqueryDestination } return nil } func (x *InputDataConfig) GetDatasetId() string { if x != nil { return x.DatasetId } return "" } func (x *InputDataConfig) GetAnnotationsFilter() string { if x != nil { return x.AnnotationsFilter } return "" } func (x *InputDataConfig) GetAnnotationSchemaUri() string { if x != nil { return x.AnnotationSchemaUri } return "" } func (x *InputDataConfig) GetSavedQueryId() string { if x != nil { return x.SavedQueryId } return "" } func (x *InputDataConfig) GetPersistMlUseAssignment() bool { if x != nil { return x.PersistMlUseAssignment } return false } type isInputDataConfig_Split interface { isInputDataConfig_Split() } type InputDataConfig_FractionSplit struct { // Split based on fractions defining the size of each set. FractionSplit *FractionSplit `protobuf:"bytes,2,opt,name=fraction_split,json=fractionSplit,proto3,oneof"` } type InputDataConfig_FilterSplit struct { // Split based on the provided filters for each set. FilterSplit *FilterSplit `protobuf:"bytes,3,opt,name=filter_split,json=filterSplit,proto3,oneof"` } type InputDataConfig_PredefinedSplit struct { // Supported only for tabular Datasets. // // Split based on a predefined key. PredefinedSplit *PredefinedSplit `protobuf:"bytes,4,opt,name=predefined_split,json=predefinedSplit,proto3,oneof"` } type InputDataConfig_TimestampSplit struct { // Supported only for tabular Datasets. // // Split based on the timestamp of the input data pieces. TimestampSplit *TimestampSplit `protobuf:"bytes,5,opt,name=timestamp_split,json=timestampSplit,proto3,oneof"` } type InputDataConfig_StratifiedSplit struct { // Supported only for tabular Datasets. // // Split based on the distribution of the specified column. StratifiedSplit *StratifiedSplit `protobuf:"bytes,12,opt,name=stratified_split,json=stratifiedSplit,proto3,oneof"` } func (*InputDataConfig_FractionSplit) isInputDataConfig_Split() {} func (*InputDataConfig_FilterSplit) isInputDataConfig_Split() {} func (*InputDataConfig_PredefinedSplit) isInputDataConfig_Split() {} func (*InputDataConfig_TimestampSplit) isInputDataConfig_Split() {} func (*InputDataConfig_StratifiedSplit) isInputDataConfig_Split() {} type isInputDataConfig_Destination interface { isInputDataConfig_Destination() } type InputDataConfig_GcsDestination struct { // The Cloud Storage location where the training data is to be // written to. In the given directory a new directory is created with // name: // `dataset---` // where timestamp is in YYYY-MM-DDThh:mm:ss.sssZ ISO-8601 format. // All training input data is written into that directory. // // The Vertex AI environment variables representing Cloud Storage // data URIs are represented in the Cloud Storage wildcard // format to support sharded data. e.g.: "gs://.../training-*.jsonl" // // * AIP_DATA_FORMAT = "jsonl" for non-tabular data, "csv" for tabular data // * AIP_TRAINING_DATA_URI = // "gcs_destination/dataset---