google-apis-aiplatform_v1beta1 0.26.0 → 0.27.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -52,6 +52,50 @@ module Google
52
52
  @batch_path = 'batch'
53
53
  end
54
54
 
55
+ # Upload a file into a RagCorpus.
56
+ # @param [String] parent
57
+ # Required. The name of the RagCorpus resource into which to upload the file.
58
+ # Format: `projects/`project`/locations/`location`/ragCorpora/`rag_corpus``
59
+ # @param [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1UploadRagFileRequest] google_cloud_aiplatform_v1beta1_upload_rag_file_request_object
60
+ # @param [String] fields
61
+ # Selector specifying which fields to include in a partial response.
62
+ # @param [String] quota_user
63
+ # Available to use for quota purposes for server-side applications. Can be any
64
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
65
+ # @param [IO, String] upload_source
66
+ # IO stream or filename containing content to upload
67
+ # @param [String] content_type
68
+ # Content type of the uploaded content.
69
+ # @param [Google::Apis::RequestOptions] options
70
+ # Request-specific options
71
+ #
72
+ # @yield [result, err] Result & error if block supplied
73
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1UploadRagFileResponse] parsed result object
74
+ # @yieldparam err [StandardError] error object if request failed
75
+ #
76
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1UploadRagFileResponse]
77
+ #
78
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
79
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
80
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
81
+ def upload_medium(parent, google_cloud_aiplatform_v1beta1_upload_rag_file_request_object = nil, fields: nil, quota_user: nil, upload_source: nil, content_type: nil, options: nil, &block)
82
+ if upload_source.nil?
83
+ command = make_simple_command(:post, 'v1beta1/{+parent}/ragFiles:upload', options)
84
+ else
85
+ command = make_upload_command(:post, 'v1beta1/{+parent}/ragFiles:upload', options)
86
+ command.upload_source = upload_source
87
+ command.upload_content_type = content_type
88
+ end
89
+ command.request_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1UploadRagFileRequest::Representation
90
+ command.request_object = google_cloud_aiplatform_v1beta1_upload_rag_file_request_object
91
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1UploadRagFileResponse::Representation
92
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1UploadRagFileResponse
93
+ command.params['parent'] = parent unless parent.nil?
94
+ command.query['fields'] = fields unless fields.nil?
95
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
96
+ execute_or_queue_command(command, &block)
97
+ end
98
+
55
99
  # Gets a GenAI cache config.
56
100
  # @param [String] name
57
101
  # Required. Name of the cache config. Format: - `projects/`project`/cacheConfig`.
@@ -223,6 +267,41 @@ module Google
223
267
  execute_or_queue_command(command, &block)
224
268
  end
225
269
 
