Google AI
Google AI
Section titled “Google AI ”The google provider allows you to use Google AI models. It gives you access
Open Google AI Studio and create a new API key.
Update the
.envfile with the API key..env GEMINI_API_KEY=...Find the model identifier in the Gemini documentation and use it in your script or cli with the
googleprovider....const model = genAI.getGenerativeModel({model: "gemini-1.5-pro-latest",});...then use the model identifier in your script.
script({ model: "google:gemini-1.5-pro-latest" });
Aliases
The following model aliases are attempted by default in GenAIScript.
| Alias | Model identifier |
|---|---|
| large | gemini-1.5-flash-latest |
| small | gemini-1.5-flash-latest |
| vision | gemini-1.5-flash-latest |
| long | gemini-1.5-flash-latest |
| reasoning | gemini-2.0-flash-thinking-exp-1219 |
| reasoning_small | gemini-2.0-flash-thinking-exp-1219 |
| embeddings | text-embedding-004 |
Limitations
- Uses OpenAI compatibility layer
- listModels
- logprobs (and top logprobs) ignored
- Ignore prediction of output tokens
- Seed ignored
- Tools implemented as fallback tools automatically.
- topLogprobs