Models
Gemini - AI Studio
Use Google’s AI Studio to access the Gemini and Gemma models.
Authentication
Set your GOOGLE_API_KEY
environment variable. You can get one from Google here.
Example
Use Gemini
with your Agent
:
Params
Parameter | Type | Default | Description |
---|---|---|---|
id | str | "gemini-1.5-flash" | The specific model ID used for generating responses. |
name | str | "Gemini" | The name identifier for the agent. |
provider | str | "Google" | The provider of the model. |
function_declarations | Optional[List[FunctionDeclaration]] | - | A list of function declarations that the model can utilize during the response generation process. |
generation_config | Optional[Any] | - | Configuration settings for the generation process, such as parameters for controlling output behavior. |
safety_settings | Optional[Any] | - | Settings related to safety measures, ensuring the generation of appropriate and safe content. |
generative_model_kwargs | Optional[Dict[str, Any]] | - | Additional keyword arguments for the generative model. |
api_key | Optional[str] | - | The API key for authenticating requests to the Google AI Studio service. |
client_params | Optional[Dict[str, Any]] | - | Additional parameters for client configuration. |
client | Optional[GenerativeModel] | - | A pre-configured instance of the Gemini client. |