forked from googleapis/google-api-python-client
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaiplatform_v1.projects.locations.evaluationRuns.html
More file actions
5262 lines (5219 loc) · 803 KB
/
aiplatform_v1.projects.locations.evaluationRuns.html
File metadata and controls
5262 lines (5219 loc) · 803 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<html><body>
<style>
body, h1, h2, h3, div, span, p, pre, a {
margin: 0;
padding: 0;
border: 0;
font-weight: inherit;
font-style: inherit;
font-size: 100%;
font-family: inherit;
vertical-align: baseline;
}
body {
font-size: 13px;
padding: 1em;
}
h1 {
font-size: 26px;
margin-bottom: 1em;
}
h2 {
font-size: 24px;
margin-bottom: 1em;
}
h3 {
font-size: 20px;
margin-bottom: 1em;
margin-top: 1em;
}
pre, code {
line-height: 1.5;
font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
}
pre {
margin-top: 0.5em;
}
h1, h2, h3, p {
font-family: Arial, sans serif;
}
h1, h2, h3 {
border-bottom: solid #CCC 1px;
}
.toc_element {
margin-top: 0.5em;
}
.firstline {
margin-left: 2 em;
}
.method {
margin-top: 1em;
border: solid 1px #CCC;
padding: 1em;
background: #EEE;
}
.details {
font-weight: bold;
font-size: 14px;
}
</style>
<h1><a href="aiplatform_v1.html">Vertex AI API</a> . <a href="aiplatform_v1.projects.html">projects</a> . <a href="aiplatform_v1.projects.locations.html">locations</a> . <a href="aiplatform_v1.projects.locations.evaluationRuns.html">evaluationRuns</a></h1>
<h2>Instance Methods</h2>
<p class="toc_element">
<code><a href="#cancel">cancel(name, body=None, x__xgafv=None)</a></code></p>
<p class="firstline">Cancels an Evaluation Run. Attempts to cancel a running Evaluation Run asynchronously. Status of run can be checked via GetEvaluationRun.</p>
<p class="toc_element">
<code><a href="#close">close()</a></code></p>
<p class="firstline">Close httplib2 connections.</p>
<p class="toc_element">
<code><a href="#create">create(parent, body=None, x__xgafv=None)</a></code></p>
<p class="firstline">Creates an Evaluation Run.</p>
<p class="toc_element">
<code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
<p class="firstline">Deletes an Evaluation Run.</p>
<p class="toc_element">
<code><a href="#get">get(name, x__xgafv=None)</a></code></p>
<p class="firstline">Gets an Evaluation Run.</p>
<p class="toc_element">
<code><a href="#list">list(parent, filter=None, orderBy=None, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
<p class="firstline">Lists Evaluation Runs.</p>
<p class="toc_element">
<code><a href="#list_next">list_next()</a></code></p>
<p class="firstline">Retrieves the next page of results.</p>
<h3>Method Details</h3>
<div class="method">
<code class="details" id="cancel">cancel(name, body=None, x__xgafv=None)</code>
<pre>Cancels an Evaluation Run. Attempts to cancel a running Evaluation Run asynchronously. Status of run can be checked via GetEvaluationRun.
Args:
name: string, Required. The name of the EvaluationRun resource to be cancelled. Format: `projects/{project}/locations/{location}/evaluationRuns/{evaluation_run}` (required)
body: object, The request body.
The object takes the form of:
{ # Request message for EvaluationManagementService.CancelEvaluationRun.
}
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
}</pre>
</div>
<div class="method">
<code class="details" id="close">close()</code>
<pre>Close httplib2 connections.</pre>
</div>
<div class="method">
<code class="details" id="create">create(parent, body=None, x__xgafv=None)</code>
<pre>Creates an Evaluation Run.
Args:
parent: string, Required. The resource name of the Location to create the Evaluation Run in. Format: `projects/{project}/locations/{location}` (required)
body: object, The request body.
The object takes the form of:
{ # EvaluationRun is a resource that represents a single evaluation run, which includes a set of prompts, model responses, evaluation configuration and the resulting metrics.
"completionTime": "A String", # Output only. Time when the evaluation run was completed.
"createTime": "A String", # Output only. Time when the evaluation run was created.
"dataSource": { # The data source for the evaluation run. # Required. The data source for the evaluation run.
"bigqueryRequestSet": { # The request set for the evaluation run. # Evaluation data in bigquery.
"candidateResponseColumns": { # Optional. Map of candidate name to candidate response column name. The column will be in evaluation_item.CandidateResponse format.
"a_key": "A String",
},
"promptColumn": "A String", # Optional. The name of the column that contains the requests to evaluate. This will be in evaluation_item.EvalPrompt format.
"rubricsColumn": "A String", # Optional. The name of the column that contains the rubrics. This is in evaluation_rubric.RubricGroup format.
"samplingConfig": { # The sampling config. # Optional. The sampling config for the bigquery resource.
"samplingCount": 42, # Optional. The total number of logged data to import. If available data is less than the sampling count, all data will be imported. Default is 100.
"samplingDuration": "A String", # Optional. How long to wait before sampling data from the BigQuery table. If not specified, defaults to 0.
"samplingMethod": "A String", # Optional. The sampling method to use.
},
"uri": "A String", # Required. The URI of a BigQuery table. e.g. bq://projectId.bqDatasetId.bqTableId
},
"evaluationSet": "A String", # The EvaluationSet resource name. Format: `projects/{project}/locations/{location}/evaluationSets/{evaluation_set}`
},
"displayName": "A String", # Required. The display name of the Evaluation Run.
"error": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # Output only. Only populated when the evaluation run's state is FAILED or CANCELLED.
"code": 42, # The status code, which should be an enum value of google.rpc.Code.
"details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
"a_key": "", # Properties of the object. Contains field @type with type URL.
},
],
"message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
"evaluationConfig": { # The Evalution configuration used for the evaluation run. # Required. The configuration used for the evaluation.
"autoraterConfig": { # The autorater config used for the evaluation run. # Optional. The autorater config for the evaluation run.
"autoraterModel": "A String", # Optional. The fully qualified name of the publisher model or tuned autorater endpoint to use. Publisher model format: `projects/{project}/locations/{location}/publishers/*/models/*` Tuned model endpoint format: `projects/{project}/locations/{location}/endpoints/{endpoint}`
"generationConfig": { # Configuration for content generation. This message contains all the parameters that control how the model generates content. It allows you to influence the randomness, length, and structure of the output. # Optional. Configuration options for model generation and outputs.
"audioTimestamp": True or False, # Optional. If enabled, audio timestamps will be included in the request to the model. This can be useful for synchronizing audio with other modalities in the response.
"candidateCount": 42, # Optional. The number of candidate responses to generate. A higher `candidate_count` can provide more options to choose from, but it also consumes more resources. This can be useful for generating a variety of responses and selecting the best one.
"enableAffectiveDialog": True or False, # Optional. If enabled, the model will detect emotions and adapt its responses accordingly. For example, if the model detects that the user is frustrated, it may provide a more empathetic response.
"frequencyPenalty": 3.14, # Optional. Penalizes tokens based on their frequency in the generated text. A positive value helps to reduce the repetition of words and phrases. Valid values can range from [-2.0, 2.0].
"imageConfig": { # Configuration for image generation. This message allows you to control various aspects of image generation, such as the output format, aspect ratio, and whether the model can generate images of people. # Optional. Config for image generation features.
"aspectRatio": "A String", # Optional. The desired aspect ratio for the generated images. The following aspect ratios are supported: "1:1" "2:3", "3:2" "3:4", "4:3" "4:5", "5:4" "9:16", "16:9" "21:9"
"imageOutputOptions": { # The image output format for generated images. # Optional. The image output format for generated images.
"compressionQuality": 42, # Optional. The compression quality of the output image.
"mimeType": "A String", # Optional. The image format that the output should be saved as.
},
"imageSize": "A String", # Optional. Specifies the size of generated images. Supported values are `1K`, `2K`, `4K`. If not specified, the model will use default value `1K`.
"personGeneration": "A String", # Optional. Controls whether the model can generate people.
},
"logprobs": 42, # Optional. The number of top log probabilities to return for each token. This can be used to see which other tokens were considered likely candidates for a given position. A higher value will return more options, but it will also increase the size of the response.
"maxOutputTokens": 42, # Optional. The maximum number of tokens to generate in the response. A token is approximately four characters. The default value varies by model. This parameter can be used to control the length of the generated text and prevent overly long responses.
"mediaResolution": "A String", # Optional. The token resolution at which input media content is sampled. This is used to control the trade-off between the quality of the response and the number of tokens used to represent the media. A higher resolution allows the model to perceive more detail, which can lead to a more nuanced response, but it will also use more tokens. This does not affect the image dimensions sent to the model.
"presencePenalty": 3.14, # Optional. Penalizes tokens that have already appeared in the generated text. A positive value encourages the model to generate more diverse and less repetitive text. Valid values can range from [-2.0, 2.0].
"responseJsonSchema": "", # Optional. When this field is set, response_schema must be omitted and response_mime_type must be set to `application/json`.
"responseLogprobs": True or False, # 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.
"responseMimeType": "A String", # 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. This is a preview feature.
"responseModalities": [ # 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.
"A String",
],
"responseSchema": { # Defines the schema of input and output data. This is a subset of the [OpenAPI 3.0 Schema Object](https://spec.openapis.org/oas/v3.0.3#schema-object). # 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`.
"additionalProperties": "", # Optional. If `type` is `OBJECT`, specifies how to handle properties not defined in `properties`. If it is a boolean `false`, no additional properties are allowed. If it is a schema, additional properties are allowed if they conform to the schema.
"anyOf": [ # Optional. The instance must be valid against any (one or more) of the subschemas listed in `any_of`.
# Object with schema name: GoogleCloudAiplatformV1Schema
],
"default": "", # Optional. Default value to use if the field is not specified.
"defs": { # Optional. `defs` provides a map of schema definitions that can be reused by `ref` elsewhere in the schema. Only allowed at root level of the schema.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"description": "A String", # Optional. Description of the schema.
"enum": [ # Optional. Possible values of the field. This field can be used to restrict a value to a fixed set of values. To mark a field as an enum, set `format` to `enum` and provide the list of possible values in `enum`. For example: 1. To define directions: `{type:STRING, format:enum, enum:["EAST", "NORTH", "SOUTH", "WEST"]}` 2. To define apartment numbers: `{type:INTEGER, format:enum, enum:["101", "201", "301"]}`
"A String",
],
"example": "", # Optional. Example of an instance of this schema.
"format": "A String", # Optional. The format of the data. For `NUMBER` type, format can be `float` or `double`. For `INTEGER` type, format can be `int32` or `int64`. For `STRING` type, format can be `email`, `byte`, `date`, `date-time`, `password`, and other formats to further refine the data type.
"items": # Object with schema name: GoogleCloudAiplatformV1Schema # Optional. If type is `ARRAY`, `items` specifies the schema of elements in the array.
"maxItems": "A String", # Optional. If type is `ARRAY`, `max_items` specifies the maximum number of items in an array.
"maxLength": "A String", # Optional. If type is `STRING`, `max_length` specifies the maximum length of the string.
"maxProperties": "A String", # Optional. If type is `OBJECT`, `max_properties` specifies the maximum number of properties that can be provided.
"maximum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `maximum` specifies the maximum allowed value.
"minItems": "A String", # Optional. If type is `ARRAY`, `min_items` specifies the minimum number of items in an array.
"minLength": "A String", # Optional. If type is `STRING`, `min_length` specifies the minimum length of the string.
"minProperties": "A String", # Optional. If type is `OBJECT`, `min_properties` specifies the minimum number of properties that can be provided.
"minimum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `minimum` specifies the minimum allowed value.
"nullable": True or False, # Optional. Indicates if the value of this field can be null.
"pattern": "A String", # Optional. If type is `STRING`, `pattern` specifies a regular expression that the string must match.
"properties": { # Optional. If type is `OBJECT`, `properties` is a map of property names to schema definitions for each property of the object.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"propertyOrdering": [ # Optional. Order of properties displayed or used where order matters. This is not a standard field in OpenAPI specification, but can be used to control the order of properties.
"A String",
],
"ref": "A String", # Optional. Allows referencing another schema definition to use in place of this schema. The value must be a valid reference to a schema in `defs`. For example, the following schema defines a reference to a schema node named "Pet": type: object properties: pet: ref: #/defs/Pet defs: Pet: type: object properties: name: type: string The value of the "pet" property is a reference to the schema node named "Pet". See details in https://json-schema.org/understanding-json-schema/structuring
"required": [ # Optional. If type is `OBJECT`, `required` lists the names of properties that must be present.
"A String",
],
"title": "A String", # Optional. Title for the schema.
"type": "A String", # Optional. Data type of the schema field.
},
"routingConfig": { # 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. # Optional. Routing configuration.
"autoMode": { # The configuration for automated routing. When automated routing is specified, the routing will be determined by the pretrained routing model and customer provided model routing preference. # In this mode, the model is selected automatically based on the content of the request.
"modelRoutingPreference": "A String", # The model routing preference.
},
"manualMode": { # The configuration for manual routing. When manual routing is specified, the model will be selected based on the model name provided. # In this mode, the model is specified manually.
"modelName": "A String", # The name of the model to use. Only public LLM models are accepted.
},
},
"seed": 42, # Optional. A seed for the random number generator. By setting a seed, you can make the model's output mostly deterministic. For a given prompt and parameters (like temperature, top_p, etc.), the model will produce the same response every time. However, it's not a guaranteed absolute deterministic behavior. This is different from parameters like `temperature`, which control the *level* of randomness. `seed` ensures that the "random" choices the model makes are the same on every run, making it essential for testing and ensuring reproducible results.
"speechConfig": { # Configuration for speech generation. # Optional. The speech generation config.
"languageCode": "A String", # Optional. The language code (ISO 639-1) for the speech synthesis.
"multiSpeakerVoiceConfig": { # Configuration for a multi-speaker text-to-speech request. # The configuration for a multi-speaker text-to-speech request. This field is mutually exclusive with `voice_config`.
"speakerVoiceConfigs": [ # Required. A list of configurations for the voices of the speakers. Exactly two speaker voice configurations must be provided.
{ # Configuration for a single speaker in a multi-speaker setup.
"speaker": "A String", # Required. The name of the speaker. This should be the same as the speaker name used in the prompt.
"voiceConfig": { # Configuration for a voice. # Required. The configuration for the voice of this speaker.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
],
},
"voiceConfig": { # Configuration for a voice. # The configuration for the voice to use.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
"stopSequences": [ # Optional. A list of character sequences that will stop the model from generating further tokens. If a stop sequence is generated, the output will end at that point. This is useful for controlling the length and structure of the output. For example, you can use ["\n", "###"] to stop generation at a new line or a specific marker.
"A String",
],
"temperature": 3.14, # Optional. Controls the randomness of the output. A higher temperature results in more creative and diverse responses, while a lower temperature makes the output more predictable and focused. The valid range is (0.0, 2.0].
"thinkingConfig": { # Configuration for the model's thinking features. "Thinking" is a process where the model breaks down a complex task into smaller, manageable steps. This allows the model to reason about the task, plan its approach, and execute the plan to generate a high-quality response. # Optional. Configuration for thinking features. An error will be returned if this field is set for models that don't support thinking.
"includeThoughts": True or False, # Optional. If true, the model will include its thoughts in the response. "Thoughts" are the intermediate steps the model takes to arrive at the final response. They can provide insights into the model's reasoning process and help with debugging. If this is true, thoughts are returned only when available.
"thinkingBudget": 42, # Optional. The token budget for the model's thinking process. The model will make a best effort to stay within this budget. This can be used to control the trade-off between response quality and latency.
"thinkingLevel": "A String", # Optional. The number of thoughts tokens that the model should generate.
},
"topK": 3.14, # Optional. Specifies the top-k sampling threshold. The model considers only the top k most probable tokens for the next token. This can be useful for generating more coherent and less random text. For example, a `top_k` of 40 means the model will choose the next word from the 40 most likely words.
"topP": 3.14, # Optional. Specifies the nucleus sampling threshold. The model considers only the smallest set of tokens whose cumulative probability is at least `top_p`. This helps generate more diverse and less repetitive responses. For example, a `top_p` of 0.9 means the model considers tokens until the cumulative probability of the tokens to select from reaches 0.9. It's recommended to adjust either temperature or `top_p`, but not both.
},
"sampleCount": 42, # Optional. Number of samples for each instance in the dataset. If not specified, the default is 4. Minimum value is 1, maximum value is 32.
},
"metrics": [ # Required. The metrics to be calculated in the evaluation run.
{ # The metric used for evaluation runs.
"computationBasedMetricSpec": { # Specification for a computation based metric. # Spec for a computation based metric.
"parameters": { # Optional. A map of parameters for the metric, e.g. {"rouge_type": "rougeL"}.
"a_key": "", # Properties of the object.
},
"type": "A String", # Required. The type of the computation based metric.
},
"llmBasedMetricSpec": { # Specification for an LLM based metric. # Spec for an LLM based metric.
"additionalConfig": { # Optional. Optional additional configuration for the metric.
"a_key": "", # Properties of the object.
},
"judgeAutoraterConfig": { # The autorater config used for the evaluation run. # Optional. Optional configuration for the judge LLM (Autorater).
"autoraterModel": "A String", # Optional. The fully qualified name of the publisher model or tuned autorater endpoint to use. Publisher model format: `projects/{project}/locations/{location}/publishers/*/models/*` Tuned model endpoint format: `projects/{project}/locations/{location}/endpoints/{endpoint}`
"generationConfig": { # Configuration for content generation. This message contains all the parameters that control how the model generates content. It allows you to influence the randomness, length, and structure of the output. # Optional. Configuration options for model generation and outputs.
"audioTimestamp": True or False, # Optional. If enabled, audio timestamps will be included in the request to the model. This can be useful for synchronizing audio with other modalities in the response.
"candidateCount": 42, # Optional. The number of candidate responses to generate. A higher `candidate_count` can provide more options to choose from, but it also consumes more resources. This can be useful for generating a variety of responses and selecting the best one.
"enableAffectiveDialog": True or False, # Optional. If enabled, the model will detect emotions and adapt its responses accordingly. For example, if the model detects that the user is frustrated, it may provide a more empathetic response.
"frequencyPenalty": 3.14, # Optional. Penalizes tokens based on their frequency in the generated text. A positive value helps to reduce the repetition of words and phrases. Valid values can range from [-2.0, 2.0].
"imageConfig": { # Configuration for image generation. This message allows you to control various aspects of image generation, such as the output format, aspect ratio, and whether the model can generate images of people. # Optional. Config for image generation features.
"aspectRatio": "A String", # Optional. The desired aspect ratio for the generated images. The following aspect ratios are supported: "1:1" "2:3", "3:2" "3:4", "4:3" "4:5", "5:4" "9:16", "16:9" "21:9"
"imageOutputOptions": { # The image output format for generated images. # Optional. The image output format for generated images.
"compressionQuality": 42, # Optional. The compression quality of the output image.
"mimeType": "A String", # Optional. The image format that the output should be saved as.
},
"imageSize": "A String", # Optional. Specifies the size of generated images. Supported values are `1K`, `2K`, `4K`. If not specified, the model will use default value `1K`.
"personGeneration": "A String", # Optional. Controls whether the model can generate people.
},
"logprobs": 42, # Optional. The number of top log probabilities to return for each token. This can be used to see which other tokens were considered likely candidates for a given position. A higher value will return more options, but it will also increase the size of the response.
"maxOutputTokens": 42, # Optional. The maximum number of tokens to generate in the response. A token is approximately four characters. The default value varies by model. This parameter can be used to control the length of the generated text and prevent overly long responses.
"mediaResolution": "A String", # Optional. The token resolution at which input media content is sampled. This is used to control the trade-off between the quality of the response and the number of tokens used to represent the media. A higher resolution allows the model to perceive more detail, which can lead to a more nuanced response, but it will also use more tokens. This does not affect the image dimensions sent to the model.
"presencePenalty": 3.14, # Optional. Penalizes tokens that have already appeared in the generated text. A positive value encourages the model to generate more diverse and less repetitive text. Valid values can range from [-2.0, 2.0].
"responseJsonSchema": "", # Optional. When this field is set, response_schema must be omitted and response_mime_type must be set to `application/json`.
"responseLogprobs": True or False, # 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.
"responseMimeType": "A String", # 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. This is a preview feature.
"responseModalities": [ # 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.
"A String",
],
"responseSchema": { # Defines the schema of input and output data. This is a subset of the [OpenAPI 3.0 Schema Object](https://spec.openapis.org/oas/v3.0.3#schema-object). # 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`.
"additionalProperties": "", # Optional. If `type` is `OBJECT`, specifies how to handle properties not defined in `properties`. If it is a boolean `false`, no additional properties are allowed. If it is a schema, additional properties are allowed if they conform to the schema.
"anyOf": [ # Optional. The instance must be valid against any (one or more) of the subschemas listed in `any_of`.
# Object with schema name: GoogleCloudAiplatformV1Schema
],
"default": "", # Optional. Default value to use if the field is not specified.
"defs": { # Optional. `defs` provides a map of schema definitions that can be reused by `ref` elsewhere in the schema. Only allowed at root level of the schema.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"description": "A String", # Optional. Description of the schema.
"enum": [ # Optional. Possible values of the field. This field can be used to restrict a value to a fixed set of values. To mark a field as an enum, set `format` to `enum` and provide the list of possible values in `enum`. For example: 1. To define directions: `{type:STRING, format:enum, enum:["EAST", "NORTH", "SOUTH", "WEST"]}` 2. To define apartment numbers: `{type:INTEGER, format:enum, enum:["101", "201", "301"]}`
"A String",
],
"example": "", # Optional. Example of an instance of this schema.
"format": "A String", # Optional. The format of the data. For `NUMBER` type, format can be `float` or `double`. For `INTEGER` type, format can be `int32` or `int64`. For `STRING` type, format can be `email`, `byte`, `date`, `date-time`, `password`, and other formats to further refine the data type.
"items": # Object with schema name: GoogleCloudAiplatformV1Schema # Optional. If type is `ARRAY`, `items` specifies the schema of elements in the array.
"maxItems": "A String", # Optional. If type is `ARRAY`, `max_items` specifies the maximum number of items in an array.
"maxLength": "A String", # Optional. If type is `STRING`, `max_length` specifies the maximum length of the string.
"maxProperties": "A String", # Optional. If type is `OBJECT`, `max_properties` specifies the maximum number of properties that can be provided.
"maximum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `maximum` specifies the maximum allowed value.
"minItems": "A String", # Optional. If type is `ARRAY`, `min_items` specifies the minimum number of items in an array.
"minLength": "A String", # Optional. If type is `STRING`, `min_length` specifies the minimum length of the string.
"minProperties": "A String", # Optional. If type is `OBJECT`, `min_properties` specifies the minimum number of properties that can be provided.
"minimum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `minimum` specifies the minimum allowed value.
"nullable": True or False, # Optional. Indicates if the value of this field can be null.
"pattern": "A String", # Optional. If type is `STRING`, `pattern` specifies a regular expression that the string must match.
"properties": { # Optional. If type is `OBJECT`, `properties` is a map of property names to schema definitions for each property of the object.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"propertyOrdering": [ # Optional. Order of properties displayed or used where order matters. This is not a standard field in OpenAPI specification, but can be used to control the order of properties.
"A String",
],
"ref": "A String", # Optional. Allows referencing another schema definition to use in place of this schema. The value must be a valid reference to a schema in `defs`. For example, the following schema defines a reference to a schema node named "Pet": type: object properties: pet: ref: #/defs/Pet defs: Pet: type: object properties: name: type: string The value of the "pet" property is a reference to the schema node named "Pet". See details in https://json-schema.org/understanding-json-schema/structuring
"required": [ # Optional. If type is `OBJECT`, `required` lists the names of properties that must be present.
"A String",
],
"title": "A String", # Optional. Title for the schema.
"type": "A String", # Optional. Data type of the schema field.
},
"routingConfig": { # 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. # Optional. Routing configuration.
"autoMode": { # The configuration for automated routing. When automated routing is specified, the routing will be determined by the pretrained routing model and customer provided model routing preference. # In this mode, the model is selected automatically based on the content of the request.
"modelRoutingPreference": "A String", # The model routing preference.
},
"manualMode": { # The configuration for manual routing. When manual routing is specified, the model will be selected based on the model name provided. # In this mode, the model is specified manually.
"modelName": "A String", # The name of the model to use. Only public LLM models are accepted.
},
},
"seed": 42, # Optional. A seed for the random number generator. By setting a seed, you can make the model's output mostly deterministic. For a given prompt and parameters (like temperature, top_p, etc.), the model will produce the same response every time. However, it's not a guaranteed absolute deterministic behavior. This is different from parameters like `temperature`, which control the *level* of randomness. `seed` ensures that the "random" choices the model makes are the same on every run, making it essential for testing and ensuring reproducible results.
"speechConfig": { # Configuration for speech generation. # Optional. The speech generation config.
"languageCode": "A String", # Optional. The language code (ISO 639-1) for the speech synthesis.
"multiSpeakerVoiceConfig": { # Configuration for a multi-speaker text-to-speech request. # The configuration for a multi-speaker text-to-speech request. This field is mutually exclusive with `voice_config`.
"speakerVoiceConfigs": [ # Required. A list of configurations for the voices of the speakers. Exactly two speaker voice configurations must be provided.
{ # Configuration for a single speaker in a multi-speaker setup.
"speaker": "A String", # Required. The name of the speaker. This should be the same as the speaker name used in the prompt.
"voiceConfig": { # Configuration for a voice. # Required. The configuration for the voice of this speaker.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
],
},
"voiceConfig": { # Configuration for a voice. # The configuration for the voice to use.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
"stopSequences": [ # Optional. A list of character sequences that will stop the model from generating further tokens. If a stop sequence is generated, the output will end at that point. This is useful for controlling the length and structure of the output. For example, you can use ["\n", "###"] to stop generation at a new line or a specific marker.
"A String",
],
"temperature": 3.14, # Optional. Controls the randomness of the output. A higher temperature results in more creative and diverse responses, while a lower temperature makes the output more predictable and focused. The valid range is (0.0, 2.0].
"thinkingConfig": { # Configuration for the model's thinking features. "Thinking" is a process where the model breaks down a complex task into smaller, manageable steps. This allows the model to reason about the task, plan its approach, and execute the plan to generate a high-quality response. # Optional. Configuration for thinking features. An error will be returned if this field is set for models that don't support thinking.
"includeThoughts": True or False, # Optional. If true, the model will include its thoughts in the response. "Thoughts" are the intermediate steps the model takes to arrive at the final response. They can provide insights into the model's reasoning process and help with debugging. If this is true, thoughts are returned only when available.
"thinkingBudget": 42, # Optional. The token budget for the model's thinking process. The model will make a best effort to stay within this budget. This can be used to control the trade-off between response quality and latency.
"thinkingLevel": "A String", # Optional. The number of thoughts tokens that the model should generate.
},
"topK": 3.14, # Optional. Specifies the top-k sampling threshold. The model considers only the top k most probable tokens for the next token. This can be useful for generating more coherent and less random text. For example, a `top_k` of 40 means the model will choose the next word from the 40 most likely words.
"topP": 3.14, # Optional. Specifies the nucleus sampling threshold. The model considers only the smallest set of tokens whose cumulative probability is at least `top_p`. This helps generate more diverse and less repetitive responses. For example, a `top_p` of 0.9 means the model considers tokens until the cumulative probability of the tokens to select from reaches 0.9. It's recommended to adjust either temperature or `top_p`, but not both.
},
"sampleCount": 42, # Optional. Number of samples for each instance in the dataset. If not specified, the default is 4. Minimum value is 1, maximum value is 32.
},
"metricPromptTemplate": "A String", # Required. Template for the prompt sent to the judge model.
"predefinedRubricGenerationSpec": { # Specification for a pre-defined metric. # Dynamically generate rubrics using a predefined spec.
"metricSpecName": "A String", # Required. The name of a pre-defined metric, such as "instruction_following_v1" or "text_quality_v1".
"parameters": { # Optional. The parameters needed to run the pre-defined metric.
"a_key": "", # Properties of the object.
},
},
"rubricGenerationSpec": { # Specification for how rubrics should be generated. # Dynamically generate rubrics using this specification.
"modelConfig": { # The autorater config used for the evaluation run. # Optional. Configuration for the model used in rubric generation. Configs including sampling count and base model can be specified here. Flipping is not supported for rubric generation.
"autoraterModel": "A String", # Optional. The fully qualified name of the publisher model or tuned autorater endpoint to use. Publisher model format: `projects/{project}/locations/{location}/publishers/*/models/*` Tuned model endpoint format: `projects/{project}/locations/{location}/endpoints/{endpoint}`
"generationConfig": { # Configuration for content generation. This message contains all the parameters that control how the model generates content. It allows you to influence the randomness, length, and structure of the output. # Optional. Configuration options for model generation and outputs.
"audioTimestamp": True or False, # Optional. If enabled, audio timestamps will be included in the request to the model. This can be useful for synchronizing audio with other modalities in the response.
"candidateCount": 42, # Optional. The number of candidate responses to generate. A higher `candidate_count` can provide more options to choose from, but it also consumes more resources. This can be useful for generating a variety of responses and selecting the best one.
"enableAffectiveDialog": True or False, # Optional. If enabled, the model will detect emotions and adapt its responses accordingly. For example, if the model detects that the user is frustrated, it may provide a more empathetic response.
"frequencyPenalty": 3.14, # Optional. Penalizes tokens based on their frequency in the generated text. A positive value helps to reduce the repetition of words and phrases. Valid values can range from [-2.0, 2.0].
"imageConfig": { # Configuration for image generation. This message allows you to control various aspects of image generation, such as the output format, aspect ratio, and whether the model can generate images of people. # Optional. Config for image generation features.
"aspectRatio": "A String", # Optional. The desired aspect ratio for the generated images. The following aspect ratios are supported: "1:1" "2:3", "3:2" "3:4", "4:3" "4:5", "5:4" "9:16", "16:9" "21:9"
"imageOutputOptions": { # The image output format for generated images. # Optional. The image output format for generated images.
"compressionQuality": 42, # Optional. The compression quality of the output image.
"mimeType": "A String", # Optional. The image format that the output should be saved as.
},
"imageSize": "A String", # Optional. Specifies the size of generated images. Supported values are `1K`, `2K`, `4K`. If not specified, the model will use default value `1K`.
"personGeneration": "A String", # Optional. Controls whether the model can generate people.
},
"logprobs": 42, # Optional. The number of top log probabilities to return for each token. This can be used to see which other tokens were considered likely candidates for a given position. A higher value will return more options, but it will also increase the size of the response.
"maxOutputTokens": 42, # Optional. The maximum number of tokens to generate in the response. A token is approximately four characters. The default value varies by model. This parameter can be used to control the length of the generated text and prevent overly long responses.
"mediaResolution": "A String", # Optional. The token resolution at which input media content is sampled. This is used to control the trade-off between the quality of the response and the number of tokens used to represent the media. A higher resolution allows the model to perceive more detail, which can lead to a more nuanced response, but it will also use more tokens. This does not affect the image dimensions sent to the model.
"presencePenalty": 3.14, # Optional. Penalizes tokens that have already appeared in the generated text. A positive value encourages the model to generate more diverse and less repetitive text. Valid values can range from [-2.0, 2.0].
"responseJsonSchema": "", # Optional. When this field is set, response_schema must be omitted and response_mime_type must be set to `application/json`.
"responseLogprobs": True or False, # 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.
"responseMimeType": "A String", # 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. This is a preview feature.
"responseModalities": [ # 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.
"A String",
],
"responseSchema": { # Defines the schema of input and output data. This is a subset of the [OpenAPI 3.0 Schema Object](https://spec.openapis.org/oas/v3.0.3#schema-object). # 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`.
"additionalProperties": "", # Optional. If `type` is `OBJECT`, specifies how to handle properties not defined in `properties`. If it is a boolean `false`, no additional properties are allowed. If it is a schema, additional properties are allowed if they conform to the schema.
"anyOf": [ # Optional. The instance must be valid against any (one or more) of the subschemas listed in `any_of`.
# Object with schema name: GoogleCloudAiplatformV1Schema
],
"default": "", # Optional. Default value to use if the field is not specified.
"defs": { # Optional. `defs` provides a map of schema definitions that can be reused by `ref` elsewhere in the schema. Only allowed at root level of the schema.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"description": "A String", # Optional. Description of the schema.
"enum": [ # Optional. Possible values of the field. This field can be used to restrict a value to a fixed set of values. To mark a field as an enum, set `format` to `enum` and provide the list of possible values in `enum`. For example: 1. To define directions: `{type:STRING, format:enum, enum:["EAST", "NORTH", "SOUTH", "WEST"]}` 2. To define apartment numbers: `{type:INTEGER, format:enum, enum:["101", "201", "301"]}`
"A String",
],
"example": "", # Optional. Example of an instance of this schema.
"format": "A String", # Optional. The format of the data. For `NUMBER` type, format can be `float` or `double`. For `INTEGER` type, format can be `int32` or `int64`. For `STRING` type, format can be `email`, `byte`, `date`, `date-time`, `password`, and other formats to further refine the data type.
"items": # Object with schema name: GoogleCloudAiplatformV1Schema # Optional. If type is `ARRAY`, `items` specifies the schema of elements in the array.
"maxItems": "A String", # Optional. If type is `ARRAY`, `max_items` specifies the maximum number of items in an array.
"maxLength": "A String", # Optional. If type is `STRING`, `max_length` specifies the maximum length of the string.
"maxProperties": "A String", # Optional. If type is `OBJECT`, `max_properties` specifies the maximum number of properties that can be provided.
"maximum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `maximum` specifies the maximum allowed value.
"minItems": "A String", # Optional. If type is `ARRAY`, `min_items` specifies the minimum number of items in an array.
"minLength": "A String", # Optional. If type is `STRING`, `min_length` specifies the minimum length of the string.
"minProperties": "A String", # Optional. If type is `OBJECT`, `min_properties` specifies the minimum number of properties that can be provided.
"minimum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `minimum` specifies the minimum allowed value.
"nullable": True or False, # Optional. Indicates if the value of this field can be null.
"pattern": "A String", # Optional. If type is `STRING`, `pattern` specifies a regular expression that the string must match.
"properties": { # Optional. If type is `OBJECT`, `properties` is a map of property names to schema definitions for each property of the object.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"propertyOrdering": [ # Optional. Order of properties displayed or used where order matters. This is not a standard field in OpenAPI specification, but can be used to control the order of properties.
"A String",
],
"ref": "A String", # Optional. Allows referencing another schema definition to use in place of this schema. The value must be a valid reference to a schema in `defs`. For example, the following schema defines a reference to a schema node named "Pet": type: object properties: pet: ref: #/defs/Pet defs: Pet: type: object properties: name: type: string The value of the "pet" property is a reference to the schema node named "Pet". See details in https://json-schema.org/understanding-json-schema/structuring
"required": [ # Optional. If type is `OBJECT`, `required` lists the names of properties that must be present.
"A String",
],
"title": "A String", # Optional. Title for the schema.
"type": "A String", # Optional. Data type of the schema field.
},
"routingConfig": { # 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. # Optional. Routing configuration.
"autoMode": { # The configuration for automated routing. When automated routing is specified, the routing will be determined by the pretrained routing model and customer provided model routing preference. # In this mode, the model is selected automatically based on the content of the request.
"modelRoutingPreference": "A String", # The model routing preference.
},
"manualMode": { # The configuration for manual routing. When manual routing is specified, the model will be selected based on the model name provided. # In this mode, the model is specified manually.
"modelName": "A String", # The name of the model to use. Only public LLM models are accepted.
},
},
"seed": 42, # Optional. A seed for the random number generator. By setting a seed, you can make the model's output mostly deterministic. For a given prompt and parameters (like temperature, top_p, etc.), the model will produce the same response every time. However, it's not a guaranteed absolute deterministic behavior. This is different from parameters like `temperature`, which control the *level* of randomness. `seed` ensures that the "random" choices the model makes are the same on every run, making it essential for testing and ensuring reproducible results.
"speechConfig": { # Configuration for speech generation. # Optional. The speech generation config.
"languageCode": "A String", # Optional. The language code (ISO 639-1) for the speech synthesis.
"multiSpeakerVoiceConfig": { # Configuration for a multi-speaker text-to-speech request. # The configuration for a multi-speaker text-to-speech request. This field is mutually exclusive with `voice_config`.
"speakerVoiceConfigs": [ # Required. A list of configurations for the voices of the speakers. Exactly two speaker voice configurations must be provided.
{ # Configuration for a single speaker in a multi-speaker setup.
"speaker": "A String", # Required. The name of the speaker. This should be the same as the speaker name used in the prompt.
"voiceConfig": { # Configuration for a voice. # Required. The configuration for the voice of this speaker.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
],
},
"voiceConfig": { # Configuration for a voice. # The configuration for the voice to use.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
"stopSequences": [ # Optional. A list of character sequences that will stop the model from generating further tokens. If a stop sequence is generated, the output will end at that point. This is useful for controlling the length and structure of the output. For example, you can use ["\n", "###"] to stop generation at a new line or a specific marker.
"A String",
],
"temperature": 3.14, # Optional. Controls the randomness of the output. A higher temperature results in more creative and diverse responses, while a lower temperature makes the output more predictable and focused. The valid range is (0.0, 2.0].
"thinkingConfig": { # Configuration for the model's thinking features. "Thinking" is a process where the model breaks down a complex task into smaller, manageable steps. This allows the model to reason about the task, plan its approach, and execute the plan to generate a high-quality response. # Optional. Configuration for thinking features. An error will be returned if this field is set for models that don't support thinking.
"includeThoughts": True or False, # Optional. If true, the model will include its thoughts in the response. "Thoughts" are the intermediate steps the model takes to arrive at the final response. They can provide insights into the model's reasoning process and help with debugging. If this is true, thoughts are returned only when available.
"thinkingBudget": 42, # Optional. The token budget for the model's thinking process. The model will make a best effort to stay within this budget. This can be used to control the trade-off between response quality and latency.
"thinkingLevel": "A String", # Optional. The number of thoughts tokens that the model should generate.
},
"topK": 3.14, # Optional. Specifies the top-k sampling threshold. The model considers only the top k most probable tokens for the next token. This can be useful for generating more coherent and less random text. For example, a `top_k` of 40 means the model will choose the next word from the 40 most likely words.
"topP": 3.14, # Optional. Specifies the nucleus sampling threshold. The model considers only the smallest set of tokens whose cumulative probability is at least `top_p`. This helps generate more diverse and less repetitive responses. For example, a `top_p` of 0.9 means the model considers tokens until the cumulative probability of the tokens to select from reaches 0.9. It's recommended to adjust either temperature or `top_p`, but not both.
},
"sampleCount": 42, # Optional. Number of samples for each instance in the dataset. If not specified, the default is 4. Minimum value is 1, maximum value is 32.
},
"promptTemplate": "A String", # Optional. Template for the prompt used to generate rubrics. The details should be updated based on the most-recent recipe requirements.
"rubricContentType": "A String", # Optional. The type of rubric content to be generated.
"rubricTypeOntology": [ # Optional. An optional, pre-defined list of allowed types for generated rubrics. If this field is provided, it implies `include_rubric_type` should be true, and the generated rubric types should be chosen from this ontology.
"A String",
],
},
"rubricGroupKey": "A String", # Use a pre-defined group of rubrics associated with the input. Refers to a key in the rubric_groups map of EvaluationInstance.
"systemInstruction": "A String", # Optional. System instructions for the judge model.
},
"metric": "A String", # Required. The name of the metric.
"metricConfig": { # The metric used for running evaluations. # The metric config.
"aggregationMetrics": [ # Optional. The aggregation metrics to use.
"A String",
],
"bleuSpec": { # Spec for bleu score metric - calculates the precision of n-grams in the prediction as compared to reference - returns a score ranging between 0 to 1. # Spec for bleu metric.
"useEffectiveOrder": True or False, # Optional. Whether to use_effective_order to compute bleu score.
},
"computationBasedMetricSpec": { # Specification for a computation based metric. # Spec for a computation based metric.
"parameters": { # Optional. A map of parameters for the metric, e.g. {"rouge_type": "rougeL"}.
"a_key": "", # Properties of the object.
},
"type": "A String", # Required. The type of the computation based metric.
},
"customCodeExecutionSpec": { # Specificies a metric that is populated by evaluating user-defined Python code. # Spec for Custom Code Execution metric.
"evaluationFunction": "A String", # Required. Python function. Expected user to define the following function, e.g.: def evaluate(instance: dict[str, Any]) -> float: Please include this function signature in the code snippet. Instance is the evaluation instance, any fields populated in the instance are available to the function as instance[field_name]. Example: Example input: ``` instance= EvaluationInstance( response=EvaluationInstance.InstanceData(text="The answer is 4."), reference=EvaluationInstance.InstanceData(text="4") ) ``` Example converted input: ``` { 'response': {'text': 'The answer is 4.'}, 'reference': {'text': '4'} } ``` Example python function: ``` def evaluate(instance: dict[str, Any]) -> float: if instance'response' == instance'reference': return 1.0 return 0.0 ``` CustomCodeExecutionSpec is also supported in Batch Evaluation (EvalDataset RPC) and Tuning Evaluation. Each line in the input jsonl file will be converted to dict[str, Any] and passed to the evaluation function.
},
"exactMatchSpec": { # Spec for exact match metric - returns 1 if prediction and reference exactly matches, otherwise 0. # Spec for exact match metric.
},
"llmBasedMetricSpec": { # Specification for an LLM based metric. # Spec for an LLM based metric.
"additionalConfig": { # Optional. Optional additional configuration for the metric.
"a_key": "", # Properties of the object.
},
"judgeAutoraterConfig": { # The configs for autorater. This is applicable to both EvaluateInstances and EvaluateDataset. # Optional. Optional configuration for the judge LLM (Autorater).
"autoraterModel": "A String", # Optional. The fully qualified name of the publisher model or tuned autorater endpoint to use. Publisher model format: `projects/{project}/locations/{location}/publishers/*/models/*` Tuned model endpoint format: `projects/{project}/locations/{location}/endpoints/{endpoint}`
"flipEnabled": True or False, # Optional. Default is true. Whether to flip the candidate and baseline responses. This is only applicable to the pairwise metric. If enabled, also provide PairwiseMetricSpec.candidate_response_field_name and PairwiseMetricSpec.baseline_response_field_name. When rendering PairwiseMetricSpec.metric_prompt_template, the candidate and baseline fields will be flipped for half of the samples to reduce bias.
"generationConfig": { # Configuration for content generation. This message contains all the parameters that control how the model generates content. It allows you to influence the randomness, length, and structure of the output. # Optional. Configuration options for model generation and outputs.
"audioTimestamp": True or False, # Optional. If enabled, audio timestamps will be included in the request to the model. This can be useful for synchronizing audio with other modalities in the response.
"candidateCount": 42, # Optional. The number of candidate responses to generate. A higher `candidate_count` can provide more options to choose from, but it also consumes more resources. This can be useful for generating a variety of responses and selecting the best one.
"enableAffectiveDialog": True or False, # Optional. If enabled, the model will detect emotions and adapt its responses accordingly. For example, if the model detects that the user is frustrated, it may provide a more empathetic response.
"frequencyPenalty": 3.14, # Optional. Penalizes tokens based on their frequency in the generated text. A positive value helps to reduce the repetition of words and phrases. Valid values can range from [-2.0, 2.0].
"imageConfig": { # Configuration for image generation. This message allows you to control various aspects of image generation, such as the output format, aspect ratio, and whether the model can generate images of people. # Optional. Config for image generation features.
"aspectRatio": "A String", # Optional. The desired aspect ratio for the generated images. The following aspect ratios are supported: "1:1" "2:3", "3:2" "3:4", "4:3" "4:5", "5:4" "9:16", "16:9" "21:9"
"imageOutputOptions": { # The image output format for generated images. # Optional. The image output format for generated images.
"compressionQuality": 42, # Optional. The compression quality of the output image.
"mimeType": "A String", # Optional. The image format that the output should be saved as.
},
"imageSize": "A String", # Optional. Specifies the size of generated images. Supported values are `1K`, `2K`, `4K`. If not specified, the model will use default value `1K`.
"personGeneration": "A String", # Optional. Controls whether the model can generate people.
},
"logprobs": 42, # Optional. The number of top log probabilities to return for each token. This can be used to see which other tokens were considered likely candidates for a given position. A higher value will return more options, but it will also increase the size of the response.
"maxOutputTokens": 42, # Optional. The maximum number of tokens to generate in the response. A token is approximately four characters. The default value varies by model. This parameter can be used to control the length of the generated text and prevent overly long responses.
"mediaResolution": "A String", # Optional. The token resolution at which input media content is sampled. This is used to control the trade-off between the quality of the response and the number of tokens used to represent the media. A higher resolution allows the model to perceive more detail, which can lead to a more nuanced response, but it will also use more tokens. This does not affect the image dimensions sent to the model.
"presencePenalty": 3.14, # Optional. Penalizes tokens that have already appeared in the generated text. A positive value encourages the model to generate more diverse and less repetitive text. Valid values can range from [-2.0, 2.0].
"responseJsonSchema": "", # Optional. When this field is set, response_schema must be omitted and response_mime_type must be set to `application/json`.
"responseLogprobs": True or False, # 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.
"responseMimeType": "A String", # 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. This is a preview feature.
"responseModalities": [ # 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.
"A String",
],
"responseSchema": { # Defines the schema of input and output data. This is a subset of the [OpenAPI 3.0 Schema Object](https://spec.openapis.org/oas/v3.0.3#schema-object). # 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`.
"additionalProperties": "", # Optional. If `type` is `OBJECT`, specifies how to handle properties not defined in `properties`. If it is a boolean `false`, no additional properties are allowed. If it is a schema, additional properties are allowed if they conform to the schema.
"anyOf": [ # Optional. The instance must be valid against any (one or more) of the subschemas listed in `any_of`.
# Object with schema name: GoogleCloudAiplatformV1Schema
],
"default": "", # Optional. Default value to use if the field is not specified.
"defs": { # Optional. `defs` provides a map of schema definitions that can be reused by `ref` elsewhere in the schema. Only allowed at root level of the schema.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"description": "A String", # Optional. Description of the schema.
"enum": [ # Optional. Possible values of the field. This field can be used to restrict a value to a fixed set of values. To mark a field as an enum, set `format` to `enum` and provide the list of possible values in `enum`. For example: 1. To define directions: `{type:STRING, format:enum, enum:["EAST", "NORTH", "SOUTH", "WEST"]}` 2. To define apartment numbers: `{type:INTEGER, format:enum, enum:["101", "201", "301"]}`
"A String",
],
"example": "", # Optional. Example of an instance of this schema.
"format": "A String", # Optional. The format of the data. For `NUMBER` type, format can be `float` or `double`. For `INTEGER` type, format can be `int32` or `int64`. For `STRING` type, format can be `email`, `byte`, `date`, `date-time`, `password`, and other formats to further refine the data type.
"items": # Object with schema name: GoogleCloudAiplatformV1Schema # Optional. If type is `ARRAY`, `items` specifies the schema of elements in the array.
"maxItems": "A String", # Optional. If type is `ARRAY`, `max_items` specifies the maximum number of items in an array.
"maxLength": "A String", # Optional. If type is `STRING`, `max_length` specifies the maximum length of the string.
"maxProperties": "A String", # Optional. If type is `OBJECT`, `max_properties` specifies the maximum number of properties that can be provided.
"maximum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `maximum` specifies the maximum allowed value.
"minItems": "A String", # Optional. If type is `ARRAY`, `min_items` specifies the minimum number of items in an array.
"minLength": "A String", # Optional. If type is `STRING`, `min_length` specifies the minimum length of the string.
"minProperties": "A String", # Optional. If type is `OBJECT`, `min_properties` specifies the minimum number of properties that can be provided.
"minimum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `minimum` specifies the minimum allowed value.
"nullable": True or False, # Optional. Indicates if the value of this field can be null.
"pattern": "A String", # Optional. If type is `STRING`, `pattern` specifies a regular expression that the string must match.
"properties": { # Optional. If type is `OBJECT`, `properties` is a map of property names to schema definitions for each property of the object.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"propertyOrdering": [ # Optional. Order of properties displayed or used where order matters. This is not a standard field in OpenAPI specification, but can be used to control the order of properties.
"A String",
],
"ref": "A String", # Optional. Allows referencing another schema definition to use in place of this schema. The value must be a valid reference to a schema in `defs`. For example, the following schema defines a reference to a schema node named "Pet": type: object properties: pet: ref: #/defs/Pet defs: Pet: type: object properties: name: type: string The value of the "pet" property is a reference to the schema node named "Pet". See details in https://json-schema.org/understanding-json-schema/structuring
"required": [ # Optional. If type is `OBJECT`, `required` lists the names of properties that must be present.
"A String",
],
"title": "A String", # Optional. Title for the schema.
"type": "A String", # Optional. Data type of the schema field.
},
"routingConfig": { # 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. # Optional. Routing configuration.
"autoMode": { # The configuration for automated routing. When automated routing is specified, the routing will be determined by the pretrained routing model and customer provided model routing preference. # In this mode, the model is selected automatically based on the content of the request.
"modelRoutingPreference": "A String", # The model routing preference.
},
"manualMode": { # The configuration for manual routing. When manual routing is specified, the model will be selected based on the model name provided. # In this mode, the model is specified manually.
"modelName": "A String", # The name of the model to use. Only public LLM models are accepted.
},
},
"seed": 42, # Optional. A seed for the random number generator. By setting a seed, you can make the model's output mostly deterministic. For a given prompt and parameters (like temperature, top_p, etc.), the model will produce the same response every time. However, it's not a guaranteed absolute deterministic behavior. This is different from parameters like `temperature`, which control the *level* of randomness. `seed` ensures that the "random" choices the model makes are the same on every run, making it essential for testing and ensuring reproducible results.
"speechConfig": { # Configuration for speech generation. # Optional. The speech generation config.
"languageCode": "A String", # Optional. The language code (ISO 639-1) for the speech synthesis.
"multiSpeakerVoiceConfig": { # Configuration for a multi-speaker text-to-speech request. # The configuration for a multi-speaker text-to-speech request. This field is mutually exclusive with `voice_config`.
"speakerVoiceConfigs": [ # Required. A list of configurations for the voices of the speakers. Exactly two speaker voice configurations must be provided.
{ # Configuration for a single speaker in a multi-speaker setup.
"speaker": "A String", # Required. The name of the speaker. This should be the same as the speaker name used in the prompt.
"voiceConfig": { # Configuration for a voice. # Required. The configuration for the voice of this speaker.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
],
},
"voiceConfig": { # Configuration for a voice. # The configuration for the voice to use.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
"stopSequences": [ # Optional. A list of character sequences that will stop the model from generating further tokens. If a stop sequence is generated, the output will end at that point. This is useful for controlling the length and structure of the output. For example, you can use ["\n", "###"] to stop generation at a new line or a specific marker.
"A String",
],
"temperature": 3.14, # Optional. Controls the randomness of the output. A higher temperature results in more creative and diverse responses, while a lower temperature makes the output more predictable and focused. The valid range is (0.0, 2.0].
"thinkingConfig": { # Configuration for the model's thinking features. "Thinking" is a process where the model breaks down a complex task into smaller, manageable steps. This allows the model to reason about the task, plan its approach, and execute the plan to generate a high-quality response. # Optional. Configuration for thinking features. An error will be returned if this field is set for models that don't support thinking.
"includeThoughts": True or False, # Optional. If true, the model will include its thoughts in the response. "Thoughts" are the intermediate steps the model takes to arrive at the final response. They can provide insights into the model's reasoning process and help with debugging. If this is true, thoughts are returned only when available.
"thinkingBudget": 42, # Optional. The token budget for the model's thinking process. The model will make a best effort to stay within this budget. This can be used to control the trade-off between response quality and latency.
"thinkingLevel": "A String", # Optional. The number of thoughts tokens that the model should generate.
},
"topK": 3.14, # Optional. Specifies the top-k sampling threshold. The model considers only the top k most probable tokens for the next token. This can be useful for generating more coherent and less random text. For example, a `top_k` of 40 means the model will choose the next word from the 40 most likely words.
"topP": 3.14, # Optional. Specifies the nucleus sampling threshold. The model considers only the smallest set of tokens whose cumulative probability is at least `top_p`. This helps generate more diverse and less repetitive responses. For example, a `top_p` of 0.9 means the model considers tokens until the cumulative probability of the tokens to select from reaches 0.9. It's recommended to adjust either temperature or `top_p`, but not both.
},
"samplingCount": 42, # Optional. Number of samples for each instance in the dataset. If not specified, the default is 4. Minimum value is 1, maximum value is 32.
},
"metricPromptTemplate": "A String", # Required. Template for the prompt sent to the judge model.
"predefinedRubricGenerationSpec": { # The spec for a pre-defined metric. # Dynamically generate rubrics using a predefined spec.
"metricSpecName": "A String", # Required. The name of a pre-defined metric, such as "instruction_following_v1" or "text_quality_v1".
"metricSpecParameters": { # Optional. The parameters needed to run the pre-defined metric.
"a_key": "", # Properties of the object.
},
},
"rubricGenerationSpec": { # Specification for how rubrics should be generated. # Dynamically generate rubrics using this specification.
"modelConfig": { # The configs for autorater. This is applicable to both EvaluateInstances and EvaluateDataset. # Configuration for the model used in rubric generation. Configs including sampling count and base model can be specified here. Flipping is not supported for rubric generation.
"autoraterModel": "A String", # Optional. The fully qualified name of the publisher model or tuned autorater endpoint to use. Publisher model format: `projects/{project}/locations/{location}/publishers/*/models/*` Tuned model endpoint format: `projects/{project}/locations/{location}/endpoints/{endpoint}`
"flipEnabled": True or False, # Optional. Default is true. Whether to flip the candidate and baseline responses. This is only applicable to the pairwise metric. If enabled, also provide PairwiseMetricSpec.candidate_response_field_name and PairwiseMetricSpec.baseline_response_field_name. When rendering PairwiseMetricSpec.metric_prompt_template, the candidate and baseline fields will be flipped for half of the samples to reduce bias.
"generationConfig": { # Configuration for content generation. This message contains all the parameters that control how the model generates content. It allows you to influence the randomness, length, and structure of the output. # Optional. Configuration options for model generation and outputs.
"audioTimestamp": True or False, # Optional. If enabled, audio timestamps will be included in the request to the model. This can be useful for synchronizing audio with other modalities in the response.
"candidateCount": 42, # Optional. The number of candidate responses to generate. A higher `candidate_count` can provide more options to choose from, but it also consumes more resources. This can be useful for generating a variety of responses and selecting the best one.
"enableAffectiveDialog": True or False, # Optional. If enabled, the model will detect emotions and adapt its responses accordingly. For example, if the model detects that the user is frustrated, it may provide a more empathetic response.
"frequencyPenalty": 3.14, # Optional. Penalizes tokens based on their frequency in the generated text. A positive value helps to reduce the repetition of words and phrases. Valid values can range from [-2.0, 2.0].
"imageConfig": { # Configuration for image generation. This message allows you to control various aspects of image generation, such as the output format, aspect ratio, and whether the model can generate images of people. # Optional. Config for image generation features.
"aspectRatio": "A String", # Optional. The desired aspect ratio for the generated images. The following aspect ratios are supported: "1:1" "2:3", "3:2" "3:4", "4:3" "4:5", "5:4" "9:16", "16:9" "21:9"
"imageOutputOptions": { # The image output format for generated images. # Optional. The image output format for generated images.
"compressionQuality": 42, # Optional. The compression quality of the output image.
"mimeType": "A String", # Optional. The image format that the output should be saved as.
},
"imageSize": "A String", # Optional. Specifies the size of generated images. Supported values are `1K`, `2K`, `4K`. If not specified, the model will use default value `1K`.
"personGeneration": "A String", # Optional. Controls whether the model can generate people.
},
"logprobs": 42, # Optional. The number of top log probabilities to return for each token. This can be used to see which other tokens were considered likely candidates for a given position. A higher value will return more options, but it will also increase the size of the response.
"maxOutputTokens": 42, # Optional. The maximum number of tokens to generate in the response. A token is approximately four characters. The default value varies by model. This parameter can be used to control the length of the generated text and prevent overly long responses.
"mediaResolution": "A String", # Optional. The token resolution at which input media content is sampled. This is used to control the trade-off between the quality of the response and the number of tokens used to represent the media. A higher resolution allows the model to perceive more detail, which can lead to a more nuanced response, but it will also use more tokens. This does not affect the image dimensions sent to the model.
"presencePenalty": 3.14, # Optional. Penalizes tokens that have already appeared in the generated text. A positive value encourages the model to generate more diverse and less repetitive text. Valid values can range from [-2.0, 2.0].
"responseJsonSchema": "", # Optional. When this field is set, response_schema must be omitted and response_mime_type must be set to `application/json`.
"responseLogprobs": True or False, # 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.
"responseMimeType": "A String", # 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. This is a preview feature.
"responseModalities": [ # 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.
"A String",
],
"responseSchema": { # Defines the schema of input and output data. This is a subset of the [OpenAPI 3.0 Schema Object](https://spec.openapis.org/oas/v3.0.3#schema-object). # 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`.
"additionalProperties": "", # Optional. If `type` is `OBJECT`, specifies how to handle properties not defined in `properties`. If it is a boolean `false`, no additional properties are allowed. If it is a schema, additional properties are allowed if they conform to the schema.
"anyOf": [ # Optional. The instance must be valid against any (one or more) of the subschemas listed in `any_of`.
# Object with schema name: GoogleCloudAiplatformV1Schema
],
"default": "", # Optional. Default value to use if the field is not specified.
"defs": { # Optional. `defs` provides a map of schema definitions that can be reused by `ref` elsewhere in the schema. Only allowed at root level of the schema.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"description": "A String", # Optional. Description of the schema.
"enum": [ # Optional. Possible values of the field. This field can be used to restrict a value to a fixed set of values. To mark a field as an enum, set `format` to `enum` and provide the list of possible values in `enum`. For example: 1. To define directions: `{type:STRING, format:enum, enum:["EAST", "NORTH", "SOUTH", "WEST"]}` 2. To define apartment numbers: `{type:INTEGER, format:enum, enum:["101", "201", "301"]}`
"A String",
],
"example": "", # Optional. Example of an instance of this schema.
"format": "A String", # Optional. The format of the data. For `NUMBER` type, format can be `float` or `double`. For `INTEGER` type, format can be `int32` or `int64`. For `STRING` type, format can be `email`, `byte`, `date`, `date-time`, `password`, and other formats to further refine the data type.
"items": # Object with schema name: GoogleCloudAiplatformV1Schema # Optional. If type is `ARRAY`, `items` specifies the schema of elements in the array.
"maxItems": "A String", # Optional. If type is `ARRAY`, `max_items` specifies the maximum number of items in an array.
"maxLength": "A String", # Optional. If type is `STRING`, `max_length` specifies the maximum length of the string.
"maxProperties": "A String", # Optional. If type is `OBJECT`, `max_properties` specifies the maximum number of properties that can be provided.
"maximum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `maximum` specifies the maximum allowed value.
"minItems": "A String", # Optional. If type is `ARRAY`, `min_items` specifies the minimum number of items in an array.
"minLength": "A String", # Optional. If type is `STRING`, `min_length` specifies the minimum length of the string.
"minProperties": "A String", # Optional. If type is `OBJECT`, `min_properties` specifies the minimum number of properties that can be provided.
"minimum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `minimum` specifies the minimum allowed value.
"nullable": True or False, # Optional. Indicates if the value of this field can be null.
"pattern": "A String", # Optional. If type is `STRING`, `pattern` specifies a regular expression that the string must match.
"properties": { # Optional. If type is `OBJECT`, `properties` is a map of property names to schema definitions for each property of the object.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"propertyOrdering": [ # Optional. Order of properties displayed or used where order matters. This is not a standard field in OpenAPI specification, but can be used to control the order of properties.
"A String",
],
"ref": "A String", # Optional. Allows referencing another schema definition to use in place of this schema. The value must be a valid reference to a schema in `defs`. For example, the following schema defines a reference to a schema node named "Pet": type: object properties: pet: ref: #/defs/Pet defs: Pet: type: object properties: name: type: string The value of the "pet" property is a reference to the schema node named "Pet". See details in https://json-schema.org/understanding-json-schema/structuring
"required": [ # Optional. If type is `OBJECT`, `required` lists the names of properties that must be present.
"A String",
],
"title": "A String", # Optional. Title for the schema.
"type": "A String", # Optional. Data type of the schema field.
},
"routingConfig": { # 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. # Optional. Routing configuration.
"autoMode": { # The configuration for automated routing. When automated routing is specified, the routing will be determined by the pretrained routing model and customer provided model routing preference. # In this mode, the model is selected automatically based on the content of the request.
"modelRoutingPreference": "A String", # The model routing preference.
},
"manualMode": { # The configuration for manual routing. When manual routing is specified, the model will be selected based on the model name provided. # In this mode, the model is specified manually.
"modelName": "A String", # The name of the model to use. Only public LLM models are accepted.
},
},
"seed": 42, # Optional. A seed for the random number generator. By setting a seed, you can make the model's output mostly deterministic. For a given prompt and parameters (like temperature, top_p, etc.), the model will produce the same response every time. However, it's not a guaranteed absolute deterministic behavior. This is different from parameters like `temperature`, which control the *level* of randomness. `seed` ensures that the "random" choices the model makes are the same on every run, making it essential for testing and ensuring reproducible results.
"speechConfig": { # Configuration for speech generation. # Optional. The speech generation config.
"languageCode": "A String", # Optional. The language code (ISO 639-1) for the speech synthesis.
"multiSpeakerVoiceConfig": { # Configuration for a multi-speaker text-to-speech request. # The configuration for a multi-speaker text-to-speech request. This field is mutually exclusive with `voice_config`.
"speakerVoiceConfigs": [ # Required. A list of configurations for the voices of the speakers. Exactly two speaker voice configurations must be provided.
{ # Configuration for a single speaker in a multi-speaker setup.
"speaker": "A String", # Required. The name of the speaker. This should be the same as the speaker name used in the prompt.
"voiceConfig": { # Configuration for a voice. # Required. The configuration for the voice of this speaker.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
],
},
"voiceConfig": { # Configuration for a voice. # The configuration for the voice to use.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
"stopSequences": [ # Optional. A list of character sequences that will stop the model from generating further tokens. If a stop sequence is generated, the output will end at that point. This is useful for controlling the length and structure of the output. For example, you can use ["\n", "###"] to stop generation at a new line or a specific marker.
"A String",
],
"temperature": 3.14, # Optional. Controls the randomness of the output. A higher temperature results in more creative and diverse responses, while a lower temperature makes the output more predictable and focused. The valid range is (0.0, 2.0].
"thinkingConfig": { # Configuration for the model's thinking features. "Thinking" is a process where the model breaks down a complex task into smaller, manageable steps. This allows the model to reason about the task, plan its approach, and execute the plan to generate a high-quality response. # Optional. Configuration for thinking features. An error will be returned if this field is set for models that don't support thinking.
"includeThoughts": True or False, # Optional. If true, the model will include its thoughts in the response. "Thoughts" are the intermediate steps the model takes to arrive at the final response. They can provide insights into the model's reasoning process and help with debugging. If this is true, thoughts are returned only when available.
"thinkingBudget": 42, # Optional. The token budget for the model's thinking process. The model will make a best effort to stay within this budget. This can be used to control the trade-off between response quality and latency.
"thinkingLevel": "A String", # Optional. The number of thoughts tokens that the model should generate.
},
"topK": 3.14, # Optional. Specifies the top-k sampling threshold. The model considers only the top k most probable tokens for the next token. This can be useful for generating more coherent and less random text. For example, a `top_k` of 40 means the model will choose the next word from the 40 most likely words.
"topP": 3.14, # Optional. Specifies the nucleus sampling threshold. The model considers only the smallest set of tokens whose cumulative probability is at least `top_p`. This helps generate more diverse and less repetitive responses. For example, a `top_p` of 0.9 means the model considers tokens until the cumulative probability of the tokens to select from reaches 0.9. It's recommended to adjust either temperature or `top_p`, but not both.
},
"samplingCount": 42, # Optional. Number of samples for each instance in the dataset. If not specified, the default is 4. Minimum value is 1, maximum value is 32.
},
"promptTemplate": "A String", # Template for the prompt used to generate rubrics. The details should be updated based on the most-recent recipe requirements.
"rubricContentType": "A String", # The type of rubric content to be generated.
"rubricTypeOntology": [ # Optional. An optional, pre-defined list of allowed types for generated rubrics. If this field is provided, it implies `include_rubric_type` should be true, and the generated rubric types should be chosen from this ontology.
"A String",
],
},
"rubricGroupKey": "A String", # Use a pre-defined group of rubrics associated with the input. Refers to a key in the rubric_groups map of EvaluationInstance.
"systemInstruction": "A String", # Optional. System instructions for the judge model.
},
"pairwiseMetricSpec": { # Spec for pairwise metric. # Spec for pairwise metric.
"baselineResponseFieldName": "A String", # Optional. The field name of the baseline response.
"candidateResponseFieldName": "A String", # Optional. The field name of the candidate response.
"customOutputFormatConfig": { # Spec for custom output format configuration. # Optional. CustomOutputFormatConfig allows customization of metric output. When this config is set, the default output is replaced with the raw output string. If a custom format is chosen, the `pairwise_choice` and `explanation` fields in the corresponding metric result will be empty.
"returnRawOutput": True or False, # Optional. Whether to return raw output.
},
"metricPromptTemplate": "A String", # Required. Metric prompt template for pairwise metric.
"systemInstruction": "A String", # Optional. System instructions for pairwise metric.
},
"pointwiseMetricSpec": { # Spec for pointwise metric. # Spec for pointwise metric.
"customOutputFormatConfig": { # Spec for custom output format configuration. # Optional. CustomOutputFormatConfig allows customization of metric output. By default, metrics return a score and explanation. When this config is set, the default output is replaced with either: - The raw output string. - A parsed output based on a user-defined schema. If a custom format is chosen, the `score` and `explanation` fields in the corresponding metric result will be empty.
"returnRawOutput": True or False, # Optional. Whether to return raw output.
},
"metricPromptTemplate": "A String", # Required. Metric prompt template for pointwise metric.
"systemInstruction": "A String", # Optional. System instructions for pointwise metric.
},
"predefinedMetricSpec": { # The spec for a pre-defined metric. # The spec for a pre-defined metric.
"metricSpecName": "A String", # Required. The name of a pre-defined metric, such as "instruction_following_v1" or "text_quality_v1".
"metricSpecParameters": { # Optional. The parameters needed to run the pre-defined metric.
"a_key": "", # Properties of the object.
},
},
"rougeSpec": { # Spec for rouge score metric - calculates the recall of n-grams in prediction as compared to reference - returns a score ranging between 0 and 1. # Spec for rouge metric.
"rougeType": "A String", # Optional. Supported rouge types are rougen[1-9], rougeL, and rougeLsum.
"splitSummaries": True or False, # Optional. Whether to split summaries while using rougeLsum.
"useStemmer": True or False, # Optional. Whether to use stemmer to compute rouge score.
},
},
"predefinedMetricSpec": { # Specification for a pre-defined metric. # Spec for a pre-defined metric.
"metricSpecName": "A String", # Required. The name of a pre-defined metric, such as "instruction_following_v1" or "text_quality_v1".
"parameters": { # Optional. The parameters needed to run the pre-defined metric.
"a_key": "", # Properties of the object.
},
},
"rubricBasedMetricSpec": { # Specification for a metric that is based on rubrics. # Spec for rubric based metric.
"inlineRubrics": { # Defines a list of rubrics, used when providing rubrics inline. # Use rubrics provided directly in the spec.
"rubrics": [ # The list of rubrics.
{ # Message representing a single testable criterion for evaluation. One input prompt could have multiple rubrics.
"content": { # Content of the rubric, defining the testable criteria. # Required. The actual testable criteria for the rubric.
"property": { # Defines criteria based on a specific property. # Evaluation criteria based on a specific property.
"description": "A String", # Description of the property being evaluated. Example: "The model's response is grammatically correct."
},
},
"importance": "A String", # Optional. The relative importance of this rubric.
"rubricId": "A String", # Unique identifier for the rubric. This ID is used to refer to this rubric, e.g., in RubricVerdict.
"type": "A String", # Optional. A type designator for the rubric, which can inform how it's evaluated or interpreted by systems or users. It's recommended to use consistent, well-defined, upper snake_case strings. Examples: "SUMMARIZATION_QUALITY", "SAFETY_HARMFUL_CONTENT", "INSTRUCTION_ADHERENCE".
},
],
},
"judgeAutoraterConfig": { # The autorater config used for the evaluation run. # Optional. Optional configuration for the judge LLM (Autorater). The definition of AutoraterConfig needs to be provided.
"autoraterModel": "A String", # Optional. The fully qualified name of the publisher model or tuned autorater endpoint to use. Publisher model format: `projects/{project}/locations/{location}/publishers/*/models/*` Tuned model endpoint format: `projects/{project}/locations/{location}/endpoints/{endpoint}`
"generationConfig": { # Configuration for content generation. This message contains all the parameters that control how the model generates content. It allows you to influence the randomness, length, and structure of the output. # Optional. Configuration options for model generation and outputs.
"audioTimestamp": True or False, # Optional. If enabled, audio timestamps will be included in the request to the model. This can be useful for synchronizing audio with other modalities in the response.
"candidateCount": 42, # Optional. The number of candidate responses to generate. A higher `candidate_count` can provide more options to choose from, but it also consumes more resources. This can be useful for generating a variety of responses and selecting the best one.
"enableAffectiveDialog": True or False, # Optional. If enabled, the model will detect emotions and adapt its responses accordingly. For example, if the model detects that the user is frustrated, it may provide a more empathetic response.
"frequencyPenalty": 3.14, # Optional. Penalizes tokens based on their frequency in the generated text. A positive value helps to reduce the repetition of words and phrases. Valid values can range from [-2.0, 2.0].
"imageConfig": { # Configuration for image generation. This message allows you to control various aspects of image generation, such as the output format, aspect ratio, and whether the model can generate images of people. # Optional. Config for image generation features.
"aspectRatio": "A String", # Optional. The desired aspect ratio for the generated images. The following aspect ratios are supported: "1:1" "2:3", "3:2" "3:4", "4:3" "4:5", "5:4" "9:16", "16:9" "21:9"
"imageOutputOptions": { # The image output format for generated images. # Optional. The image output format for generated images.
"compressionQuality": 42, # Optional. The compression quality of the output image.
"mimeType": "A String", # Optional. The image format that the output should be saved as.
},
"imageSize": "A String", # Optional. Specifies the size of generated images. Supported values are `1K`, `2K`, `4K`. If not specified, the model will use default value `1K`.
"personGeneration": "A String", # Optional. Controls whether the model can generate people.
},
"logprobs": 42, # Optional. The number of top log probabilities to return for each token. This can be used to see which other tokens were considered likely candidates for a given position. A higher value will return more options, but it will also increase the size of the response.
"maxOutputTokens": 42, # Optional. The maximum number of tokens to generate in the response. A token is approximately four characters. The default value varies by model. This parameter can be used to control the length of the generated text and prevent overly long responses.
"mediaResolution": "A String", # Optional. The token resolution at which input media content is sampled. This is used to control the trade-off between the quality of the response and the number of tokens used to represent the media. A higher resolution allows the model to perceive more detail, which can lead to a more nuanced response, but it will also use more tokens. This does not affect the image dimensions sent to the model.
"presencePenalty": 3.14, # Optional. Penalizes tokens that have already appeared in the generated text. A positive value encourages the model to generate more diverse and less repetitive text. Valid values can range from [-2.0, 2.0].
"responseJsonSchema": "", # Optional. When this field is set, response_schema must be omitted and response_mime_type must be set to `application/json`.
"responseLogprobs": True or False, # 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.
"responseMimeType": "A String", # 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. This is a preview feature.
"responseModalities": [ # 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.
"A String",
],
"responseSchema": { # Defines the schema of input and output data. This is a subset of the [OpenAPI 3.0 Schema Object](https://spec.openapis.org/oas/v3.0.3#schema-object). # 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`.
"additionalProperties": "", # Optional. If `type` is `OBJECT`, specifies how to handle properties not defined in `properties`. If it is a boolean `false`, no additional properties are allowed. If it is a schema, additional properties are allowed if they conform to the schema.
"anyOf": [ # Optional. The instance must be valid against any (one or more) of the subschemas listed in `any_of`.
# Object with schema name: GoogleCloudAiplatformV1Schema
],
"default": "", # Optional. Default value to use if the field is not specified.
"defs": { # Optional. `defs` provides a map of schema definitions that can be reused by `ref` elsewhere in the schema. Only allowed at root level of the schema.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"description": "A String", # Optional. Description of the schema.
"enum": [ # Optional. Possible values of the field. This field can be used to restrict a value to a fixed set of values. To mark a field as an enum, set `format` to `enum` and provide the list of possible values in `enum`. For example: 1. To define directions: `{type:STRING, format:enum, enum:["EAST", "NORTH", "SOUTH", "WEST"]}` 2. To define apartment numbers: `{type:INTEGER, format:enum, enum:["101", "201", "301"]}`
"A String",
],
"example": "", # Optional. Example of an instance of this schema.
"format": "A String", # Optional. The format of the data. For `NUMBER` type, format can be `float` or `double`. For `INTEGER` type, format can be `int32` or `int64`. For `STRING` type, format can be `email`, `byte`, `date`, `date-time`, `password`, and other formats to further refine the data type.
"items": # Object with schema name: GoogleCloudAiplatformV1Schema # Optional. If type is `ARRAY`, `items` specifies the schema of elements in the array.
"maxItems": "A String", # Optional. If type is `ARRAY`, `max_items` specifies the maximum number of items in an array.
"maxLength": "A String", # Optional. If type is `STRING`, `max_length` specifies the maximum length of the string.
"maxProperties": "A String", # Optional. If type is `OBJECT`, `max_properties` specifies the maximum number of properties that can be provided.
"maximum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `maximum` specifies the maximum allowed value.
"minItems": "A String", # Optional. If type is `ARRAY`, `min_items` specifies the minimum number of items in an array.
"minLength": "A String", # Optional. If type is `STRING`, `min_length` specifies the minimum length of the string.
"minProperties": "A String", # Optional. If type is `OBJECT`, `min_properties` specifies the minimum number of properties that can be provided.
"minimum": 3.14, # Optional. If type is `INTEGER` or `NUMBER`, `minimum` specifies the minimum allowed value.
"nullable": True or False, # Optional. Indicates if the value of this field can be null.
"pattern": "A String", # Optional. If type is `STRING`, `pattern` specifies a regular expression that the string must match.
"properties": { # Optional. If type is `OBJECT`, `properties` is a map of property names to schema definitions for each property of the object.
"a_key": # Object with schema name: GoogleCloudAiplatformV1Schema
},
"propertyOrdering": [ # Optional. Order of properties displayed or used where order matters. This is not a standard field in OpenAPI specification, but can be used to control the order of properties.
"A String",
],
"ref": "A String", # Optional. Allows referencing another schema definition to use in place of this schema. The value must be a valid reference to a schema in `defs`. For example, the following schema defines a reference to a schema node named "Pet": type: object properties: pet: ref: #/defs/Pet defs: Pet: type: object properties: name: type: string The value of the "pet" property is a reference to the schema node named "Pet". See details in https://json-schema.org/understanding-json-schema/structuring
"required": [ # Optional. If type is `OBJECT`, `required` lists the names of properties that must be present.
"A String",
],
"title": "A String", # Optional. Title for the schema.
"type": "A String", # Optional. Data type of the schema field.
},
"routingConfig": { # 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. # Optional. Routing configuration.
"autoMode": { # The configuration for automated routing. When automated routing is specified, the routing will be determined by the pretrained routing model and customer provided model routing preference. # In this mode, the model is selected automatically based on the content of the request.
"modelRoutingPreference": "A String", # The model routing preference.
},
"manualMode": { # The configuration for manual routing. When manual routing is specified, the model will be selected based on the model name provided. # In this mode, the model is specified manually.
"modelName": "A String", # The name of the model to use. Only public LLM models are accepted.
},
},
"seed": 42, # Optional. A seed for the random number generator. By setting a seed, you can make the model's output mostly deterministic. For a given prompt and parameters (like temperature, top_p, etc.), the model will produce the same response every time. However, it's not a guaranteed absolute deterministic behavior. This is different from parameters like `temperature`, which control the *level* of randomness. `seed` ensures that the "random" choices the model makes are the same on every run, making it essential for testing and ensuring reproducible results.
"speechConfig": { # Configuration for speech generation. # Optional. The speech generation config.
"languageCode": "A String", # Optional. The language code (ISO 639-1) for the speech synthesis.
"multiSpeakerVoiceConfig": { # Configuration for a multi-speaker text-to-speech request. # The configuration for a multi-speaker text-to-speech request. This field is mutually exclusive with `voice_config`.
"speakerVoiceConfigs": [ # Required. A list of configurations for the voices of the speakers. Exactly two speaker voice configurations must be provided.
{ # Configuration for a single speaker in a multi-speaker setup.
"speaker": "A String", # Required. The name of the speaker. This should be the same as the speaker name used in the prompt.
"voiceConfig": { # Configuration for a voice. # Required. The configuration for the voice of this speaker.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
],
},
"voiceConfig": { # Configuration for a voice. # The configuration for the voice to use.
"prebuiltVoiceConfig": { # Configuration for a prebuilt voice. # The configuration for a prebuilt voice.
"voiceName": "A String", # The name of the prebuilt voice to use.
},
"replicatedVoiceConfig": { # The configuration for the replicated voice to use. # Optional. The configuration for a replicated voice. This enables users to replicate a voice from an audio sample.
"mimeType": "A String", # Optional. The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate. `mime_type` will default to `audio/wav` if not set.
"voiceSampleAudio": "A String", # Optional. The sample of the custom voice.
},
},
},
"stopSequences": [ # Optional. A list of character sequences that will stop the model from generating further tokens. If a stop sequence is generated, the output will end at that point. This is useful for controlling the length and structure of the output. For example, you can use ["\n", "###"] to stop generation at a new line or a specific marker.
"A String",
],
"temperature": 3.14, # Optional. Controls the randomness of the output. A higher temperature results in more creative and diverse responses, while a lower temperature makes the output more predictable and focused. The valid range is (0.0, 2.0].
"thinkingConfig": { # Configuration for the model's thinking features. "Thinking" is a process where the model breaks down a complex task into smaller, manageable steps. This allows the model to reason about the task, plan its approach, and execute the plan to generate a high-quality response. # Optional. Configuration for thinking features. An error will be returned if this field is set for models that don't support thinking.
"includeThoughts": True or False, # Optional. If true, the model will include its thoughts in the response. "Thoughts" are the intermediate steps the model takes to arrive at the final response. They can provide insights into the model's reasoning process and help with debugging. If this is true, thoughts are returned only when available.
"thinkingBudget": 42, # Optional. The token budget for the model's thinking process. The model will make a best effort to stay within this budget. This can be used to control the trade-off between response quality and latency.
"thinkingLevel": "A String", # Optional. The number of thoughts tokens that the model should generate.
},
"topK": 3.14, # Optional. Specifies the top-k sampling threshold. The model considers only the top k most probable tokens for the next token. This can be useful for generating more coherent and less random text. For example, a `top_k` of 40 means the model will choose the next word from the 40 most likely words.
"topP": 3.14, # Optional. Specifies the nucleus sampling threshold. The model considers only the smallest set of tokens whose cumulative probability is at least `top_p`. This helps generate more diverse and less repetitive responses. For example, a `top_p` of 0.9 means the model considers tokens until the cumulative probability of the tokens to select from reaches 0.9. It's recommended to adjust either temperature or `top_p`, but not both.
},
"sampleCount": 42, # Optional. Number of samples for each instance in the dataset. If not specified, the default is 4. Minimum value is 1, maximum value is 32.
},
"metricPromptTemplate": "A String", # Optional. Template for the prompt used by the judge model to evaluate against rubrics.
"rubricGenerationSpec": { # Specification for how rubrics should be generated. # Dynamically generate rubrics for evaluation using this specification.
"modelConfig": { # The autorater config used for the evaluation run. # Optional. Configuration for the model used in rubric generation. Configs including sampling count and base model can be specified here. Flipping is not supported for rubric generation.
"autoraterModel": "A String", # Optional. The fully qualified name of the publisher model or tuned autorater endpoint to use. Publisher model format: `projects/{project}/locations/{location}/publishers/*/models/*` Tuned model endpoint format: `projects/{project}/locations/{location}/endpoints/{endpoint}`
"generationConfig": { # Configuration for content generation. This message contains all the parameters that control how the model generates content. It allows you to influence the randomness, length, and structure of the output. # Optional. Configuration options for model generation and outputs.
"audioTimestamp": True or False, # Optional. If enabled, audio timestamps will be included in the request to the model. This can be useful for synchronizing audio with other modalities in the response.
"candidateCount": 42, # Optional. The number of candidate responses to generate. A higher `candidate_count` can provide more options to choose from, but it also consumes more resources. This can be useful for generating a variety of responses and selecting the best one.
"enableAffectiveDialog": True or False, # Optional. If enabled, the model will detect emotions and adapt its responses accordingly. For example, if the model detects that the user is frustrated, it may provide a more empathetic response.
"frequencyPenalty": 3.14, # Optional. Penalizes tokens based on their frequency in the generated text. A positive value helps to reduce the repetition of words and phrases. Valid values can range from [-2.0, 2.0].
"imageConfig": { # Configuration for image generation. This message allows you to control various aspects of image generation, such as the output format, aspect ratio, and whether the model can generate images of people. # Optional. Config for image generation features.
"aspectRatio": "A String", # Optional. The desired aspect ratio for the generated images. The following aspect ratios are supported: "1:1" "2:3", "3:2" "3:4", "4:3" "4:5", "5:4" "9:16", "16:9" "21:9"
"imageOutputOptions": { # The image output format for generated images. # Optional. The image output format for generated images.
"compressionQuality": 42, # Optional. The compression quality of the output image.
"mimeType": "A String", # Optional. The image format that the output should be saved as.
},
"imageSize": "A String", # Optional. Specifies the size of generated images. Supported values are `1K`, `2K`, `4K`. If not specified, the model will use default value `1K`.
"personGeneration": "A String", # Optional. Controls whether the model can generate people.
},