Package-level declarations
Types
The generic reusable api auth config. Deprecated. Please use AuthConfig (google/cloud/aiplatform/master/auth.proto) instead. This data type is not supported in Gemini API.
The API secret. This data type is not supported in Gemini API.
Config for authentication with API key. This data type is not supported in Gemini API.
The authentication config to access the API.
Config for Google Service Account Authentication. This data type is not supported in Gemini API.
Config for HTTP Basic Authentication. This data type is not supported in Gemini API.
Config for user oauth. This data type is not supported in Gemini API.
Config for user OIDC auth. This data type is not supported in Gemini API.
Output only. The reason why the prompt was blocked.
A custom serializer for ByteArray that encodes to and decodes from Base64 strings.
A resource used in LLM queries for users to explicitly specify what to cache.
A response candidate generated from the model.
A citation for a piece of generatedcontent. This data type is not supported in Gemini API.
Citation information when the model quotes another source.
Result of executing the ExecutableCode. Generated only when the CodeExecution tool is used.
Tool to support computer use.
Optional configuration for cached content creation.
Parameters for caches.create method.
Optional parameters for caches.delete method.
Parameters for caches.delete method.
Empty response for caches.delete method.
A custom serializer for Duration that formats it as a string ending in 's'.
Describes the options to customize dynamic retrieval.
The mode of the predictor to be used in dynamic retrieval.
Tool to search public web data, powered by Vertex AI Search and Sec4 compliance. This data type is not supported in Gemini API.
The environment being operated.
Code generated by the model that is meant to be executed, and the result returned to the model. Generated when using the CodeExecution tool, in which the code will be automatically executed, and a corresponding CodeExecutionResult will also be generated.
Retrieve from data source powered by external API for grounding. The external API is not owned by Google, but need to follow the pre-defined API spec. This data type is not supported in Gemini API.
The search parameters to use for the ELASTIC_SEARCH spec. This data type is not supported in Gemini API.
The search parameters to use for SIMPLE_SEARCH spec. This data type is not supported in Gemini API.
Options for feature selection preference.
The FileSearch tool that retrieves knowledge from Semantic Retrieval corpora. Files are imported to Semantic Retrieval corpora using the ImportFile API. This data type is not supported in Vertex AI.
Output only. The reason why the model stopped generating tokens.
A predicted FunctionCall returned from the model that contains a string representing the FunctionDeclaration.name and a structured JSON object containing the parameters and their values.
Function calling config.
Function calling mode.
Structured representation of a function declaration as defined by the OpenAPI 3.0 specification. 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.
The result output from a FunctionCall that contains a string representing the FunctionDeclaration.name and a structured JSON object containing any output from the function is used as context to the model. This should contain the result of a FunctionCall made based on model prediction.
Raw media bytes for function response. Text should not be sent as raw bytes, use the 'text' field.
URI based data for function response. This data type is not supported in Gemini API.
A datatype containing media that is part of a FunctionResponse message. A FunctionResponsePart consists of data which has an associated datatype. A FunctionResponsePart can only contain one of the accepted types in FunctionResponsePart.data. A FunctionResponsePart must have a fixed IANA MIME type identifying the type and subtype of the media if the inline_data field is filled with raw bytes.
Specifies how the response should be scheduled in the conversation. Only applicable to NON_BLOCKING function calls, is ignored otherwise. Defaults to WHEN_IDLE.
Optional model configuration parameters.
Config for models.generate_content parameters.
Response message for PredictionService.GenerateContent.
Content filter results for a prompt sent in the request. Note: This is sent only in the first stream chunk and only if no candidates were generated due to content violations.
Usage metadata about the content generation request and response. This message provides a detailed breakdown of token usage and other relevant metrics. This data type is not supported in Gemini API.
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.
The configuration for automated routing. When automated routing is specified, the routing will be determined by the pretrained routing model and customer provided model routing preference. This data type is not supported in Gemini API.
The configuration for manual routing. When manual routing is specified, the model will be selected based on the model name provided. This data type is not supported in Gemini API.
Optional parameters for caches.get method.
Parameters for caches.get method.
Tool to retrieve knowledge from Google Maps.
GoogleSearch tool type. Tool to support Google Search in Model. Powered by Google.
Tool to retrieve public web data for grounding, powered by Google.
Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp. This data type is not supported in Gemini API.
A piece of evidence that supports a claim made by the model.
User provided metadata about the GroundingFact. This data type is not supported in Vertex AI.
An Image chunk is a piece of evidence that comes from an image search result. It contains the URI of the image search result and the URI of the image. This is used to provide the user with a link to the source of the information.
A Maps chunk is a piece of evidence that comes from Google Maps.
The sources that were used to generate the place answer.
Author attribution for a photo or review.
Encapsulates a review snippet.
Route information from Google Maps. This data type is not supported in Gemini API.
Context retrieved from a data source to ground the model's response. This is used when a retrieval tool fetches information from a user-provided corpus or a public dataset.
A list of string values. This data type is not supported in Vertex AI.
A Web chunk is a piece of evidence that comes from a web page. It contains the URI of the web page, the title of the page, and the domain of the page. This is used to provide the user with a link to the source of the information.
Information for various kinds of grounding.
A URI that can be used to flag a place or review for inappropriate content. This is populated only when the grounding source is Google Maps. This data type is not supported in Gemini API.
The method for blocking content. If not specified, the default behavior is to use the probability score. This enum is not supported in Gemini API.
The threshold for blocking content. If the harm probability exceeds this threshold, the content will be blocked.
The harm category to be blocked.
Output only. The probability of harm for this category.
Output only. The severity of harm for this category. This enum is not supported in Gemini API.
The location of the API key. This enum is not supported in Gemini API.
A wrapper class for the http response.
The image generation configuration to be used in GenerateContentConfig.
The image output format for generated images. This data type is not supported in Gemini API.
Image search for grounding and related configurations.
A custom serializer for Instant that encodes to and decodes from ISO-8601 strings.
Represents a time interval, encoded as a Timestamp start (inclusive) and a Timestamp end (exclusive). The start must be less than or equal to the end. When the start equals the end, the interval is empty (matches no time). When both start and end are unspecified, the interval matches any time.
An object that represents a latitude/longitude pair. This is expressed as a pair of doubles to represent degrees latitude and degrees longitude. Unless specified otherwise, this object must conform to the WGS84 standard. Values must be within normalized ranges.
Config for caches.list method.
Parameters for caches.list method.
The log probabilities of the tokens generated by the model. This is useful for understanding the model's confidence in its predictions and for debugging. For example, you can use log probabilities to identify when the model is making a less confident prediction or to explore alternative responses that the model considered. A low log probability can also indicate that the model is "hallucinating" or generating factually incorrect information.
A single token and its associated log probability.
A list of the top candidate tokens and their log probabilities at each decoding step. This can be used to see what other tokens the model considered.
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.
The modality that this token count applies to.
The media resolution to use.
Represents a breakdown of token usage by modality. This message is used in CountTokensResponse and GenerateContentResponse.UsageMetadata to provide a detailed view of how many tokens are used by each modality (e.g., text, image, video) in a request. This is particularly useful for multimodal models, allowing you to track and manage token consumption for billing and quota purposes.
Configuration for Model Armor. Model Armor is a Google Cloud service that provides safety and security filtering for prompts and responses. It helps protect your AI applications from risks such as harmful content, sensitive data leakage, and prompt injection attacks. This data type is not supported in Gemini API.
The model routing preference.
Config for model selection.
The stage of the underlying model. This enum is not supported in Vertex AI.
The status of the underlying model. This is used to indicate the stage of the underlying model and the retirement time if applicable. This data type is not supported in Vertex AI.
Configuration for a multi-speaker text-to-speech request.
A datatype containing media content.
Partial argument value of the function call. This data type is not supported in Gemini API.
Media resolution for the input media.
The tokenization quality used for given media.
Sites with confidence level chosen & above this value will be blocked from the search results. This enum is not supported in Gemini API.
Configuration for a prebuilt voice.
Controls whether prominent people (celebrities) generation is allowed. If used with personGeneration, personGeneration enum would take precedence. For instance, if ALLOW_NONE is set, all person generation would be blocked. If this field is unspecified, the default behavior is to allow prominent people. This enum is not supported in Gemini API.
A RagChunk includes the content of a chunk of a RagFile, and associated metadata. This data type is not supported in Gemini API.
Represents where the chunk starts and ends in the document. This data type is not supported in Gemini API.
Specifies the context retrieval config. This data type is not supported in Gemini API.
Config for filters. This data type is not supported in Gemini API.
Config for Hybrid Search. This data type is not supported in Gemini API.
Config for ranking and reranking. This data type is not supported in Gemini API.
Config for LlmRanker. This data type is not supported in Gemini API.
Config for Rank Service. This data type is not supported in Gemini API.
The configuration for the replicated voice to use.
Defines a retrieval tool that model can call to access external knowledge. This data type is not supported in Gemini API.
Retrieval config.
Metadata returned to client when grounding is enabled.
SafetyPolicy
A safety rating for a piece of content. The safety rating contains the harm category and the harm probability level.
A safety setting that affects the safety-blocking behavior. A SafetySetting consists of a harm category and a threshold for that category.
Schema is used to define the format of input/output data.
The entry point used to search for grounding sources.
Different types of search that can be enabled on the GoogleSearch tool.
Pricing and performance service tier.
Configuration for a single speaker in a multi-speaker setup.
Config for speech generation and transcription.
A transport that can stream HTTP requests and responses. Next ID: 6. This data type is not supported in Vertex AI.
The thinking features configuration.
The number of thoughts tokens that the model should generate.
Tool details of a tool that the model may use to generate a response.
Tool that executes code generated by the model, and automatically returns the result to the model. See also ExecutableCode and CodeExecutionResult, which are input and output to this tool. This data type is not supported in Gemini API.
Tool config. This config is shared for all tools provided in the request.
ExaAiSearch tool type. A tool that uses the Exa.ai search engine for grounding. This data type is not supported in Gemini API.
ParallelAiSearch tool type. A tool that uses the Parallel.ai search engine for grounding. This data type is not supported in Gemini API.
The output from a server-side ToolCall execution.
Output only. The traffic type for this request. This enum is not supported in Gemini API.
Optional parameters for caches.update method.
Tool to support URL context.
Metadata returned when the model uses the url_context tool to get information from a user-provided URL.
The metadata for a single URL retrieval.
The status of the URL retrieval.
Retrieve from Vertex AI Search datastore or engine for grounding. datastore and engine are mutually exclusive. See https://cloud.google.com/products/agent-builder. This data type is not supported in Gemini API.
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.
Retrieve from Vertex RAG Store for grounding. This data type is not supported in Gemini API.
The definition of the Rag resource. This data type is not supported in Gemini API.
Provides metadata for a video, including the start and end offsets for clipping and the frame rate.
The configuration for the voice to use.
The signature of the voice consent check.