@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/web/web.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. */
|
|
@@ -5828,7 +5921,6 @@ export declare interface GoogleMaps {
|
|
|
5828
5921
|
* A tool that can be used by the model to call Google Maps.
|
|
5829
5922
|
*/
|
|
5830
5923
|
declare type GoogleMaps_2 = {
|
|
5831
|
-
type: "google_maps";
|
|
5832
5924
|
/**
|
|
5833
5925
|
* Whether to return a widget context token in the tool call result of the
|
|
5834
5926
|
*
|
|
@@ -5844,6 +5936,7 @@ declare type GoogleMaps_2 = {
|
|
|
5844
5936
|
* The longitude of the user's location.
|
|
5845
5937
|
*/
|
|
5846
5938
|
longitude?: number | undefined;
|
|
5939
|
+
type: "google_maps";
|
|
5847
5940
|
};
|
|
5848
5941
|
|
|
5849
5942
|
declare type GoogleMapsCall$ = GoogleMapsCallDelta;
|
|
@@ -5868,7 +5961,6 @@ declare type GoogleMapsCallArguments = {
|
|
|
5868
5961
|
};
|
|
5869
5962
|
|
|
5870
5963
|
declare type GoogleMapsCallDelta = {
|
|
5871
|
-
type: "google_maps_call";
|
|
5872
5964
|
/**
|
|
5873
5965
|
* The arguments to pass to the Google Maps tool.
|
|
5874
5966
|
*/
|
|
@@ -5877,6 +5969,7 @@ declare type GoogleMapsCallDelta = {
|
|
|
5877
5969
|
* A signature hash for backend validation.
|
|
5878
5970
|
*/
|
|
5879
5971
|
signature?: string | undefined;
|
|
5972
|
+
type: "google_maps_call";
|
|
5880
5973
|
};
|
|
5881
5974
|
|
|
5882
5975
|
declare type GoogleMapsCallStep$ = GoogleMapsCallStep;
|
|
@@ -5885,7 +5978,6 @@ declare type GoogleMapsCallStep$ = GoogleMapsCallStep;
|
|
|
5885
5978
|
* Google Maps call step.
|
|
5886
5979
|
*/
|
|
5887
5980
|
declare type GoogleMapsCallStep = {
|
|
5888
|
-
type: "google_maps_call";
|
|
5889
5981
|
/**
|
|
5890
5982
|
* The arguments to pass to the Google Maps tool.
|
|
5891
5983
|
*/
|
|
@@ -5898,6 +5990,7 @@ declare type GoogleMapsCallStep = {
|
|
|
5898
5990
|
* A signature hash for backend validation.
|
|
5899
5991
|
*/
|
|
5900
5992
|
signature?: string | undefined;
|
|
5993
|
+
type: "google_maps_call";
|
|
5901
5994
|
};
|
|
5902
5995
|
|
|
5903
5996
|
declare type GoogleMapsResult$ = GoogleMapsResult;
|
|
@@ -5913,7 +6006,6 @@ declare type GoogleMapsResult = {
|
|
|
5913
6006
|
};
|
|
5914
6007
|
|
|
5915
6008
|
declare type GoogleMapsResultDelta = {
|
|
5916
|
-
type: "google_maps_result";
|
|
5917
6009
|
/**
|
|
5918
6010
|
* The results of the Google Maps.
|
|
5919
6011
|
*/
|
|
@@ -5922,13 +6014,14 @@ declare type GoogleMapsResultDelta = {
|
|
|
5922
6014
|
* A signature hash for backend validation.
|
|
5923
6015
|
*/
|
|
5924
6016
|
signature?: string | undefined;
|
|
6017
|
+
type: "google_maps_result";
|
|
5925
6018
|
};
|
|
5926
6019
|
|
|
5927
6020
|
declare type GoogleMapsResultPlaces = {
|
|
5928
|
-
place_id?: string | undefined;
|
|
5929
6021
|
name?: string | undefined;
|
|
5930
|
-
|
|
6022
|
+
place_id?: string | undefined;
|
|
5931
6023
|
review_snippets?: Array<ReviewSnippet> | undefined;
|
|
6024
|
+
url?: string | undefined;
|
|
5932
6025
|
};
|
|
5933
6026
|
|
|
5934
6027
|
declare type GoogleMapsResultStep$ = GoogleMapsResultStep;
|
|
@@ -5937,16 +6030,16 @@ declare type GoogleMapsResultStep$ = GoogleMapsResultStep;
|
|
|
5937
6030
|
* Google Maps result step.
|
|
5938
6031
|
*/
|
|
5939
6032
|
declare type GoogleMapsResultStep = {
|
|
5940
|
-
type: "google_maps_result";
|
|
5941
|
-
result: Array<GoogleMapsResult>;
|
|
5942
6033
|
/**
|
|
5943
6034
|
* Required. ID to match the ID from the function call block.
|
|
5944
6035
|
*/
|
|
5945
6036
|
call_id: string;
|
|
6037
|
+
result: Array<GoogleMapsResult>;
|
|
5946
6038
|
/**
|
|
5947
6039
|
* A signature hash for backend validation.
|
|
5948
6040
|
*/
|
|
5949
6041
|
signature?: string | undefined;
|
|
6042
|
+
type: "google_maps_result";
|
|
5950
6043
|
};
|
|
5951
6044
|
|
|
5952
6045
|
/** 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. */
|
|
@@ -5977,11 +6070,11 @@ export declare interface GoogleSearch {
|
|
|
5977
6070
|
* A tool that can be used by the model to search Google.
|
|
5978
6071
|
*/
|
|
5979
6072
|
declare type GoogleSearch_2 = {
|
|
5980
|
-
type: "google_search";
|
|
5981
6073
|
/**
|
|
5982
6074
|
* The types of search grounding to enable.
|
|
5983
6075
|
*/
|
|
5984
6076
|
search_types?: Array<GoogleSearchSearchType> | undefined;
|
|
6077
|
+
type: "google_search";
|
|
5985
6078
|
};
|
|
5986
6079
|
|
|
5987
6080
|
declare type GoogleSearchCall$ = GoogleSearchCallDelta;
|
|
@@ -6006,7 +6099,6 @@ declare type GoogleSearchCallArguments = {
|
|
|
6006
6099
|
};
|
|
6007
6100
|
|
|
6008
6101
|
declare type GoogleSearchCallDelta = {
|
|
6009
|
-
type: "google_search_call";
|
|
6010
6102
|
/**
|
|
6011
6103
|
* The arguments to pass to Google Search.
|
|
6012
6104
|
*/
|
|
@@ -6015,6 +6107,7 @@ declare type GoogleSearchCallDelta = {
|
|
|
6015
6107
|
* A signature hash for backend validation.
|
|
6016
6108
|
*/
|
|
6017
6109
|
signature?: string | undefined;
|
|
6110
|
+
type: "google_search_call";
|
|
6018
6111
|
};
|
|
6019
6112
|
|
|
6020
6113
|
declare type GoogleSearchCallStep$ = GoogleSearchCallStep;
|
|
@@ -6023,23 +6116,23 @@ declare type GoogleSearchCallStep$ = GoogleSearchCallStep;
|
|
|
6023
6116
|
* Google Search call step.
|
|
6024
6117
|
*/
|
|
6025
6118
|
declare type GoogleSearchCallStep = {
|
|
6026
|
-
type: "google_search_call";
|
|
6027
6119
|
/**
|
|
6028
6120
|
* The arguments to pass to Google Search.
|
|
6029
6121
|
*/
|
|
6030
6122
|
arguments: GoogleSearchCallArguments;
|
|
6031
|
-
/**
|
|
6032
|
-
* The type of search grounding enabled.
|
|
6033
|
-
*/
|
|
6034
|
-
search_type?: GoogleSearchCallStepSearchType | undefined;
|
|
6035
6123
|
/**
|
|
6036
6124
|
* Required. A unique ID for this specific tool call.
|
|
6037
6125
|
*/
|
|
6038
6126
|
id: string;
|
|
6127
|
+
/**
|
|
6128
|
+
* The type of search grounding enabled.
|
|
6129
|
+
*/
|
|
6130
|
+
search_type?: GoogleSearchCallStepSearchType | undefined;
|
|
6039
6131
|
/**
|
|
6040
6132
|
* A signature hash for backend validation.
|
|
6041
6133
|
*/
|
|
6042
6134
|
signature?: string | undefined;
|
|
6135
|
+
type: "google_search_call";
|
|
6043
6136
|
};
|
|
6044
6137
|
|
|
6045
6138
|
/**
|
|
@@ -6069,13 +6162,13 @@ declare type GoogleSearchResult = {
|
|
|
6069
6162
|
};
|
|
6070
6163
|
|
|
6071
6164
|
declare type GoogleSearchResultDelta = {
|
|
6072
|
-
type: "google_search_result";
|
|
6073
|
-
result: Array<GoogleSearchResult>;
|
|
6074
6165
|
is_error?: boolean | undefined;
|
|
6166
|
+
result: Array<GoogleSearchResult>;
|
|
6075
6167
|
/**
|
|
6076
6168
|
* A signature hash for backend validation.
|
|
6077
6169
|
*/
|
|
6078
6170
|
signature?: string | undefined;
|
|
6171
|
+
type: "google_search_result";
|
|
6079
6172
|
};
|
|
6080
6173
|
|
|
6081
6174
|
declare type GoogleSearchResultStep$ = GoogleSearchResultStep;
|
|
@@ -6084,23 +6177,23 @@ declare type GoogleSearchResultStep$ = GoogleSearchResultStep;
|
|
|
6084
6177
|
* Google Search result step.
|
|
6085
6178
|
*/
|
|
6086
6179
|
declare type GoogleSearchResultStep = {
|
|
6087
|
-
type: "google_search_result";
|
|
6088
6180
|
/**
|
|
6089
|
-
* Required.
|
|
6181
|
+
* Required. ID to match the ID from the function call block.
|
|
6090
6182
|
*/
|
|
6091
|
-
|
|
6183
|
+
call_id: string;
|
|
6092
6184
|
/**
|
|
6093
6185
|
* Whether the Google Search resulted in an error.
|
|
6094
6186
|
*/
|
|
6095
6187
|
is_error?: boolean | undefined;
|
|
6096
6188
|
/**
|
|
6097
|
-
* Required.
|
|
6189
|
+
* Required. The results of the Google Search.
|
|
6098
6190
|
*/
|
|
6099
|
-
|
|
6191
|
+
result: Array<GoogleSearchResult>;
|
|
6100
6192
|
/**
|
|
6101
6193
|
* A signature hash for backend validation.
|
|
6102
6194
|
*/
|
|
6103
6195
|
signature?: string | undefined;
|
|
6196
|
+
type: "google_search_result";
|
|
6104
6197
|
};
|
|
6105
6198
|
|
|
6106
6199
|
/** Tool to retrieve public web data for grounding, powered by Google. */
|
|
@@ -6303,7 +6396,7 @@ export declare interface GroundingMetadata {
|
|
|
6303
6396
|
searchEntryPoint?: SearchEntryPoint;
|
|
6304
6397
|
/** Web search queries for the following-up web search. */
|
|
6305
6398
|
webSearchQueries?: string[];
|
|
6306
|
-
/** 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. */
|
|
6399
|
+
/** 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. */
|
|
6307
6400
|
googleMapsWidgetContextToken?: string;
|
|
6308
6401
|
/** 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. */
|
|
6309
6402
|
retrievalQueries?: string[];
|
|
@@ -6343,14 +6436,14 @@ declare type GroundingToolCount$ = GroundingToolCount;
|
|
|
6343
6436
|
* The number of grounding tool counts.
|
|
6344
6437
|
*/
|
|
6345
6438
|
declare type GroundingToolCount = {
|
|
6346
|
-
/**
|
|
6347
|
-
* The grounding tool type associated with the count.
|
|
6348
|
-
*/
|
|
6349
|
-
type?: GroundingToolCountType | undefined;
|
|
6350
6439
|
/**
|
|
6351
6440
|
* The number of grounding tool counts.
|
|
6352
6441
|
*/
|
|
6353
6442
|
count?: number | undefined;
|
|
6443
|
+
/**
|
|
6444
|
+
* The grounding tool type associated with the count.
|
|
6445
|
+
*/
|
|
6446
|
+
type?: GroundingToolCountType | undefined;
|
|
6354
6447
|
};
|
|
6355
6448
|
|
|
6356
6449
|
/**
|
|
@@ -6409,6 +6502,8 @@ export declare enum HarmBlockThreshold {
|
|
|
6409
6502
|
OFF = "OFF"
|
|
6410
6503
|
}
|
|
6411
6504
|
|
|
6505
|
+
declare type HarmCategory$ = HarmCategory_2;
|
|
6506
|
+
|
|
6412
6507
|
/** The harm category to be blocked. */
|
|
6413
6508
|
export declare enum HarmCategory {
|
|
6414
6509
|
/**
|
|
@@ -6457,6 +6552,15 @@ export declare enum HarmCategory {
|
|
|
6457
6552
|
HARM_CATEGORY_JAILBREAK = "HARM_CATEGORY_JAILBREAK"
|
|
6458
6553
|
}
|
|
6459
6554
|
|
|
6555
|
+
/**
|
|
6556
|
+
* @license
|
|
6557
|
+
* Copyright 2026 Google LLC
|
|
6558
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
6559
|
+
*
|
|
6560
|
+
* g3-prettier-ignore-file
|
|
6561
|
+
*/
|
|
6562
|
+
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 & {});
|
|
6563
|
+
|
|
6460
6564
|
/** Output only. The probability of harm for this category. */
|
|
6461
6565
|
export declare enum HarmProbability {
|
|
6462
6566
|
/**
|
|
@@ -6716,20 +6820,20 @@ declare type ImageContent$ = ImageContent;
|
|
|
6716
6820
|
* An image content block.
|
|
6717
6821
|
*/
|
|
6718
6822
|
declare type ImageContent = {
|
|
6719
|
-
type: "image";
|
|
6720
6823
|
/**
|
|
6721
6824
|
* The image content.
|
|
6722
6825
|
*/
|
|
6723
6826
|
data?: string | undefined;
|
|
6724
|
-
/**
|
|
6725
|
-
* The URI of the image.
|
|
6726
|
-
*/
|
|
6727
|
-
uri?: string | undefined;
|
|
6728
6827
|
/**
|
|
6729
6828
|
* The mime type of the image.
|
|
6730
6829
|
*/
|
|
6731
6830
|
mime_type?: ImageContentMimeType | undefined;
|
|
6732
6831
|
resolution?: MediaResolution_2 | undefined;
|
|
6832
|
+
type: "image";
|
|
6833
|
+
/**
|
|
6834
|
+
* The URI of the image.
|
|
6835
|
+
*/
|
|
6836
|
+
uri?: string | undefined;
|
|
6733
6837
|
};
|
|
6734
6838
|
|
|
6735
6839
|
/**
|
|
@@ -6738,11 +6842,11 @@ declare type ImageContent = {
|
|
|
6738
6842
|
declare type ImageContentMimeType = "image/png" | "image/jpeg" | "image/webp" | "image/heic" | "image/heif" | "image/gif" | "image/bmp" | "image/tiff" | (string & {});
|
|
6739
6843
|
|
|
6740
6844
|
declare type ImageDelta = {
|
|
6741
|
-
type: "image";
|
|
6742
6845
|
data?: string | undefined;
|
|
6743
|
-
uri?: string | undefined;
|
|
6744
6846
|
mime_type?: ImageDeltaMimeType | undefined;
|
|
6745
6847
|
resolution?: MediaResolution_2 | undefined;
|
|
6848
|
+
type: "image";
|
|
6849
|
+
uri?: string | undefined;
|
|
6746
6850
|
};
|
|
6747
6851
|
|
|
6748
6852
|
declare type ImageDeltaMimeType = "image/png" | "image/jpeg" | "image/webp" | "image/heic" | "image/heif" | "image/gif" | "image/bmp" | "image/tiff" | (string & {});
|
|
@@ -6797,31 +6901,50 @@ export declare enum ImageResizeMode {
|
|
|
6797
6901
|
PAD = "PAD"
|
|
6798
6902
|
}
|
|
6799
6903
|
|
|
6800
|
-
declare type ImageResponseFormat$ =
|
|
6904
|
+
declare type ImageResponseFormat$ = ImageResponseFormat_2;
|
|
6905
|
+
|
|
6906
|
+
/** Configuration for image-specific output formatting. */
|
|
6907
|
+
export declare class ImageResponseFormat {
|
|
6908
|
+
/** Optional. The aspect ratio for the image output. */
|
|
6909
|
+
aspectRatio?: AspectRatio;
|
|
6910
|
+
/** Optional. Delivery mode for the generated content. */
|
|
6911
|
+
delivery?: Delivery;
|
|
6912
|
+
/** Optional. The size of the image output. */
|
|
6913
|
+
imageSize?: ImageSize;
|
|
6914
|
+
/** Optional. The MIME type of the image output. */
|
|
6915
|
+
mimeType?: string;
|
|
6916
|
+
}
|
|
6801
6917
|
|
|
6802
6918
|
/**
|
|
6803
6919
|
* Configuration for image output format.
|
|
6804
6920
|
*/
|
|
6805
|
-
declare type
|
|
6806
|
-
type: "image";
|
|
6921
|
+
declare type ImageResponseFormat_2 = {
|
|
6807
6922
|
/**
|
|
6808
|
-
* The
|
|
6923
|
+
* The aspect ratio for the image output.
|
|
6809
6924
|
*/
|
|
6810
|
-
|
|
6925
|
+
aspect_ratio?: ImageResponseFormatAspectRatio | undefined;
|
|
6811
6926
|
/**
|
|
6812
6927
|
* The delivery mode for the image output.
|
|
6813
6928
|
*/
|
|
6814
6929
|
delivery?: ImageResponseFormatDelivery | undefined;
|
|
6815
|
-
/**
|
|
6816
|
-
* The aspect ratio for the image output.
|
|
6817
|
-
*/
|
|
6818
|
-
aspect_ratio?: ImageResponseFormatAspectRatio | undefined;
|
|
6819
6930
|
/**
|
|
6820
6931
|
* The size of the image output.
|
|
6821
6932
|
*/
|
|
6822
6933
|
image_size?: ImageResponseFormatImageSize | undefined;
|
|
6934
|
+
/**
|
|
6935
|
+
* The MIME type of the image output.
|
|
6936
|
+
*/
|
|
6937
|
+
mime_type?: ImageResponseFormatMimeType | undefined;
|
|
6938
|
+
type: "image";
|
|
6823
6939
|
};
|
|
6824
6940
|
|
|
6941
|
+
/**
|
|
6942
|
+
* @license
|
|
6943
|
+
* Copyright 2026 Google LLC
|
|
6944
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
6945
|
+
*
|
|
6946
|
+
* g3-prettier-ignore-file
|
|
6947
|
+
*/
|
|
6825
6948
|
/**
|
|
6826
6949
|
* The aspect ratio for the image output.
|
|
6827
6950
|
*/
|
|
@@ -6837,13 +6960,6 @@ declare type ImageResponseFormatDelivery = "inline" | "uri" | (string & {});
|
|
|
6837
6960
|
*/
|
|
6838
6961
|
declare type ImageResponseFormatImageSize = "512" | "1K" | "2K" | "4K" | (string & {});
|
|
6839
6962
|
|
|
6840
|
-
/**
|
|
6841
|
-
* @license
|
|
6842
|
-
* Copyright 2026 Google LLC
|
|
6843
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
6844
|
-
*
|
|
6845
|
-
* g3-prettier-ignore-file
|
|
6846
|
-
*/
|
|
6847
6963
|
/**
|
|
6848
6964
|
* The MIME type of the image output.
|
|
6849
6965
|
*/
|
|
@@ -6853,15 +6969,39 @@ declare type ImageResponseFormatMimeType = "image/jpeg";
|
|
|
6853
6969
|
export declare interface ImageSearch {
|
|
6854
6970
|
}
|
|
6855
6971
|
|
|
6856
|
-
/**
|
|
6857
|
-
export declare
|
|
6858
|
-
/**
|
|
6859
|
-
|
|
6860
|
-
|
|
6861
|
-
|
|
6862
|
-
|
|
6863
|
-
|
|
6864
|
-
|
|
6972
|
+
/** The size of the image output. */
|
|
6973
|
+
export declare enum ImageSize {
|
|
6974
|
+
/**
|
|
6975
|
+
* Default value. This value is unused.
|
|
6976
|
+
*/
|
|
6977
|
+
IMAGE_SIZE_UNSPECIFIED = "IMAGE_SIZE_UNSPECIFIED",
|
|
6978
|
+
/**
|
|
6979
|
+
* 512px image size.
|
|
6980
|
+
*/
|
|
6981
|
+
IMAGE_SIZE_FIVE_TWELVE = "IMAGE_SIZE_FIVE_TWELVE",
|
|
6982
|
+
/**
|
|
6983
|
+
* 1K image size.
|
|
6984
|
+
*/
|
|
6985
|
+
IMAGE_SIZE_ONE_K = "IMAGE_SIZE_ONE_K",
|
|
6986
|
+
/**
|
|
6987
|
+
* 2K image size.
|
|
6988
|
+
*/
|
|
6989
|
+
IMAGE_SIZE_TWO_K = "IMAGE_SIZE_TWO_K",
|
|
6990
|
+
/**
|
|
6991
|
+
* 4K image size.
|
|
6992
|
+
*/
|
|
6993
|
+
IMAGE_SIZE_FOUR_K = "IMAGE_SIZE_FOUR_K"
|
|
6994
|
+
}
|
|
6995
|
+
|
|
6996
|
+
/** Optional parameters for importing a file. */
|
|
6997
|
+
export declare interface ImportFileConfig {
|
|
6998
|
+
/** Used to override HTTP request options. */
|
|
6999
|
+
httpOptions?: HttpOptions;
|
|
7000
|
+
/** Abort signal which can be used to cancel the request.
|
|
7001
|
+
|
|
7002
|
+
NOTE: AbortSignal is a client-only operation. Using it to cancel an
|
|
7003
|
+
operation will not cancel the request in the service. You will still
|
|
7004
|
+
be charged usage for any applicable operations.
|
|
6865
7005
|
*/
|
|
6866
7006
|
abortSignal?: AbortSignal;
|
|
6867
7007
|
/** User provided custom metadata stored as key-value pairs used for querying. */
|
|
@@ -7030,7 +7170,7 @@ declare type Interaction = {
|
|
|
7030
7170
|
/**
|
|
7031
7171
|
* Enforces that the generated response is a JSON object that complies with the JSON schema specified in this field.
|
|
7032
7172
|
*/
|
|
7033
|
-
response_format?: Array<
|
|
7173
|
+
response_format?: Array<ResponseFormat_2> | ResponseFormat_2 | undefined;
|
|
7034
7174
|
/**
|
|
7035
7175
|
* The environment configuration for the interaction. Can be an object specifying remote environment sources or a string referencing an existing environment ID.
|
|
7036
7176
|
*/
|
|
@@ -7053,6 +7193,16 @@ declare type Interaction = {
|
|
|
7053
7193
|
* Configuration parameters for the agent interaction.
|
|
7054
7194
|
*/
|
|
7055
7195
|
agent_config?: DynamicAgentConfig | DeepResearchAgentConfig | undefined;
|
|
7196
|
+
/**
|
|
7197
|
+
* Safety settings for the interaction.
|
|
7198
|
+
*/
|
|
7199
|
+
safety_settings?: Array<SafetySetting_2> | undefined;
|
|
7200
|
+
/**
|
|
7201
|
+
* The labels with user-defined metadata for the request.
|
|
7202
|
+
*/
|
|
7203
|
+
labels?: {
|
|
7204
|
+
[k: string]: string;
|
|
7205
|
+
} | undefined;
|
|
7056
7206
|
/**
|
|
7057
7207
|
* The input for the interaction.
|
|
7058
7208
|
*/
|
|
@@ -7166,7 +7316,7 @@ declare type InteractionGetParamsStreaming = GetInteractionByIdParamsStreaming;
|
|
|
7166
7316
|
/**
|
|
7167
7317
|
* Enforces that the generated response is a JSON object that complies with the JSON schema specified in this field.
|
|
7168
7318
|
*/
|
|
7169
|
-
declare type InteractionResponseFormat = Array<
|
|
7319
|
+
declare type InteractionResponseFormat = Array<ResponseFormat_2> | ResponseFormat_2;
|
|
7170
7320
|
|
|
7171
7321
|
export declare namespace Interactions {
|
|
7172
7322
|
export type AllowedTools = AllowedTools$;
|
|
@@ -7209,6 +7359,7 @@ export declare namespace Interactions {
|
|
|
7209
7359
|
export type GoogleSearchResult = GoogleSearchResult$;
|
|
7210
7360
|
export interface GoogleSearchResultStep extends GoogleSearchResultStep$ {
|
|
7211
7361
|
}
|
|
7362
|
+
export type HarmCategory = HarmCategory$;
|
|
7212
7363
|
export type ImageConfig = ImageConfig$;
|
|
7213
7364
|
export type ImageContent = ImageContent$;
|
|
7214
7365
|
export type ImageResponseFormat = ImageResponseFormat$;
|
|
@@ -7234,6 +7385,11 @@ export declare namespace Interactions {
|
|
|
7234
7385
|
}
|
|
7235
7386
|
export interface PlaceCitation extends PlaceCitation$ {
|
|
7236
7387
|
}
|
|
7388
|
+
export type RetrievalCallArguments = RetrievalCallArguments$;
|
|
7389
|
+
export interface RetrievalCallDelta extends RetrievalCallDelta$ {
|
|
7390
|
+
}
|
|
7391
|
+
export type RetrievalResultDelta = RetrievalResultDelta$;
|
|
7392
|
+
export type SafetySetting = SafetySetting$;
|
|
7237
7393
|
export type SpeechConfig = SpeechConfig$;
|
|
7238
7394
|
export type Step = Step$;
|
|
7239
7395
|
export interface StepDelta extends StepDelta$ {
|
|
@@ -7267,12 +7423,8 @@ export declare namespace Interactions {
|
|
|
7267
7423
|
export type Arguments = Arguments$;
|
|
7268
7424
|
}
|
|
7269
7425
|
export namespace Environment {
|
|
7270
|
-
export
|
|
7271
|
-
}
|
|
7426
|
+
export type Allowlist = Allowlist$;
|
|
7272
7427
|
export type Source = Source$;
|
|
7273
|
-
export namespace Allowlist {
|
|
7274
|
-
export type Allowlist = Allowlist$2;
|
|
7275
|
-
}
|
|
7276
7428
|
}
|
|
7277
7429
|
export namespace ErrorEvent {
|
|
7278
7430
|
export type Error = Error$;
|
|
@@ -7324,6 +7476,9 @@ export declare namespace Interactions {
|
|
|
7324
7476
|
export namespace PlaceCitation {
|
|
7325
7477
|
export type ReviewSnippet = ReviewSnippet$3;
|
|
7326
7478
|
}
|
|
7479
|
+
export namespace RetrievalCallDelta {
|
|
7480
|
+
export type Arguments = Arguments$4;
|
|
7481
|
+
}
|
|
7327
7482
|
export namespace StepDelta {
|
|
7328
7483
|
export type ArgumentsDelta = ArgumentsDelta$;
|
|
7329
7484
|
export type Audio = Audio$;
|
|
@@ -7370,7 +7525,7 @@ export declare namespace Interactions {
|
|
|
7370
7525
|
}
|
|
7371
7526
|
}
|
|
7372
7527
|
export namespace URLContextCallStep {
|
|
7373
|
-
export type Arguments = Arguments$
|
|
7528
|
+
export type Arguments = Arguments$5;
|
|
7374
7529
|
}
|
|
7375
7530
|
export namespace URLContextResultStep {
|
|
7376
7531
|
export type Result = Result$3;
|
|
@@ -7388,6 +7543,7 @@ declare namespace interactions {
|
|
|
7388
7543
|
export {
|
|
7389
7544
|
AgentOption,
|
|
7390
7545
|
AllowedTools,
|
|
7546
|
+
Transform,
|
|
7391
7547
|
AllowlistEntry,
|
|
7392
7548
|
Annotation,
|
|
7393
7549
|
ArgumentsDelta,
|
|
@@ -7395,9 +7551,9 @@ declare namespace interactions {
|
|
|
7395
7551
|
AudioContent,
|
|
7396
7552
|
AudioDeltaMimeType,
|
|
7397
7553
|
AudioDelta,
|
|
7398
|
-
AudioResponseFormatMimeType,
|
|
7399
7554
|
AudioResponseFormatDelivery,
|
|
7400
|
-
|
|
7555
|
+
AudioResponseFormatMimeType,
|
|
7556
|
+
AudioResponseFormat_2 as AudioResponseFormat,
|
|
7401
7557
|
Language_2 as Language,
|
|
7402
7558
|
CodeExecutionCallArguments,
|
|
7403
7559
|
CodeExecutionCallDelta,
|
|
@@ -7405,8 +7561,8 @@ declare namespace interactions {
|
|
|
7405
7561
|
CodeExecutionResultDelta,
|
|
7406
7562
|
CodeExecutionResultStep,
|
|
7407
7563
|
CodeExecution,
|
|
7408
|
-
EnvironmentEnum,
|
|
7409
7564
|
DisabledSafetyPolicy,
|
|
7565
|
+
EnvironmentEnum,
|
|
7410
7566
|
ComputerUse_2 as ComputerUse,
|
|
7411
7567
|
Content_2 as Content,
|
|
7412
7568
|
CreateAgentInteractionResponseFormat,
|
|
@@ -7471,6 +7627,7 @@ declare namespace interactions {
|
|
|
7471
7627
|
GoogleSearch_2 as GoogleSearch,
|
|
7472
7628
|
GroundingToolCountType,
|
|
7473
7629
|
GroundingToolCount,
|
|
7630
|
+
HarmCategory_2 as HarmCategory,
|
|
7474
7631
|
HybridSearch,
|
|
7475
7632
|
ImageConfigAspectRatio,
|
|
7476
7633
|
ImageConfigImageSize,
|
|
@@ -7479,11 +7636,11 @@ declare namespace interactions {
|
|
|
7479
7636
|
ImageContent,
|
|
7480
7637
|
ImageDeltaMimeType,
|
|
7481
7638
|
ImageDelta,
|
|
7482
|
-
ImageResponseFormatMimeType,
|
|
7483
|
-
ImageResponseFormatDelivery,
|
|
7484
7639
|
ImageResponseFormatAspectRatio,
|
|
7640
|
+
ImageResponseFormatDelivery,
|
|
7485
7641
|
ImageResponseFormatImageSize,
|
|
7486
|
-
|
|
7642
|
+
ImageResponseFormatMimeType,
|
|
7643
|
+
ImageResponseFormat_2 as ImageResponseFormat,
|
|
7487
7644
|
InteractionCompletedEvent,
|
|
7488
7645
|
InteractionCreatedEvent,
|
|
7489
7646
|
InteractionSseEventInteractionStatus,
|
|
@@ -7517,11 +7674,18 @@ declare namespace interactions {
|
|
|
7517
7674
|
RagRetrievalConfig_2 as RagRetrievalConfig,
|
|
7518
7675
|
RagStoreConfig,
|
|
7519
7676
|
Ranking,
|
|
7520
|
-
ResponseFormat,
|
|
7677
|
+
ResponseFormat_2 as ResponseFormat,
|
|
7521
7678
|
ResponseModality,
|
|
7522
|
-
|
|
7679
|
+
RetrievalCallArguments,
|
|
7680
|
+
RetrievalCallDeltaRetrievalType,
|
|
7681
|
+
RetrievalCallDelta,
|
|
7682
|
+
RetrievalResultDelta,
|
|
7683
|
+
RetrievalRetrievalType,
|
|
7523
7684
|
Retrieval_2 as Retrieval,
|
|
7524
7685
|
ReviewSnippet,
|
|
7686
|
+
Method,
|
|
7687
|
+
Threshold,
|
|
7688
|
+
SafetySetting_2 as SafetySetting,
|
|
7525
7689
|
ServiceTier_2 as ServiceTier,
|
|
7526
7690
|
SourceType,
|
|
7527
7691
|
Source,
|
|
@@ -7538,7 +7702,7 @@ declare namespace interactions {
|
|
|
7538
7702
|
TextContent,
|
|
7539
7703
|
TextDelta,
|
|
7540
7704
|
TextResponseFormatMimeType,
|
|
7541
|
-
TextResponseFormat,
|
|
7705
|
+
TextResponseFormat_2 as TextResponseFormat,
|
|
7542
7706
|
ThinkingLevel_2 as ThinkingLevel,
|
|
7543
7707
|
ThinkingSummaries,
|
|
7544
7708
|
ThoughtSignatureDelta,
|
|
@@ -7553,7 +7717,6 @@ declare namespace interactions {
|
|
|
7553
7717
|
URLCitation,
|
|
7554
7718
|
URLContextCallArguments,
|
|
7555
7719
|
URLContextCallDelta,
|
|
7556
|
-
Arguments,
|
|
7557
7720
|
URLContextCallStep,
|
|
7558
7721
|
URLContextResultDelta,
|
|
7559
7722
|
URLContextResultStep,
|
|
@@ -7569,9 +7732,9 @@ declare namespace interactions {
|
|
|
7569
7732
|
VideoContent,
|
|
7570
7733
|
VideoDeltaMimeType,
|
|
7571
7734
|
VideoDelta,
|
|
7572
|
-
VideoResponseFormatDelivery,
|
|
7573
7735
|
VideoResponseFormatAspectRatio,
|
|
7574
|
-
|
|
7736
|
+
VideoResponseFormatDelivery,
|
|
7737
|
+
VideoResponseFormat_2 as VideoResponseFormat,
|
|
7575
7738
|
WebhookConfig_2 as WebhookConfig
|
|
7576
7739
|
}
|
|
7577
7740
|
}
|
|
@@ -7649,9 +7812,6 @@ declare type InteractionStatus = "in_progress" | "requires_action" | "completed"
|
|
|
7649
7812
|
declare type InteractionStatusUpdate$ = InteractionStatusUpdate;
|
|
7650
7813
|
|
|
7651
7814
|
declare type InteractionStatusUpdate = {
|
|
7652
|
-
event_type: "interaction.status_update";
|
|
7653
|
-
interaction_id: string;
|
|
7654
|
-
status: InteractionStatusUpdateStatus;
|
|
7655
7815
|
/**
|
|
7656
7816
|
* The event_id token to be used to resume the interaction stream, from
|
|
7657
7817
|
*
|
|
@@ -7659,7 +7819,10 @@ declare type InteractionStatusUpdate = {
|
|
|
7659
7819
|
* this event.
|
|
7660
7820
|
*/
|
|
7661
7821
|
event_id?: string | undefined;
|
|
7822
|
+
event_type: "interaction.status_update";
|
|
7823
|
+
interaction_id: string;
|
|
7662
7824
|
metadata?: StreamMetadata | undefined;
|
|
7825
|
+
status: InteractionStatusUpdateStatus;
|
|
7663
7826
|
};
|
|
7664
7827
|
|
|
7665
7828
|
declare type InteractionStatusUpdateStatus = "in_progress" | "requires_action" | "completed" | "failed" | "cancelled" | "incomplete" | "budget_exceeded" | (string & {});
|
|
@@ -8808,6 +8971,11 @@ export declare interface LiveServerSessionResumptionUpdate {
|
|
|
8808
8971
|
export declare interface LiveServerSetupComplete {
|
|
8809
8972
|
/** The session id of the live session. */
|
|
8810
8973
|
sessionId?: string;
|
|
8974
|
+
/** Signature of the verified consent audio. This is populated when the
|
|
8975
|
+
request has a ReplicatedVoiceConfig with consent_audio set, if the consent
|
|
8976
|
+
verification was successful. This may be used in a subsequent request
|
|
8977
|
+
instead of the consent_audio to verify the same consent. */
|
|
8978
|
+
voiceConsentSignature?: VoiceConsentSignature;
|
|
8811
8979
|
}
|
|
8812
8980
|
|
|
8813
8981
|
/** Request for the client to execute the `function_calls` and return the responses with the matching `id`s. */
|
|
@@ -8896,22 +9064,22 @@ export declare enum MaskReferenceMode {
|
|
|
8896
9064
|
MASK_MODE_SEMANTIC = "MASK_MODE_SEMANTIC"
|
|
8897
9065
|
}
|
|
8898
9066
|
|
|
8899
|
-
/** Match operation to use for
|
|
9067
|
+
/** Match operation to use for evaluating rewards. This enum is not supported in Gemini API. */
|
|
8900
9068
|
export declare enum MatchOperation {
|
|
8901
9069
|
/**
|
|
8902
|
-
* Default value.
|
|
9070
|
+
* Default value. A user error will be returned if not set.
|
|
8903
9071
|
*/
|
|
8904
9072
|
MATCH_OPERATION_UNSPECIFIED = "MATCH_OPERATION_UNSPECIFIED",
|
|
8905
9073
|
/**
|
|
8906
|
-
* Equivalent to GoogleSQL `REGEX_CONTAINS(target, expression)`.
|
|
9074
|
+
* Equivalent to [GoogleSQL](https://cloud.google.com/bigquery/docs/reference/standard-sql/string_functions#regexp_contains) `REGEX_CONTAINS(target, expression)`.
|
|
8907
9075
|
*/
|
|
8908
9076
|
REGEX_CONTAINS = "REGEX_CONTAINS",
|
|
8909
9077
|
/**
|
|
8910
|
-
* `
|
|
9078
|
+
* The match operation returns `true` if expression is a substring of the target.
|
|
8911
9079
|
*/
|
|
8912
9080
|
PARTIAL_MATCH = "PARTIAL_MATCH",
|
|
8913
9081
|
/**
|
|
8914
|
-
* `
|
|
9082
|
+
* The match operation returns `true` expression is an exact match of the target.
|
|
8915
9083
|
*/
|
|
8916
9084
|
EXACT_MATCH = "EXACT_MATCH"
|
|
8917
9085
|
}
|
|
@@ -8922,11 +9090,21 @@ declare type MCPServer$ = MCPServer;
|
|
|
8922
9090
|
* A MCPServer is a server that can be called by the model to perform actions.
|
|
8923
9091
|
*/
|
|
8924
9092
|
declare type MCPServer = {
|
|
8925
|
-
|
|
9093
|
+
/**
|
|
9094
|
+
* The allowed tools.
|
|
9095
|
+
*/
|
|
9096
|
+
allowed_tools?: Array<AllowedTools> | undefined;
|
|
9097
|
+
/**
|
|
9098
|
+
* Optional: Fields for authentication headers, timeouts, etc., if needed.
|
|
9099
|
+
*/
|
|
9100
|
+
headers?: {
|
|
9101
|
+
[k: string]: string;
|
|
9102
|
+
} | undefined;
|
|
8926
9103
|
/**
|
|
8927
9104
|
* The name of the MCPServer.
|
|
8928
9105
|
*/
|
|
8929
9106
|
name?: string | undefined;
|
|
9107
|
+
type: "mcp_server";
|
|
8930
9108
|
/**
|
|
8931
9109
|
* The full URL for the MCPServer endpoint.
|
|
8932
9110
|
*
|
|
@@ -8934,16 +9112,6 @@ declare type MCPServer = {
|
|
|
8934
9112
|
* Example: "https://api.example.com/mcp"
|
|
8935
9113
|
*/
|
|
8936
9114
|
url?: string | undefined;
|
|
8937
|
-
/**
|
|
8938
|
-
* Optional: Fields for authentication headers, timeouts, etc., if needed.
|
|
8939
|
-
*/
|
|
8940
|
-
headers?: {
|
|
8941
|
-
[k: string]: string;
|
|
8942
|
-
} | undefined;
|
|
8943
|
-
/**
|
|
8944
|
-
* The allowed tools.
|
|
8945
|
-
*/
|
|
8946
|
-
allowed_tools?: Array<AllowedTools> | undefined;
|
|
8947
9115
|
};
|
|
8948
9116
|
|
|
8949
9117
|
/** 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. */
|
|
@@ -8964,12 +9132,12 @@ declare type MCPServerToolCall$ = MCPServerToolCallDelta;
|
|
|
8964
9132
|
* g3-prettier-ignore-file
|
|
8965
9133
|
*/
|
|
8966
9134
|
declare type MCPServerToolCallDelta = {
|
|
8967
|
-
type: "mcp_server_tool_call";
|
|
8968
|
-
name: string;
|
|
8969
|
-
server_name: string;
|
|
8970
9135
|
arguments: {
|
|
8971
9136
|
[k: string]: any;
|
|
8972
9137
|
};
|
|
9138
|
+
name: string;
|
|
9139
|
+
server_name: string;
|
|
9140
|
+
type: "mcp_server_tool_call";
|
|
8973
9141
|
};
|
|
8974
9142
|
|
|
8975
9143
|
declare type MCPServerToolCallStep$ = MCPServerToolCallStep;
|
|
@@ -8985,15 +9153,6 @@ declare type MCPServerToolCallStep$ = MCPServerToolCallStep;
|
|
|
8985
9153
|
* MCPServer tool call step.
|
|
8986
9154
|
*/
|
|
8987
9155
|
declare type MCPServerToolCallStep = {
|
|
8988
|
-
type: "mcp_server_tool_call";
|
|
8989
|
-
/**
|
|
8990
|
-
* Required. The name of the tool which was called.
|
|
8991
|
-
*/
|
|
8992
|
-
name: string;
|
|
8993
|
-
/**
|
|
8994
|
-
* Required. The name of the used MCP server.
|
|
8995
|
-
*/
|
|
8996
|
-
server_name: string;
|
|
8997
9156
|
/**
|
|
8998
9157
|
* Required. The JSON object of arguments for the function.
|
|
8999
9158
|
*/
|
|
@@ -9004,15 +9163,24 @@ declare type MCPServerToolCallStep = {
|
|
|
9004
9163
|
* Required. A unique ID for this specific tool call.
|
|
9005
9164
|
*/
|
|
9006
9165
|
id: string;
|
|
9166
|
+
/**
|
|
9167
|
+
* Required. The name of the tool which was called.
|
|
9168
|
+
*/
|
|
9169
|
+
name: string;
|
|
9170
|
+
/**
|
|
9171
|
+
* Required. The name of the used MCP server.
|
|
9172
|
+
*/
|
|
9173
|
+
server_name: string;
|
|
9174
|
+
type: "mcp_server_tool_call";
|
|
9007
9175
|
};
|
|
9008
9176
|
|
|
9009
9177
|
declare type MCPServerToolResult$ = MCPServerToolResultDelta;
|
|
9010
9178
|
|
|
9011
9179
|
declare type MCPServerToolResultDelta = {
|
|
9012
|
-
type: "mcp_server_tool_result";
|
|
9013
9180
|
name?: string | undefined;
|
|
9014
|
-
server_name?: string | undefined;
|
|
9015
9181
|
result: MCPServerToolResultDeltaResult | Array<FunctionResultSubcontent> | string;
|
|
9182
|
+
server_name?: string | undefined;
|
|
9183
|
+
type: "mcp_server_tool_result";
|
|
9016
9184
|
};
|
|
9017
9185
|
|
|
9018
9186
|
declare type MCPServerToolResultDeltaResult = {};
|
|
@@ -9025,23 +9193,23 @@ declare type MCPServerToolResultStep$ = MCPServerToolResultStep;
|
|
|
9025
9193
|
* MCPServer tool result step.
|
|
9026
9194
|
*/
|
|
9027
9195
|
declare type MCPServerToolResultStep = {
|
|
9028
|
-
type: "mcp_server_tool_result";
|
|
9029
|
-
/**
|
|
9030
|
-
* Name of the tool which is called for this specific tool call.
|
|
9031
|
-
*/
|
|
9032
|
-
name?: string | undefined;
|
|
9033
|
-
/**
|
|
9034
|
-
* The name of the used MCP server.
|
|
9035
|
-
*/
|
|
9036
|
-
server_name?: string | undefined;
|
|
9037
9196
|
/**
|
|
9038
9197
|
* Required. ID to match the ID from the function call block.
|
|
9039
9198
|
*/
|
|
9040
9199
|
call_id: string;
|
|
9200
|
+
/**
|
|
9201
|
+
* Name of the tool which is called for this specific tool call.
|
|
9202
|
+
*/
|
|
9203
|
+
name?: string | undefined;
|
|
9041
9204
|
/**
|
|
9042
9205
|
* The output from the MCP server call. Can be simple text or rich content.
|
|
9043
9206
|
*/
|
|
9044
9207
|
result: MCPServerToolResultStepResult | string | Array<FunctionResultSubcontent>;
|
|
9208
|
+
/**
|
|
9209
|
+
* The name of the used MCP server.
|
|
9210
|
+
*/
|
|
9211
|
+
server_name?: string | undefined;
|
|
9212
|
+
type: "mcp_server_tool_result";
|
|
9045
9213
|
};
|
|
9046
9214
|
|
|
9047
9215
|
declare type MCPServerToolResultStepResult = {};
|
|
@@ -9134,6 +9302,14 @@ declare type Metadata$6 = StreamMetadata;
|
|
|
9134
9302
|
|
|
9135
9303
|
declare type Metadata$7 = StreamMetadata;
|
|
9136
9304
|
|
|
9305
|
+
/**
|
|
9306
|
+
* Optional. The method for blocking content. If not specified, the default
|
|
9307
|
+
*
|
|
9308
|
+
* @remarks
|
|
9309
|
+
* behavior is to use the probability score.
|
|
9310
|
+
*/
|
|
9311
|
+
declare type Method = "severity" | "probability" | (string & {});
|
|
9312
|
+
|
|
9137
9313
|
/** Server content modalities. */
|
|
9138
9314
|
export declare enum Modality {
|
|
9139
9315
|
/**
|
|
@@ -9260,7 +9436,6 @@ declare type ModelOutputStep$ = ModelOutputStep;
|
|
|
9260
9436
|
* Output generated by the model.
|
|
9261
9437
|
*/
|
|
9262
9438
|
declare type ModelOutputStep = {
|
|
9263
|
-
type: "model_output";
|
|
9264
9439
|
content?: Array<Content_2> | undefined;
|
|
9265
9440
|
/**
|
|
9266
9441
|
* The `Status` type defines a logical error model that is suitable for
|
|
@@ -9274,6 +9449,7 @@ declare type ModelOutputStep = {
|
|
|
9274
9449
|
* [API Design Guide](https://cloud.google.com/apis/design/errors).
|
|
9275
9450
|
*/
|
|
9276
9451
|
error?: Status | undefined;
|
|
9452
|
+
type: "model_output";
|
|
9277
9453
|
};
|
|
9278
9454
|
|
|
9279
9455
|
export declare class Models extends BaseModule {
|
|
@@ -10182,19 +10358,18 @@ declare type PlaceCitation$ = PlaceCitation;
|
|
|
10182
10358
|
* A place citation annotation.
|
|
10183
10359
|
*/
|
|
10184
10360
|
declare type PlaceCitation = {
|
|
10185
|
-
type: "place_citation";
|
|
10186
10361
|
/**
|
|
10187
|
-
*
|
|
10362
|
+
* End of the attributed segment, exclusive.
|
|
10188
10363
|
*/
|
|
10189
|
-
|
|
10364
|
+
end_index?: number | undefined;
|
|
10190
10365
|
/**
|
|
10191
10366
|
* Title of the place.
|
|
10192
10367
|
*/
|
|
10193
10368
|
name?: string | undefined;
|
|
10194
10369
|
/**
|
|
10195
|
-
*
|
|
10370
|
+
* The ID of the place, in `places/{place_id}` format.
|
|
10196
10371
|
*/
|
|
10197
|
-
|
|
10372
|
+
place_id?: string | undefined;
|
|
10198
10373
|
/**
|
|
10199
10374
|
* Snippets of reviews that are used to generate answers about the
|
|
10200
10375
|
*
|
|
@@ -10210,10 +10385,11 @@ declare type PlaceCitation = {
|
|
|
10210
10385
|
* Index indicates the start of the segment, measured in bytes.
|
|
10211
10386
|
*/
|
|
10212
10387
|
start_index?: number | undefined;
|
|
10388
|
+
type: "place_citation";
|
|
10213
10389
|
/**
|
|
10214
|
-
*
|
|
10390
|
+
* URI reference of the place.
|
|
10215
10391
|
*/
|
|
10216
|
-
|
|
10392
|
+
url?: string | undefined;
|
|
10217
10393
|
};
|
|
10218
10394
|
|
|
10219
10395
|
/** Spec for pointwise metric result. This data type is not supported in Gemini API. */
|
|
@@ -10381,21 +10557,21 @@ export declare interface RagRetrievalConfig {
|
|
|
10381
10557
|
*/
|
|
10382
10558
|
declare type RagRetrievalConfig_2 = {
|
|
10383
10559
|
/**
|
|
10384
|
-
*
|
|
10560
|
+
* Config for filters.
|
|
10385
10561
|
*/
|
|
10386
|
-
|
|
10562
|
+
filter?: Filter | undefined;
|
|
10387
10563
|
/**
|
|
10388
10564
|
* Config for Hybrid Search.
|
|
10389
10565
|
*/
|
|
10390
10566
|
hybrid_search?: HybridSearch | undefined;
|
|
10391
|
-
/**
|
|
10392
|
-
* Config for filters.
|
|
10393
|
-
*/
|
|
10394
|
-
filter?: Filter | undefined;
|
|
10395
10567
|
/**
|
|
10396
10568
|
* Config for Rank Service.
|
|
10397
10569
|
*/
|
|
10398
10570
|
ranking?: Ranking | undefined;
|
|
10571
|
+
/**
|
|
10572
|
+
* Optional. The number of contexts to retrieve.
|
|
10573
|
+
*/
|
|
10574
|
+
top_k?: number | undefined;
|
|
10399
10575
|
};
|
|
10400
10576
|
|
|
10401
10577
|
/** Config for filters. This data type is not supported in Gemini API. */
|
|
@@ -10442,6 +10618,10 @@ declare type RagStoreConfig = {
|
|
|
10442
10618
|
* Optional. The representation of the rag source.
|
|
10443
10619
|
*/
|
|
10444
10620
|
rag_resources?: Array<RagResource> | undefined;
|
|
10621
|
+
/**
|
|
10622
|
+
* Specifies the context retrieval config.
|
|
10623
|
+
*/
|
|
10624
|
+
rag_retrieval_config?: RagRetrievalConfig_2 | undefined;
|
|
10445
10625
|
/**
|
|
10446
10626
|
* Optional. Number of top k results to return from the selected corpora.
|
|
10447
10627
|
*
|
|
@@ -10454,10 +10634,6 @@ declare type RagStoreConfig = {
|
|
|
10454
10634
|
* @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
10455
10635
|
*/
|
|
10456
10636
|
vector_distance_threshold?: number | undefined;
|
|
10457
|
-
/**
|
|
10458
|
-
* Specifies the context retrieval config.
|
|
10459
|
-
*/
|
|
10460
|
-
rag_retrieval_config?: RagRetrievalConfig_2 | undefined;
|
|
10461
10637
|
};
|
|
10462
10638
|
|
|
10463
10639
|
/**
|
|
@@ -10471,11 +10647,11 @@ declare type RagStoreConfig = {
|
|
|
10471
10647
|
* Config for Rank Service.
|
|
10472
10648
|
*/
|
|
10473
10649
|
declare type Ranking = {
|
|
10474
|
-
ranking_config: "rank_service";
|
|
10475
10650
|
/**
|
|
10476
10651
|
* Optional. The model name of the rank service.
|
|
10477
10652
|
*/
|
|
10478
10653
|
model_name?: string | undefined;
|
|
10654
|
+
ranking_config: "rank_service";
|
|
10479
10655
|
};
|
|
10480
10656
|
|
|
10481
10657
|
/** Raw output. This data type is not supported in Gemini API. */
|
|
@@ -10639,39 +10815,39 @@ export declare class RegisterFilesResponse {
|
|
|
10639
10815
|
export declare interface ReinforcementTuningAutoraterScorer {
|
|
10640
10816
|
/** Autorater config for evaluation. */
|
|
10641
10817
|
autoraterConfig?: AutoraterConfig;
|
|
10642
|
-
/**
|
|
10818
|
+
/** 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}} */
|
|
10643
10819
|
autoraterPrompt?: string;
|
|
10644
|
-
/** Parses autorater returned response. */
|
|
10820
|
+
/** 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"`. */
|
|
10645
10821
|
autoraterResponseParseConfig?: ReinforcementTuningParseResponseConfig;
|
|
10646
|
-
/** Scores autorater responses by directly converting parsed autorater response to float reward. */
|
|
10822
|
+
/** 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)`. */
|
|
10647
10823
|
parsedResponseConversionScorer?: ReinforcementTuningAutoraterScorerParsedResponseConversionScorer;
|
|
10648
|
-
/** Scores autorater responses by using
|
|
10824
|
+
/** Scores autorater responses by using string match reward scorer. */
|
|
10649
10825
|
exactMatchScorer?: ReinforcementTuningAutoraterScorerExactMatchScorer;
|
|
10650
10826
|
}
|
|
10651
10827
|
|
|
10652
|
-
/** Scores autorater responses by using exact string match reward scorer. */
|
|
10828
|
+
/** Scores autorater responses by using exact string match reward scorer. This data type is not supported in Gemini API. */
|
|
10653
10829
|
export declare interface ReinforcementTuningAutoraterScorerExactMatchScorer {
|
|
10654
|
-
/** Assigns this reward score if parsed response string equals the expression. */
|
|
10830
|
+
/** Assigns this reward score if the parsed response string equals the expression. */
|
|
10655
10831
|
correctAnswerReward?: number;
|
|
10656
|
-
/** Assigns this reward score if parsed reward value does not equal the expression. */
|
|
10832
|
+
/** Assigns this reward score if the parsed reward value does not equal the expression. */
|
|
10657
10833
|
wrongAnswerReward?: number;
|
|
10658
|
-
/** The string expression to match against.
|
|
10834
|
+
/** 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`. */
|
|
10659
10835
|
expression?: string;
|
|
10660
10836
|
}
|
|
10661
10837
|
|
|
10662
|
-
/** Scores responses by directly converting parsed autorater response to float reward
|
|
10838
|
+
/** 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. */
|
|
10663
10839
|
export declare class ReinforcementTuningAutoraterScorerParsedResponseConversionScorer {
|
|
10664
10840
|
}
|
|
10665
10841
|
|
|
10666
|
-
/**
|
|
10842
|
+
/** 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. */
|
|
10667
10843
|
export declare interface ReinforcementTuningCloudRunRewardScorer {
|
|
10668
|
-
/** URI of the Cloud Run service that will be used to compute the reward. The Vertex AI Secure Fine Tuning Service Agent (`service
|
|
10844
|
+
/** 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. */
|
|
10669
10845
|
cloudRunUri?: string;
|
|
10670
10846
|
}
|
|
10671
10847
|
|
|
10672
|
-
/**
|
|
10848
|
+
/** 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. */
|
|
10673
10849
|
export declare interface ReinforcementTuningCodeExecutionRewardScorer {
|
|
10674
|
-
/**
|
|
10850
|
+
/** 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)`. */
|
|
10675
10851
|
pythonCodeSnippet?: string;
|
|
10676
10852
|
}
|
|
10677
10853
|
|
|
@@ -10681,37 +10857,39 @@ export declare interface ReinforcementTuningExample {
|
|
|
10681
10857
|
contents?: Content[];
|
|
10682
10858
|
/** References for the given prompt. The key is the name of the reference, and the value is the reference itself. */
|
|
10683
10859
|
references?: Record<string, string>;
|
|
10684
|
-
/** Corresponds to
|
|
10860
|
+
/** Corresponds to system_instruction in user-facing GenerateContentRequest. */
|
|
10685
10861
|
systemInstruction?: Content;
|
|
10686
10862
|
}
|
|
10687
10863
|
|
|
10688
10864
|
/** Hyperparameters for Reinforcement Tuning. */
|
|
10689
10865
|
export declare interface ReinforcementTuningHyperParameters {
|
|
10690
|
-
/** Number of training
|
|
10866
|
+
/** Optional. Number of training epoches for the tuning job. */
|
|
10691
10867
|
epochCount?: string;
|
|
10692
10868
|
/** Learning rate multiplier for Reinforcement Learning. */
|
|
10693
10869
|
learningRateMultiplier?: number;
|
|
10694
|
-
/** Adapter size for Reinforcement Tuning. */
|
|
10870
|
+
/** Optional. Adapter size for Reinforcement Tuning. */
|
|
10695
10871
|
adapterSize?: AdapterSize;
|
|
10696
|
-
/** Number of different responses to generate per prompt during tuning. */
|
|
10872
|
+
/** Optional. Number of different responses to generate per prompt during tuning. */
|
|
10697
10873
|
samplesPerPrompt?: number;
|
|
10698
|
-
/** 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. */
|
|
10874
|
+
/** 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. */
|
|
10699
10875
|
batchSize?: number;
|
|
10700
|
-
/** How often
|
|
10876
|
+
/** 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` */
|
|
10701
10877
|
evaluateInterval?: number;
|
|
10702
|
-
/** How often
|
|
10878
|
+
/** 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``` */
|
|
10703
10879
|
checkpointInterval?: number;
|
|
10704
|
-
/** The maximum number of tokens to generate per prompt.
|
|
10880
|
+
/** Optional. The maximum number of tokens to generate per prompt. Default to 32768. */
|
|
10705
10881
|
maxOutputTokens?: number;
|
|
10706
|
-
/** Indicates the maximum thinking depth.
|
|
10882
|
+
/** 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. */
|
|
10707
10883
|
thinkingLevel?: ReinforcementTuningThinkingLevel;
|
|
10884
|
+
/** 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). */
|
|
10885
|
+
thinkingBudget?: number;
|
|
10708
10886
|
}
|
|
10709
10887
|
|
|
10710
|
-
/** Defines how to parse sample response for reinforcement tuning. */
|
|
10888
|
+
/** 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. */
|
|
10711
10889
|
export declare class ReinforcementTuningParseResponseConfig {
|
|
10712
|
-
/** Defines
|
|
10890
|
+
/** Defines the type for parsing sample response. */
|
|
10713
10891
|
parseType?: ResponseParseType;
|
|
10714
|
-
/** Defines the regex
|
|
10892
|
+
/** Defines the regex for extracting the important part of sample response. This field is only used when parse_type is ResponseParseType.REGEX_EXTRACT. */
|
|
10715
10893
|
regexExtractExpression?: string;
|
|
10716
10894
|
}
|
|
10717
10895
|
|
|
@@ -10719,16 +10897,17 @@ export declare class ReinforcementTuningParseResponseConfig {
|
|
|
10719
10897
|
export declare interface ReinforcementTuningRewardInfo {
|
|
10720
10898
|
/** Output only. The calculated reward for the reward function. */
|
|
10721
10899
|
reward?: number;
|
|
10722
|
-
/** Output only. The user-requested auxiliary info for the reward function. */
|
|
10900
|
+
/** 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. */
|
|
10723
10901
|
userRequestedAuxInfo?: string;
|
|
10724
10902
|
}
|
|
10725
10903
|
|
|
10726
10904
|
/** Reinforcement tuning spec for tuning. */
|
|
10727
10905
|
export declare interface ReinforcementTuningSpec {
|
|
10906
|
+
/** Composite reward function configuration for reinforcement tuning. */
|
|
10728
10907
|
compositeRewardConfig?: CompositeReinforcementTuningRewardConfig;
|
|
10729
|
-
/** Cloud Storage path to file containing training dataset for tuning. The dataset must be formatted as a JSONL file. */
|
|
10908
|
+
/** Cloud Storage path to the file containing training dataset for tuning. The dataset must be formatted as a JSONL file. */
|
|
10730
10909
|
trainingDatasetUri?: string;
|
|
10731
|
-
/** Cloud Storage path to file containing validation dataset for tuning. The dataset must be formatted as a JSONL file.
|
|
10910
|
+
/** Cloud Storage path to the file containing validation dataset for tuning. The dataset must be formatted as a JSONL file. */
|
|
10732
10911
|
validationDatasetUri?: string;
|
|
10733
10912
|
/** Additional hyper-parameters to use during tuning. */
|
|
10734
10913
|
hyperParameters?: ReinforcementTuningHyperParameters;
|
|
@@ -10736,11 +10915,11 @@ export declare interface ReinforcementTuningSpec {
|
|
|
10736
10915
|
singleRewardConfig?: SingleReinforcementTuningRewardConfig;
|
|
10737
10916
|
}
|
|
10738
10917
|
|
|
10739
|
-
/**
|
|
10918
|
+
/** 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. */
|
|
10740
10919
|
export declare interface ReinforcementTuningStringMatchRewardScorer {
|
|
10741
|
-
/** Wrong answer reward is returned if
|
|
10920
|
+
/** Wrong answer reward is returned if the parsed response is evaluated as `false`. All wrong answers get the same reward. */
|
|
10742
10921
|
wrongAnswerReward?: number;
|
|
10743
|
-
/** Correct answer
|
|
10922
|
+
/** Correct answer rewawrd is returned if the parsed response is evaluated as `true`. All correct answers get the same reward. */
|
|
10744
10923
|
correctAnswerReward?: number;
|
|
10745
10924
|
/** Uses string match expression to evaluate parsed response. */
|
|
10746
10925
|
stringMatchExpression?: ReinforcementTuningStringMatchRewardScorerStringMatchExpression;
|
|
@@ -10748,19 +10927,19 @@ export declare interface ReinforcementTuningStringMatchRewardScorer {
|
|
|
10748
10927
|
jsonMatchExpression?: ReinforcementTuningStringMatchRewardScorerJsonMatchExpression;
|
|
10749
10928
|
}
|
|
10750
10929
|
|
|
10751
|
-
/**
|
|
10930
|
+
/** 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. */
|
|
10752
10931
|
export declare interface ReinforcementTuningStringMatchRewardScorerJsonMatchExpression {
|
|
10753
|
-
/**
|
|
10932
|
+
/** The key name to find the value in the parsed response that's in JSON format. Only first-level key matching is supported. */
|
|
10754
10933
|
keyName?: string;
|
|
10755
|
-
/** String match expression to match against the value of
|
|
10934
|
+
/** String match expression to match against the extracted value from the JSON representation of the parsed response. */
|
|
10756
10935
|
valueStringMatchExpression?: ReinforcementTuningStringMatchRewardScorerStringMatchExpression;
|
|
10757
10936
|
}
|
|
10758
10937
|
|
|
10759
|
-
/** Evaluates parsed response using match type against expression. */
|
|
10938
|
+
/** 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. */
|
|
10760
10939
|
export declare interface ReinforcementTuningStringMatchRewardScorerStringMatchExpression {
|
|
10761
|
-
/** Match operation to use for
|
|
10940
|
+
/** Match operation to use for evaluating rewards. */
|
|
10762
10941
|
matchOperation?: MatchOperation;
|
|
10763
|
-
/**
|
|
10942
|
+
/** 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.*" } ``` */
|
|
10764
10943
|
expression?: string;
|
|
10765
10944
|
}
|
|
10766
10945
|
|
|
@@ -10780,6 +10959,12 @@ export declare enum ReinforcementTuningThinkingLevel {
|
|
|
10780
10959
|
HIGH = "HIGH"
|
|
10781
10960
|
}
|
|
10782
10961
|
|
|
10962
|
+
/** 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. */
|
|
10963
|
+
export declare interface ReinforcementTuningUserDatasetExamples {
|
|
10964
|
+
/** List of user datasset examples showing to user. */
|
|
10965
|
+
userDatasetExamples?: ReinforcementTuningExample[];
|
|
10966
|
+
}
|
|
10967
|
+
|
|
10783
10968
|
/** Represents a recorded session. */
|
|
10784
10969
|
export declare interface ReplayFile {
|
|
10785
10970
|
replayId?: string;
|
|
@@ -10819,6 +11004,17 @@ export declare interface ReplicatedVoiceConfig {
|
|
|
10819
11004
|
|
|
10820
11005
|
* @remarks Encoded as base64 string. */
|
|
10821
11006
|
voiceSampleAudio?: string;
|
|
11007
|
+
/** Recorded consent verifying ownership of the voice. This
|
|
11008
|
+
represents 16-bit signed little-endian wav data, with a 24kHz sampling
|
|
11009
|
+
rate.
|
|
11010
|
+
* @remarks Encoded as base64 string. */
|
|
11011
|
+
consentAudio?: string;
|
|
11012
|
+
/** Signature of a previously verified consent audio. This should be
|
|
11013
|
+
populated with a signature generated by the server for a previous
|
|
11014
|
+
request containing the consent_audio field. When provided, the
|
|
11015
|
+
signature is verified instead of the consent_audio field to reduce
|
|
11016
|
+
latency. Requests will fail if the signature is invalid or expired. */
|
|
11017
|
+
voiceConsentSignature?: VoiceConsentSignature;
|
|
10822
11018
|
}
|
|
10823
11019
|
|
|
10824
11020
|
declare type RequestOptions = {
|
|
@@ -10875,7 +11071,19 @@ export declare enum ResourceScope {
|
|
|
10875
11071
|
COLLECTION = "COLLECTION"
|
|
10876
11072
|
}
|
|
10877
11073
|
|
|
10878
|
-
|
|
11074
|
+
/** Configuration for the model to configure output formatting and delivery. This data type is not supported in Gemini API. */
|
|
11075
|
+
export declare class ResponseFormat {
|
|
11076
|
+
/** Audio output format. */
|
|
11077
|
+
audio?: AudioResponseFormat;
|
|
11078
|
+
/** Image output format. */
|
|
11079
|
+
image?: ImageResponseFormat;
|
|
11080
|
+
/** Text output format. */
|
|
11081
|
+
text?: TextResponseFormat;
|
|
11082
|
+
/** Video output format. */
|
|
11083
|
+
video?: VideoResponseFormat;
|
|
11084
|
+
}
|
|
11085
|
+
|
|
11086
|
+
declare type ResponseFormat_2 = AudioResponseFormat_2 | TextResponseFormat_2 | ImageResponseFormat_2 | VideoResponseFormat_2 | {
|
|
10879
11087
|
[k: string]: any;
|
|
10880
11088
|
};
|
|
10881
11089
|
|
|
@@ -10888,18 +11096,18 @@ declare type ResponseFormat = AudioResponseFormat | TextResponseFormat | ImageRe
|
|
|
10888
11096
|
*/
|
|
10889
11097
|
declare type ResponseModality = "text" | "image" | "audio" | "video" | "document" | (string & {});
|
|
10890
11098
|
|
|
10891
|
-
/** Defines
|
|
11099
|
+
/** Defines the type for parsing sample response. This enum is not supported in Gemini API. */
|
|
10892
11100
|
export declare enum ResponseParseType {
|
|
10893
11101
|
/**
|
|
10894
|
-
* Default value.
|
|
11102
|
+
* Default value. Fallback to IDENTITY
|
|
10895
11103
|
*/
|
|
10896
11104
|
RESPONSE_PARSE_TYPE_UNSPECIFIED = "RESPONSE_PARSE_TYPE_UNSPECIFIED",
|
|
10897
11105
|
/**
|
|
10898
|
-
*
|
|
11106
|
+
* Returns the sample response as is.
|
|
10899
11107
|
*/
|
|
10900
11108
|
IDENTITY = "IDENTITY",
|
|
10901
11109
|
/**
|
|
10902
|
-
*
|
|
11110
|
+
* 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.
|
|
10903
11111
|
*/
|
|
10904
11112
|
REGEX_EXTRACT = "REGEX_EXTRACT"
|
|
10905
11113
|
}
|
|
@@ -10928,29 +11136,77 @@ export declare interface Retrieval {
|
|
|
10928
11136
|
* A tool that can be used by the model to retrieve files.
|
|
10929
11137
|
*/
|
|
10930
11138
|
declare type Retrieval_2 = {
|
|
10931
|
-
|
|
11139
|
+
/**
|
|
11140
|
+
* Used to specify configuration for ExaAISearch.
|
|
11141
|
+
*/
|
|
11142
|
+
exa_ai_search_config?: ExaAISearchConfig | undefined;
|
|
11143
|
+
/**
|
|
11144
|
+
* Used to specify configuration for ParallelAISearch.
|
|
11145
|
+
*/
|
|
11146
|
+
parallel_ai_search_config?: ParallelAISearchConfig | undefined;
|
|
11147
|
+
/**
|
|
11148
|
+
* Use to specify configuration for RAG Store.
|
|
11149
|
+
*/
|
|
11150
|
+
rag_store_config?: RagStoreConfig | undefined;
|
|
10932
11151
|
/**
|
|
10933
11152
|
* The types of file retrieval to enable.
|
|
10934
11153
|
*/
|
|
10935
|
-
retrieval_types?: Array<
|
|
11154
|
+
retrieval_types?: Array<RetrievalRetrievalType> | undefined;
|
|
11155
|
+
type: "retrieval";
|
|
10936
11156
|
/**
|
|
10937
11157
|
* Used to specify configuration for VertexAISearch.
|
|
10938
11158
|
*/
|
|
10939
11159
|
vertex_ai_search_config?: VertexAISearchConfig | undefined;
|
|
11160
|
+
};
|
|
11161
|
+
|
|
11162
|
+
declare type RetrievalCallArguments$ = RetrievalCallArguments;
|
|
11163
|
+
|
|
11164
|
+
/**
|
|
11165
|
+
* @license
|
|
11166
|
+
* Copyright 2026 Google LLC
|
|
11167
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
11168
|
+
*
|
|
11169
|
+
* g3-prettier-ignore-file
|
|
11170
|
+
*/
|
|
11171
|
+
/**
|
|
11172
|
+
* The arguments to pass to Retrieval tools.
|
|
11173
|
+
*/
|
|
11174
|
+
declare type RetrievalCallArguments = {
|
|
10940
11175
|
/**
|
|
10941
|
-
*
|
|
11176
|
+
* Queries for Retrieval information.
|
|
10942
11177
|
*/
|
|
10943
|
-
|
|
11178
|
+
queries?: Array<string> | undefined;
|
|
11179
|
+
};
|
|
11180
|
+
|
|
11181
|
+
declare type RetrievalCallDelta$ = RetrievalCallDelta;
|
|
11182
|
+
|
|
11183
|
+
/**
|
|
11184
|
+
* Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search,
|
|
11185
|
+
*
|
|
11186
|
+
* @remarks
|
|
11187
|
+
* etc. RetrievalType decides which tool is used.
|
|
11188
|
+
*/
|
|
11189
|
+
declare type RetrievalCallDelta = {
|
|
10944
11190
|
/**
|
|
10945
|
-
*
|
|
11191
|
+
* The arguments to pass to Retrieval tools.
|
|
10946
11192
|
*/
|
|
10947
|
-
|
|
11193
|
+
arguments: RetrievalCallArguments;
|
|
10948
11194
|
/**
|
|
10949
|
-
*
|
|
11195
|
+
* The type of retrieval tools.
|
|
10950
11196
|
*/
|
|
10951
|
-
|
|
11197
|
+
retrieval_type?: RetrievalCallDeltaRetrievalType | undefined;
|
|
11198
|
+
/**
|
|
11199
|
+
* A signature hash for backend validation.
|
|
11200
|
+
*/
|
|
11201
|
+
signature?: string | undefined;
|
|
11202
|
+
type: "retrieval_call";
|
|
10952
11203
|
};
|
|
10953
11204
|
|
|
11205
|
+
/**
|
|
11206
|
+
* The type of retrieval tools.
|
|
11207
|
+
*/
|
|
11208
|
+
declare type RetrievalCallDeltaRetrievalType = "vertex_ai_search" | "rag_store" | "exa_ai_search" | "parallel_ai_search" | (string & {});
|
|
11209
|
+
|
|
10954
11210
|
/** Retrieval config. */
|
|
10955
11211
|
export declare interface RetrievalConfig {
|
|
10956
11212
|
/** The location of the user. */
|
|
@@ -10970,7 +11226,35 @@ export declare interface RetrievalMetadata {
|
|
|
10970
11226
|
googleSearchDynamicRetrievalScore?: number;
|
|
10971
11227
|
}
|
|
10972
11228
|
|
|
10973
|
-
declare type
|
|
11229
|
+
declare type RetrievalResultDelta$ = RetrievalResultDelta;
|
|
11230
|
+
|
|
11231
|
+
/**
|
|
11232
|
+
* @license
|
|
11233
|
+
* Copyright 2026 Google LLC
|
|
11234
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
11235
|
+
*
|
|
11236
|
+
* g3-prettier-ignore-file
|
|
11237
|
+
*/
|
|
11238
|
+
/**
|
|
11239
|
+
* Used by Vertex Retrieval tools such as Parallel AI, Exa AI, Vertex AI Search,
|
|
11240
|
+
*
|
|
11241
|
+
* @remarks
|
|
11242
|
+
* etc.
|
|
11243
|
+
* ToolResultDelta.type
|
|
11244
|
+
*/
|
|
11245
|
+
declare type RetrievalResultDelta = {
|
|
11246
|
+
/**
|
|
11247
|
+
* Whether the retrieval resulted in an error.
|
|
11248
|
+
*/
|
|
11249
|
+
is_error?: boolean | undefined;
|
|
11250
|
+
/**
|
|
11251
|
+
* A signature hash for backend validation.
|
|
11252
|
+
*/
|
|
11253
|
+
signature?: string | undefined;
|
|
11254
|
+
type: "retrieval_result";
|
|
11255
|
+
};
|
|
11256
|
+
|
|
11257
|
+
declare type RetrievalRetrievalType = "vertex_ai_search" | "rag_store" | "exa_ai_search" | "parallel_ai_search" | (string & {});
|
|
10974
11258
|
|
|
10975
11259
|
declare type RetryConfig = {
|
|
10976
11260
|
strategy: "none";
|
|
@@ -11005,6 +11289,10 @@ declare type ReviewSnippet$3 = ReviewSnippet;
|
|
|
11005
11289
|
* the features of a specific place in Google Maps.
|
|
11006
11290
|
*/
|
|
11007
11291
|
declare type ReviewSnippet = {
|
|
11292
|
+
/**
|
|
11293
|
+
* The ID of the review snippet.
|
|
11294
|
+
*/
|
|
11295
|
+
review_id?: string | undefined;
|
|
11008
11296
|
/**
|
|
11009
11297
|
* Title of the review.
|
|
11010
11298
|
*/
|
|
@@ -11013,10 +11301,6 @@ declare type ReviewSnippet = {
|
|
|
11013
11301
|
* A link that corresponds to the user review on Google Maps.
|
|
11014
11302
|
*/
|
|
11015
11303
|
url?: string | undefined;
|
|
11016
|
-
/**
|
|
11017
|
-
* The ID of the review snippet.
|
|
11018
|
-
*/
|
|
11019
|
-
review_id?: string | undefined;
|
|
11020
11304
|
};
|
|
11021
11305
|
|
|
11022
11306
|
/**
|
|
@@ -11121,6 +11405,8 @@ export declare interface SafetyRating {
|
|
|
11121
11405
|
severityScore?: number;
|
|
11122
11406
|
}
|
|
11123
11407
|
|
|
11408
|
+
declare type SafetySetting$ = SafetySetting_2;
|
|
11409
|
+
|
|
11124
11410
|
/** A safety setting that affects the safety-blocking behavior. A SafetySetting consists of a harm category and a threshold for that category. */
|
|
11125
11411
|
export declare interface SafetySetting {
|
|
11126
11412
|
/** Required. The harm category to be blocked. */
|
|
@@ -11131,10 +11417,38 @@ export declare interface SafetySetting {
|
|
|
11131
11417
|
threshold?: HarmBlockThreshold;
|
|
11132
11418
|
}
|
|
11133
11419
|
|
|
11134
|
-
/**
|
|
11135
|
-
|
|
11136
|
-
|
|
11137
|
-
|
|
11420
|
+
/**
|
|
11421
|
+
* A safety setting that affects the safety-blocking behavior.
|
|
11422
|
+
*
|
|
11423
|
+
* @remarks
|
|
11424
|
+
*
|
|
11425
|
+
* A SafetySetting consists of a
|
|
11426
|
+
* harm category and a
|
|
11427
|
+
* threshold for that
|
|
11428
|
+
* category.
|
|
11429
|
+
*/
|
|
11430
|
+
declare type SafetySetting_2 = {
|
|
11431
|
+
/**
|
|
11432
|
+
* Optional. The method for blocking content. If not specified, the default
|
|
11433
|
+
*
|
|
11434
|
+
* @remarks
|
|
11435
|
+
* behavior is to use the probability score.
|
|
11436
|
+
*/
|
|
11437
|
+
method?: Method | undefined;
|
|
11438
|
+
/**
|
|
11439
|
+
* Required. The threshold for blocking content. If the harm probability
|
|
11440
|
+
*
|
|
11441
|
+
* @remarks
|
|
11442
|
+
* exceeds this threshold, the content will be blocked.
|
|
11443
|
+
*/
|
|
11444
|
+
threshold: Threshold;
|
|
11445
|
+
type: HarmCategory_2;
|
|
11446
|
+
};
|
|
11447
|
+
|
|
11448
|
+
/** Scale of the generated music. */
|
|
11449
|
+
export declare enum Scale {
|
|
11450
|
+
/**
|
|
11451
|
+
* Default value. This value is unused.
|
|
11138
11452
|
*/
|
|
11139
11453
|
SCALE_UNSPECIFIED = "SCALE_UNSPECIFIED",
|
|
11140
11454
|
/**
|
|
@@ -11411,6 +11725,7 @@ declare type ServiceTier_2 = "flex" | "standard" | "priority" | (string & {});
|
|
|
11411
11725
|
export declare class Session {
|
|
11412
11726
|
readonly conn: WebSocket_2;
|
|
11413
11727
|
private readonly apiClient;
|
|
11728
|
+
setupComplete?: types.LiveServerSetupComplete;
|
|
11414
11729
|
constructor(conn: WebSocket_2, apiClient: ApiClient);
|
|
11415
11730
|
private tLiveClientContent;
|
|
11416
11731
|
private tLiveClienttToolResponse;
|
|
@@ -11576,14 +11891,14 @@ declare type SigningSecret$ = SigningSecret;
|
|
|
11576
11891
|
* Represents a signing secret used to verify webhook payloads.
|
|
11577
11892
|
*/
|
|
11578
11893
|
declare type SigningSecret = {
|
|
11579
|
-
/**
|
|
11580
|
-
* Output only. The truncated version of the signing secret.
|
|
11581
|
-
*/
|
|
11582
|
-
truncated_secret?: string | undefined;
|
|
11583
11894
|
/**
|
|
11584
11895
|
* Output only. The expiration date of the signing secret.
|
|
11585
11896
|
*/
|
|
11586
11897
|
expire_time?: string | undefined;
|
|
11898
|
+
/**
|
|
11899
|
+
* Output only. The truncated version of the signing secret.
|
|
11900
|
+
*/
|
|
11901
|
+
truncated_secret?: string | undefined;
|
|
11587
11902
|
};
|
|
11588
11903
|
|
|
11589
11904
|
/** Config for `response` parameter. */
|
|
@@ -11600,15 +11915,15 @@ export declare class SingleEmbedContentResponse {
|
|
|
11600
11915
|
export declare interface SingleReinforcementTuningRewardConfig {
|
|
11601
11916
|
/** Scores parsed responses for autorater use cases by using a model to compute the reward. */
|
|
11602
11917
|
autoraterScorer?: ReinforcementTuningAutoraterScorer;
|
|
11603
|
-
/** A unique reward name
|
|
11918
|
+
/** A unique reward name for identifying each single reinforcement tuning reward. */
|
|
11604
11919
|
rewardName?: string;
|
|
11605
|
-
/** Defines how to parse sample response. */
|
|
11920
|
+
/** 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. */
|
|
11606
11921
|
parseResponseConfig?: ReinforcementTuningParseResponseConfig;
|
|
11607
|
-
/**
|
|
11922
|
+
/** ReinforcementTuningCodeExecutionRewardScorer is used to score parsed responses for code execution use cases. */
|
|
11608
11923
|
codeExecutionRewardScorer?: ReinforcementTuningCodeExecutionRewardScorer;
|
|
11609
|
-
/**
|
|
11924
|
+
/** ReinforcementTuningStringMatchRewardScorer is used to score parsed responses for simple string matching use cases against reference answers. */
|
|
11610
11925
|
stringMatchRewardScorer?: ReinforcementTuningStringMatchRewardScorer;
|
|
11611
|
-
/**
|
|
11926
|
+
/** ReinforcementTuningCloudRunRewardScorer is used to score parsed responses by calling a Cloud Run service. */
|
|
11612
11927
|
cloudRunRewardScorer?: ReinforcementTuningCloudRunRewardScorer;
|
|
11613
11928
|
}
|
|
11614
11929
|
|
|
@@ -11629,7 +11944,14 @@ declare type Source$ = Source;
|
|
|
11629
11944
|
* A source to be mounted into the environment.
|
|
11630
11945
|
*/
|
|
11631
11946
|
declare type Source = {
|
|
11632
|
-
|
|
11947
|
+
/**
|
|
11948
|
+
* The inline content if `type` is `INLINE`.
|
|
11949
|
+
*/
|
|
11950
|
+
content?: string | undefined;
|
|
11951
|
+
/**
|
|
11952
|
+
* Optional encoding for inline content (e.g. `base64`).
|
|
11953
|
+
*/
|
|
11954
|
+
encoding?: string | undefined;
|
|
11633
11955
|
/**
|
|
11634
11956
|
* The source of the environment.
|
|
11635
11957
|
*
|
|
@@ -11642,14 +11964,7 @@ declare type Source = {
|
|
|
11642
11964
|
* Where the source should appear in the environment.
|
|
11643
11965
|
*/
|
|
11644
11966
|
target?: string | undefined;
|
|
11645
|
-
|
|
11646
|
-
* The inline content if `type` is `INLINE`.
|
|
11647
|
-
*/
|
|
11648
|
-
content?: string | undefined;
|
|
11649
|
-
/**
|
|
11650
|
-
* Optional encoding for inline content (e.g. `base64`).
|
|
11651
|
-
*/
|
|
11652
|
-
encoding?: string | undefined;
|
|
11967
|
+
type?: SourceType | undefined;
|
|
11653
11968
|
};
|
|
11654
11969
|
|
|
11655
11970
|
/**
|
|
@@ -11692,10 +12007,6 @@ export declare interface SpeechConfig {
|
|
|
11692
12007
|
* The configuration for speech interaction.
|
|
11693
12008
|
*/
|
|
11694
12009
|
declare type SpeechConfig_2 = {
|
|
11695
|
-
/**
|
|
11696
|
-
* The voice of the speaker.
|
|
11697
|
-
*/
|
|
11698
|
-
voice?: string | undefined;
|
|
11699
12010
|
/**
|
|
11700
12011
|
* The language of the speech.
|
|
11701
12012
|
*/
|
|
@@ -11704,6 +12015,10 @@ declare type SpeechConfig_2 = {
|
|
|
11704
12015
|
* The speaker's name, it should match the speaker name given in the prompt.
|
|
11705
12016
|
*/
|
|
11706
12017
|
speaker?: string | undefined;
|
|
12018
|
+
/**
|
|
12019
|
+
* The voice of the speaker.
|
|
12020
|
+
*/
|
|
12021
|
+
voice?: string | undefined;
|
|
11707
12022
|
};
|
|
11708
12023
|
|
|
11709
12024
|
export declare type SpeechConfigUnion = SpeechConfig | string;
|
|
@@ -11754,14 +12069,6 @@ declare type Status = {
|
|
|
11754
12069
|
* The status code, which should be an enum value of google.rpc.Code.
|
|
11755
12070
|
*/
|
|
11756
12071
|
code?: number | undefined;
|
|
11757
|
-
/**
|
|
11758
|
-
* A developer-facing error message, which should be in English. Any
|
|
11759
|
-
*
|
|
11760
|
-
* @remarks
|
|
11761
|
-
* user-facing error message should be localized and sent in the
|
|
11762
|
-
* google.rpc.Status.details field, or localized by the client.
|
|
11763
|
-
*/
|
|
11764
|
-
message?: string | undefined;
|
|
11765
12072
|
/**
|
|
11766
12073
|
* A list of messages that carry the error details. There is a common set of
|
|
11767
12074
|
*
|
|
@@ -11771,6 +12078,14 @@ declare type Status = {
|
|
|
11771
12078
|
details?: Array<{
|
|
11772
12079
|
[k: string]: any;
|
|
11773
12080
|
}> | undefined;
|
|
12081
|
+
/**
|
|
12082
|
+
* A developer-facing error message, which should be in English. Any
|
|
12083
|
+
*
|
|
12084
|
+
* @remarks
|
|
12085
|
+
* user-facing error message should be localized and sent in the
|
|
12086
|
+
* google.rpc.Status.details field, or localized by the client.
|
|
12087
|
+
*/
|
|
12088
|
+
message?: string | undefined;
|
|
11774
12089
|
};
|
|
11775
12090
|
|
|
11776
12091
|
declare type Step$ = Step;
|
|
@@ -11783,8 +12098,6 @@ declare type Step = UserInputStep | ModelOutputStep | ThoughtStep | FunctionCall
|
|
|
11783
12098
|
declare type StepDelta$ = StepDelta;
|
|
11784
12099
|
|
|
11785
12100
|
declare type StepDelta = {
|
|
11786
|
-
event_type: "step.delta";
|
|
11787
|
-
index: number;
|
|
11788
12101
|
delta: StepDeltaData;
|
|
11789
12102
|
/**
|
|
11790
12103
|
* The event_id token to be used to resume the interaction stream, from
|
|
@@ -11793,13 +12106,15 @@ declare type StepDelta = {
|
|
|
11793
12106
|
* this event.
|
|
11794
12107
|
*/
|
|
11795
12108
|
event_id?: string | undefined;
|
|
12109
|
+
event_type: "step.delta";
|
|
12110
|
+
index: number;
|
|
11796
12111
|
/**
|
|
11797
12112
|
* Optional metadata accompanying ANY streamed event.
|
|
11798
12113
|
*/
|
|
11799
12114
|
metadata?: StepDeltaMetadata | undefined;
|
|
11800
12115
|
};
|
|
11801
12116
|
|
|
11802
|
-
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;
|
|
12117
|
+
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;
|
|
11803
12118
|
|
|
11804
12119
|
/**
|
|
11805
12120
|
* Optional metadata accompanying ANY streamed event.
|
|
@@ -11814,12 +12129,6 @@ declare type StepDeltaMetadata = {
|
|
|
11814
12129
|
declare type StepStart$ = StepStart;
|
|
11815
12130
|
|
|
11816
12131
|
declare type StepStart = {
|
|
11817
|
-
event_type: "step.start";
|
|
11818
|
-
index: number;
|
|
11819
|
-
/**
|
|
11820
|
-
* A step in the interaction.
|
|
11821
|
-
*/
|
|
11822
|
-
step: Step;
|
|
11823
12132
|
/**
|
|
11824
12133
|
* The event_id token to be used to resume the interaction stream, from
|
|
11825
12134
|
*
|
|
@@ -11827,22 +12136,18 @@ declare type StepStart = {
|
|
|
11827
12136
|
* this event.
|
|
11828
12137
|
*/
|
|
11829
12138
|
event_id?: string | undefined;
|
|
12139
|
+
event_type: "step.start";
|
|
12140
|
+
index: number;
|
|
11830
12141
|
metadata?: StreamMetadata | undefined;
|
|
12142
|
+
/**
|
|
12143
|
+
* A step in the interaction.
|
|
12144
|
+
*/
|
|
12145
|
+
step: Step;
|
|
11831
12146
|
};
|
|
11832
12147
|
|
|
11833
12148
|
declare type StepStop$ = StepStop;
|
|
11834
12149
|
|
|
11835
12150
|
declare type StepStop = {
|
|
11836
|
-
event_type: "step.stop";
|
|
11837
|
-
index: number;
|
|
11838
|
-
/**
|
|
11839
|
-
* Statistics on the interaction request's token usage.
|
|
11840
|
-
*/
|
|
11841
|
-
usage?: Usage | undefined;
|
|
11842
|
-
/**
|
|
11843
|
-
* Statistics on the interaction request's token usage.
|
|
11844
|
-
*/
|
|
11845
|
-
step_usage?: Usage | undefined;
|
|
11846
12151
|
/**
|
|
11847
12152
|
* The event_id token to be used to resume the interaction stream, from
|
|
11848
12153
|
*
|
|
@@ -11850,7 +12155,17 @@ declare type StepStop = {
|
|
|
11850
12155
|
* this event.
|
|
11851
12156
|
*/
|
|
11852
12157
|
event_id?: string | undefined;
|
|
12158
|
+
event_type: "step.stop";
|
|
12159
|
+
index: number;
|
|
11853
12160
|
metadata?: StreamMetadata | undefined;
|
|
12161
|
+
/**
|
|
12162
|
+
* Statistics on the interaction request's token usage.
|
|
12163
|
+
*/
|
|
12164
|
+
step_usage?: Usage | undefined;
|
|
12165
|
+
/**
|
|
12166
|
+
* Statistics on the interaction request's token usage.
|
|
12167
|
+
*/
|
|
12168
|
+
usage?: Usage | undefined;
|
|
11854
12169
|
};
|
|
11855
12170
|
|
|
11856
12171
|
export declare class Stream<T> extends ReadableStream<T> {
|
|
@@ -12102,11 +12417,11 @@ declare type Text$ = TextDelta;
|
|
|
12102
12417
|
declare type TextAnnotationDelta$ = TextAnnotationDelta;
|
|
12103
12418
|
|
|
12104
12419
|
declare type TextAnnotationDelta = {
|
|
12105
|
-
type: "text_annotation_delta";
|
|
12106
12420
|
/**
|
|
12107
12421
|
* Citation information for model-generated content.
|
|
12108
12422
|
*/
|
|
12109
12423
|
annotations?: Array<Annotation> | undefined;
|
|
12424
|
+
type: "text_annotation_delta";
|
|
12110
12425
|
};
|
|
12111
12426
|
|
|
12112
12427
|
declare type TextContent$ = TextContent;
|
|
@@ -12115,15 +12430,15 @@ declare type TextContent$ = TextContent;
|
|
|
12115
12430
|
* A text content block.
|
|
12116
12431
|
*/
|
|
12117
12432
|
declare type TextContent = {
|
|
12118
|
-
type: "text";
|
|
12119
|
-
/**
|
|
12120
|
-
* Required. The text content.
|
|
12121
|
-
*/
|
|
12122
|
-
text: string;
|
|
12123
12433
|
/**
|
|
12124
12434
|
* Citation information for model-generated content.
|
|
12125
12435
|
*/
|
|
12126
12436
|
annotations?: Array<Annotation> | undefined;
|
|
12437
|
+
/**
|
|
12438
|
+
* Required. The text content.
|
|
12439
|
+
*/
|
|
12440
|
+
text: string;
|
|
12441
|
+
type: "text";
|
|
12127
12442
|
};
|
|
12128
12443
|
|
|
12129
12444
|
/**
|
|
@@ -12134,17 +12449,24 @@ declare type TextContent = {
|
|
|
12134
12449
|
* g3-prettier-ignore-file
|
|
12135
12450
|
*/
|
|
12136
12451
|
declare type TextDelta = {
|
|
12137
|
-
type: "text";
|
|
12138
12452
|
text: string;
|
|
12453
|
+
type: "text";
|
|
12139
12454
|
};
|
|
12140
12455
|
|
|
12141
|
-
declare type TextResponseFormat$ =
|
|
12456
|
+
declare type TextResponseFormat$ = TextResponseFormat_2;
|
|
12457
|
+
|
|
12458
|
+
/** Configuration for text-specific output formatting. */
|
|
12459
|
+
export declare class TextResponseFormat {
|
|
12460
|
+
/** Optional. The IANA standard MIME type of the response. */
|
|
12461
|
+
mimeType?: string;
|
|
12462
|
+
/** Optional. The JSON schema that the output should conform to. Only applicable when mime_type is APPLICATION_JSON. */
|
|
12463
|
+
schema?: unknown;
|
|
12464
|
+
}
|
|
12142
12465
|
|
|
12143
12466
|
/**
|
|
12144
12467
|
* Configuration for text output format.
|
|
12145
12468
|
*/
|
|
12146
|
-
declare type
|
|
12147
|
-
type: "text";
|
|
12469
|
+
declare type TextResponseFormat_2 = {
|
|
12148
12470
|
/**
|
|
12149
12471
|
* The MIME type of the text output.
|
|
12150
12472
|
*/
|
|
@@ -12158,6 +12480,7 @@ declare type TextResponseFormat = {
|
|
|
12158
12480
|
schema?: {
|
|
12159
12481
|
[k: string]: any;
|
|
12160
12482
|
} | undefined;
|
|
12483
|
+
type: "text";
|
|
12161
12484
|
};
|
|
12162
12485
|
|
|
12163
12486
|
/**
|
|
@@ -12238,11 +12561,11 @@ declare type ThoughtSignature$ = ThoughtSignatureDelta;
|
|
|
12238
12561
|
* g3-prettier-ignore-file
|
|
12239
12562
|
*/
|
|
12240
12563
|
declare type ThoughtSignatureDelta = {
|
|
12241
|
-
type: "thought_signature";
|
|
12242
12564
|
/**
|
|
12243
12565
|
* Signature to match the backend source to be part of the generation.
|
|
12244
12566
|
*/
|
|
12245
12567
|
signature?: string | undefined;
|
|
12568
|
+
type: "thought_signature";
|
|
12246
12569
|
};
|
|
12247
12570
|
|
|
12248
12571
|
declare type ThoughtStep$ = ThoughtStep;
|
|
@@ -12251,7 +12574,6 @@ declare type ThoughtStep$ = ThoughtStep;
|
|
|
12251
12574
|
* A thought step.
|
|
12252
12575
|
*/
|
|
12253
12576
|
declare type ThoughtStep = {
|
|
12254
|
-
type: "thought";
|
|
12255
12577
|
/**
|
|
12256
12578
|
* A signature hash for backend validation.
|
|
12257
12579
|
*/
|
|
@@ -12260,6 +12582,7 @@ declare type ThoughtStep = {
|
|
|
12260
12582
|
* A summary of the thought.
|
|
12261
12583
|
*/
|
|
12262
12584
|
summary?: Array<ThoughtSummaryContent> | undefined;
|
|
12585
|
+
type: "thought";
|
|
12263
12586
|
};
|
|
12264
12587
|
|
|
12265
12588
|
declare type ThoughtSummary$ = ThoughtSummaryDelta;
|
|
@@ -12267,13 +12590,21 @@ declare type ThoughtSummary$ = ThoughtSummaryDelta;
|
|
|
12267
12590
|
declare type ThoughtSummaryContent = TextContent | ImageContent;
|
|
12268
12591
|
|
|
12269
12592
|
declare type ThoughtSummaryDelta = {
|
|
12270
|
-
type: "thought_summary";
|
|
12271
12593
|
/**
|
|
12272
12594
|
* The content of the response.
|
|
12273
12595
|
*/
|
|
12274
12596
|
content?: Content_2 | undefined;
|
|
12597
|
+
type: "thought_summary";
|
|
12275
12598
|
};
|
|
12276
12599
|
|
|
12600
|
+
/**
|
|
12601
|
+
* Required. The threshold for blocking content. If the harm probability
|
|
12602
|
+
*
|
|
12603
|
+
* @remarks
|
|
12604
|
+
* exceeds this threshold, the content will be blocked.
|
|
12605
|
+
*/
|
|
12606
|
+
declare type Threshold = "block_low_and_above" | "block_medium_and_above" | "block_only_high" | "block_none" | "off" | (string & {});
|
|
12607
|
+
|
|
12277
12608
|
export declare class Tokens extends BaseModule {
|
|
12278
12609
|
private readonly apiClient;
|
|
12279
12610
|
constructor(apiClient: ApiClient);
|
|
@@ -12403,6 +12734,8 @@ export declare interface Tool {
|
|
|
12403
12734
|
urlContext?: UrlContext;
|
|
12404
12735
|
/** Optional. MCP Servers to connect to. This field is not supported in Vertex AI. */
|
|
12405
12736
|
mcpServers?: McpServer[];
|
|
12737
|
+
/** 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. */
|
|
12738
|
+
exaAiSearch?: ToolExaAiSearch;
|
|
12406
12739
|
}
|
|
12407
12740
|
|
|
12408
12741
|
/**
|
|
@@ -12467,6 +12800,14 @@ export declare interface ToolConfig {
|
|
|
12467
12800
|
includeServerSideToolInvocations?: boolean;
|
|
12468
12801
|
}
|
|
12469
12802
|
|
|
12803
|
+
/** ExaAiSearch tool type. A tool that uses the Exa.ai search engine for grounding. This data type is not supported in Gemini API. */
|
|
12804
|
+
export declare interface ToolExaAiSearch {
|
|
12805
|
+
/** Required. The API key for ExaAiSearch. */
|
|
12806
|
+
apiKey?: string;
|
|
12807
|
+
/** Optional. This field can be used to pass any parameter from the Exa.ai Search API. */
|
|
12808
|
+
customConfigs?: Record<string, unknown>;
|
|
12809
|
+
}
|
|
12810
|
+
|
|
12470
12811
|
export declare type ToolListUnion = ToolUnion[];
|
|
12471
12812
|
|
|
12472
12813
|
/** ParallelAiSearch tool type. A tool that uses the Parallel.ai search engine for grounding. This data type is not supported in Gemini API. */
|
|
@@ -12558,14 +12899,27 @@ export declare interface Transcription {
|
|
|
12558
12899
|
languageCode?: string;
|
|
12559
12900
|
}
|
|
12560
12901
|
|
|
12902
|
+
/**
|
|
12903
|
+
* @license
|
|
12904
|
+
* Copyright 2026 Google LLC
|
|
12905
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
12906
|
+
*
|
|
12907
|
+
* g3-prettier-ignore-file
|
|
12908
|
+
*/
|
|
12909
|
+
/**
|
|
12910
|
+
* 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.
|
|
12911
|
+
*/
|
|
12912
|
+
declare type Transform = {
|
|
12913
|
+
[k: string]: string;
|
|
12914
|
+
} | Array<{
|
|
12915
|
+
[k: string]: string;
|
|
12916
|
+
}>;
|
|
12917
|
+
|
|
12561
12918
|
/** Config for stream translation. */
|
|
12562
12919
|
export declare interface TranslationConfig {
|
|
12563
|
-
/** If true, the model will generate audio when the target language is
|
|
12564
|
-
spoken, essentially it will parrot the input. If false, we will not produce
|
|
12565
|
-
audio for the target language. */
|
|
12920
|
+
/** 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. */
|
|
12566
12921
|
echoTargetLanguage?: boolean;
|
|
12567
|
-
/** The target language for translation. Supported values are BCP-47
|
|
12568
|
-
language codes (e.g. "en", "es", "fr"). */
|
|
12922
|
+
/** Required. The target language for translation. Supported values are BCP-47 language codes (e.g. "en", "es", "fr"). */
|
|
12569
12923
|
targetLanguageCode?: string;
|
|
12570
12924
|
}
|
|
12571
12925
|
|
|
@@ -12633,6 +12987,8 @@ export declare interface TuningDataStats {
|
|
|
12633
12987
|
preferenceOptimizationDataStats?: PreferenceOptimizationDataStats;
|
|
12634
12988
|
/** The SFT Tuning data stats. */
|
|
12635
12989
|
supervisedTuningDataStats?: SupervisedTuningDataStats;
|
|
12990
|
+
/** Output only. Statistics for reinforcement tuning. */
|
|
12991
|
+
reinforcementTuningDataStats?: DatasetStats;
|
|
12636
12992
|
}
|
|
12637
12993
|
|
|
12638
12994
|
/** A single example for tuning. This data type is not supported in Vertex AI. */
|
|
@@ -12675,6 +13031,7 @@ export declare interface TuningJob {
|
|
|
12675
13031
|
preferenceOptimizationSpec?: PreferenceOptimizationSpec;
|
|
12676
13032
|
/** Tuning Spec for Distillation. */
|
|
12677
13033
|
distillationSpec?: DistillationSpec;
|
|
13034
|
+
/** Tuning Spec for Reinforcement Tuning. */
|
|
12678
13035
|
reinforcementTuningSpec?: ReinforcementTuningSpec;
|
|
12679
13036
|
/** Output only. The tuning data statistics associated with this TuningJob. */
|
|
12680
13037
|
tuningDataStats?: TuningDataStats;
|
|
@@ -12901,6 +13258,7 @@ export declare interface TuningValidationDataset {
|
|
|
12901
13258
|
* @deprecated class: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
12902
13259
|
*/
|
|
12903
13260
|
declare type Turn = {
|
|
13261
|
+
content?: Array<Content_2> | string | undefined;
|
|
12904
13262
|
/**
|
|
12905
13263
|
* The originator of this turn. Must be user for input or model for
|
|
12906
13264
|
*
|
|
@@ -12908,7 +13266,6 @@ declare type Turn = {
|
|
|
12908
13266
|
* model output.
|
|
12909
13267
|
*/
|
|
12910
13268
|
role?: string | undefined;
|
|
12911
|
-
content?: Array<Content_2> | string | undefined;
|
|
12912
13269
|
};
|
|
12913
13270
|
|
|
12914
13271
|
/** The reason why the turn is complete. */
|
|
@@ -13127,8 +13484,14 @@ declare namespace types {
|
|
|
13127
13484
|
ModelStage,
|
|
13128
13485
|
MediaResolution,
|
|
13129
13486
|
Modality,
|
|
13487
|
+
Delivery,
|
|
13488
|
+
AspectRatio,
|
|
13489
|
+
ImageSize,
|
|
13130
13490
|
TuningMode,
|
|
13131
13491
|
AdapterSize,
|
|
13492
|
+
ResponseParseType,
|
|
13493
|
+
MatchOperation,
|
|
13494
|
+
ReinforcementTuningThinkingLevel,
|
|
13132
13495
|
JobState,
|
|
13133
13496
|
TuningJobState,
|
|
13134
13497
|
AggregationMetric,
|
|
@@ -13154,9 +13517,6 @@ declare namespace types {
|
|
|
13154
13517
|
VideoGenerationMaskMode,
|
|
13155
13518
|
VideoCompressionQuality,
|
|
13156
13519
|
ImageResizeMode,
|
|
13157
|
-
ResponseParseType,
|
|
13158
|
-
MatchOperation,
|
|
13159
|
-
ReinforcementTuningThinkingLevel,
|
|
13160
13520
|
TuningMethod,
|
|
13161
13521
|
FileState,
|
|
13162
13522
|
FileSource,
|
|
@@ -13229,7 +13589,9 @@ declare namespace types {
|
|
|
13229
13589
|
UrlContext,
|
|
13230
13590
|
StreamableHttpTransport,
|
|
13231
13591
|
McpServer,
|
|
13592
|
+
ToolExaAiSearch,
|
|
13232
13593
|
Tool,
|
|
13594
|
+
VoiceConsentSignature,
|
|
13233
13595
|
ReplicatedVoiceConfig,
|
|
13234
13596
|
PrebuiltVoiceConfig,
|
|
13235
13597
|
VoiceConfig,
|
|
@@ -13334,6 +13696,12 @@ declare namespace types {
|
|
|
13334
13696
|
DeleteModelConfig,
|
|
13335
13697
|
DeleteModelParameters,
|
|
13336
13698
|
DeleteModelResponse,
|
|
13699
|
+
AudioResponseFormat,
|
|
13700
|
+
ImageResponseFormat,
|
|
13701
|
+
TextResponseFormat,
|
|
13702
|
+
VideoResponseFormat,
|
|
13703
|
+
ResponseFormat,
|
|
13704
|
+
TranslationConfig,
|
|
13337
13705
|
GenerationConfig,
|
|
13338
13706
|
CountTokensConfig,
|
|
13339
13707
|
CountTokensParameters,
|
|
@@ -13383,6 +13751,8 @@ declare namespace types {
|
|
|
13383
13751
|
PreTunedModel,
|
|
13384
13752
|
DatasetDistributionDistributionBucket,
|
|
13385
13753
|
DatasetDistribution,
|
|
13754
|
+
ReinforcementTuningExample,
|
|
13755
|
+
ReinforcementTuningUserDatasetExamples,
|
|
13386
13756
|
DatasetStats,
|
|
13387
13757
|
DistillationDataStats,
|
|
13388
13758
|
GeminiPreferenceExampleCompletion,
|
|
@@ -13428,7 +13798,6 @@ declare namespace types {
|
|
|
13428
13798
|
CreateTuningJobConfig,
|
|
13429
13799
|
CreateTuningJobParametersPrivate,
|
|
13430
13800
|
TuningOperation,
|
|
13431
|
-
ReinforcementTuningExample,
|
|
13432
13801
|
ValidateRewardConfig,
|
|
13433
13802
|
ValidateRewardParameters,
|
|
13434
13803
|
ReinforcementTuningRewardInfo,
|
|
@@ -13572,7 +13941,6 @@ declare namespace types {
|
|
|
13572
13941
|
LiveClientRealtimeInput,
|
|
13573
13942
|
LiveClientToolResponse,
|
|
13574
13943
|
LiveClientMessage,
|
|
13575
|
-
TranslationConfig,
|
|
13576
13944
|
LiveConnectConfig,
|
|
13577
13945
|
LiveConnectParameters,
|
|
13578
13946
|
CreateChatParameters,
|
|
@@ -13884,15 +14252,10 @@ declare type URLCitation$ = URLCitation;
|
|
|
13884
14252
|
* A URL citation annotation.
|
|
13885
14253
|
*/
|
|
13886
14254
|
declare type URLCitation = {
|
|
13887
|
-
type: "url_citation";
|
|
13888
|
-
/**
|
|
13889
|
-
* The URL.
|
|
13890
|
-
*/
|
|
13891
|
-
url?: string | undefined;
|
|
13892
14255
|
/**
|
|
13893
|
-
*
|
|
14256
|
+
* End of the attributed segment, exclusive.
|
|
13894
14257
|
*/
|
|
13895
|
-
|
|
14258
|
+
end_index?: number | undefined;
|
|
13896
14259
|
/**
|
|
13897
14260
|
* Start of segment of the response that is attributed to this source.
|
|
13898
14261
|
*
|
|
@@ -13902,9 +14265,14 @@ declare type URLCitation = {
|
|
|
13902
14265
|
*/
|
|
13903
14266
|
start_index?: number | undefined;
|
|
13904
14267
|
/**
|
|
13905
|
-
*
|
|
14268
|
+
* The title of the URL.
|
|
13906
14269
|
*/
|
|
13907
|
-
|
|
14270
|
+
title?: string | undefined;
|
|
14271
|
+
type: "url_citation";
|
|
14272
|
+
/**
|
|
14273
|
+
* The URL.
|
|
14274
|
+
*/
|
|
14275
|
+
url?: string | undefined;
|
|
13908
14276
|
};
|
|
13909
14277
|
|
|
13910
14278
|
declare type URLContext$ = URLContext;
|
|
@@ -13949,7 +14317,6 @@ declare type URLContextCallArguments = {
|
|
|
13949
14317
|
};
|
|
13950
14318
|
|
|
13951
14319
|
declare type URLContextCallDelta = {
|
|
13952
|
-
type: "url_context_call";
|
|
13953
14320
|
/**
|
|
13954
14321
|
* The arguments to pass to the URL context.
|
|
13955
14322
|
*/
|
|
@@ -13958,6 +14325,7 @@ declare type URLContextCallDelta = {
|
|
|
13958
14325
|
* A signature hash for backend validation.
|
|
13959
14326
|
*/
|
|
13960
14327
|
signature?: string | undefined;
|
|
14328
|
+
type: "url_context_call";
|
|
13961
14329
|
};
|
|
13962
14330
|
|
|
13963
14331
|
declare type URLContextCallStep$ = URLContextCallStep;
|
|
@@ -13966,7 +14334,10 @@ declare type URLContextCallStep$ = URLContextCallStep;
|
|
|
13966
14334
|
* URL context call step.
|
|
13967
14335
|
*/
|
|
13968
14336
|
declare type URLContextCallStep = {
|
|
13969
|
-
|
|
14337
|
+
/**
|
|
14338
|
+
* The arguments to pass to the URL context.
|
|
14339
|
+
*/
|
|
14340
|
+
arguments: URLContextCallArguments;
|
|
13970
14341
|
/**
|
|
13971
14342
|
* Required. A unique ID for this specific tool call.
|
|
13972
14343
|
*/
|
|
@@ -13975,10 +14346,7 @@ declare type URLContextCallStep = {
|
|
|
13975
14346
|
* A signature hash for backend validation.
|
|
13976
14347
|
*/
|
|
13977
14348
|
signature?: string | undefined;
|
|
13978
|
-
|
|
13979
|
-
* The arguments to pass to the URL context.
|
|
13980
|
-
*/
|
|
13981
|
-
arguments: Arguments;
|
|
14349
|
+
type: "url_context_call";
|
|
13982
14350
|
};
|
|
13983
14351
|
|
|
13984
14352
|
/** Metadata returned when the model uses the `url_context` tool to get information from a user-provided URL. */
|
|
@@ -13995,24 +14363,24 @@ declare type URLContextResult$2 = URLContextResultDelta;
|
|
|
13995
14363
|
* The result of the URL context.
|
|
13996
14364
|
*/
|
|
13997
14365
|
declare type URLContextResult = {
|
|
13998
|
-
/**
|
|
13999
|
-
* The URL that was fetched.
|
|
14000
|
-
*/
|
|
14001
|
-
url?: string | undefined;
|
|
14002
14366
|
/**
|
|
14003
14367
|
* The status of the URL retrieval.
|
|
14004
14368
|
*/
|
|
14005
14369
|
status?: URLContextResultStatus | undefined;
|
|
14370
|
+
/**
|
|
14371
|
+
* The URL that was fetched.
|
|
14372
|
+
*/
|
|
14373
|
+
url?: string | undefined;
|
|
14006
14374
|
};
|
|
14007
14375
|
|
|
14008
14376
|
declare type URLContextResultDelta = {
|
|
14009
|
-
type: "url_context_result";
|
|
14010
|
-
result: Array<URLContextResult>;
|
|
14011
14377
|
is_error?: boolean | undefined;
|
|
14378
|
+
result: Array<URLContextResult>;
|
|
14012
14379
|
/**
|
|
14013
14380
|
* A signature hash for backend validation.
|
|
14014
14381
|
*/
|
|
14015
14382
|
signature?: string | undefined;
|
|
14383
|
+
type: "url_context_result";
|
|
14016
14384
|
};
|
|
14017
14385
|
|
|
14018
14386
|
/**
|
|
@@ -14033,23 +14401,23 @@ declare type URLContextResultStep$ = URLContextResultStep;
|
|
|
14033
14401
|
* URL context result step.
|
|
14034
14402
|
*/
|
|
14035
14403
|
declare type URLContextResultStep = {
|
|
14036
|
-
type: "url_context_result";
|
|
14037
14404
|
/**
|
|
14038
|
-
* Required.
|
|
14405
|
+
* Required. ID to match the ID from the function call block.
|
|
14039
14406
|
*/
|
|
14040
|
-
|
|
14407
|
+
call_id: string;
|
|
14041
14408
|
/**
|
|
14042
14409
|
* Whether the URL context resulted in an error.
|
|
14043
14410
|
*/
|
|
14044
14411
|
is_error?: boolean | undefined;
|
|
14045
14412
|
/**
|
|
14046
|
-
* Required.
|
|
14413
|
+
* Required. The results of the URL context.
|
|
14047
14414
|
*/
|
|
14048
|
-
|
|
14415
|
+
result: Array<URLContextResult>;
|
|
14049
14416
|
/**
|
|
14050
14417
|
* A signature hash for backend validation.
|
|
14051
14418
|
*/
|
|
14052
14419
|
signature?: string | undefined;
|
|
14420
|
+
type: "url_context_result";
|
|
14053
14421
|
};
|
|
14054
14422
|
|
|
14055
14423
|
/** The metadata for a single URL retrieval. */
|
|
@@ -14091,37 +14459,37 @@ declare type Usage$ = Usage;
|
|
|
14091
14459
|
*/
|
|
14092
14460
|
declare type Usage = {
|
|
14093
14461
|
/**
|
|
14094
|
-
*
|
|
14462
|
+
* A breakdown of cached token usage by modality.
|
|
14095
14463
|
*/
|
|
14096
|
-
|
|
14464
|
+
cached_tokens_by_modality?: Array<ModalityTokens> | undefined;
|
|
14097
14465
|
/**
|
|
14098
|
-
*
|
|
14466
|
+
* Grounding tool count.
|
|
14099
14467
|
*/
|
|
14100
|
-
|
|
14468
|
+
grounding_tool_count?: Array<GroundingToolCount> | undefined;
|
|
14101
14469
|
/**
|
|
14102
|
-
*
|
|
14470
|
+
* A breakdown of input token usage by modality.
|
|
14103
14471
|
*/
|
|
14104
|
-
|
|
14472
|
+
input_tokens_by_modality?: Array<ModalityTokens> | undefined;
|
|
14105
14473
|
/**
|
|
14106
|
-
* A breakdown of
|
|
14474
|
+
* A breakdown of output token usage by modality.
|
|
14107
14475
|
*/
|
|
14108
|
-
|
|
14476
|
+
output_tokens_by_modality?: Array<ModalityTokens> | undefined;
|
|
14109
14477
|
/**
|
|
14110
|
-
*
|
|
14478
|
+
* A breakdown of tool-use token usage by modality.
|
|
14111
14479
|
*/
|
|
14112
|
-
|
|
14480
|
+
tool_use_tokens_by_modality?: Array<ModalityTokens> | undefined;
|
|
14113
14481
|
/**
|
|
14114
|
-
*
|
|
14482
|
+
* Number of tokens in the cached part of the prompt (the cached content).
|
|
14115
14483
|
*/
|
|
14116
|
-
|
|
14484
|
+
total_cached_tokens?: number | undefined;
|
|
14117
14485
|
/**
|
|
14118
|
-
* Number of tokens
|
|
14486
|
+
* Number of tokens in the prompt (context).
|
|
14119
14487
|
*/
|
|
14120
|
-
|
|
14488
|
+
total_input_tokens?: number | undefined;
|
|
14121
14489
|
/**
|
|
14122
|
-
*
|
|
14490
|
+
* Total number of tokens across all the generated responses.
|
|
14123
14491
|
*/
|
|
14124
|
-
|
|
14492
|
+
total_output_tokens?: number | undefined;
|
|
14125
14493
|
/**
|
|
14126
14494
|
* Number of tokens of thoughts for thinking models.
|
|
14127
14495
|
*/
|
|
@@ -14134,9 +14502,9 @@ declare type Usage = {
|
|
|
14134
14502
|
*/
|
|
14135
14503
|
total_tokens?: number | undefined;
|
|
14136
14504
|
/**
|
|
14137
|
-
*
|
|
14505
|
+
* Number of tokens present in tool-use prompt(s).
|
|
14138
14506
|
*/
|
|
14139
|
-
|
|
14507
|
+
total_tool_use_tokens?: number | undefined;
|
|
14140
14508
|
};
|
|
14141
14509
|
|
|
14142
14510
|
/** Usage metadata about response(s). */
|
|
@@ -14305,14 +14673,14 @@ declare type VertexAISearchConfig$ = VertexAISearchConfig;
|
|
|
14305
14673
|
* Used to specify configuration for VertexAISearch.
|
|
14306
14674
|
*/
|
|
14307
14675
|
declare type VertexAISearchConfig = {
|
|
14308
|
-
/**
|
|
14309
|
-
* Optional. Used to specify Vertex AI Search engine.
|
|
14310
|
-
*/
|
|
14311
|
-
engine?: string | undefined;
|
|
14312
14676
|
/**
|
|
14313
14677
|
* Optional. Used to specify Vertex AI Search datastores.
|
|
14314
14678
|
*/
|
|
14315
14679
|
datastores?: Array<string> | undefined;
|
|
14680
|
+
/**
|
|
14681
|
+
* Optional. Used to specify Vertex AI Search engine.
|
|
14682
|
+
*/
|
|
14683
|
+
engine?: string | undefined;
|
|
14316
14684
|
};
|
|
14317
14685
|
|
|
14318
14686
|
/** 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. */
|
|
@@ -14406,20 +14774,20 @@ declare type VideoContent$ = VideoContent;
|
|
|
14406
14774
|
* A video content block.
|
|
14407
14775
|
*/
|
|
14408
14776
|
declare type VideoContent = {
|
|
14409
|
-
type: "video";
|
|
14410
14777
|
/**
|
|
14411
14778
|
* The video content.
|
|
14412
14779
|
*/
|
|
14413
14780
|
data?: string | undefined;
|
|
14414
|
-
/**
|
|
14415
|
-
* The URI of the video.
|
|
14416
|
-
*/
|
|
14417
|
-
uri?: string | undefined;
|
|
14418
14781
|
/**
|
|
14419
14782
|
* The mime type of the video.
|
|
14420
14783
|
*/
|
|
14421
14784
|
mime_type?: VideoContentMimeType | undefined;
|
|
14422
14785
|
resolution?: MediaResolution_2 | undefined;
|
|
14786
|
+
type: "video";
|
|
14787
|
+
/**
|
|
14788
|
+
* The URI of the video.
|
|
14789
|
+
*/
|
|
14790
|
+
uri?: string | undefined;
|
|
14423
14791
|
};
|
|
14424
14792
|
|
|
14425
14793
|
/**
|
|
@@ -14428,11 +14796,11 @@ declare type VideoContent = {
|
|
|
14428
14796
|
declare type VideoContentMimeType = "video/mp4" | "video/mpeg" | "video/mpg" | "video/mov" | "video/avi" | "video/x-flv" | "video/webm" | "video/wmv" | "video/3gpp" | (string & {});
|
|
14429
14797
|
|
|
14430
14798
|
declare type VideoDelta = {
|
|
14431
|
-
type: "video";
|
|
14432
14799
|
data?: string | undefined;
|
|
14433
|
-
uri?: string | undefined;
|
|
14434
14800
|
mime_type?: VideoDeltaMimeType | undefined;
|
|
14435
14801
|
resolution?: MediaResolution_2 | undefined;
|
|
14802
|
+
type: "video";
|
|
14803
|
+
uri?: string | undefined;
|
|
14436
14804
|
};
|
|
14437
14805
|
|
|
14438
14806
|
declare type VideoDeltaMimeType = "video/mp4" | "video/mpeg" | "video/mpg" | "video/mov" | "video/avi" | "video/x-flv" | "video/webm" | "video/wmv" | "video/3gpp" | (string & {});
|
|
@@ -14524,17 +14892,36 @@ export declare enum VideoOrientation {
|
|
|
14524
14892
|
PORTRAIT = "PORTRAIT"
|
|
14525
14893
|
}
|
|
14526
14894
|
|
|
14527
|
-
declare type VideoResponseFormat$ =
|
|
14895
|
+
declare type VideoResponseFormat$ = VideoResponseFormat_2;
|
|
14896
|
+
|
|
14897
|
+
/** Configuration for video-specific output formatting. This data type is not supported in Gemini API. */
|
|
14898
|
+
export declare class VideoResponseFormat {
|
|
14899
|
+
/** The aspect ratio for the video output. */
|
|
14900
|
+
aspectRatio?: AspectRatio;
|
|
14901
|
+
/** Optional. Delivery mode for the generated content. */
|
|
14902
|
+
delivery?: Delivery;
|
|
14903
|
+
/** Optional. The duration for the video output. */
|
|
14904
|
+
duration?: string;
|
|
14905
|
+
/** Optional. The Google Cloud Storage URI to store the video output. Required for Vertex if delivery is URI. */
|
|
14906
|
+
gcsUri?: string;
|
|
14907
|
+
}
|
|
14528
14908
|
|
|
14529
14909
|
/**
|
|
14530
14910
|
* Configuration for video output format.
|
|
14531
14911
|
*/
|
|
14532
|
-
declare type
|
|
14533
|
-
|
|
14912
|
+
declare type VideoResponseFormat_2 = {
|
|
14913
|
+
/**
|
|
14914
|
+
* The aspect ratio for the video output.
|
|
14915
|
+
*/
|
|
14916
|
+
aspect_ratio?: VideoResponseFormatAspectRatio | undefined;
|
|
14534
14917
|
/**
|
|
14535
14918
|
* The delivery mode for the video output.
|
|
14536
14919
|
*/
|
|
14537
14920
|
delivery?: VideoResponseFormatDelivery | undefined;
|
|
14921
|
+
/**
|
|
14922
|
+
* The duration for the video output.
|
|
14923
|
+
*/
|
|
14924
|
+
duration?: string | undefined;
|
|
14538
14925
|
/**
|
|
14539
14926
|
* The GCS URI to store the video output. Required for Vertex if delivery mode
|
|
14540
14927
|
*
|
|
@@ -14542,21 +14929,9 @@ declare type VideoResponseFormat = {
|
|
|
14542
14929
|
* is URI.
|
|
14543
14930
|
*/
|
|
14544
14931
|
gcs_uri?: string | undefined;
|
|
14545
|
-
|
|
14546
|
-
* The aspect ratio for the video output.
|
|
14547
|
-
*/
|
|
14548
|
-
aspect_ratio?: VideoResponseFormatAspectRatio | undefined;
|
|
14549
|
-
/**
|
|
14550
|
-
* The duration for the video output.
|
|
14551
|
-
*/
|
|
14552
|
-
duration?: string | undefined;
|
|
14932
|
+
type: "video";
|
|
14553
14933
|
};
|
|
14554
14934
|
|
|
14555
|
-
/**
|
|
14556
|
-
* The aspect ratio for the video output.
|
|
14557
|
-
*/
|
|
14558
|
-
declare type VideoResponseFormatAspectRatio = "16:9" | "9:16" | (string & {});
|
|
14559
|
-
|
|
14560
14935
|
/**
|
|
14561
14936
|
* @license
|
|
14562
14937
|
* Copyright 2026 Google LLC
|
|
@@ -14564,6 +14939,11 @@ declare type VideoResponseFormatAspectRatio = "16:9" | "9:16" | (string & {});
|
|
|
14564
14939
|
*
|
|
14565
14940
|
* g3-prettier-ignore-file
|
|
14566
14941
|
*/
|
|
14942
|
+
/**
|
|
14943
|
+
* The aspect ratio for the video output.
|
|
14944
|
+
*/
|
|
14945
|
+
declare type VideoResponseFormatAspectRatio = "16:9" | "9:16" | (string & {});
|
|
14946
|
+
|
|
14567
14947
|
/**
|
|
14568
14948
|
* The delivery mode for the video output.
|
|
14569
14949
|
*/
|
|
@@ -14613,20 +14993,43 @@ export declare interface VoiceConfig {
|
|
|
14613
14993
|
prebuiltVoiceConfig?: PrebuiltVoiceConfig;
|
|
14614
14994
|
}
|
|
14615
14995
|
|
|
14996
|
+
/** The signature of the voice consent check. */
|
|
14997
|
+
export declare interface VoiceConsentSignature {
|
|
14998
|
+
/** The signature string.
|
|
14999
|
+
*/
|
|
15000
|
+
signature?: string;
|
|
15001
|
+
}
|
|
15002
|
+
|
|
14616
15003
|
declare type Webhook$ = Webhook;
|
|
14617
15004
|
|
|
14618
15005
|
/**
|
|
14619
15006
|
* A Webhook resource.
|
|
14620
15007
|
*/
|
|
14621
15008
|
declare type Webhook = {
|
|
15009
|
+
/**
|
|
15010
|
+
* Output only. The timestamp when the webhook was created.
|
|
15011
|
+
*/
|
|
15012
|
+
create_time?: string | undefined;
|
|
15013
|
+
/**
|
|
15014
|
+
* Output only. The ID of the webhook.
|
|
15015
|
+
*/
|
|
15016
|
+
id?: string | undefined;
|
|
14622
15017
|
/**
|
|
14623
15018
|
* Optional. The user-provided name of the webhook.
|
|
14624
15019
|
*/
|
|
14625
15020
|
name?: string | undefined;
|
|
14626
15021
|
/**
|
|
14627
|
-
*
|
|
15022
|
+
* Output only. The new signing secret for the webhook. Only populated on create.
|
|
14628
15023
|
*/
|
|
14629
|
-
|
|
15024
|
+
new_signing_secret?: string | undefined;
|
|
15025
|
+
/**
|
|
15026
|
+
* Output only. The signing secrets associated with this webhook.
|
|
15027
|
+
*/
|
|
15028
|
+
signing_secrets?: Array<SigningSecret> | undefined;
|
|
15029
|
+
/**
|
|
15030
|
+
* Output only. The state of the webhook.
|
|
15031
|
+
*/
|
|
15032
|
+
state?: WebhookState | undefined;
|
|
14630
15033
|
/**
|
|
14631
15034
|
* Required. The events that the webhook is subscribed to.
|
|
14632
15035
|
*
|
|
@@ -14641,30 +15044,14 @@ declare type Webhook = {
|
|
|
14641
15044
|
* - video.generated
|
|
14642
15045
|
*/
|
|
14643
15046
|
subscribed_events: Array<WebhookSubscribedEvent>;
|
|
14644
|
-
/**
|
|
14645
|
-
* Output only. The timestamp when the webhook was created.
|
|
14646
|
-
*/
|
|
14647
|
-
create_time?: string | undefined;
|
|
14648
15047
|
/**
|
|
14649
15048
|
* Output only. The timestamp when the webhook was last updated.
|
|
14650
15049
|
*/
|
|
14651
15050
|
update_time?: string | undefined;
|
|
14652
15051
|
/**
|
|
14653
|
-
*
|
|
14654
|
-
*/
|
|
14655
|
-
signing_secrets?: Array<SigningSecret> | undefined;
|
|
14656
|
-
/**
|
|
14657
|
-
* Output only. The state of the webhook.
|
|
14658
|
-
*/
|
|
14659
|
-
state?: WebhookState | undefined;
|
|
14660
|
-
/**
|
|
14661
|
-
* Output only. The new signing secret for the webhook. Only populated on create.
|
|
14662
|
-
*/
|
|
14663
|
-
new_signing_secret?: string | undefined;
|
|
14664
|
-
/**
|
|
14665
|
-
* Output only. The ID of the webhook.
|
|
15052
|
+
* Required. The URI to which webhook events will be sent.
|
|
14666
15053
|
*/
|
|
14667
|
-
|
|
15054
|
+
uri: string;
|
|
14668
15055
|
};
|
|
14669
15056
|
|
|
14670
15057
|
declare type WebhookConfig$ = WebhookConfig_2;
|
|
@@ -14730,10 +15117,6 @@ declare type WebhookInput = {
|
|
|
14730
15117
|
* Optional. The user-provided name of the webhook.
|
|
14731
15118
|
*/
|
|
14732
15119
|
name?: string | undefined;
|
|
14733
|
-
/**
|
|
14734
|
-
* Required. The URI to which webhook events will be sent.
|
|
14735
|
-
*/
|
|
14736
|
-
uri: string;
|
|
14737
15120
|
/**
|
|
14738
15121
|
* Required. The events that the webhook is subscribed to.
|
|
14739
15122
|
*
|
|
@@ -14748,6 +15131,10 @@ declare type WebhookInput = {
|
|
|
14748
15131
|
* - video.generated
|
|
14749
15132
|
*/
|
|
14750
15133
|
subscribed_events: Array<WebhookSubscribedEvent>;
|
|
15134
|
+
/**
|
|
15135
|
+
* Required. The URI to which webhook events will be sent.
|
|
15136
|
+
*/
|
|
15137
|
+
uri: string;
|
|
14751
15138
|
};
|
|
14752
15139
|
|
|
14753
15140
|
declare type WebhookListParams$ = ListWebhooksParams;
|
|
@@ -14764,10 +15151,6 @@ declare type WebhookListResponse$ = WebhookListResponse;
|
|
|
14764
15151
|
* Response message for WebhookService.ListWebhooks.
|
|
14765
15152
|
*/
|
|
14766
15153
|
declare type WebhookListResponse = {
|
|
14767
|
-
/**
|
|
14768
|
-
* The webhooks.
|
|
14769
|
-
*/
|
|
14770
|
-
webhooks?: Array<Webhook> | undefined;
|
|
14771
15154
|
/**
|
|
14772
15155
|
* A token, which can be sent as `page_token` to retrieve the next page.
|
|
14773
15156
|
*
|
|
@@ -14775,6 +15158,10 @@ declare type WebhookListResponse = {
|
|
|
14775
15158
|
* If this field is omitted, there are no subsequent pages.
|
|
14776
15159
|
*/
|
|
14777
15160
|
next_page_token?: string | undefined;
|
|
15161
|
+
/**
|
|
15162
|
+
* The webhooks.
|
|
15163
|
+
*/
|
|
15164
|
+
webhooks?: Array<Webhook> | undefined;
|
|
14778
15165
|
};
|
|
14779
15166
|
|
|
14780
15167
|
declare type WebhookPingParams$ = PingWebhookRequest;
|
|
@@ -14852,11 +15239,11 @@ declare namespace webhooks {
|
|
|
14852
15239
|
WebhookListResponse,
|
|
14853
15240
|
WebhookPingResponse,
|
|
14854
15241
|
WebhookRotateSigningSecretResponse,
|
|
14855
|
-
WebhookUpdateSubscribedEvent,
|
|
14856
15242
|
WebhookUpdateState,
|
|
15243
|
+
WebhookUpdateSubscribedEvent,
|
|
14857
15244
|
WebhookUpdate,
|
|
14858
|
-
WebhookSubscribedEvent,
|
|
14859
15245
|
WebhookState,
|
|
15246
|
+
WebhookSubscribedEvent,
|
|
14860
15247
|
Webhook,
|
|
14861
15248
|
WebhookInput
|
|
14862
15249
|
}
|
|
@@ -14877,9 +15264,9 @@ declare type WebhookUpdate = {
|
|
|
14877
15264
|
*/
|
|
14878
15265
|
name?: string | undefined;
|
|
14879
15266
|
/**
|
|
14880
|
-
* Optional. The
|
|
15267
|
+
* Optional. The state of the webhook.
|
|
14881
15268
|
*/
|
|
14882
|
-
|
|
15269
|
+
state?: WebhookUpdateState | undefined;
|
|
14883
15270
|
/**
|
|
14884
15271
|
* Optional. The events that the webhook is subscribed to.
|
|
14885
15272
|
*
|
|
@@ -14895,9 +15282,9 @@ declare type WebhookUpdate = {
|
|
|
14895
15282
|
*/
|
|
14896
15283
|
subscribed_events?: Array<WebhookUpdateSubscribedEvent> | undefined;
|
|
14897
15284
|
/**
|
|
14898
|
-
* Optional. The
|
|
15285
|
+
* Optional. The URI to which webhook events will be sent.
|
|
14899
15286
|
*/
|
|
14900
|
-
|
|
15287
|
+
uri?: string | undefined;
|
|
14901
15288
|
};
|
|
14902
15289
|
|
|
14903
15290
|
declare type WebhookUpdateParams$ = WebhookUpdate;
|
|
@@ -14907,11 +15294,6 @@ declare type WebhookUpdateParams = {
|
|
|
14907
15294
|
update_mask?: string;
|
|
14908
15295
|
} & webhooks.WebhookUpdate;
|
|
14909
15296
|
|
|
14910
|
-
/**
|
|
14911
|
-
* Optional. The state of the webhook.
|
|
14912
|
-
*/
|
|
14913
|
-
declare type WebhookUpdateState = "enabled" | "disabled" | "disabled_due_to_failed_deliveries";
|
|
14914
|
-
|
|
14915
15297
|
/**
|
|
14916
15298
|
* @license
|
|
14917
15299
|
* Copyright 2026 Google LLC
|
|
@@ -14919,6 +15301,11 @@ declare type WebhookUpdateState = "enabled" | "disabled" | "disabled_due_to_fail
|
|
|
14919
15301
|
*
|
|
14920
15302
|
* g3-prettier-ignore-file
|
|
14921
15303
|
*/
|
|
15304
|
+
/**
|
|
15305
|
+
* Optional. The state of the webhook.
|
|
15306
|
+
*/
|
|
15307
|
+
declare type WebhookUpdateState = "enabled" | "disabled" | "disabled_due_to_failed_deliveries";
|
|
15308
|
+
|
|
14922
15309
|
declare type WebhookUpdateSubscribedEvent = "batch.succeeded" | "batch.expired" | "batch.failed" | "interaction.requires_action" | "interaction.completed" | "interaction.failed" | "video.generated" | (string & {});
|
|
14923
15310
|
|
|
14924
15311
|
/** Standard web search for grounding and related configurations. Only text results are returned. */
|