@google/genai 2.10.0 → 2.12.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.
@@ -309,6 +309,70 @@ declare enum ApiSpec {
309
309
  ELASTIC_SEARCH = "ELASTIC_SEARCH"
310
310
  }
311
311
 
312
+ /** The aspect ratio for the image output. */
313
+ declare enum AspectRatio {
314
+ /**
315
+ * Default value. This value is unused.
316
+ */
317
+ ASPECT_RATIO_UNSPECIFIED = "ASPECT_RATIO_UNSPECIFIED",
318
+ /**
319
+ * 1:1 aspect ratio.
320
+ */
321
+ ASPECT_RATIO_ONE_BY_ONE = "ASPECT_RATIO_ONE_BY_ONE",
322
+ /**
323
+ * 2:3 aspect ratio.
324
+ */
325
+ ASPECT_RATIO_TWO_BY_THREE = "ASPECT_RATIO_TWO_BY_THREE",
326
+ /**
327
+ * 3:2 aspect ratio.
328
+ */
329
+ ASPECT_RATIO_THREE_BY_TWO = "ASPECT_RATIO_THREE_BY_TWO",
330
+ /**
331
+ * 3:4 aspect ratio.
332
+ */
333
+ ASPECT_RATIO_THREE_BY_FOUR = "ASPECT_RATIO_THREE_BY_FOUR",
334
+ /**
335
+ * 4:3 aspect ratio.
336
+ */
337
+ ASPECT_RATIO_FOUR_BY_THREE = "ASPECT_RATIO_FOUR_BY_THREE",
338
+ /**
339
+ * 4:5 aspect ratio.
340
+ */
341
+ ASPECT_RATIO_FOUR_BY_FIVE = "ASPECT_RATIO_FOUR_BY_FIVE",
342
+ /**
343
+ * 5:4 aspect ratio.
344
+ */
345
+ ASPECT_RATIO_FIVE_BY_FOUR = "ASPECT_RATIO_FIVE_BY_FOUR",
346
+ /**
347
+ * 9:16 aspect ratio.
348
+ */
349
+ ASPECT_RATIO_NINE_BY_SIXTEEN = "ASPECT_RATIO_NINE_BY_SIXTEEN",
350
+ /**
351
+ * 16:9 aspect ratio.
352
+ */
353
+ ASPECT_RATIO_SIXTEEN_BY_NINE = "ASPECT_RATIO_SIXTEEN_BY_NINE",
354
+ /**
355
+ * 21:9 aspect ratio.
356
+ */
357
+ ASPECT_RATIO_TWENTY_ONE_BY_NINE = "ASPECT_RATIO_TWENTY_ONE_BY_NINE",
358
+ /**
359
+ * 1:8 aspect ratio.
360
+ */
361
+ ASPECT_RATIO_ONE_BY_EIGHT = "ASPECT_RATIO_ONE_BY_EIGHT",
362
+ /**
363
+ * 8:1 aspect ratio.
364
+ */
365
+ ASPECT_RATIO_EIGHT_BY_ONE = "ASPECT_RATIO_EIGHT_BY_ONE",
366
+ /**
367
+ * 1:4 aspect ratio.
368
+ */
369
+ ASPECT_RATIO_ONE_BY_FOUR = "ASPECT_RATIO_ONE_BY_FOUR",
370
+ /**
371
+ * 4:1 aspect ratio.
372
+ */
373
+ ASPECT_RATIO_FOUR_BY_ONE = "ASPECT_RATIO_FOUR_BY_ONE"
374
+ }
375
+
312
376
  /** Representation of an audio chunk. */
