Tool details of a tool that the model may use to generate a response.

Properties

codeExecution?: ToolCodeExecution

Optional. CodeExecution tool type. Enables the model to execute code as part of generation.

computerUse?: ComputerUse

Optional. Tool to support the model interacting directly with the computer. If enabled, it automatically populates computer-use specific Function Declarations.

enterpriseWebSearch?: EnterpriseWebSearch

Optional. Tool to support searching public web data, powered by Vertex AI Search and Sec4 compliance. This field is not supported in Gemini API.

fileSearch?: FileSearch

Optional. Tool to retrieve knowledge from the File Search Stores.

functionDeclarations?: FunctionDeclaration[]

List of function declarations that the tool supports.

googleMaps?: GoogleMaps

Optional. GoogleMaps tool type. Tool to support Google Maps in Model.

googleSearch?: GoogleSearch

Optional. GoogleSearch tool type. Tool to support Google Search in Model. Powered by Google.

googleSearchRetrieval?: GoogleSearchRetrieval

Optional. Specialized retrieval tool that is powered by Google Search.

retrieval?: Retrieval

Optional. Retrieval tool type. System will always execute the provided retrieval tool(s) to get external knowledge to answer the prompt. Retrieval results are presented to the model for generation. This field is not supported in Gemini API.

urlContext?: UrlContext

Optional. Tool to support URL context retrieval.