Response for InteractionService.CreateInteraction.
| JSON representation |
|---|
{ "id": string, "status": enum ( |
| Fields | |
|---|---|
id |
Required. Output only. A unique identifier for the interaction completion. |
status |
Required. Output only. The status of the interaction. |
created |
Required. Output only. The time at which the response was created in ISO 8601 format (YYYY-MM-DDThh:mm:ssZ). |
updated |
Required. Output only. The time at which the response was last updated in ISO 8601 format (YYYY-MM-DDThh:mm:ssZ). |
role |
Output only. The role of the interaction. |
outputs[] |
Output only. Responses from the model. |
systemInstruction |
System instruction for the interaction. |
tools[] |
A list of tool declarations the model may call during interaction. |
usage |
Output only. Statistics on the interaction request's token usage. |
responseModalities[] |
The requested modalities of the response (TEXT, IMAGE, AUDIO). |
responseMimeType |
The mime type of the response. This is required if responseFormat is set. |
previousInteractionId |
The id of the previous interaction, if any. |
environmentId |
Output only. The environment id for the interaction. Only populated if environment config is set in the request. |
serviceTier |
The service tier for the interaction. |
steps[] |
Required. Output only. The steps that make up the interaction. |
safetySettings[] |
Safety settings for the interaction. |
labels |
Optional. The labels with user-defined metadata for the request. It is used for billing and reporting only. label keys and values can be no longer than 63 characters (Unicode codepoints) and can only contain lowercase letters, numeric characters, underscores, and dashes. International characters are allowed. label values are optional. label keys must start with a letter. |
errors[] |
Output only. Diagnostic faults / platform errors recorded on the interaction. |
Union field input. The input for the interaction. input can be only one of the following: |
|
contentList |
The inputs for the interaction. |
stringContent |
A string input for the interaction, it will be processed as a single text input. |
turnList |
The turns for the interaction. |
stepList |
Input only. The steps for the interaction. |
content |
The content for the interaction. |
Union field
|
|
responseFormat |
Enforces that the generated response is a JSON object that complies with the JSON schema specified in this field. |
responseFormatList |
|
responseFormatSingleton |
|
Union field request_type. The request type for the interaction. request_type can be only one of the following: |
|
modelInteraction |
Interaction for generating the completion using models. |
agentInteraction |
Interaction for generating the completion using agents. |
Union field environment. The environment configuration for the interaction. environment can be only one of the following: |
|
envId |
The environment id for the interaction. Can be 'remote' for default environment. |
remoteEnvironment |
|
localEnvironment |
The agent's environment lives on the client connection: its built-in environment operations (filesystem ops and running commands) are yielded to the client to execute, instead of running in a server-managed sandbox. Mutually exclusive with |
TurnList
A list of Turns.
| JSON representation |
|---|
{
"turns": [
{
object ( |
| Fields | |
|---|---|
turns[] |
|
Turn
| JSON representation |
|---|
{ "role": string, // Union field |
| Fields | |
|---|---|
role |
The originator of this turn. Must be user for input or model for model output. |
Union field
|
|
contentList |
The content of the turn. An array of Content objects. |
contentString |
The content of the turn. A single string. |
StepList
A list of Steps.
| JSON representation |
|---|
{
"steps": [
{
object ( |
| Fields | |
|---|---|
steps[] |
The steps of the list. |
ResponseFormatList
| JSON representation |
|---|
{
"responseFormats": [
{
object ( |
| Fields | |
|---|---|
responseFormats[] |
|
ResponseFormat
| JSON representation |
|---|
{ // Union field |
| Fields | |
|---|---|
Union field
|
|
audio |
|
text |
|
image |
|
video |
|
structValue |
Multi-discriminator values is already enabled in GAOS |
AudioResponseFormat
Configuration for audio output format.
| JSON representation |
|---|
{ "mimeType": enum ( |
| Fields | |
|---|---|
mimeType |
The MIME type of the audio output. |
delivery |
The delivery mode for the audio output. |
sampleRate |
Sample rate in Hz. |
bitRate |
Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus). |
MimeType
Supported MIME types for audio output.
| Enums | |
|---|---|
TYPE_UNSPECIFIED |
Default value. This value is unused. |
TYPE_MP3 |
MP3 audio format. |
TYPE_OGG_OPUS |
OGG Opus audio format. |
TYPE_L16 |
Raw PCM (L16) audio format. |
TYPE_WAV |
WAV audio format. |
TYPE_ALAW |
A-law audio format. |
TYPE_MULAW |
Mu-law audio format. |
Delivery
Delivery mode for audio output.
| Enums | |
|---|---|
DELIVERY_UNSPECIFIED |
Default value. This value is unused. |
INLINE |
Audio data is returned inline in the response. |
URI |
Audio data is returned as a URI. |
TextResponseFormat
Configuration for text output format.
| JSON representation |
|---|
{ "mimeType": enum ( |
| Fields | |
|---|---|
mimeType |
The MIME type of the text output. |
schema |
The JSON schema that the output should conform to. Only applicable when mimeType is application/json. |
MimeType
Supported MIME types for text output.
| Enums | |
|---|---|
TYPE_UNSPECIFIED |
Default value. This value is unused. |
TYPE_APPLICATION_JSON |
JSON output format. |
TYPE_TEXT_PLAIN |
Plain text output format. |
ImageResponseFormat
Configuration for image output format.
| JSON representation |
|---|
{ "mimeType": enum ( |
| Fields | |
|---|---|
mimeType |
The MIME type of the image output. |
delivery |
The delivery mode for the image output. |
aspectRatio |
The aspect ratio for the image output. |
imageSize |
The size of the image output. |
MimeType
Supported MIME types for image output.
| Enums | |
|---|---|
TYPE_UNSPECIFIED |
Default value. This value is unused. |
TYPE_JPEG |
JPEG image format. |
Delivery
Delivery mode for image output.
| Enums | |
|---|---|
DELIVERY_UNSPECIFIED |
Default value. This value is unused. |
INLINE |
Image data is returned inline in the response. |
URI |
Image data is returned as a URI. |
AspectRatio
Supported aspect ratios for image output.
| Enums | |
|---|---|
ASPECT_RATIO_UNSPECIFIED |
Default value. This value is unused. |
ASPECT_RATIO_ONE_BY_ONE |
1:1 aspect ratio. |
ASPECT_RATIO_TWO_BY_THREE |
2:3 aspect ratio. |
ASPECT_RATIO_THREE_BY_TWO |
3:2 aspect ratio. |
ASPECT_RATIO_THREE_BY_FOUR |
3:4 aspect ratio. |
ASPECT_RATIO_FOUR_BY_THREE |
4:3 aspect ratio. |
ASPECT_RATIO_FOUR_BY_FIVE |
4:5 aspect ratio. |
ASPECT_RATIO_FIVE_BY_FOUR |
5:4 aspect ratio. |
ASPECT_RATIO_NINE_BY_SIXTEEN |
9:16 aspect ratio. |
ASPECT_RATIO_SIXTEEN_BY_NINE |
16:9 aspect ratio. |
ASPECT_RATIO_TWENTY_ONE_BY_NINE |
21:9 aspect ratio. |
ASPECT_RATIO_ONE_BY_EIGHT |
1:8 aspect ratio. |
ASPECT_RATIO_EIGHT_BY_ONE |
8:1 aspect ratio. |
ASPECT_RATIO_ONE_BY_FOUR |
1:4 aspect ratio. |
ASPECT_RATIO_FOUR_BY_ONE |
4:1 aspect ratio. |
ImageSize
Supported image sizes for image output.
| Enums | |
|---|---|
IMAGE_SIZE_UNSPECIFIED |
Default value. This value is unused. |
IMAGE_SIZE_FIVE_TWELVE |
512px image size. |
IMAGE_SIZE_ONE_K |
1K image size. |
IMAGE_SIZE_TWO_K |
2K image size. |
IMAGE_SIZE_FOUR_K |
4K image size. |
VideoResponseFormat
Configuration for video output format.
| JSON representation |
|---|
{ "delivery": enum ( |
| Fields | |
|---|---|
delivery |
The delivery mode for the video output. |
gcsUri |
The GCS URI to store the video output. Required for Vertex if delivery mode is URI. |
aspectRatio |
The aspect ratio for the video output. |
duration |
The duration for the video output. A duration in seconds with up to nine fractional digits, ending with ' |
Delivery
Delivery mode for video output.
| Enums | |
|---|---|
DELIVERY_UNSPECIFIED |
Default value. This value is unused. |
INLINE |
Video data is returned inline in the response. |
URI |
Video data is returned as a URI. |
AspectRatio
Supported aspect ratios for video output.
| Enums | |
|---|---|
ASPECT_RATIO_UNSPECIFIED |
Default value. This value is unused. |
ASPECT_RATIO_SIXTEEN_BY_NINE |
16:9 aspect ratio. |
ASPECT_RATIO_NINE_BY_SIXTEEN |
9:16 aspect ratio. |
ModelInteraction
Interaction for generating the completion using models.
| JSON representation |
|---|
{
"model": string,
"generationConfig": {
object ( |
| Fields | |
|---|---|
model |
The name of the |
generationConfig |
Input only. Configuration parameters for the model interaction. |
GenerationConfig
Configuration parameters for model interactions.
| JSON representation |
|---|
{ "temperature": number, "topP": number, "seed": integer, "stopSequences": [ string ], "thinkingLevel": enum ( |
| Fields | |
|---|---|
temperature |
Controls the randomness of the output. |
topP |
The maximum cumulative probability of tokens to consider when sampling. |
seed |
Seed used in decoding for reproducibility. |
stopSequences[] |
A list of character sequences that will stop output interaction. |
thinkingLevel |
The level of thought tokens that the model should generate. |
thinkingSummaries |
Whether to include thought summaries in the response. |
maxOutputTokens |
The maximum number of tokens to include in the response. |
speechConfig[] |
Configuration for speech interaction. |
imageConfig |
Configuration for image interaction. |
videoConfig |
Configuration for video generation. |
transcriptionConfig |
Optional. Configuration for speech recognition (transcription). If present, ASR is enabled. |
Union field tool_choice. The tool choice configuration. tool_choice can be only one of the following: |
|
toolChoiceMode |
The mode of the tool choice. |
toolChoiceConfig |
The config for the tool choice. |
ToolChoiceType
The type of tool choice.
| Enums | |
|---|---|
TOOL_CHOICE_TYPE_UNSPECIFIED |
Default value. This value is unused. |
AUTO |
Auto tool choice. |
ANY |
Any tool choice. |
NONE |
No tool choice. |
VALIDATED |
Validated tool choice. |
ToolChoiceConfig
The tool choice configuration containing allowed tools.
| JSON representation |
|---|
{
"allowedTools": {
object ( |
| Fields | |
|---|---|
allowedTools |
The allowed tools. |
AllowedTools
The configuration for allowed tools.
| JSON representation |
|---|
{
"mode": enum ( |
| Fields | |
|---|---|
mode |
The mode of the tool choice. |
tools[] |
The names of the allowed tools. |
ThinkingLevel
The level of thought tokens that the model should generate.
| Enums | |
|---|---|
THINKING_LEVEL_UNSPECIFIED |
Default value. This value is unused. |
THINKING_LEVEL_MINIMAL |
Little to no thinking. |
THINKING_LEVEL_LOW |
Low thinking level. |
THINKING_LEVEL_MEDIUM |
Medium thinking level. |
THINKING_LEVEL_HIGH |
High thinking level. |
ThinkingSummaries
Whether to include thought summaries in the response.
| Enums | |
|---|---|
THINKING_SUMMARIES_UNSPECIFIED |
Default value. This value is unused. |
THINKING_SUMMARIES_AUTO |
Auto thinking summaries. |
THINKING_SUMMARIES_NONE |
No thinking summaries. |
SpeechConfig
The configuration for speech interaction.
| JSON representation |
|---|
{ "voice": string, "language": string, "speaker": string } |
| Fields | |
|---|---|
voice |
The voice of the speaker. |
language |
The language of the speech. |
speaker |
The speaker's name, it should match the speaker name given in the prompt. |
ImageConfig
The configuration for image interaction.
| JSON representation |
|---|
{ "aspectRatio": string, "imageSize": string } |
| Fields | |
|---|---|
aspectRatio |
The aspect ratio of the image to generate. Supported aspect ratios: 1:1, 2:3, 3:2, 3:4, 4:3, 9:16, 16:9, 21:9. If not specified, the model will choose a default aspect ratio based on any reference images provided. |
imageSize |
Specifies the size of generated images. Supported values are |
VideoConfig
Configuration options for video generation.
| JSON representation |
|---|
{
"task": enum ( |
| Fields | |
|---|---|
task |
Optional task mode for video generation. If not specified, the model automatically determines the appropriate mode based on the provided text prompt and input media. |
Task
Supported video generation tasks.
| Enums | |
|---|---|
TASK_UNSPECIFIED |
Unspecified task. The task is inferred from the input prompt and media. |
TEXT_TO_VIDEO |
Generates video solely from a text prompt. |
IMAGE_TO_VIDEO |
Generates video from one or two source images. The first image defines the starting frame, and the optional second image defines the ending frame. |
REFERENCE_TO_VIDEO |
Generates video using reference media (such as images, audio, or video). |
EDIT |
Modifies an existing input video. |
TranscriptionConfig
Configuration for speech recognition (transcription).
| JSON representation |
|---|
{ "timestampGranularities": [ string ], "diarizationMode": string, "languageCodes": [ string ], "adaptationPhrases": [ string ], "customVocabulary": [ string ] } |
| Fields | |
|---|---|
timestampGranularities[] |
Optional. The granularity of timestamps to include in the transcription output. Supported values: "word". If empty, no timestamps are generated. |
diarizationMode |
Optional. Configures speaker diarization. Supported values: "speaker". |
languageCodes[] |
Optional. BCP-47 language codes providing hints about the languages present in the audio. If omitted or empty, defaults to automatic language detection. |
adaptationPhrases[] |
Optional. A list of phrases to bias the ASR model towards. |
customVocabulary[] |
Optional. A list of custom vocabulary phrases to bias the speech recognition model toward recognizing specific terms. |
AgentInteraction
Interaction for generating the completion using agents.
| JSON representation |
|---|
{ "agent": string, // Union field |
| Fields | |
|---|---|
agent |
The name of the |
Union field agent_config. Parameters for the agent interaction. agent_config can be only one of the following: |
|
dynamicConfig |
|
deepResearchConfig |
|
codeMenderConfig |
|
antigravityConfig |
Antigravity agent configuration. This configuration is session-level settings that are passed to the agent runtime on a per-request basis. |
DynamicAgentConfig
Configuration for dynamic agents.
| JSON representation |
|---|
{
"config": {
object ( |
| Fields | |
|---|---|
config |
For agents that are not supported statically in the API definition. |
DeepResearchAgentConfig
Configuration for the Deep Research agent.
| JSON representation |
|---|
{ "thinkingSummaries": enum ( |
| Fields | |
|---|---|
thinkingSummaries |
Whether to include thought summaries in the response. |
visualization |
Whether to include visualizations in the response. |
collaborativePlanning |
Enables human-in-the-loop planning for the Deep Research agent. If set to true, the Deep Research agent will provide a research plan in its response. The agent will then proceed only if the user confirms the plan in the next turn. |
enableBigqueryTool |
Enables bigquery tool for the Deep Research agent. |
VisualizationMode
Enum for visualization mode. Eventually we will support an interactive mode where the user can choose whether to include HTML visualizations in the response.
| Enums | |
|---|---|
UNSPECIFIED |
The default visualization mode. Will default to AUTO. |
OFF |
Do not include visualizations. |
AUTO |
Automatically include visualizations. |
CodeMenderAgentConfig
Configuration for the CodeMender agent.
| JSON representation |
|---|
{ "sessionId": string, "sessionConfig": { object ( |
| Fields | |
|---|---|
sessionId |
Parameter for grouping multiple interactions that belong to the same CodeMender session. |
sessionConfig |
Optional session-specific configurations to override default agent behavior. |
model |
The name of the model to use for the CodeMender agent. One CodeMender session will only use one model. |
Union field request. CodeMender's request type. Set exactly one of find_request/fix_request only on the first round to start a session; on subsequent rounds (e.g. submitting tool results), leave this unset and identify the session via session_id. This oneof is intentionally not a subtype_source discriminator so it can be omitted on resume rounds. request can be only one of the following: |
|
findRequest |
Parameters for finding vulnerabilities. |
fixRequest |
Parameters for fixing vulnerabilities. |
FindRequest
Request parameters specific to FIND sessions, used for discovering vulnerabilities in a codebase.
| JSON representation |
|---|
{ "sourceFiles": [ { object ( |
| Fields | |
|---|---|
sourceFiles[] |
A list of source files to provide as context for the scan. |
findingId |
The identifier of a specific finding to verify. This is primarily used in VERIFY mode to focus the agent's execution-based validation on a single vulnerability. |
description |
Additional context or custom instructions provided by the user to guide the vulnerability analysis. |
mode |
The mode of the find session. |
FileContent
Content of a single file in the codebase.
| JSON representation |
|---|
{ "path": string, "content": string } |
| Fields | |
|---|---|
path |
The relative path of the file from the project root. |
content |
The UTF-8 encoded text content of the file. |
Mode
Defines the depth and thoroughness of the find session.
| Enums | |
|---|---|
MODE_UNSPECIFIED |
Default value. This value is unused. |
MODE_SCAN |
Fast scan using only the initial classifier. |
MODE_VERIFY |
Performs classification followed by detailed investigation. |
FixRequest
Request parameters specific to FIX sessions, used for generating and validating security patches.
| JSON representation |
|---|
{
"sourceFiles": [
{
object ( |
| Fields | |
|---|---|
sourceFiles[] |
A list of source files providing context for the remediation. These files are typically the ones containing the identified vulnerability. |
findingId |
The identifier of the specific security finding to be remediated. This id maps to a previously discovered vulnerability. |
description |
Additional context or custom instructions provided by the user to guide the patch generation process. |
SessionConfig
The configuration of CodeMender sessions.
| JSON representation |
|---|
{ "maxRounds": integer } |
| Fields | |
|---|---|
maxRounds |
The maximum number of interaction rounds the agent is allowed to perform before reaching a timeout. |
AntigravityAgentConfig
Configuration for the Antigravity agent runtime. Provides server-side control over the agent's execution environment and tool configuration.
| JSON representation |
|---|
{ "model": string, "maxTotalTokens": string } |
| Fields | |
|---|---|
model |
The model to use for agent reasoning. |
maxTotalTokens |
Max total tokens for the agent run. |
EnvironmentConfig
Configuration for a custom environment.
| JSON representation |
|---|
{ "sources": [ { object ( |
| Fields | |
|---|---|
sources[] |
|
environmentId |
Optional. The environment id for the interaction. If specified, the request will update the existing environment instead of creating a new one. |
Union field network. Network configuration for the environment. network can be only one of the following: |
|
networkAllowlist |
Allow only specific domains. |
networkMode |
Network egress mode. |
EnvironmentNetworkEgressAllowlist
Network egress configuration for the environment.
| JSON representation |
|---|
{
"allowlist": [
{
object ( |
| Fields | |
|---|---|
allowlist[] |
List of allowed domains and their configurations. |
EgressRule
A network egress rule that controls which external domains the environment is allowed to reach. Each rule identifies a target domain and, optionally, a set of HTTP headers to inject into every matching outbound request.
| JSON representation |
|---|
{ "domain": string, "transform": { string: string, ... } } |
| Fields | |
|---|---|
domain |
The domain pattern to match for this rule. Use an exact hostname (e.g., |
transform |
headers to inject into requests matching this rule. Key: header name (e.g., "Authorization"). value: header value (e.g., "Bearer your-token"). |
NetworkMode
Network egress mode for non-allowlist configurations.
| Enums | |
|---|---|
NETWORK_MODE_UNSPECIFIED |
Default value. Unused. |
DISABLED |
All network egress is blocked. |
Source
A source to be mounted into the environment.
| JSON representation |
|---|
{
"type": enum ( |
| Fields | |
|---|---|
type |
|
source |
The source of the environment. For GCS, this is the GCS path. For GitHub, this is the GitHub path. |
target |
Where the source should appear in the environment. |
content |
The inline content if |
encoding |
Optional encoding for inline content (e.g. |
Type
| Enums | |
|---|---|
TYPE_UNSPECIFIED |
|
GCS |
A GCS bucket. |
INLINE |
Inline content. |
REPOSITORY |
A generic repository. The protocol prefix in the source URL identifies the provider (e.g., github://, gcs://). |
SKILL_REGISTRY |
A skill resource from the Skill Registry service. Skill: projects/{project}/locations/{location}/skills/{skill} SkillRevision: projects/{project}/locations/{location}/skills/{skill}/revisions/{revision} Support mounting all skills under a project: projects/{project}/locations/{location}/skills. |
LocalEnvironmentConfig
This type has no fields.
Configuration for an environment that lives on the client connection rather than in a server-managed sandbox.
When set (via Interaction.local_environment), the agent's filesystem and shell are treated as living on the client: the agent's built-in environment operations (e.g. reading/listing/editing files and running commands) are suspended on the server and yielded back to the client to execute, with their results returned on a subsequent turn. This is mutually exclusive with a server-managed EnvironmentConfig (remoteEnvironment), since the environment is either on the client or in a server sandbox, never both.
This governs only the agent's built-in environment. client-declared function tools are always executed on the client regardless of this field.
Tool
A tool that can be used by the model.
| JSON representation |
|---|
{ // Union field |
| Fields | |
|---|---|
Union field type. The tool to use. type can be only one of the following: |
|
function |
A function that can be used by the model. |
codeExecution |
A tool that can be used by the model to execute code. |
urlContext |
A tool that can be used by the model to fetch URL context. |
computerUse |
Tool to support the model interacting directly with the computer. |
mcpServer |
A MCPServer is a server that can be called by the model to perform actions. |
googleSearch |
A tool that can be used by the model to search Google. |
fileSearch |
A tool that can be used by the model to search files. |
googleMaps |
A tool that can be used by the model to search Google Maps. |
retrieval |
A tool that can be used by the model to retrieve files. |
Function
A tool that can be used by the model.
| JSON representation |
|---|
{
"name": string,
"description": string,
"parameters": {
object ( |
| Fields | |
|---|---|
name |
The name of the function. |
description |
A description of the function. |
parameters |
The JSON Schema for the function's parameters. |
CodeExecution
This type has no fields.
A tool that can be used by the model to execute code.
UrlContext
This type has no fields.
A tool that can be used by the model to fetch URL context.
ComputerUse
A tool that can be used by the model to interact with the computer.
| JSON representation |
|---|
{ "environment": enum ( |
| Fields | |
|---|---|
environment |
The environment being operated. |
excludedPredefinedFunctions[] |
The list of predefined functions that are excluded from the model call. |
enablePromptInjectionDetection |
Whether enable the prompt injection detection check on computer-use request. |
disabledSafetyPolicies[] |
Optional. disabled safety policies for computer use. |
Environment
Represents the environment being operated, such as a web browser.
| Enums | |
|---|---|
ENVIRONMENT_UNSPECIFIED |
Defaults to browser. |
BROWSER |
Operates in a web browser. |
MOBILE |
Operates in a mobile environment. |
DESKTOP |
Operates in a desktop environment. |
SafetyPolicy
| Enums | |
|---|---|
SAFETY_POLICY_UNSPECIFIED |
Unspecified safety policy. |
FINANCIAL_TRANSACTIONS |
Safety policy for financial transactions. |
SENSITIVE_DATA_MODIFICATION |
Safety policy for sensitive data modification. |
COMMUNICATION_TOOL |
Safety policy for communication tools (e.g. Gmail, Chat, Meet). |
ACCOUNT_CREATION |
Safety policy for account creation. |
DATA_MODIFICATION |
Safety policy for data modification. |
USER_CONSENT_MANAGEMENT |
Safety policy for user consent management. |
LEGAL_TERMS_AND_AGREEMENTS |
Safety policy for legal terms and agreements. |
McpServer
A MCPServer is a server that can be called by the model to perform actions.
| JSON representation |
|---|
{ "name": string, "headers": { string: string, ... }, "allowedTools": [ { object ( |
| Fields | |
|---|---|
name |
The name of the MCPServer. |
headers |
Optional: Fields for authentication headers, timeouts, etc., if needed. |
allowedTools[] |
The allowed tools. |
Union field
|
|
url |
The full URL for the MCPServer endpoint. Example: "https://api.example.com/mcp" |
GoogleSearch
A tool that can be used by the model to search Google.
| JSON representation |
|---|
{
"searchTypes": [
enum ( |
| Fields | |
|---|---|
searchTypes[] |
The types of search grounding to enable. |
FileSearch
A tool that can be used by the model to search files.
| JSON representation |
|---|
{ "fileSearchStoreNames": [ string ], "topK": integer, "metadataFilter": string } |
| Fields | |
|---|---|
fileSearchStoreNames[] |
The file search store names to search. |
topK |
The number of semantic retrieval chunks to retrieve. |
metadataFilter |
metadata filter to apply to the semantic retrieval documents and chunks. |
GoogleMaps
A tool that can be used by the model to call Google Maps.
| JSON representation |
|---|
{ "enableWidget": boolean, "latitude": number, "longitude": number } |
| Fields | |
|---|---|
enableWidget |
Whether to return a widget context token in the tool call result of the response. |
latitude |
The latitude of the user's location. |
longitude |
The longitude of the user's location. |
Retrieval
A tool that can be used by the model to retrieve files.
| JSON representation |
|---|
{ "retrievalTypes": [ enum ( |
| Fields | |
|---|---|
retrievalTypes[] |
The types of file retrieval to enable. |
vertexAiSearchConfig |
Used to specify configuration for VertexAISearch. |
exaAiSearchConfig |
Used to specify configuration for ExaAISearch. |
parallelAiSearchConfig |
Used to specify configuration for ParallelAISearch. |
ragStoreConfig |
Used to specify configuration for RagStore. |
VertexAISearchConfig
Used to specify configuration for VertexAISearch.
| JSON representation |
|---|
{ "engine": string, "datastores": [ string ] } |
| Fields | |
|---|---|
engine |
Optional. Used to specify Vertex AI Search engine. |
datastores[] |
Optional. Used to specify Vertex AI Search datastores. |
ExaAISearchConfig
Used to specify configuration for ExaAISearch.
| JSON representation |
|---|
{ "apiKey": string, "customConfig": { object } } |
| Fields | |
|---|---|
apiKey |
Required. The API key for ExaAiSearch. |
customConfig |
Optional. This field can be used to pass any parameter from the Exa.ai Search API. |
ParallelAISearchConfig
Used to specify configuration for ParallelAISearch.
| JSON representation |
|---|
{ "apiKey": string, "customConfig": { object } } |
| Fields | |
|---|---|
apiKey |
Optional. The API key for ParallelAiSearch. |
customConfig |
Optional. Custom configs for ParallelAiSearch. |
RagStoreConfig
Use to specify configuration for RAG Store.
| JSON representation |
|---|
{ "ragResources": [ { object ( |
| Fields | |
|---|---|
ragResources[] |
Optional. The representation of the rag source. |
similarityTopK |
Optional. Number of top k results to return from the selected corpora. |
vectorDistanceThreshold |
Optional. Only return results with vector distance smaller than the threshold. |
ragRetrievalConfig |
Optional. The retrieval config for the Rag query. |
RagResource
The definition of the Rag resource.
| JSON representation |
|---|
{ "ragCorpus": string, "ragFileIds": [ string ] } |
| Fields | |
|---|---|
ragCorpus |
Optional. RagCorpora resource name. |
ragFileIds[] |
Optional. ragFileId. The files should be in the same ragCorpus set in ragCorpus field. |
RagRetrievalConfig
Specifies the context retrieval config.
| JSON representation |
|---|
{ "topK": integer, "hybridSearch": { object ( |
| Fields | |
|---|---|
topK |
Optional. The number of contexts to retrieve. |
hybridSearch |
Optional. Config for Hybrid Search. |
filter |
Optional. Config for filters. |
ranking |
Optional. Config for ranking and reranking. |
HybridSearch
Config for Hybrid Search.
| JSON representation |
|---|
{ "alpha": number } |
| Fields | |
|---|---|
alpha |
Optional. Alpha value controls the weight between dense and sparse vector search results. |
Filter
Config for filters.
| JSON representation |
|---|
{ "metadataFilter": string, // Union field |
| Fields | |
|---|---|
metadataFilter |
Optional. String for metadata filtering. |
Union field vector_db_threshold. Filter contexts retrieved from the vector DB based on either vector distance or vector similarity. vector_db_threshold can be only one of the following: |
|
vectorDistanceThreshold |
Optional. Only returns contexts with vector distance smaller than the threshold. |
vectorSimilarityThreshold |
Optional. Only returns contexts with vector similarity larger than the threshold. |
Ranking
Config for ranking and reranking.
| JSON representation |
|---|
{ // Union field |
| Fields | |
|---|---|
Union field ranking_config. Config options for ranking. ranking_config can be only one of the following: |
|
rankService |
Optional. Config for Rank service. |
RankService
Config for Rank service.
| JSON representation |
|---|
{ "modelName": string } |
| Fields | |
|---|---|
modelName |
Optional. The model name of the rank service. |
ServiceTier
The service tier of the interaction.
| Enums | |
|---|---|
SERVICE_TIER_UNSPECIFIED |
Default service tier, which is standard. |
SERVICE_TIER_FLEX |
Flex service tier. |
SERVICE_TIER_STANDARD |
Standard service tier. |
SERVICE_TIER_PRIORITY |
priority service tier. |
SERVICE_TIER_DEFERRED |
Deferred service tier. |
SafetySetting
A safety setting that affects the safety-blocking behavior.
A SafetySetting consists of a harm category and a threshold for that category.
| JSON representation |
|---|
{ "type": enum ( |
| Fields | |
|---|---|
type |
Required. The type of harm category to be blocked. |
threshold |
Required. The threshold for blocking content. If the harm probability exceeds this threshold, the content will be blocked. |
method |
Optional. The method for blocking content. If not specified, the default behavior is to use the probability score. |
HarmCategory
Harm categories that can be detected in user input and model responses.
| Enums | |
|---|---|
HARM_CATEGORY_UNSPECIFIED |
Default value. This value is unused. |
HARM_CATEGORY_HATE_SPEECH |
Content that promotes violence or incites hatred against individuals or groups based on certain attributes. |
HARM_CATEGORY_DANGEROUS_CONTENT |
Content that promotes, facilitates, or enables dangerous activities. |
HARM_CATEGORY_HARASSMENT |
Abusive, threatening, or content intended to bully, torment, or ridicule. |
HARM_CATEGORY_SEXUALLY_EXPLICIT |
Content that contains sexually explicit material. |
HARM_CATEGORY_CIVIC_INTEGRITY |
Deprecated: Election filter is not longer supported. The harm category is civic integrity. |
HARM_CATEGORY_IMAGE_HATE |
Images that contain hate speech. |
HARM_CATEGORY_IMAGE_DANGEROUS_CONTENT |
Images that contain dangerous content. |
HARM_CATEGORY_IMAGE_HARASSMENT |
Images that contain harassment. |
HARM_CATEGORY_IMAGE_SEXUALLY_EXPLICIT |
Images that contain sexually explicit content. |
HARM_CATEGORY_JAILBREAK |
Prompts designed to bypass safety filters. |
HarmBlockThreshold
Thresholds for blocking content based on harm probability.
| Enums | |
|---|---|
HARM_BLOCK_THRESHOLD_UNSPECIFIED |
The harm block threshold is unspecified. |
BLOCK_LOW_AND_ABOVE |
Block content with a low harm probability or higher. |
BLOCK_MEDIUM_AND_ABOVE |
Block content with a medium harm probability or higher. |
BLOCK_ONLY_HIGH |
Block content with a high harm probability. |
BLOCK_NONE |
Do not block any content, regardless of its harm probability. |
OFF |
Turn off the safety filter entirely. |
HarmBlockMethod
The method for blocking content.
| Enums | |
|---|---|
HARM_BLOCK_METHOD_UNSPECIFIED |
The harm block method is unspecified. |
SEVERITY |
The harm block method uses both probability and severity scores. |
PROBABILITY |
The harm block method uses the probability score. |