313
377
  declare interface AudioChunk {
314
378
  /** Raw bytes of audio data.
@@ -320,6 +384,18 @@ declare interface AudioChunk {
320
384
  sourceMetadata?: LiveMusicSourceMetadata;
321
385
  }
322
386
 
387
+ /** Configuration for audio-specific output formatting. */
388
+ declare class AudioResponseFormat {
389
+ /** Optional. Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus). */
390
+ bitRate?: number;
391
+ /** Optional. Delivery mode for the generated content. */
392
+ delivery?: Delivery;
393
+ /** Optional. The MIME type of the audio output. */
394
+ mimeType?: string;
395
+ /** Optional. Sample rate for the generated audio in Hertz. */
396
+ sampleRate?: number;
397
+ }
398
+
323
399
  /** The audio transcription configuration in Setup. */
324
400
  declare interface AudioTranscriptionConfig {
325
401
  /** Deprecated: use LanguageAuto or LanguageHints instead. */
@@ -626,7 +702,7 @@ declare interface BatchJobSource {
626
702
 
627
703
  declare type BatchJobSourceUnion = BatchJobSource | InlinedRequest[] | string;
628
704
 
629
- /** Specifies the function Behavior. Currently only non-blocking functions are supported. If not specified, the system keeps the current function call behavior. This field is currently only supported by the BidiGenerateContent method. */
705
+ /** Specifies the function Behavior. If not specified, the system keeps the current function call behavior. This field is currently only supported by the BidiGenerateContent method. */
630
706
  declare enum Behavior {
631
707
  /**
632
708
  * This value is unspecified.
@@ -919,13 +995,15 @@ declare interface CompletionStats {
919
995
 
920
996
  /** Composite reinforcement tuning reward config. */
921
997
  declare interface CompositeReinforcementTuningRewardConfig {
998
+ /** List of reward function configurations with weights. */
922
999
  weightedRewardConfigs?: CompositeReinforcementTuningRewardConfigWeightedRewardConfig[];
923
1000
  }
924
1001
 
925
1002
  /** Composite reinforcement tuning reward config weighted reward config. */
926
1003
  declare interface CompositeReinforcementTuningRewardConfigWeightedRewardConfig {
1004
+ /** Single reward configuration. */
927
1005
  rewardConfig?: SingleReinforcementTuningRewardConfig;
928
- /** How much this single reward contributes to the total overall reward. */
1006
+ /** How much this single reward contributes to the total overall reward. Total reward is a linear combination of single rewards with their corresponding weights, i.e., ``` total_reward = ( weight_a * reward_a + weight_b * reward_b + ... ) / (weight_a + weight_b + ...) ``` */
929
1007
  weight?: number;
930
1008
  }
931
1009
 
@@ -1009,6 +1087,9 @@ declare interface ContentEmbeddingStatistics {
1009
1087
  /** Gemini Enterprise Agent Platform only. Number of tokens of the input text.
1010
1088
  */
1011
1089
  tokenCount?: number;
1090
+ /** Gemini Enterprise Agent Platform only. List of modalities and their token count for the input content.
1091
+ */
1092
+ tokensDetails?: ModalityTokenCount[];
1012
1093
  }
1013
1094
 
1014
1095
  declare type ContentListUnion = Content | Content[] | PartUnion | PartUnion[];
@@ -1605,6 +1686,12 @@ declare interface DatasetStats {
1605
1686
  userMessagePerExampleDistribution?: DatasetDistribution;
1606
1687
  /** Output only. Dataset distributions for the user output tokens. */
1607
1688
  userOutputTokenDistribution?: DatasetDistribution;
1689
+ /** Output only. Dataset distributions for the number of contents per example. */
1690
+ contentsPerExampleDistribution?: DatasetDistribution;
1691
+ /** Output only. Sample user dataset examples in the training dataset uri for Reinforcement Tuning. */
1692
+ reinforcementTuningUserDatasetExamples?: ReinforcementTuningUserDatasetExamples;
1693
+ /** Output only. Number of billable tokens in the tuning dataset. */
1694
+ totalBillableTokenCount?: string;
1608
1695
  }
1609
1696
 
1610
1697
  /** Optional parameters for models.get method. */
@@ -1773,6 +1860,22 @@ declare interface DeleteResourceJob {
1773
1860
  error?: JobError;
1774
1861
  }
1775
1862
 
1863
+ /** Delivery mode for the generated content. */
1864
+ declare enum Delivery {
1865
+ /**
1866
+ * Default value. This value is unused.
1867
+ */
1868
+ DELIVERY_UNSPECIFIED = "DELIVERY_UNSPECIFIED",
1869
+ /**
1870
+ * Generated bytes are returned inline in the response.
1871
+ */
1872
+ INLINE = "INLINE",
1873
+ /**
1874
+ * Generated content is stored and a URI is returned.
1875
+ */
1876
+ URI = "URI"
1877
+ }
1878
+
1776
1879
  /** Statistics for distillation prompt dataset. These statistics do not include the responses sampled from the teacher model. This data type is not supported in Gemini API. */
1777
1880
  declare interface DistillationDataStats {
1778
1881
  /** Output only. Statistics computed for the training dataset. */
@@ -2602,7 +2705,7 @@ declare interface FunctionDeclaration {
2602
2705
  response?: Schema;
2603
2706
  /** Optional. Describes the output from this function in JSON Schema format. The value specified by the schema is the response value of the function. This field is mutually exclusive with `response`. */
2604
2707
  responseJsonSchema?: unknown;
2605
- /** Optional. Specifies the function Behavior. Currently only non-blocking functions are supported. If not specified, the system keeps the current function call behavior. This field is currently only supported by the BidiGenerateContent method. */
2708
+ /** Optional. Specifies the function Behavior. If not specified, the system keeps the current function call behavior. This field is currently only supported by the BidiGenerateContent method. */
2606
2709
  behavior?: Behavior;
2607
2710
  }
2608
2711
 
@@ -3319,11 +3422,11 @@ declare interface GenerationConfig {
3319
3422
  presencePenalty?: number;
3320
3423
  /** Optional. If set to true, the log probabilities of the output tokens are returned. Log probabilities are the logarithm of the probability of a token appearing in the output. A higher log probability means the token is more likely to be generated. This can be useful for analyzing the model's confidence in its own output and for debugging. */
3321
3424
  responseLogprobs?: boolean;
3322
- /** Optional. The IANA standard MIME type of the response. The model will generate output that conforms to this MIME type. Supported values include 'text/plain' (default) and 'application/json'. The model needs to be prompted to output the appropriate response type, otherwise the behavior is undefined. */
3425
+ /** Optional. The IANA standard MIME type of the response. The model will generate output that conforms to this MIME type. Supported values include 'text/plain' (default) and 'application/json'. The model needs to be prompted to output the appropriate response type, otherwise the behavior is undefined. Deprecated: Use `response_format` instead. */
3323
3426
  responseMimeType?: string;
3324
3427
  /** Optional. The modalities of the response. The model will generate a response that includes all the specified modalities. For example, if this is set to `[TEXT, IMAGE]`, the response will include both text and an image. */
3325
3428
  responseModalities?: Modality[];
3326
- /** Optional. Lets you to specify a schema for the model's response, ensuring that the output conforms to a particular structure. This is useful for generating structured data such as JSON. The schema is a subset of the [OpenAPI 3.0 schema object](https://spec.openapis.org/oas/v3.0.3#schema) object. When this field is set, you must also set the `response_mime_type` to `application/json`. */
3429
+ /** Optional. Lets you to specify a schema for the model's response, ensuring that the output conforms to a particular structure. This is useful for generating structured data such as JSON. The schema is a subset of the [OpenAPI 3.0 schema object](https://spec.openapis.org/oas/v3.0.3#schema) object. When this field is set, you must also set the `response_mime_type` to `application/json`. Deprecated: Use `response_format` instead. */
3327
3430
  responseSchema?: Schema;
3328
3431
  /** Optional. Routing configuration. This field is not supported in Gemini API. */
3329
3432
  routingConfig?: GenerationConfigRoutingConfig;
@@ -3343,6 +3446,10 @@ declare interface GenerationConfig {
3343
3446
  topP?: number;
3344
3447
  /** Optional. Enables enhanced civic answers. It may not be available for all models. This field is not supported in Vertex AI. */
3345
3448
  enableEnhancedCivicAnswers?: boolean;
3449
+ /** Optional. New response format field for the model to configure output formatting and delivery. */
3450
+ responseFormat?: ResponseFormat[];
3451
+ /** Optional. Config for translation. This field is not supported in Vertex AI. */
3452
+ translationConfig?: TranslationConfig;
3346
3453
  }
3347
3454
 
3348
3455
  /** The configuration for routing the request to a specific model. This can be used to control which model is used for the generation, either automatically or by specifying a model name. This data type is not supported in Gemini API. */
@@ -3766,7 +3873,7 @@ declare interface GroundingMetadata {
3766
3873
  searchEntryPoint?: SearchEntryPoint;
3767
3874
  /** Web search queries for the following-up web search. */
3768
3875
  webSearchQueries?: string[];
3769
- /** Optional. Output only. A token that can be used to render a Google Maps widget with the contextual data. This field is populated only when the grounding source is Google Maps. */
3876
+ /** Optional. Output only. Deprecated: The Google Maps contextual widget behavior in Grounding with Google Maps is being deprecated; this field is planned for removal and will no longer be populated once removed. A token that can be used to render a Google Maps widget with the contextual data. This field is populated only when the grounding source is Google Maps. */
3770
3877
  googleMapsWidgetContextToken?: string;
3771
3878
  /** Optional. The queries that were executed by the retrieval tools. This field is populated only when the grounding source is a retrieval tool, such as Vertex AI Search. This field is not supported in Gemini API. */
3772
3879
  retrievalQueries?: string[];
@@ -3940,6 +4047,16 @@ declare enum HarmSeverity {
3940
4047
  HARM_SEVERITY_HIGH = "HARM_SEVERITY_HIGH"
3941
4048
  }
3942
4049
 
4050
+ /** Configuration for history exchange between client and server. */
4051
+ declare interface HistoryConfig {
4052
+ /** If true, after sending `setup_complete`, the server will wait
4053
+ and at first process `client_content` messages until `turn_complete` is
4054
+ `true`. This initial history will not trigger a model call and
4055
+ may end with model content. After `turn_complete` is `true`, the client
4056
+ can start the realtime conversation via `realtime_input`. */
4057
+ initialHistoryInClientContent?: boolean;
4058
+ }
4059
+
3943
4060
  /** The location of the API key. This enum is not supported in Gemini API. */
3944
4061
  declare enum HttpElementLocation {
3945
4062
  HTTP_IN_UNSPECIFIED = "HTTP_IN_UNSPECIFIED",
@@ -4149,10 +4266,46 @@ declare enum ImageResizeMode {
4149
4266
  PAD = "PAD"
4150
4267
  }
4151
4268
 
4269
+ /** Configuration for image-specific output formatting. */
4270
+ declare class ImageResponseFormat {
4271
+ /** Optional. The aspect ratio for the image output. */
4272
+ aspectRatio?: AspectRatio;
4273
+ /** Optional. Delivery mode for the generated content. */
4274
+ delivery?: Delivery;
4275
+ /** Optional. The size of the image output. */
4276
+ imageSize?: ImageSize;
4277
+ /** Optional. The MIME type of the image output. */
4278
+ mimeType?: string;
4279
+ }
4280
+
4152
4281
  /** Image search for grounding and related configurations. */
4153
4282
  declare interface ImageSearch {
4154
4283
  }
4155
4284
 
4285
+ /** The size of the image output. */
4286
+ declare enum ImageSize {
4287
+ /**
4288
+ * Default value. This value is unused.
4289
+ */
4290
+ IMAGE_SIZE_UNSPECIFIED = "IMAGE_SIZE_UNSPECIFIED",
4291
+ /**
4292
+ * 512px image size.
4293
+ */
4294
+ IMAGE_SIZE_FIVE_TWELVE = "IMAGE_SIZE_FIVE_TWELVE",
4295
+ /**
4296
+ * 1K image size.
4297
+ */
4298
+ IMAGE_SIZE_ONE_K = "IMAGE_SIZE_ONE_K",
4299
+ /**
4300
+ * 2K image size.
4301
+ */
4302
+ IMAGE_SIZE_TWO_K = "IMAGE_SIZE_TWO_K",
4303
+ /**
4304
+ * 4K image size.
4305
+ */
4306
+ IMAGE_SIZE_FOUR_K = "IMAGE_SIZE_FOUR_K"
4307
+ }
4308
+
4156
4309
  /** Optional parameters for importing a file. */
4157
4310
  declare interface ImportFileConfig {
4158
4311
  /** Used to override HTTP request options. */
@@ -4709,6 +4862,8 @@ declare interface LiveClientSetup {
4709
4862
  response.
4710
4863
  */
4711
4864
  safetySettings?: SafetySetting[];
4865
+ /** Configures the exchange of history between the client and the server. */
4866
+ historyConfig?: HistoryConfig;
4712
4867
  }
4713
4868
 
4714
4869
  /** Client generated response to a `ToolCall` received from the server.
@@ -5165,6 +5320,11 @@ declare interface LiveServerSessionResumptionUpdate {
5165
5320
  declare interface LiveServerSetupComplete {
5166
5321
  /** The session id of the live session. */
5167
5322
  sessionId?: string;
5323
+ /** Signature of the verified consent audio. This is populated when the
5324
+ request has a ReplicatedVoiceConfig with consent_audio set, if the consent
5325
+ verification was successful. This may be used in a subsequent request
5326
+ instead of the consent_audio to verify the same consent. */
5327
+ voiceConsentSignature?: VoiceConsentSignature;
5168
5328
  }
5169
5329
 
5170
5330
  /** Request for the client to execute the `function_calls` and return the responses with the matching `id`s. */
@@ -5253,22 +5413,22 @@ declare enum MaskReferenceMode {
5253
5413
  MASK_MODE_SEMANTIC = "MASK_MODE_SEMANTIC"
5254
5414
  }
5255
5415
 
5256
- /** Match operation to use for evaluation. */
5416
+ /** Match operation to use for evaluating rewards. This enum is not supported in Gemini API. */
5257
5417
  declare enum MatchOperation {
5258
5418
  /**
5259
- * Default value. This value is unused.
5419
+ * Default value. A user error will be returned if not set.
5260
5420
  */
5261
5421
  MATCH_OPERATION_UNSPECIFIED = "MATCH_OPERATION_UNSPECIFIED",
5262
5422
  /**
5263
- * Equivalent to GoogleSQL `REGEX_CONTAINS(target, expression)`.
5423
+ * Equivalent to [GoogleSQL](https://cloud.google.com/bigquery/docs/reference/standard-sql/string_functions#regexp_contains) `REGEX_CONTAINS(target, expression)`.
5264
5424
  */
5265
5425
  REGEX_CONTAINS = "REGEX_CONTAINS",
5266
5426
  /**
5267
- * `expression` is a substring of target.
5427
+ * The match operation returns `true` if expression is a substring of the target.
5268
5428
  */
5269
5429
  PARTIAL_MATCH = "PARTIAL_MATCH",
5270
5430
  /**
5271
- * `expression` is an exact match of target.
5431
+ * The match operation returns `true` expression is an exact match of the target.
5272
5432
  */
5273
5433
  EXACT_MATCH = "EXACT_MATCH"
5274
5434
  }
@@ -6133,39 +6293,39 @@ declare class RegisterFilesResponse {
6133
6293
  declare interface ReinforcementTuningAutoraterScorer {
6134
6294
  /** Autorater config for evaluation. */
6135
6295
  autoraterConfig?: AutoraterConfig;
6136
- /** Allows substituting `prompt`, `response`, `system_instruction` and `references.reference` (each wrapped in double curly braces) into the autorater prompt. */
6296
+ /** The prompt for an autorater to scorer the parsed sample response. This field supports the following placeholders that will be replaced before scoring: - {{prompt}} - {{response}} - {{system_instruction}} - {{references.key}} */
6137
6297
  autoraterPrompt?: string;
6138
- /** Parses autorater returned response. */
6298
+ /** Parses autorater returned response for scoring. For example, if the autorater response has reward stored in the `2.0` block, defining a parsing response config using regex `".*(.*?)"` will return a score `"2.0"`. */
6139
6299
  autoraterResponseParseConfig?: ReinforcementTuningParseResponseConfig;
6140
- /** Scores autorater responses by directly converting parsed autorater response to float reward. */
6300
+ /** Scores autorater responses by directly converting parsed autorater response to a float reward. Note: Reward is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. */
6141
6301
  parsedResponseConversionScorer?: ReinforcementTuningAutoraterScorerParsedResponseConversionScorer;
6142
- /** Scores autorater responses by using exact string match reward scorer. */
6302
+ /** Scores autorater responses by using string match reward scorer. */
6143
6303
  exactMatchScorer?: ReinforcementTuningAutoraterScorerExactMatchScorer;
6144
6304
  }
6145
6305
 
6146
- /** Scores autorater responses by using exact string match reward scorer. */
6306
+ /** Scores autorater responses by using exact string match reward scorer. This data type is not supported in Gemini API. */
6147
6307
  declare interface ReinforcementTuningAutoraterScorerExactMatchScorer {
6148
- /** Assigns this reward score if parsed response string equals the expression. */
6308
+ /** Assigns this reward score if the parsed response string equals the expression. */
6149
6309
  correctAnswerReward?: number;
6150
- /** Assigns this reward score if parsed reward value does not equal the expression. */
6310
+ /** Assigns this reward score if the parsed reward value does not equal the expression. */
6151
6311
  wrongAnswerReward?: number;
6152
- /** The string expression to match against. Supports substitution in the format of `references.reference` (wrapped in double curly braces) before matching. No regex support. */
6312
+ /** The string expression to match against for scoring. This field supports placeholders in the format of {{references.key}} that will be replaced before matching. Regex is not supported for this expression. For example, users can define an ExactMatchScorer as follows: { "correctAnswerReward": 1.0, "wrongAnswerReward": -1.0, "expression": "{{references.concise_answer}}" } When evaluating the reward for each parsed autorater response, if the prompt references in the training/validation dataset has the following fields: ``` { "example": ..., "references": { "concise_ansser": "Yes", "verbose_answer": "The answer is Yes" } } ``` The above ExactMatchScorer will be replaced as follows for scoring: ``` { "correctAnswerReward": 1.0, "wrongAnswerReward": -1.0, "expression": "Yes" } ``` If the *parsed* autorater response is equal to the string `"Yes"`, then the reward is `1.0`, otherwise the reward is `-1.0`. */
6153
6313
  expression?: string;
6154
6314
  }
6155
6315
 
6156
- /** Scores responses by directly converting parsed autorater response to float reward (reward is clipped to be within [-1, 1]). */
6316
+ /** Scores responses by directly converting the parsed autorater response to a float reward. Note: Reward is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. This data type is not supported in Gemini API. */
6157
6317
  declare class ReinforcementTuningAutoraterScorerParsedResponseConversionScorer {
6158
6318
  }
6159
6319
 
6160
- /** Scores parsed responses by calling a Cloud Run service. */
6320
+ /** ReinforcementTuningCloudRunRewardScorer allows users to implement a reward function through GCP Cloud Run. Comparing with ReinforcementTuningCodeExecutionRewardScorer that runs in a Sandbox and has no internet access, Cloud Run reward scorer is fully controlled by users. The Cloud Run service should implement the following HTTP API: HTTP method: `POST` HTTP request body: ``` { "example": ReinforcementTuningExample, "response": Content, "metadata": { "step": int "tuning_job_id": int64 } } ``` * `example` is a ReinforcementTuningExample in ProtoJSON format, (i.e., the format is the same as as one line in the training/validation dataset except that the keys must be in camel case). System instructions (i.e., `example.get("systemInstruction")`) and references (i.e., `example.get("references")`) are also included in the `example` provided that they are set in the training/validation dataset. * `response` is a Content in ProtoJSON format (i.e., keys must be in camel case), which is the same as the Online Prediction response for Gemini models. HTTP response body: { "reward": float, "user_requested_aux_info": str // Optional } where the field "user_requested_aux_info" is any (optional) string provided by users for assisting debugging. It's in snake case. This field is mostly useful when calling the GenAiTuningService.ValidateReinforcementTuningReward API, where the proto field (not Cloud Run HTTP response body) userRequestedAuxInfo will be populated if the Cloud Run reward function sets this field in the HTTP response. The following are examples for the HTTP request and response body. Example HTTP request body: ``` { "example": { "contents": [ { "role": "user", "parts": [ { "text": "What is the capital of France?" } ] } ], "references": { "answer": "Paris" } }, "response": { "parts": [ { "text": "London" } ] }, "metadata": { "step": 1, "tuning_job_id": 123456789 } } ``` Example HTTP response body: ``` { "reward": -1.0 } ``` Note: Reward output by Cloud Run reward function is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. This data type is not supported in Gemini API. */
6161
6321
  declare interface ReinforcementTuningCloudRunRewardScorer {
6162
- /** URI of the Cloud Run service that will be used to compute the reward. The Vertex AI Secure Fine Tuning Service Agent (`service-PROJECT_NUMBER@gcp-sa-vertex-tune.iam.gserviceaccount.com`, where `PROJECT_NUMBER` is the numeric project number) must be granted the permission (e.g. by granting `roles/run.invoker` in IAM) to invoke the Cloud Run service. */
6322
+ /** URI of the Cloud Run service that will be used to compute the reward. The [Vertex AI Secure Fine Tuning Service Agent](https://docs.cloud.google.com/iam/docs/service-agents#vertex-ai-secure-fine-tuning-service-agent) (`service-@gcp-sa-vertex-tune.iam.gserviceaccount.com`) must be granted the permission (e.g. by granting `roles/run.invoker` in IAM) to invoke the Cloud Run service. */
6163
6323
  cloudRunUri?: string;
6164
6324
  }
6165
6325
 
6166
- /** Scores parsed responses for code execution use cases. */
6326
+ /** ReinforcementTuningCodeExecutionRewardScorer allows users to implement a function to evaluate rewards for the sample response. The function signature is as follows: ``` def evaluate(example: dict[str, Any], response: dict[str, Any]) -> float: ... ``` `example` is a ReinforcementTuningExample in ProtoJSON format, (i.e., the format is the same as as one line in the training/validation dataset except that the keys must be in camel case). System instructions (i.e., `example.get("systemInstruction")`) and references (i.e., `example.get("references")`) are also included in the `example` provided that they are set in the training/validation dataset. `response` is a Content in ProtoJSON format (i.e., keys must be in camel case), which is the same as the Online Prediction response for Gemini models. Note: Reward output by the `evaluate` function is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. This data type is not supported in Gemini API. */
6167
6327
  declare interface ReinforcementTuningCodeExecutionRewardScorer {
6168
- /** Example python code snippet which assigns reward of 1 to answer matching user provided reference answer in per prompt references map. */
6328
+ /** The python code snippet as a string for evaluating rewards. The following is an example python code snippet that returns a reward `1.0` for a parsed response matching the user-provided reference answer in per prompt references map. ``` def evaluate(example, response) -> float: response_str = response.get("parts", [])0 references = example.get("references", {}) if response_str == references.get("concise_answer"): return 1.0 return -1.0 ``` Note: Reward output by the evaluate function is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. */
6169
6329
  pythonCodeSnippet?: string;
6170
6330
  }
6171
6331
 
@@ -6175,37 +6335,39 @@ declare interface ReinforcementTuningExample {
6175
6335
  contents?: Content[];
6176
6336
  /** References for the given prompt. The key is the name of the reference, and the value is the reference itself. */
6177
6337
  references?: Record<string, string>;
6178
- /** Corresponds to `system_instruction` in user-facing GenerateContentRequest. */
6338
+ /** Corresponds to system_instruction in user-facing GenerateContentRequest. */
6179
6339
  systemInstruction?: Content;
6180
6340
  }
6181
6341
 
6182
6342
  /** Hyperparameters for Reinforcement Tuning. */
6183
6343
  declare interface ReinforcementTuningHyperParameters {
6184
- /** Number of training epochs for the tuning job. */
6344
+ /** Optional. Number of training epoches for the tuning job. */
6185
6345
  epochCount?: string;
6186
6346
  /** Learning rate multiplier for Reinforcement Learning. */
6187
6347
  learningRateMultiplier?: number;
6188
- /** Adapter size for Reinforcement Tuning. */
6348
+ /** Optional. Adapter size for Reinforcement Tuning. */
6189
6349
  adapterSize?: AdapterSize;
6190
- /** Number of different responses to generate per prompt during tuning. */
6350
+ /** Optional. Number of different responses to generate per prompt during tuning. */
6191
6351
  samplesPerPrompt?: number;
6192
- /** Batch size for the tuning job. How many prompts to process at a train step. If not set, the batch size will be determined automatically. */
6352
+ /** Optional. Batch size for the tuning job. How many prompts to process at a train step. If not set, the batch size will be determined automatically. */
6193
6353
  batchSize?: number;
6194
- /** How often (in steps) to evaluate the tuning job during training. If not set, evaluation will run per epoch. */
6354
+ /** Optional. How often at steps to evaluate the tuning job during training. If not set, evel will be run per epoch. `total_steps = epoch_count * samples_per_prompt / total_prompts_in_dataset` */
6195
6355
  evaluateInterval?: number;
6196
- /** How often (in steps) to save checkpoints during training. If not set, one checkpoint per epoch will be saved. */
6356
+ /** Optional. How often at steps to save checkpoints during training. If not set, one checkpoint per epoch will be set. ```total_steps = epoch_count * samples_per_prompt / total_prompts_in_dataset``` */
6197
6357
  checkpointInterval?: number;
6198
- /** The maximum number of tokens to generate per prompt. If not set, defaults to 32768. */
6358
+ /** Optional. The maximum number of tokens to generate per prompt. Default to 32768. */
6199
6359
  maxOutputTokens?: number;
6200
- /** Indicates the maximum thinking depth. Use with earlier models shall result in error. */
6360
+ /** Indicates the maximum thinking depth during tuning. Starting from Gemini 3.5 models, the old thinking_budget will no longer be supported and will result in a user error if set. Instead, users should use the thinking_level parameter to control the maximum thinking depth. */
6201
6361
  thinkingLevel?: ReinforcementTuningThinkingLevel;
6362
+ /** Optional. The thinking budget for the tuning job to optimize for (Gemini 2.5 only). * -1 means dynamic thinking * 0 means no thinking * > 0 means thinking budget in tokens If not set, default to -1 (dynamic thinking). */
6363
+ thinkingBudget?: number;
6202
6364
  }
6203
6365
 
6204
- /** Defines how to parse sample response for reinforcement tuning. */
6366
+ /** Defines how to parse sample response config for reinforcement tuning. The parsed response (i.e., substring) will be passed to the reward functions. For example, the input prompt might be: > "Perform step-by-step thoughts first to problem A, finally output answer in the <ans> </ans> block." The sample response from the model under tuning might look like: > "<ans>Yes</ans>" Here, users can define the following parse config: ``` { "parseType": "REGEX_EXTRACT", "regexExtractExpression": ".*(.*?)" } ``` The resulting parsed response would be `"Yes"` and will be passed to the reward functions for evaluating rewards. This data type is not supported in Gemini API. */
6205
6367
  declare class ReinforcementTuningParseResponseConfig {
6206
- /** Defines how to parse sample response. */
6368
+ /** Defines the type for parsing sample response. */
6207
6369
  parseType?: ResponseParseType;
6208
- /** Defines the regex to extract the important part of sample response. This field is only used when `parse_type` is `REGEX_EXTRACT`. */
6370
+ /** Defines the regex for extracting the important part of sample response. This field is only used when parse_type is ResponseParseType.REGEX_EXTRACT. */
6209
6371
  regexExtractExpression?: string;
6210
6372
  }
6211
6373
 
@@ -6213,16 +6375,17 @@ declare class ReinforcementTuningParseResponseConfig {
6213
6375
  declare interface ReinforcementTuningRewardInfo {
6214
6376
  /** Output only. The calculated reward for the reward function. */
6215
6377
  reward?: number;
6216
- /** Output only. The user-requested auxiliary info for the reward function. */
6378
+ /** Output only. The user-requested auxiliary info for the reward function. This field is set only if the Cloud Run reward function configured by user returns a "user_requested_aux_info". Refer to ReinforcementTuningCloudRunRewardScorer for more details. */
6217
6379
  userRequestedAuxInfo?: string;
6218
6380
  }
6219
6381
 
6220
6382
  /** Reinforcement tuning spec for tuning. */
6221
6383
  declare interface ReinforcementTuningSpec {
6384
+ /** Composite reward function configuration for reinforcement tuning. */
6222
6385
  compositeRewardConfig?: CompositeReinforcementTuningRewardConfig;
6223
- /** Cloud Storage path to file containing training dataset for tuning. The dataset must be formatted as a JSONL file. */
6386
+ /** Cloud Storage path to the file containing training dataset for tuning. The dataset must be formatted as a JSONL file. */
6224
6387
  trainingDatasetUri?: string;
6225
- /** Cloud Storage path to file containing validation dataset for tuning. The dataset must be formatted as a JSONL file. If no validation dataset is provided, by default the API splits 25% of the training dataset or 50 examples, whichever is larger, as the validation dataset. */
6388
+ /** Cloud Storage path to the file containing validation dataset for tuning. The dataset must be formatted as a JSONL file. */
6226
6389
  validationDatasetUri?: string;
6227
6390
  /** Additional hyper-parameters to use during tuning. */
6228
6391
  hyperParameters?: ReinforcementTuningHyperParameters;
@@ -6230,11 +6393,11 @@ declare interface ReinforcementTuningSpec {
6230
6393
  singleRewardConfig?: SingleReinforcementTuningRewardConfig;
6231
6394
  }
6232
6395
 
6233
- /** Scores parsed responses for string matching use cases. */
6396
+ /** ReinforcementTuningStringMatchRewardScorer is used to score parsed responses for string matching use cases. For example, for math problems, users can use string match scorer to check if the correct exact answer is generated. Note: Reward returned by the string match reward function is clipped to be within `[-1, 1]` if wrongAnswerReward or correctAnswerReward are beyond the range, i.e., `reward = max(min(reward, 1.0), -1.0)`. This data type is not supported in Gemini API. */
6234
6397
  declare interface ReinforcementTuningStringMatchRewardScorer {
6235
- /** Wrong answer reward is returned if evaluator evaluates to `false`. All wrong answers get the same reward. */
6398
+ /** Wrong answer reward is returned if the parsed response is evaluated as `false`. All wrong answers get the same reward. */
6236
6399
  wrongAnswerReward?: number;
6237
- /** Correct answer reward is returned if evaluator evaluates to `true`. All correct answers get the same reward. */
6400
+ /** Correct answer rewawrd is returned if the parsed response is evaluated as `true`. All correct answers get the same reward. */
6238
6401
  correctAnswerReward?: number;
6239
6402
  /** Uses string match expression to evaluate parsed response. */
6240
6403
  stringMatchExpression?: ReinforcementTuningStringMatchRewardScorerStringMatchExpression;
@@ -6242,19 +6405,19 @@ declare interface ReinforcementTuningStringMatchRewardScorer {
6242
6405
  jsonMatchExpression?: ReinforcementTuningStringMatchRewardScorerJsonMatchExpression;
6243
6406
  }
6244
6407
 
6245
- /** Converts parsed responses to JSON format, finds the first-level matching key, then performs StringMatchExpression on the value. */
6408
+ /** JsonMatchExpression supports converting the parsed responses to JSON format, finding the value in the JSON response that matches the key_name in the first level, and performing StringMatchExpression operation on the matched JSON value. This data type is not supported in Gemini API. */
6246
6409
  declare interface ReinforcementTuningStringMatchRewardScorerJsonMatchExpression {
6247
- /** Json key name to find the value to match against. */
6410
+ /** The key name to find the value in the parsed response that's in JSON format. Only first-level key matching is supported. */
6248
6411
  keyName?: string;
6249
- /** String match expression to match against the value of json key. */
6412
+ /** String match expression to match against the extracted value from the JSON representation of the parsed response. */
6250
6413
  valueStringMatchExpression?: ReinforcementTuningStringMatchRewardScorerStringMatchExpression;
6251
6414
  }
6252
6415
 
6253
- /** Evaluates parsed response using match type against expression. */
6416
+ /** Evaluates parsed response using match type against the expression. Returns `true` if `MatchOperation(target, expression)` evaluates to `true`, and `false` otherwise. This data type is not supported in Gemini API. */
6254
6417
  declare interface ReinforcementTuningStringMatchRewardScorerStringMatchExpression {
6255
- /** Match operation to use for evaluation. */
6418
+ /** Match operation to use for evaluating rewards. */
6256
6419
  matchOperation?: MatchOperation;
6257
- /** String or regular expression to match against. Customer can also provide a references map (key/value pairs) whose value will be substituted into the expression by referencing `references.key_name` (wrapped in double curly braces). */
6420
+ /** A string or a regular expression to match against for evaluating rewards. Users can also provide a references map of `{key: value}` whose `value` will be used to replace the placeholder {{references.key}} in the expression. For example, if the following `references` are defined in the training / validation dataset: ``` { "systemInstruction": ..., "contents": ..., "references": { "concise_answer": "Yes", "verbose_answer": "The answer is Yes" } } ``` and if users define the following StringMatchExpression: { "matchOperation": "REGEX_CONTAINS", "expression": ".*{{references.concise_answer}}.*" } On evaluating the reward for each sample response, this StringMatchExpression will be substituted as: ``` { "matchOperation": "REGEX_CONTAINS", "expression": ".*Yes.*" } ``` */
6258
6421
  expression?: string;
6259
6422
  }
6260
6423
 
@@ -6274,6 +6437,12 @@ declare enum ReinforcementTuningThinkingLevel {
6274
6437
  HIGH = "HIGH"
6275
6438
  }
6276
6439
 
6440
+ /** Sample reinforcement tuning user data in the training dataset. The contents are truncated for better UI showing. This data type is not supported in Gemini API. */
6441
+ declare interface ReinforcementTuningUserDatasetExamples {
6442
+ /** List of user datasset examples showing to user. */
6443
+ userDatasetExamples?: ReinforcementTuningExample[];
6444
+ }
6445
+
6277
6446
  /** Represents a recorded session. */
6278
6447
  declare interface ReplayFile {
6279
6448
  replayId?: string;
@@ -6313,6 +6482,17 @@ declare interface ReplicatedVoiceConfig {
6313
6482
 
6314
6483
  * @remarks Encoded as base64 string. */
6315
6484
  voiceSampleAudio?: string;
6485
+ /** Recorded consent verifying ownership of the voice. This
6486
+ represents 16-bit signed little-endian wav data, with a 24kHz sampling
6487
+ rate.
6488
+ * @remarks Encoded as base64 string. */
6489
+ consentAudio?: string;
6490
+ /** Signature of a previously verified consent audio. This should be
6491
+ populated with a signature generated by the server for a previous
6492
+ request containing the consent_audio field. When provided, the
6493
+ signature is verified instead of the consent_audio field to reduce
6494
+ latency. Requests will fail if the signature is invalid or expired. */
6495
+ voiceConsentSignature?: VoiceConsentSignature;
6316
6496
  }
6317
6497
 
6318
6498
  /** Resource scope. */
@@ -6327,18 +6507,30 @@ declare enum ResourceScope {
6327
6507
  COLLECTION = "COLLECTION"
6328
6508
  }
6329
6509
 
6330
- /** Defines how to parse sample response. */
6510
+ /** Configuration for the model to configure output formatting and delivery. This data type is not supported in Gemini API. */
6511
+ declare class ResponseFormat {
6512
+ /** Audio output format. */
6513
+ audio?: AudioResponseFormat;
6514
+ /** Image output format. */
6515
+ image?: ImageResponseFormat;
6516
+ /** Text output format. */
6517
+ text?: TextResponseFormat;
6518
+ /** Video output format. */
6519
+ video?: VideoResponseFormat;
6520
+ }
6521
+
6522
+ /** Defines the type for parsing sample response. This enum is not supported in Gemini API. */
6331
6523
  declare enum ResponseParseType {
6332
6524
  /**
6333
- * Default value. This value is unused.
6525
+ * Default value. Fallback to IDENTITY
6334
6526
  */
6335
6527
  RESPONSE_PARSE_TYPE_UNSPECIFIED = "RESPONSE_PARSE_TYPE_UNSPECIFIED",
6336
6528
  /**
6337
- * Use the sample response as is.
6529
+ * Returns the sample response as is.
6338
6530
  */
6339
6531
  IDENTITY = "IDENTITY",
6340
6532
  /**
6341
- * Use regex to extract the important part of sample response.
6533
+ * Uses regex to extract the important part of sample response. Similar to [GoogleSQL](https://cloud.google.com/bigquery/docs/reference/standard-sql/string_functions#regexp_extract) `REGEX_EXTRACT(response, regex_extract_expression)`, but different in that if there are multiple matches, the last match will be returned.
6342
6534
  */
6343
6535
  REGEX_EXTRACT = "REGEX_EXTRACT"
6344
6536
  }
@@ -6754,15 +6946,15 @@ declare class SingleEmbedContentResponse {
6754
6946
  declare interface SingleReinforcementTuningRewardConfig {
6755
6947
  /** Scores parsed responses for autorater use cases by using a model to compute the reward. */
6756
6948
  autoraterScorer?: ReinforcementTuningAutoraterScorer;
6757
- /** A unique reward name used to identify each single reinforcement tuning reward. */
6949
+ /** A unique reward name for identifying each single reinforcement tuning reward. */
6758
6950
  rewardName?: string;
6759
- /** Defines how to parse sample response. */
6951
+ /** Defines how to parse sample response. For example, given a sample response for evaluating the reward, users might want to extract the text only between `` and `` in the sample response, and keeps only the last one in case there are multiple such tags. To achieve such a purpose, they can define a regex `".*(.*?)"` using the ReinforcementTuningParseResponseConfig.ResponseParseType.REGEX_EXTRACT parse type. */
6760
6952
  parseResponseConfig?: ReinforcementTuningParseResponseConfig;
6761
- /** Scores parsed responses for code execution use cases. */
6953
+ /** ReinforcementTuningCodeExecutionRewardScorer is used to score parsed responses for code execution use cases. */
6762
6954
  codeExecutionRewardScorer?: ReinforcementTuningCodeExecutionRewardScorer;
6763
- /** Scores parsed responses for simple string matching use cases against reference answer without writing python code. */
6955
+ /** ReinforcementTuningStringMatchRewardScorer is used to score parsed responses for simple string matching use cases against reference answers. */
6764
6956
  stringMatchRewardScorer?: ReinforcementTuningStringMatchRewardScorer;
6765
- /** Scores parsed responses by calling a Cloud Run service. */
6957
+ /** ReinforcementTuningCloudRunRewardScorer is used to score parsed responses by calling a Cloud Run service. */
6766
6958
  cloudRunRewardScorer?: ReinforcementTuningCloudRunRewardScorer;
6767
6959
  }
6768
6960
 
@@ -7008,6 +7200,14 @@ declare interface TestTableItem {
7008
7200
  ignoreKeys?: string[];
7009
7201
  }
7010
7202
 
7203
+ /** Configuration for text-specific output formatting. */
7204
+ declare class TextResponseFormat {
7205
+ /** Optional. The IANA standard MIME type of the response. */
7206
+ mimeType?: string;
7207
+ /** Optional. The JSON schema that the output should conform to. Only applicable when mime_type is APPLICATION_JSON. */
7208
+ schema?: unknown;
7209
+ }
7210
+
7011
7211
  /** The thinking features configuration. */
7012
7212
  declare interface ThinkingConfig {
7013
7213
  /** Indicates whether to include thoughts in the response. If true, thoughts are returned only if the model supports thought and thoughts are available.
@@ -7082,6 +7282,8 @@ declare interface Tool {
7082
7282
  urlContext?: UrlContext;
7083
7283
  /** Optional. MCP Servers to connect to. This field is not supported in Vertex AI. */
7084
7284
  mcpServers?: McpServer[];
7285
+ /** Optional. Uses Exa.ai to search for information to answer user queries. The search results will be grounded on Exa.ai and presented to the model for response generation. This field is not supported in Gemini API. */
7286
+ exaAiSearch?: ToolExaAiSearch;
7085
7287
  }
7086
7288
 
7087
7289
  /** A predicted server-side `ToolCall` returned from the model.
@@ -7113,6 +7315,14 @@ declare interface ToolConfig {
7113
7315
  includeServerSideToolInvocations?: boolean;
7114
7316
  }
7115
7317
 
7318
+ /** ExaAiSearch tool type. A tool that uses the Exa.ai search engine for grounding. This data type is not supported in Gemini API. */
7319
+ declare interface ToolExaAiSearch {
7320
+ /** Required. The API key for ExaAiSearch. */
7321
+ apiKey?: string;
7322
+ /** Optional. This field can be used to pass any parameter from the Exa.ai Search API. */
7323
+ customConfigs?: Record<string, unknown>;
7324
+ }
7325
+
7116
7326
  declare type ToolListUnion = ToolUnion[];
7117
7327
 
7118
7328
  /** ParallelAiSearch tool type. A tool that uses the Parallel.ai search engine for grounding. This data type is not supported in Gemini API. */
@@ -7204,12 +7414,9 @@ declare interface Transcription {
7204
7414
 
7205
7415
  /** Config for stream translation. */
7206
7416
  declare interface TranslationConfig {
7207
- /** If true, the model will generate audio when the target language is
7208
- spoken, essentially it will parrot the input. If false, we will not produce
7209
- audio for the target language. */
7417
+ /** Optional. If true, the model will generate audio when the target language is spoken, essentially it will parrot the input. If false, we will not produce audio for the target language. */
7210
7418
  echoTargetLanguage?: boolean;
7211
- /** The target language for translation. Supported values are BCP-47
7212
- language codes (e.g. "en", "es", "fr"). */
7419
+ /** Required. The target language for translation. Supported values are BCP-47 language codes (e.g. "en", "es", "fr"). */
7213
7420
  targetLanguageCode?: string;
7214
7421
  }
7215
7422
 
@@ -7277,6 +7484,8 @@ declare interface TuningDataStats {
7277
7484
  preferenceOptimizationDataStats?: PreferenceOptimizationDataStats;
7278
7485
  /** The SFT Tuning data stats. */
7279
7486
  supervisedTuningDataStats?: SupervisedTuningDataStats;
7487
+ /** Output only. Statistics for reinforcement tuning. */
7488
+ reinforcementTuningDataStats?: DatasetStats;
7280
7489
  }
7281
7490
 
7282
7491
  /** A single example for tuning. This data type is not supported in Vertex AI. */
@@ -7319,6 +7528,7 @@ declare interface TuningJob {
7319
7528
  preferenceOptimizationSpec?: PreferenceOptimizationSpec;
7320
7529
  /** Tuning Spec for Distillation. */
7321
7530
  distillationSpec?: DistillationSpec;
7531
+ /** Tuning Spec for Reinforcement Tuning. */
7322
7532
  reinforcementTuningSpec?: ReinforcementTuningSpec;
7323
7533
  /** Output only. The tuning data statistics associated with this TuningJob. */
7324
7534
  tuningDataStats?: TuningDataStats;
@@ -7698,8 +7908,14 @@ declare namespace types {
7698
7908
  ModelStage,
7699
7909
  MediaResolution,
7700
7910
  Modality,
7911
+ Delivery,
7912
+ AspectRatio,
7913
+ ImageSize,
7701
7914
  TuningMode,
7702
7915
  AdapterSize,
7916
+ ResponseParseType,
7917
+ MatchOperation,
7918
+ ReinforcementTuningThinkingLevel,
7703
7919
  JobState,
7704
7920
  TuningJobState,
7705
7921
  AggregationMetric,
@@ -7725,9 +7941,6 @@ declare namespace types {
7725
7941
  VideoGenerationMaskMode,
7726
7942
  VideoCompressionQuality,
7727
7943
  ImageResizeMode,
7728
- ResponseParseType,
7729
- MatchOperation,
7730
- ReinforcementTuningThinkingLevel,
7731
7944
  TuningMethod,
7732
7945
  FileState,
7733
7946
  FileSource,
@@ -7800,7 +8013,9 @@ declare namespace types {
7800
8013
  UrlContext,
7801
8014
  StreamableHttpTransport,
7802
8015
  McpServer,
8016
+ ToolExaAiSearch,
7803
8017
  Tool,
8018
+ VoiceConsentSignature,
7804
8019
  ReplicatedVoiceConfig,
7805
8020
  PrebuiltVoiceConfig,
7806
8021
  VoiceConfig,
@@ -7905,6 +8120,12 @@ declare namespace types {
7905
8120
  DeleteModelConfig,
7906
8121
  DeleteModelParameters,
7907
8122
  DeleteModelResponse,
8123
+ AudioResponseFormat,
8124
+ ImageResponseFormat,
8125
+ TextResponseFormat,
8126
+ VideoResponseFormat,
8127
+ ResponseFormat,
8128
+ TranslationConfig,
7908
8129
  GenerationConfig,
7909
8130
  CountTokensConfig,
7910
8131
  CountTokensParameters,
@@ -7954,6 +8175,8 @@ declare namespace types {
7954
8175
  PreTunedModel,
7955
8176
  DatasetDistributionDistributionBucket,
7956
8177
  DatasetDistribution,
8178
+ ReinforcementTuningExample,
8179
+ ReinforcementTuningUserDatasetExamples,
7957
8180
  DatasetStats,
7958
8181
  DistillationDataStats,
7959
8182
  GeminiPreferenceExampleCompletion,
@@ -7999,7 +8222,6 @@ declare namespace types {
7999
8222
  CreateTuningJobConfig,
8000
8223
  CreateTuningJobParametersPrivate,
8001
8224
  TuningOperation,
8002
- ReinforcementTuningExample,
8003
8225
  ValidateRewardConfig,
8004
8226
  ValidateRewardParameters,
8005
8227
  ReinforcementTuningRewardInfo,
@@ -8134,6 +8356,7 @@ declare namespace types {
8134
8356
  LanguageHints,
8135
8357
  AudioTranscriptionConfig,
8136
8358
  ProactivityConfig,
8359
+ HistoryConfig,
8137
8360
  CustomizedAvatar,
8138
8361
  AvatarConfig,
8139
8362
  LiveClientSetup,
@@ -8143,7 +8366,6 @@ declare namespace types {
8143
8366
  LiveClientRealtimeInput,
8144
8367
  LiveClientToolResponse,
8145
8368
  LiveClientMessage,
8146
- TranslationConfig,
8147
8369
  LiveConnectConfig,
8148
8370
  LiveConnectParameters,
8149
8371
  CreateChatParameters,
@@ -8781,6 +9003,18 @@ declare enum VideoOrientation {
8781
9003
  PORTRAIT = "PORTRAIT"
8782
9004
  }
8783
9005
 
9006
+ /** Configuration for video-specific output formatting. This data type is not supported in Gemini API. */
9007
+ declare class VideoResponseFormat {
9008
+ /** The aspect ratio for the video output. */
9009
+ aspectRatio?: AspectRatio;
9010
+ /** Optional. Delivery mode for the generated content. */
9011
+ delivery?: Delivery;
9012
+ /** Optional. The duration for the video output. */
9013
+ duration?: string;
9014
+ /** Optional. The Google Cloud Storage URI to store the video output. Required for Vertex if delivery is URI. */
9015
+ gcsUri?: string;
9016
+ }
9017
+
8784
9018
  /** Voice activity signal. */
8785
9019
  declare interface VoiceActivity {
8786
9020
  /** The type of the voice activity signal. */
@@ -8820,6 +9054,13 @@ declare interface VoiceConfig {
8820
9054
  prebuiltVoiceConfig?: PrebuiltVoiceConfig;
8821
9055
  }
8822
9056
 
9057
+ /** The signature of the voice consent check. */
9058
+ declare interface VoiceConsentSignature {
9059
+ /** The signature string.
9060
+ */
9061
+ signature?: string;
9062
+ }
9063
+
8823
9064
  /** Configuration for webhook notifications.
8824
9065
 
8825
9066
  Used to configure webhook endpoints that will receive notifications