@google/genai 2.10.0 → 2.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/genai.d.ts +975 -588
- package/dist/index.cjs +446 -77
- package/dist/index.mjs +442 -78
- package/dist/index.mjs.map +1 -1
- package/dist/node/index.cjs +446 -77
- package/dist/node/index.mjs +442 -78
- package/dist/node/index.mjs.map +1 -1
- package/dist/node/node.d.ts +975 -588
- package/dist/tokenizer/node.cjs +157 -53
- package/dist/tokenizer/node.d.ts +204 -4
- package/dist/tokenizer/node.mjs +157 -53
- package/dist/tokenizer/node.mjs.map +1 -1
- package/dist/vertex_internal/index.cjs +158 -54
- package/dist/vertex_internal/index.cjs.map +1 -1
- package/dist/vertex_internal/index.d.ts +292 -67
- package/dist/vertex_internal/index.js +158 -54
- package/dist/vertex_internal/index.js.map +1 -1
- package/dist/web/index.mjs +442 -78
- package/dist/web/index.mjs.map +1 -1
- package/dist/web/web.d.ts +975 -588
- package/package.json +2 -9
package/dist/genai.d.ts
CHANGED
|
@@ -80,30 +80,30 @@ declare type Agent$ = Agent;
|
|
|
80
80
|
* }
|
|
81
81
|
*/
|
|
82
82
|
declare type Agent = {
|
|
83
|
-
/**
|
|
84
|
-
* The unique identifier for the agent.
|
|
85
|
-
*/
|
|
86
|
-
id?: string | undefined;
|
|
87
83
|
/**
|
|
88
84
|
* The base agent to extend.
|
|
89
85
|
*/
|
|
90
86
|
base_agent?: string | undefined;
|
|
91
87
|
/**
|
|
92
|
-
*
|
|
88
|
+
* The environment configuration for the agent.
|
|
93
89
|
*/
|
|
94
|
-
|
|
90
|
+
base_environment?: interactions.Environment | string | undefined;
|
|
95
91
|
/**
|
|
96
92
|
* Agent description for developers to quickly read and understand.
|
|
97
93
|
*/
|
|
98
94
|
description?: string | undefined;
|
|
99
95
|
/**
|
|
100
|
-
* The
|
|
96
|
+
* The unique identifier for the agent.
|
|
101
97
|
*/
|
|
102
|
-
|
|
98
|
+
id?: string | undefined;
|
|
103
99
|
/**
|
|
104
|
-
*
|
|
100
|
+
* System instruction for the agent.
|
|
105
101
|
*/
|
|
106
|
-
|
|
102
|
+
system_instruction?: string | undefined;
|
|
103
|
+
/**
|
|
104
|
+
* The tools available to the agent.
|
|
105
|
+
*/
|
|
106
|
+
tools?: Array<AgentTool> | undefined;
|
|
107
107
|
};
|
|
108
108
|
|
|
109
109
|
declare type AgentCreateParams$ = CreateAgentParams;
|
|
@@ -160,7 +160,7 @@ declare type AgentTool$ = AgentTool;
|
|
|
160
160
|
/**
|
|
161
161
|
* A tool that the agent can use.
|
|
162
162
|
*/
|
|
163
|
-
declare type AgentTool = interactions.CodeExecution | interactions.GoogleSearch | interactions.URLContext | interactions.MCPServer;
|
|
163
|
+
declare type AgentTool = interactions.CodeExecution | interactions.GoogleSearch | interactions.URLContext | interactions.MCPServer | interactions.FunctionT;
|
|
164
164
|
|
|
165
165
|
/** Aggregation metric. This enum is not supported in Gemini API. */
|
|
166
166
|
export declare enum AggregationMetric {
|
|
@@ -251,8 +251,6 @@ declare type AllowedTools = {
|
|
|
251
251
|
|
|
252
252
|
declare type Allowlist$ = Allowlist;
|
|
253
253
|
|
|
254
|
-
declare type Allowlist$2 = AllowlistEntry;
|
|
255
|
-
|
|
256
254
|
/**
|
|
257
255
|
* Outbound networking configuration for the sandbox. When specified, restricts which external domains the sandbox can reach. Omit entirely to allow all outbound traffic with no header injection.
|
|
258
256
|
*/
|
|
@@ -263,13 +261,6 @@ declare type Allowlist = {
|
|
|
263
261
|
allowlist?: Array<AllowlistEntry> | undefined;
|
|
264
262
|
};
|
|
265
263
|
|
|
266
|
-
/**
|
|
267
|
-
* @license
|
|
268
|
-
* Copyright 2026 Google LLC
|
|
269
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
270
|
-
*
|
|
271
|
-
* g3-prettier-ignore-file
|
|
272
|
-
*/
|
|
273
264
|
/**
|
|
274
265
|
* A single domain allowlist rule with optional header injection.
|
|
275
266
|
*/
|
|
@@ -279,9 +270,11 @@ declare type AllowlistEntry = {
|
|
|
279
270
|
*/
|
|
280
271
|
domain: string;
|
|
281
272
|
/**
|
|
282
|
-
* Headers to inject on all outbound requests matching this domain.
|
|
273
|
+
* Headers to inject on all outbound requests matching this domain. Accepts a single dict or a list of dicts. The egress proxy injects these automatically.
|
|
283
274
|
*/
|
|
284
|
-
transform?:
|
|
275
|
+
transform?: {
|
|
276
|
+
[k: string]: string;
|
|
277
|
+
} | Array<{
|
|
285
278
|
[k: string]: string;
|
|
286
279
|
}> | undefined;
|
|
287
280
|
};
|
|
@@ -496,24 +489,9 @@ declare type Arguments$2 = GoogleMapsCallArguments;
|
|
|
496
489
|
|
|
497
490
|
declare type Arguments$3 = GoogleSearchCallArguments;
|
|
498
491
|
|
|
499
|
-
declare type Arguments$4 =
|
|
492
|
+
declare type Arguments$4 = RetrievalCallArguments;
|
|
500
493
|
|
|
501
|
-
|
|
502
|
-
* @license
|
|
503
|
-
* Copyright 2026 Google LLC
|
|
504
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
505
|
-
*
|
|
506
|
-
* g3-prettier-ignore-file
|
|
507
|
-
*/
|
|
508
|
-
/**
|
|
509
|
-
* The arguments to pass to the URL context.
|
|
510
|
-
*/
|
|
511
|
-
declare type Arguments = {
|
|
512
|
-
/**
|
|
513
|
-
* The URLs to fetch.
|
|
514
|
-
*/
|
|
515
|
-
urls?: Array<string> | undefined;
|
|
516
|
-
};
|
|
494
|
+
declare type Arguments$5 = URLContextCallArguments;
|
|
517
495
|
|
|
518
496
|
declare type ArgumentsDelta$ = ArgumentsDelta;
|
|
519
497
|
|
|
@@ -525,10 +503,74 @@ declare type ArgumentsDelta$ = ArgumentsDelta;
|
|
|
525
503
|
* g3-prettier-ignore-file
|
|
526
504
|
*/
|
|
527
505
|
declare type ArgumentsDelta = {
|
|
528
|
-
type: "arguments_delta";
|
|
529
506
|
arguments?: string | undefined;
|
|
507
|
+
type: "arguments_delta";
|
|
530
508
|
};
|
|
531
509
|
|
|
510
|
+
/** The aspect ratio for the image output. */
|
|
511
|
+
export declare enum AspectRatio {
|
|
512
|
+
/**
|
|
513
|
+
* Default value. This value is unused.
|
|
514
|
+
*/
|
|
515
|
+
ASPECT_RATIO_UNSPECIFIED = "ASPECT_RATIO_UNSPECIFIED",
|
|
516
|
+
/**
|
|
517
|
+
* 1:1 aspect ratio.
|
|
518
|
+
*/
|
|
519
|
+
ASPECT_RATIO_ONE_BY_ONE = "ASPECT_RATIO_ONE_BY_ONE",
|
|
520
|
+
/**
|
|
521
|
+
* 2:3 aspect ratio.
|
|
522
|
+
*/
|
|
523
|
+
ASPECT_RATIO_TWO_BY_THREE = "ASPECT_RATIO_TWO_BY_THREE",
|
|
524
|
+
/**
|
|
525
|
+
* 3:2 aspect ratio.
|
|
526
|
+
*/
|
|
527
|
+
ASPECT_RATIO_THREE_BY_TWO = "ASPECT_RATIO_THREE_BY_TWO",
|
|
528
|
+
/**
|
|
529
|
+
* 3:4 aspect ratio.
|
|
530
|
+
*/
|
|
531
|
+
ASPECT_RATIO_THREE_BY_FOUR = "ASPECT_RATIO_THREE_BY_FOUR",
|
|
532
|
+
/**
|
|
533
|
+
* 4:3 aspect ratio.
|
|
534
|
+
*/
|
|
535
|
+
ASPECT_RATIO_FOUR_BY_THREE = "ASPECT_RATIO_FOUR_BY_THREE",
|
|
536
|
+
/**
|
|
537
|
+
* 4:5 aspect ratio.
|
|
538
|
+
*/
|
|
539
|
+
ASPECT_RATIO_FOUR_BY_FIVE = "ASPECT_RATIO_FOUR_BY_FIVE",
|
|
540
|
+
/**
|
|
541
|
+
* 5:4 aspect ratio.
|
|
542
|
+
*/
|
|
543
|
+
ASPECT_RATIO_FIVE_BY_FOUR = "ASPECT_RATIO_FIVE_BY_FOUR",
|
|
544
|
+
/**
|
|
545
|
+
* 9:16 aspect ratio.
|
|
546
|
+
*/
|
|
547
|
+
ASPECT_RATIO_NINE_BY_SIXTEEN = "ASPECT_RATIO_NINE_BY_SIXTEEN",
|
|
548
|
+
/**
|
|
549
|
+
* 16:9 aspect ratio.
|
|
550
|
+
*/
|
|
551
|
+
ASPECT_RATIO_SIXTEEN_BY_NINE = "ASPECT_RATIO_SIXTEEN_BY_NINE",
|
|
552
|
+
/**
|
|
553
|
+
* 21:9 aspect ratio.
|
|
554
|
+
*/
|
|
555
|
+
ASPECT_RATIO_TWENTY_ONE_BY_NINE = "ASPECT_RATIO_TWENTY_ONE_BY_NINE",
|
|
556
|
+
/**
|
|
557
|
+
* 1:8 aspect ratio.
|
|
558
|
+
*/
|
|
559
|
+
ASPECT_RATIO_ONE_BY_EIGHT = "ASPECT_RATIO_ONE_BY_EIGHT",
|
|
560
|
+
/**
|
|
561
|
+
* 8:1 aspect ratio.
|
|
562
|
+
*/
|
|
563
|
+
ASPECT_RATIO_EIGHT_BY_ONE = "ASPECT_RATIO_EIGHT_BY_ONE",
|
|
564
|
+
/**
|
|
565
|
+
* 1:4 aspect ratio.
|
|
566
|
+
*/
|
|
567
|
+
ASPECT_RATIO_ONE_BY_FOUR = "ASPECT_RATIO_ONE_BY_FOUR",
|
|
568
|
+
/**
|
|
569
|
+
* 4:1 aspect ratio.
|
|
570
|
+
*/
|
|
571
|
+
ASPECT_RATIO_FOUR_BY_ONE = "ASPECT_RATIO_FOUR_BY_ONE"
|
|
572
|
+
}
|
|
573
|
+
|
|
532
574
|
declare type Audio$ = AudioDelta;
|
|
533
575
|
|
|
534
576
|
/** Representation of an audio chunk. */
|
|
@@ -548,27 +590,27 @@ declare type AudioContent$ = AudioContent;
|
|
|
548
590
|
* An audio content block.
|
|
549
591
|
*/
|
|
550
592
|
declare type AudioContent = {
|
|
551
|
-
type: "audio";
|
|
552
593
|
/**
|
|
553
|
-
* The audio
|
|
594
|
+
* The number of audio channels.
|
|
554
595
|
*/
|
|
555
|
-
|
|
596
|
+
channels?: number | undefined;
|
|
556
597
|
/**
|
|
557
|
-
* The
|
|
598
|
+
* The audio content.
|
|
558
599
|
*/
|
|
559
|
-
|
|
600
|
+
data?: string | undefined;
|
|
560
601
|
/**
|
|
561
602
|
* The mime type of the audio.
|
|
562
603
|
*/
|
|
563
604
|
mime_type?: AudioContentMimeType | undefined;
|
|
564
|
-
/**
|
|
565
|
-
* The number of audio channels.
|
|
566
|
-
*/
|
|
567
|
-
channels?: number | undefined;
|
|
568
605
|
/**
|
|
569
606
|
* The sample rate of the audio.
|
|
570
607
|
*/
|
|
571
608
|
sample_rate?: number | undefined;
|
|
609
|
+
type: "audio";
|
|
610
|
+
/**
|
|
611
|
+
* The URI of the audio.
|
|
612
|
+
*/
|
|
613
|
+
uri?: string | undefined;
|
|
572
614
|
};
|
|
573
615
|
|
|
574
616
|
/**
|
|
@@ -584,9 +626,11 @@ declare type AudioContent = {
|
|
|
584
626
|
declare type AudioContentMimeType = "audio/wav" | "audio/mp3" | "audio/aiff" | "audio/aac" | "audio/ogg" | "audio/flac" | "audio/mpeg" | "audio/m4a" | "audio/l16" | "audio/opus" | "audio/alaw" | "audio/mulaw" | (string & {});
|
|
585
627
|
|
|
586
628
|
declare type AudioDelta = {
|
|
587
|
-
|
|
629
|
+
/**
|
|
630
|
+
* The number of audio channels.
|
|
631
|
+
*/
|
|
632
|
+
channels?: number | undefined;
|
|
588
633
|
data?: string | undefined;
|
|
589
|
-
uri?: string | undefined;
|
|
590
634
|
mime_type?: AudioDeltaMimeType | undefined;
|
|
591
635
|
/**
|
|
592
636
|
* Deprecated. Use sample_rate instead. The value is ignored.
|
|
@@ -598,10 +642,8 @@ declare type AudioDelta = {
|
|
|
598
642
|
* The sample rate of the audio.
|
|
599
643
|
*/
|
|
600
644
|
sample_rate?: number | undefined;
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
*/
|
|
604
|
-
channels?: number | undefined;
|
|
645
|
+
type: "audio";
|
|
646
|
+
uri?: string | undefined;
|
|
605
647
|
};
|
|
606
648
|
|
|
607
649
|
/**
|
|
@@ -613,39 +655,46 @@ declare type AudioDelta = {
|
|
|
613
655
|
*/
|
|
614
656
|
declare type AudioDeltaMimeType = "audio/wav" | "audio/mp3" | "audio/aiff" | "audio/aac" | "audio/ogg" | "audio/flac" | "audio/mpeg" | "audio/m4a" | "audio/l16" | "audio/opus" | "audio/alaw" | "audio/mulaw" | (string & {});
|
|
615
657
|
|
|
616
|
-
declare type AudioResponseFormat$ =
|
|
658
|
+
declare type AudioResponseFormat$ = AudioResponseFormat_2;
|
|
659
|
+
|
|
660
|
+
/** Configuration for audio-specific output formatting. */
|
|
661
|
+
export declare class AudioResponseFormat {
|
|
662
|
+
/** Optional. Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus). */
|
|
663
|
+
bitRate?: number;
|
|
664
|
+
/** Optional. Delivery mode for the generated content. */
|
|
665
|
+
delivery?: Delivery;
|
|
666
|
+
/** Optional. The MIME type of the audio output. */
|
|
667
|
+
mimeType?: string;
|
|
668
|
+
/** Optional. Sample rate for the generated audio in Hertz. */
|
|
669
|
+
sampleRate?: number;
|
|
670
|
+
}
|
|
617
671
|
|
|
618
672
|
/**
|
|
619
673
|
* Configuration for audio output format.
|
|
620
674
|
*/
|
|
621
|
-
declare type
|
|
622
|
-
type: "audio";
|
|
675
|
+
declare type AudioResponseFormat_2 = {
|
|
623
676
|
/**
|
|
624
|
-
*
|
|
677
|
+
* Bit rate in bits per second (bps). Only applicable for compressed formats
|
|
678
|
+
*
|
|
679
|
+
* @remarks
|
|
680
|
+
* (MP3, Opus).
|
|
625
681
|
*/
|
|
626
|
-
|
|
682
|
+
bit_rate?: number | undefined;
|
|
627
683
|
/**
|
|
628
684
|
* The delivery mode for the audio output.
|
|
629
685
|
*/
|
|
630
686
|
delivery?: AudioResponseFormatDelivery | undefined;
|
|
631
687
|
/**
|
|
632
|
-
*
|
|
688
|
+
* The MIME type of the audio output.
|
|
633
689
|
*/
|
|
634
|
-
|
|
690
|
+
mime_type?: AudioResponseFormatMimeType | undefined;
|
|
635
691
|
/**
|
|
636
|
-
*
|
|
637
|
-
*
|
|
638
|
-
* @remarks
|
|
639
|
-
* (MP3, Opus).
|
|
692
|
+
* Sample rate in Hz.
|
|
640
693
|
*/
|
|
641
|
-
|
|
694
|
+
sample_rate?: number | undefined;
|
|
695
|
+
type: "audio";
|
|
642
696
|
};
|
|
643
697
|
|
|
644
|
-
/**
|
|
645
|
-
* The delivery mode for the audio output.
|
|
646
|
-
*/
|
|
647
|
-
declare type AudioResponseFormatDelivery = "inline" | "uri" | (string & {});
|
|
648
|
-
|
|
649
698
|
/**
|
|
650
699
|
* @license
|
|
651
700
|
* Copyright 2026 Google LLC
|
|
@@ -653,6 +702,11 @@ declare type AudioResponseFormatDelivery = "inline" | "uri" | (string & {});
|
|
|
653
702
|
*
|
|
654
703
|
* g3-prettier-ignore-file
|
|
655
704
|
*/
|
|
705
|
+
/**
|
|
706
|
+
* The delivery mode for the audio output.
|
|
707
|
+
*/
|
|
708
|
+
declare type AudioResponseFormatDelivery = "inline" | "uri" | (string & {});
|
|
709
|
+
|
|
656
710
|
/**
|
|
657
711
|
* The MIME type of the audio output.
|
|
658
712
|
*/
|
|
@@ -1103,7 +1157,7 @@ export declare interface BatchJobSource {
|
|
|
1103
1157
|
|
|
1104
1158
|
export declare type BatchJobSourceUnion = BatchJobSource | InlinedRequest[] | string;
|
|
1105
1159
|
|
|
1106
|
-
/** Specifies the function Behavior.
|
|
1160
|
+
/** Specifies the function Behavior. If not specified, the system keeps the current function call behavior. This field is currently only supported by the BidiGenerateContent method. */
|
|
1107
1161
|
export declare enum Behavior {
|
|
1108
1162
|
/**
|
|
1109
1163
|
* This value is unspecified.
|
|
@@ -1618,18 +1672,17 @@ declare type CodeExecutionCallArguments$ = CodeExecutionCallArguments;
|
|
|
1618
1672
|
* The arguments to pass to the code execution.
|
|
1619
1673
|
*/
|
|
1620
1674
|
declare type CodeExecutionCallArguments = {
|
|
1621
|
-
/**
|
|
1622
|
-
* Programming language of the `code`.
|
|
1623
|
-
*/
|
|
1624
|
-
language?: Language_2 | undefined;
|
|
1625
1675
|
/**
|
|
1626
1676
|
* The code to be executed.
|
|
1627
1677
|
*/
|
|
1628
1678
|
code?: string | undefined;
|
|
1679
|
+
/**
|
|
1680
|
+
* Programming language of the `code`.
|
|
1681
|
+
*/
|
|
1682
|
+
language?: Language_2 | undefined;
|
|
1629
1683
|
};
|
|
1630
1684
|
|
|
1631
1685
|
declare type CodeExecutionCallDelta = {
|
|
1632
|
-
type: "code_execution_call";
|
|
1633
1686
|
/**
|
|
1634
1687
|
* The arguments to pass to the code execution.
|
|
1635
1688
|
*/
|
|
@@ -1638,6 +1691,7 @@ declare type CodeExecutionCallDelta = {
|
|
|
1638
1691
|
* A signature hash for backend validation.
|
|
1639
1692
|
*/
|
|
1640
1693
|
signature?: string | undefined;
|
|
1694
|
+
type: "code_execution_call";
|
|
1641
1695
|
};
|
|
1642
1696
|
|
|
1643
1697
|
declare type CodeExecutionCallStep$ = CodeExecutionCallStep;
|
|
@@ -1646,7 +1700,6 @@ declare type CodeExecutionCallStep$ = CodeExecutionCallStep;
|
|
|
1646
1700
|
* Code execution call step.
|
|
1647
1701
|
*/
|
|
1648
1702
|
declare type CodeExecutionCallStep = {
|
|
1649
|
-
type: "code_execution_call";
|
|
1650
1703
|
/**
|
|
1651
1704
|
* The arguments to pass to the code execution.
|
|
1652
1705
|
*/
|
|
@@ -1659,6 +1712,7 @@ declare type CodeExecutionCallStep = {
|
|
|
1659
1712
|
* A signature hash for backend validation.
|
|
1660
1713
|
*/
|
|
1661
1714
|
signature?: string | undefined;
|
|
1715
|
+
type: "code_execution_call";
|
|
1662
1716
|
};
|
|
1663
1717
|
|
|
1664
1718
|
declare type CodeExecutionResult$ = CodeExecutionResultDelta;
|
|
@@ -1681,13 +1735,13 @@ export declare interface CodeExecutionResult {
|
|
|
1681
1735
|
* g3-prettier-ignore-file
|
|
1682
1736
|
*/
|
|
1683
1737
|
declare type CodeExecutionResultDelta = {
|
|
1684
|
-
type: "code_execution_result";
|
|
1685
|
-
result: string;
|
|
1686
1738
|
is_error?: boolean | undefined;
|
|
1739
|
+
result: string;
|
|
1687
1740
|
/**
|
|
1688
1741
|
* A signature hash for backend validation.
|
|
1689
1742
|
*/
|
|
1690
1743
|
signature?: string | undefined;
|
|
1744
|
+
type: "code_execution_result";
|
|
1691
1745
|
};
|
|
1692
1746
|
|
|
1693
1747
|
declare type CodeExecutionResultStep$ = CodeExecutionResultStep;
|
|
@@ -1703,23 +1757,23 @@ declare type CodeExecutionResultStep$ = CodeExecutionResultStep;
|
|
|
1703
1757
|
* Code execution result step.
|
|
1704
1758
|
*/
|
|
1705
1759
|
declare type CodeExecutionResultStep = {
|
|
1706
|
-
type: "code_execution_result";
|
|
1707
1760
|
/**
|
|
1708
|
-
* Required.
|
|
1761
|
+
* Required. ID to match the ID from the function call block.
|
|
1709
1762
|
*/
|
|
1710
|
-
|
|
1763
|
+
call_id: string;
|
|
1711
1764
|
/**
|
|
1712
1765
|
* Whether the code execution resulted in an error.
|
|
1713
1766
|
*/
|
|
1714
1767
|
is_error?: boolean | undefined;
|
|
1715
1768
|
/**
|
|
1716
|
-
* Required.
|
|
1769
|
+
* Required. The output of the code execution.
|
|
1717
1770
|
*/
|
|
1718
|
-
|
|
1771
|
+
result: string;
|
|
1719
1772
|
/**
|
|
1720
1773
|
* A signature hash for backend validation.
|
|
1721
1774
|
*/
|
|
1722
1775
|
signature?: string | undefined;
|
|
1776
|
+
type: "code_execution_result";
|
|
1723
1777
|
};
|
|
1724
1778
|
|
|
1725
1779
|
/** Success and error statistics of processing multiple entities (for example, DataItems or structured data rows) in batch. This data type is not supported in Gemini API. */
|
|
@@ -1736,13 +1790,15 @@ export declare interface CompletionStats {
|
|
|
1736
1790
|
|
|
1737
1791
|
/** Composite reinforcement tuning reward config. */
|
|
1738
1792
|
export declare interface CompositeReinforcementTuningRewardConfig {
|
|
1793
|
+
/** List of reward function configurations with weights. */
|
|
1739
1794
|
weightedRewardConfigs?: CompositeReinforcementTuningRewardConfigWeightedRewardConfig[];
|
|
1740
1795
|
}
|
|
1741
1796
|
|
|
1742
1797
|
/** Composite reinforcement tuning reward config weighted reward config. */
|
|
1743
1798
|
export declare interface CompositeReinforcementTuningRewardConfigWeightedRewardConfig {
|
|
1799
|
+
/** Single reward configuration. */
|
|
1744
1800
|
rewardConfig?: SingleReinforcementTuningRewardConfig;
|
|
1745
|
-
/** How much this single reward contributes to the total overall reward. */
|
|
1801
|
+
/** How much this single reward contributes to the total overall reward. Total reward is a linear combination of single rewards with their corresponding weights, i.e., ``` total_reward = ( weight_a * reward_a + weight_b * reward_b + ... ) / (weight_a + weight_b + ...) ``` */
|
|
1746
1802
|
weight?: number;
|
|
1747
1803
|
}
|
|
1748
1804
|
|
|
@@ -1764,15 +1820,10 @@ export declare interface ComputerUse {
|
|
|
1764
1820
|
* A tool that can be used by the model to interact with the computer.
|
|
1765
1821
|
*/
|
|
1766
1822
|
declare type ComputerUse_2 = {
|
|
1767
|
-
type: "computer_use";
|
|
1768
|
-
/**
|
|
1769
|
-
* The environment being operated.
|
|
1770
|
-
*/
|
|
1771
|
-
environment?: EnvironmentEnum | undefined;
|
|
1772
1823
|
/**
|
|
1773
|
-
*
|
|
1824
|
+
* Optional. Disabled safety policies for computer use.
|
|
1774
1825
|
*/
|
|
1775
|
-
|
|
1826
|
+
disabled_safety_policies?: Array<DisabledSafetyPolicy> | undefined;
|
|
1776
1827
|
/**
|
|
1777
1828
|
* Whether enable the prompt injection detection check on computer-use
|
|
1778
1829
|
*
|
|
@@ -1781,9 +1832,14 @@ declare type ComputerUse_2 = {
|
|
|
1781
1832
|
*/
|
|
1782
1833
|
enable_prompt_injection_detection?: boolean | undefined;
|
|
1783
1834
|
/**
|
|
1784
|
-
*
|
|
1835
|
+
* The environment being operated.
|
|
1785
1836
|
*/
|
|
1786
|
-
|
|
1837
|
+
environment?: EnvironmentEnum | undefined;
|
|
1838
|
+
/**
|
|
1839
|
+
* The list of predefined functions that are excluded from the model call.
|
|
1840
|
+
*/
|
|
1841
|
+
excluded_predefined_functions?: Array<string> | undefined;
|
|
1842
|
+
type: "computer_use";
|
|
1787
1843
|
};
|
|
1788
1844
|
|
|
1789
1845
|
/** Optional parameters for computing tokens. */
|
|
@@ -2032,7 +2088,7 @@ declare type CreateAgentInteraction = {
|
|
|
2032
2088
|
/**
|
|
2033
2089
|
* Enforces that the generated response is a JSON object that complies with the JSON schema specified in this field.
|
|
2034
2090
|
*/
|
|
2035
|
-
response_format?: Array<
|
|
2091
|
+
response_format?: Array<ResponseFormat_2> | ResponseFormat_2 | undefined;
|
|
2036
2092
|
/**
|
|
2037
2093
|
* The environment configuration for the interaction. Can be an object specifying remote environment sources or a string referencing an existing environment ID.
|
|
2038
2094
|
*/
|
|
@@ -2041,6 +2097,16 @@ declare type CreateAgentInteraction = {
|
|
|
2041
2097
|
* Configuration parameters for the agent interaction.
|
|
2042
2098
|
*/
|
|
2043
2099
|
agent_config?: DynamicAgentConfig | DeepResearchAgentConfig | undefined;
|
|
2100
|
+
/**
|
|
2101
|
+
* Safety settings for the interaction.
|
|
2102
|
+
*/
|
|
2103
|
+
safety_settings?: Array<SafetySetting_2> | undefined;
|
|
2104
|
+
/**
|
|
2105
|
+
* The labels with user-defined metadata for the request.
|
|
2106
|
+
*/
|
|
2107
|
+
labels?: {
|
|
2108
|
+
[k: string]: string;
|
|
2109
|
+
} | undefined;
|
|
2044
2110
|
/**
|
|
2045
2111
|
* The input for the interaction.
|
|
2046
2112
|
*/
|
|
@@ -2074,7 +2140,7 @@ declare type CreateAgentInteractionParamsStreaming = CreateAgentInteractionParam
|
|
|
2074
2140
|
/**
|
|
2075
2141
|
* Enforces that the generated response is a JSON object that complies with the JSON schema specified in this field.
|
|
2076
2142
|
*/
|
|
2077
|
-
declare type CreateAgentInteractionResponseFormat = Array<
|
|
2143
|
+
declare type CreateAgentInteractionResponseFormat = Array<ResponseFormat_2> | ResponseFormat_2;
|
|
2078
2144
|
|
|
2079
2145
|
declare type CreateAgentParams = Omit<CreateAgentRequest, "body"> & CreateAgentRequest["body"];
|
|
2080
2146
|
|
|
@@ -2418,7 +2484,7 @@ declare type CreateModelInteraction = {
|
|
|
2418
2484
|
/**
|
|
2419
2485
|
* Enforces that the generated response is a JSON object that complies with the JSON schema specified in this field.
|
|
2420
2486
|
*/
|
|
2421
|
-
response_format?: Array<
|
|
2487
|
+
response_format?: Array<ResponseFormat_2> | ResponseFormat_2 | undefined;
|
|
2422
2488
|
/**
|
|
2423
2489
|
* The environment configuration for the interaction. Can be an object specifying remote environment sources or a string referencing an existing environment ID.
|
|
2424
2490
|
*/
|
|
@@ -2437,6 +2503,16 @@ declare type CreateModelInteraction = {
|
|
|
2437
2503
|
* `projects/{project}/locations/{location}/cachedContents/{cachedContent}`
|
|
2438
2504
|
*/
|
|
2439
2505
|
cached_content?: string | undefined;
|
|
2506
|
+
/**
|
|
2507
|
+
* Safety settings for the interaction.
|
|
2508
|
+
*/
|
|
2509
|
+
safety_settings?: Array<SafetySetting_2> | undefined;
|
|
2510
|
+
/**
|
|
2511
|
+
* The labels with user-defined metadata for the request.
|
|
2512
|
+
*/
|
|
2513
|
+
labels?: {
|
|
2514
|
+
[k: string]: string;
|
|
2515
|
+
} | undefined;
|
|
2440
2516
|
/**
|
|
2441
2517
|
* The input for the interaction.
|
|
2442
2518
|
*/
|
|
@@ -2465,7 +2541,7 @@ declare type CreateModelInteractionParamsStreaming = CreateModelInteractionParam
|
|
|
2465
2541
|
/**
|
|
2466
2542
|
* Enforces that the generated response is a JSON object that complies with the JSON schema specified in this field.
|
|
2467
2543
|
*/
|
|
2468
|
-
declare type CreateModelInteractionResponseFormat = Array<
|
|
2544
|
+
declare type CreateModelInteractionResponseFormat = Array<ResponseFormat_2> | ResponseFormat_2;
|
|
2469
2545
|
|
|
2470
2546
|
/**
|
|
2471
2547
|
* Creates a `Part` object from a `base64` encoded `string`.
|
|
@@ -2697,6 +2773,12 @@ export declare interface DatasetStats {
|
|
|
2697
2773
|
userMessagePerExampleDistribution?: DatasetDistribution;
|
|
2698
2774
|
/** Output only. Dataset distributions for the user output tokens. */
|
|
2699
2775
|
userOutputTokenDistribution?: DatasetDistribution;
|
|
2776
|
+
/** Output only. Dataset distributions for the number of contents per example. */
|
|
2777
|
+
contentsPerExampleDistribution?: DatasetDistribution;
|
|
2778
|
+
/** Output only. Sample user dataset examples in the training dataset uri for Reinforcement Tuning. */
|
|
2779
|
+
reinforcementTuningUserDatasetExamples?: ReinforcementTuningUserDatasetExamples;
|
|
2780
|
+
/** Output only. Number of billable tokens in the tuning dataset. */
|
|
2781
|
+
totalBillableTokenCount?: string;
|
|
2700
2782
|
}
|
|
2701
2783
|
|
|
2702
2784
|
declare type DeepResearchAgentConfig$ = DeepResearchAgentConfig;
|
|
@@ -2705,12 +2787,6 @@ declare type DeepResearchAgentConfig$ = DeepResearchAgentConfig;
|
|
|
2705
2787
|
* Configuration for the Deep Research agent.
|
|
2706
2788
|
*/
|
|
2707
2789
|
declare type DeepResearchAgentConfig = {
|
|
2708
|
-
type: "deep-research";
|
|
2709
|
-
thinking_summaries?: ThinkingSummaries | undefined;
|
|
2710
|
-
/**
|
|
2711
|
-
* Whether to include visualizations in the response.
|
|
2712
|
-
*/
|
|
2713
|
-
visualization?: Visualization | undefined;
|
|
2714
2790
|
/**
|
|
2715
2791
|
* Enables human-in-the-loop planning for the Deep Research agent. If set to
|
|
2716
2792
|
*
|
|
@@ -2724,6 +2800,12 @@ declare type DeepResearchAgentConfig = {
|
|
|
2724
2800
|
* Enables bigquery tool for the Deep Research agent.
|
|
2725
2801
|
*/
|
|
2726
2802
|
enable_bigquery_tool?: boolean | undefined;
|
|
2803
|
+
thinking_summaries?: ThinkingSummaries | undefined;
|
|
2804
|
+
type: "deep-research";
|
|
2805
|
+
/**
|
|
2806
|
+
* Whether to include visualizations in the response.
|
|
2807
|
+
*/
|
|
2808
|
+
visualization?: Visualization | undefined;
|
|
2727
2809
|
};
|
|
2728
2810
|
|
|
2729
2811
|
declare type DeleteAgentParams = Omit<DeleteAgentRequest, "id">;
|
|
@@ -2931,11 +3013,34 @@ declare type DeleteWebhookRequest = {
|
|
|
2931
3013
|
id: string;
|
|
2932
3014
|
};
|
|
2933
3015
|
|
|
3016
|
+
/** Delivery mode for the generated content. */
|
|
3017
|
+
export declare enum Delivery {
|
|
3018
|
+
/**
|
|
3019
|
+
* Default value. This value is unused.
|
|
3020
|
+
*/
|
|
3021
|
+
DELIVERY_UNSPECIFIED = "DELIVERY_UNSPECIFIED",
|
|
3022
|
+
/**
|
|
3023
|
+
* Generated bytes are returned inline in the response.
|
|
3024
|
+
*/
|
|
3025
|
+
INLINE = "INLINE",
|
|
3026
|
+
/**
|
|
3027
|
+
* Generated content is stored and a URI is returned.
|
|
3028
|
+
*/
|
|
3029
|
+
URI = "URI"
|
|
3030
|
+
}
|
|
3031
|
+
|
|
2934
3032
|
/**
|
|
2935
3033
|
* Turns all network off.
|
|
2936
3034
|
*/
|
|
2937
3035
|
declare type Disabled = "disabled";
|
|
2938
3036
|
|
|
3037
|
+
/**
|
|
3038
|
+
* @license
|
|
3039
|
+
* Copyright 2026 Google LLC
|
|
3040
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
3041
|
+
*
|
|
3042
|
+
* g3-prettier-ignore-file
|
|
3043
|
+
*/
|
|
2939
3044
|
declare type DisabledSafetyPolicy = "financial_transactions" | "sensitive_data_modification" | "communication_tool" | "account_creation" | "data_modification" | "user_consent_management" | "legal_terms_and_agreements" | (string & {});
|
|
2940
3045
|
|
|
2941
3046
|
/** Statistics for distillation prompt dataset. These statistics do not include the responses sampled from the teacher model. This data type is not supported in Gemini API. */
|
|
@@ -3037,19 +3142,19 @@ declare type DocumentContent$ = DocumentContent;
|
|
|
3037
3142
|
* A document content block.
|
|
3038
3143
|
*/
|
|
3039
3144
|
declare type DocumentContent = {
|
|
3040
|
-
type: "document";
|
|
3041
3145
|
/**
|
|
3042
3146
|
* The document content.
|
|
3043
3147
|
*/
|
|
3044
3148
|
data?: string | undefined;
|
|
3045
|
-
/**
|
|
3046
|
-
* The URI of the document.
|
|
3047
|
-
*/
|
|
3048
|
-
uri?: string | undefined;
|
|
3049
3149
|
/**
|
|
3050
3150
|
* The mime type of the document.
|
|
3051
3151
|
*/
|
|
3052
3152
|
mime_type?: DocumentContentMimeType | undefined;
|
|
3153
|
+
type: "document";
|
|
3154
|
+
/**
|
|
3155
|
+
* The URI of the document.
|
|
3156
|
+
*/
|
|
3157
|
+
uri?: string | undefined;
|
|
3053
3158
|
};
|
|
3054
3159
|
|
|
3055
3160
|
/**
|
|
@@ -3065,10 +3170,10 @@ declare type DocumentContent = {
|
|
|
3065
3170
|
declare type DocumentContentMimeType = "application/pdf" | "text/csv" | (string & {});
|
|
3066
3171
|
|
|
3067
3172
|
declare type DocumentDelta = {
|
|
3068
|
-
type: "document";
|
|
3069
3173
|
data?: string | undefined;
|
|
3070
|
-
uri?: string | undefined;
|
|
3071
3174
|
mime_type?: DocumentDeltaMimeType | undefined;
|
|
3175
|
+
type: "document";
|
|
3176
|
+
uri?: string | undefined;
|
|
3072
3177
|
};
|
|
3073
3178
|
|
|
3074
3179
|
/**
|
|
@@ -3526,21 +3631,21 @@ export declare enum Environment {
|
|
|
3526
3631
|
* Configuration for a custom environment.
|
|
3527
3632
|
*/
|
|
3528
3633
|
declare type Environment_2 = {
|
|
3529
|
-
|
|
3530
|
-
|
|
3634
|
+
/**
|
|
3635
|
+
* Optional. The environment ID for the interaction. If specified, the request will
|
|
3636
|
+
*
|
|
3637
|
+
* @remarks
|
|
3638
|
+
* update the existing environment instead of creating a new one.
|
|
3639
|
+
*/
|
|
3640
|
+
environment_id?: string | undefined;
|
|
3531
3641
|
/**
|
|
3532
3642
|
* Network configuration for the environment.
|
|
3533
3643
|
*/
|
|
3534
3644
|
network?: EnvironmentNetworkEgressAllowlist | NetworkEnum | undefined;
|
|
3645
|
+
sources?: Array<Source> | undefined;
|
|
3646
|
+
type: "remote";
|
|
3535
3647
|
};
|
|
3536
3648
|
|
|
3537
|
-
/**
|
|
3538
|
-
* @license
|
|
3539
|
-
* Copyright 2026 Google LLC
|
|
3540
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
3541
|
-
*
|
|
3542
|
-
* g3-prettier-ignore-file
|
|
3543
|
-
*/
|
|
3544
3649
|
/**
|
|
3545
3650
|
* The environment being operated.
|
|
3546
3651
|
*/
|
|
@@ -3558,7 +3663,6 @@ declare type Error$2 = Status;
|
|
|
3558
3663
|
declare type ErrorEvent$ = ErrorEvent_2;
|
|
3559
3664
|
|
|
3560
3665
|
declare type ErrorEvent_2 = {
|
|
3561
|
-
event_type: "error";
|
|
3562
3666
|
/**
|
|
3563
3667
|
* Error message from an interaction.
|
|
3564
3668
|
*/
|
|
@@ -3570,6 +3674,7 @@ declare type ErrorEvent_2 = {
|
|
|
3570
3674
|
* this event.
|
|
3571
3675
|
*/
|
|
3572
3676
|
event_id?: string | undefined;
|
|
3677
|
+
event_type: "error";
|
|
3573
3678
|
metadata?: StreamMetadata | undefined;
|
|
3574
3679
|
};
|
|
3575
3680
|
|
|
@@ -3768,33 +3873,36 @@ declare type FileCitation$ = FileCitation;
|
|
|
3768
3873
|
* A file citation annotation.
|
|
3769
3874
|
*/
|
|
3770
3875
|
declare type FileCitation = {
|
|
3771
|
-
|
|
3876
|
+
/**
|
|
3877
|
+
* User provided metadata about the retrieved context.
|
|
3878
|
+
*/
|
|
3879
|
+
custom_metadata?: {
|
|
3880
|
+
[k: string]: any;
|
|
3881
|
+
} | undefined;
|
|
3772
3882
|
/**
|
|
3773
3883
|
* The URI of the file.
|
|
3774
3884
|
*/
|
|
3775
3885
|
document_uri?: string | undefined;
|
|
3776
3886
|
/**
|
|
3777
|
-
*
|
|
3887
|
+
* End of the attributed segment, exclusive.
|
|
3778
3888
|
*/
|
|
3779
|
-
|
|
3889
|
+
end_index?: number | undefined;
|
|
3780
3890
|
/**
|
|
3781
|
-
*
|
|
3891
|
+
* The name of the file.
|
|
3782
3892
|
*/
|
|
3783
|
-
|
|
3893
|
+
file_name?: string | undefined;
|
|
3784
3894
|
/**
|
|
3785
|
-
*
|
|
3895
|
+
* Media ID in-case of image citations, if applicable.
|
|
3786
3896
|
*/
|
|
3787
|
-
|
|
3788
|
-
[k: string]: any;
|
|
3789
|
-
} | undefined;
|
|
3897
|
+
media_id?: string | undefined;
|
|
3790
3898
|
/**
|
|
3791
3899
|
* Page number of the cited document, if applicable.
|
|
3792
3900
|
*/
|
|
3793
3901
|
page_number?: number | undefined;
|
|
3794
3902
|
/**
|
|
3795
|
-
*
|
|
3903
|
+
* Source attributed for a portion of the text.
|
|
3796
3904
|
*/
|
|
3797
|
-
|
|
3905
|
+
source?: string | undefined;
|
|
3798
3906
|
/**
|
|
3799
3907
|
* Start of segment of the response that is attributed to this source.
|
|
3800
3908
|
*
|
|
@@ -3803,10 +3911,7 @@ declare type FileCitation = {
|
|
|
3803
3911
|
* Index indicates the start of the segment, measured in bytes.
|
|
3804
3912
|
*/
|
|
3805
3913
|
start_index?: number | undefined;
|
|
3806
|
-
|
|
3807
|
-
* End of the attributed segment, exclusive.
|
|
3808
|
-
*/
|
|
3809
|
-
end_index?: number | undefined;
|
|
3914
|
+
type: "file_citation";
|
|
3810
3915
|
};
|
|
3811
3916
|
|
|
3812
3917
|
/** URI-based data. A FileData message contains a URI pointing to data of a specific media type. It is used to represent images, audio, and video stored in Google Cloud Storage. */
|
|
@@ -3962,19 +4067,19 @@ export declare interface FileSearch {
|
|
|
3962
4067
|
* A tool that can be used by the model to search files.
|
|
3963
4068
|
*/
|
|
3964
4069
|
declare type FileSearch_2 = {
|
|
3965
|
-
type: "file_search";
|
|
3966
4070
|
/**
|
|
3967
4071
|
* The file search store names to search.
|
|
3968
4072
|
*/
|
|
3969
4073
|
file_search_store_names?: Array<string> | undefined;
|
|
3970
|
-
/**
|
|
3971
|
-
* The number of semantic retrieval chunks to retrieve.
|
|
3972
|
-
*/
|
|
3973
|
-
top_k?: number | undefined;
|
|
3974
4074
|
/**
|
|
3975
4075
|
* Metadata filter to apply to the semantic retrieval documents and chunks.
|
|
3976
4076
|
*/
|
|
3977
4077
|
metadata_filter?: string | undefined;
|
|
4078
|
+
/**
|
|
4079
|
+
* The number of semantic retrieval chunks to retrieve.
|
|
4080
|
+
*/
|
|
4081
|
+
top_k?: number | undefined;
|
|
4082
|
+
type: "file_search";
|
|
3978
4083
|
};
|
|
3979
4084
|
|
|
3980
4085
|
declare type FileSearchCall$ = FileSearchCallDelta;
|
|
@@ -3987,11 +4092,11 @@ declare type FileSearchCall$ = FileSearchCallDelta;
|
|
|
3987
4092
|
* g3-prettier-ignore-file
|
|
3988
4093
|
*/
|
|
3989
4094
|
declare type FileSearchCallDelta = {
|
|
3990
|
-
type: "file_search_call";
|
|
3991
4095
|
/**
|
|
3992
4096
|
* A signature hash for backend validation.
|
|
3993
4097
|
*/
|
|
3994
4098
|
signature?: string | undefined;
|
|
4099
|
+
type: "file_search_call";
|
|
3995
4100
|
};
|
|
3996
4101
|
|
|
3997
4102
|
declare type FileSearchCallStep$ = FileSearchCallStep;
|
|
@@ -4007,7 +4112,6 @@ declare type FileSearchCallStep$ = FileSearchCallStep;
|
|
|
4007
4112
|
* File Search call step.
|
|
4008
4113
|
*/
|
|
4009
4114
|
declare type FileSearchCallStep = {
|
|
4010
|
-
type: "file_search_call";
|
|
4011
4115
|
/**
|
|
4012
4116
|
* Required. A unique ID for this specific tool call.
|
|
4013
4117
|
*/
|
|
@@ -4016,6 +4120,7 @@ declare type FileSearchCallStep = {
|
|
|
4016
4120
|
* A signature hash for backend validation.
|
|
4017
4121
|
*/
|
|
4018
4122
|
signature?: string | undefined;
|
|
4123
|
+
type: "file_search_call";
|
|
4019
4124
|
};
|
|
4020
4125
|
|
|
4021
4126
|
declare type FileSearchResult$ = FileSearchResultDelta;
|
|
@@ -4033,12 +4138,12 @@ declare type FileSearchResult$ = FileSearchResultDelta;
|
|
|
4033
4138
|
declare type FileSearchResult = {};
|
|
4034
4139
|
|
|
4035
4140
|
declare type FileSearchResultDelta = {
|
|
4036
|
-
type: "file_search_result";
|
|
4037
4141
|
result: Array<FileSearchResult>;
|
|
4038
4142
|
/**
|
|
4039
4143
|
* A signature hash for backend validation.
|
|
4040
4144
|
*/
|
|
4041
4145
|
signature?: string | undefined;
|
|
4146
|
+
type: "file_search_result";
|
|
4042
4147
|
};
|
|
4043
4148
|
|
|
4044
4149
|
declare type FileSearchResultStep$ = FileSearchResultStep;
|
|
@@ -4054,7 +4159,6 @@ declare type FileSearchResultStep$ = FileSearchResultStep;
|
|
|
4054
4159
|
* File Search result step.
|
|
4055
4160
|
*/
|
|
4056
4161
|
declare type FileSearchResultStep = {
|
|
4057
|
-
type: "file_search_result";
|
|
4058
4162
|
/**
|
|
4059
4163
|
* Required. ID to match the ID from the function call block.
|
|
4060
4164
|
*/
|
|
@@ -4063,6 +4167,7 @@ declare type FileSearchResultStep = {
|
|
|
4063
4167
|
* A signature hash for backend validation.
|
|
4064
4168
|
*/
|
|
4065
4169
|
signature?: string | undefined;
|
|
4170
|
+
type: "file_search_result";
|
|
4066
4171
|
};
|
|
4067
4172
|
|
|
4068
4173
|
/** A collection of Documents. */
|
|
@@ -4239,6 +4344,10 @@ export declare interface FileStatus {
|
|
|
4239
4344
|
* Config for filters.
|
|
4240
4345
|
*/
|
|
4241
4346
|
declare type Filter = {
|
|
4347
|
+
/**
|
|
4348
|
+
* Optional. String for metadata filtering.
|
|
4349
|
+
*/
|
|
4350
|
+
metadata_filter?: string | undefined;
|
|
4242
4351
|
/**
|
|
4243
4352
|
* Optional. Only returns contexts with vector distance smaller than the
|
|
4244
4353
|
*
|
|
@@ -4253,10 +4362,6 @@ declare type Filter = {
|
|
|
4253
4362
|
* threshold.
|
|
4254
4363
|
*/
|
|
4255
4364
|
vector_similarity_threshold?: number | undefined;
|
|
4256
|
-
/**
|
|
4257
|
-
* Optional. String for metadata filtering.
|
|
4258
|
-
*/
|
|
4259
|
-
metadata_filter?: string | undefined;
|
|
4260
4365
|
};
|
|
4261
4366
|
|
|
4262
4367
|
/** Output only. The reason why the model stopped generating tokens.
|
|
@@ -4406,11 +4511,6 @@ declare type FunctionCallStep$ = FunctionCallStep;
|
|
|
4406
4511
|
* A function tool call step.
|
|
4407
4512
|
*/
|
|
4408
4513
|
declare type FunctionCallStep = {
|
|
4409
|
-
type: "function_call";
|
|
4410
|
-
/**
|
|
4411
|
-
* Required. The name of the tool to call.
|
|
4412
|
-
*/
|
|
4413
|
-
name: string;
|
|
4414
4514
|
/**
|
|
4415
4515
|
* Required. The arguments to pass to the function.
|
|
4416
4516
|
*/
|
|
@@ -4421,6 +4521,11 @@ declare type FunctionCallStep = {
|
|
|
4421
4521
|
* Required. A unique ID for this specific tool call.
|
|
4422
4522
|
*/
|
|
4423
4523
|
id: string;
|
|
4524
|
+
/**
|
|
4525
|
+
* Required. The name of the tool to call.
|
|
4526
|
+
*/
|
|
4527
|
+
name: string;
|
|
4528
|
+
type: "function_call";
|
|
4424
4529
|
};
|
|
4425
4530
|
|
|
4426
4531
|
/** Structured representation of a function declaration as defined by the [OpenAPI 3.0 specification](https://spec.openapis.org/oas/v3.0.3). Included in this declaration are the function name, description, parameters and response type. This FunctionDeclaration is a representation of a block of code that can be used as a `Tool` by the model and executed by the client. */
|
|
@@ -4437,7 +4542,7 @@ export declare interface FunctionDeclaration {
|
|
|
4437
4542
|
response?: Schema;
|
|
4438
4543
|
/** Optional. Describes the output from this function in JSON Schema format. The value specified by the schema is the response value of the function. This field is mutually exclusive with `response`. */
|
|
4439
4544
|
responseJsonSchema?: unknown;
|
|
4440
|
-
/** Optional. Specifies the function Behavior.
|
|
4545
|
+
/** Optional. Specifies the function Behavior. If not specified, the system keeps the current function call behavior. This field is currently only supported by the BidiGenerateContent method. */
|
|
4441
4546
|
behavior?: Behavior;
|
|
4442
4547
|
}
|
|
4443
4548
|
|
|
@@ -4509,14 +4614,14 @@ export declare enum FunctionResponseScheduling {
|
|
|
4509
4614
|
declare type FunctionResult$ = FunctionResultDelta;
|
|
4510
4615
|
|
|
4511
4616
|
declare type FunctionResultDelta = {
|
|
4512
|
-
type: "function_result";
|
|
4513
|
-
name?: string | undefined;
|
|
4514
|
-
is_error?: boolean | undefined;
|
|
4515
4617
|
/**
|
|
4516
4618
|
* Required. ID to match the ID from the function call block.
|
|
4517
4619
|
*/
|
|
4518
4620
|
call_id: string;
|
|
4621
|
+
is_error?: boolean | undefined;
|
|
4622
|
+
name?: string | undefined;
|
|
4519
4623
|
result: FunctionResultDeltaResult | Array<FunctionResultSubcontent> | string;
|
|
4624
|
+
type: "function_result";
|
|
4520
4625
|
};
|
|
4521
4626
|
|
|
4522
4627
|
declare type FunctionResultDeltaResult = {};
|
|
@@ -4529,23 +4634,23 @@ declare type FunctionResultStep$ = FunctionResultStep;
|
|
|
4529
4634
|
* Result of a function tool call.
|
|
4530
4635
|
*/
|
|
4531
4636
|
declare type FunctionResultStep = {
|
|
4532
|
-
type: "function_result";
|
|
4533
4637
|
/**
|
|
4534
|
-
*
|
|
4638
|
+
* Required. ID to match the ID from the function call block.
|
|
4535
4639
|
*/
|
|
4536
|
-
|
|
4640
|
+
call_id: string;
|
|
4537
4641
|
/**
|
|
4538
4642
|
* Whether the tool call resulted in an error.
|
|
4539
4643
|
*/
|
|
4540
4644
|
is_error?: boolean | undefined;
|
|
4541
4645
|
/**
|
|
4542
|
-
*
|
|
4646
|
+
* The name of the tool that was called.
|
|
4543
4647
|
*/
|
|
4544
|
-
|
|
4648
|
+
name?: string | undefined;
|
|
4545
4649
|
/**
|
|
4546
4650
|
* The result of the tool call.
|
|
4547
4651
|
*/
|
|
4548
4652
|
result: FunctionResultStepResult | Array<FunctionResultSubcontent> | string;
|
|
4653
|
+
type: "function_result";
|
|
4549
4654
|
};
|
|
4550
4655
|
|
|
4551
4656
|
declare type FunctionResultStepResult = {};
|
|
@@ -4568,19 +4673,19 @@ declare type FunctionResultSubcontent = TextContent | ImageContent;
|
|
|
4568
4673
|
* A tool that can be used by the model.
|
|
4569
4674
|
*/
|
|
4570
4675
|
declare type FunctionT = {
|
|
4571
|
-
type: "function";
|
|
4572
|
-
/**
|
|
4573
|
-
* The name of the function.
|
|
4574
|
-
*/
|
|
4575
|
-
name?: string | undefined;
|
|
4576
4676
|
/**
|
|
4577
4677
|
* A description of the function.
|
|
4578
4678
|
*/
|
|
4579
4679
|
description?: string | undefined;
|
|
4680
|
+
/**
|
|
4681
|
+
* The name of the function.
|
|
4682
|
+
*/
|
|
4683
|
+
name?: string | undefined;
|
|
4580
4684
|
/**
|
|
4581
4685
|
* The JSON Schema for the function's parameters.
|
|
4582
4686
|
*/
|
|
4583
4687
|
parameters?: any | undefined;
|
|
4688
|
+
type: "function";
|
|
4584
4689
|
};
|
|
4585
4690
|
|
|
4586
4691
|
/** The Google Cloud Storage location for the input content. This data type is not supported in Gemini API. */
|
|
@@ -5287,11 +5392,11 @@ export declare interface GenerationConfig {
|
|
|
5287
5392
|
presencePenalty?: number;
|
|
5288
5393
|
/** 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. */
|
|
5289
5394
|
responseLogprobs?: boolean;
|
|
5290
|
-
/** 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. */
|
|
5395
|
+
/** Optional. The IANA standard MIME type of the response. The model will generate output that conforms to this MIME type. Supported values include 'text/plain' (default) and 'application/json'. The model needs to be prompted to output the appropriate response type, otherwise the behavior is undefined. Deprecated: Use `response_format` instead. */
|
|
5291
5396
|
responseMimeType?: string;
|
|
5292
5397
|
/** 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. */
|
|
5293
5398
|
responseModalities?: Modality[];
|
|
5294
|
-
/** 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`. */
|
|
5399
|
+
/** Optional. Lets you to specify a schema for the model's response, ensuring that the output conforms to a particular structure. This is useful for generating structured data such as JSON. The schema is a subset of the [OpenAPI 3.0 schema object](https://spec.openapis.org/oas/v3.0.3#schema) object. When this field is set, you must also set the `response_mime_type` to `application/json`. Deprecated: Use `response_format` instead. */
|
|
5295
5400
|
responseSchema?: Schema;
|
|
5296
5401
|
/** Optional. Routing configuration. This field is not supported in Gemini API. */
|
|
5297
5402
|
routingConfig?: GenerationConfigRoutingConfig;
|
|
@@ -5311,6 +5416,10 @@ export declare interface GenerationConfig {
|
|
|
5311
5416
|
topP?: number;
|
|
5312
5417
|
/** Optional. Enables enhanced civic answers. It may not be available for all models. This field is not supported in Vertex AI. */
|
|
5313
5418
|
enableEnhancedCivicAnswers?: boolean;
|
|
5419
|
+
/** Optional. New response format field for the model to configure output formatting and delivery. */
|
|
5420
|
+
responseFormat?: ResponseFormat[];
|
|
5421
|
+
/** Optional. Config for translation. This field is not supported in Vertex AI. */
|
|
5422
|
+
translationConfig?: TranslationConfig;
|
|
5314
5423
|
}
|
|
5315
5424
|
|
|
5316
5425
|
/**
|
|
@@ -5318,61 +5427,45 @@ export declare interface GenerationConfig {
|
|
|
5318
5427
|
*/
|
|
5319
5428
|
declare type GenerationConfig_2 = {
|
|
5320
5429
|
/**
|
|
5321
|
-
*
|
|
5430
|
+
* The configuration for image interaction.
|
|
5431
|
+
*
|
|
5432
|
+
* @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
5322
5433
|
*/
|
|
5323
|
-
|
|
5434
|
+
image_config?: ImageConfig_2 | undefined;
|
|
5324
5435
|
/**
|
|
5325
|
-
* The maximum
|
|
5436
|
+
* The maximum number of tokens to include in the response.
|
|
5326
5437
|
*/
|
|
5327
|
-
|
|
5438
|
+
max_output_tokens?: number | undefined;
|
|
5328
5439
|
/**
|
|
5329
5440
|
* Seed used in decoding for reproducibility.
|
|
5330
5441
|
*/
|
|
5331
5442
|
seed?: number | undefined;
|
|
5332
|
-
/**
|
|
5333
|
-
* A list of character sequences that will stop output interaction.
|
|
5334
|
-
*/
|
|
5335
|
-
stop_sequences?: Array<string> | undefined;
|
|
5336
|
-
thinking_level?: ThinkingLevel_2 | undefined;
|
|
5337
|
-
thinking_summaries?: ThinkingSummaries | undefined;
|
|
5338
|
-
/**
|
|
5339
|
-
* The maximum number of tokens to include in the response.
|
|
5340
|
-
*/
|
|
5341
|
-
max_output_tokens?: number | undefined;
|
|
5342
5443
|
/**
|
|
5343
5444
|
* Configuration for speech interaction.
|
|
5344
5445
|
*/
|
|
5345
5446
|
speech_config?: Array<SpeechConfig_2> | undefined;
|
|
5346
5447
|
/**
|
|
5347
|
-
*
|
|
5348
|
-
*
|
|
5349
|
-
* @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
5448
|
+
* A list of character sequences that will stop output interaction.
|
|
5350
5449
|
*/
|
|
5351
|
-
|
|
5450
|
+
stop_sequences?: Array<string> | undefined;
|
|
5352
5451
|
/**
|
|
5353
|
-
*
|
|
5452
|
+
* Controls the randomness of the output.
|
|
5354
5453
|
*/
|
|
5355
|
-
|
|
5454
|
+
temperature?: number | undefined;
|
|
5455
|
+
thinking_level?: ThinkingLevel_2 | undefined;
|
|
5456
|
+
thinking_summaries?: ThinkingSummaries | undefined;
|
|
5356
5457
|
/**
|
|
5357
|
-
*
|
|
5358
|
-
*
|
|
5359
|
-
* @remarks
|
|
5360
|
-
* text. A positive value encourages the model to generate more diverse and
|
|
5361
|
-
* less repetitive text. Valid values can range from [-2.0, 2.0].
|
|
5458
|
+
* The tool choice configuration.
|
|
5362
5459
|
*/
|
|
5363
|
-
|
|
5460
|
+
tool_choice?: ToolChoiceType | ToolChoiceConfig | undefined;
|
|
5364
5461
|
/**
|
|
5365
|
-
*
|
|
5366
|
-
*
|
|
5367
|
-
* @remarks
|
|
5368
|
-
* A positive value helps to reduce the repetition of words and phrases.
|
|
5369
|
-
* Valid values can range from [-2.0, 2.0].
|
|
5462
|
+
* The maximum cumulative probability of tokens to consider when sampling.
|
|
5370
5463
|
*/
|
|
5371
|
-
|
|
5464
|
+
top_p?: number | undefined;
|
|
5372
5465
|
/**
|
|
5373
|
-
*
|
|
5466
|
+
* Configuration options for video generation.
|
|
5374
5467
|
*/
|
|
5375
|
-
|
|
5468
|
+
video_config?: VideoConfig | undefined;
|
|
5376
5469
|
};
|
|
5377
5470
|
|
|
5378
5471
|
/** The configuration for routing the request to a specific model. This can be used to control which model is used for the generation, either automatically or by specifying a model name. This data type is not supported in Gemini API. */
|
|
@@ -5823,7 +5916,6 @@ export declare interface GoogleMaps {
|
|
|
5823
5916
|
* A tool that can be used by the model to call Google Maps.
|
|
5824
5917
|
*/
|
|
5825
5918
|
declare type GoogleMaps_2 = {
|
|
5826
|
-
type: "google_maps";
|
|
5827
5919
|
/**
|
|
5828
5920
|
* Whether to return a widget context token in the tool call result of the
|
|
5829
5921
|
*
|
|
@@ -5839,6 +5931,7 @@ declare type GoogleMaps_2 = {
|
|
|
5839
5931
|
* The longitude of the user's location.
|
|
5840
5932
|
*/
|
|
5841
5933
|
longitude?: number | undefined;
|
|
5934
|
+
type: "google_maps";
|
|
5842
5935
|
};
|
|
5843
5936
|
|
|
5844
5937
|
declare type GoogleMapsCall$ = GoogleMapsCallDelta;
|
|
@@ -5863,7 +5956,6 @@ declare type GoogleMapsCallArguments = {
|
|
|
5863
5956
|
};
|
|
5864
5957
|
|
|
5865
5958
|
declare type GoogleMapsCallDelta = {
|
|
5866
|
-
type: "google_maps_call";
|
|
5867
5959
|
/**
|
|
5868
5960
|
* The arguments to pass to the Google Maps tool.
|
|
5869
5961
|
*/
|
|
@@ -5872,6 +5964,7 @@ declare type GoogleMapsCallDelta = {
|
|
|
5872
5964
|
* A signature hash for backend validation.
|
|
5873
5965
|
*/
|
|
5874
5966
|
signature?: string | undefined;
|
|
5967
|
+
type: "google_maps_call";
|
|
5875
5968
|
};
|
|
5876
5969
|
|
|
5877
5970
|
declare type GoogleMapsCallStep$ = GoogleMapsCallStep;
|
|
@@ -5880,7 +5973,6 @@ declare type GoogleMapsCallStep$ = GoogleMapsCallStep;
|
|
|
5880
5973
|
* Google Maps call step.
|
|
5881
5974
|
*/
|
|
5882
5975
|
declare type GoogleMapsCallStep = {
|
|
5883
|
-
type: "google_maps_call";
|
|
5884
5976
|
/**
|
|
5885
5977
|
* The arguments to pass to the Google Maps tool.
|
|
5886
5978
|
*/
|
|
@@ -5893,6 +5985,7 @@ declare type GoogleMapsCallStep = {
|
|
|
5893
5985
|
* A signature hash for backend validation.
|
|
5894
5986
|
*/
|
|
5895
5987
|
signature?: string | undefined;
|
|
5988
|
+
type: "google_maps_call";
|
|
5896
5989
|
};
|
|
5897
5990
|
|
|
5898
5991
|
declare type GoogleMapsResult$ = GoogleMapsResult;
|
|
@@ -5908,7 +6001,6 @@ declare type GoogleMapsResult = {
|
|
|
5908
6001
|
};
|
|
5909
6002
|
|
|
5910
6003
|
declare type GoogleMapsResultDelta = {
|
|
5911
|
-
type: "google_maps_result";
|
|
5912
6004
|
/**
|
|
5913
6005
|
* The results of the Google Maps.
|
|
5914
6006
|
*/
|
|
@@ -5917,13 +6009,14 @@ declare type GoogleMapsResultDelta = {
|
|
|
5917
6009
|
* A signature hash for backend validation.
|
|
5918
6010
|
*/
|
|
5919
6011
|
signature?: string | undefined;
|
|
6012
|
+
type: "google_maps_result";
|
|
5920
6013
|
};
|
|
5921
6014
|
|
|
5922
6015
|
declare type GoogleMapsResultPlaces = {
|
|
5923
|
-
place_id?: string | undefined;
|
|
5924
6016
|
name?: string | undefined;
|
|
5925
|
-
|
|
6017
|
+
place_id?: string | undefined;
|
|
5926
6018
|
review_snippets?: Array<ReviewSnippet> | undefined;
|
|
6019
|
+
url?: string | undefined;
|
|
5927
6020
|
};
|
|
5928
6021
|
|
|
5929
6022
|
declare type GoogleMapsResultStep$ = GoogleMapsResultStep;
|
|
@@ -5932,16 +6025,16 @@ declare type GoogleMapsResultStep$ = GoogleMapsResultStep;
|
|
|
5932
6025
|
* Google Maps result step.
|
|
5933
6026
|
*/
|
|
5934
6027
|
declare type GoogleMapsResultStep = {
|
|
5935
|
-
type: "google_maps_result";
|
|
5936
|
-
result: Array<GoogleMapsResult>;
|
|
5937
6028
|
/**
|
|
5938
6029
|
* Required. ID to match the ID from the function call block.
|
|
5939
6030
|
*/
|
|
5940
6031
|
call_id: string;
|
|
6032
|
+
result: Array<GoogleMapsResult>;
|
|
5941
6033
|
/**
|
|
5942
6034
|
* A signature hash for backend validation.
|
|
5943
6035
|
*/
|
|
5944
6036
|
signature?: string | undefined;
|
|
6037
|
+
type: "google_maps_result";
|
|
5945
6038
|
};
|
|
5946
6039
|
|
|
5947
6040
|
/** 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). This data type is not supported in Gemini API. */
|
|
@@ -5972,11 +6065,11 @@ export declare interface GoogleSearch {
|
|
|
5972
6065
|
* A tool that can be used by the model to search Google.
|
|
5973
6066
|
*/
|
|
5974
6067
|
declare type GoogleSearch_2 = {
|
|
5975
|
-
type: "google_search";
|
|
5976
6068
|
/**
|
|
5977
6069
|
* The types of search grounding to enable.
|
|
5978
6070
|
*/
|
|
5979
6071
|
search_types?: Array<GoogleSearchSearchType> | undefined;
|
|
6072
|
+
type: "google_search";
|
|
5980
6073
|
};
|
|
5981
6074
|
|
|
5982
6075
|
declare type GoogleSearchCall$ = GoogleSearchCallDelta;
|
|
@@ -6001,7 +6094,6 @@ declare type GoogleSearchCallArguments = {
|
|
|
6001
6094
|
};
|
|
6002
6095
|
|
|
6003
6096
|
declare type GoogleSearchCallDelta = {
|
|
6004
|
-
type: "google_search_call";
|
|
6005
6097
|
/**
|
|
6006
6098
|
* The arguments to pass to Google Search.
|
|
6007
6099
|
*/
|
|
@@ -6010,6 +6102,7 @@ declare type GoogleSearchCallDelta = {
|
|
|
6010
6102
|
* A signature hash for backend validation.
|
|
6011
6103
|
*/
|
|
6012
6104
|
signature?: string | undefined;
|
|
6105
|
+
type: "google_search_call";
|
|
6013
6106
|
};
|
|
6014
6107
|
|
|
6015
6108
|
declare type GoogleSearchCallStep$ = GoogleSearchCallStep;
|
|
@@ -6018,23 +6111,23 @@ declare type GoogleSearchCallStep$ = GoogleSearchCallStep;
|
|
|
6018
6111
|
* Google Search call step.
|
|
6019
6112
|
*/
|
|
6020
6113
|
declare type GoogleSearchCallStep = {
|
|
6021
|
-
type: "google_search_call";
|
|
6022
6114
|
/**
|
|
6023
6115
|
* The arguments to pass to Google Search.
|
|
6024
6116
|
*/
|
|
6025
6117
|
arguments: GoogleSearchCallArguments;
|
|
6026
|
-
/**
|
|
6027
|
-
* The type of search grounding enabled.
|
|
6028
|
-
*/
|
|
6029
|
-
search_type?: GoogleSearchCallStepSearchType | undefined;
|
|
6030
6118
|
/**
|
|
6031
6119
|
* Required. A unique ID for this specific tool call.
|
|
6032
6120
|
*/
|
|
6033
6121
|
id: string;
|
|
6122
|
+
/**
|
|
6123
|
+
* The type of search grounding enabled.
|
|
6124
|
+
*/
|
|
6125
|
+
search_type?: GoogleSearchCallStepSearchType | undefined;
|
|
6034
6126
|
/**
|
|
6035
6127
|
* A signature hash for backend validation.
|
|
6036
6128
|
*/
|
|
6037
6129
|
signature?: string | undefined;
|
|
6130
|
+
type: "google_search_call";
|
|
6038
6131
|
};
|
|
6039
6132
|
|
|
6040
6133
|
/**
|
|
@@ -6064,13 +6157,13 @@ declare type GoogleSearchResult = {
|
|
|
6064
6157
|
};
|
|
6065
6158
|
|
|
6066
6159
|
declare type GoogleSearchResultDelta = {
|
|
6067
|
-
type: "google_search_result";
|
|
6068
|
-
result: Array<GoogleSearchResult>;
|
|
6069
6160
|
is_error?: boolean | undefined;
|
|
6161
|
+
result: Array<GoogleSearchResult>;
|
|
6070
6162
|
/**
|
|
6071
6163
|
* A signature hash for backend validation.
|
|
6072
6164
|
*/
|
|
6073
6165
|
signature?: string | undefined;
|
|
6166
|
+
type: "google_search_result";
|
|
6074
6167
|
};
|
|
6075
6168
|
|
|
6076
6169
|
declare type GoogleSearchResultStep$ = GoogleSearchResultStep;
|
|
@@ -6079,23 +6172,23 @@ declare type GoogleSearchResultStep$ = GoogleSearchResultStep;
|
|
|
6079
6172
|
* Google Search result step.
|
|
6080
6173
|
*/
|
|
6081
6174
|
declare type GoogleSearchResultStep = {
|
|
6082
|
-
type: "google_search_result";
|
|
6083
6175
|
/**
|
|
6084
|
-
* Required.
|
|
6176
|
+
* Required. ID to match the ID from the function call block.
|
|
6085
6177
|
*/
|
|
6086
|
-
|
|
6178
|
+
call_id: string;
|
|
6087
6179
|
/**
|
|
6088
6180
|
* Whether the Google Search resulted in an error.
|
|
6089
6181
|
*/
|
|
6090
6182
|
is_error?: boolean | undefined;
|
|
6091
6183
|
/**
|
|
6092
|
-
* Required.
|
|
6184
|
+
* Required. The results of the Google Search.
|
|
6093
6185
|
*/
|
|
6094
|
-
|
|
6186
|
+
result: Array<GoogleSearchResult>;
|
|
6095
6187
|
/**
|
|
6096
6188
|
* A signature hash for backend validation.
|
|
6097
6189
|
*/
|
|
6098
6190
|
signature?: string | undefined;
|
|
6191
|
+
type: "google_search_result";
|
|
6099
6192
|
};
|
|
6100
6193
|
|
|
6101
6194
|
/** Tool to retrieve public web data for grounding, powered by Google. */
|
|
@@ -6298,7 +6391,7 @@ export declare interface GroundingMetadata {
|
|
|
6298
6391
|
searchEntryPoint?: SearchEntryPoint;
|
|
6299
6392
|
/** Web search queries for the following-up web search. */
|
|
6300
6393
|
webSearchQueries?: string[];
|
|
6301
|
-
/** Optional. Output only. A token that can be used to render a Google Maps widget with the contextual data. This field is populated only when the grounding source is Google Maps. */
|
|
6394
|
+
/** Optional. Output only. Deprecated: The Google Maps contextual widget behavior in Grounding with Google Maps is being deprecated; this field is planned for removal and will no longer be populated once removed. A token that can be used to render a Google Maps widget with the contextual data. This field is populated only when the grounding source is Google Maps. */
|
|
6302
6395
|
googleMapsWidgetContextToken?: string;
|
|
6303
6396
|
/** Optional. The queries that were executed by the retrieval tools. This field is populated only when the grounding source is a retrieval tool, such as Vertex AI Search. This field is not supported in Gemini API. */
|
|
6304
6397
|
retrievalQueries?: string[];
|
|
@@ -6338,14 +6431,14 @@ declare type GroundingToolCount$ = GroundingToolCount;
|
|
|
6338
6431
|
* The number of grounding tool counts.
|
|
6339
6432
|
*/
|
|
6340
6433
|
declare type GroundingToolCount = {
|
|
6341
|
-
/**
|
|
6342
|
-
* The grounding tool type associated with the count.
|
|
6343
|
-
*/
|
|
6344
|
-
type?: GroundingToolCountType | undefined;
|
|
6345
6434
|
/**
|
|
6346
6435
|
* The number of grounding tool counts.
|
|
6347
6436
|
*/
|
|
6348
6437
|
count?: number | undefined;
|
|
6438
|
+
/**
|
|
6439
|
+
* The grounding tool type associated with the count.
|
|
6440
|
+
*/
|
|
6441
|
+
type?: GroundingToolCountType | undefined;
|
|
6349
6442
|
};
|
|
6350
6443
|
|
|
6351
6444
|
/**
|
|
@@ -6404,6 +6497,8 @@ export declare enum HarmBlockThreshold {
|
|
|
6404
6497
|
OFF = "OFF"
|
|
6405
6498
|
}
|
|
6406
6499
|
|
|
6500
|
+
declare type HarmCategory$ = HarmCategory_2;
|
|
6501
|
+
|
|
6407
6502
|
/** The harm category to be blocked. */
|
|
6408
6503
|
export declare enum HarmCategory {
|
|
6409
6504
|
/**
|
|
@@ -6452,6 +6547,15 @@ export declare enum HarmCategory {
|
|
|
6452
6547
|
HARM_CATEGORY_JAILBREAK = "HARM_CATEGORY_JAILBREAK"
|
|
6453
6548
|
}
|
|
6454
6549
|
|
|
6550
|
+
/**
|
|
6551
|
+
* @license
|
|
6552
|
+
* Copyright 2026 Google LLC
|
|
6553
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
6554
|
+
*
|
|
6555
|
+
* g3-prettier-ignore-file
|
|
6556
|
+
*/
|
|
6557
|
+
declare type HarmCategory_2 = "hate_speech" | "dangerous_content" | "harassment" | "sexually_explicit" | "civic_integrity" | "image_hate" | "image_dangerous_content" | "image_harassment" | "image_sexually_explicit" | "jailbreak" | (string & {});
|
|
6558
|
+
|
|
6455
6559
|
/** Output only. The probability of harm for this category. */
|
|
6456
6560
|
export declare enum HarmProbability {
|
|
6457
6561
|
/**
|
|
@@ -6711,20 +6815,20 @@ declare type ImageContent$ = ImageContent;
|
|
|
6711
6815
|
* An image content block.
|
|
6712
6816
|
*/
|
|
6713
6817
|
declare type ImageContent = {
|
|
6714
|
-
type: "image";
|
|
6715
6818
|
/**
|
|
6716
6819
|
* The image content.
|
|
6717
6820
|
*/
|
|
6718
6821
|
data?: string | undefined;
|
|
6719
|
-
/**
|
|
6720
|
-
* The URI of the image.
|
|
6721
|
-
*/
|
|
6722
|
-
uri?: string | undefined;
|
|
6723
6822
|
/**
|
|
6724
6823
|
* The mime type of the image.
|
|
6725
6824
|
*/
|
|
6726
6825
|
mime_type?: ImageContentMimeType | undefined;
|
|
6727
6826
|
resolution?: MediaResolution_2 | undefined;
|
|
6827
|
+
type: "image";
|
|
6828
|
+
/**
|
|
6829
|
+
* The URI of the image.
|
|
6830
|
+
*/
|
|
6831
|
+
uri?: string | undefined;
|
|
6728
6832
|
};
|
|
6729
6833
|
|
|
6730
6834
|
/**
|
|
@@ -6733,11 +6837,11 @@ declare type ImageContent = {
|
|
|
6733
6837
|
declare type ImageContentMimeType = "image/png" | "image/jpeg" | "image/webp" | "image/heic" | "image/heif" | "image/gif" | "image/bmp" | "image/tiff" | (string & {});
|
|
6734
6838
|
|
|
6735
6839
|
declare type ImageDelta = {
|
|
6736
|
-
type: "image";
|
|
6737
6840
|
data?: string | undefined;
|
|
6738
|
-
uri?: string | undefined;
|
|
6739
6841
|
mime_type?: ImageDeltaMimeType | undefined;
|
|
6740
6842
|
resolution?: MediaResolution_2 | undefined;
|
|
6843
|
+
type: "image";
|
|
6844
|
+
uri?: string | undefined;
|
|
6741
6845
|
};
|
|
6742
6846
|
|
|
6743
6847
|
declare type ImageDeltaMimeType = "image/png" | "image/jpeg" | "image/webp" | "image/heic" | "image/heif" | "image/gif" | "image/bmp" | "image/tiff" | (string & {});
|
|
@@ -6792,31 +6896,50 @@ export declare enum ImageResizeMode {
|
|
|
6792
6896
|
PAD = "PAD"
|
|
6793
6897
|
}
|
|
6794
6898
|
|
|
6795
|
-
declare type ImageResponseFormat$ =
|
|
6899
|
+
declare type ImageResponseFormat$ = ImageResponseFormat_2;
|
|
6900
|
+
|
|
6901
|
+
/** Configuration for image-specific output formatting. */
|
|
6902
|
+
export declare class ImageResponseFormat {
|
|
6903
|
+
/** Optional. The aspect ratio for the image output. */
|
|
6904
|
+
aspectRatio?: AspectRatio;
|
|
6905
|
+
/** Optional. Delivery mode for the generated content. */
|
|
6906
|
+
delivery?: Delivery;
|
|
6907
|
+
/** Optional. The size of the image output. */
|
|
6908
|
+
imageSize?: ImageSize;
|
|
6909
|
+
/** Optional. The MIME type of the image output. */
|
|
6910
|
+
mimeType?: string;
|
|
6911
|
+
}
|
|
6796
6912
|
|
|
6797
6913
|
/**
|
|
6798
6914
|
* Configuration for image output format.
|
|
6799
6915
|
*/
|
|
6800
|
-
declare type
|
|
6801
|
-
type: "image";
|
|
6916
|
+
declare type ImageResponseFormat_2 = {
|
|
6802
6917
|
/**
|
|
6803
|
-
* The
|
|
6918
|
+
* The aspect ratio for the image output.
|
|
6804
6919
|
*/
|
|
6805
|
-
|
|
6920
|
+
aspect_ratio?: ImageResponseFormatAspectRatio | undefined;
|
|
6806
6921
|
/**
|
|
6807
6922
|
* The delivery mode for the image output.
|
|
6808
6923
|
*/
|
|
6809
6924
|
delivery?: ImageResponseFormatDelivery | undefined;
|
|
6810
|
-
/**
|
|
6811
|
-
* The aspect ratio for the image output.
|
|
6812
|
-
*/
|
|
6813
|
-
aspect_ratio?: ImageResponseFormatAspectRatio | undefined;
|
|
6814
6925
|
/**
|
|
6815
6926
|
* The size of the image output.
|
|
6816
6927
|
*/
|
|
6817
6928
|
image_size?: ImageResponseFormatImageSize | undefined;
|
|
6929
|
+
/**
|
|
6930
|
+
* The MIME type of the image output.
|
|
6931
|
+
*/
|
|
6932
|
+
mime_type?: ImageResponseFormatMimeType | undefined;
|
|
6933
|
+
type: "image";
|
|
6818
6934
|
};
|
|
6819
6935
|
|
|
6936
|
+
/**
|
|
6937
|
+
* @license
|
|
6938
|
+
* Copyright 2026 Google LLC
|
|
6939
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
6940
|
+
*
|
|
6941
|
+
* g3-prettier-ignore-file
|
|
6942
|
+
*/
|
|
6820
6943
|
/**
|
|
6821
6944
|
* The aspect ratio for the image output.
|
|
6822
6945
|
*/
|
|
@@ -6832,13 +6955,6 @@ declare type ImageResponseFormatDelivery = "inline" | "uri" | (string & {});
|
|
|
6832
6955
|
*/
|
|
6833
6956
|
declare type ImageResponseFormatImageSize = "512" | "1K" | "2K" | "4K" | (string & {});
|
|
6834
6957
|
|
|
6835
|
-
/**
|
|
6836
|
-
* @license
|
|
6837
|
-
* Copyright 2026 Google LLC
|
|
6838
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
6839
|
-
*
|
|
6840
|
-
* g3-prettier-ignore-file
|
|
6841
|
-
*/
|
|
6842
6958
|
/**
|
|
6843
6959
|
* The MIME type of the image output.
|
|
6844
6960
|
*/
|
|
@@ -6848,15 +6964,39 @@ declare type ImageResponseFormatMimeType = "image/jpeg";
|
|
|
6848
6964
|
export declare interface ImageSearch {
|
|
6849
6965
|
}
|
|
6850
6966
|
|
|
6851
|
-
/**
|
|
6852
|
-
export declare
|
|
6853
|
-
/**
|
|
6854
|
-
|
|
6855
|
-
|
|
6856
|
-
|
|
6857
|
-
|
|
6858
|
-
|
|
6859
|
-
|
|
6967
|
+
/** The size of the image output. */
|
|
6968
|
+
export declare enum ImageSize {
|
|
6969
|
+
/**
|
|
6970
|
+
* Default value. This value is unused.
|
|
6971
|
+
*/
|
|
6972
|
+
IMAGE_SIZE_UNSPECIFIED = "IMAGE_SIZE_UNSPECIFIED",
|
|
6973
|
+
/**
|
|
6974
|
+
* 512px image size.
|
|
6975
|
+
*/
|
|
6976
|
+
IMAGE_SIZE_FIVE_TWELVE = "IMAGE_SIZE_FIVE_TWELVE",
|
|
6977
|
+
/**
|
|
6978
|
+
* 1K image size.
|
|
6979
|
+
*/
|
|
6980
|
+
IMAGE_SIZE_ONE_K = "IMAGE_SIZE_ONE_K",
|
|
6981
|
+
/**
|
|
6982
|
+
* 2K image size.
|
|
6983
|
+
*/
|
|
6984
|
+
IMAGE_SIZE_TWO_K = "IMAGE_SIZE_TWO_K",
|
|
6985
|
+
/**
|
|
6986
|
+
* 4K image size.
|
|
6987
|
+
*/
|
|
6988
|
+
IMAGE_SIZE_FOUR_K = "IMAGE_SIZE_FOUR_K"
|
|
6989
|
+
}
|
|
6990
|
+
|
|
6991
|
+
/** Optional parameters for importing a file. */
|
|
6992
|
+
export declare interface ImportFileConfig {
|
|
6993
|
+
/** Used to override HTTP request options. */
|
|
6994
|
+
httpOptions?: HttpOptions;
|
|
6995
|
+
/** Abort signal which can be used to cancel the request.
|
|
6996
|
+
|
|
6997
|
+
NOTE: AbortSignal is a client-only operation. Using it to cancel an
|
|
6998
|
+
operation will not cancel the request in the service. You will still
|
|
6999
|
+
be charged usage for any applicable operations.
|
|
6860
7000
|
*/
|
|
6861
7001
|
abortSignal?: AbortSignal;
|
|
6862
7002
|
/** User provided custom metadata stored as key-value pairs used for querying. */
|
|
@@ -7025,7 +7165,7 @@ declare type Interaction = {
|
|
|
7025
7165
|
/**
|
|
7026
7166
|
* Enforces that the generated response is a JSON object that complies with the JSON schema specified in this field.
|
|
7027
7167
|
*/
|
|
7028
|
-
response_format?: Array<
|
|
7168
|
+
response_format?: Array<ResponseFormat_2> | ResponseFormat_2 | undefined;
|
|
7029
7169
|
/**
|
|
7030
7170
|
* The environment configuration for the interaction. Can be an object specifying remote environment sources or a string referencing an existing environment ID.
|
|
7031
7171
|
*/
|
|
@@ -7048,6 +7188,16 @@ declare type Interaction = {
|
|
|
7048
7188
|
* Configuration parameters for the agent interaction.
|
|
7049
7189
|
*/
|
|
7050
7190
|
agent_config?: DynamicAgentConfig | DeepResearchAgentConfig | undefined;
|
|
7191
|
+
/**
|
|
7192
|
+
* Safety settings for the interaction.
|
|
7193
|
+
*/
|
|
7194
|
+
safety_settings?: Array<SafetySetting_2> | undefined;
|
|
7195
|
+
/**
|
|
7196
|
+
* The labels with user-defined metadata for the request.
|
|
7197
|
+
*/
|
|
7198
|
+
labels?: {
|
|
7199
|
+
[k: string]: string;
|
|
7200
|
+
} | undefined;
|
|
7051
7201
|
/**
|
|
7052
7202
|
* The input for the interaction.
|
|
7053
7203
|
*/
|
|
@@ -7161,7 +7311,7 @@ declare type InteractionGetParamsStreaming = GetInteractionByIdParamsStreaming;
|
|
|
7161
7311
|
/**
|
|
7162
7312
|
* Enforces that the generated response is a JSON object that complies with the JSON schema specified in this field.
|
|
7163
7313
|
*/
|
|
7164
|
-
declare type InteractionResponseFormat = Array<
|
|
7314
|
+
declare type InteractionResponseFormat = Array<ResponseFormat_2> | ResponseFormat_2;
|
|
7165
7315
|
|
|
7166
7316
|
export declare namespace Interactions {
|
|
7167
7317
|
export type AllowedTools = AllowedTools$;
|
|
@@ -7204,6 +7354,7 @@ export declare namespace Interactions {
|
|
|
7204
7354
|
export type GoogleSearchResult = GoogleSearchResult$;
|
|
7205
7355
|
export interface GoogleSearchResultStep extends GoogleSearchResultStep$ {
|
|
7206
7356
|
}
|
|
7357
|
+
export type HarmCategory = HarmCategory$;
|
|
7207
7358
|
export type ImageConfig = ImageConfig$;
|
|
7208
7359
|
export type ImageContent = ImageContent$;
|
|
7209
7360
|
export type ImageResponseFormat = ImageResponseFormat$;
|
|
@@ -7229,6 +7380,11 @@ export declare namespace Interactions {
|
|
|
7229
7380
|
}
|
|
7230
7381
|
export interface PlaceCitation extends PlaceCitation$ {
|
|
7231
7382
|
}
|
|
7383
|
+
export type RetrievalCallArguments = RetrievalCallArguments$;
|
|
7384
|
+
export interface RetrievalCallDelta extends RetrievalCallDelta$ {
|
|
7385
|
+
}
|
|
7386
|
+
export type RetrievalResultDelta = RetrievalResultDelta$;
|
|
7387
|
+
export type SafetySetting = SafetySetting$;
|
|
7232
7388
|
export type SpeechConfig = SpeechConfig$;
|
|
7233
7389
|
export type Step = Step$;
|
|
7234
7390
|
export interface StepDelta extends StepDelta$ {
|
|
@@ -7262,12 +7418,8 @@ export declare namespace Interactions {
|
|
|
7262
7418
|
export type Arguments = Arguments$;
|
|
7263
7419
|
}
|
|
7264
7420
|
export namespace Environment {
|
|
7265
|
-
export
|
|
7266
|
-
}
|
|
7421
|
+
export type Allowlist = Allowlist$;
|
|
7267
7422
|
export type Source = Source$;
|
|
7268
|
-
export namespace Allowlist {
|
|
7269
|
-
export type Allowlist = Allowlist$2;
|
|
7270
|
-
}
|
|
7271
7423
|
}
|
|
7272
7424
|
export namespace ErrorEvent {
|
|
7273
7425
|
export type Error = Error$;
|
|
@@ -7319,6 +7471,9 @@ export declare namespace Interactions {
|
|
|
7319
7471
|
export namespace PlaceCitation {
|
|
7320
7472
|
export type ReviewSnippet = ReviewSnippet$3;
|
|
7321
7473
|
}
|
|
7474
|
+
export namespace RetrievalCallDelta {
|
|
7475
|
+
export type Arguments = Arguments$4;
|
|
7476
|
+
}
|
|
7322
7477
|
export namespace StepDelta {
|
|
7323
7478
|
export type ArgumentsDelta = ArgumentsDelta$;
|
|
7324
7479
|
export type Audio = Audio$;
|
|
@@ -7365,7 +7520,7 @@ export declare namespace Interactions {
|
|
|
7365
7520
|
}
|
|
7366
7521
|
}
|
|
7367
7522
|
export namespace URLContextCallStep {
|
|
7368
|
-
export type Arguments = Arguments$
|
|
7523
|
+
export type Arguments = Arguments$5;
|
|
7369
7524
|
}
|
|
7370
7525
|
export namespace URLContextResultStep {
|
|
7371
7526
|
export type Result = Result$3;
|
|
@@ -7383,6 +7538,7 @@ declare namespace interactions {
|
|
|
7383
7538
|
export {
|
|
7384
7539
|
AgentOption,
|
|
7385
7540
|
AllowedTools,
|
|
7541
|
+
Transform,
|
|
7386
7542
|
AllowlistEntry,
|
|
7387
7543
|
Annotation,
|
|
7388
7544
|
ArgumentsDelta,
|
|
@@ -7390,9 +7546,9 @@ declare namespace interactions {
|
|
|
7390
7546
|
AudioContent,
|
|
7391
7547
|
AudioDeltaMimeType,
|
|
7392
7548
|
AudioDelta,
|
|
7393
|
-
AudioResponseFormatMimeType,
|
|
7394
7549
|
AudioResponseFormatDelivery,
|
|
7395
|
-
|
|
7550
|
+
AudioResponseFormatMimeType,
|
|
7551
|
+
AudioResponseFormat_2 as AudioResponseFormat,
|
|
7396
7552
|
Language_2 as Language,
|
|
7397
7553
|
CodeExecutionCallArguments,
|
|
7398
7554
|
CodeExecutionCallDelta,
|
|
@@ -7400,8 +7556,8 @@ declare namespace interactions {
|
|
|
7400
7556
|
CodeExecutionResultDelta,
|
|
7401
7557
|
CodeExecutionResultStep,
|
|
7402
7558
|
CodeExecution,
|
|
7403
|
-
EnvironmentEnum,
|
|
7404
7559
|
DisabledSafetyPolicy,
|
|
7560
|
+
EnvironmentEnum,
|
|
7405
7561
|
ComputerUse_2 as ComputerUse,
|
|
7406
7562
|
Content_2 as Content,
|
|
7407
7563
|
CreateAgentInteractionResponseFormat,
|
|
@@ -7466,6 +7622,7 @@ declare namespace interactions {
|
|
|
7466
7622
|
GoogleSearch_2 as GoogleSearch,
|
|
7467
7623
|
GroundingToolCountType,
|
|
7468
7624
|
GroundingToolCount,
|
|
7625
|
+
HarmCategory_2 as HarmCategory,
|
|
7469
7626
|
HybridSearch,
|
|
7470
7627
|
ImageConfigAspectRatio,
|
|
7471
7628
|
ImageConfigImageSize,
|
|
@@ -7474,11 +7631,11 @@ declare namespace interactions {
|
|
|
7474
7631
|
ImageContent,
|
|
7475
7632
|
ImageDeltaMimeType,
|
|
7476
7633
|
ImageDelta,
|
|
7477
|
-
ImageResponseFormatMimeType,
|
|
7478
|
-
ImageResponseFormatDelivery,
|
|
7479
7634
|
ImageResponseFormatAspectRatio,
|
|
7635
|
+
ImageResponseFormatDelivery,
|
|
7480
7636
|
ImageResponseFormatImageSize,
|
|
7481
|
-
|
|
7637
|
+
ImageResponseFormatMimeType,
|
|
7638
|
+
ImageResponseFormat_2 as ImageResponseFormat,
|
|
7482
7639
|
InteractionCompletedEvent,
|
|
7483
7640
|
InteractionCreatedEvent,
|
|
7484
7641
|
InteractionSseEventInteractionStatus,
|
|
@@ -7512,11 +7669,18 @@ declare namespace interactions {
|
|
|
7512
7669
|
RagRetrievalConfig_2 as RagRetrievalConfig,
|
|
7513
7670
|
RagStoreConfig,
|
|
7514
7671
|
Ranking,
|
|
7515
|
-
ResponseFormat,
|
|
7672
|
+
ResponseFormat_2 as ResponseFormat,
|
|
7516
7673
|
ResponseModality,
|
|
7517
|
-
|
|
7674
|
+
RetrievalCallArguments,
|
|
7675
|
+
RetrievalCallDeltaRetrievalType,
|
|
7676
|
+
RetrievalCallDelta,
|
|
7677
|
+
RetrievalResultDelta,
|
|
7678
|
+
RetrievalRetrievalType,
|
|
7518
7679
|
Retrieval_2 as Retrieval,
|
|
7519
7680
|
ReviewSnippet,
|
|
7681
|
+
Method,
|
|
7682
|
+
Threshold,
|
|
7683
|
+
SafetySetting_2 as SafetySetting,
|
|
7520
7684
|
ServiceTier_2 as ServiceTier,
|
|
7521
7685
|
SourceType,
|
|
7522
7686
|
Source,
|
|
@@ -7533,7 +7697,7 @@ declare namespace interactions {
|
|
|
7533
7697
|
TextContent,
|
|
7534
7698
|
TextDelta,
|
|
7535
7699
|
TextResponseFormatMimeType,
|
|
7536
|
-
TextResponseFormat,
|
|
7700
|
+
TextResponseFormat_2 as TextResponseFormat,
|
|
7537
7701
|
ThinkingLevel_2 as ThinkingLevel,
|
|
7538
7702
|
ThinkingSummaries,
|
|
7539
7703
|
ThoughtSignatureDelta,
|
|
@@ -7548,7 +7712,6 @@ declare namespace interactions {
|
|
|
7548
7712
|
URLCitation,
|
|
7549
7713
|
URLContextCallArguments,
|
|
7550
7714
|
URLContextCallDelta,
|
|
7551
|
-
Arguments,
|
|
7552
7715
|
URLContextCallStep,
|
|
7553
7716
|
URLContextResultDelta,
|
|
7554
7717
|
URLContextResultStep,
|
|
@@ -7564,9 +7727,9 @@ declare namespace interactions {
|
|
|
7564
7727
|
VideoContent,
|
|
7565
7728
|
VideoDeltaMimeType,
|
|
7566
7729
|
VideoDelta,
|
|
7567
|
-
VideoResponseFormatDelivery,
|
|
7568
7730
|
VideoResponseFormatAspectRatio,
|
|
7569
|
-
|
|
7731
|
+
VideoResponseFormatDelivery,
|
|
7732
|
+
VideoResponseFormat_2 as VideoResponseFormat,
|
|
7570
7733
|
WebhookConfig_2 as WebhookConfig
|
|
7571
7734
|
}
|
|
7572
7735
|
}
|
|
@@ -7644,9 +7807,6 @@ declare type InteractionStatus = "in_progress" | "requires_action" | "completed"
|
|
|
7644
7807
|
declare type InteractionStatusUpdate$ = InteractionStatusUpdate;
|
|
7645
7808
|
|
|
7646
7809
|
declare type InteractionStatusUpdate = {
|
|
7647
|
-
event_type: "interaction.status_update";
|
|
7648
|
-
interaction_id: string;
|
|
7649
|
-
status: InteractionStatusUpdateStatus;
|
|
7650
7810
|
/**
|
|
7651
7811
|
* The event_id token to be used to resume the interaction stream, from
|
|
7652
7812
|
*
|
|
@@ -7654,7 +7814,10 @@ declare type InteractionStatusUpdate = {
|
|
|
7654
7814
|
* this event.
|
|
7655
7815
|
*/
|
|
7656
7816
|
event_id?: string | undefined;
|
|
7817
|
+
event_type: "interaction.status_update";
|
|
7818
|
+
interaction_id: string;
|
|
7657
7819
|
metadata?: StreamMetadata | undefined;
|
|
7820
|
+
status: InteractionStatusUpdateStatus;
|
|
7658
7821
|
};
|
|
7659
7822
|
|
|
7660
7823
|
declare type InteractionStatusUpdateStatus = "in_progress" | "requires_action" | "completed" | "failed" | "cancelled" | "incomplete" | "budget_exceeded" | (string & {});
|
|
@@ -8803,6 +8966,11 @@ export declare interface LiveServerSessionResumptionUpdate {
|
|
|
8803
8966
|
export declare interface LiveServerSetupComplete {
|
|
8804
8967
|
/** The session id of the live session. */
|
|
8805
8968
|
sessionId?: string;
|
|
8969
|
+
/** Signature of the verified consent audio. This is populated when the
|
|
8970
|
+
request has a ReplicatedVoiceConfig with consent_audio set, if the consent
|
|
8971
|
+
verification was successful. This may be used in a subsequent request
|
|
8972
|
+
instead of the consent_audio to verify the same consent. */
|
|
8973
|
+
voiceConsentSignature?: VoiceConsentSignature;
|
|
8806
8974
|
}
|
|
8807
8975
|
|
|
8808
8976
|
/** Request for the client to execute the `function_calls` and return the responses with the matching `id`s. */
|
|
@@ -8891,22 +9059,22 @@ export declare enum MaskReferenceMode {
|
|
|
8891
9059
|
MASK_MODE_SEMANTIC = "MASK_MODE_SEMANTIC"
|
|
8892
9060
|
}
|
|
8893
9061
|
|
|
8894
|
-
/** Match operation to use for
|
|
9062
|
+
/** Match operation to use for evaluating rewards. This enum is not supported in Gemini API. */
|
|
8895
9063
|
export declare enum MatchOperation {
|
|
8896
9064
|
/**
|
|
8897
|
-
* Default value.
|
|
9065
|
+
* Default value. A user error will be returned if not set.
|
|
8898
9066
|
*/
|
|
8899
9067
|
MATCH_OPERATION_UNSPECIFIED = "MATCH_OPERATION_UNSPECIFIED",
|
|
8900
9068
|
/**
|
|
8901
|
-
* Equivalent to GoogleSQL `REGEX_CONTAINS(target, expression)`.
|
|
9069
|
+
* Equivalent to [GoogleSQL](https://cloud.google.com/bigquery/docs/reference/standard-sql/string_functions#regexp_contains) `REGEX_CONTAINS(target, expression)`.
|
|
8902
9070
|
*/
|
|
8903
9071
|
REGEX_CONTAINS = "REGEX_CONTAINS",
|
|
8904
9072
|
/**
|
|
8905
|
-
* `
|
|
9073
|
+
* The match operation returns `true` if expression is a substring of the target.
|
|
8906
9074
|
*/
|
|
8907
9075
|
PARTIAL_MATCH = "PARTIAL_MATCH",
|
|
8908
9076
|
/**
|
|
8909
|
-
* `
|
|
9077
|
+
* The match operation returns `true` expression is an exact match of the target.
|
|
8910
9078
|
*/
|
|
8911
9079
|
EXACT_MATCH = "EXACT_MATCH"
|
|
8912
9080
|
}
|
|
@@ -8917,11 +9085,21 @@ declare type MCPServer$ = MCPServer;
|
|
|
8917
9085
|
* A MCPServer is a server that can be called by the model to perform actions.
|
|
8918
9086
|
*/
|
|
8919
9087
|
declare type MCPServer = {
|
|
8920
|
-
|
|
9088
|
+
/**
|
|
9089
|
+
* The allowed tools.
|
|
9090
|
+
*/
|
|
9091
|
+
allowed_tools?: Array<AllowedTools> | undefined;
|
|
9092
|
+
/**
|
|
9093
|
+
* Optional: Fields for authentication headers, timeouts, etc., if needed.
|
|
9094
|
+
*/
|
|
9095
|
+
headers?: {
|
|
9096
|
+
[k: string]: string;
|
|
9097
|
+
} | undefined;
|
|
8921
9098
|
/**
|
|
8922
9099
|
* The name of the MCPServer.
|
|
8923
9100
|
*/
|
|
8924
9101
|
name?: string | undefined;
|
|
9102
|
+
type: "mcp_server";
|
|
8925
9103
|
/**
|
|
8926
9104
|
* The full URL for the MCPServer endpoint.
|
|
8927
9105
|
*
|
|
@@ -8929,16 +9107,6 @@ declare type MCPServer = {
|
|
|
8929
9107
|
* Example: "https://api.example.com/mcp"
|
|
8930
9108
|
*/
|
|
8931
9109
|
url?: string | undefined;
|
|
8932
|
-
/**
|
|
8933
|
-
* Optional: Fields for authentication headers, timeouts, etc., if needed.
|
|
8934
|
-
*/
|
|
8935
|
-
headers?: {
|
|
8936
|
-
[k: string]: string;
|
|
8937
|
-
} | undefined;
|
|
8938
|
-
/**
|
|
8939
|
-
* The allowed tools.
|
|
8940
|
-
*/
|
|
8941
|
-
allowed_tools?: Array<AllowedTools> | undefined;
|
|
8942
9110
|
};
|
|
8943
9111
|
|
|
8944
9112
|
/** A MCPServer is a server that can be called by the model to perform actions. It is a server that implements the MCP protocol. Next ID: 6. This data type is not supported in Vertex AI. */
|
|
@@ -8959,12 +9127,12 @@ declare type MCPServerToolCall$ = MCPServerToolCallDelta;
|
|
|
8959
9127
|
* g3-prettier-ignore-file
|
|
8960
9128
|
*/
|
|
8961
9129
|
declare type MCPServerToolCallDelta = {
|
|
8962
|
-
type: "mcp_server_tool_call";
|
|
8963
|
-
name: string;
|
|
8964
|
-
server_name: string;
|
|
8965
9130
|
arguments: {
|
|
8966
9131
|
[k: string]: any;
|
|
8967
9132
|
};
|
|
9133
|
+
name: string;
|
|
9134
|
+
server_name: string;
|
|
9135
|
+
type: "mcp_server_tool_call";
|
|
8968
9136
|
};
|
|
8969
9137
|
|
|
8970
9138
|
declare type MCPServerToolCallStep$ = MCPServerToolCallStep;
|
|
@@ -8980,15 +9148,6 @@ declare type MCPServerToolCallStep$ = MCPServerToolCallStep;
|
|
|
8980
9148
|
* MCPServer tool call step.
|
|
8981
9149
|
*/
|
|
8982
9150
|
declare type MCPServerToolCallStep = {
|
|
8983
|
-
type: "mcp_server_tool_call";
|
|
8984
|
-
/**
|
|
8985
|
-
* Required. The name of the tool which was called.
|
|
8986
|
-
*/
|
|
8987
|
-
name: string;
|
|
8988
|
-
/**
|
|
8989
|
-
* Required. The name of the used MCP server.
|
|
8990
|
-
*/
|
|
8991
|
-
server_name: string;
|
|
8992
9151
|
/**
|
|
8993
9152
|
* Required. The JSON object of arguments for the function.
|
|
8994
9153
|
*/
|
|
@@ -8999,15 +9158,24 @@ declare type MCPServerToolCallStep = {
|
|
|
8999
9158
|
* Required. A unique ID for this specific tool call.
|
|
9000
9159
|
*/
|
|
9001
9160
|
id: string;
|
|
9161
|
+
/**
|
|
9162
|
+
* Required. The name of the tool which was called.
|
|
9163
|
+
*/
|
|
9164
|
+
name: string;
|
|
9165
|
+
/**
|
|
9166
|
+
* Required. The name of the used MCP server.
|
|
9167
|
+
*/
|
|
9168
|
+
server_name: string;
|
|
9169
|
+
type: "mcp_server_tool_call";
|
|
9002
9170
|
};
|
|
9003
9171
|
|
|
9004
9172
|
declare type MCPServerToolResult$ = MCPServerToolResultDelta;
|
|
9005
9173
|
|
|
9006
9174
|
declare type MCPServerToolResultDelta = {
|
|
9007
|
-
type: "mcp_server_tool_result";
|
|
9008
9175
|
name?: string | undefined;
|
|
9009
|
-
server_name?: string | undefined;
|
|
9010
9176
|
result: MCPServerToolResultDeltaResult | Array<FunctionResultSubcontent> | string;
|
|
9177
|
+
server_name?: string | undefined;
|
|
9178
|
+
type: "mcp_server_tool_result";
|
|
9011
9179
|
};
|
|
9012
9180
|
|
|
9013
9181
|
declare type MCPServerToolResultDeltaResult = {};
|
|
@@ -9020,23 +9188,23 @@ declare type MCPServerToolResultStep$ = MCPServerToolResultStep;
|
|
|
9020
9188
|
* MCPServer tool result step.
|
|
9021
9189
|
*/
|
|
9022
9190
|
declare type MCPServerToolResultStep = {
|
|
9023
|
-
type: "mcp_server_tool_result";
|
|
9024
|
-
/**
|
|
9025
|
-
* Name of the tool which is called for this specific tool call.
|
|
9026
|
-
*/
|
|
9027
|
-
name?: string | undefined;
|
|
9028
|
-
/**
|
|
9029
|
-
* The name of the used MCP server.
|
|
9030
|
-
*/
|
|
9031
|
-
server_name?: string | undefined;
|
|
9032
9191
|
/**
|
|
9033
9192
|
* Required. ID to match the ID from the function call block.
|
|
9034
9193
|
*/
|
|
9035
9194
|
call_id: string;
|
|
9195
|
+
/**
|
|
9196
|
+
* Name of the tool which is called for this specific tool call.
|
|
9197
|
+
*/
|
|
9198
|
+
name?: string | undefined;
|
|
9036
9199
|
/**
|
|
9037
9200
|
* The output from the MCP server call. Can be simple text or rich content.
|
|
9038
9201
|
*/
|
|
9039
9202
|
result: MCPServerToolResultStepResult | string | Array<FunctionResultSubcontent>;
|
|
9203
|
+
/**
|
|
9204
|
+
* The name of the used MCP server.
|
|
9205
|
+
*/
|
|
9206
|
+
server_name?: string | undefined;
|
|
9207
|
+
type: "mcp_server_tool_result";
|
|
9040
9208
|
};
|
|
9041
9209
|
|
|
9042
9210
|
declare type MCPServerToolResultStepResult = {};
|
|
@@ -9129,6 +9297,14 @@ declare type Metadata$6 = StreamMetadata;
|
|
|
9129
9297
|
|
|
9130
9298
|
declare type Metadata$7 = StreamMetadata;
|
|
9131
9299
|
|
|
9300
|
+
/**
|
|
9301
|
+
* Optional. The method for blocking content. If not specified, the default
|
|
9302
|
+
*
|
|
9303
|
+
* @remarks
|
|
9304
|
+
* behavior is to use the probability score.
|
|
9305
|
+
*/
|
|
9306
|
+
declare type Method = "severity" | "probability" | (string & {});
|
|
9307
|
+
|
|
9132
9308
|
/** Server content modalities. */
|
|
9133
9309
|
export declare enum Modality {
|
|
9134
9310
|
/**
|
|
@@ -9255,7 +9431,6 @@ declare type ModelOutputStep$ = ModelOutputStep;
|
|
|
9255
9431
|
* Output generated by the model.
|
|
9256
9432
|
*/
|
|
9257
9433
|
declare type ModelOutputStep = {
|
|
9258
|
-
type: "model_output";
|
|
9259
9434
|
content?: Array<Content_2> | undefined;
|
|
9260
9435
|
/**
|
|
9261
9436
|
* The `Status` type defines a logical error model that is suitable for
|
|
@@ -9269,6 +9444,7 @@ declare type ModelOutputStep = {
|
|
|
9269
9444
|
* [API Design Guide](https://cloud.google.com/apis/design/errors).
|
|
9270
9445
|
*/
|
|
9271
9446
|
error?: Status | undefined;
|
|
9447
|
+
type: "model_output";
|
|
9272
9448
|
};
|
|
9273
9449
|
|
|
9274
9450
|
export declare class Models extends BaseModule {
|
|
@@ -10177,19 +10353,18 @@ declare type PlaceCitation$ = PlaceCitation;
|
|
|
10177
10353
|
* A place citation annotation.
|
|
10178
10354
|
*/
|
|
10179
10355
|
declare type PlaceCitation = {
|
|
10180
|
-
type: "place_citation";
|
|
10181
10356
|
/**
|
|
10182
|
-
*
|
|
10357
|
+
* End of the attributed segment, exclusive.
|
|
10183
10358
|
*/
|
|
10184
|
-
|
|
10359
|
+
end_index?: number | undefined;
|
|
10185
10360
|
/**
|
|
10186
10361
|
* Title of the place.
|
|
10187
10362
|
*/
|
|
10188
10363
|
name?: string | undefined;
|
|
10189
10364
|
/**
|
|
10190
|
-
*
|
|
10365
|
+
* The ID of the place, in `places/{place_id}` format.
|
|
10191
10366
|
*/
|
|
10192
|
-
|
|
10367
|
+
place_id?: string | undefined;
|
|
10193
10368
|
/**
|
|
10194
10369
|
* Snippets of reviews that are used to generate answers about the
|
|
10195
10370
|
*
|
|
@@ -10205,10 +10380,11 @@ declare type PlaceCitation = {
|
|
|
10205
10380
|
* Index indicates the start of the segment, measured in bytes.
|
|
10206
10381
|
*/
|
|
10207
10382
|
start_index?: number | undefined;
|
|
10383
|
+
type: "place_citation";
|
|
10208
10384
|
/**
|
|
10209
|
-
*
|
|
10385
|
+
* URI reference of the place.
|
|
10210
10386
|
*/
|
|
10211
|
-
|
|
10387
|
+
url?: string | undefined;
|
|
10212
10388
|
};
|
|
10213
10389
|
|
|
10214
10390
|
/** Spec for pointwise metric result. This data type is not supported in Gemini API. */
|
|
@@ -10376,21 +10552,21 @@ export declare interface RagRetrievalConfig {
|
|
|
10376
10552
|
*/
|
|
10377
10553
|
declare type RagRetrievalConfig_2 = {
|
|
10378
10554
|
/**
|
|
10379
|
-
*
|
|
10555
|
+
* Config for filters.
|
|
10380
10556
|
*/
|
|
10381
|
-
|
|
10557
|
+
filter?: Filter | undefined;
|
|
10382
10558
|
/**
|
|
10383
10559
|
* Config for Hybrid Search.
|
|
10384
10560
|
*/
|
|
10385
10561
|
hybrid_search?: HybridSearch | undefined;
|
|
10386
|
-
/**
|
|
10387
|
-
* Config for filters.
|
|
10388
|
-
*/
|
|
10389
|
-
filter?: Filter | undefined;
|
|
10390
10562
|
/**
|
|
10391
10563
|
* Config for Rank Service.
|
|
10392
10564
|
*/
|
|
10393
10565
|
ranking?: Ranking | undefined;
|
|
10566
|
+
/**
|
|
10567
|
+
* Optional. The number of contexts to retrieve.
|
|
10568
|
+
*/
|
|
10569
|
+
top_k?: number | undefined;
|
|
10394
10570
|
};
|
|
10395
10571
|
|
|
10396
10572
|
/** Config for filters. This data type is not supported in Gemini API. */
|
|
@@ -10437,6 +10613,10 @@ declare type RagStoreConfig = {
|
|
|
10437
10613
|
* Optional. The representation of the rag source.
|
|
10438
10614
|
*/
|
|
10439
10615
|
rag_resources?: Array<RagResource> | undefined;
|
|
10616
|
+
/**
|
|
10617
|
+
* Specifies the context retrieval config.
|
|
10618
|
+
*/
|
|
10619
|
+
rag_retrieval_config?: RagRetrievalConfig_2 | undefined;
|
|
10440
10620
|
/**
|
|
10441
10621
|
* Optional. Number of top k results to return from the selected corpora.
|
|
10442
10622
|
*
|
|
@@ -10449,10 +10629,6 @@ declare type RagStoreConfig = {
|
|
|
10449
10629
|
* @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
10450
10630
|
*/
|
|
10451
10631
|
vector_distance_threshold?: number | undefined;
|
|
10452
|
-
/**
|
|
10453
|
-
* Specifies the context retrieval config.
|
|
10454
|
-
*/
|
|
10455
|
-
rag_retrieval_config?: RagRetrievalConfig_2 | undefined;
|
|
10456
10632
|
};
|
|
10457
10633
|
|
|
10458
10634
|
/**
|
|
@@ -10466,11 +10642,11 @@ declare type RagStoreConfig = {
|
|
|
10466
10642
|
* Config for Rank Service.
|
|
10467
10643
|
*/
|
|
10468
10644
|
declare type Ranking = {
|
|
10469
|
-
ranking_config: "rank_service";
|
|
10470
10645
|
/**
|
|
10471
10646
|
* Optional. The model name of the rank service.
|
|
10472
10647
|
*/
|
|
10473
10648
|
model_name?: string | undefined;
|
|
10649
|
+
ranking_config: "rank_service";
|
|
10474
10650
|
};
|
|
10475
10651
|
|
|
10476
10652
|
/** Raw output. This data type is not supported in Gemini API. */
|
|
@@ -10634,39 +10810,39 @@ export declare class RegisterFilesResponse {
|
|
|
10634
10810
|
export declare interface ReinforcementTuningAutoraterScorer {
|
|
10635
10811
|
/** Autorater config for evaluation. */
|
|
10636
10812
|
autoraterConfig?: AutoraterConfig;
|
|
10637
|
-
/**
|
|
10813
|
+
/** The prompt for an autorater to scorer the parsed sample response. This field supports the following placeholders that will be replaced before scoring: - {{prompt}} - {{response}} - {{system_instruction}} - {{references.key}} */
|
|
10638
10814
|
autoraterPrompt?: string;
|
|
10639
|
-
/** Parses autorater returned response. */
|
|
10815
|
+
/** Parses autorater returned response for scoring. For example, if the autorater response has reward stored in the `2.0` block, defining a parsing response config using regex `".*(.*?)"` will return a score `"2.0"`. */
|
|
10640
10816
|
autoraterResponseParseConfig?: ReinforcementTuningParseResponseConfig;
|
|
10641
|
-
/** Scores autorater responses by directly converting parsed autorater response to float reward. */
|
|
10817
|
+
/** Scores autorater responses by directly converting parsed autorater response to a float reward. Note: Reward is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. */
|
|
10642
10818
|
parsedResponseConversionScorer?: ReinforcementTuningAutoraterScorerParsedResponseConversionScorer;
|
|
10643
|
-
/** Scores autorater responses by using
|
|
10819
|
+
/** Scores autorater responses by using string match reward scorer. */
|
|
10644
10820
|
exactMatchScorer?: ReinforcementTuningAutoraterScorerExactMatchScorer;
|
|
10645
10821
|
}
|
|
10646
10822
|
|
|
10647
|
-
/** Scores autorater responses by using exact string match reward scorer. */
|
|
10823
|
+
/** Scores autorater responses by using exact string match reward scorer. This data type is not supported in Gemini API. */
|
|
10648
10824
|
export declare interface ReinforcementTuningAutoraterScorerExactMatchScorer {
|
|
10649
|
-
/** Assigns this reward score if parsed response string equals the expression. */
|
|
10825
|
+
/** Assigns this reward score if the parsed response string equals the expression. */
|
|
10650
10826
|
correctAnswerReward?: number;
|
|
10651
|
-
/** Assigns this reward score if parsed reward value does not equal the expression. */
|
|
10827
|
+
/** Assigns this reward score if the parsed reward value does not equal the expression. */
|
|
10652
10828
|
wrongAnswerReward?: number;
|
|
10653
|
-
/** The string expression to match against.
|
|
10829
|
+
/** The string expression to match against for scoring. This field supports placeholders in the format of {{references.key}} that will be replaced before matching. Regex is not supported for this expression. For example, users can define an ExactMatchScorer as follows: { "correctAnswerReward": 1.0, "wrongAnswerReward": -1.0, "expression": "{{references.concise_answer}}" } When evaluating the reward for each parsed autorater response, if the prompt references in the training/validation dataset has the following fields: ``` { "example": ..., "references": { "concise_ansser": "Yes", "verbose_answer": "The answer is Yes" } } ``` The above ExactMatchScorer will be replaced as follows for scoring: ``` { "correctAnswerReward": 1.0, "wrongAnswerReward": -1.0, "expression": "Yes" } ``` If the *parsed* autorater response is equal to the string `"Yes"`, then the reward is `1.0`, otherwise the reward is `-1.0`. */
|
|
10654
10830
|
expression?: string;
|
|
10655
10831
|
}
|
|
10656
10832
|
|
|
10657
|
-
/** Scores responses by directly converting parsed autorater response to float reward
|
|
10833
|
+
/** Scores responses by directly converting the parsed autorater response to a float reward. Note: Reward is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. This data type is not supported in Gemini API. */
|
|
10658
10834
|
export declare class ReinforcementTuningAutoraterScorerParsedResponseConversionScorer {
|
|
10659
10835
|
}
|
|
10660
10836
|
|
|
10661
|
-
/**
|
|
10837
|
+
/** ReinforcementTuningCloudRunRewardScorer allows users to implement a reward function through GCP Cloud Run. Comparing with ReinforcementTuningCodeExecutionRewardScorer that runs in a Sandbox and has no internet access, Cloud Run reward scorer is fully controlled by users. The Cloud Run service should implement the following HTTP API: HTTP method: `POST` HTTP request body: ``` { "example": ReinforcementTuningExample, "response": Content, "metadata": { "step": int "tuning_job_id": int64 } } ``` * `example` is a ReinforcementTuningExample in ProtoJSON format, (i.e., the format is the same as as one line in the training/validation dataset except that the keys must be in camel case). System instructions (i.e., `example.get("systemInstruction")`) and references (i.e., `example.get("references")`) are also included in the `example` provided that they are set in the training/validation dataset. * `response` is a Content in ProtoJSON format (i.e., keys must be in camel case), which is the same as the Online Prediction response for Gemini models. HTTP response body: { "reward": float, "user_requested_aux_info": str // Optional } where the field "user_requested_aux_info" is any (optional) string provided by users for assisting debugging. It's in snake case. This field is mostly useful when calling the GenAiTuningService.ValidateReinforcementTuningReward API, where the proto field (not Cloud Run HTTP response body) userRequestedAuxInfo will be populated if the Cloud Run reward function sets this field in the HTTP response. The following are examples for the HTTP request and response body. Example HTTP request body: ``` { "example": { "contents": [ { "role": "user", "parts": [ { "text": "What is the capital of France?" } ] } ], "references": { "answer": "Paris" } }, "response": { "parts": [ { "text": "London" } ] }, "metadata": { "step": 1, "tuning_job_id": 123456789 } } ``` Example HTTP response body: ``` { "reward": -1.0 } ``` Note: Reward output by Cloud Run reward function is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. This data type is not supported in Gemini API. */
|
|
10662
10838
|
export declare interface ReinforcementTuningCloudRunRewardScorer {
|
|
10663
|
-
/** URI of the Cloud Run service that will be used to compute the reward. The Vertex AI Secure Fine Tuning Service Agent (`service
|
|
10839
|
+
/** URI of the Cloud Run service that will be used to compute the reward. The [Vertex AI Secure Fine Tuning Service Agent](https://docs.cloud.google.com/iam/docs/service-agents#vertex-ai-secure-fine-tuning-service-agent) (`service-@gcp-sa-vertex-tune.iam.gserviceaccount.com`) must be granted the permission (e.g. by granting `roles/run.invoker` in IAM) to invoke the Cloud Run service. */
|
|
10664
10840
|
cloudRunUri?: string;
|
|
10665
10841
|
}
|
|
10666
10842
|
|
|
10667
|
-
/**
|
|
10843
|
+
/** ReinforcementTuningCodeExecutionRewardScorer allows users to implement a function to evaluate rewards for the sample response. The function signature is as follows: ``` def evaluate(example: dict[str, Any], response: dict[str, Any]) -> float: ... ``` `example` is a ReinforcementTuningExample in ProtoJSON format, (i.e., the format is the same as as one line in the training/validation dataset except that the keys must be in camel case). System instructions (i.e., `example.get("systemInstruction")`) and references (i.e., `example.get("references")`) are also included in the `example` provided that they are set in the training/validation dataset. `response` is a Content in ProtoJSON format (i.e., keys must be in camel case), which is the same as the Online Prediction response for Gemini models. Note: Reward output by the `evaluate` function is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. This data type is not supported in Gemini API. */
|
|
10668
10844
|
export declare interface ReinforcementTuningCodeExecutionRewardScorer {
|
|
10669
|
-
/**
|
|
10845
|
+
/** The python code snippet as a string for evaluating rewards. The following is an example python code snippet that returns a reward `1.0` for a parsed response matching the user-provided reference answer in per prompt references map. ``` def evaluate(example, response) -> float: response_str = response.get("parts", [])0 references = example.get("references", {}) if response_str == references.get("concise_answer"): return 1.0 return -1.0 ``` Note: Reward output by the evaluate function is clipped to be within `[-1, 1]`, i.e., `reward = max(min(reward, 1.0), -1.0)`. */
|
|
10670
10846
|
pythonCodeSnippet?: string;
|
|
10671
10847
|
}
|
|
10672
10848
|
|
|
@@ -10676,37 +10852,39 @@ export declare interface ReinforcementTuningExample {
|
|
|
10676
10852
|
contents?: Content[];
|
|
10677
10853
|
/** References for the given prompt. The key is the name of the reference, and the value is the reference itself. */
|
|
10678
10854
|
references?: Record<string, string>;
|
|
10679
|
-
/** Corresponds to
|
|
10855
|
+
/** Corresponds to system_instruction in user-facing GenerateContentRequest. */
|
|
10680
10856
|
systemInstruction?: Content;
|
|
10681
10857
|
}
|
|
10682
10858
|
|
|
10683
10859
|
/** Hyperparameters for Reinforcement Tuning. */
|
|
10684
10860
|
export declare interface ReinforcementTuningHyperParameters {
|
|
10685
|
-
/** Number of training
|
|
10861
|
+
/** Optional. Number of training epoches for the tuning job. */
|
|
10686
10862
|
epochCount?: string;
|
|
10687
10863
|
/** Learning rate multiplier for Reinforcement Learning. */
|
|
10688
10864
|
learningRateMultiplier?: number;
|
|
10689
|
-
/** Adapter size for Reinforcement Tuning. */
|
|
10865
|
+
/** Optional. Adapter size for Reinforcement Tuning. */
|
|
10690
10866
|
adapterSize?: AdapterSize;
|
|
10691
|
-
/** Number of different responses to generate per prompt during tuning. */
|
|
10867
|
+
/** Optional. Number of different responses to generate per prompt during tuning. */
|
|
10692
10868
|
samplesPerPrompt?: number;
|
|
10693
|
-
/** Batch size for the tuning job. How many prompts to process at a train step. If not set, the batch size will be determined automatically. */
|
|
10869
|
+
/** Optional. Batch size for the tuning job. How many prompts to process at a train step. If not set, the batch size will be determined automatically. */
|
|
10694
10870
|
batchSize?: number;
|
|
10695
|
-
/** How often
|
|
10871
|
+
/** Optional. How often at steps to evaluate the tuning job during training. If not set, evel will be run per epoch. `total_steps = epoch_count * samples_per_prompt / total_prompts_in_dataset` */
|
|
10696
10872
|
evaluateInterval?: number;
|
|
10697
|
-
/** How often
|
|
10873
|
+
/** Optional. How often at steps to save checkpoints during training. If not set, one checkpoint per epoch will be set. ```total_steps = epoch_count * samples_per_prompt / total_prompts_in_dataset``` */
|
|
10698
10874
|
checkpointInterval?: number;
|
|
10699
|
-
/** The maximum number of tokens to generate per prompt.
|
|
10875
|
+
/** Optional. The maximum number of tokens to generate per prompt. Default to 32768. */
|
|
10700
10876
|
maxOutputTokens?: number;
|
|
10701
|
-
/** Indicates the maximum thinking depth.
|
|
10877
|
+
/** Indicates the maximum thinking depth during tuning. Starting from Gemini 3.5 models, the old thinking_budget will no longer be supported and will result in a user error if set. Instead, users should use the thinking_level parameter to control the maximum thinking depth. */
|
|
10702
10878
|
thinkingLevel?: ReinforcementTuningThinkingLevel;
|
|
10879
|
+
/** Optional. The thinking budget for the tuning job to optimize for (Gemini 2.5 only). * -1 means dynamic thinking * 0 means no thinking * > 0 means thinking budget in tokens If not set, default to -1 (dynamic thinking). */
|
|
10880
|
+
thinkingBudget?: number;
|
|
10703
10881
|
}
|
|
10704
10882
|
|
|
10705
|
-
/** Defines how to parse sample response for reinforcement tuning. */
|
|
10883
|
+
/** Defines how to parse sample response config for reinforcement tuning. The parsed response (i.e., substring) will be passed to the reward functions. For example, the input prompt might be: > "Perform step-by-step thoughts first to problem A, finally output answer in the <ans> </ans> block." The sample response from the model under tuning might look like: > "<ans>Yes</ans>" Here, users can define the following parse config: ``` { "parseType": "REGEX_EXTRACT", "regexExtractExpression": ".*(.*?)" } ``` The resulting parsed response would be `"Yes"` and will be passed to the reward functions for evaluating rewards. This data type is not supported in Gemini API. */
|
|
10706
10884
|
export declare class ReinforcementTuningParseResponseConfig {
|
|
10707
|
-
/** Defines
|
|
10885
|
+
/** Defines the type for parsing sample response. */
|
|
10708
10886
|
parseType?: ResponseParseType;
|
|
10709
|
-
/** Defines the regex
|
|
10887
|
+
/** Defines the regex for extracting the important part of sample response. This field is only used when parse_type is ResponseParseType.REGEX_EXTRACT. */
|
|
10710
10888
|
regexExtractExpression?: string;
|
|
10711
10889
|
}
|
|
10712
10890
|
|
|
@@ -10714,16 +10892,17 @@ export declare class ReinforcementTuningParseResponseConfig {
|
|
|
10714
10892
|
export declare interface ReinforcementTuningRewardInfo {
|
|
10715
10893
|
/** Output only. The calculated reward for the reward function. */
|
|
10716
10894
|
reward?: number;
|
|
10717
|
-
/** Output only. The user-requested auxiliary info for the reward function. */
|
|
10895
|
+
/** Output only. The user-requested auxiliary info for the reward function. This field is set only if the Cloud Run reward function configured by user returns a "user_requested_aux_info". Refer to ReinforcementTuningCloudRunRewardScorer for more details. */
|
|
10718
10896
|
userRequestedAuxInfo?: string;
|
|
10719
10897
|
}
|
|
10720
10898
|
|
|
10721
10899
|
/** Reinforcement tuning spec for tuning. */
|
|
10722
10900
|
export declare interface ReinforcementTuningSpec {
|
|
10901
|
+
/** Composite reward function configuration for reinforcement tuning. */
|
|
10723
10902
|
compositeRewardConfig?: CompositeReinforcementTuningRewardConfig;
|
|
10724
|
-
/** Cloud Storage path to file containing training dataset for tuning. The dataset must be formatted as a JSONL file. */
|
|
10903
|
+
/** Cloud Storage path to the file containing training dataset for tuning. The dataset must be formatted as a JSONL file. */
|
|
10725
10904
|
trainingDatasetUri?: string;
|
|
10726
|
-
/** Cloud Storage path to file containing validation dataset for tuning. The dataset must be formatted as a JSONL file.
|
|
10905
|
+
/** Cloud Storage path to the file containing validation dataset for tuning. The dataset must be formatted as a JSONL file. */
|
|
10727
10906
|
validationDatasetUri?: string;
|
|
10728
10907
|
/** Additional hyper-parameters to use during tuning. */
|
|
10729
10908
|
hyperParameters?: ReinforcementTuningHyperParameters;
|
|
@@ -10731,11 +10910,11 @@ export declare interface ReinforcementTuningSpec {
|
|
|
10731
10910
|
singleRewardConfig?: SingleReinforcementTuningRewardConfig;
|
|
10732
10911
|
}
|
|
10733
10912
|
|
|
10734
|
-
/**
|
|
10913
|
+
/** ReinforcementTuningStringMatchRewardScorer is used to score parsed responses for string matching use cases. For example, for math problems, users can use string match scorer to check if the correct exact answer is generated. Note: Reward returned by the string match reward function is clipped to be within `[-1, 1]` if wrongAnswerReward or correctAnswerReward are beyond the range, i.e., `reward = max(min(reward, 1.0), -1.0)`. This data type is not supported in Gemini API. */
|
|
10735
10914
|
export declare interface ReinforcementTuningStringMatchRewardScorer {
|
|
10736
|
-
/** Wrong answer reward is returned if
|
|
10915
|
+
/** Wrong answer reward is returned if the parsed response is evaluated as `false`. All wrong answers get the same reward. */
|
|
10737
10916
|
wrongAnswerReward?: number;
|
|
10738
|
-
/** Correct answer
|
|
10917
|
+
/** Correct answer rewawrd is returned if the parsed response is evaluated as `true`. All correct answers get the same reward. */
|
|
10739
10918
|
correctAnswerReward?: number;
|
|
10740
10919
|
/** Uses string match expression to evaluate parsed response. */
|
|
10741
10920
|
stringMatchExpression?: ReinforcementTuningStringMatchRewardScorerStringMatchExpression;
|
|
@@ -10743,19 +10922,19 @@ export declare interface ReinforcementTuningStringMatchRewardScorer {
|
|
|
10743
10922
|
jsonMatchExpression?: ReinforcementTuningStringMatchRewardScorerJsonMatchExpression;
|
|
10744
10923
|
}
|
|
10745
10924
|
|
|
10746
|
-
/**
|
|
10925
|
+
/** JsonMatchExpression supports converting the parsed responses to JSON format, finding the value in the JSON response that matches the key_name in the first level, and performing StringMatchExpression operation on the matched JSON value. This data type is not supported in Gemini API. */
|
|
10747
10926
|
export declare interface ReinforcementTuningStringMatchRewardScorerJsonMatchExpression {
|
|
10748
|
-
/**
|
|
10927
|
+
/** The key name to find the value in the parsed response that's in JSON format. Only first-level key matching is supported. */
|
|
10749
10928
|
keyName?: string;
|
|
10750
|
-
/** String match expression to match against the value of
|
|
10929
|
+
/** String match expression to match against the extracted value from the JSON representation of the parsed response. */
|
|
10751
10930
|
valueStringMatchExpression?: ReinforcementTuningStringMatchRewardScorerStringMatchExpression;
|
|
10752
10931
|
}
|
|
10753
10932
|
|
|
10754
|
-
/** Evaluates parsed response using match type against expression. */
|
|
10933
|
+
/** Evaluates parsed response using match type against the expression. Returns `true` if `MatchOperation(target, expression)` evaluates to `true`, and `false` otherwise. This data type is not supported in Gemini API. */
|
|
10755
10934
|
export declare interface ReinforcementTuningStringMatchRewardScorerStringMatchExpression {
|
|
10756
|
-
/** Match operation to use for
|
|
10935
|
+
/** Match operation to use for evaluating rewards. */
|
|
10757
10936
|
matchOperation?: MatchOperation;
|
|
10758
|
-
/**
|
|
10937
|
+
/** A string or a regular expression to match against for evaluating rewards. Users can also provide a references map of `{key: value}` whose `value` will be used to replace the placeholder {{references.key}} in the expression. For example, if the following `references` are defined in the training / validation dataset: ``` { "systemInstruction": ..., "contents": ..., "references": { "concise_answer": "Yes", "verbose_answer": "The answer is Yes" } } ``` and if users define the following StringMatchExpression: { "matchOperation": "REGEX_CONTAINS", "expression": ".*{{references.concise_answer}}.*" } On evaluating the reward for each sample response, this StringMatchExpression will be substituted as: ``` { "matchOperation": "REGEX_CONTAINS", "expression": ".*Yes.*" } ``` */
|
|
10759
10938
|
expression?: string;
|
|
10760
10939
|
}
|
|
10761
10940
|
|
|
@@ -10775,6 +10954,12 @@ export declare enum ReinforcementTuningThinkingLevel {
|
|
|
10775
10954
|
HIGH = "HIGH"
|
|
10776
10955
|
}
|
|
10777
10956
|
|
|
10957
|
+
/** Sample reinforcement tuning user data in the training dataset. The contents are truncated for better UI showing. This data type is not supported in Gemini API. */
|
|
10958
|
+
export declare interface ReinforcementTuningUserDatasetExamples {
|
|
10959
|
+
/** List of user datasset examples showing to user. */
|
|
10960
|
+
userDatasetExamples?: ReinforcementTuningExample[];
|
|
10961
|
+
}
|
|
10962
|
+
|
|
10778
10963
|
/** Represents a recorded session. */
|
|
10779
10964
|
export declare interface ReplayFile {
|
|
10780
10965
|
replayId?: string;
|
|
@@ -10814,6 +10999,17 @@ export declare interface ReplicatedVoiceConfig {
|
|
|
10814
10999
|
|
|
10815
11000
|
* @remarks Encoded as base64 string. */
|
|
10816
11001
|
voiceSampleAudio?: string;
|
|
11002
|
+
/** Recorded consent verifying ownership of the voice. This
|
|
11003
|
+
represents 16-bit signed little-endian wav data, with a 24kHz sampling
|
|
11004
|
+
rate.
|
|
11005
|
+
* @remarks Encoded as base64 string. */
|
|
11006
|
+
consentAudio?: string;
|
|
11007
|
+
/** Signature of a previously verified consent audio. This should be
|
|
11008
|
+
populated with a signature generated by the server for a previous
|
|
11009
|
+
request containing the consent_audio field. When provided, the
|
|
11010
|
+
signature is verified instead of the consent_audio field to reduce
|
|
11011
|
+
latency. Requests will fail if the signature is invalid or expired. */
|
|
11012
|
+
voiceConsentSignature?: VoiceConsentSignature;
|
|
10817
11013
|
}
|
|
10818
11014
|
|
|
10819
11015
|
declare type RequestOptions = {
|
|
@@ -10870,7 +11066,19 @@ export declare enum ResourceScope {
|
|
|
10870
11066
|
COLLECTION = "COLLECTION"
|
|
10871
11067
|
}
|
|
10872
11068
|
|
|
10873
|
-
|
|
11069
|
+
/** Configuration for the model to configure output formatting and delivery. This data type is not supported in Gemini API. */
|
|
11070
|
+
export declare class ResponseFormat {
|
|
11071
|
+
/** Audio output format. */
|
|
11072
|
+
audio?: AudioResponseFormat;
|
|
11073
|
+
/** Image output format. */
|
|
11074
|
+
image?: ImageResponseFormat;
|
|
11075
|
+
/** Text output format. */
|
|
11076
|
+
text?: TextResponseFormat;
|
|
11077
|
+
/** Video output format. */
|
|
11078
|
+
video?: VideoResponseFormat;
|
|
11079
|
+
}
|
|
11080
|
+
|
|
11081
|
+
declare type ResponseFormat_2 = AudioResponseFormat_2 | TextResponseFormat_2 | ImageResponseFormat_2 | VideoResponseFormat_2 | {
|
|
10874
11082
|
[k: string]: any;
|
|
10875
11083
|
};
|
|
10876
11084
|
|
|
@@ -10883,18 +11091,18 @@ declare type ResponseFormat = AudioResponseFormat | TextResponseFormat | ImageRe
|
|
|
10883
11091
|
*/
|
|
10884
11092
|
declare type ResponseModality = "text" | "image" | "audio" | "video" | "document" | (string & {});
|
|
10885
11093
|
|
|
10886
|
-
/** Defines
|
|
11094
|
+
/** Defines the type for parsing sample response. This enum is not supported in Gemini API. */
|
|
10887
11095
|
export declare enum ResponseParseType {
|
|
10888
11096
|
/**
|
|
10889
|
-
* Default value.
|
|
11097
|
+
* Default value. Fallback to IDENTITY
|
|
10890
11098
|
*/
|
|
10891
11099
|
RESPONSE_PARSE_TYPE_UNSPECIFIED = "RESPONSE_PARSE_TYPE_UNSPECIFIED",
|
|
10892
11100
|
/**
|
|
10893
|
-
*
|
|
11101
|
+
* Returns the sample response as is.
|
|
10894
11102
|
*/
|
|
10895
11103
|
IDENTITY = "IDENTITY",
|
|
10896
11104
|
/**
|
|
10897
|
-
*
|
|
11105
|
+
* Uses regex to extract the important part of sample response. Similar to [GoogleSQL](https://cloud.google.com/bigquery/docs/reference/standard-sql/string_functions#regexp_extract) `REGEX_EXTRACT(response, regex_extract_expression)`, but different in that if there are multiple matches, the last match will be returned.
|
|
10898
11106
|
*/
|
|
10899
11107
|
REGEX_EXTRACT = "REGEX_EXTRACT"
|
|
10900
11108
|
}
|
|
@@ -10923,29 +11131,77 @@ export declare interface Retrieval {
|
|
|
10923
11131
|
* A tool that can be used by the model to retrieve files.
|
|
10924
11132
|
*/
|
|
10925
11133
|
declare type Retrieval_2 = {
|
|
10926
|
-
|
|
11134
|
+
/**
|
|
11135
|
+
* Used to specify configuration for ExaAISearch.
|
|
11136
|
+
*/
|
|
11137
|
+
exa_ai_search_config?: ExaAISearchConfig | undefined;
|
|
11138
|
+
/**
|
|
11139
|
+
* Used to specify configuration for ParallelAISearch.
|
|
11140
|
+
*/
|
|
11141
|
+
parallel_ai_search_config?: ParallelAISearchConfig | undefined;
|
|
11142
|
+
/**
|
|
11143
|
+
* Use to specify configuration for RAG Store.
|
|
11144
|
+
*/
|
|
11145
|
+
rag_store_config?: RagStoreConfig | undefined;
|
|
10927
11146
|
/**
|
|
10928
11147
|
* The types of file retrieval to enable.
|
|
10929
11148
|
*/
|
|
10930
|
-
retrieval_types?: Array<
|
|
11149
|
+
retrieval_types?: Array<RetrievalRetrievalType> | undefined;
|
|
11150
|
+
type: "retrieval";
|
|
10931
11151
|
/**
|
|
10932
11152
|
* Used to specify configuration for VertexAISearch.
|
|
10933
11153
|
*/
|
|
10934
11154
|
vertex_ai_search_config?: VertexAISearchConfig | undefined;
|
|
11155
|
+
};
|
|
11156
|
+
|
|
11157
|
+
declare type RetrievalCallArguments$ = RetrievalCallArguments;
|
|
11158
|
+
|
|
11159
|
+
/**
|
|
11160
|
+
* @license
|
|
11161
|
+
* Copyright 2026 Google LLC
|
|
11162
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
11163
|
+
*
|
|
11164
|
+
* g3-prettier-ignore-file
|
|
11165
|
+
*/
|
|
11166
|
+
/**
|
|
11167
|
+
* The arguments to pass to Retrieval tools.
|
|
11168
|
+
*/
|
|
11169
|
+
declare type RetrievalCallArguments = {
|
|
10935
11170
|
/**
|
|
10936
|
-
*
|
|
11171
|
+
* Queries for Retrieval information.
|
|
10937
11172
|
*/
|
|
10938
|
-
|
|
11173
|
+
queries?: Array<string> | undefined;
|
|
11174
|
+
};
|
|
11175
|
+
|
|
11176
|
+
declare type RetrievalCallDelta$ = RetrievalCallDelta;
|
|
11177
|
+
|
|
11178
|
+
/**
|
|
11179
|
+
* Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search,
|
|
11180
|
+
*
|
|
11181
|
+
* @remarks
|
|
11182
|
+
* etc. RetrievalType decides which tool is used.
|
|
11183
|
+
*/
|
|
11184
|
+
declare type RetrievalCallDelta = {
|
|
10939
11185
|
/**
|
|
10940
|
-
*
|
|
11186
|
+
* The arguments to pass to Retrieval tools.
|
|
10941
11187
|
*/
|
|
10942
|
-
|
|
11188
|
+
arguments: RetrievalCallArguments;
|
|
10943
11189
|
/**
|
|
10944
|
-
*
|
|
11190
|
+
* The type of retrieval tools.
|
|
10945
11191
|
*/
|
|
10946
|
-
|
|
11192
|
+
retrieval_type?: RetrievalCallDeltaRetrievalType | undefined;
|
|
11193
|
+
/**
|
|
11194
|
+
* A signature hash for backend validation.
|
|
11195
|
+
*/
|
|
11196
|
+
signature?: string | undefined;
|
|
11197
|
+
type: "retrieval_call";
|
|
10947
11198
|
};
|
|
10948
11199
|
|
|
11200
|
+
/**
|
|
11201
|
+
* The type of retrieval tools.
|
|
11202
|
+
*/
|
|
11203
|
+
declare type RetrievalCallDeltaRetrievalType = "vertex_ai_search" | "rag_store" | "exa_ai_search" | "parallel_ai_search" | (string & {});
|
|
11204
|
+
|
|
10949
11205
|
/** Retrieval config. */
|
|
10950
11206
|
export declare interface RetrievalConfig {
|
|
10951
11207
|
/** The location of the user. */
|
|
@@ -10965,7 +11221,35 @@ export declare interface RetrievalMetadata {
|
|
|
10965
11221
|
googleSearchDynamicRetrievalScore?: number;
|
|
10966
11222
|
}
|
|
10967
11223
|
|
|
10968
|
-
declare type
|
|
11224
|
+
declare type RetrievalResultDelta$ = RetrievalResultDelta;
|
|
11225
|
+
|
|
11226
|
+
/**
|
|
11227
|
+
* @license
|
|
11228
|
+
* Copyright 2026 Google LLC
|
|
11229
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
11230
|
+
*
|
|
11231
|
+
* g3-prettier-ignore-file
|
|
11232
|
+
*/
|
|
11233
|
+
/**
|
|
11234
|
+
* Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search,
|
|
11235
|
+
*
|
|
11236
|
+
* @remarks
|
|
11237
|
+
* etc.
|
|
11238
|
+
* ToolResultDelta.type
|
|
11239
|
+
*/
|
|
11240
|
+
declare type RetrievalResultDelta = {
|
|
11241
|
+
/**
|
|
11242
|
+
* Whether the retrieval resulted in an error.
|
|
11243
|
+
*/
|
|
11244
|
+
is_error?: boolean | undefined;
|
|
11245
|
+
/**
|
|
11246
|
+
* A signature hash for backend validation.
|
|
11247
|
+
*/
|
|
11248
|
+
signature?: string | undefined;
|
|
11249
|
+
type: "retrieval_result";
|
|
11250
|
+
};
|
|
11251
|
+
|
|
11252
|
+
declare type RetrievalRetrievalType = "vertex_ai_search" | "rag_store" | "exa_ai_search" | "parallel_ai_search" | (string & {});
|
|
10969
11253
|
|
|
10970
11254
|
declare type RetryConfig = {
|
|
10971
11255
|
strategy: "none";
|
|
@@ -11000,6 +11284,10 @@ declare type ReviewSnippet$3 = ReviewSnippet;
|
|
|
11000
11284
|
* the features of a specific place in Google Maps.
|
|
11001
11285
|
*/
|
|
11002
11286
|
declare type ReviewSnippet = {
|
|
11287
|
+
/**
|
|
11288
|
+
* The ID of the review snippet.
|
|
11289
|
+
*/
|
|
11290
|
+
review_id?: string | undefined;
|
|
11003
11291
|
/**
|
|
11004
11292
|
* Title of the review.
|
|
11005
11293
|
*/
|
|
@@ -11008,10 +11296,6 @@ declare type ReviewSnippet = {
|
|
|
11008
11296
|
* A link that corresponds to the user review on Google Maps.
|
|
11009
11297
|
*/
|
|
11010
11298
|
url?: string | undefined;
|
|
11011
|
-
/**
|
|
11012
|
-
* The ID of the review snippet.
|
|
11013
|
-
*/
|
|
11014
|
-
review_id?: string | undefined;
|
|
11015
11299
|
};
|
|
11016
11300
|
|
|
11017
11301
|
/**
|
|
@@ -11116,6 +11400,8 @@ export declare interface SafetyRating {
|
|
|
11116
11400
|
severityScore?: number;
|
|
11117
11401
|
}
|
|
11118
11402
|
|
|
11403
|
+
declare type SafetySetting$ = SafetySetting_2;
|
|
11404
|
+
|
|
11119
11405
|
/** A safety setting that affects the safety-blocking behavior. A SafetySetting consists of a harm category and a threshold for that category. */
|
|
11120
11406
|
export declare interface SafetySetting {
|
|
11121
11407
|
/** Required. The harm category to be blocked. */
|
|
@@ -11126,10 +11412,38 @@ export declare interface SafetySetting {
|
|
|
11126
11412
|
threshold?: HarmBlockThreshold;
|
|
11127
11413
|
}
|
|
11128
11414
|
|
|
11129
|
-
/**
|
|
11130
|
-
|
|
11131
|
-
|
|
11132
|
-
|
|
11415
|
+
/**
|
|
11416
|
+
* A safety setting that affects the safety-blocking behavior.
|
|
11417
|
+
*
|
|
11418
|
+
* @remarks
|
|
11419
|
+
*
|
|
11420
|
+
* A SafetySetting consists of a
|
|
11421
|
+
* harm category and a
|
|
11422
|
+
* threshold for that
|
|
11423
|
+
* category.
|
|
11424
|
+
*/
|
|
11425
|
+
declare type SafetySetting_2 = {
|
|
11426
|
+
/**
|
|
11427
|
+
* Optional. The method for blocking content. If not specified, the default
|
|
11428
|
+
*
|
|
11429
|
+
* @remarks
|
|
11430
|
+
* behavior is to use the probability score.
|
|
11431
|
+
*/
|
|
11432
|
+
method?: Method | undefined;
|
|
11433
|
+
/**
|
|
11434
|
+
* Required. The threshold for blocking content. If the harm probability
|
|
11435
|
+
*
|
|
11436
|
+
* @remarks
|
|
11437
|
+
* exceeds this threshold, the content will be blocked.
|
|
11438
|
+
*/
|
|
11439
|
+
threshold: Threshold;
|
|
11440
|
+
type: HarmCategory_2;
|
|
11441
|
+
};
|
|
11442
|
+
|
|
11443
|
+
/** Scale of the generated music. */
|
|
11444
|
+
export declare enum Scale {
|
|
11445
|
+
/**
|
|
11446
|
+
* Default value. This value is unused.
|
|
11133
11447
|
*/
|
|
11134
11448
|
SCALE_UNSPECIFIED = "SCALE_UNSPECIFIED",
|
|
11135
11449
|
/**
|
|
@@ -11406,6 +11720,7 @@ declare type ServiceTier_2 = "flex" | "standard" | "priority" | (string & {});
|
|
|
11406
11720
|
export declare class Session {
|
|
11407
11721
|
readonly conn: WebSocket_2;
|
|
11408
11722
|
private readonly apiClient;
|
|
11723
|
+
setupComplete?: types.LiveServerSetupComplete;
|
|
11409
11724
|
constructor(conn: WebSocket_2, apiClient: ApiClient);
|
|
11410
11725
|
private tLiveClientContent;
|
|
11411
11726
|
private tLiveClienttToolResponse;
|
|
@@ -11571,14 +11886,14 @@ declare type SigningSecret$ = SigningSecret;
|
|
|
11571
11886
|
* Represents a signing secret used to verify webhook payloads.
|
|
11572
11887
|
*/
|
|
11573
11888
|
declare type SigningSecret = {
|
|
11574
|
-
/**
|
|
11575
|
-
* Output only. The truncated version of the signing secret.
|
|
11576
|
-
*/
|
|
11577
|
-
truncated_secret?: string | undefined;
|
|
11578
11889
|
/**
|
|
11579
11890
|
* Output only. The expiration date of the signing secret.
|
|
11580
11891
|
*/
|
|
11581
11892
|
expire_time?: string | undefined;
|
|
11893
|
+
/**
|
|
11894
|
+
* Output only. The truncated version of the signing secret.
|
|
11895
|
+
*/
|
|
11896
|
+
truncated_secret?: string | undefined;
|
|
11582
11897
|
};
|
|
11583
11898
|
|
|
11584
11899
|
/** Config for `response` parameter. */
|
|
@@ -11595,15 +11910,15 @@ export declare class SingleEmbedContentResponse {
|
|
|
11595
11910
|
export declare interface SingleReinforcementTuningRewardConfig {
|
|
11596
11911
|
/** Scores parsed responses for autorater use cases by using a model to compute the reward. */
|
|
11597
11912
|
autoraterScorer?: ReinforcementTuningAutoraterScorer;
|
|
11598
|
-
/** A unique reward name
|
|
11913
|
+
/** A unique reward name for identifying each single reinforcement tuning reward. */
|
|
11599
11914
|
rewardName?: string;
|
|
11600
|
-
/** Defines how to parse sample response. */
|
|
11915
|
+
/** Defines how to parse sample response. For example, given a sample response for evaluating the reward, users might want to extract the text only between `` and `` in the sample response, and keeps only the last one in case there are multiple such tags. To achieve such a purpose, they can define a regex `".*(.*?)"` using the ReinforcementTuningParseResponseConfig.ResponseParseType.REGEX_EXTRACT parse type. */
|
|
11601
11916
|
parseResponseConfig?: ReinforcementTuningParseResponseConfig;
|
|
11602
|
-
/**
|
|
11917
|
+
/** ReinforcementTuningCodeExecutionRewardScorer is used to score parsed responses for code execution use cases. */
|
|
11603
11918
|
codeExecutionRewardScorer?: ReinforcementTuningCodeExecutionRewardScorer;
|
|
11604
|
-
/**
|
|
11919
|
+
/** ReinforcementTuningStringMatchRewardScorer is used to score parsed responses for simple string matching use cases against reference answers. */
|
|
11605
11920
|
stringMatchRewardScorer?: ReinforcementTuningStringMatchRewardScorer;
|
|
11606
|
-
/**
|
|
11921
|
+
/** ReinforcementTuningCloudRunRewardScorer is used to score parsed responses by calling a Cloud Run service. */
|
|
11607
11922
|
cloudRunRewardScorer?: ReinforcementTuningCloudRunRewardScorer;
|
|
11608
11923
|
}
|
|
11609
11924
|
|
|
@@ -11624,7 +11939,14 @@ declare type Source$ = Source;
|
|
|
11624
11939
|
* A source to be mounted into the environment.
|
|
11625
11940
|
*/
|
|
11626
11941
|
declare type Source = {
|
|
11627
|
-
|
|
11942
|
+
/**
|
|
11943
|
+
* The inline content if `type` is `INLINE`.
|
|
11944
|
+
*/
|
|
11945
|
+
content?: string | undefined;
|
|
11946
|
+
/**
|
|
11947
|
+
* Optional encoding for inline content (e.g. `base64`).
|
|
11948
|
+
*/
|
|
11949
|
+
encoding?: string | undefined;
|
|
11628
11950
|
/**
|
|
11629
11951
|
* The source of the environment.
|
|
11630
11952
|
*
|
|
@@ -11637,14 +11959,7 @@ declare type Source = {
|
|
|
11637
11959
|
* Where the source should appear in the environment.
|
|
11638
11960
|
*/
|
|
11639
11961
|
target?: string | undefined;
|
|
11640
|
-
|
|
11641
|
-
* The inline content if `type` is `INLINE`.
|
|
11642
|
-
*/
|
|
11643
|
-
content?: string | undefined;
|
|
11644
|
-
/**
|
|
11645
|
-
* Optional encoding for inline content (e.g. `base64`).
|
|
11646
|
-
*/
|
|
11647
|
-
encoding?: string | undefined;
|
|
11962
|
+
type?: SourceType | undefined;
|
|
11648
11963
|
};
|
|
11649
11964
|
|
|
11650
11965
|
/**
|
|
@@ -11687,10 +12002,6 @@ export declare interface SpeechConfig {
|
|
|
11687
12002
|
* The configuration for speech interaction.
|
|
11688
12003
|
*/
|
|
11689
12004
|
declare type SpeechConfig_2 = {
|
|
11690
|
-
/**
|
|
11691
|
-
* The voice of the speaker.
|
|
11692
|
-
*/
|
|
11693
|
-
voice?: string | undefined;
|
|
11694
12005
|
/**
|
|
11695
12006
|
* The language of the speech.
|
|
11696
12007
|
*/
|
|
@@ -11699,6 +12010,10 @@ declare type SpeechConfig_2 = {
|
|
|
11699
12010
|
* The speaker's name, it should match the speaker name given in the prompt.
|
|
11700
12011
|
*/
|
|
11701
12012
|
speaker?: string | undefined;
|
|
12013
|
+
/**
|
|
12014
|
+
* The voice of the speaker.
|
|
12015
|
+
*/
|
|
12016
|
+
voice?: string | undefined;
|
|
11702
12017
|
};
|
|
11703
12018
|
|
|
11704
12019
|
export declare type SpeechConfigUnion = SpeechConfig | string;
|
|
@@ -11749,14 +12064,6 @@ declare type Status = {
|
|
|
11749
12064
|
* The status code, which should be an enum value of google.rpc.Code.
|
|
11750
12065
|
*/
|
|
11751
12066
|
code?: number | undefined;
|
|
11752
|
-
/**
|
|
11753
|
-
* A developer-facing error message, which should be in English. Any
|
|
11754
|
-
*
|
|
11755
|
-
* @remarks
|
|
11756
|
-
* user-facing error message should be localized and sent in the
|
|
11757
|
-
* google.rpc.Status.details field, or localized by the client.
|
|
11758
|
-
*/
|
|
11759
|
-
message?: string | undefined;
|
|
11760
12067
|
/**
|
|
11761
12068
|
* A list of messages that carry the error details. There is a common set of
|
|
11762
12069
|
*
|
|
@@ -11766,6 +12073,14 @@ declare type Status = {
|
|
|
11766
12073
|
details?: Array<{
|
|
11767
12074
|
[k: string]: any;
|
|
11768
12075
|
}> | undefined;
|
|
12076
|
+
/**
|
|
12077
|
+
* A developer-facing error message, which should be in English. Any
|
|
12078
|
+
*
|
|
12079
|
+
* @remarks
|
|
12080
|
+
* user-facing error message should be localized and sent in the
|
|
12081
|
+
* google.rpc.Status.details field, or localized by the client.
|
|
12082
|
+
*/
|
|
12083
|
+
message?: string | undefined;
|
|
11769
12084
|
};
|
|
11770
12085
|
|
|
11771
12086
|
declare type Step$ = Step;
|
|
@@ -11778,8 +12093,6 @@ declare type Step = UserInputStep | ModelOutputStep | ThoughtStep | FunctionCall
|
|
|
11778
12093
|
declare type StepDelta$ = StepDelta;
|
|
11779
12094
|
|
|
11780
12095
|
declare type StepDelta = {
|
|
11781
|
-
event_type: "step.delta";
|
|
11782
|
-
index: number;
|
|
11783
12096
|
delta: StepDeltaData;
|
|
11784
12097
|
/**
|
|
11785
12098
|
* The event_id token to be used to resume the interaction stream, from
|
|
@@ -11788,13 +12101,15 @@ declare type StepDelta = {
|
|
|
11788
12101
|
* this event.
|
|
11789
12102
|
*/
|
|
11790
12103
|
event_id?: string | undefined;
|
|
12104
|
+
event_type: "step.delta";
|
|
12105
|
+
index: number;
|
|
11791
12106
|
/**
|
|
11792
12107
|
* Optional metadata accompanying ANY streamed event.
|
|
11793
12108
|
*/
|
|
11794
12109
|
metadata?: StepDeltaMetadata | undefined;
|
|
11795
12110
|
};
|
|
11796
12111
|
|
|
11797
|
-
declare type StepDeltaData = TextDelta | ImageDelta | AudioDelta | DocumentDelta | VideoDelta | ThoughtSummaryDelta | ThoughtSignatureDelta | TextAnnotationDelta | ArgumentsDelta | CodeExecutionCallDelta | URLContextCallDelta | GoogleSearchCallDelta | MCPServerToolCallDelta | FileSearchCallDelta | GoogleMapsCallDelta | CodeExecutionResultDelta | URLContextResultDelta | GoogleSearchResultDelta | MCPServerToolResultDelta | FileSearchResultDelta | GoogleMapsResultDelta | FunctionResultDelta;
|
|
12112
|
+
declare type StepDeltaData = TextDelta | ImageDelta | AudioDelta | DocumentDelta | VideoDelta | ThoughtSummaryDelta | ThoughtSignatureDelta | TextAnnotationDelta | ArgumentsDelta | CodeExecutionCallDelta | URLContextCallDelta | GoogleSearchCallDelta | MCPServerToolCallDelta | FileSearchCallDelta | GoogleMapsCallDelta | RetrievalCallDelta | CodeExecutionResultDelta | URLContextResultDelta | GoogleSearchResultDelta | MCPServerToolResultDelta | FileSearchResultDelta | GoogleMapsResultDelta | RetrievalResultDelta | FunctionResultDelta;
|
|
11798
12113
|
|
|
11799
12114
|
/**
|
|
11800
12115
|
* Optional metadata accompanying ANY streamed event.
|
|
@@ -11809,12 +12124,6 @@ declare type StepDeltaMetadata = {
|
|
|
11809
12124
|
declare type StepStart$ = StepStart;
|
|
11810
12125
|
|
|
11811
12126
|
declare type StepStart = {
|
|
11812
|
-
event_type: "step.start";
|
|
11813
|
-
index: number;
|
|
11814
|
-
/**
|
|
11815
|
-
* A step in the interaction.
|
|
11816
|
-
*/
|
|
11817
|
-
step: Step;
|
|
11818
12127
|
/**
|
|
11819
12128
|
* The event_id token to be used to resume the interaction stream, from
|
|
11820
12129
|
*
|
|
@@ -11822,22 +12131,18 @@ declare type StepStart = {
|
|
|
11822
12131
|
* this event.
|
|
11823
12132
|
*/
|
|
11824
12133
|
event_id?: string | undefined;
|
|
12134
|
+
event_type: "step.start";
|
|
12135
|
+
index: number;
|
|
11825
12136
|
metadata?: StreamMetadata | undefined;
|
|
12137
|
+
/**
|
|
12138
|
+
* A step in the interaction.
|
|
12139
|
+
*/
|
|
12140
|
+
step: Step;
|
|
11826
12141
|
};
|
|
11827
12142
|
|
|
11828
12143
|
declare type StepStop$ = StepStop;
|
|
11829
12144
|
|
|
11830
12145
|
declare type StepStop = {
|
|
11831
|
-
event_type: "step.stop";
|
|
11832
|
-
index: number;
|
|
11833
|
-
/**
|
|
11834
|
-
* Statistics on the interaction request's token usage.
|
|
11835
|
-
*/
|
|
11836
|
-
usage?: Usage | undefined;
|
|
11837
|
-
/**
|
|
11838
|
-
* Statistics on the interaction request's token usage.
|
|
11839
|
-
*/
|
|
11840
|
-
step_usage?: Usage | undefined;
|
|
11841
12146
|
/**
|
|
11842
12147
|
* The event_id token to be used to resume the interaction stream, from
|
|
11843
12148
|
*
|
|
@@ -11845,7 +12150,17 @@ declare type StepStop = {
|
|
|
11845
12150
|
* this event.
|
|
11846
12151
|
*/
|
|
11847
12152
|
event_id?: string | undefined;
|
|
12153
|
+
event_type: "step.stop";
|
|
12154
|
+
index: number;
|
|
11848
12155
|
metadata?: StreamMetadata | undefined;
|
|
12156
|
+
/**
|
|
12157
|
+
* Statistics on the interaction request's token usage.
|
|
12158
|
+
*/
|
|
12159
|
+
step_usage?: Usage | undefined;
|
|
12160
|
+
/**
|
|
12161
|
+
* Statistics on the interaction request's token usage.
|
|
12162
|
+
*/
|
|
12163
|
+
usage?: Usage | undefined;
|
|
11849
12164
|
};
|
|
11850
12165
|
|
|
11851
12166
|
export declare class Stream<T> extends ReadableStream<T> {
|
|
@@ -12097,11 +12412,11 @@ declare type Text$ = TextDelta;
|
|
|
12097
12412
|
declare type TextAnnotationDelta$ = TextAnnotationDelta;
|
|
12098
12413
|
|
|
12099
12414
|
declare type TextAnnotationDelta = {
|
|
12100
|
-
type: "text_annotation_delta";
|
|
12101
12415
|
/**
|
|
12102
12416
|
* Citation information for model-generated content.
|
|
12103
12417
|
*/
|
|
12104
12418
|
annotations?: Array<Annotation> | undefined;
|
|
12419
|
+
type: "text_annotation_delta";
|
|
12105
12420
|
};
|
|
12106
12421
|
|
|
12107
12422
|
declare type TextContent$ = TextContent;
|
|
@@ -12110,15 +12425,15 @@ declare type TextContent$ = TextContent;
|
|
|
12110
12425
|
* A text content block.
|
|
12111
12426
|
*/
|
|
12112
12427
|
declare type TextContent = {
|
|
12113
|
-
type: "text";
|
|
12114
|
-
/**
|
|
12115
|
-
* Required. The text content.
|
|
12116
|
-
*/
|
|
12117
|
-
text: string;
|
|
12118
12428
|
/**
|
|
12119
12429
|
* Citation information for model-generated content.
|
|
12120
12430
|
*/
|
|
12121
12431
|
annotations?: Array<Annotation> | undefined;
|
|
12432
|
+
/**
|
|
12433
|
+
* Required. The text content.
|
|
12434
|
+
*/
|
|
12435
|
+
text: string;
|
|
12436
|
+
type: "text";
|
|
12122
12437
|
};
|
|
12123
12438
|
|
|
12124
12439
|
/**
|
|
@@ -12129,17 +12444,24 @@ declare type TextContent = {
|
|
|
12129
12444
|
* g3-prettier-ignore-file
|
|
12130
12445
|
*/
|
|
12131
12446
|
declare type TextDelta = {
|
|
12132
|
-
type: "text";
|
|
12133
12447
|
text: string;
|
|
12448
|
+
type: "text";
|
|
12134
12449
|
};
|
|
12135
12450
|
|
|
12136
|
-
declare type TextResponseFormat$ =
|
|
12451
|
+
declare type TextResponseFormat$ = TextResponseFormat_2;
|
|
12452
|
+
|
|
12453
|
+
/** Configuration for text-specific output formatting. */
|
|
12454
|
+
export declare class TextResponseFormat {
|
|
12455
|
+
/** Optional. The IANA standard MIME type of the response. */
|
|
12456
|
+
mimeType?: string;
|
|
12457
|
+
/** Optional. The JSON schema that the output should conform to. Only applicable when mime_type is APPLICATION_JSON. */
|
|
12458
|
+
schema?: unknown;
|
|
12459
|
+
}
|
|
12137
12460
|
|
|
12138
12461
|
/**
|
|
12139
12462
|
* Configuration for text output format.
|
|
12140
12463
|
*/
|
|
12141
|
-
declare type
|
|
12142
|
-
type: "text";
|
|
12464
|
+
declare type TextResponseFormat_2 = {
|
|
12143
12465
|
/**
|
|
12144
12466
|
* The MIME type of the text output.
|
|
12145
12467
|
*/
|
|
@@ -12153,6 +12475,7 @@ declare type TextResponseFormat = {
|
|
|
12153
12475
|
schema?: {
|
|
12154
12476
|
[k: string]: any;
|
|
12155
12477
|
} | undefined;
|
|
12478
|
+
type: "text";
|
|
12156
12479
|
};
|
|
12157
12480
|
|
|
12158
12481
|
/**
|
|
@@ -12233,11 +12556,11 @@ declare type ThoughtSignature$ = ThoughtSignatureDelta;
|
|
|
12233
12556
|
* g3-prettier-ignore-file
|
|
12234
12557
|
*/
|
|
12235
12558
|
declare type ThoughtSignatureDelta = {
|
|
12236
|
-
type: "thought_signature";
|
|
12237
12559
|
/**
|
|
12238
12560
|
* Signature to match the backend source to be part of the generation.
|
|
12239
12561
|
*/
|
|
12240
12562
|
signature?: string | undefined;
|
|
12563
|
+
type: "thought_signature";
|
|
12241
12564
|
};
|
|
12242
12565
|
|
|
12243
12566
|
declare type ThoughtStep$ = ThoughtStep;
|
|
@@ -12246,7 +12569,6 @@ declare type ThoughtStep$ = ThoughtStep;
|
|
|
12246
12569
|
* A thought step.
|
|
12247
12570
|
*/
|
|
12248
12571
|
declare type ThoughtStep = {
|
|
12249
|
-
type: "thought";
|
|
12250
12572
|
/**
|
|
12251
12573
|
* A signature hash for backend validation.
|
|
12252
12574
|
*/
|
|
@@ -12255,6 +12577,7 @@ declare type ThoughtStep = {
|
|
|
12255
12577
|
* A summary of the thought.
|
|
12256
12578
|
*/
|
|
12257
12579
|
summary?: Array<ThoughtSummaryContent> | undefined;
|
|
12580
|
+
type: "thought";
|
|
12258
12581
|
};
|
|
12259
12582
|
|
|
12260
12583
|
declare type ThoughtSummary$ = ThoughtSummaryDelta;
|
|
@@ -12262,13 +12585,21 @@ declare type ThoughtSummary$ = ThoughtSummaryDelta;
|
|
|
12262
12585
|
declare type ThoughtSummaryContent = TextContent | ImageContent;
|
|
12263
12586
|
|
|
12264
12587
|
declare type ThoughtSummaryDelta = {
|
|
12265
|
-
type: "thought_summary";
|
|
12266
12588
|
/**
|
|
12267
12589
|
* The content of the response.
|
|
12268
12590
|
*/
|
|
12269
12591
|
content?: Content_2 | undefined;
|
|
12592
|
+
type: "thought_summary";
|
|
12270
12593
|
};
|
|
12271
12594
|
|
|
12595
|
+
/**
|
|
12596
|
+
* Required. The threshold for blocking content. If the harm probability
|
|
12597
|
+
*
|
|
12598
|
+
* @remarks
|
|
12599
|
+
* exceeds this threshold, the content will be blocked.
|
|
12600
|
+
*/
|
|
12601
|
+
declare type Threshold = "block_low_and_above" | "block_medium_and_above" | "block_only_high" | "block_none" | "off" | (string & {});
|
|
12602
|
+
|
|
12272
12603
|
export declare class Tokens extends BaseModule {
|
|
12273
12604
|
private readonly apiClient;
|
|
12274
12605
|
constructor(apiClient: ApiClient);
|
|
@@ -12398,6 +12729,8 @@ export declare interface Tool {
|
|
|
12398
12729
|
urlContext?: UrlContext;
|
|
12399
12730
|
/** Optional. MCP Servers to connect to. This field is not supported in Vertex AI. */
|
|
12400
12731
|
mcpServers?: McpServer[];
|
|
12732
|
+
/** Optional. Uses Exa.ai to search for information to answer user queries. The search results will be grounded on Exa.ai and presented to the model for response generation. This field is not supported in Gemini API. */
|
|
12733
|
+
exaAiSearch?: ToolExaAiSearch;
|
|
12401
12734
|
}
|
|
12402
12735
|
|
|
12403
12736
|
/**
|
|
@@ -12462,6 +12795,14 @@ export declare interface ToolConfig {
|
|
|
12462
12795
|
includeServerSideToolInvocations?: boolean;
|
|
12463
12796
|
}
|
|
12464
12797
|
|
|
12798
|
+
/** ExaAiSearch tool type. A tool that uses the Exa.ai search engine for grounding. This data type is not supported in Gemini API. */
|
|
12799
|
+
export declare interface ToolExaAiSearch {
|
|
12800
|
+
/** Required. The API key for ExaAiSearch. */
|
|
12801
|
+
apiKey?: string;
|
|
12802
|
+
/** Optional. This field can be used to pass any parameter from the Exa.ai Search API. */
|
|
12803
|
+
customConfigs?: Record<string, unknown>;
|
|
12804
|
+
}
|
|
12805
|
+
|
|
12465
12806
|
export declare type ToolListUnion = ToolUnion[];
|
|
12466
12807
|
|
|
12467
12808
|
/** ParallelAiSearch tool type. A tool that uses the Parallel.ai search engine for grounding. This data type is not supported in Gemini API. */
|
|
@@ -12553,14 +12894,27 @@ export declare interface Transcription {
|
|
|
12553
12894
|
languageCode?: string;
|
|
12554
12895
|
}
|
|
12555
12896
|
|
|
12897
|
+
/**
|
|
12898
|
+
* @license
|
|
12899
|
+
* Copyright 2026 Google LLC
|
|
12900
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
12901
|
+
*
|
|
12902
|
+
* g3-prettier-ignore-file
|
|
12903
|
+
*/
|
|
12904
|
+
/**
|
|
12905
|
+
* Headers to inject on all outbound requests matching this domain. Accepts a single dict or a list of dicts. The egress proxy injects these automatically.
|
|
12906
|
+
*/
|
|
12907
|
+
declare type Transform = {
|
|
12908
|
+
[k: string]: string;
|
|
12909
|
+
} | Array<{
|
|
12910
|
+
[k: string]: string;
|
|
12911
|
+
}>;
|
|
12912
|
+
|
|
12556
12913
|
/** Config for stream translation. */
|
|
12557
12914
|
export declare interface TranslationConfig {
|
|
12558
|
-
/** If true, the model will generate audio when the target language is
|
|
12559
|
-
spoken, essentially it will parrot the input. If false, we will not produce
|
|
12560
|
-
audio for the target language. */
|
|
12915
|
+
/** Optional. If true, the model will generate audio when the target language is spoken, essentially it will parrot the input. If false, we will not produce audio for the target language. */
|
|
12561
12916
|
echoTargetLanguage?: boolean;
|
|
12562
|
-
/** The target language for translation. Supported values are BCP-47
|
|
12563
|
-
language codes (e.g. "en", "es", "fr"). */
|
|
12917
|
+
/** Required. The target language for translation. Supported values are BCP-47 language codes (e.g. "en", "es", "fr"). */
|
|
12564
12918
|
targetLanguageCode?: string;
|
|
12565
12919
|
}
|
|
12566
12920
|
|
|
@@ -12628,6 +12982,8 @@ export declare interface TuningDataStats {
|
|
|
12628
12982
|
preferenceOptimizationDataStats?: PreferenceOptimizationDataStats;
|
|
12629
12983
|
/** The SFT Tuning data stats. */
|
|
12630
12984
|
supervisedTuningDataStats?: SupervisedTuningDataStats;
|
|
12985
|
+
/** Output only. Statistics for reinforcement tuning. */
|
|
12986
|
+
reinforcementTuningDataStats?: DatasetStats;
|
|
12631
12987
|
}
|
|
12632
12988
|
|
|
12633
12989
|
/** A single example for tuning. This data type is not supported in Vertex AI. */
|
|
@@ -12670,6 +13026,7 @@ export declare interface TuningJob {
|
|
|
12670
13026
|
preferenceOptimizationSpec?: PreferenceOptimizationSpec;
|
|
12671
13027
|
/** Tuning Spec for Distillation. */
|
|
12672
13028
|
distillationSpec?: DistillationSpec;
|
|
13029
|
+
/** Tuning Spec for Reinforcement Tuning. */
|
|
12673
13030
|
reinforcementTuningSpec?: ReinforcementTuningSpec;
|
|
12674
13031
|
/** Output only. The tuning data statistics associated with this TuningJob. */
|
|
12675
13032
|
tuningDataStats?: TuningDataStats;
|
|
@@ -12896,6 +13253,7 @@ export declare interface TuningValidationDataset {
|
|
|
12896
13253
|
* @deprecated class: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
12897
13254
|
*/
|
|
12898
13255
|
declare type Turn = {
|
|
13256
|
+
content?: Array<Content_2> | string | undefined;
|
|
12899
13257
|
/**
|
|
12900
13258
|
* The originator of this turn. Must be user for input or model for
|
|
12901
13259
|
*
|
|
@@ -12903,7 +13261,6 @@ declare type Turn = {
|
|
|
12903
13261
|
* model output.
|
|
12904
13262
|
*/
|
|
12905
13263
|
role?: string | undefined;
|
|
12906
|
-
content?: Array<Content_2> | string | undefined;
|
|
12907
13264
|
};
|
|
12908
13265
|
|
|
12909
13266
|
/** The reason why the turn is complete. */
|
|
@@ -13122,8 +13479,14 @@ declare namespace types {
|
|
|
13122
13479
|
ModelStage,
|
|
13123
13480
|
MediaResolution,
|
|
13124
13481
|
Modality,
|
|
13482
|
+
Delivery,
|
|
13483
|
+
AspectRatio,
|
|
13484
|
+
ImageSize,
|
|
13125
13485
|
TuningMode,
|
|
13126
13486
|
AdapterSize,
|
|
13487
|
+
ResponseParseType,
|
|
13488
|
+
MatchOperation,
|
|
13489
|
+
ReinforcementTuningThinkingLevel,
|
|
13127
13490
|
JobState,
|
|
13128
13491
|
TuningJobState,
|
|
13129
13492
|
AggregationMetric,
|
|
@@ -13149,9 +13512,6 @@ declare namespace types {
|
|
|
13149
13512
|
VideoGenerationMaskMode,
|
|
13150
13513
|
VideoCompressionQuality,
|
|
13151
13514
|
ImageResizeMode,
|
|
13152
|
-
ResponseParseType,
|
|
13153
|
-
MatchOperation,
|
|
13154
|
-
ReinforcementTuningThinkingLevel,
|
|
13155
13515
|
TuningMethod,
|
|
13156
13516
|
FileState,
|
|
13157
13517
|
FileSource,
|
|
@@ -13224,7 +13584,9 @@ declare namespace types {
|
|
|
13224
13584
|
UrlContext,
|
|
13225
13585
|
StreamableHttpTransport,
|
|
13226
13586
|
McpServer,
|
|
13587
|
+
ToolExaAiSearch,
|
|
13227
13588
|
Tool,
|
|
13589
|
+
VoiceConsentSignature,
|
|
13228
13590
|
ReplicatedVoiceConfig,
|
|
13229
13591
|
PrebuiltVoiceConfig,
|
|
13230
13592
|
VoiceConfig,
|
|
@@ -13329,6 +13691,12 @@ declare namespace types {
|
|
|
13329
13691
|
DeleteModelConfig,
|
|
13330
13692
|
DeleteModelParameters,
|
|
13331
13693
|
DeleteModelResponse,
|
|
13694
|
+
AudioResponseFormat,
|
|
13695
|
+
ImageResponseFormat,
|
|
13696
|
+
TextResponseFormat,
|
|
13697
|
+
VideoResponseFormat,
|
|
13698
|
+
ResponseFormat,
|
|
13699
|
+
TranslationConfig,
|
|
13332
13700
|
GenerationConfig,
|
|
13333
13701
|
CountTokensConfig,
|
|
13334
13702
|
CountTokensParameters,
|
|
@@ -13378,6 +13746,8 @@ declare namespace types {
|
|
|
13378
13746
|
PreTunedModel,
|
|
13379
13747
|
DatasetDistributionDistributionBucket,
|
|
13380
13748
|
DatasetDistribution,
|
|
13749
|
+
ReinforcementTuningExample,
|
|
13750
|
+
ReinforcementTuningUserDatasetExamples,
|
|
13381
13751
|
DatasetStats,
|
|
13382
13752
|
DistillationDataStats,
|
|
13383
13753
|
GeminiPreferenceExampleCompletion,
|
|
@@ -13423,7 +13793,6 @@ declare namespace types {
|
|
|
13423
13793
|
CreateTuningJobConfig,
|
|
13424
13794
|
CreateTuningJobParametersPrivate,
|
|
13425
13795
|
TuningOperation,
|
|
13426
|
-
ReinforcementTuningExample,
|
|
13427
13796
|
ValidateRewardConfig,
|
|
13428
13797
|
ValidateRewardParameters,
|
|
13429
13798
|
ReinforcementTuningRewardInfo,
|
|
@@ -13567,7 +13936,6 @@ declare namespace types {
|
|
|
13567
13936
|
LiveClientRealtimeInput,
|
|
13568
13937
|
LiveClientToolResponse,
|
|
13569
13938
|
LiveClientMessage,
|
|
13570
|
-
TranslationConfig,
|
|
13571
13939
|
LiveConnectConfig,
|
|
13572
13940
|
LiveConnectParameters,
|
|
13573
13941
|
CreateChatParameters,
|
|
@@ -13879,15 +14247,10 @@ declare type URLCitation$ = URLCitation;
|
|
|
13879
14247
|
* A URL citation annotation.
|
|
13880
14248
|
*/
|
|
13881
14249
|
declare type URLCitation = {
|
|
13882
|
-
type: "url_citation";
|
|
13883
|
-
/**
|
|
13884
|
-
* The URL.
|
|
13885
|
-
*/
|
|
13886
|
-
url?: string | undefined;
|
|
13887
14250
|
/**
|
|
13888
|
-
*
|
|
14251
|
+
* End of the attributed segment, exclusive.
|
|
13889
14252
|
*/
|
|
13890
|
-
|
|
14253
|
+
end_index?: number | undefined;
|
|
13891
14254
|
/**
|
|
13892
14255
|
* Start of segment of the response that is attributed to this source.
|
|
13893
14256
|
*
|
|
@@ -13897,9 +14260,14 @@ declare type URLCitation = {
|
|
|
13897
14260
|
*/
|
|
13898
14261
|
start_index?: number | undefined;
|
|
13899
14262
|
/**
|
|
13900
|
-
*
|
|
14263
|
+
* The title of the URL.
|
|
13901
14264
|
*/
|
|
13902
|
-
|
|
14265
|
+
title?: string | undefined;
|
|
14266
|
+
type: "url_citation";
|
|
14267
|
+
/**
|
|
14268
|
+
* The URL.
|
|
14269
|
+
*/
|
|
14270
|
+
url?: string | undefined;
|
|
13903
14271
|
};
|
|
13904
14272
|
|
|
13905
14273
|
declare type URLContext$ = URLContext;
|
|
@@ -13944,7 +14312,6 @@ declare type URLContextCallArguments = {
|
|
|
13944
14312
|
};
|
|
13945
14313
|
|
|
13946
14314
|
declare type URLContextCallDelta = {
|
|
13947
|
-
type: "url_context_call";
|
|
13948
14315
|
/**
|
|
13949
14316
|
* The arguments to pass to the URL context.
|
|
13950
14317
|
*/
|
|
@@ -13953,6 +14320,7 @@ declare type URLContextCallDelta = {
|
|
|
13953
14320
|
* A signature hash for backend validation.
|
|
13954
14321
|
*/
|
|
13955
14322
|
signature?: string | undefined;
|
|
14323
|
+
type: "url_context_call";
|
|
13956
14324
|
};
|
|
13957
14325
|
|
|
13958
14326
|
declare type URLContextCallStep$ = URLContextCallStep;
|
|
@@ -13961,7 +14329,10 @@ declare type URLContextCallStep$ = URLContextCallStep;
|
|
|
13961
14329
|
* URL context call step.
|
|
13962
14330
|
*/
|
|
13963
14331
|
declare type URLContextCallStep = {
|
|
13964
|
-
|
|
14332
|
+
/**
|
|
14333
|
+
* The arguments to pass to the URL context.
|
|
14334
|
+
*/
|
|
14335
|
+
arguments: URLContextCallArguments;
|
|
13965
14336
|
/**
|
|
13966
14337
|
* Required. A unique ID for this specific tool call.
|
|
13967
14338
|
*/
|
|
@@ -13970,10 +14341,7 @@ declare type URLContextCallStep = {
|
|
|
13970
14341
|
* A signature hash for backend validation.
|
|
13971
14342
|
*/
|
|
13972
14343
|
signature?: string | undefined;
|
|
13973
|
-
|
|
13974
|
-
* The arguments to pass to the URL context.
|
|
13975
|
-
*/
|
|
13976
|
-
arguments: Arguments;
|
|
14344
|
+
type: "url_context_call";
|
|
13977
14345
|
};
|
|
13978
14346
|
|
|
13979
14347
|
/** Metadata returned when the model uses the `url_context` tool to get information from a user-provided URL. */
|
|
@@ -13990,24 +14358,24 @@ declare type URLContextResult$2 = URLContextResultDelta;
|
|
|
13990
14358
|
* The result of the URL context.
|
|
13991
14359
|
*/
|
|
13992
14360
|
declare type URLContextResult = {
|
|
13993
|
-
/**
|
|
13994
|
-
* The URL that was fetched.
|
|
13995
|
-
*/
|
|
13996
|
-
url?: string | undefined;
|
|
13997
14361
|
/**
|
|
13998
14362
|
* The status of the URL retrieval.
|
|
13999
14363
|
*/
|
|
14000
14364
|
status?: URLContextResultStatus | undefined;
|
|
14365
|
+
/**
|
|
14366
|
+
* The URL that was fetched.
|
|
14367
|
+
*/
|
|
14368
|
+
url?: string | undefined;
|
|
14001
14369
|
};
|
|
14002
14370
|
|
|
14003
14371
|
declare type URLContextResultDelta = {
|
|
14004
|
-
type: "url_context_result";
|
|
14005
|
-
result: Array<URLContextResult>;
|
|
14006
14372
|
is_error?: boolean | undefined;
|
|
14373
|
+
result: Array<URLContextResult>;
|
|
14007
14374
|
/**
|
|
14008
14375
|
* A signature hash for backend validation.
|
|
14009
14376
|
*/
|
|
14010
14377
|
signature?: string | undefined;
|
|
14378
|
+
type: "url_context_result";
|
|
14011
14379
|
};
|
|
14012
14380
|
|
|
14013
14381
|
/**
|
|
@@ -14028,23 +14396,23 @@ declare type URLContextResultStep$ = URLContextResultStep;
|
|
|
14028
14396
|
* URL context result step.
|
|
14029
14397
|
*/
|
|
14030
14398
|
declare type URLContextResultStep = {
|
|
14031
|
-
type: "url_context_result";
|
|
14032
14399
|
/**
|
|
14033
|
-
* Required.
|
|
14400
|
+
* Required. ID to match the ID from the function call block.
|
|
14034
14401
|
*/
|
|
14035
|
-
|
|
14402
|
+
call_id: string;
|
|
14036
14403
|
/**
|
|
14037
14404
|
* Whether the URL context resulted in an error.
|
|
14038
14405
|
*/
|
|
14039
14406
|
is_error?: boolean | undefined;
|
|
14040
14407
|
/**
|
|
14041
|
-
* Required.
|
|
14408
|
+
* Required. The results of the URL context.
|
|
14042
14409
|
*/
|
|
14043
|
-
|
|
14410
|
+
result: Array<URLContextResult>;
|
|
14044
14411
|
/**
|
|
14045
14412
|
* A signature hash for backend validation.
|
|
14046
14413
|
*/
|
|
14047
14414
|
signature?: string | undefined;
|
|
14415
|
+
type: "url_context_result";
|
|
14048
14416
|
};
|
|
14049
14417
|
|
|
14050
14418
|
/** The metadata for a single URL retrieval. */
|
|
@@ -14086,37 +14454,37 @@ declare type Usage$ = Usage;
|
|
|
14086
14454
|
*/
|
|
14087
14455
|
declare type Usage = {
|
|
14088
14456
|
/**
|
|
14089
|
-
*
|
|
14457
|
+
* A breakdown of cached token usage by modality.
|
|
14090
14458
|
*/
|
|
14091
|
-
|
|
14459
|
+
cached_tokens_by_modality?: Array<ModalityTokens> | undefined;
|
|
14092
14460
|
/**
|
|
14093
|
-
*
|
|
14461
|
+
* Grounding tool count.
|
|
14094
14462
|
*/
|
|
14095
|
-
|
|
14463
|
+
grounding_tool_count?: Array<GroundingToolCount> | undefined;
|
|
14096
14464
|
/**
|
|
14097
|
-
*
|
|
14465
|
+
* A breakdown of input token usage by modality.
|
|
14098
14466
|
*/
|
|
14099
|
-
|
|
14467
|
+
input_tokens_by_modality?: Array<ModalityTokens> | undefined;
|
|
14100
14468
|
/**
|
|
14101
|
-
* A breakdown of
|
|
14469
|
+
* A breakdown of output token usage by modality.
|
|
14102
14470
|
*/
|
|
14103
|
-
|
|
14471
|
+
output_tokens_by_modality?: Array<ModalityTokens> | undefined;
|
|
14104
14472
|
/**
|
|
14105
|
-
*
|
|
14473
|
+
* A breakdown of tool-use token usage by modality.
|
|
14106
14474
|
*/
|
|
14107
|
-
|
|
14475
|
+
tool_use_tokens_by_modality?: Array<ModalityTokens> | undefined;
|
|
14108
14476
|
/**
|
|
14109
|
-
*
|
|
14477
|
+
* Number of tokens in the cached part of the prompt (the cached content).
|
|
14110
14478
|
*/
|
|
14111
|
-
|
|
14479
|
+
total_cached_tokens?: number | undefined;
|
|
14112
14480
|
/**
|
|
14113
|
-
* Number of tokens
|
|
14481
|
+
* Number of tokens in the prompt (context).
|
|
14114
14482
|
*/
|
|
14115
|
-
|
|
14483
|
+
total_input_tokens?: number | undefined;
|
|
14116
14484
|
/**
|
|
14117
|
-
*
|
|
14485
|
+
* Total number of tokens across all the generated responses.
|
|
14118
14486
|
*/
|
|
14119
|
-
|
|
14487
|
+
total_output_tokens?: number | undefined;
|
|
14120
14488
|
/**
|
|
14121
14489
|
* Number of tokens of thoughts for thinking models.
|
|
14122
14490
|
*/
|
|
@@ -14129,9 +14497,9 @@ declare type Usage = {
|
|
|
14129
14497
|
*/
|
|
14130
14498
|
total_tokens?: number | undefined;
|
|
14131
14499
|
/**
|
|
14132
|
-
*
|
|
14500
|
+
* Number of tokens present in tool-use prompt(s).
|
|
14133
14501
|
*/
|
|
14134
|
-
|
|
14502
|
+
total_tool_use_tokens?: number | undefined;
|
|
14135
14503
|
};
|
|
14136
14504
|
|
|
14137
14505
|
/** Usage metadata about response(s). */
|
|
@@ -14300,14 +14668,14 @@ declare type VertexAISearchConfig$ = VertexAISearchConfig;
|
|
|
14300
14668
|
* Used to specify configuration for VertexAISearch.
|
|
14301
14669
|
*/
|
|
14302
14670
|
declare type VertexAISearchConfig = {
|
|
14303
|
-
/**
|
|
14304
|
-
* Optional. Used to specify Vertex AI Search engine.
|
|
14305
|
-
*/
|
|
14306
|
-
engine?: string | undefined;
|
|
14307
14671
|
/**
|
|
14308
14672
|
* Optional. Used to specify Vertex AI Search datastores.
|
|
14309
14673
|
*/
|
|
14310
14674
|
datastores?: Array<string> | undefined;
|
|
14675
|
+
/**
|
|
14676
|
+
* Optional. Used to specify Vertex AI Search engine.
|
|
14677
|
+
*/
|
|
14678
|
+
engine?: string | undefined;
|
|
14311
14679
|
};
|
|
14312
14680
|
|
|
14313
14681
|
/** Define data stores within engine to filter on in a search call and configurations for those data stores. For more information, see https://cloud.google.com/generative-ai-app-builder/docs/reference/rpc/google.cloud.discoveryengine.v1#datastorespec. This data type is not supported in Gemini API. */
|
|
@@ -14401,20 +14769,20 @@ declare type VideoContent$ = VideoContent;
|
|
|
14401
14769
|
* A video content block.
|
|
14402
14770
|
*/
|
|
14403
14771
|
declare type VideoContent = {
|
|
14404
|
-
type: "video";
|
|
14405
14772
|
/**
|
|
14406
14773
|
* The video content.
|
|
14407
14774
|
*/
|
|
14408
14775
|
data?: string | undefined;
|
|
14409
|
-
/**
|
|
14410
|
-
* The URI of the video.
|
|
14411
|
-
*/
|
|
14412
|
-
uri?: string | undefined;
|
|
14413
14776
|
/**
|
|
14414
14777
|
* The mime type of the video.
|
|
14415
14778
|
*/
|
|
14416
14779
|
mime_type?: VideoContentMimeType | undefined;
|
|
14417
14780
|
resolution?: MediaResolution_2 | undefined;
|
|
14781
|
+
type: "video";
|
|
14782
|
+
/**
|
|
14783
|
+
* The URI of the video.
|
|
14784
|
+
*/
|
|
14785
|
+
uri?: string | undefined;
|
|
14418
14786
|
};
|
|
14419
14787
|
|
|
14420
14788
|
/**
|
|
@@ -14423,11 +14791,11 @@ declare type VideoContent = {
|
|
|
14423
14791
|
declare type VideoContentMimeType = "video/mp4" | "video/mpeg" | "video/mpg" | "video/mov" | "video/avi" | "video/x-flv" | "video/webm" | "video/wmv" | "video/3gpp" | (string & {});
|
|
14424
14792
|
|
|
14425
14793
|
declare type VideoDelta = {
|
|
14426
|
-
type: "video";
|
|
14427
14794
|
data?: string | undefined;
|
|
14428
|
-
uri?: string | undefined;
|
|
14429
14795
|
mime_type?: VideoDeltaMimeType | undefined;
|
|
14430
14796
|
resolution?: MediaResolution_2 | undefined;
|
|
14797
|
+
type: "video";
|
|
14798
|
+
uri?: string | undefined;
|
|
14431
14799
|
};
|
|
14432
14800
|
|
|
14433
14801
|
declare type VideoDeltaMimeType = "video/mp4" | "video/mpeg" | "video/mpg" | "video/mov" | "video/avi" | "video/x-flv" | "video/webm" | "video/wmv" | "video/3gpp" | (string & {});
|
|
@@ -14519,17 +14887,36 @@ export declare enum VideoOrientation {
|
|
|
14519
14887
|
PORTRAIT = "PORTRAIT"
|
|
14520
14888
|
}
|
|
14521
14889
|
|
|
14522
|
-
declare type VideoResponseFormat$ =
|
|
14890
|
+
declare type VideoResponseFormat$ = VideoResponseFormat_2;
|
|
14891
|
+
|
|
14892
|
+
/** Configuration for video-specific output formatting. This data type is not supported in Gemini API. */
|
|
14893
|
+
export declare class VideoResponseFormat {
|
|
14894
|
+
/** The aspect ratio for the video output. */
|
|
14895
|
+
aspectRatio?: AspectRatio;
|
|
14896
|
+
/** Optional. Delivery mode for the generated content. */
|
|
14897
|
+
delivery?: Delivery;
|
|
14898
|
+
/** Optional. The duration for the video output. */
|
|
14899
|
+
duration?: string;
|
|
14900
|
+
/** Optional. The Google Cloud Storage URI to store the video output. Required for Vertex if delivery is URI. */
|
|
14901
|
+
gcsUri?: string;
|
|
14902
|
+
}
|
|
14523
14903
|
|
|
14524
14904
|
/**
|
|
14525
14905
|
* Configuration for video output format.
|
|
14526
14906
|
*/
|
|
14527
|
-
declare type
|
|
14528
|
-
|
|
14907
|
+
declare type VideoResponseFormat_2 = {
|
|
14908
|
+
/**
|
|
14909
|
+
* The aspect ratio for the video output.
|
|
14910
|
+
*/
|
|
14911
|
+
aspect_ratio?: VideoResponseFormatAspectRatio | undefined;
|
|
14529
14912
|
/**
|
|
14530
14913
|
* The delivery mode for the video output.
|
|
14531
14914
|
*/
|
|
14532
14915
|
delivery?: VideoResponseFormatDelivery | undefined;
|
|
14916
|
+
/**
|
|
14917
|
+
* The duration for the video output.
|
|
14918
|
+
*/
|
|
14919
|
+
duration?: string | undefined;
|
|
14533
14920
|
/**
|
|
14534
14921
|
* The GCS URI to store the video output. Required for Vertex if delivery mode
|
|
14535
14922
|
*
|
|
@@ -14537,21 +14924,9 @@ declare type VideoResponseFormat = {
|
|
|
14537
14924
|
* is URI.
|
|
14538
14925
|
*/
|
|
14539
14926
|
gcs_uri?: string | undefined;
|
|
14540
|
-
|
|
14541
|
-
* The aspect ratio for the video output.
|
|
14542
|
-
*/
|
|
14543
|
-
aspect_ratio?: VideoResponseFormatAspectRatio | undefined;
|
|
14544
|
-
/**
|
|
14545
|
-
* The duration for the video output.
|
|
14546
|
-
*/
|
|
14547
|
-
duration?: string | undefined;
|
|
14927
|
+
type: "video";
|
|
14548
14928
|
};
|
|
14549
14929
|
|
|
14550
|
-
/**
|
|
14551
|
-
* The aspect ratio for the video output.
|
|
14552
|
-
*/
|
|
14553
|
-
declare type VideoResponseFormatAspectRatio = "16:9" | "9:16" | (string & {});
|
|
14554
|
-
|
|
14555
14930
|
/**
|
|
14556
14931
|
* @license
|
|
14557
14932
|
* Copyright 2026 Google LLC
|
|
@@ -14559,6 +14934,11 @@ declare type VideoResponseFormatAspectRatio = "16:9" | "9:16" | (string & {});
|
|
|
14559
14934
|
*
|
|
14560
14935
|
* g3-prettier-ignore-file
|
|
14561
14936
|
*/
|
|
14937
|
+
/**
|
|
14938
|
+
* The aspect ratio for the video output.
|
|
14939
|
+
*/
|
|
14940
|
+
declare type VideoResponseFormatAspectRatio = "16:9" | "9:16" | (string & {});
|
|
14941
|
+
|
|
14562
14942
|
/**
|
|
14563
14943
|
* The delivery mode for the video output.
|
|
14564
14944
|
*/
|
|
@@ -14608,20 +14988,43 @@ export declare interface VoiceConfig {
|
|
|
14608
14988
|
prebuiltVoiceConfig?: PrebuiltVoiceConfig;
|
|
14609
14989
|
}
|
|
14610
14990
|
|
|
14991
|
+
/** The signature of the voice consent check. */
|
|
14992
|
+
export declare interface VoiceConsentSignature {
|
|
14993
|
+
/** The signature string.
|
|
14994
|
+
*/
|
|
14995
|
+
signature?: string;
|
|
14996
|
+
}
|
|
14997
|
+
|
|
14611
14998
|
declare type Webhook$ = Webhook;
|
|
14612
14999
|
|
|
14613
15000
|
/**
|
|
14614
15001
|
* A Webhook resource.
|
|
14615
15002
|
*/
|
|
14616
15003
|
declare type Webhook = {
|
|
15004
|
+
/**
|
|
15005
|
+
* Output only. The timestamp when the webhook was created.
|
|
15006
|
+
*/
|
|
15007
|
+
create_time?: string | undefined;
|
|
15008
|
+
/**
|
|
15009
|
+
* Output only. The ID of the webhook.
|
|
15010
|
+
*/
|
|
15011
|
+
id?: string | undefined;
|
|
14617
15012
|
/**
|
|
14618
15013
|
* Optional. The user-provided name of the webhook.
|
|
14619
15014
|
*/
|
|
14620
15015
|
name?: string | undefined;
|
|
14621
15016
|
/**
|
|
14622
|
-
*
|
|
15017
|
+
* Output only. The new signing secret for the webhook. Only populated on create.
|
|
14623
15018
|
*/
|
|
14624
|
-
|
|
15019
|
+
new_signing_secret?: string | undefined;
|
|
15020
|
+
/**
|
|
15021
|
+
* Output only. The signing secrets associated with this webhook.
|
|
15022
|
+
*/
|
|
15023
|
+
signing_secrets?: Array<SigningSecret> | undefined;
|
|
15024
|
+
/**
|
|
15025
|
+
* Output only. The state of the webhook.
|
|
15026
|
+
*/
|
|
15027
|
+
state?: WebhookState | undefined;
|
|
14625
15028
|
/**
|
|
14626
15029
|
* Required. The events that the webhook is subscribed to.
|
|
14627
15030
|
*
|
|
@@ -14636,30 +15039,14 @@ declare type Webhook = {
|
|
|
14636
15039
|
* - video.generated
|
|
14637
15040
|
*/
|
|
14638
15041
|
subscribed_events: Array<WebhookSubscribedEvent>;
|
|
14639
|
-
/**
|
|
14640
|
-
* Output only. The timestamp when the webhook was created.
|
|
14641
|
-
*/
|
|
14642
|
-
create_time?: string | undefined;
|
|
14643
15042
|
/**
|
|
14644
15043
|
* Output only. The timestamp when the webhook was last updated.
|
|
14645
15044
|
*/
|
|
14646
15045
|
update_time?: string | undefined;
|
|
14647
15046
|
/**
|
|
14648
|
-
*
|
|
14649
|
-
*/
|
|
14650
|
-
signing_secrets?: Array<SigningSecret> | undefined;
|
|
14651
|
-
/**
|
|
14652
|
-
* Output only. The state of the webhook.
|
|
14653
|
-
*/
|
|
14654
|
-
state?: WebhookState | undefined;
|
|
14655
|
-
/**
|
|
14656
|
-
* Output only. The new signing secret for the webhook. Only populated on create.
|
|
14657
|
-
*/
|
|
14658
|
-
new_signing_secret?: string | undefined;
|
|
14659
|
-
/**
|
|
14660
|
-
* Output only. The ID of the webhook.
|
|
15047
|
+
* Required. The URI to which webhook events will be sent.
|
|
14661
15048
|
*/
|
|
14662
|
-
|
|
15049
|
+
uri: string;
|
|
14663
15050
|
};
|
|
14664
15051
|
|
|
14665
15052
|
declare type WebhookConfig$ = WebhookConfig_2;
|
|
@@ -14725,10 +15112,6 @@ declare type WebhookInput = {
|
|
|
14725
15112
|
* Optional. The user-provided name of the webhook.
|
|
14726
15113
|
*/
|
|
14727
15114
|
name?: string | undefined;
|
|
14728
|
-
/**
|
|
14729
|
-
* Required. The URI to which webhook events will be sent.
|
|
14730
|
-
*/
|
|
14731
|
-
uri: string;
|
|
14732
15115
|
/**
|
|
14733
15116
|
* Required. The events that the webhook is subscribed to.
|
|
14734
15117
|
*
|
|
@@ -14743,6 +15126,10 @@ declare type WebhookInput = {
|
|
|
14743
15126
|
* - video.generated
|
|
14744
15127
|
*/
|
|
14745
15128
|
subscribed_events: Array<WebhookSubscribedEvent>;
|
|
15129
|
+
/**
|
|
15130
|
+
* Required. The URI to which webhook events will be sent.
|
|
15131
|
+
*/
|
|
15132
|
+
uri: string;
|
|
14746
15133
|
};
|
|
14747
15134
|
|
|
14748
15135
|
declare type WebhookListParams$ = ListWebhooksParams;
|
|
@@ -14759,10 +15146,6 @@ declare type WebhookListResponse$ = WebhookListResponse;
|
|
|
14759
15146
|
* Response message for WebhookService.ListWebhooks.
|
|
14760
15147
|
*/
|
|
14761
15148
|
declare type WebhookListResponse = {
|
|
14762
|
-
/**
|
|
14763
|
-
* The webhooks.
|
|
14764
|
-
*/
|
|
14765
|
-
webhooks?: Array<Webhook> | undefined;
|
|
14766
15149
|
/**
|
|
14767
15150
|
* A token, which can be sent as `page_token` to retrieve the next page.
|
|
14768
15151
|
*
|
|
@@ -14770,6 +15153,10 @@ declare type WebhookListResponse = {
|
|
|
14770
15153
|
* If this field is omitted, there are no subsequent pages.
|
|
14771
15154
|
*/
|
|
14772
15155
|
next_page_token?: string | undefined;
|
|
15156
|
+
/**
|
|
15157
|
+
* The webhooks.
|
|
15158
|
+
*/
|
|
15159
|
+
webhooks?: Array<Webhook> | undefined;
|
|
14773
15160
|
};
|
|
14774
15161
|
|
|
14775
15162
|
declare type WebhookPingParams$ = PingWebhookRequest;
|
|
@@ -14847,11 +15234,11 @@ declare namespace webhooks {
|
|
|
14847
15234
|
WebhookListResponse,
|
|
14848
15235
|
WebhookPingResponse,
|
|
14849
15236
|
WebhookRotateSigningSecretResponse,
|
|
14850
|
-
WebhookUpdateSubscribedEvent,
|
|
14851
15237
|
WebhookUpdateState,
|
|
15238
|
+
WebhookUpdateSubscribedEvent,
|
|
14852
15239
|
WebhookUpdate,
|
|
14853
|
-
WebhookSubscribedEvent,
|
|
14854
15240
|
WebhookState,
|
|
15241
|
+
WebhookSubscribedEvent,
|
|
14855
15242
|
Webhook,
|
|
14856
15243
|
WebhookInput
|
|
14857
15244
|
}
|
|
@@ -14872,9 +15259,9 @@ declare type WebhookUpdate = {
|
|
|
14872
15259
|
*/
|
|
14873
15260
|
name?: string | undefined;
|
|
14874
15261
|
/**
|
|
14875
|
-
* Optional. The
|
|
15262
|
+
* Optional. The state of the webhook.
|
|
14876
15263
|
*/
|
|
14877
|
-
|
|
15264
|
+
state?: WebhookUpdateState | undefined;
|
|
14878
15265
|
/**
|
|
14879
15266
|
* Optional. The events that the webhook is subscribed to.
|
|
14880
15267
|
*
|
|
@@ -14890,9 +15277,9 @@ declare type WebhookUpdate = {
|
|
|
14890
15277
|
*/
|
|
14891
15278
|
subscribed_events?: Array<WebhookUpdateSubscribedEvent> | undefined;
|
|
14892
15279
|
/**
|
|
14893
|
-
* Optional. The
|
|
15280
|
+
* Optional. The URI to which webhook events will be sent.
|
|
14894
15281
|
*/
|
|
14895
|
-
|
|
15282
|
+
uri?: string | undefined;
|
|
14896
15283
|
};
|
|
14897
15284
|
|
|
14898
15285
|
declare type WebhookUpdateParams$ = WebhookUpdate;
|
|
@@ -14902,11 +15289,6 @@ declare type WebhookUpdateParams = {
|
|
|
14902
15289
|
update_mask?: string;
|
|
14903
15290
|
} & webhooks.WebhookUpdate;
|
|
14904
15291
|
|
|
14905
|
-
/**
|
|
14906
|
-
* Optional. The state of the webhook.
|
|
14907
|
-
*/
|
|
14908
|
-
declare type WebhookUpdateState = "enabled" | "disabled" | "disabled_due_to_failed_deliveries";
|
|
14909
|
-
|
|
14910
15292
|
/**
|
|
14911
15293
|
* @license
|
|
14912
15294
|
* Copyright 2026 Google LLC
|
|
@@ -14914,6 +15296,11 @@ declare type WebhookUpdateState = "enabled" | "disabled" | "disabled_due_to_fail
|
|
|
14914
15296
|
*
|
|
14915
15297
|
* g3-prettier-ignore-file
|
|
14916
15298
|
*/
|
|
15299
|
+
/**
|
|
15300
|
+
* Optional. The state of the webhook.
|
|
15301
|
+
*/
|
|
15302
|
+
declare type WebhookUpdateState = "enabled" | "disabled" | "disabled_due_to_failed_deliveries";
|
|
15303
|
+
|
|
14917
15304
|
declare type WebhookUpdateSubscribedEvent = "batch.succeeded" | "batch.expired" | "batch.failed" | "interaction.requires_action" | "interaction.completed" | "interaction.failed" | "video.generated" | (string & {});
|
|
14918
15305
|
|
|
14919
15306
|
/** Standard web search for grounding and related configurations. Only text results are returned. */
|