From 401ef21a843cd2dc126712165e812956a0c93345 Mon Sep 17 00:00:00 2001
From: Yoshi Automation Method Details
"frequencyPenalty": 3.14, # Optional. Frequency penalties.
"maxOutputTokens": 42, # Optional. The maximum number of output tokens to generate per message.
"presencePenalty": 3.14, # Optional. Positive penalties.
+ "responseMimeType": "A String", # Optional. Output response mimetype of the generated candidate text. Supported mimetype: `text/plain`: (default) Text output. `application/json`: JSON response in the candidates. The model needs to be prompted to output the appropriate response type, otherwise the behavior is undefined. This is a preview feature.
"stopSequences": [ # Optional. Stop sequences.
"A String",
],
@@ -1269,9 +1270,6 @@ Method Details
},
},
],
- "retrievalQueries": [ # Optional. Queries executed by the retrieval tools.
- "A String",
- ],
"webSearchQueries": [ # Optional. Web search queries for the following-up web search.
"A String",
],
@@ -2589,6 +2587,7 @@ Method Details
"frequencyPenalty": 3.14, # Optional. Frequency penalties.
"maxOutputTokens": 42, # Optional. The maximum number of output tokens to generate per message.
"presencePenalty": 3.14, # Optional. Positive penalties.
+ "responseMimeType": "A String", # Optional. Output response mimetype of the generated candidate text. Supported mimetype: `text/plain`: (default) Text output. `application/json`: JSON response in the candidates. The model needs to be prompted to output the appropriate response type, otherwise the behavior is undefined. This is a preview feature.
"stopSequences": [ # Optional. Stop sequences.
"A String",
],
@@ -2760,9 +2759,6 @@ Method Details
},
},
],
- "retrievalQueries": [ # Optional. Queries executed by the retrieval tools.
- "A String",
- ],
"webSearchQueries": [ # Optional. Web search queries for the following-up web search.
"A String",
],
diff --git a/docs/dyn/aiplatform_v1.projects.locations.indexEndpoints.html b/docs/dyn/aiplatform_v1.projects.locations.indexEndpoints.html
index 44d2d5368b8..9c9df7d2c88 100644
--- a/docs/dyn/aiplatform_v1.projects.locations.indexEndpoints.html
+++ b/docs/dyn/aiplatform_v1.projects.locations.indexEndpoints.html
@@ -377,7 +377,7 @@ Method Details
body: object, The request body.
The object takes the form of:
-{ # LINT.IfChange The request message for MatchService.FindNeighbors.
+{ # The request message for MatchService.FindNeighbors.
"deployedIndexId": "A String", # The ID of the DeployedIndex that will serve the request. This request is sent to a specific IndexEndpoint, as per the IndexEndpoint.network. That IndexEndpoint also has IndexEndpoint.deployed_indexes, and each such index has a DeployedIndex.id field. The value of the field below must equal one of the DeployedIndex.id fields of the IndexEndpoint that is being called for this request.
"queries": [ # The list of queries.
{ # A query to find a number of the nearest neighbors (most similar vectors) of a vector.
diff --git a/docs/dyn/aiplatform_v1.projects.locations.persistentResources.html b/docs/dyn/aiplatform_v1.projects.locations.persistentResources.html
index 154cd5e1ccb..6af3e0a394d 100644
--- a/docs/dyn/aiplatform_v1.projects.locations.persistentResources.html
+++ b/docs/dyn/aiplatform_v1.projects.locations.persistentResources.html
@@ -163,25 +163,13 @@ Method Details
},
],
"resourceRuntime": { # Persistent Cluster runtime information as output # Output only. Runtime information of the Persistent Resource.
- "accessUris": { # Output only. URIs for user to connect to the Cluster. Example: { "RAY_HEAD_NODE_INTERNAL_IP": "head-node-IP:10001" "RAY_DASHBOARD_URI": "ray-dashboard-address:8888" }
- "a_key": "A String",
- },
- "notebookRuntimeTemplate": "A String", # Output only. The resource name of NotebookRuntimeTemplate for the RoV Persistent Cluster The NotebokRuntimeTemplate is created in the same VPC (if set), and with the same Ray and Python version as the Persistent Cluster. Example: "projects/1000/locations/us-central1/notebookRuntimeTemplates/abc123"
},
"resourceRuntimeSpec": { # Configuration for the runtime on a PersistentResource instance, including but not limited to: * Service accounts used to run the workloads. * Whether to make it a dedicated Ray Cluster. # Optional. Persistent Resource runtime spec. For example, used for Ray cluster configuration.
"raySpec": { # Configuration information for the Ray cluster. For experimental launch, Ray cluster creation and Persistent cluster creation are 1:1 mapping: We will provision all the nodes within the Persistent cluster as Ray nodes. # Optional. Ray cluster configuration. Required when creating a dedicated RayCluster on the PersistentResource.
- "headNodeResourcePoolId": "A String", # Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field isn't set.
- "imageUri": "A String", # Optional. Default image for user to choose a preferred ML framework (for example, TensorFlow or Pytorch) by choosing from [Vertex prebuilt images](https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image. Otherwise, use the {@code resource_pool_images} field.
- "rayMetricSpec": { # Configuration for the Ray metrics. # Optional. Ray metrics configurations.
- "disabled": True or False, # Optional. Flag to disable the Ray metrics collection.
- },
- "resourcePoolImages": { # Optional. Required if image_uri isn't set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
- "a_key": "A String",
- },
},
"serviceAccountSpec": { # Configuration for the use of custom service account to run the workloads. # Optional. Configure the use of workload identity on the PersistentResource
"enableCustomServiceAccount": True or False, # Required. If true, custom user-managed service account is enforced to run any workloads (for example, Vertex Jobs) on the resource. Otherwise, uses the [Vertex AI Custom Code Service Agent](https://cloud.google.com/vertex-ai/docs/general/access-control#service-agents).
- "serviceAccount": "A String", # Optional. Default service account that this PersistentResource's workloads run as. The workloads include: * Any runtime specified via `ResourceRuntimeSpec` on creation time, for example, Ray. * Jobs submitted to PersistentResource, if no other service account specified in the job specs. Only works when custom service account is enabled and users have the `iam.serviceAccounts.actAs` permission on this service account. Required if any containers are specified in `ResourceRuntimeSpec`.
+ "serviceAccount": "A String", # Optional. Required when all below conditions are met * `enable_custom_service_account` is true; * any runtime is specified via `ResourceRuntimeSpec` on creation time, for example, Ray The users must have `iam.serviceAccounts.actAs` permission on this service account and then the specified runtime containers will run as it. Do not set this field if you want to submit jobs using custom service account to this PersistentResource after creation, but only specify the `service_account` inside the job.
},
},
"startTime": "A String", # Output only. Time when the PersistentResource for the first time entered the `RUNNING` state.
@@ -313,25 +301,13 @@ Method Details
},
],
"resourceRuntime": { # Persistent Cluster runtime information as output # Output only. Runtime information of the Persistent Resource.
- "accessUris": { # Output only. URIs for user to connect to the Cluster. Example: { "RAY_HEAD_NODE_INTERNAL_IP": "head-node-IP:10001" "RAY_DASHBOARD_URI": "ray-dashboard-address:8888" }
- "a_key": "A String",
- },
- "notebookRuntimeTemplate": "A String", # Output only. The resource name of NotebookRuntimeTemplate for the RoV Persistent Cluster The NotebokRuntimeTemplate is created in the same VPC (if set), and with the same Ray and Python version as the Persistent Cluster. Example: "projects/1000/locations/us-central1/notebookRuntimeTemplates/abc123"
},
"resourceRuntimeSpec": { # Configuration for the runtime on a PersistentResource instance, including but not limited to: * Service accounts used to run the workloads. * Whether to make it a dedicated Ray Cluster. # Optional. Persistent Resource runtime spec. For example, used for Ray cluster configuration.
"raySpec": { # Configuration information for the Ray cluster. For experimental launch, Ray cluster creation and Persistent cluster creation are 1:1 mapping: We will provision all the nodes within the Persistent cluster as Ray nodes. # Optional. Ray cluster configuration. Required when creating a dedicated RayCluster on the PersistentResource.
- "headNodeResourcePoolId": "A String", # Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field isn't set.
- "imageUri": "A String", # Optional. Default image for user to choose a preferred ML framework (for example, TensorFlow or Pytorch) by choosing from [Vertex prebuilt images](https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image. Otherwise, use the {@code resource_pool_images} field.
- "rayMetricSpec": { # Configuration for the Ray metrics. # Optional. Ray metrics configurations.
- "disabled": True or False, # Optional. Flag to disable the Ray metrics collection.
- },
- "resourcePoolImages": { # Optional. Required if image_uri isn't set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
- "a_key": "A String",
- },
},
"serviceAccountSpec": { # Configuration for the use of custom service account to run the workloads. # Optional. Configure the use of workload identity on the PersistentResource
"enableCustomServiceAccount": True or False, # Required. If true, custom user-managed service account is enforced to run any workloads (for example, Vertex Jobs) on the resource. Otherwise, uses the [Vertex AI Custom Code Service Agent](https://cloud.google.com/vertex-ai/docs/general/access-control#service-agents).
- "serviceAccount": "A String", # Optional. Default service account that this PersistentResource's workloads run as. The workloads include: * Any runtime specified via `ResourceRuntimeSpec` on creation time, for example, Ray. * Jobs submitted to PersistentResource, if no other service account specified in the job specs. Only works when custom service account is enabled and users have the `iam.serviceAccounts.actAs` permission on this service account. Required if any containers are specified in `ResourceRuntimeSpec`.
+ "serviceAccount": "A String", # Optional. Required when all below conditions are met * `enable_custom_service_account` is true; * any runtime is specified via `ResourceRuntimeSpec` on creation time, for example, Ray The users must have `iam.serviceAccounts.actAs` permission on this service account and then the specified runtime containers will run as it. Do not set this field if you want to submit jobs using custom service account to this PersistentResource after creation, but only specify the `service_account` inside the job.
},
},
"startTime": "A String", # Output only. Time when the PersistentResource for the first time entered the `RUNNING` state.
@@ -404,25 +380,13 @@ Method Details
},
],
"resourceRuntime": { # Persistent Cluster runtime information as output # Output only. Runtime information of the Persistent Resource.
- "accessUris": { # Output only. URIs for user to connect to the Cluster. Example: { "RAY_HEAD_NODE_INTERNAL_IP": "head-node-IP:10001" "RAY_DASHBOARD_URI": "ray-dashboard-address:8888" }
- "a_key": "A String",
- },
- "notebookRuntimeTemplate": "A String", # Output only. The resource name of NotebookRuntimeTemplate for the RoV Persistent Cluster The NotebokRuntimeTemplate is created in the same VPC (if set), and with the same Ray and Python version as the Persistent Cluster. Example: "projects/1000/locations/us-central1/notebookRuntimeTemplates/abc123"
},
"resourceRuntimeSpec": { # Configuration for the runtime on a PersistentResource instance, including but not limited to: * Service accounts used to run the workloads. * Whether to make it a dedicated Ray Cluster. # Optional. Persistent Resource runtime spec. For example, used for Ray cluster configuration.
"raySpec": { # Configuration information for the Ray cluster. For experimental launch, Ray cluster creation and Persistent cluster creation are 1:1 mapping: We will provision all the nodes within the Persistent cluster as Ray nodes. # Optional. Ray cluster configuration. Required when creating a dedicated RayCluster on the PersistentResource.
- "headNodeResourcePoolId": "A String", # Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field isn't set.
- "imageUri": "A String", # Optional. Default image for user to choose a preferred ML framework (for example, TensorFlow or Pytorch) by choosing from [Vertex prebuilt images](https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image. Otherwise, use the {@code resource_pool_images} field.
- "rayMetricSpec": { # Configuration for the Ray metrics. # Optional. Ray metrics configurations.
- "disabled": True or False, # Optional. Flag to disable the Ray metrics collection.
- },
- "resourcePoolImages": { # Optional. Required if image_uri isn't set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
- "a_key": "A String",
- },
},
"serviceAccountSpec": { # Configuration for the use of custom service account to run the workloads. # Optional. Configure the use of workload identity on the PersistentResource
"enableCustomServiceAccount": True or False, # Required. If true, custom user-managed service account is enforced to run any workloads (for example, Vertex Jobs) on the resource. Otherwise, uses the [Vertex AI Custom Code Service Agent](https://cloud.google.com/vertex-ai/docs/general/access-control#service-agents).
- "serviceAccount": "A String", # Optional. Default service account that this PersistentResource's workloads run as. The workloads include: * Any runtime specified via `ResourceRuntimeSpec` on creation time, for example, Ray. * Jobs submitted to PersistentResource, if no other service account specified in the job specs. Only works when custom service account is enabled and users have the `iam.serviceAccounts.actAs` permission on this service account. Required if any containers are specified in `ResourceRuntimeSpec`.
+ "serviceAccount": "A String", # Optional. Required when all below conditions are met * `enable_custom_service_account` is true; * any runtime is specified via `ResourceRuntimeSpec` on creation time, for example, Ray The users must have `iam.serviceAccounts.actAs` permission on this service account and then the specified runtime containers will run as it. Do not set this field if you want to submit jobs using custom service account to this PersistentResource after creation, but only specify the `service_account` inside the job.
},
},
"startTime": "A String", # Output only. Time when the PersistentResource for the first time entered the `RUNNING` state.
@@ -501,25 +465,13 @@ Method Details
},
],
"resourceRuntime": { # Persistent Cluster runtime information as output # Output only. Runtime information of the Persistent Resource.
- "accessUris": { # Output only. URIs for user to connect to the Cluster. Example: { "RAY_HEAD_NODE_INTERNAL_IP": "head-node-IP:10001" "RAY_DASHBOARD_URI": "ray-dashboard-address:8888" }
- "a_key": "A String",
- },
- "notebookRuntimeTemplate": "A String", # Output only. The resource name of NotebookRuntimeTemplate for the RoV Persistent Cluster The NotebokRuntimeTemplate is created in the same VPC (if set), and with the same Ray and Python version as the Persistent Cluster. Example: "projects/1000/locations/us-central1/notebookRuntimeTemplates/abc123"
},
"resourceRuntimeSpec": { # Configuration for the runtime on a PersistentResource instance, including but not limited to: * Service accounts used to run the workloads. * Whether to make it a dedicated Ray Cluster. # Optional. Persistent Resource runtime spec. For example, used for Ray cluster configuration.
"raySpec": { # Configuration information for the Ray cluster. For experimental launch, Ray cluster creation and Persistent cluster creation are 1:1 mapping: We will provision all the nodes within the Persistent cluster as Ray nodes. # Optional. Ray cluster configuration. Required when creating a dedicated RayCluster on the PersistentResource.
- "headNodeResourcePoolId": "A String", # Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field isn't set.
- "imageUri": "A String", # Optional. Default image for user to choose a preferred ML framework (for example, TensorFlow or Pytorch) by choosing from [Vertex prebuilt images](https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image. Otherwise, use the {@code resource_pool_images} field.
- "rayMetricSpec": { # Configuration for the Ray metrics. # Optional. Ray metrics configurations.
- "disabled": True or False, # Optional. Flag to disable the Ray metrics collection.
- },
- "resourcePoolImages": { # Optional. Required if image_uri isn't set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { "ray_head_node_pool": "head image" "ray_worker_node_pool1": "worker image" "ray_worker_node_pool2": "another worker image" }
- "a_key": "A String",
- },
},
"serviceAccountSpec": { # Configuration for the use of custom service account to run the workloads. # Optional. Configure the use of workload identity on the PersistentResource
"enableCustomServiceAccount": True or False, # Required. If true, custom user-managed service account is enforced to run any workloads (for example, Vertex Jobs) on the resource. Otherwise, uses the [Vertex AI Custom Code Service Agent](https://cloud.google.com/vertex-ai/docs/general/access-control#service-agents).
- "serviceAccount": "A String", # Optional. Default service account that this PersistentResource's workloads run as. The workloads include: * Any runtime specified via `ResourceRuntimeSpec` on creation time, for example, Ray. * Jobs submitted to PersistentResource, if no other service account specified in the job specs. Only works when custom service account is enabled and users have the `iam.serviceAccounts.actAs` permission on this service account. Required if any containers are specified in `ResourceRuntimeSpec`.
+ "serviceAccount": "A String", # Optional. Required when all below conditions are met * `enable_custom_service_account` is true; * any runtime is specified via `ResourceRuntimeSpec` on creation time, for example, Ray The users must have `iam.serviceAccounts.actAs` permission on this service account and then the specified runtime containers will run as it. Do not set this field if you want to submit jobs using custom service account to this PersistentResource after creation, but only specify the `service_account` inside the job.
},
},
"startTime": "A String", # Output only. Time when the PersistentResource for the first time entered the `RUNNING` state.
diff --git a/docs/dyn/aiplatform_v1.projects.locations.publishers.models.html b/docs/dyn/aiplatform_v1.projects.locations.publishers.models.html
index fa69d5997a8..720ddbc3bb1 100644
--- a/docs/dyn/aiplatform_v1.projects.locations.publishers.models.html
+++ b/docs/dyn/aiplatform_v1.projects.locations.publishers.models.html
@@ -257,6 +257,7 @@ Method Details
"frequencyPenalty": 3.14, # Optional. Frequency penalties.
"maxOutputTokens": 42, # Optional. The maximum number of output tokens to generate per message.
"presencePenalty": 3.14, # Optional. Positive penalties.
+ "responseMimeType": "A String", # Optional. Output response mimetype of the generated candidate text. Supported mimetype: `text/plain`: (default) Text output. `application/json`: JSON response in the candidates. The model needs to be prompted to output the appropriate response type, otherwise the behavior is undefined. This is a preview feature.
"stopSequences": [ # Optional. Stop sequences.
"A String",
],
@@ -428,9 +429,6 @@ Method Details
},
},
],
- "retrievalQueries": [ # Optional. Queries executed by the retrieval tools.
- "A String",
- ],
"webSearchQueries": [ # Optional. Web search queries for the following-up web search.
"A String",
],
@@ -783,6 +781,7 @@ Method Details
"frequencyPenalty": 3.14, # Optional. Frequency penalties.
"maxOutputTokens": 42, # Optional. The maximum number of output tokens to generate per message.
"presencePenalty": 3.14, # Optional. Positive penalties.
+ "responseMimeType": "A String", # Optional. Output response mimetype of the generated candidate text. Supported mimetype: `text/plain`: (default) Text output. `application/json`: JSON response in the candidates. The model needs to be prompted to output the appropriate response type, otherwise the behavior is undefined. This is a preview feature.
"stopSequences": [ # Optional. Stop sequences.
"A String",
],
@@ -954,9 +953,6 @@ Method Details
},
},
],
- "retrievalQueries": [ # Optional. Queries executed by the retrieval tools.
- "A String",
- ],
"webSearchQueries": [ # Optional. Web search queries for the following-up web search.
"A String",
],
diff --git a/docs/dyn/aiplatform_v1.projects.locations.tuningJobs.html b/docs/dyn/aiplatform_v1.projects.locations.tuningJobs.html
index 481ce416f99..56c4db6bc38 100644
--- a/docs/dyn/aiplatform_v1.projects.locations.tuningJobs.html
+++ b/docs/dyn/aiplatform_v1.projects.locations.tuningJobs.html
@@ -79,13 +79,634 @@ Instance Methods
Returns the operations Resource.
+
+ cancel(name, body=None, x__xgafv=None)
Cancels a TuningJob. Starts asynchronous cancellation on the TuningJob. The server makes a best effort to cancel the job, but success is not guaranteed. Clients can use GenAiTuningService.GetTuningJob or other methods to check whether the cancellation succeeded or whether the job completed despite cancellation. On successful cancellation, the TuningJob is not deleted; instead it becomes a job with a TuningJob.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`, and TuningJob.state is set to `CANCELLED`.
Close httplib2 connections.
+
+ create(parent, body=None, x__xgafv=None)
Creates a TuningJob. A created TuningJob right away will be attempted to be run.
+ +Gets a TuningJob.
+
+ list(parent, filter=None, pageSize=None, pageToken=None, x__xgafv=None)
Lists TuningJobs in a Location.
+ +Retrieves the next page of results.
cancel(name, body=None, x__xgafv=None)
+ Cancels a TuningJob. Starts asynchronous cancellation on the TuningJob. The server makes a best effort to cancel the job, but success is not guaranteed. Clients can use GenAiTuningService.GetTuningJob or other methods to check whether the cancellation succeeded or whether the job completed despite cancellation. On successful cancellation, the TuningJob is not deleted; instead it becomes a job with a TuningJob.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`, and TuningJob.state is set to `CANCELLED`. + +Args: + name: string, Required. The name of the TuningJob to cancel. Format: `projects/{project}/locations/{location}/tuningJobs/{tuning_job}` (required) + body: object, The request body. + The object takes the form of: + +{ # Request message for GenAiTuningService.CancelTuningJob. +} + + x__xgafv: string, V1 error format. + Allowed values + 1 - v1 error format + 2 - v2 error format + +Returns: + An object of the form: + + { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } +}+
close()
Close httplib2 connections.
create(parent, body=None, x__xgafv=None)
+ Creates a TuningJob. A created TuningJob right away will be attempted to be run. + +Args: + parent: string, Required. The resource name of the Location to create the TuningJob in. Format: `projects/{project}/locations/{location}` (required) + body: object, The request body. + The object takes the form of: + +{ # Represents a TuningJob that runs with Google owned models. + "baseModel": "A String", # Model name for tuning, e.g., "gemini-1.0-pro-002". + "createTime": "A String", # Output only. Time when the TuningJob was created. + "description": "A String", # Optional. The description of the TuningJob. + "endTime": "A String", # Output only. Time when the TuningJob entered any of the following JobStates: `JOB_STATE_SUCCEEDED`, `JOB_STATE_FAILED`, `JOB_STATE_CANCELLED`, `JOB_STATE_EXPIRED`. + "error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # Output only. Only populated when job's state is `JOB_STATE_FAILED` or `JOB_STATE_CANCELLED`. + "code": 42, # The status code, which should be an enum value of google.rpc.Code. + "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. + { + "a_key": "", # Properties of the object. Contains field @type with type URL. + }, + ], + "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + }, + "experiment": "A String", # Output only. The Experiment associated with this TuningJob. + "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. + "a_key": "A String", + }, + "name": "A String", # Output only. Identifier. Resource name of a TuningJob. Format: `projects/{project}/locations/{location}/tuningJobs/{tuning_job}` + "startTime": "A String", # Output only. Time when the TuningJob for the first time entered the `JOB_STATE_RUNNING` state. + "state": "A String", # Output only. The detailed state of the job. + "supervisedTuningSpec": { # Tuning Spec for Supervised Tuning. # Tuning Spec for Supervised Fine Tuning. + "hyperParameters": { # Hyperparameters for SFT. # Optional. Hyperparameters for SFT. + "adapterSize": "A String", # Optional. Adapter size for tuning. + "epochCount": "A String", # Optional. Number of training epoches for this tuning job. + "learningRateMultiplier": 3.14, # Optional. Learning rate multiplier for tuning. + }, + "trainingDatasetUri": "A String", # Required. Cloud Storage path to file containing training dataset for tuning. + "validationDatasetUri": "A String", # Optional. Cloud Storage path to file containing validation dataset for tuning. + }, + "tunedModel": { # The Model Registry Model and Online Prediction Endpoint assiociated with this TuningJob. # Output only. The tuned model resources assiociated with this TuningJob. + "endpoint": "A String", # Output only. A resource name of an Endpoint. Format: `projects/{project}/locations/{location}/endpoints/{endpoint}`. + "model": "A String", # Output only. The resource name of the TunedModel. Format: `projects/{project}/locations/{location}/models/{model}`. + }, + "tunedModelDisplayName": "A String", # Optional. The display name of the TunedModel. The name can be up to 128 characters long and can consist of any UTF-8 characters. + "tuningDataStats": { # The tuning data statistic values for TuningJob. # Output only. The tuning data statistics associated with this TuningJob. + "supervisedTuningDataStats": { # Tuning data statistics for Supervised Tuning. # The SFT Tuning data stats. + "totalBillableCharacterCount": "A String", # Output only. Number of billable characters in the tuning dataset. + "totalTuningCharacterCount": "A String", # Output only. Number of tuning characters in the tuning dataset. + "tuningDatasetExampleCount": "A String", # Output only. Number of examples in the tuning dataset. + "tuningStepCount": "A String", # Output only. Number of tuning steps for this Tuning Job. + "userDatasetExamples": [ # Output only. Sample user messages in the training dataset uri. + { # The base structured datatype containing multi-part content of a message. A `Content` includes a `role` field designating the producer of the `Content` and a `parts` field containing multi-part data that contains the content of the message turn. + "parts": [ # Required. Ordered `Parts` that constitute a single message. Parts may have different IANA MIME types. + { # A datatype containing media that is part of a multi-part `Content` message. A `Part` consists of data which has an associated datatype. A `Part` can only contain one of the accepted types in `Part.data`. A `Part` must have a fixed IANA MIME type identifying the type and subtype of the media if `inline_data` or `file_data` field is filled with raw bytes. + "fileData": { # URI based data. # Optional. URI based data. + "fileUri": "A String", # Required. URI. + "mimeType": "A String", # Required. The IANA standard MIME type of the source data. + }, + "functionCall": { # A predicted [FunctionCall] returned from the model that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing the parameters and their values. # Optional. A predicted [FunctionCall] returned from the model that contains a string representing the [FunctionDeclaration.name] with the parameters and their values. + "args": { # Optional. Required. The function parameters and values in JSON object format. See [FunctionDeclaration.parameters] for parameter details. + "a_key": "", # Properties of the object. + }, + "name": "A String", # Required. The name of the function to call. Matches [FunctionDeclaration.name]. + }, + "functionResponse": { # The result output from a [FunctionCall] that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing any output from the function is used as context to the model. This should contain the result of a [FunctionCall] made based on model prediction. # Optional. The result output of a [FunctionCall] that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing any output from the function call. It is used as context to the model. + "name": "A String", # Required. The name of the function to call. Matches [FunctionDeclaration.name] and [FunctionCall.name]. + "response": { # Required. The function response in JSON object format. + "a_key": "", # Properties of the object. + }, + }, + "inlineData": { # Content blob. It's preferred to send as text directly rather than raw bytes. # Optional. Inlined bytes data. + "data": "A String", # Required. Raw bytes. + "mimeType": "A String", # Required. The IANA standard MIME type of the source data. + }, + "text": "A String", # Optional. Text part (can be code). + "videoMetadata": { # Metadata describes the input video content. # Optional. Video metadata. The metadata should only be specified while the video data is presented in inline_data or file_data. + "endOffset": "A String", # Optional. The end offset of the video. + "startOffset": "A String", # Optional. The start offset of the video. + }, + }, + ], + "role": "A String", # Optional. The producer of the content. Must be either 'user' or 'model'. Useful to set for multi-turn conversations, otherwise can be left blank or unset. + }, + ], + "userInputTokenDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the user input tokens. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + "userMessagePerExampleDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the messages per example. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + "userOutputTokenDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the user output tokens. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + }, + }, + "updateTime": "A String", # Output only. Time when the TuningJob was most recently updated. +} + + x__xgafv: string, V1 error format. + Allowed values + 1 - v1 error format + 2 - v2 error format + +Returns: + An object of the form: + + { # Represents a TuningJob that runs with Google owned models. + "baseModel": "A String", # Model name for tuning, e.g., "gemini-1.0-pro-002". + "createTime": "A String", # Output only. Time when the TuningJob was created. + "description": "A String", # Optional. The description of the TuningJob. + "endTime": "A String", # Output only. Time when the TuningJob entered any of the following JobStates: `JOB_STATE_SUCCEEDED`, `JOB_STATE_FAILED`, `JOB_STATE_CANCELLED`, `JOB_STATE_EXPIRED`. + "error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # Output only. Only populated when job's state is `JOB_STATE_FAILED` or `JOB_STATE_CANCELLED`. + "code": 42, # The status code, which should be an enum value of google.rpc.Code. + "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. + { + "a_key": "", # Properties of the object. Contains field @type with type URL. + }, + ], + "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + }, + "experiment": "A String", # Output only. The Experiment associated with this TuningJob. + "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. + "a_key": "A String", + }, + "name": "A String", # Output only. Identifier. Resource name of a TuningJob. Format: `projects/{project}/locations/{location}/tuningJobs/{tuning_job}` + "startTime": "A String", # Output only. Time when the TuningJob for the first time entered the `JOB_STATE_RUNNING` state. + "state": "A String", # Output only. The detailed state of the job. + "supervisedTuningSpec": { # Tuning Spec for Supervised Tuning. # Tuning Spec for Supervised Fine Tuning. + "hyperParameters": { # Hyperparameters for SFT. # Optional. Hyperparameters for SFT. + "adapterSize": "A String", # Optional. Adapter size for tuning. + "epochCount": "A String", # Optional. Number of training epoches for this tuning job. + "learningRateMultiplier": 3.14, # Optional. Learning rate multiplier for tuning. + }, + "trainingDatasetUri": "A String", # Required. Cloud Storage path to file containing training dataset for tuning. + "validationDatasetUri": "A String", # Optional. Cloud Storage path to file containing validation dataset for tuning. + }, + "tunedModel": { # The Model Registry Model and Online Prediction Endpoint assiociated with this TuningJob. # Output only. The tuned model resources assiociated with this TuningJob. + "endpoint": "A String", # Output only. A resource name of an Endpoint. Format: `projects/{project}/locations/{location}/endpoints/{endpoint}`. + "model": "A String", # Output only. The resource name of the TunedModel. Format: `projects/{project}/locations/{location}/models/{model}`. + }, + "tunedModelDisplayName": "A String", # Optional. The display name of the TunedModel. The name can be up to 128 characters long and can consist of any UTF-8 characters. + "tuningDataStats": { # The tuning data statistic values for TuningJob. # Output only. The tuning data statistics associated with this TuningJob. + "supervisedTuningDataStats": { # Tuning data statistics for Supervised Tuning. # The SFT Tuning data stats. + "totalBillableCharacterCount": "A String", # Output only. Number of billable characters in the tuning dataset. + "totalTuningCharacterCount": "A String", # Output only. Number of tuning characters in the tuning dataset. + "tuningDatasetExampleCount": "A String", # Output only. Number of examples in the tuning dataset. + "tuningStepCount": "A String", # Output only. Number of tuning steps for this Tuning Job. + "userDatasetExamples": [ # Output only. Sample user messages in the training dataset uri. + { # The base structured datatype containing multi-part content of a message. A `Content` includes a `role` field designating the producer of the `Content` and a `parts` field containing multi-part data that contains the content of the message turn. + "parts": [ # Required. Ordered `Parts` that constitute a single message. Parts may have different IANA MIME types. + { # A datatype containing media that is part of a multi-part `Content` message. A `Part` consists of data which has an associated datatype. A `Part` can only contain one of the accepted types in `Part.data`. A `Part` must have a fixed IANA MIME type identifying the type and subtype of the media if `inline_data` or `file_data` field is filled with raw bytes. + "fileData": { # URI based data. # Optional. URI based data. + "fileUri": "A String", # Required. URI. + "mimeType": "A String", # Required. The IANA standard MIME type of the source data. + }, + "functionCall": { # A predicted [FunctionCall] returned from the model that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing the parameters and their values. # Optional. A predicted [FunctionCall] returned from the model that contains a string representing the [FunctionDeclaration.name] with the parameters and their values. + "args": { # Optional. Required. The function parameters and values in JSON object format. See [FunctionDeclaration.parameters] for parameter details. + "a_key": "", # Properties of the object. + }, + "name": "A String", # Required. The name of the function to call. Matches [FunctionDeclaration.name]. + }, + "functionResponse": { # The result output from a [FunctionCall] that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing any output from the function is used as context to the model. This should contain the result of a [FunctionCall] made based on model prediction. # Optional. The result output of a [FunctionCall] that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing any output from the function call. It is used as context to the model. + "name": "A String", # Required. The name of the function to call. Matches [FunctionDeclaration.name] and [FunctionCall.name]. + "response": { # Required. The function response in JSON object format. + "a_key": "", # Properties of the object. + }, + }, + "inlineData": { # Content blob. It's preferred to send as text directly rather than raw bytes. # Optional. Inlined bytes data. + "data": "A String", # Required. Raw bytes. + "mimeType": "A String", # Required. The IANA standard MIME type of the source data. + }, + "text": "A String", # Optional. Text part (can be code). + "videoMetadata": { # Metadata describes the input video content. # Optional. Video metadata. The metadata should only be specified while the video data is presented in inline_data or file_data. + "endOffset": "A String", # Optional. The end offset of the video. + "startOffset": "A String", # Optional. The start offset of the video. + }, + }, + ], + "role": "A String", # Optional. The producer of the content. Must be either 'user' or 'model'. Useful to set for multi-turn conversations, otherwise can be left blank or unset. + }, + ], + "userInputTokenDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the user input tokens. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + "userMessagePerExampleDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the messages per example. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + "userOutputTokenDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the user output tokens. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + }, + }, + "updateTime": "A String", # Output only. Time when the TuningJob was most recently updated. +}+
get(name, x__xgafv=None)
+ Gets a TuningJob. + +Args: + name: string, Required. The name of the TuningJob resource. Format: `projects/{project}/locations/{location}/tuningJobs/{tuning_job}` (required) + x__xgafv: string, V1 error format. + Allowed values + 1 - v1 error format + 2 - v2 error format + +Returns: + An object of the form: + + { # Represents a TuningJob that runs with Google owned models. + "baseModel": "A String", # Model name for tuning, e.g., "gemini-1.0-pro-002". + "createTime": "A String", # Output only. Time when the TuningJob was created. + "description": "A String", # Optional. The description of the TuningJob. + "endTime": "A String", # Output only. Time when the TuningJob entered any of the following JobStates: `JOB_STATE_SUCCEEDED`, `JOB_STATE_FAILED`, `JOB_STATE_CANCELLED`, `JOB_STATE_EXPIRED`. + "error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # Output only. Only populated when job's state is `JOB_STATE_FAILED` or `JOB_STATE_CANCELLED`. + "code": 42, # The status code, which should be an enum value of google.rpc.Code. + "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. + { + "a_key": "", # Properties of the object. Contains field @type with type URL. + }, + ], + "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + }, + "experiment": "A String", # Output only. The Experiment associated with this TuningJob. + "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. + "a_key": "A String", + }, + "name": "A String", # Output only. Identifier. Resource name of a TuningJob. Format: `projects/{project}/locations/{location}/tuningJobs/{tuning_job}` + "startTime": "A String", # Output only. Time when the TuningJob for the first time entered the `JOB_STATE_RUNNING` state. + "state": "A String", # Output only. The detailed state of the job. + "supervisedTuningSpec": { # Tuning Spec for Supervised Tuning. # Tuning Spec for Supervised Fine Tuning. + "hyperParameters": { # Hyperparameters for SFT. # Optional. Hyperparameters for SFT. + "adapterSize": "A String", # Optional. Adapter size for tuning. + "epochCount": "A String", # Optional. Number of training epoches for this tuning job. + "learningRateMultiplier": 3.14, # Optional. Learning rate multiplier for tuning. + }, + "trainingDatasetUri": "A String", # Required. Cloud Storage path to file containing training dataset for tuning. + "validationDatasetUri": "A String", # Optional. Cloud Storage path to file containing validation dataset for tuning. + }, + "tunedModel": { # The Model Registry Model and Online Prediction Endpoint assiociated with this TuningJob. # Output only. The tuned model resources assiociated with this TuningJob. + "endpoint": "A String", # Output only. A resource name of an Endpoint. Format: `projects/{project}/locations/{location}/endpoints/{endpoint}`. + "model": "A String", # Output only. The resource name of the TunedModel. Format: `projects/{project}/locations/{location}/models/{model}`. + }, + "tunedModelDisplayName": "A String", # Optional. The display name of the TunedModel. The name can be up to 128 characters long and can consist of any UTF-8 characters. + "tuningDataStats": { # The tuning data statistic values for TuningJob. # Output only. The tuning data statistics associated with this TuningJob. + "supervisedTuningDataStats": { # Tuning data statistics for Supervised Tuning. # The SFT Tuning data stats. + "totalBillableCharacterCount": "A String", # Output only. Number of billable characters in the tuning dataset. + "totalTuningCharacterCount": "A String", # Output only. Number of tuning characters in the tuning dataset. + "tuningDatasetExampleCount": "A String", # Output only. Number of examples in the tuning dataset. + "tuningStepCount": "A String", # Output only. Number of tuning steps for this Tuning Job. + "userDatasetExamples": [ # Output only. Sample user messages in the training dataset uri. + { # The base structured datatype containing multi-part content of a message. A `Content` includes a `role` field designating the producer of the `Content` and a `parts` field containing multi-part data that contains the content of the message turn. + "parts": [ # Required. Ordered `Parts` that constitute a single message. Parts may have different IANA MIME types. + { # A datatype containing media that is part of a multi-part `Content` message. A `Part` consists of data which has an associated datatype. A `Part` can only contain one of the accepted types in `Part.data`. A `Part` must have a fixed IANA MIME type identifying the type and subtype of the media if `inline_data` or `file_data` field is filled with raw bytes. + "fileData": { # URI based data. # Optional. URI based data. + "fileUri": "A String", # Required. URI. + "mimeType": "A String", # Required. The IANA standard MIME type of the source data. + }, + "functionCall": { # A predicted [FunctionCall] returned from the model that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing the parameters and their values. # Optional. A predicted [FunctionCall] returned from the model that contains a string representing the [FunctionDeclaration.name] with the parameters and their values. + "args": { # Optional. Required. The function parameters and values in JSON object format. See [FunctionDeclaration.parameters] for parameter details. + "a_key": "", # Properties of the object. + }, + "name": "A String", # Required. The name of the function to call. Matches [FunctionDeclaration.name]. + }, + "functionResponse": { # The result output from a [FunctionCall] that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing any output from the function is used as context to the model. This should contain the result of a [FunctionCall] made based on model prediction. # Optional. The result output of a [FunctionCall] that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing any output from the function call. It is used as context to the model. + "name": "A String", # Required. The name of the function to call. Matches [FunctionDeclaration.name] and [FunctionCall.name]. + "response": { # Required. The function response in JSON object format. + "a_key": "", # Properties of the object. + }, + }, + "inlineData": { # Content blob. It's preferred to send as text directly rather than raw bytes. # Optional. Inlined bytes data. + "data": "A String", # Required. Raw bytes. + "mimeType": "A String", # Required. The IANA standard MIME type of the source data. + }, + "text": "A String", # Optional. Text part (can be code). + "videoMetadata": { # Metadata describes the input video content. # Optional. Video metadata. The metadata should only be specified while the video data is presented in inline_data or file_data. + "endOffset": "A String", # Optional. The end offset of the video. + "startOffset": "A String", # Optional. The start offset of the video. + }, + }, + ], + "role": "A String", # Optional. The producer of the content. Must be either 'user' or 'model'. Useful to set for multi-turn conversations, otherwise can be left blank or unset. + }, + ], + "userInputTokenDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the user input tokens. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + "userMessagePerExampleDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the messages per example. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + "userOutputTokenDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the user output tokens. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + }, + }, + "updateTime": "A String", # Output only. Time when the TuningJob was most recently updated. +}+
list(parent, filter=None, pageSize=None, pageToken=None, x__xgafv=None)
+ Lists TuningJobs in a Location. + +Args: + parent: string, Required. The resource name of the Location to list the TuningJobs from. Format: `projects/{project}/locations/{location}` (required) + filter: string, Optional. The standard list filter. + pageSize: integer, Optional. The standard list page size. + pageToken: string, Optional. The standard list page token. Typically obtained via ListTuningJob.next_page_token of the previous GenAiTuningService.ListTuningJob][] call. + x__xgafv: string, V1 error format. + Allowed values + 1 - v1 error format + 2 - v2 error format + +Returns: + An object of the form: + + { # Response message for GenAiTuningService.ListTuningJobs + "nextPageToken": "A String", # A token to retrieve the next page of results. Pass to ListTuningJobsRequest.page_token to obtain that page. + "tuningJobs": [ # List of TuningJobs in the requested page. + { # Represents a TuningJob that runs with Google owned models. + "baseModel": "A String", # Model name for tuning, e.g., "gemini-1.0-pro-002". + "createTime": "A String", # Output only. Time when the TuningJob was created. + "description": "A String", # Optional. The description of the TuningJob. + "endTime": "A String", # Output only. Time when the TuningJob entered any of the following JobStates: `JOB_STATE_SUCCEEDED`, `JOB_STATE_FAILED`, `JOB_STATE_CANCELLED`, `JOB_STATE_EXPIRED`. + "error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # Output only. Only populated when job's state is `JOB_STATE_FAILED` or `JOB_STATE_CANCELLED`. + "code": 42, # The status code, which should be an enum value of google.rpc.Code. + "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. + { + "a_key": "", # Properties of the object. Contains field @type with type URL. + }, + ], + "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + }, + "experiment": "A String", # Output only. The Experiment associated with this TuningJob. + "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. + "a_key": "A String", + }, + "name": "A String", # Output only. Identifier. Resource name of a TuningJob. Format: `projects/{project}/locations/{location}/tuningJobs/{tuning_job}` + "startTime": "A String", # Output only. Time when the TuningJob for the first time entered the `JOB_STATE_RUNNING` state. + "state": "A String", # Output only. The detailed state of the job. + "supervisedTuningSpec": { # Tuning Spec for Supervised Tuning. # Tuning Spec for Supervised Fine Tuning. + "hyperParameters": { # Hyperparameters for SFT. # Optional. Hyperparameters for SFT. + "adapterSize": "A String", # Optional. Adapter size for tuning. + "epochCount": "A String", # Optional. Number of training epoches for this tuning job. + "learningRateMultiplier": 3.14, # Optional. Learning rate multiplier for tuning. + }, + "trainingDatasetUri": "A String", # Required. Cloud Storage path to file containing training dataset for tuning. + "validationDatasetUri": "A String", # Optional. Cloud Storage path to file containing validation dataset for tuning. + }, + "tunedModel": { # The Model Registry Model and Online Prediction Endpoint assiociated with this TuningJob. # Output only. The tuned model resources assiociated with this TuningJob. + "endpoint": "A String", # Output only. A resource name of an Endpoint. Format: `projects/{project}/locations/{location}/endpoints/{endpoint}`. + "model": "A String", # Output only. The resource name of the TunedModel. Format: `projects/{project}/locations/{location}/models/{model}`. + }, + "tunedModelDisplayName": "A String", # Optional. The display name of the TunedModel. The name can be up to 128 characters long and can consist of any UTF-8 characters. + "tuningDataStats": { # The tuning data statistic values for TuningJob. # Output only. The tuning data statistics associated with this TuningJob. + "supervisedTuningDataStats": { # Tuning data statistics for Supervised Tuning. # The SFT Tuning data stats. + "totalBillableCharacterCount": "A String", # Output only. Number of billable characters in the tuning dataset. + "totalTuningCharacterCount": "A String", # Output only. Number of tuning characters in the tuning dataset. + "tuningDatasetExampleCount": "A String", # Output only. Number of examples in the tuning dataset. + "tuningStepCount": "A String", # Output only. Number of tuning steps for this Tuning Job. + "userDatasetExamples": [ # Output only. Sample user messages in the training dataset uri. + { # The base structured datatype containing multi-part content of a message. A `Content` includes a `role` field designating the producer of the `Content` and a `parts` field containing multi-part data that contains the content of the message turn. + "parts": [ # Required. Ordered `Parts` that constitute a single message. Parts may have different IANA MIME types. + { # A datatype containing media that is part of a multi-part `Content` message. A `Part` consists of data which has an associated datatype. A `Part` can only contain one of the accepted types in `Part.data`. A `Part` must have a fixed IANA MIME type identifying the type and subtype of the media if `inline_data` or `file_data` field is filled with raw bytes. + "fileData": { # URI based data. # Optional. URI based data. + "fileUri": "A String", # Required. URI. + "mimeType": "A String", # Required. The IANA standard MIME type of the source data. + }, + "functionCall": { # A predicted [FunctionCall] returned from the model that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing the parameters and their values. # Optional. A predicted [FunctionCall] returned from the model that contains a string representing the [FunctionDeclaration.name] with the parameters and their values. + "args": { # Optional. Required. The function parameters and values in JSON object format. See [FunctionDeclaration.parameters] for parameter details. + "a_key": "", # Properties of the object. + }, + "name": "A String", # Required. The name of the function to call. Matches [FunctionDeclaration.name]. + }, + "functionResponse": { # The result output from a [FunctionCall] that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing any output from the function is used as context to the model. This should contain the result of a [FunctionCall] made based on model prediction. # Optional. The result output of a [FunctionCall] that contains a string representing the [FunctionDeclaration.name] and a structured JSON object containing any output from the function call. It is used as context to the model. + "name": "A String", # Required. The name of the function to call. Matches [FunctionDeclaration.name] and [FunctionCall.name]. + "response": { # Required. The function response in JSON object format. + "a_key": "", # Properties of the object. + }, + }, + "inlineData": { # Content blob. It's preferred to send as text directly rather than raw bytes. # Optional. Inlined bytes data. + "data": "A String", # Required. Raw bytes. + "mimeType": "A String", # Required. The IANA standard MIME type of the source data. + }, + "text": "A String", # Optional. Text part (can be code). + "videoMetadata": { # Metadata describes the input video content. # Optional. Video metadata. The metadata should only be specified while the video data is presented in inline_data or file_data. + "endOffset": "A String", # Optional. The end offset of the video. + "startOffset": "A String", # Optional. The start offset of the video. + }, + }, + ], + "role": "A String", # Optional. The producer of the content. Must be either 'user' or 'model'. Useful to set for multi-turn conversations, otherwise can be left blank or unset. + }, + ], + "userInputTokenDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the user input tokens. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + "userMessagePerExampleDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the messages per example. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + "userOutputTokenDistribution": { # Dataset distribution for Supervised Tuning. # Output only. Dataset distributions for the user output tokens. + "buckets": [ # Output only. Defines the histogram bucket. + { # Dataset bucket used to create a histogram for the distribution given a population of values. + "count": 3.14, # Output only. Number of values in the bucket. + "left": 3.14, # Output only. Left bound of the bucket. + "right": 3.14, # Output only. Right bound of the bucket. + }, + ], + "max": 3.14, # Output only. The maximum of the population values. + "mean": 3.14, # Output only. The arithmetic mean of the values in the population. + "median": 3.14, # Output only. The median of the values in the population. + "min": 3.14, # Output only. The minimum of the population values. + "p5": 3.14, # Output only. The 5th percentile of the values in the population. + "p95": 3.14, # Output only. The 95th percentile of the values in the population. + "sum": "A String", # Output only. Sum of a given population of values. + }, + }, + }, + "updateTime": "A String", # Output only. Time when the TuningJob was most recently updated. + }, + ], +}+
list_next()
+ Retrieves the next page of results. + + Args: + previous_request: The request for the previous page. (required) + previous_response: The response from the request for the previous page. (required) + + Returns: + A request object that you can call 'execute()' on to request the next + page. Returns None if there are no more items in the collection. ++