Tool

public final class Tool

A tool that can be used by the model.

Types

Link copied to clipboard
public final class ComputerUse

A tool that can be used by the model to interact with the computer.

Link copied to clipboard
public final class FileSearch

A tool that can be used by the model to search files.

Link copied to clipboard
public final class GoogleMaps

A tool that can be used by the model to call Google Maps.

Link copied to clipboard
public final class GoogleSearch

A tool that can be used by the model to search Google.

Link copied to clipboard
public final class McpServer

A MCPServer is a server that can be called by the model to perform actions.

Link copied to clipboard
public final class Retrieval

A tool that can be used by the model to retrieve files.

Link copied to clipboard
public interface Visitor<T extends Object>

An interface that defines how to map each variant of Tool to a value of type T.

Functions

Link copied to clipboard
public final Optional<JsonValue> _json()
Link copied to clipboard
public final T accept<T extends Any>(Tool.Visitor<T> visitor)
Link copied to clipboard
public final JsonValue asCodeExecution()

A tool that can be used by the model to execute code.

Link copied to clipboard

A tool that can be used by the model to interact with the computer.

Link copied to clipboard

A tool that can be used by the model to search files.

Link copied to clipboard
public final Function asFunction()

A tool that can be used by the model.

Link copied to clipboard

A tool that can be used by the model to call Google Maps.

Link copied to clipboard

A tool that can be used by the model to search Google.

Link copied to clipboard
public final Tool.McpServer asMcpServer()

A MCPServer is a server that can be called by the model to perform actions.

Link copied to clipboard
public final Tool.Retrieval asRetrieval()

A tool that can be used by the model to retrieve files.

Link copied to clipboard
public final JsonValue asUrlContext()

A tool that can be used by the model to fetch URL context.

Link copied to clipboard
public final Optional<JsonValue> codeExecution()

A tool that can be used by the model to execute code.

Link copied to clipboard

A tool that can be used by the model to interact with the computer.

Link copied to clipboard
public Boolean equals(Object other)
Link copied to clipboard

A tool that can be used by the model to search files.

Link copied to clipboard
public final Optional<Function> function()

A tool that can be used by the model.

Link copied to clipboard

A tool that can be used by the model to call Google Maps.

Link copied to clipboard

A tool that can be used by the model to search Google.

Link copied to clipboard
public Integer hashCode()
Link copied to clipboard
public final Boolean isCodeExecution()
Link copied to clipboard
public final Boolean isComputerUse()
Link copied to clipboard
public final Boolean isFileSearch()
Link copied to clipboard
public final Boolean isFunction()
Link copied to clipboard
public final Boolean isGoogleMaps()
Link copied to clipboard
public final Boolean isGoogleSearch()
Link copied to clipboard
public final Boolean isMcpServer()
Link copied to clipboard
public final Boolean isRetrieval()
Link copied to clipboard
public final Boolean isUrlContext()
Link copied to clipboard
public final Boolean isValid()
Link copied to clipboard

A MCPServer is a server that can be called by the model to perform actions.

Link copied to clipboard
public final static Tool ofCodeExecution()

A tool that can be used by the model to execute code.

Link copied to clipboard
public final static Tool ofComputerUse(Tool.ComputerUse computerUse)

A tool that can be used by the model to interact with the computer.

Link copied to clipboard
public final static Tool ofFileSearch(Tool.FileSearch fileSearch)

A tool that can be used by the model to search files.

Link copied to clipboard
public final static Tool ofFunction(Function function)

A tool that can be used by the model.

Link copied to clipboard
public final static Tool ofGoogleMaps(Tool.GoogleMaps googleMaps)

A tool that can be used by the model to call Google Maps.

Link copied to clipboard
public final static Tool ofGoogleSearch(Tool.GoogleSearch googleSearch)

A tool that can be used by the model to search Google.

Link copied to clipboard
public final static Tool ofMcpServer(Tool.McpServer mcpServer)

A MCPServer is a server that can be called by the model to perform actions.

Link copied to clipboard
public final static Tool ofRetrieval(Tool.Retrieval retrieval)

A tool that can be used by the model to retrieve files.

Link copied to clipboard
public final static Tool ofUrlContext()

A tool that can be used by the model to fetch URL context.

Link copied to clipboard

A tool that can be used by the model to retrieve files.

Link copied to clipboard
public String toString()
Link copied to clipboard
public final Optional<JsonValue> urlContext()

A tool that can be used by the model to fetch URL context.

Link copied to clipboard
public final Tool validate()