fix(agentic): Use gemini-2.0-flash instead of gemini-3-flash-preview

The gemini-3-flash-preview model was returning 404 errors:
"Publisher Model was not found or your project does not have access"

Root cause: Gemini 3 Flash preview models are only available in the
'global' location, but the code was using 'us-central1'.

Switching to gemini-2.0-flash which is a stable model available in
all regional locations including us-central1.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Andrew BeveridgeandClaude Opus 4.5 committed 2025-12-30 14:20:51 -05:00
1 parent 597492b687
commit c3e12530bd
2 files changed
+7 -5

No files matched your search

@@ -5,8 +5,10 @@ from typing import Dict, Any
from .providers.config import ProviderConfig
# Default model for cloud deployments - Gemini 3 Flash via Vertex AI
DEFAULT_CLOUD_MODEL = "vertexai/gemini-3-flash-preview"
# Default model for cloud deployments - Gemini 2.0 Flash via Vertex AI
# Note: gemini-3-flash-preview requires 'global' location, not us-central1
# Using gemini-2.0-flash for broader regional availability
DEFAULT_CLOUD_MODEL = "vertexai/gemini-2.0-flash"
class ModelRouter:
@@ -19,7 +21,7 @@ class ModelRouter:
"""Choose appropriate model based on gap characteristics.
Returns model identifier in format "provider/model" for LangChain:
- "vertexai/gemini-3-flash-preview" for Gemini via Vertex AI (default)
- "vertexai/gemini-2.0-flash" for Gemini via Vertex AI (default)
- "ollama/llama3.2:latest" for local Ollama models
- "openai/gpt-4" for OpenAI models
- "anthropic/claude-3-sonnet-20240229" for Anthropic models
@@ -33,7 +35,7 @@ class ModelRouter:
if self._config.privacy_mode:
return "ollama/llama3.2:latest"
# Default to Gemini 3 Flash for all cases (fast, cost-effective)
# Default to Gemini 2.0 Flash for all cases (fast, cost-effective)
return DEFAULT_CLOUD_MODEL
+1 -1
View File
@@ -1,6 +1,6 @@
[tool.poetry]
name = "karaoke-gen"
version = "0.81.3"
version = "0.81.4"
description = "Generate karaoke videos with synchronized lyrics. Handles the entire process from downloading audio and lyrics to creating the final video with title screens."
authors = ["Andrew Beveridge <andrew@beveridge.uk>"]
license = "MIT"