270
+ # Retrieves relevant contexts for a query.
271
+ # @param [String] parent
272
+ # Required. The resource name of the Location from which to retrieve RagContexts.
273
+ # The users must have permission to make a call in the project. Format: `
274
+ # projects/`project`/locations/`location``.
275
+ # @param [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RetrieveContextsRequest] google_cloud_aiplatform_v1beta1_retrieve_contexts_request_object
276
+ # @param [String] fields
277
+ # Selector specifying which fields to include in a partial response.
278
+ # @param [String] quota_user
279
+ # Available to use for quota purposes for server-side applications. Can be any
280
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
281
+ # @param [Google::Apis::RequestOptions] options
282
+ # Request-specific options
283
+ #
284
+ # @yield [result, err] Result & error if block supplied
285
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RetrieveContextsResponse] parsed result object
286
+ # @yieldparam err [StandardError] error object if request failed
287
+ #
288
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RetrieveContextsResponse]
289
+ #
290
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
291
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
292
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
293
+ def retrieve_project_location_contexts(parent, google_cloud_aiplatform_v1beta1_retrieve_contexts_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
294
+ command = make_simple_command(:post, 'v1beta1/{+parent}:retrieveContexts', options)
295
+ command.request_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RetrieveContextsRequest::Representation
296
+ command.request_object = google_cloud_aiplatform_v1beta1_retrieve_contexts_request_object
297
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RetrieveContextsResponse::Representation
298
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RetrieveContextsResponse
299
+ command.params['parent'] = parent unless parent.nil?
300
+ command.query['fields'] = fields unless fields.nil?
301
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
302
+ execute_or_queue_command(command, &block)
303
+ end
304
+
226
305
  # Starts asynchronous cancellation on a long-running operation. The server makes
227
306
  # a best effort to cancel the operation, but success is not guaranteed. If the
228
307
  # server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.
@@ -2700,6 +2779,43 @@ module Google
2700
2779
  execute_or_queue_command(command, &block)
2701
2780
  end
2702
2781
 
2782
+ # Updates a DatasetVersion.
2783
+ # @param [String] name
2784
+ # Output only. The resource name of the DatasetVersion.
2785
+ # @param [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1DatasetVersion] google_cloud_aiplatform_v1beta1_dataset_version_object
2786
+ # @param [String] update_mask
2787
+ # Required. The update mask applies to the resource. For the `FieldMask`
2788
+ # definition, see google.protobuf.FieldMask. Updatable fields: * `display_name`
2789
+ # @param [String] fields
2790
+ # Selector specifying which fields to include in a partial response.
2791
+ # @param [String] quota_user
2792
+ # Available to use for quota purposes for server-side applications. Can be any
2793
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2794
+ # @param [Google::Apis::RequestOptions] options
2795
+ # Request-specific options
2796
+ #
2797
+ # @yield [result, err] Result & error if block supplied
2798
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1DatasetVersion] parsed result object
2799
+ # @yieldparam err [StandardError] error object if request failed
2800
+ #
2801
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1DatasetVersion]
2802
+ #
2803
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2804
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2805
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2806
+ def patch_project_location_dataset_dataset_version(name, google_cloud_aiplatform_v1beta1_dataset_version_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
2807
+ command = make_simple_command(:patch, 'v1beta1/{+name}', options)
2808
+ command.request_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1DatasetVersion::Representation
2809
+ command.request_object = google_cloud_aiplatform_v1beta1_dataset_version_object
2810
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1DatasetVersion::Representation
2811
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1DatasetVersion
2812
+ command.params['name'] = name unless name.nil?
2813
+ command.query['updateMask'] = update_mask unless update_mask.nil?
2814
+ command.query['fields'] = fields unless fields.nil?
2815
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2816
+ execute_or_queue_command(command, &block)
2817
+ end
2818
+
2703
2819
  # Restores a dataset version.
2704
2820
  # @param [String] name
2705
2821
  # Required. The name of the DatasetVersion resource. Format: `projects/`project`/
@@ -17622,6 +17738,145 @@ module Google
17622
17738
  execute_or_queue_command(command, &block)
17623
17739
  end
17624
17740
 
17741
+ # Creates a RagCorpus.
17742
+ # @param [String] parent
17743
+ # Required. The resource name of the Location to create the RagCorpus in. Format:
17744
+ # `projects/`project`/locations/`location``
17745
+ # @param [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagCorpus] google_cloud_aiplatform_v1beta1_rag_corpus_object
17746
+ # @param [String] fields
17747
+ # Selector specifying which fields to include in a partial response.
17748
+ # @param [String] quota_user
17749
+ # Available to use for quota purposes for server-side applications. Can be any
17750
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
17751
+ # @param [Google::Apis::RequestOptions] options
17752
+ # Request-specific options
17753
+ #
17754
+ # @yield [result, err] Result & error if block supplied
17755
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation] parsed result object
17756
+ # @yieldparam err [StandardError] error object if request failed
17757
+ #
17758
+ # @return [Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation]
17759
+ #
17760
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
17761
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
17762
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
17763
+ def create_project_location_rag_corpora(parent, google_cloud_aiplatform_v1beta1_rag_corpus_object = nil, fields: nil, quota_user: nil, options: nil, &block)
17764
+ command = make_simple_command(:post, 'v1beta1/{+parent}/ragCorpora', options)
17765
+ command.request_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagCorpus::Representation
17766
+ command.request_object = google_cloud_aiplatform_v1beta1_rag_corpus_object
17767
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation::Representation
17768
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation
17769
+ command.params['parent'] = parent unless parent.nil?
17770
+ command.query['fields'] = fields unless fields.nil?
17771
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
17772
+ execute_or_queue_command(command, &block)
17773
+ end
17774
+
17775
+ # Deletes a RagCorpus.
17776
+ # @param [String] name
17777
+ # Required. The name of the RagCorpus resource to be deleted. Format: `projects/`
17778
+ # project`/locations/`location`/ragCorpora/`rag_corpus``
17779
+ # @param [Boolean] force
17780
+ # Optional. If set to true, any RagFiles in this RagCorpus will also be deleted.
17781
+ # Otherwise, the request will only work if the RagCorpus has no RagFiles.
17782
+ # @param [String] fields
17783
+ # Selector specifying which fields to include in a partial response.
17784
+ # @param [String] quota_user
17785
+ # Available to use for quota purposes for server-side applications. Can be any
17786
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
17787
+ # @param [Google::Apis::RequestOptions] options
17788
+ # Request-specific options
17789
+ #
17790
+ # @yield [result, err] Result & error if block supplied
17791
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation] parsed result object
17792
+ # @yieldparam err [StandardError] error object if request failed
17793
+ #
17794
+ # @return [Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation]
17795
+ #
17796
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
17797
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
17798
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
17799
+ def delete_project_location_rag_corpora(name, force: nil, fields: nil, quota_user: nil, options: nil, &block)
17800
+ command = make_simple_command(:delete, 'v1beta1/{+name}', options)
17801
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation::Representation
17802
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation
17803
+ command.params['name'] = name unless name.nil?
17804
+ command.query['force'] = force unless force.nil?
17805
+ command.query['fields'] = fields unless fields.nil?
17806
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
17807
+ execute_or_queue_command(command, &block)
17808
+ end
17809
+
17810
+ # Gets a RagCorpus.
17811
+ # @param [String] name
17812
+ # Required. The name of the RagCorpus resource. Format: `projects/`project`/
17813
+ # locations/`location`/ragCorpora/`rag_corpus``
17814
+ # @param [String] fields
17815
+ # Selector specifying which fields to include in a partial response.
17816
+ # @param [String] quota_user
17817
+ # Available to use for quota purposes for server-side applications. Can be any
17818
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
17819
+ # @param [Google::Apis::RequestOptions] options
17820
+ # Request-specific options
17821
+ #
17822
+ # @yield [result, err] Result & error if block supplied
17823
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagCorpus] parsed result object
17824
+ # @yieldparam err [StandardError] error object if request failed
17825
+ #
17826
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagCorpus]
17827
+ #
17828
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
17829
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
17830
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
17831
+ def get_project_location_rag_corpora(name, fields: nil, quota_user: nil, options: nil, &block)
17832
+ command = make_simple_command(:get, 'v1beta1/{+name}', options)
17833
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagCorpus::Representation
17834
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagCorpus
17835
+ command.params['name'] = name unless name.nil?
17836
+ command.query['fields'] = fields unless fields.nil?
17837
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
17838
+ execute_or_queue_command(command, &block)
17839
+ end
17840
+
17841
+ # Lists RagCorpora in a Location.
17842
+ # @param [String] parent
17843
+ # Required. The resource name of the Location from which to list the RagCorpora.
17844
+ # Format: `projects/`project`/locations/`location``
17845
+ # @param [Fixnum] page_size
17846
+ # Optional. The standard list page size.
17847
+ # @param [String] page_token
17848
+ # Optional. The standard list page token. Typically obtained via
17849
+ # ListRagCorporaResponse.next_page_token of the previous VertexRagDataService.
17850
+ # ListRagCorpora call.
17851
+ # @param [String] fields
17852
+ # Selector specifying which fields to include in a partial response.
17853
+ # @param [String] quota_user
17854
+ # Available to use for quota purposes for server-side applications. Can be any
17855
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
17856
+ # @param [Google::Apis::RequestOptions] options
17857
+ # Request-specific options
17858
+ #
17859
+ # @yield [result, err] Result & error if block supplied
17860
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListRagCorporaResponse] parsed result object
17861
+ # @yieldparam err [StandardError] error object if request failed
17862
+ #
17863
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListRagCorporaResponse]
17864
+ #
17865
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
17866
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
17867
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
17868
+ def list_project_location_rag_corporas(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
17869
+ command = make_simple_command(:get, 'v1beta1/{+parent}/ragCorpora', options)
17870
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListRagCorporaResponse::Representation
17871
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListRagCorporaResponse
17872
+ command.params['parent'] = parent unless parent.nil?
17873
+ command.query['pageSize'] = page_size unless page_size.nil?
17874
+ command.query['pageToken'] = page_token unless page_token.nil?
17875
+ command.query['fields'] = fields unless fields.nil?
17876
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
17877
+ execute_or_queue_command(command, &block)
17878
+ end
17879
+
17625
17880
  # Starts asynchronous cancellation on a long-running operation. The server makes
17626
17881
  # a best effort to cancel the operation, but success is not guaranteed. If the
17627
17882
  # server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.
@@ -17805,6 +18060,141 @@ module Google
17805
18060
  execute_or_queue_command(command, &block)
17806
18061
  end
17807
18062
 
18063
+ # Deletes a RagFile.
18064
+ # @param [String] name
18065
+ # Required. The name of the RagFile resource to be deleted. Format: `projects/`
18066
+ # project`/locations/`location`/ragCorpora/`rag_corpus`/ragFiles/`rag_file``
18067
+ # @param [String] fields
18068
+ # Selector specifying which fields to include in a partial response.
18069
+ # @param [String] quota_user
18070
+ # Available to use for quota purposes for server-side applications. Can be any
18071
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
18072
+ # @param [Google::Apis::RequestOptions] options
18073
+ # Request-specific options
18074
+ #
18075
+ # @yield [result, err] Result & error if block supplied
18076
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation] parsed result object
18077
+ # @yieldparam err [StandardError] error object if request failed
18078
+ #
18079
+ # @return [Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation]
18080
+ #
18081
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
18082
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
18083
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
18084
+ def delete_project_location_rag_corpora_rag_file(name, fields: nil, quota_user: nil, options: nil, &block)
18085
+ command = make_simple_command(:delete, 'v1beta1/{+name}', options)
18086
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation::Representation
18087
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation
18088
+ command.params['name'] = name unless name.nil?
18089
+ command.query['fields'] = fields unless fields.nil?
18090
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
18091
+ execute_or_queue_command(command, &block)
18092
+ end
18093
+
18094
+ # Gets a RagFile.
18095
+ # @param [String] name
18096
+ # Required. The name of the RagFile resource. Format: `projects/`project`/
18097
+ # locations/`location`/ragCorpora/`rag_corpus`/ragFiles/`rag_file``
18098
+ # @param [String] fields
18099
+ # Selector specifying which fields to include in a partial response.
18100
+ # @param [String] quota_user
18101
+ # Available to use for quota purposes for server-side applications. Can be any
18102
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
18103
+ # @param [Google::Apis::RequestOptions] options
18104
+ # Request-specific options
18105
+ #
18106
+ # @yield [result, err] Result & error if block supplied
18107
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagFile] parsed result object
18108
+ # @yieldparam err [StandardError] error object if request failed
18109
+ #
18110
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagFile]
18111
+ #
18112
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
18113
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
18114
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
18115
+ def get_project_location_rag_corpora_rag_file(name, fields: nil, quota_user: nil, options: nil, &block)
18116
+ command = make_simple_command(:get, 'v1beta1/{+name}', options)
18117
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagFile::Representation
18118
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1RagFile
18119
+ command.params['name'] = name unless name.nil?
18120
+ command.query['fields'] = fields unless fields.nil?
18121
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
18122
+ execute_or_queue_command(command, &block)
18123
+ end
18124
+
18125
+ # Import files from Google Cloud Storage or Google Drive into a RagCorpus.
18126
+ # @param [String] parent
18127
+ # Required. The name of the RagCorpus resource into which to import files.
18128
+ # Format: `projects/`project`/locations/`location`/ragCorpora/`rag_corpus``
18129
+ # @param [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ImportRagFilesRequest] google_cloud_aiplatform_v1beta1_import_rag_files_request_object
18130
+ # @param [String] fields
18131
+ # Selector specifying which fields to include in a partial response.
18132
+ # @param [String] quota_user
18133
+ # Available to use for quota purposes for server-side applications. Can be any
18134
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
18135
+ # @param [Google::Apis::RequestOptions] options
18136
+ # Request-specific options
18137
+ #
18138
+ # @yield [result, err] Result & error if block supplied
18139
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation] parsed result object
18140
+ # @yieldparam err [StandardError] error object if request failed
18141
+ #
18142
+ # @return [Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation]
18143
+ #
18144
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
18145
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
18146
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
18147
+ def import_project_location_rag_corpora_rag_file(parent, google_cloud_aiplatform_v1beta1_import_rag_files_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
18148
+ command = make_simple_command(:post, 'v1beta1/{+parent}/ragFiles:import', options)
18149
+ command.request_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ImportRagFilesRequest::Representation
18150
+ command.request_object = google_cloud_aiplatform_v1beta1_import_rag_files_request_object
18151
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation::Representation
18152
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleLongrunningOperation
18153
+ command.params['parent'] = parent unless parent.nil?
18154
+ command.query['fields'] = fields unless fields.nil?
18155
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
18156
+ execute_or_queue_command(command, &block)
18157
+ end
18158
+
18159
+ # Lists RagFiles in a RagCorpus.
18160
+ # @param [String] parent
18161
+ # Required. The resource name of the RagCorpus from which to list the RagFiles.
18162
+ # Format: `projects/`project`/locations/`location`/ragCorpora/`rag_corpus``
18163
+ # @param [Fixnum] page_size
18164
+ # Optional. The standard list page size.
18165
+ # @param [String] page_token
18166
+ # Optional. The standard list page token. Typically obtained via
18167
+ # ListRagFilesResponse.next_page_token of the previous VertexRagDataService.
18168
+ # ListRagFiles call.
18169
+ # @param [String] fields
18170
+ # Selector specifying which fields to include in a partial response.
18171
+ # @param [String] quota_user
18172
+ # Available to use for quota purposes for server-side applications. Can be any
18173
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
18174
+ # @param [Google::Apis::RequestOptions] options
18175
+ # Request-specific options
18176
+ #
18177
+ # @yield [result, err] Result & error if block supplied
18178
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListRagFilesResponse] parsed result object
18179
+ # @yieldparam err [StandardError] error object if request failed
18180
+ #
18181
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListRagFilesResponse]
18182
+ #
18183
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
18184
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
18185
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
18186
+ def list_project_location_rag_corpora_rag_files(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
18187
+ command = make_simple_command(:get, 'v1beta1/{+parent}/ragFiles', options)
18188
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListRagFilesResponse::Representation
18189
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListRagFilesResponse
18190
+ command.params['parent'] = parent unless parent.nil?
18191
+ command.query['pageSize'] = page_size unless page_size.nil?
18192
+ command.query['pageToken'] = page_token unless page_token.nil?
18193
+ command.query['fields'] = fields unless fields.nil?
18194
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
18195
+ execute_or_queue_command(command, &block)
18196
+ end
18197
+
17808
18198
  # Starts asynchronous cancellation on a long-running operation. The server makes
17809
18199
  # a best effort to cancel the operation, but success is not guaranteed. If the
17810
18200
  # server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.
@@ -22399,6 +22789,154 @@ module Google
22399
22789
  execute_or_queue_command(command, &block)
22400
22790
  end
22401
22791
 
22792
+ # Cancels a TuningJob. Starts asynchronous cancellation on the TuningJob. The
22793
+ # server makes a best effort to cancel the job, but success is not guaranteed.
22794
+ # Clients can use GenAiTuningService.GetTuningJob or other methods to check
22795
+ # whether the cancellation succeeded or whether the job completed despite
22796
+ # cancellation. On successful cancellation, the TuningJob is not deleted;
22797
+ # instead it becomes a job with a TuningJob.error value with a google.rpc.Status.
22798
+ # code of 1, corresponding to `Code.CANCELLED`, and TuningJob.state is set to `
22799
+ # CANCELLED`.
22800
+ # @param [String] name
22801
+ # Required. The name of the TuningJob to cancel. Format: `projects/`project`/
22802
+ # locations/`location`/tuningJobs/`tuning_job``
22803
+ # @param [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1CancelTuningJobRequest] google_cloud_aiplatform_v1beta1_cancel_tuning_job_request_object
22804
+ # @param [String] fields
22805
+ # Selector specifying which fields to include in a partial response.
22806
+ # @param [String] quota_user
22807
+ # Available to use for quota purposes for server-side applications. Can be any
22808
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
22809
+ # @param [Google::Apis::RequestOptions] options
22810
+ # Request-specific options
22811
+ #
22812
+ # @yield [result, err] Result & error if block supplied
22813
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleProtobufEmpty] parsed result object
22814
+ # @yieldparam err [StandardError] error object if request failed
22815
+ #
22816
+ # @return [Google::Apis::AiplatformV1beta1::GoogleProtobufEmpty]
22817
+ #
22818
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
22819
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
22820
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
22821
+ def cancel_project_location_tuning_job(name, google_cloud_aiplatform_v1beta1_cancel_tuning_job_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
22822
+ command = make_simple_command(:post, 'v1beta1/{+name}:cancel', options)
22823
+ command.request_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1CancelTuningJobRequest::Representation
22824
+ command.request_object = google_cloud_aiplatform_v1beta1_cancel_tuning_job_request_object
22825
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleProtobufEmpty::Representation
22826
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleProtobufEmpty
22827
+ command.params['name'] = name unless name.nil?
22828
+ command.query['fields'] = fields unless fields.nil?
22829
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
22830
+ execute_or_queue_command(command, &block)
22831
+ end
22832
+
22833
+ # Creates a TuningJob. A created TuningJob right away will be attempted to be
22834
+ # run.
22835
+ # @param [String] parent
22836
+ # Required. The resource name of the Location to create the TuningJob in. Format:
22837
+ # `projects/`project`/locations/`location``
22838
+ # @param [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob] google_cloud_aiplatform_v1beta1_tuning_job_object
22839
+ # @param [String] fields
22840
+ # Selector specifying which fields to include in a partial response.
22841
+ # @param [String] quota_user
22842
+ # Available to use for quota purposes for server-side applications. Can be any
22843
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
22844
+ # @param [Google::Apis::RequestOptions] options
22845
+ # Request-specific options
22846
+ #
22847
+ # @yield [result, err] Result & error if block supplied
22848
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob] parsed result object
22849
+ # @yieldparam err [StandardError] error object if request failed
22850
+ #
22851
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob]
22852
+ #
22853
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
22854
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
22855
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
22856
+ def create_project_location_tuning_job(parent, google_cloud_aiplatform_v1beta1_tuning_job_object = nil, fields: nil, quota_user: nil, options: nil, &block)
22857
+ command = make_simple_command(:post, 'v1beta1/{+parent}/tuningJobs', options)
22858
+ command.request_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob::Representation
22859
+ command.request_object = google_cloud_aiplatform_v1beta1_tuning_job_object
22860
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob::Representation
22861
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob
22862
+ command.params['parent'] = parent unless parent.nil?
22863
+ command.query['fields'] = fields unless fields.nil?
22864
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
22865
+ execute_or_queue_command(command, &block)
22866
+ end
22867
+
22868
+ # Gets a TuningJob.
22869
+ # @param [String] name
22870
+ # Required. The name of the TuningJob resource. Format: `projects/`project`/
22871
+ # locations/`location`/tuningJobs/`tuning_job``
22872
+ # @param [String] fields
22873
+ # Selector specifying which fields to include in a partial response.
22874
+ # @param [String] quota_user
22875
+ # Available to use for quota purposes for server-side applications. Can be any
22876
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
22877
+ # @param [Google::Apis::RequestOptions] options
22878
+ # Request-specific options
22879
+ #
22880
+ # @yield [result, err] Result & error if block supplied
22881
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob] parsed result object
22882
+ # @yieldparam err [StandardError] error object if request failed
22883
+ #
22884
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob]
22885
+ #
22886
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
22887
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
22888
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
22889
+ def get_project_location_tuning_job(name, fields: nil, quota_user: nil, options: nil, &block)
22890
+ command = make_simple_command(:get, 'v1beta1/{+name}', options)
22891
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob::Representation
22892
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1TuningJob
22893
+ command.params['name'] = name unless name.nil?
22894
+ command.query['fields'] = fields unless fields.nil?
22895
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
22896
+ execute_or_queue_command(command, &block)
22897
+ end
22898
+
22899
+ # Lists TuningJobs in a Location.
22900
+ # @param [String] parent
22901
+ # Required. The resource name of the Location to list the TuningJobs from.
22902
+ # Format: `projects/`project`/locations/`location``
22903
+ # @param [String] filter
22904
+ # Optional. The standard list filter.
22905
+ # @param [Fixnum] page_size
22906
+ # Optional. The standard list page size.
22907
+ # @param [String] page_token
22908
+ # Optional. The standard list page token. Typically obtained via ListTuningJob.
22909
+ # next_page_token of the previous GenAiTuningService.ListTuningJob][] call.
22910
+ # @param [String] fields
22911
+ # Selector specifying which fields to include in a partial response.
22912
+ # @param [String] quota_user
22913
+ # Available to use for quota purposes for server-side applications. Can be any
22914
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
22915
+ # @param [Google::Apis::RequestOptions] options
22916
+ # Request-specific options
22917
+ #
22918
+ # @yield [result, err] Result & error if block supplied
22919
+ # @yieldparam result [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListTuningJobsResponse] parsed result object
22920
+ # @yieldparam err [StandardError] error object if request failed
22921
+ #
22922
+ # @return [Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListTuningJobsResponse]
22923
+ #
22924
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
22925
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
22926
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
22927
+ def list_project_location_tuning_jobs(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
22928
+ command = make_simple_command(:get, 'v1beta1/{+parent}/tuningJobs', options)
22929
+ command.response_representation = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListTuningJobsResponse::Representation
22930
+ command.response_class = Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1ListTuningJobsResponse
22931
+ command.params['parent'] = parent unless parent.nil?
22932
+ command.query['filter'] = filter unless filter.nil?
22933
+ command.query['pageSize'] = page_size unless page_size.nil?
22934
+ command.query['pageToken'] = page_token unless page_token.nil?
22935
+ command.query['fields'] = fields unless fields.nil?
22936
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
22937
+ execute_or_queue_command(command, &block)
22938
+ end
22939
+
22402
22940
  # Gets a Model Garden publisher model.
22403
22941
  # @param [String] name
22404
22942
  # Required. The name of the PublisherModel resource. Format: `publishers/`
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-apis-aiplatform_v1beta1
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.26.0
4
+ version: 0.27.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-05-05 00:00:00.000000000 Z
11
+ date: 2024-05-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-apis-core
@@ -58,7 +58,7 @@ licenses:
58
58
  metadata:
59
59
  bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
60
60
  changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-aiplatform_v1beta1/CHANGELOG.md
61
- documentation_uri: https://googleapis.dev/ruby/google-apis-aiplatform_v1beta1/v0.26.0
61
+ documentation_uri: https://googleapis.dev/ruby/google-apis-aiplatform_v1beta1/v0.27.0
62
62
  source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-aiplatform_v1beta1
63
63
  post_install_message:
64
64
  rdoc_options: []