Google Gemini
Google's Gemini models offer strong multimodal capabilities and competitive pricing.
Setup
- Get an API key from aistudio.google.com/apikey
- In Alma, go to Settings → Providers → Add Provider
- Select Google as the provider type
- Enter your API key
- Click Save
Available Models
| Model | Description | Context Window |
|---|---|---|
| gemini-2.0-flash-exp | Latest experimental model | 1M |
| gemini-1.5-pro | Most capable production model | 2M |
| gemini-1.5-flash | Fast and efficient | 1M |
| gemini-1.5-flash-8b | Smallest, fastest option | 1M |
Features
Massive Context Window
Gemini models support extremely long context:
- Up to 2 million tokens for Gemini 1.5 Pro
- Ideal for analyzing entire codebases or books
Multimodal
Gemini natively supports:
- Text
- Images
- Audio
- Video
- Code
Grounding
Gemini can be grounded with Google Search for up-to-date information.
Image Generation
Some Gemini models can generate images directly.
Configuration
Base URL
Leave empty for official Google AI API. Google Cloud Vertex AI uses a different endpoint.
Pricing
Gemini offers generous free tiers and competitive paid pricing. See Google AI pricing.
Troubleshooting
"API Key Invalid"
- Ensure you're using a Google AI Studio key (not Cloud API key)
- Check the key at aistudio.google.com
"Model Not Available"
- Some models are region-restricted
- Try a different model variant
"Safety Filter Triggered"
- Gemini has built-in safety filters
- Rephrase your request
