google-apis-firebaseml_v2beta 0.33.0 → 0.35.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.
|
@@ -314,20 +314,21 @@ module Google
|
|
|
314
314
|
end
|
|
315
315
|
end
|
|
316
316
|
|
|
317
|
-
#
|
|
317
|
+
# A content blob. A Blob contains data of a specific media type. It is used to
|
|
318
|
+
# represent images, audio, and video.
|
|
318
319
|
class GoogleCloudAiplatformV1beta1Blob
|
|
319
320
|
include Google::Apis::Core::Hashable
|
|
320
321
|
|
|
321
|
-
# Required.
|
|
322
|
+
# Required. The raw bytes of the data.
|
|
322
323
|
# Corresponds to the JSON property `data`
|
|
323
324
|
# NOTE: Values are automatically base64 encoded/decoded in the client library.
|
|
324
325
|
# @return [String]
|
|
325
326
|
attr_accessor :data
|
|
326
327
|
|
|
327
|
-
# Optional.
|
|
328
|
-
# distinguish blobs. This field is only returned in PromptMessage for prompt
|
|
329
|
-
# management. It is
|
|
330
|
-
#
|
|
328
|
+
# Optional. The display name of the blob. Used to provide a label or filename to
|
|
329
|
+
# distinguish blobs. This field is only returned in `PromptMessage` for prompt
|
|
330
|
+
# management. It is used in the Gemini calls only when server-side tools (`
|
|
331
|
+
# code_execution`, `google_search`, and `url_context`) are enabled.
|
|
331
332
|
# Corresponds to the JSON property `displayName`
|
|
332
333
|
# @return [String]
|
|
333
334
|
attr_accessor :display_name
|
|
@@ -353,58 +354,70 @@ module Google
|
|
|
353
354
|
class GoogleCloudAiplatformV1beta1Candidate
|
|
354
355
|
include Google::Apis::Core::Hashable
|
|
355
356
|
|
|
356
|
-
# Output only.
|
|
357
|
+
# Output only. The average log probability of the tokens in this candidate. This
|
|
358
|
+
# is a length-normalized score that can be used to compare the quality of
|
|
359
|
+
# candidates of different lengths. A higher average log probability suggests a
|
|
360
|
+
# more confident and coherent response.
|
|
357
361
|
# Corresponds to the JSON property `avgLogprobs`
|
|
358
362
|
# @return [Float]
|
|
359
363
|
attr_accessor :avg_logprobs
|
|
360
364
|
|
|
361
|
-
# A collection of
|
|
365
|
+
# A collection of citations that apply to a piece of generated content.
|
|
362
366
|
# Corresponds to the JSON property `citationMetadata`
|
|
363
367
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1CitationMetadata]
|
|
364
368
|
attr_accessor :citation_metadata
|
|
365
369
|
|
|
366
|
-
# The
|
|
367
|
-
#
|
|
368
|
-
#
|
|
369
|
-
# message turn.
|
|
370
|
+
# The structured data content of a message. A Content message contains a `role`
|
|
371
|
+
# field, which indicates the producer of the content, and a `parts` field, which
|
|
372
|
+
# contains the multi-part data of the message.
|
|
370
373
|
# Corresponds to the JSON property `content`
|
|
371
374
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Content]
|
|
372
375
|
attr_accessor :content
|
|
373
376
|
|
|
374
|
-
# Output only. Describes the reason the
|
|
375
|
-
# detail. This is only
|
|
377
|
+
# Output only. Describes the reason the model stopped generating tokens in more
|
|
378
|
+
# detail. This field is returned only when `finish_reason` is set.
|
|
376
379
|
# Corresponds to the JSON property `finishMessage`
|
|
377
380
|
# @return [String]
|
|
378
381
|
attr_accessor :finish_message
|
|
379
382
|
|
|
380
383
|
# Output only. The reason why the model stopped generating tokens. If empty, the
|
|
381
|
-
# model has not stopped generating
|
|
384
|
+
# model has not stopped generating.
|
|
382
385
|
# Corresponds to the JSON property `finishReason`
|
|
383
386
|
# @return [String]
|
|
384
387
|
attr_accessor :finish_reason
|
|
385
388
|
|
|
386
|
-
#
|
|
389
|
+
# Information about the sources that support the content of a response. When
|
|
390
|
+
# grounding is enabled, the model returns citations for claims in the response.
|
|
391
|
+
# This object contains the retrieved sources.
|
|
387
392
|
# Corresponds to the JSON property `groundingMetadata`
|
|
388
393
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GroundingMetadata]
|
|
389
394
|
attr_accessor :grounding_metadata
|
|
390
395
|
|
|
391
|
-
# Output only.
|
|
396
|
+
# Output only. The 0-based index of this candidate in the list of generated
|
|
397
|
+
# responses. This is useful for distinguishing between multiple candidates when `
|
|
398
|
+
# candidate_count` > 1.
|
|
392
399
|
# Corresponds to the JSON property `index`
|
|
393
400
|
# @return [Fixnum]
|
|
394
401
|
attr_accessor :index
|
|
395
402
|
|
|
396
|
-
#
|
|
403
|
+
# The log probabilities of the tokens generated by the model. This is useful for
|
|
404
|
+
# understanding the model's confidence in its predictions and for debugging. For
|
|
405
|
+
# example, you can use log probabilities to identify when the model is making a
|
|
406
|
+
# less confident prediction or to explore alternative responses that the model
|
|
407
|
+
# considered. A low log probability can also indicate that the model is "
|
|
408
|
+
# hallucinating" or generating factually incorrect information.
|
|
397
409
|
# Corresponds to the JSON property `logprobsResult`
|
|
398
410
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1LogprobsResult]
|
|
399
411
|
attr_accessor :logprobs_result
|
|
400
412
|
|
|
401
|
-
# Output only.
|
|
402
|
-
# at most one rating per category.
|
|
413
|
+
# Output only. A list of ratings for the safety of a response candidate. There
|
|
414
|
+
# is at most one rating per category.
|
|
403
415
|
# Corresponds to the JSON property `safetyRatings`
|
|
404
416
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1SafetyRating>]
|
|
405
417
|
attr_accessor :safety_ratings
|
|
406
418
|
|
|
407
|
-
# Metadata
|
|
419
|
+
# Metadata returned when the model uses the `url_context` tool to get
|
|
420
|
+
# information from a user-provided URL.
|
|
408
421
|
# Corresponds to the JSON property `urlContextMetadata`
|
|
409
422
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1UrlContextMetadata]
|
|
410
423
|
attr_accessor :url_context_metadata
|
|
@@ -428,16 +441,16 @@ module Google
|
|
|
428
441
|
end
|
|
429
442
|
end
|
|
430
443
|
|
|
431
|
-
#
|
|
444
|
+
# A citation for a piece of generatedcontent.
|
|
432
445
|
class GoogleCloudAiplatformV1beta1Citation
|
|
433
446
|
include Google::Apis::Core::Hashable
|
|
434
447
|
|
|
435
|
-
# Output only.
|
|
448
|
+
# Output only. The end index of the citation in the content.
|
|
436
449
|
# Corresponds to the JSON property `endIndex`
|
|
437
450
|
# @return [Fixnum]
|
|
438
451
|
attr_accessor :end_index
|
|
439
452
|
|
|
440
|
-
# Output only.
|
|
453
|
+
# Output only. The license of the source of the citation.
|
|
441
454
|
# Corresponds to the JSON property `license`
|
|
442
455
|
# @return [String]
|
|
443
456
|
attr_accessor :license
|
|
@@ -454,17 +467,17 @@ module Google
|
|
|
454
467
|
# @return [Google::Apis::FirebasemlV2beta::Date]
|
|
455
468
|
attr_accessor :publication_date
|
|
456
469
|
|
|
457
|
-
# Output only.
|
|
470
|
+
# Output only. The start index of the citation in the content.
|
|
458
471
|
# Corresponds to the JSON property `startIndex`
|
|
459
472
|
# @return [Fixnum]
|
|
460
473
|
attr_accessor :start_index
|
|
461
474
|
|
|
462
|
-
# Output only.
|
|
475
|
+
# Output only. The title of the source of the citation.
|
|
463
476
|
# Corresponds to the JSON property `title`
|
|
464
477
|
# @return [String]
|
|
465
478
|
attr_accessor :title
|
|
466
479
|
|
|
467
|
-
# Output only.
|
|
480
|
+
# Output only. The URI of the source of the citation.
|
|
468
481
|
# Corresponds to the JSON property `uri`
|
|
469
482
|
# @return [String]
|
|
470
483
|
attr_accessor :uri
|
|
@@ -484,11 +497,11 @@ module Google
|
|
|
484
497
|
end
|
|
485
498
|
end
|
|
486
499
|
|
|
487
|
-
# A collection of
|
|
500
|
+
# A collection of citations that apply to a piece of generated content.
|
|
488
501
|
class GoogleCloudAiplatformV1beta1CitationMetadata
|
|
489
502
|
include Google::Apis::Core::Hashable
|
|
490
503
|
|
|
491
|
-
# Output only.
|
|
504
|
+
# Output only. A list of citations for the content.
|
|
492
505
|
# Corresponds to the JSON property `citations`
|
|
493
506
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Citation>]
|
|
494
507
|
attr_accessor :citations
|
|
@@ -531,22 +544,21 @@ module Google
|
|
|
531
544
|
end
|
|
532
545
|
end
|
|
533
546
|
|
|
534
|
-
# The
|
|
535
|
-
#
|
|
536
|
-
#
|
|
537
|
-
# message turn.
|
|
547
|
+
# The structured data content of a message. A Content message contains a `role`
|
|
548
|
+
# field, which indicates the producer of the content, and a `parts` field, which
|
|
549
|
+
# contains the multi-part data of the message.
|
|
538
550
|
class GoogleCloudAiplatformV1beta1Content
|
|
539
551
|
include Google::Apis::Core::Hashable
|
|
540
552
|
|
|
541
|
-
# Required.
|
|
542
|
-
# different
|
|
553
|
+
# Required. A list of Part objects that make up a single message. Parts of a
|
|
554
|
+
# message can have different MIME types. A Content message must have at least
|
|
555
|
+
# one Part.
|
|
543
556
|
# Corresponds to the JSON property `parts`
|
|
544
557
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Part>]
|
|
545
558
|
attr_accessor :parts
|
|
546
559
|
|
|
547
|
-
# Optional. The producer of the content. Must be either 'user' or 'model'.
|
|
548
|
-
#
|
|
549
|
-
# unset.
|
|
560
|
+
# Optional. The producer of the content. Must be either 'user' or 'model'. If
|
|
561
|
+
# not set, the service will default to 'user'.
|
|
550
562
|
# Corresponds to the JSON property `role`
|
|
551
563
|
# @return [String]
|
|
552
564
|
attr_accessor :role
|
|
@@ -571,7 +583,9 @@ module Google
|
|
|
571
583
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Content>]
|
|
572
584
|
attr_accessor :contents
|
|
573
585
|
|
|
574
|
-
#
|
|
586
|
+
# Configuration for content generation. This message contains all the parameters
|
|
587
|
+
# that control how the model generates content. It allows you to influence the
|
|
588
|
+
# randomness, length, and structure of the output.
|
|
575
589
|
# Corresponds to the JSON property `generationConfig`
|
|
576
590
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GenerationConfig]
|
|
577
591
|
attr_accessor :generation_config
|
|
@@ -588,10 +602,9 @@ module Google
|
|
|
588
602
|
# @return [String]
|
|
589
603
|
attr_accessor :model
|
|
590
604
|
|
|
591
|
-
# The
|
|
592
|
-
#
|
|
593
|
-
#
|
|
594
|
-
# message turn.
|
|
605
|
+
# The structured data content of a message. A Content message contains a `role`
|
|
606
|
+
# field, which indicates the producer of the content, and a `parts` field, which
|
|
607
|
+
# contains the multi-part data of the message.
|
|
595
608
|
# Corresponds to the JSON property `systemInstruction`
|
|
596
609
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Content]
|
|
597
610
|
attr_accessor :system_instruction
|
|
@@ -831,20 +844,21 @@ module Google
|
|
|
831
844
|
end
|
|
832
845
|
end
|
|
833
846
|
|
|
834
|
-
# URI
|
|
847
|
+
# URI-based data. A FileData message contains a URI pointing to data of a
|
|
848
|
+
# specific media type. It is used to represent images, audio, and video stored
|
|
849
|
+
# in Google Cloud Storage.
|
|
835
850
|
class GoogleCloudAiplatformV1beta1FileData
|
|
836
851
|
include Google::Apis::Core::Hashable
|
|
837
852
|
|
|
838
|
-
# Optional.
|
|
839
|
-
#
|
|
840
|
-
#
|
|
841
|
-
#
|
|
842
|
-
# are enabled.
|
|
853
|
+
# Optional. The display name of the file. Used to provide a label or filename to
|
|
854
|
+
# distinguish files. This field is only returned in `PromptMessage` for prompt
|
|
855
|
+
# management. It is used in the Gemini calls only when server side tools (`
|
|
856
|
+
# code_execution`, `google_search`, and `url_context`) are enabled.
|
|
843
857
|
# Corresponds to the JSON property `displayName`
|
|
844
858
|
# @return [String]
|
|
845
859
|
attr_accessor :display_name
|
|
846
860
|
|
|
847
|
-
# Required. URI.
|
|
861
|
+
# Required. The URI of the file in Google Cloud Storage.
|
|
848
862
|
# Corresponds to the JSON property `fileUri`
|
|
849
863
|
# @return [String]
|
|
850
864
|
attr_accessor :file_uri
|
|
@@ -1163,7 +1177,9 @@ module Google
|
|
|
1163
1177
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Content>]
|
|
1164
1178
|
attr_accessor :contents
|
|
1165
1179
|
|
|
1166
|
-
#
|
|
1180
|
+
# Configuration for content generation. This message contains all the parameters
|
|
1181
|
+
# that control how the model generates content. It allows you to influence the
|
|
1182
|
+
# randomness, length, and structure of the output.
|
|
1167
1183
|
# Corresponds to the JSON property `generationConfig`
|
|
1168
1184
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GenerationConfig]
|
|
1169
1185
|
attr_accessor :generation_config
|
|
@@ -1177,7 +1193,10 @@ module Google
|
|
|
1177
1193
|
# @return [Hash<String,String>]
|
|
1178
1194
|
attr_accessor :labels
|
|
1179
1195
|
|
|
1180
|
-
# Configuration for Model Armor
|
|
1196
|
+
# Configuration for Model Armor. Model Armor is a Google Cloud service that
|
|
1197
|
+
# provides safety and security filtering for prompts and responses. It helps
|
|
1198
|
+
# protect your AI applications from risks such as harmful content, sensitive
|
|
1199
|
+
# data leakage, and prompt injection attacks.
|
|
1181
1200
|
# Corresponds to the JSON property `modelArmorConfig`
|
|
1182
1201
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1ModelArmorConfig]
|
|
1183
1202
|
attr_accessor :model_armor_config
|
|
@@ -1188,10 +1207,9 @@ module Google
|
|
|
1188
1207
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1SafetySetting>]
|
|
1189
1208
|
attr_accessor :safety_settings
|
|
1190
1209
|
|
|
1191
|
-
# The
|
|
1192
|
-
#
|
|
1193
|
-
#
|
|
1194
|
-
# message turn.
|
|
1210
|
+
# The structured data content of a message. A Content message contains a `role`
|
|
1211
|
+
# field, which indicates the producer of the content, and a `parts` field, which
|
|
1212
|
+
# contains the multi-part data of the message.
|
|
1195
1213
|
# Corresponds to the JSON property `systemInstruction`
|
|
1196
1214
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Content]
|
|
1197
1215
|
attr_accessor :system_instruction
|
|
@@ -1406,50 +1424,72 @@ module Google
|
|
|
1406
1424
|
end
|
|
1407
1425
|
end
|
|
1408
1426
|
|
|
1409
|
-
#
|
|
1427
|
+
# Configuration for content generation. This message contains all the parameters
|
|
1428
|
+
# that control how the model generates content. It allows you to influence the
|
|
1429
|
+
# randomness, length, and structure of the output.
|
|
1410
1430
|
class GoogleCloudAiplatformV1beta1GenerationConfig
|
|
1411
1431
|
include Google::Apis::Core::Hashable
|
|
1412
1432
|
|
|
1413
|
-
# Optional. If enabled, audio
|
|
1414
|
-
# model.
|
|
1433
|
+
# Optional. If enabled, audio timestamps will be included in the request to the
|
|
1434
|
+
# model. This can be useful for synchronizing audio with other modalities in the
|
|
1435
|
+
# response.
|
|
1415
1436
|
# Corresponds to the JSON property `audioTimestamp`
|
|
1416
1437
|
# @return [Boolean]
|
|
1417
1438
|
attr_accessor :audio_timestamp
|
|
1418
1439
|
alias_method :audio_timestamp?, :audio_timestamp
|
|
1419
1440
|
|
|
1420
|
-
# Optional.
|
|
1441
|
+
# Optional. The number of candidate responses to generate. A higher `
|
|
1442
|
+
# candidate_count` can provide more options to choose from, but it also consumes
|
|
1443
|
+
# more resources. This can be useful for generating a variety of responses and
|
|
1444
|
+
# selecting the best one.
|
|
1421
1445
|
# Corresponds to the JSON property `candidateCount`
|
|
1422
1446
|
# @return [Fixnum]
|
|
1423
1447
|
attr_accessor :candidate_count
|
|
1424
1448
|
|
|
1425
1449
|
# Optional. If enabled, the model will detect emotions and adapt its responses
|
|
1426
|
-
# accordingly.
|
|
1450
|
+
# accordingly. For example, if the model detects that the user is frustrated, it
|
|
1451
|
+
# may provide a more empathetic response.
|
|
1427
1452
|
# Corresponds to the JSON property `enableAffectiveDialog`
|
|
1428
1453
|
# @return [Boolean]
|
|
1429
1454
|
attr_accessor :enable_affective_dialog
|
|
1430
1455
|
alias_method :enable_affective_dialog?, :enable_affective_dialog
|
|
1431
1456
|
|
|
1432
|
-
# Optional.
|
|
1457
|
+
# Optional. Penalizes tokens based on their frequency in the generated text. A
|
|
1458
|
+
# positive value helps to reduce the repetition of words and phrases. Valid
|
|
1459
|
+
# values can range from [-2.0, 2.0].
|
|
1433
1460
|
# Corresponds to the JSON property `frequencyPenalty`
|
|
1434
1461
|
# @return [Float]
|
|
1435
1462
|
attr_accessor :frequency_penalty
|
|
1436
1463
|
|
|
1437
|
-
#
|
|
1464
|
+
# Configuration for image generation. This message allows you to control various
|
|
1465
|
+
# aspects of image generation, such as the output format, aspect ratio, and
|
|
1466
|
+
# whether the model can generate images of people.
|
|
1438
1467
|
# Corresponds to the JSON property `imageConfig`
|
|
1439
1468
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1ImageConfig]
|
|
1440
1469
|
attr_accessor :image_config
|
|
1441
1470
|
|
|
1442
|
-
# Optional.
|
|
1471
|
+
# Optional. The number of top log probabilities to return for each token. This
|
|
1472
|
+
# can be used to see which other tokens were considered likely candidates for a
|
|
1473
|
+
# given position. A higher value will return more options, but it will also
|
|
1474
|
+
# increase the size of the response.
|
|
1443
1475
|
# Corresponds to the JSON property `logprobs`
|
|
1444
1476
|
# @return [Fixnum]
|
|
1445
1477
|
attr_accessor :logprobs
|
|
1446
1478
|
|
|
1447
|
-
# Optional. The maximum number of
|
|
1479
|
+
# Optional. The maximum number of tokens to generate in the response. A token is
|
|
1480
|
+
# approximately four characters. The default value varies by model. This
|
|
1481
|
+
# parameter can be used to control the length of the generated text and prevent
|
|
1482
|
+
# overly long responses.
|
|
1448
1483
|
# Corresponds to the JSON property `maxOutputTokens`
|
|
1449
1484
|
# @return [Fixnum]
|
|
1450
1485
|
attr_accessor :max_output_tokens
|
|
1451
1486
|
|
|
1452
|
-
# Optional.
|
|
1487
|
+
# Optional. The token resolution at which input media content is sampled. This
|
|
1488
|
+
# is used to control the trade-off between the quality of the response and the
|
|
1489
|
+
# number of tokens used to represent the media. A higher resolution allows the
|
|
1490
|
+
# model to perceive more detail, which can lead to a more nuanced response, but
|
|
1491
|
+
# it will also use more tokens. This does not affect the image dimensions sent
|
|
1492
|
+
# to the model.
|
|
1453
1493
|
# Corresponds to the JSON property `mediaResolution`
|
|
1454
1494
|
# @return [String]
|
|
1455
1495
|
attr_accessor :media_resolution
|
|
@@ -1459,44 +1499,41 @@ module Google
|
|
|
1459
1499
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GenerationConfigModelConfig]
|
|
1460
1500
|
attr_accessor :model_config
|
|
1461
1501
|
|
|
1462
|
-
# Optional.
|
|
1502
|
+
# Optional. Penalizes tokens that have already appeared in the generated text. A
|
|
1503
|
+
# positive value encourages the model to generate more diverse and less
|
|
1504
|
+
# repetitive text. Valid values can range from [-2.0, 2.0].
|
|
1463
1505
|
# Corresponds to the JSON property `presencePenalty`
|
|
1464
1506
|
# @return [Float]
|
|
1465
1507
|
attr_accessor :presence_penalty
|
|
1466
1508
|
|
|
1467
|
-
# Optional.
|
|
1468
|
-
#
|
|
1469
|
-
# `response_schema` must be omitted, but `response_mime_type` is required. While
|
|
1470
|
-
# the full JSON Schema may be sent, not all features are supported. Specifically,
|
|
1471
|
-
# only the following properties are supported: - `$id` - `$defs` - `$ref` - `$
|
|
1472
|
-
# anchor` - `type` - `format` - `title` - `description` - `enum` (for strings
|
|
1473
|
-
# and numbers) - `items` - `prefixItems` - `minItems` - `maxItems` - `minimum` -
|
|
1474
|
-
# `maximum` - `anyOf` - `oneOf` (interpreted the same as `anyOf`) - `properties`
|
|
1475
|
-
# - `additionalProperties` - `required` The non-standard `propertyOrdering`
|
|
1476
|
-
# property may also be set. Cyclic references are unrolled to a limited degree
|
|
1477
|
-
# and, as such, may only be used within non-required properties. (Nullable
|
|
1478
|
-
# properties are not sufficient.) If `$ref` is set on a sub-schema, no other
|
|
1479
|
-
# properties, except for than those starting as a `$`, may be set.
|
|
1509
|
+
# Optional. When this field is set, response_schema must be omitted and
|
|
1510
|
+
# response_mime_type must be set to `application/json`.
|
|
1480
1511
|
# Corresponds to the JSON property `responseJsonSchema`
|
|
1481
1512
|
# @return [Object]
|
|
1482
1513
|
attr_accessor :response_json_schema
|
|
1483
1514
|
|
|
1484
|
-
# Optional. If true,
|
|
1515
|
+
# Optional. If set to true, the log probabilities of the output tokens are
|
|
1516
|
+
# returned. Log probabilities are the logarithm of the probability of a token
|
|
1517
|
+
# appearing in the output. A higher log probability means the token is more
|
|
1518
|
+
# likely to be generated. This can be useful for analyzing the model's
|
|
1519
|
+
# confidence in its own output and for debugging.
|
|
1485
1520
|
# Corresponds to the JSON property `responseLogprobs`
|
|
1486
1521
|
# @return [Boolean]
|
|
1487
1522
|
attr_accessor :response_logprobs
|
|
1488
1523
|
alias_method :response_logprobs?, :response_logprobs
|
|
1489
1524
|
|
|
1490
|
-
# Optional.
|
|
1491
|
-
#
|
|
1492
|
-
#
|
|
1525
|
+
# Optional. The IANA standard MIME type of the response. The model will generate
|
|
1526
|
+
# output that conforms to this MIME type. Supported values include 'text/plain' (
|
|
1527
|
+
# default) and 'application/json'. The model needs to be prompted to output the
|
|
1493
1528
|
# appropriate response type, otherwise the behavior is undefined. This is a
|
|
1494
1529
|
# preview feature.
|
|
1495
1530
|
# Corresponds to the JSON property `responseMimeType`
|
|
1496
1531
|
# @return [String]
|
|
1497
1532
|
attr_accessor :response_mime_type
|
|
1498
1533
|
|
|
1499
|
-
# Optional. The modalities of the response.
|
|
1534
|
+
# Optional. The modalities of the response. The model will generate a response
|
|
1535
|
+
# that includes all the specified modalities. For example, if this is set to `[
|
|
1536
|
+
# TEXT, IMAGE]`, the response will include both text and an image.
|
|
1500
1537
|
# Corresponds to the JSON property `responseModalities`
|
|
1501
1538
|
# @return [Array<String>]
|
|
1502
1539
|
attr_accessor :response_modalities
|
|
@@ -1508,42 +1545,68 @@ module Google
|
|
|
1508
1545
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Schema]
|
|
1509
1546
|
attr_accessor :response_schema
|
|
1510
1547
|
|
|
1511
|
-
# The configuration for routing the request to a specific model.
|
|
1548
|
+
# The configuration for routing the request to a specific model. This can be
|
|
1549
|
+
# used to control which model is used for the generation, either automatically
|
|
1550
|
+
# or by specifying a model name.
|
|
1512
1551
|
# Corresponds to the JSON property `routingConfig`
|
|
1513
1552
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GenerationConfigRoutingConfig]
|
|
1514
1553
|
attr_accessor :routing_config
|
|
1515
1554
|
|
|
1516
|
-
# Optional.
|
|
1555
|
+
# Optional. A seed for the random number generator. By setting a seed, you can
|
|
1556
|
+
# make the model's output mostly deterministic. For a given prompt and
|
|
1557
|
+
# parameters (like temperature, top_p, etc.), the model will produce the same
|
|
1558
|
+
# response every time. However, it's not a guaranteed absolute deterministic
|
|
1559
|
+
# behavior. This is different from parameters like `temperature`, which control
|
|
1560
|
+
# the *level* of randomness. `seed` ensures that the "random" choices the model
|
|
1561
|
+
# makes are the same on every run, making it essential for testing and ensuring
|
|
1562
|
+
# reproducible results.
|
|
1517
1563
|
# Corresponds to the JSON property `seed`
|
|
1518
1564
|
# @return [Fixnum]
|
|
1519
1565
|
attr_accessor :seed
|
|
1520
1566
|
|
|
1521
|
-
#
|
|
1567
|
+
# Configuration for speech generation.
|
|
1522
1568
|
# Corresponds to the JSON property `speechConfig`
|
|
1523
1569
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1SpeechConfig]
|
|
1524
1570
|
attr_accessor :speech_config
|
|
1525
1571
|
|
|
1526
|
-
# Optional.
|
|
1572
|
+
# Optional. A list of character sequences that will stop the model from
|
|
1573
|
+
# generating further tokens. If a stop sequence is generated, the output will
|
|
1574
|
+
# end at that point. This is useful for controlling the length and structure of
|
|
1575
|
+
# the output. For example, you can use ["\n", "###"] to stop generation at a new
|
|
1576
|
+
# line or a specific marker.
|
|
1527
1577
|
# Corresponds to the JSON property `stopSequences`
|
|
1528
1578
|
# @return [Array<String>]
|
|
1529
1579
|
attr_accessor :stop_sequences
|
|
1530
1580
|
|
|
1531
|
-
# Optional. Controls the randomness of
|
|
1581
|
+
# Optional. Controls the randomness of the output. A higher temperature results
|
|
1582
|
+
# in more creative and diverse responses, while a lower temperature makes the
|
|
1583
|
+
# output more predictable and focused. The valid range is (0.0, 2.0].
|
|
1532
1584
|
# Corresponds to the JSON property `temperature`
|
|
1533
1585
|
# @return [Float]
|
|
1534
1586
|
attr_accessor :temperature
|
|
1535
1587
|
|
|
1536
|
-
#
|
|
1588
|
+
# Configuration for the model's thinking features. "Thinking" is a process where
|
|
1589
|
+
# the model breaks down a complex task into smaller, manageable steps. This
|
|
1590
|
+
# allows the model to reason about the task, plan its approach, and execute the
|
|
1591
|
+
# plan to generate a high-quality response.
|
|
1537
1592
|
# Corresponds to the JSON property `thinkingConfig`
|
|
1538
1593
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GenerationConfigThinkingConfig]
|
|
1539
1594
|
attr_accessor :thinking_config
|
|
1540
1595
|
|
|
1541
|
-
# Optional.
|
|
1596
|
+
# Optional. Specifies the top-k sampling threshold. The model considers only the
|
|
1597
|
+
# top k most probable tokens for the next token. This can be useful for
|
|
1598
|
+
# generating more coherent and less random text. For example, a `top_k` of 40
|
|
1599
|
+
# means the model will choose the next word from the 40 most likely words.
|
|
1542
1600
|
# Corresponds to the JSON property `topK`
|
|
1543
1601
|
# @return [Float]
|
|
1544
1602
|
attr_accessor :top_k
|
|
1545
1603
|
|
|
1546
|
-
# Optional.
|
|
1604
|
+
# Optional. Specifies the nucleus sampling threshold. The model considers only
|
|
1605
|
+
# the smallest set of tokens whose cumulative probability is at least `top_p`.
|
|
1606
|
+
# This helps generate more diverse and less repetitive responses. For example, a
|
|
1607
|
+
# `top_p` of 0.9 means the model considers tokens until the cumulative
|
|
1608
|
+
# probability of the tokens to select from reaches 0.9. It's recommended to
|
|
1609
|
+
# adjust either temperature or `top_p`, but not both.
|
|
1547
1610
|
# Corresponds to the JSON property `topP`
|
|
1548
1611
|
# @return [Float]
|
|
1549
1612
|
attr_accessor :top_p
|
|
@@ -1599,17 +1662,21 @@ module Google
|
|
|
1599
1662
|
end
|
|
1600
1663
|
end
|
|
1601
1664
|
|
|
1602
|
-
# The configuration for routing the request to a specific model.
|
|
1665
|
+
# The configuration for routing the request to a specific model. This can be
|
|
1666
|
+
# used to control which model is used for the generation, either automatically
|
|
1667
|
+
# or by specifying a model name.
|
|
1603
1668
|
class GoogleCloudAiplatformV1beta1GenerationConfigRoutingConfig
|
|
1604
1669
|
include Google::Apis::Core::Hashable
|
|
1605
1670
|
|
|
1606
|
-
# When automated routing is specified,
|
|
1607
|
-
#
|
|
1671
|
+
# The configuration for automated routing. When automated routing is specified,
|
|
1672
|
+
# the routing will be determined by the pretrained routing model and customer
|
|
1673
|
+
# provided model routing preference.
|
|
1608
1674
|
# Corresponds to the JSON property `autoMode`
|
|
1609
1675
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GenerationConfigRoutingConfigAutoRoutingMode]
|
|
1610
1676
|
attr_accessor :auto_mode
|
|
1611
1677
|
|
|
1612
|
-
# When manual routing is
|
|
1678
|
+
# The configuration for manual routing. When manual routing is specified, the
|
|
1679
|
+
# model will be selected based on the model name provided.
|
|
1613
1680
|
# Corresponds to the JSON property `manualMode`
|
|
1614
1681
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GenerationConfigRoutingConfigManualRoutingMode]
|
|
1615
1682
|
attr_accessor :manual_mode
|
|
@@ -1625,8 +1692,9 @@ module Google
|
|
|
1625
1692
|
end
|
|
1626
1693
|
end
|
|
1627
1694
|
|
|
1628
|
-
# When automated routing is specified,
|
|
1629
|
-
#
|
|
1695
|
+
# The configuration for automated routing. When automated routing is specified,
|
|
1696
|
+
# the routing will be determined by the pretrained routing model and customer
|
|
1697
|
+
# provided model routing preference.
|
|
1630
1698
|
class GoogleCloudAiplatformV1beta1GenerationConfigRoutingConfigAutoRoutingMode
|
|
1631
1699
|
include Google::Apis::Core::Hashable
|
|
1632
1700
|
|
|
@@ -1645,13 +1713,12 @@ module Google
|
|
|
1645
1713
|
end
|
|
1646
1714
|
end
|
|
1647
1715
|
|
|
1648
|
-
# When manual routing is
|
|
1716
|
+
# The configuration for manual routing. When manual routing is specified, the
|
|
1717
|
+
# model will be selected based on the model name provided.
|
|
1649
1718
|
class GoogleCloudAiplatformV1beta1GenerationConfigRoutingConfigManualRoutingMode
|
|
1650
1719
|
include Google::Apis::Core::Hashable
|
|
1651
1720
|
|
|
1652
|
-
# The model
|
|
1653
|
-
# models](https://cloud.google.com/vertex-ai/generative-ai/docs/model-reference/
|
|
1654
|
-
# inference#supported-models).
|
|
1721
|
+
# The name of the model to use. Only public LLM models are accepted.
|
|
1655
1722
|
# Corresponds to the JSON property `modelName`
|
|
1656
1723
|
# @return [String]
|
|
1657
1724
|
attr_accessor :model_name
|
|
@@ -1666,18 +1733,26 @@ module Google
|
|
|
1666
1733
|
end
|
|
1667
1734
|
end
|
|
1668
1735
|
|
|
1669
|
-
#
|
|
1736
|
+
# Configuration for the model's thinking features. "Thinking" is a process where
|
|
1737
|
+
# the model breaks down a complex task into smaller, manageable steps. This
|
|
1738
|
+
# allows the model to reason about the task, plan its approach, and execute the
|
|
1739
|
+
# plan to generate a high-quality response.
|
|
1670
1740
|
class GoogleCloudAiplatformV1beta1GenerationConfigThinkingConfig
|
|
1671
1741
|
include Google::Apis::Core::Hashable
|
|
1672
1742
|
|
|
1673
|
-
# Optional.
|
|
1674
|
-
#
|
|
1743
|
+
# Optional. If true, the model will include its thoughts in the response. "
|
|
1744
|
+
# Thoughts" are the intermediate steps the model takes to arrive at the final
|
|
1745
|
+
# response. They can provide insights into the model's reasoning process and
|
|
1746
|
+
# help with debugging. If this is true, thoughts are returned only when
|
|
1747
|
+
# available.
|
|
1675
1748
|
# Corresponds to the JSON property `includeThoughts`
|
|
1676
1749
|
# @return [Boolean]
|
|
1677
1750
|
attr_accessor :include_thoughts
|
|
1678
1751
|
alias_method :include_thoughts?, :include_thoughts
|
|
1679
1752
|
|
|
1680
|
-
# Optional.
|
|
1753
|
+
# Optional. The token budget for the model's thinking process. The model will
|
|
1754
|
+
# make a best effort to stay within this budget. This can be used to control the
|
|
1755
|
+
# trade-off between response quality and latency.
|
|
1681
1756
|
# Corresponds to the JSON property `thinkingBudget`
|
|
1682
1757
|
# @return [Fixnum]
|
|
1683
1758
|
attr_accessor :thinking_budget
|
|
@@ -1732,21 +1807,30 @@ module Google
|
|
|
1732
1807
|
end
|
|
1733
1808
|
end
|
|
1734
1809
|
|
|
1735
|
-
#
|
|
1810
|
+
# A piece of evidence that supports a claim made by the model. This is used to
|
|
1811
|
+
# show a citation for a claim made by the model. When grounding is enabled, the
|
|
1812
|
+
# model returns a `GroundingChunk` that contains a reference to the source of
|
|
1813
|
+
# the information.
|
|
1736
1814
|
class GoogleCloudAiplatformV1beta1GroundingChunk
|
|
1737
1815
|
include Google::Apis::Core::Hashable
|
|
1738
1816
|
|
|
1739
|
-
#
|
|
1817
|
+
# A `Maps` chunk is a piece of evidence that comes from Google Maps. It contains
|
|
1818
|
+
# information about a place, such as its name, address, and reviews. This is
|
|
1819
|
+
# used to provide the user with rich, location-based information.
|
|
1740
1820
|
# Corresponds to the JSON property `maps`
|
|
1741
1821
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GroundingChunkMaps]
|
|
1742
1822
|
attr_accessor :maps
|
|
1743
1823
|
|
|
1744
|
-
#
|
|
1824
|
+
# Context retrieved from a data source to ground the model's response. This is
|
|
1825
|
+
# used when a retrieval tool fetches information from a user-provided corpus or
|
|
1826
|
+
# a public dataset.
|
|
1745
1827
|
# Corresponds to the JSON property `retrievedContext`
|
|
1746
1828
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GroundingChunkRetrievedContext]
|
|
1747
1829
|
attr_accessor :retrieved_context
|
|
1748
1830
|
|
|
1749
|
-
#
|
|
1831
|
+
# A `Web` chunk is a piece of evidence that comes from a web page. It contains
|
|
1832
|
+
# the URI of the web page, the title of the page, and the domain of the page.
|
|
1833
|
+
# This is used to provide the user with a link to the source of the information.
|
|
1750
1834
|
# Corresponds to the JSON property `web`
|
|
1751
1835
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GroundingChunkWeb]
|
|
1752
1836
|
attr_accessor :web
|
|
@@ -1763,32 +1847,36 @@ module Google
|
|
|
1763
1847
|
end
|
|
1764
1848
|
end
|
|
1765
1849
|
|
|
1766
|
-
#
|
|
1850
|
+
# A `Maps` chunk is a piece of evidence that comes from Google Maps. It contains
|
|
1851
|
+
# information about a place, such as its name, address, and reviews. This is
|
|
1852
|
+
# used to provide the user with rich, location-based information.
|
|
1767
1853
|
class GoogleCloudAiplatformV1beta1GroundingChunkMaps
|
|
1768
1854
|
include Google::Apis::Core::Hashable
|
|
1769
1855
|
|
|
1770
|
-
#
|
|
1856
|
+
# The sources that were used to generate the place answer. This includes review
|
|
1857
|
+
# snippets and photos that were used to generate the answer, as well as URIs to
|
|
1858
|
+
# flag content.
|
|
1771
1859
|
# Corresponds to the JSON property `placeAnswerSources`
|
|
1772
1860
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources]
|
|
1773
1861
|
attr_accessor :place_answer_sources
|
|
1774
1862
|
|
|
1775
|
-
# This Place's resource name, in `places/`place_id`` format.
|
|
1776
|
-
# up the
|
|
1863
|
+
# This Place's resource name, in `places/`place_id`` format. This can be used to
|
|
1864
|
+
# look up the place in the Google Maps API.
|
|
1777
1865
|
# Corresponds to the JSON property `placeId`
|
|
1778
1866
|
# @return [String]
|
|
1779
1867
|
attr_accessor :place_id
|
|
1780
1868
|
|
|
1781
|
-
#
|
|
1869
|
+
# The text of the place answer.
|
|
1782
1870
|
# Corresponds to the JSON property `text`
|
|
1783
1871
|
# @return [String]
|
|
1784
1872
|
attr_accessor :text
|
|
1785
1873
|
|
|
1786
|
-
#
|
|
1874
|
+
# The title of the place.
|
|
1787
1875
|
# Corresponds to the JSON property `title`
|
|
1788
1876
|
# @return [String]
|
|
1789
1877
|
attr_accessor :title
|
|
1790
1878
|
|
|
1791
|
-
# URI
|
|
1879
|
+
# The URI of the place.
|
|
1792
1880
|
# Corresponds to the JSON property `uri`
|
|
1793
1881
|
# @return [String]
|
|
1794
1882
|
attr_accessor :uri
|
|
@@ -1807,11 +1895,13 @@ module Google
|
|
|
1807
1895
|
end
|
|
1808
1896
|
end
|
|
1809
1897
|
|
|
1810
|
-
#
|
|
1898
|
+
# The sources that were used to generate the place answer. This includes review
|
|
1899
|
+
# snippets and photos that were used to generate the answer, as well as URIs to
|
|
1900
|
+
# flag content.
|
|
1811
1901
|
class GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources
|
|
1812
1902
|
include Google::Apis::Core::Hashable
|
|
1813
1903
|
|
|
1814
|
-
# Snippets of reviews that
|
|
1904
|
+
# Snippets of reviews that were used to generate the answer.
|
|
1815
1905
|
# Corresponds to the JSON property `reviewSnippets`
|
|
1816
1906
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet>]
|
|
1817
1907
|
attr_accessor :review_snippets
|
|
@@ -1826,7 +1916,7 @@ module Google
|
|
|
1826
1916
|
end
|
|
1827
1917
|
end
|
|
1828
1918
|
|
|
1829
|
-
#
|
|
1919
|
+
# A review snippet that is used to generate the answer.
|
|
1830
1920
|
class GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet
|
|
1831
1921
|
include Google::Apis::Core::Hashable
|
|
1832
1922
|
|
|
@@ -1835,12 +1925,12 @@ module Google
|
|
|
1835
1925
|
# @return [String]
|
|
1836
1926
|
attr_accessor :google_maps_uri
|
|
1837
1927
|
|
|
1838
|
-
#
|
|
1928
|
+
# The ID of the review that is being referenced.
|
|
1839
1929
|
# Corresponds to the JSON property `reviewId`
|
|
1840
1930
|
# @return [String]
|
|
1841
1931
|
attr_accessor :review_id
|
|
1842
1932
|
|
|
1843
|
-
#
|
|
1933
|
+
# The title of the review.
|
|
1844
1934
|
# Corresponds to the JSON property `title`
|
|
1845
1935
|
# @return [String]
|
|
1846
1936
|
attr_accessor :title
|
|
@@ -1857,12 +1947,16 @@ module Google
|
|
|
1857
1947
|
end
|
|
1858
1948
|
end
|
|
1859
1949
|
|
|
1860
|
-
#
|
|
1950
|
+
# Context retrieved from a data source to ground the model's response. This is
|
|
1951
|
+
# used when a retrieval tool fetches information from a user-provided corpus or
|
|
1952
|
+
# a public dataset.
|
|
1861
1953
|
class GoogleCloudAiplatformV1beta1GroundingChunkRetrievedContext
|
|
1862
1954
|
include Google::Apis::Core::Hashable
|
|
1863
1955
|
|
|
1864
|
-
# Output only. The full
|
|
1865
|
-
# document.
|
|
1956
|
+
# Output only. The full resource name of the referenced Vertex AI Search
|
|
1957
|
+
# document. This is used to identify the specific document that was retrieved.
|
|
1958
|
+
# The format is `projects/`project`/locations/`location`/collections/`collection`
|
|
1959
|
+
# /dataStores/`data_store`/branches/`branch`/documents/`document``.
|
|
1866
1960
|
# Corresponds to the JSON property `documentName`
|
|
1867
1961
|
# @return [String]
|
|
1868
1962
|
attr_accessor :document_name
|
|
@@ -1873,17 +1967,17 @@ module Google
|
|
|
1873
1967
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1RagChunk]
|
|
1874
1968
|
attr_accessor :rag_chunk
|
|
1875
1969
|
|
|
1876
|
-
#
|
|
1970
|
+
# The content of the retrieved data source.
|
|
1877
1971
|
# Corresponds to the JSON property `text`
|
|
1878
1972
|
# @return [String]
|
|
1879
1973
|
attr_accessor :text
|
|
1880
1974
|
|
|
1881
|
-
#
|
|
1975
|
+
# The title of the retrieved data source.
|
|
1882
1976
|
# Corresponds to the JSON property `title`
|
|
1883
1977
|
# @return [String]
|
|
1884
1978
|
attr_accessor :title
|
|
1885
1979
|
|
|
1886
|
-
# URI
|
|
1980
|
+
# The URI of the retrieved data source.
|
|
1887
1981
|
# Corresponds to the JSON property `uri`
|
|
1888
1982
|
# @return [String]
|
|
1889
1983
|
attr_accessor :uri
|
|
@@ -1902,21 +1996,24 @@ module Google
|
|
|
1902
1996
|
end
|
|
1903
1997
|
end
|
|
1904
1998
|
|
|
1905
|
-
#
|
|
1999
|
+
# A `Web` chunk is a piece of evidence that comes from a web page. It contains
|
|
2000
|
+
# the URI of the web page, the title of the page, and the domain of the page.
|
|
2001
|
+
# This is used to provide the user with a link to the source of the information.
|
|
1906
2002
|
class GoogleCloudAiplatformV1beta1GroundingChunkWeb
|
|
1907
2003
|
include Google::Apis::Core::Hashable
|
|
1908
2004
|
|
|
1909
|
-
#
|
|
2005
|
+
# The domain of the web page that contains the evidence. This can be used to
|
|
2006
|
+
# filter out low-quality sources.
|
|
1910
2007
|
# Corresponds to the JSON property `domain`
|
|
1911
2008
|
# @return [String]
|
|
1912
2009
|
attr_accessor :domain
|
|
1913
2010
|
|
|
1914
|
-
#
|
|
2011
|
+
# The title of the web page that contains the evidence.
|
|
1915
2012
|
# Corresponds to the JSON property `title`
|
|
1916
2013
|
# @return [String]
|
|
1917
2014
|
attr_accessor :title
|
|
1918
2015
|
|
|
1919
|
-
# URI
|
|
2016
|
+
# The URI of the web page that contains the evidence.
|
|
1920
2017
|
# Corresponds to the JSON property `uri`
|
|
1921
2018
|
# @return [String]
|
|
1922
2019
|
attr_accessor :uri
|
|
@@ -1933,49 +2030,63 @@ module Google
|
|
|
1933
2030
|
end
|
|
1934
2031
|
end
|
|
1935
2032
|
|
|
1936
|
-
#
|
|
2033
|
+
# Information about the sources that support the content of a response. When
|
|
2034
|
+
# grounding is enabled, the model returns citations for claims in the response.
|
|
2035
|
+
# This object contains the retrieved sources.
|
|
1937
2036
|
class GoogleCloudAiplatformV1beta1GroundingMetadata
|
|
1938
2037
|
include Google::Apis::Core::Hashable
|
|
1939
2038
|
|
|
1940
|
-
# Optional. Output only.
|
|
1941
|
-
#
|
|
1942
|
-
#
|
|
2039
|
+
# Optional. Output only. A token that can be used to render a Google Maps widget
|
|
2040
|
+
# with the contextual data. This field is populated only when the grounding
|
|
2041
|
+
# source is Google Maps.
|
|
1943
2042
|
# Corresponds to the JSON property `googleMapsWidgetContextToken`
|
|
1944
2043
|
# @return [String]
|
|
1945
2044
|
attr_accessor :google_maps_widget_context_token
|
|
1946
2045
|
|
|
1947
|
-
#
|
|
2046
|
+
# A list of supporting references retrieved from the grounding source. This
|
|
2047
|
+
# field is populated when the grounding source is Google Search, Vertex AI
|
|
2048
|
+
# Search, or Google Maps.
|
|
1948
2049
|
# Corresponds to the JSON property `groundingChunks`
|
|
1949
2050
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GroundingChunk>]
|
|
1950
2051
|
attr_accessor :grounding_chunks
|
|
1951
2052
|
|
|
1952
|
-
# Optional.
|
|
2053
|
+
# Optional. A list of grounding supports that connect the generated content to
|
|
2054
|
+
# the grounding chunks. This field is populated when the grounding source is
|
|
2055
|
+
# Google Search or Vertex AI Search.
|
|
1953
2056
|
# Corresponds to the JSON property `groundingSupports`
|
|
1954
2057
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GroundingSupport>]
|
|
1955
2058
|
attr_accessor :grounding_supports
|
|
1956
2059
|
|
|
1957
|
-
# Metadata related to retrieval
|
|
2060
|
+
# Metadata related to the retrieval grounding source. This is part of the `
|
|
2061
|
+
# GroundingMetadata` returned when grounding is enabled.
|
|
1958
2062
|
# Corresponds to the JSON property `retrievalMetadata`
|
|
1959
2063
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1RetrievalMetadata]
|
|
1960
2064
|
attr_accessor :retrieval_metadata
|
|
1961
2065
|
|
|
1962
|
-
# Optional.
|
|
2066
|
+
# Optional. The queries that were executed by the retrieval tools. This field is
|
|
2067
|
+
# populated only when the grounding source is a retrieval tool, such as Vertex
|
|
2068
|
+
# AI Search.
|
|
1963
2069
|
# Corresponds to the JSON property `retrievalQueries`
|
|
1964
2070
|
# @return [Array<String>]
|
|
1965
2071
|
attr_accessor :retrieval_queries
|
|
1966
2072
|
|
|
1967
|
-
#
|
|
2073
|
+
# An entry point for displaying Google Search results. A `SearchEntryPoint` is
|
|
2074
|
+
# populated when the grounding source for a model's response is Google Search.
|
|
2075
|
+
# It provides information that you can use to display the search results in your
|
|
2076
|
+
# application.
|
|
1968
2077
|
# Corresponds to the JSON property `searchEntryPoint`
|
|
1969
2078
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1SearchEntryPoint]
|
|
1970
2079
|
attr_accessor :search_entry_point
|
|
1971
2080
|
|
|
1972
|
-
# Optional. Output only.
|
|
1973
|
-
# populated only
|
|
2081
|
+
# Optional. Output only. A list of URIs that can be used to flag a place or
|
|
2082
|
+
# review for inappropriate content. This field is populated only when the
|
|
2083
|
+
# grounding source is Google Maps.
|
|
1974
2084
|
# Corresponds to the JSON property `sourceFlaggingUris`
|
|
1975
2085
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1GroundingMetadataSourceFlaggingUri>]
|
|
1976
2086
|
attr_accessor :source_flagging_uris
|
|
1977
2087
|
|
|
1978
|
-
# Optional.
|
|
2088
|
+
# Optional. The web search queries that were used to generate the content. This
|
|
2089
|
+
# field is populated only when the grounding source is Google Search.
|
|
1979
2090
|
# Corresponds to the JSON property `webSearchQueries`
|
|
1980
2091
|
# @return [Array<String>]
|
|
1981
2092
|
attr_accessor :web_search_queries
|
|
@@ -1997,17 +2108,17 @@ module Google
|
|
|
1997
2108
|
end
|
|
1998
2109
|
end
|
|
1999
2110
|
|
|
2000
|
-
#
|
|
2001
|
-
# only
|
|
2111
|
+
# A URI that can be used to flag a place or review for inappropriate content.
|
|
2112
|
+
# This is populated only when the grounding source is Google Maps.
|
|
2002
2113
|
class GoogleCloudAiplatformV1beta1GroundingMetadataSourceFlaggingUri
|
|
2003
2114
|
include Google::Apis::Core::Hashable
|
|
2004
2115
|
|
|
2005
|
-
#
|
|
2116
|
+
# The URI that can be used to flag the content.
|
|
2006
2117
|
# Corresponds to the JSON property `flagContentUri`
|
|
2007
2118
|
# @return [String]
|
|
2008
2119
|
attr_accessor :flag_content_uri
|
|
2009
2120
|
|
|
2010
|
-
#
|
|
2121
|
+
# The ID of the place or review.
|
|
2011
2122
|
# Corresponds to the JSON property `sourceId`
|
|
2012
2123
|
# @return [String]
|
|
2013
2124
|
attr_accessor :source_id
|
|
@@ -2023,27 +2134,30 @@ module Google
|
|
|
2023
2134
|
end
|
|
2024
2135
|
end
|
|
2025
2136
|
|
|
2026
|
-
#
|
|
2137
|
+
# A collection of supporting references for a segment of the model's response.
|
|
2027
2138
|
class GoogleCloudAiplatformV1beta1GroundingSupport
|
|
2028
2139
|
include Google::Apis::Core::Hashable
|
|
2029
2140
|
|
|
2030
|
-
#
|
|
2031
|
-
#
|
|
2032
|
-
#
|
|
2141
|
+
# The confidence scores for the support references. This list is parallel to the
|
|
2142
|
+
# `grounding_chunk_indices` list. A score is a value between 0.0 and 1.0, with a
|
|
2143
|
+
# higher score indicating a higher confidence that the reference supports the
|
|
2144
|
+
# claim. For Gemini 2.0 and before, this list has the same size as `
|
|
2145
|
+
# grounding_chunk_indices`. For Gemini 2.5 and later, this list is empty and
|
|
2033
2146
|
# should be ignored.
|
|
2034
2147
|
# Corresponds to the JSON property `confidenceScores`
|
|
2035
2148
|
# @return [Array<Float>]
|
|
2036
2149
|
attr_accessor :confidence_scores
|
|
2037
2150
|
|
|
2038
|
-
# A list of indices
|
|
2039
|
-
#
|
|
2040
|
-
#
|
|
2041
|
-
# the
|
|
2151
|
+
# A list of indices into the `grounding_chunks` field of the `GroundingMetadata`
|
|
2152
|
+
# message. These indices specify which grounding chunks support the claim made
|
|
2153
|
+
# in the content segment. For example, if this field has the values `[1, 3]`, it
|
|
2154
|
+
# means that `grounding_chunks[1]` and `grounding_chunks[3]` are the sources for
|
|
2155
|
+
# the claim in the content segment.
|
|
2042
2156
|
# Corresponds to the JSON property `groundingChunkIndices`
|
|
2043
2157
|
# @return [Array<Fixnum>]
|
|
2044
2158
|
attr_accessor :grounding_chunk_indices
|
|
2045
2159
|
|
|
2046
|
-
#
|
|
2160
|
+
# A segment of the content.
|
|
2047
2161
|
# Corresponds to the JSON property `segment`
|
|
2048
2162
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Segment]
|
|
2049
2163
|
attr_accessor :segment
|
|
@@ -2060,7 +2174,9 @@ module Google
|
|
|
2060
2174
|
end
|
|
2061
2175
|
end
|
|
2062
2176
|
|
|
2063
|
-
#
|
|
2177
|
+
# Configuration for image generation. This message allows you to control various
|
|
2178
|
+
# aspects of image generation, such as the output format, aspect ratio, and
|
|
2179
|
+
# whether the model can generate images of people.
|
|
2064
2180
|
class GoogleCloudAiplatformV1beta1ImageConfig
|
|
2065
2181
|
include Google::Apis::Core::Hashable
|
|
2066
2182
|
|
|
@@ -2071,6 +2187,16 @@ module Google
|
|
|
2071
2187
|
# @return [String]
|
|
2072
2188
|
attr_accessor :aspect_ratio
|
|
2073
2189
|
|
|
2190
|
+
# The image output format for generated images.
|
|
2191
|
+
# Corresponds to the JSON property `imageOutputOptions`
|
|
2192
|
+
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1ImageConfigImageOutputOptions]
|
|
2193
|
+
attr_accessor :image_output_options
|
|
2194
|
+
|
|
2195
|
+
# Optional. Controls whether the model can generate people.
|
|
2196
|
+
# Corresponds to the JSON property `personGeneration`
|
|
2197
|
+
# @return [String]
|
|
2198
|
+
attr_accessor :person_generation
|
|
2199
|
+
|
|
2074
2200
|
def initialize(**args)
|
|
2075
2201
|
update!(**args)
|
|
2076
2202
|
end
|
|
@@ -2078,20 +2204,54 @@ module Google
|
|
|
2078
2204
|
# Update properties of this object
|
|
2079
2205
|
def update!(**args)
|
|
2080
2206
|
@aspect_ratio = args[:aspect_ratio] if args.key?(:aspect_ratio)
|
|
2207
|
+
@image_output_options = args[:image_output_options] if args.key?(:image_output_options)
|
|
2208
|
+
@person_generation = args[:person_generation] if args.key?(:person_generation)
|
|
2209
|
+
end
|
|
2210
|
+
end
|
|
2211
|
+
|
|
2212
|
+
# The image output format for generated images.
|
|
2213
|
+
class GoogleCloudAiplatformV1beta1ImageConfigImageOutputOptions
|
|
2214
|
+
include Google::Apis::Core::Hashable
|
|
2215
|
+
|
|
2216
|
+
# Optional. The compression quality of the output image.
|
|
2217
|
+
# Corresponds to the JSON property `compressionQuality`
|
|
2218
|
+
# @return [Fixnum]
|
|
2219
|
+
attr_accessor :compression_quality
|
|
2220
|
+
|
|
2221
|
+
# Optional. The image format that the output should be saved as.
|
|
2222
|
+
# Corresponds to the JSON property `mimeType`
|
|
2223
|
+
# @return [String]
|
|
2224
|
+
attr_accessor :mime_type
|
|
2225
|
+
|
|
2226
|
+
def initialize(**args)
|
|
2227
|
+
update!(**args)
|
|
2228
|
+
end
|
|
2229
|
+
|
|
2230
|
+
# Update properties of this object
|
|
2231
|
+
def update!(**args)
|
|
2232
|
+
@compression_quality = args[:compression_quality] if args.key?(:compression_quality)
|
|
2233
|
+
@mime_type = args[:mime_type] if args.key?(:mime_type)
|
|
2081
2234
|
end
|
|
2082
2235
|
end
|
|
2083
2236
|
|
|
2084
|
-
#
|
|
2237
|
+
# The log probabilities of the tokens generated by the model. This is useful for
|
|
2238
|
+
# understanding the model's confidence in its predictions and for debugging. For
|
|
2239
|
+
# example, you can use log probabilities to identify when the model is making a
|
|
2240
|
+
# less confident prediction or to explore alternative responses that the model
|
|
2241
|
+
# considered. A low log probability can also indicate that the model is "
|
|
2242
|
+
# hallucinating" or generating factually incorrect information.
|
|
2085
2243
|
class GoogleCloudAiplatformV1beta1LogprobsResult
|
|
2086
2244
|
include Google::Apis::Core::Hashable
|
|
2087
2245
|
|
|
2088
|
-
#
|
|
2089
|
-
#
|
|
2246
|
+
# A list of the chosen candidate tokens at each decoding step. The length of
|
|
2247
|
+
# this list is equal to the total number of decoding steps. Note that the chosen
|
|
2248
|
+
# candidate might not be in `top_candidates`.
|
|
2090
2249
|
# Corresponds to the JSON property `chosenCandidates`
|
|
2091
2250
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1LogprobsResultCandidate>]
|
|
2092
2251
|
attr_accessor :chosen_candidates
|
|
2093
2252
|
|
|
2094
|
-
#
|
|
2253
|
+
# A list of the top candidate tokens at each decoding step. The length of this
|
|
2254
|
+
# list is equal to the total number of decoding steps.
|
|
2095
2255
|
# Corresponds to the JSON property `topCandidates`
|
|
2096
2256
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1LogprobsResultTopCandidates>]
|
|
2097
2257
|
attr_accessor :top_candidates
|
|
@@ -2107,21 +2267,27 @@ module Google
|
|
|
2107
2267
|
end
|
|
2108
2268
|
end
|
|
2109
2269
|
|
|
2110
|
-
#
|
|
2270
|
+
# A single token and its associated log probability.
|
|
2111
2271
|
class GoogleCloudAiplatformV1beta1LogprobsResultCandidate
|
|
2112
2272
|
include Google::Apis::Core::Hashable
|
|
2113
2273
|
|
|
2114
|
-
# The
|
|
2274
|
+
# The log probability of this token. A higher value indicates that the model was
|
|
2275
|
+
# more confident in this token. The log probability can be used to assess the
|
|
2276
|
+
# relative likelihood of different tokens and to identify when the model is
|
|
2277
|
+
# uncertain.
|
|
2115
2278
|
# Corresponds to the JSON property `logProbability`
|
|
2116
2279
|
# @return [Float]
|
|
2117
2280
|
attr_accessor :log_probability
|
|
2118
2281
|
|
|
2119
|
-
# The
|
|
2282
|
+
# The token's string representation.
|
|
2120
2283
|
# Corresponds to the JSON property `token`
|
|
2121
2284
|
# @return [String]
|
|
2122
2285
|
attr_accessor :token
|
|
2123
2286
|
|
|
2124
|
-
# The
|
|
2287
|
+
# The token's numerical ID. While the `token` field provides the string
|
|
2288
|
+
# representation of the token, the `token_id` is the numerical representation
|
|
2289
|
+
# that the model uses internally. This can be useful for developers who want to
|
|
2290
|
+
# build custom logic based on the model's vocabulary.
|
|
2125
2291
|
# Corresponds to the JSON property `tokenId`
|
|
2126
2292
|
# @return [Fixnum]
|
|
2127
2293
|
attr_accessor :token_id
|
|
@@ -2138,11 +2304,12 @@ module Google
|
|
|
2138
2304
|
end
|
|
2139
2305
|
end
|
|
2140
2306
|
|
|
2141
|
-
#
|
|
2307
|
+
# A list of the top candidate tokens and their log probabilities at each
|
|
2308
|
+
# decoding step. This can be used to see what other tokens the model considered.
|
|
2142
2309
|
class GoogleCloudAiplatformV1beta1LogprobsResultTopCandidates
|
|
2143
2310
|
include Google::Apis::Core::Hashable
|
|
2144
2311
|
|
|
2145
|
-
#
|
|
2312
|
+
# The list of candidate tokens, sorted by log probability in descending order.
|
|
2146
2313
|
# Corresponds to the JSON property `candidates`
|
|
2147
2314
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1LogprobsResultCandidate>]
|
|
2148
2315
|
attr_accessor :candidates
|
|
@@ -2157,16 +2324,21 @@ module Google
|
|
|
2157
2324
|
end
|
|
2158
2325
|
end
|
|
2159
2326
|
|
|
2160
|
-
# Represents
|
|
2327
|
+
# Represents a breakdown of token usage by modality. This message is used in
|
|
2328
|
+
# CountTokensResponse and GenerateContentResponse.UsageMetadata to provide a
|
|
2329
|
+
# detailed view of how many tokens are used by each modality (e.g., text, image,
|
|
2330
|
+
# video) in a request. This is particularly useful for multimodal models,
|
|
2331
|
+
# allowing you to track and manage token consumption for billing and quota
|
|
2332
|
+
# purposes.
|
|
2161
2333
|
class GoogleCloudAiplatformV1beta1ModalityTokenCount
|
|
2162
2334
|
include Google::Apis::Core::Hashable
|
|
2163
2335
|
|
|
2164
|
-
# The modality
|
|
2336
|
+
# The modality that this token count applies to.
|
|
2165
2337
|
# Corresponds to the JSON property `modality`
|
|
2166
2338
|
# @return [String]
|
|
2167
2339
|
attr_accessor :modality
|
|
2168
2340
|
|
|
2169
|
-
#
|
|
2341
|
+
# The number of tokens counted for this modality.
|
|
2170
2342
|
# Corresponds to the JSON property `tokenCount`
|
|
2171
2343
|
# @return [Fixnum]
|
|
2172
2344
|
attr_accessor :token_count
|
|
@@ -2182,17 +2354,29 @@ module Google
|
|
|
2182
2354
|
end
|
|
2183
2355
|
end
|
|
2184
2356
|
|
|
2185
|
-
# Configuration for Model Armor
|
|
2357
|
+
# Configuration for Model Armor. Model Armor is a Google Cloud service that
|
|
2358
|
+
# provides safety and security filtering for prompts and responses. It helps
|
|
2359
|
+
# protect your AI applications from risks such as harmful content, sensitive
|
|
2360
|
+
# data leakage, and prompt injection attacks.
|
|
2186
2361
|
class GoogleCloudAiplatformV1beta1ModelArmorConfig
|
|
2187
2362
|
include Google::Apis::Core::Hashable
|
|
2188
2363
|
|
|
2189
|
-
# Optional. The name of the Model Armor template to use for prompt
|
|
2364
|
+
# Optional. The resource name of the Model Armor template to use for prompt
|
|
2365
|
+
# screening. A Model Armor template is a set of customized filters and
|
|
2366
|
+
# thresholds that define how Model Armor screens content. If specified, Model
|
|
2367
|
+
# Armor will use this template to check the user's prompt for safety and
|
|
2368
|
+
# security risks before it is sent to the model. The name must be in the format `
|
|
2369
|
+
# projects/`project`/locations/`location`/templates/`template``.
|
|
2190
2370
|
# Corresponds to the JSON property `promptTemplateName`
|
|
2191
2371
|
# @return [String]
|
|
2192
2372
|
attr_accessor :prompt_template_name
|
|
2193
2373
|
|
|
2194
|
-
# Optional. The name of the Model Armor template to use for response
|
|
2195
|
-
#
|
|
2374
|
+
# Optional. The resource name of the Model Armor template to use for response
|
|
2375
|
+
# screening. A Model Armor template is a set of customized filters and
|
|
2376
|
+
# thresholds that define how Model Armor screens content. If specified, Model
|
|
2377
|
+
# Armor will use this template to check the model's response for safety and
|
|
2378
|
+
# security risks before it is returned to the user. The name must be in the
|
|
2379
|
+
# format `projects/`project`/locations/`location`/templates/`template``.
|
|
2196
2380
|
# Corresponds to the JSON property `responseTemplateName`
|
|
2197
2381
|
# @return [String]
|
|
2198
2382
|
attr_accessor :response_template_name
|
|
@@ -2208,8 +2392,7 @@ module Google
|
|
|
2208
2392
|
end
|
|
2209
2393
|
end
|
|
2210
2394
|
|
|
2211
|
-
# Configuration for a multi-speaker text-to-speech
|
|
2212
|
-
# to two distinct voices in a single synthesis request.
|
|
2395
|
+
# Configuration for a multi-speaker text-to-speech request.
|
|
2213
2396
|
class GoogleCloudAiplatformV1beta1MultiSpeakerVoiceConfig
|
|
2214
2397
|
include Google::Apis::Core::Hashable
|
|
2215
2398
|
|
|
@@ -2229,11 +2412,11 @@ module Google
|
|
|
2229
2412
|
end
|
|
2230
2413
|
end
|
|
2231
2414
|
|
|
2232
|
-
# A datatype containing media that is part of a multi-part
|
|
2415
|
+
# A datatype containing media that is part of a multi-part Content message. A `
|
|
2233
2416
|
# Part` consists of data which has an associated datatype. A `Part` can only
|
|
2234
|
-
# contain one of the accepted types in `Part.data`.
|
|
2235
|
-
# IANA MIME type identifying the type and subtype
|
|
2236
|
-
# or `file_data` field is filled with raw bytes.
|
|
2417
|
+
# contain one of the accepted types in `Part.data`. For media types that are not
|
|
2418
|
+
# text, `Part` must have a fixed IANA MIME type identifying the type and subtype
|
|
2419
|
+
# of the media if `inline_data` or `file_data` field is filled with raw bytes.
|
|
2237
2420
|
class GoogleCloudAiplatformV1beta1Part
|
|
2238
2421
|
include Google::Apis::Core::Hashable
|
|
2239
2422
|
|
|
@@ -2252,7 +2435,9 @@ module Google
|
|
|
2252
2435
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1ExecutableCode]
|
|
2253
2436
|
attr_accessor :executable_code
|
|
2254
2437
|
|
|
2255
|
-
# URI
|
|
2438
|
+
# URI-based data. A FileData message contains a URI pointing to data of a
|
|
2439
|
+
# specific media type. It is used to represent images, audio, and video stored
|
|
2440
|
+
# in Google Cloud Storage.
|
|
2256
2441
|
# Corresponds to the JSON property `fileData`
|
|
2257
2442
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1FileData]
|
|
2258
2443
|
attr_accessor :file_data
|
|
@@ -2272,17 +2457,19 @@ module Google
|
|
|
2272
2457
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1FunctionResponse]
|
|
2273
2458
|
attr_accessor :function_response
|
|
2274
2459
|
|
|
2275
|
-
#
|
|
2460
|
+
# A content blob. A Blob contains data of a specific media type. It is used to
|
|
2461
|
+
# represent images, audio, and video.
|
|
2276
2462
|
# Corresponds to the JSON property `inlineData`
|
|
2277
2463
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1Blob]
|
|
2278
2464
|
attr_accessor :inline_data
|
|
2279
2465
|
|
|
2280
|
-
# Optional.
|
|
2466
|
+
# Optional. The text content of the part.
|
|
2281
2467
|
# Corresponds to the JSON property `text`
|
|
2282
2468
|
# @return [String]
|
|
2283
2469
|
attr_accessor :text
|
|
2284
2470
|
|
|
2285
|
-
# Optional. Indicates
|
|
2471
|
+
# Optional. Indicates whether the `part` represents the model's thought process
|
|
2472
|
+
# or reasoning.
|
|
2286
2473
|
# Corresponds to the JSON property `thought`
|
|
2287
2474
|
# @return [Boolean]
|
|
2288
2475
|
attr_accessor :thought
|
|
@@ -2295,7 +2482,8 @@ module Google
|
|
|
2295
2482
|
# @return [String]
|
|
2296
2483
|
attr_accessor :thought_signature
|
|
2297
2484
|
|
|
2298
|
-
#
|
|
2485
|
+
# Provides metadata for a video, including the start and end offsets for
|
|
2486
|
+
# clipping and the frame rate.
|
|
2299
2487
|
# Corresponds to the JSON property `videoMetadata`
|
|
2300
2488
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1VideoMetadata]
|
|
2301
2489
|
attr_accessor :video_metadata
|
|
@@ -2319,11 +2507,11 @@ module Google
|
|
|
2319
2507
|
end
|
|
2320
2508
|
end
|
|
2321
2509
|
|
|
2322
|
-
#
|
|
2510
|
+
# Configuration for a prebuilt voice.
|
|
2323
2511
|
class GoogleCloudAiplatformV1beta1PrebuiltVoiceConfig
|
|
2324
2512
|
include Google::Apis::Core::Hashable
|
|
2325
2513
|
|
|
2326
|
-
# The name of the
|
|
2514
|
+
# The name of the prebuilt voice to use.
|
|
2327
2515
|
# Corresponds to the JSON property `voiceName`
|
|
2328
2516
|
# @return [String]
|
|
2329
2517
|
attr_accessor :voice_name
|
|
@@ -2616,15 +2804,17 @@ module Google
|
|
|
2616
2804
|
end
|
|
2617
2805
|
end
|
|
2618
2806
|
|
|
2619
|
-
# Metadata related to retrieval
|
|
2807
|
+
# Metadata related to the retrieval grounding source. This is part of the `
|
|
2808
|
+
# GroundingMetadata` returned when grounding is enabled.
|
|
2620
2809
|
class GoogleCloudAiplatformV1beta1RetrievalMetadata
|
|
2621
2810
|
include Google::Apis::Core::Hashable
|
|
2622
2811
|
|
|
2623
|
-
# Optional.
|
|
2624
|
-
# help answer the prompt. The score is in the range `[0, 1]
|
|
2625
|
-
#
|
|
2626
|
-
#
|
|
2627
|
-
#
|
|
2812
|
+
# Optional. A score indicating how likely it is that a Google Search query could
|
|
2813
|
+
# help answer the prompt. The score is in the range of `[0, 1]`. A score of 1
|
|
2814
|
+
# means the model is confident that a search will be helpful, and 0 means it is
|
|
2815
|
+
# not. This score is populated only when Google Search grounding and dynamic
|
|
2816
|
+
# retrieval are enabled. The score is used to determine whether to trigger a
|
|
2817
|
+
# search.
|
|
2628
2818
|
# Corresponds to the JSON property `googleSearchDynamicRetrievalScore`
|
|
2629
2819
|
# @return [Float]
|
|
2630
2820
|
attr_accessor :google_search_dynamic_retrieval_score
|
|
@@ -2639,18 +2829,18 @@ module Google
|
|
|
2639
2829
|
end
|
|
2640
2830
|
end
|
|
2641
2831
|
|
|
2642
|
-
#
|
|
2832
|
+
# A safety rating for a piece of content. The safety rating contains the harm
|
|
2833
|
+
# category and the harm probability level.
|
|
2643
2834
|
class GoogleCloudAiplatformV1beta1SafetyRating
|
|
2644
2835
|
include Google::Apis::Core::Hashable
|
|
2645
2836
|
|
|
2646
|
-
# Output only. Indicates whether the content was
|
|
2647
|
-
# rating.
|
|
2837
|
+
# Output only. Indicates whether the content was blocked because of this rating.
|
|
2648
2838
|
# Corresponds to the JSON property `blocked`
|
|
2649
2839
|
# @return [Boolean]
|
|
2650
2840
|
attr_accessor :blocked
|
|
2651
2841
|
alias_method :blocked?, :blocked
|
|
2652
2842
|
|
|
2653
|
-
# Output only.
|
|
2843
|
+
# Output only. The harm category of this rating.
|
|
2654
2844
|
# Corresponds to the JSON property `category`
|
|
2655
2845
|
# @return [String]
|
|
2656
2846
|
attr_accessor :category
|
|
@@ -2662,22 +2852,22 @@ module Google
|
|
|
2662
2852
|
# @return [String]
|
|
2663
2853
|
attr_accessor :overwritten_threshold
|
|
2664
2854
|
|
|
2665
|
-
# Output only.
|
|
2855
|
+
# Output only. The probability of harm for this category.
|
|
2666
2856
|
# Corresponds to the JSON property `probability`
|
|
2667
2857
|
# @return [String]
|
|
2668
2858
|
attr_accessor :probability
|
|
2669
2859
|
|
|
2670
|
-
# Output only.
|
|
2860
|
+
# Output only. The probability score of harm for this category.
|
|
2671
2861
|
# Corresponds to the JSON property `probabilityScore`
|
|
2672
2862
|
# @return [Float]
|
|
2673
2863
|
attr_accessor :probability_score
|
|
2674
2864
|
|
|
2675
|
-
# Output only.
|
|
2865
|
+
# Output only. The severity of harm for this category.
|
|
2676
2866
|
# Corresponds to the JSON property `severity`
|
|
2677
2867
|
# @return [String]
|
|
2678
2868
|
attr_accessor :severity
|
|
2679
2869
|
|
|
2680
|
-
# Output only.
|
|
2870
|
+
# Output only. The severity score of harm for this category.
|
|
2681
2871
|
# Corresponds to the JSON property `severityScore`
|
|
2682
2872
|
# @return [Float]
|
|
2683
2873
|
attr_accessor :severity_score
|
|
@@ -2698,22 +2888,24 @@ module Google
|
|
|
2698
2888
|
end
|
|
2699
2889
|
end
|
|
2700
2890
|
|
|
2701
|
-
#
|
|
2891
|
+
# A safety setting that affects the safety-blocking behavior. A SafetySetting
|
|
2892
|
+
# consists of a harm category and a threshold for that category.
|
|
2702
2893
|
class GoogleCloudAiplatformV1beta1SafetySetting
|
|
2703
2894
|
include Google::Apis::Core::Hashable
|
|
2704
2895
|
|
|
2705
|
-
# Required.
|
|
2896
|
+
# Required. The harm category to be blocked.
|
|
2706
2897
|
# Corresponds to the JSON property `category`
|
|
2707
2898
|
# @return [String]
|
|
2708
2899
|
attr_accessor :category
|
|
2709
2900
|
|
|
2710
|
-
# Optional.
|
|
2711
|
-
#
|
|
2901
|
+
# Optional. The method for blocking content. If not specified, the default
|
|
2902
|
+
# behavior is to use the probability score.
|
|
2712
2903
|
# Corresponds to the JSON property `method`
|
|
2713
2904
|
# @return [String]
|
|
2714
2905
|
attr_accessor :method_prop
|
|
2715
2906
|
|
|
2716
|
-
# Required. The harm
|
|
2907
|
+
# Required. The threshold for blocking content. If the harm probability exceeds
|
|
2908
|
+
# this threshold, the content will be blocked.
|
|
2717
2909
|
# Corresponds to the JSON property `threshold`
|
|
2718
2910
|
# @return [String]
|
|
2719
2911
|
attr_accessor :threshold
|
|
@@ -2916,17 +3108,23 @@ module Google
|
|
|
2916
3108
|
end
|
|
2917
3109
|
end
|
|
2918
3110
|
|
|
2919
|
-
#
|
|
3111
|
+
# An entry point for displaying Google Search results. A `SearchEntryPoint` is
|
|
3112
|
+
# populated when the grounding source for a model's response is Google Search.
|
|
3113
|
+
# It provides information that you can use to display the search results in your
|
|
3114
|
+
# application.
|
|
2920
3115
|
class GoogleCloudAiplatformV1beta1SearchEntryPoint
|
|
2921
3116
|
include Google::Apis::Core::Hashable
|
|
2922
3117
|
|
|
2923
|
-
# Optional.
|
|
2924
|
-
# webview.
|
|
3118
|
+
# Optional. An HTML snippet that can be embedded in a web page or an application'
|
|
3119
|
+
# s webview. This snippet displays a search result, including the title, URL,
|
|
3120
|
+
# and a brief description of the search result.
|
|
2925
3121
|
# Corresponds to the JSON property `renderedContent`
|
|
2926
3122
|
# @return [String]
|
|
2927
3123
|
attr_accessor :rendered_content
|
|
2928
3124
|
|
|
2929
|
-
# Optional.
|
|
3125
|
+
# Optional. A base64-encoded JSON object that contains a list of search queries
|
|
3126
|
+
# and their corresponding search URLs. This information can be used to build a
|
|
3127
|
+
# custom search UI.
|
|
2930
3128
|
# Corresponds to the JSON property `sdkBlob`
|
|
2931
3129
|
# NOTE: Values are automatically base64 encoded/decoded in the client library.
|
|
2932
3130
|
# @return [String]
|
|
@@ -2943,28 +3141,31 @@ module Google
|
|
|
2943
3141
|
end
|
|
2944
3142
|
end
|
|
2945
3143
|
|
|
2946
|
-
#
|
|
3144
|
+
# A segment of the content.
|
|
2947
3145
|
class GoogleCloudAiplatformV1beta1Segment
|
|
2948
3146
|
include Google::Apis::Core::Hashable
|
|
2949
3147
|
|
|
2950
|
-
# Output only.
|
|
2951
|
-
#
|
|
3148
|
+
# Output only. The end index of the segment in the `Part`, measured in bytes.
|
|
3149
|
+
# This marks the end of the segment and is exclusive, meaning the segment
|
|
3150
|
+
# includes content up to, but not including, the byte at this index.
|
|
2952
3151
|
# Corresponds to the JSON property `endIndex`
|
|
2953
3152
|
# @return [Fixnum]
|
|
2954
3153
|
attr_accessor :end_index
|
|
2955
3154
|
|
|
2956
|
-
# Output only. The index of
|
|
3155
|
+
# Output only. The index of the `Part` object that this segment belongs to. This
|
|
3156
|
+
# is useful for associating the segment with a specific part of the content.
|
|
2957
3157
|
# Corresponds to the JSON property `partIndex`
|
|
2958
3158
|
# @return [Fixnum]
|
|
2959
3159
|
attr_accessor :part_index
|
|
2960
3160
|
|
|
2961
|
-
# Output only.
|
|
2962
|
-
#
|
|
3161
|
+
# Output only. The start index of the segment in the `Part`, measured in bytes.
|
|
3162
|
+
# This marks the beginning of the segment and is inclusive, meaning the byte at
|
|
3163
|
+
# this index is the first byte of the segment.
|
|
2963
3164
|
# Corresponds to the JSON property `startIndex`
|
|
2964
3165
|
# @return [Fixnum]
|
|
2965
3166
|
attr_accessor :start_index
|
|
2966
3167
|
|
|
2967
|
-
# Output only. The text
|
|
3168
|
+
# Output only. The text of the segment.
|
|
2968
3169
|
# Corresponds to the JSON property `text`
|
|
2969
3170
|
# @return [String]
|
|
2970
3171
|
attr_accessor :text
|
|
@@ -2982,7 +3183,7 @@ module Google
|
|
|
2982
3183
|
end
|
|
2983
3184
|
end
|
|
2984
3185
|
|
|
2985
|
-
# Configuration for a single speaker in a multi
|
|
3186
|
+
# Configuration for a single speaker in a multi-speaker setup.
|
|
2986
3187
|
class GoogleCloudAiplatformV1beta1SpeakerVoiceConfig
|
|
2987
3188
|
include Google::Apis::Core::Hashable
|
|
2988
3189
|
|
|
@@ -2992,7 +3193,7 @@ module Google
|
|
|
2992
3193
|
# @return [String]
|
|
2993
3194
|
attr_accessor :speaker
|
|
2994
3195
|
|
|
2995
|
-
#
|
|
3196
|
+
# Configuration for a voice.
|
|
2996
3197
|
# Corresponds to the JSON property `voiceConfig`
|
|
2997
3198
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1VoiceConfig]
|
|
2998
3199
|
attr_accessor :voice_config
|
|
@@ -3008,22 +3209,21 @@ module Google
|
|
|
3008
3209
|
end
|
|
3009
3210
|
end
|
|
3010
3211
|
|
|
3011
|
-
#
|
|
3212
|
+
# Configuration for speech generation.
|
|
3012
3213
|
class GoogleCloudAiplatformV1beta1SpeechConfig
|
|
3013
3214
|
include Google::Apis::Core::Hashable
|
|
3014
3215
|
|
|
3015
|
-
# Optional.
|
|
3216
|
+
# Optional. The language code (ISO 639-1) for the speech synthesis.
|
|
3016
3217
|
# Corresponds to the JSON property `languageCode`
|
|
3017
3218
|
# @return [String]
|
|
3018
3219
|
attr_accessor :language_code
|
|
3019
3220
|
|
|
3020
|
-
# Configuration for a multi-speaker text-to-speech
|
|
3021
|
-
# to two distinct voices in a single synthesis request.
|
|
3221
|
+
# Configuration for a multi-speaker text-to-speech request.
|
|
3022
3222
|
# Corresponds to the JSON property `multiSpeakerVoiceConfig`
|
|
3023
3223
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1MultiSpeakerVoiceConfig]
|
|
3024
3224
|
attr_accessor :multi_speaker_voice_config
|
|
3025
3225
|
|
|
3026
|
-
#
|
|
3226
|
+
# Configuration for a voice.
|
|
3027
3227
|
# Corresponds to the JSON property `voiceConfig`
|
|
3028
3228
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1VoiceConfig]
|
|
3029
3229
|
attr_accessor :voice_config
|
|
@@ -3144,11 +3344,12 @@ module Google
|
|
|
3144
3344
|
# @return [String]
|
|
3145
3345
|
attr_accessor :environment
|
|
3146
3346
|
|
|
3147
|
-
# Optional. By default, predefined functions
|
|
3148
|
-
#
|
|
3149
|
-
#
|
|
3150
|
-
#
|
|
3151
|
-
#
|
|
3347
|
+
# Optional. By default, [predefined functions](https://cloud.google.com/vertex-
|
|
3348
|
+
# ai/generative-ai/docs/computer-use#supported-actions) are included in the
|
|
3349
|
+
# final model call. Some of them can be explicitly excluded from being
|
|
3350
|
+
# automatically included. This can serve two purposes: 1. Using a more
|
|
3351
|
+
# restricted / different action space. 2. Improving the definitions /
|
|
3352
|
+
# instructions of predefined functions.
|
|
3152
3353
|
# Corresponds to the JSON property `excludedPredefinedFunctions`
|
|
3153
3354
|
# @return [Array<String>]
|
|
3154
3355
|
attr_accessor :excluded_predefined_functions
|
|
@@ -3230,11 +3431,13 @@ module Google
|
|
|
3230
3431
|
end
|
|
3231
3432
|
end
|
|
3232
3433
|
|
|
3233
|
-
# Metadata
|
|
3434
|
+
# Metadata returned when the model uses the `url_context` tool to get
|
|
3435
|
+
# information from a user-provided URL.
|
|
3234
3436
|
class GoogleCloudAiplatformV1beta1UrlContextMetadata
|
|
3235
3437
|
include Google::Apis::Core::Hashable
|
|
3236
3438
|
|
|
3237
|
-
# Output only.
|
|
3439
|
+
# Output only. A list of URL metadata, with one entry for each URL retrieved by
|
|
3440
|
+
# the tool.
|
|
3238
3441
|
# Corresponds to the JSON property `urlMetadata`
|
|
3239
3442
|
# @return [Array<Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1UrlMetadata>]
|
|
3240
3443
|
attr_accessor :url_metadata
|
|
@@ -3249,16 +3452,16 @@ module Google
|
|
|
3249
3452
|
end
|
|
3250
3453
|
end
|
|
3251
3454
|
|
|
3252
|
-
#
|
|
3455
|
+
# The metadata for a single URL retrieval.
|
|
3253
3456
|
class GoogleCloudAiplatformV1beta1UrlMetadata
|
|
3254
3457
|
include Google::Apis::Core::Hashable
|
|
3255
3458
|
|
|
3256
|
-
#
|
|
3459
|
+
# The URL retrieved by the tool.
|
|
3257
3460
|
# Corresponds to the JSON property `retrievedUrl`
|
|
3258
3461
|
# @return [String]
|
|
3259
3462
|
attr_accessor :retrieved_url
|
|
3260
3463
|
|
|
3261
|
-
#
|
|
3464
|
+
# The status of the URL retrieval.
|
|
3262
3465
|
# Corresponds to the JSON property `urlRetrievalStatus`
|
|
3263
3466
|
# @return [String]
|
|
3264
3467
|
attr_accessor :url_retrieval_status
|
|
@@ -3440,7 +3643,8 @@ module Google
|
|
|
3440
3643
|
end
|
|
3441
3644
|
end
|
|
3442
3645
|
|
|
3443
|
-
#
|
|
3646
|
+
# Provides metadata for a video, including the start and end offsets for
|
|
3647
|
+
# clipping and the frame rate.
|
|
3444
3648
|
class GoogleCloudAiplatformV1beta1VideoMetadata
|
|
3445
3649
|
include Google::Apis::Core::Hashable
|
|
3446
3650
|
|
|
@@ -3450,7 +3654,7 @@ module Google
|
|
|
3450
3654
|
attr_accessor :end_offset
|
|
3451
3655
|
|
|
3452
3656
|
# Optional. The frame rate of the video sent to the model. If not specified, the
|
|
3453
|
-
# default value
|
|
3657
|
+
# default value is 1.0. The valid range is (0.0, 24.0].
|
|
3454
3658
|
# Corresponds to the JSON property `fps`
|
|
3455
3659
|
# @return [Float]
|
|
3456
3660
|
attr_accessor :fps
|
|
@@ -3472,11 +3676,11 @@ module Google
|
|
|
3472
3676
|
end
|
|
3473
3677
|
end
|
|
3474
3678
|
|
|
3475
|
-
#
|
|
3679
|
+
# Configuration for a voice.
|
|
3476
3680
|
class GoogleCloudAiplatformV1beta1VoiceConfig
|
|
3477
3681
|
include Google::Apis::Core::Hashable
|
|
3478
3682
|
|
|
3479
|
-
#
|
|
3683
|
+
# Configuration for a prebuilt voice.
|
|
3480
3684
|
# Corresponds to the JSON property `prebuiltVoiceConfig`
|
|
3481
3685
|
# @return [Google::Apis::FirebasemlV2beta::GoogleCloudAiplatformV1beta1PrebuiltVoiceConfig]
|
|
3482
3686
|
attr_accessor :prebuilt_voice_config
|