v0.4.0 - Intelligent Gemini Free Model Rotation & Optimized Model Defaults
What's Changed in v0.4.0
🔄 Intelligent Gemini Free Model Rotation & HTTP 429 Failover
- Automatic 429 Failover: When hitting rate limits or daily quota exhaustion on \gemini_free, the client automatically cascades through 11 text models (\gemini-3.5-flash-lite, \gemini-3.1-flash-lite, \gemini-3.7-flash, \gemini-3.6-flash, \gemini-3.5-flash, \gemini-2.5-flash-lite, \gemini-2.5-flash, \gemma-4-31b-it, \gemma-4-26b-a4b-it) and 7 multimodal vision models.
- Dynamic Cooldown Management: Temporarily cools down depleted models to prevent wasted HTTP calls.
- Optimized Free Default: Switched default \GEMINI_FREE_MODEL\ to \gemini-3.5-flash-lite\ (500 RPD / 15 RPM).
- Pro Tier Flagship Model: Set \GEMINI_PRO_MODEL\ default to \gemini-3.1-pro\ (\gemini-3.1-pro-preview) with automatic shorthand alias normalization.
- 100% Free Multi-Provider Fallback Gateway: Added \AIGateway.auto_fallback_free()\ for instant zero-cost multi-provider resilience (Gemini Free ➔ Groq ➔ Cerebras ➔ Nvidia NIM ➔ OrcaRouter ➔ Mistral ➔ Cohere ➔ OpenRouter).
🧪 Tests & Docs
- Added comprehensive unit tests for text model rotation, vision model rotation, and \�uto_fallback_free\ (37/37 passing).
- Added dedicated cookbooks and architectural guides in READMEs and Integration Guide.
Full Changelog: v0.3.1...v0.4.0