AutoGPT is the vision of accessible AI for everyone, to use and to build on. Our mission is to provide the tools, so that you can focus on what matters.
feat(backend): add Google Gemini 3.8 Flash support (#14422)
Nicholas Tindle79168d31f156
diff --git a/autogpt_platform/backend/backend/data/llm_registry/catalog.py b/autogpt_platform/backend/backend/data/llm_registry/catalog.pyindex 18f1e82b88..8385b6c1be 100644--- a/autogpt_platform/backend/backend/data/llm_registry/catalog.py+++ b/autogpt_platform/backend/backend/data/llm_registry/catalog.py@@ -585,6 +585,20 @@ def _build_catalog() -> CatalogPayload:output_credits_per_1m=1800.0,),),+ CatalogModel(+ slug="google/gemini-3.8-flash",+ display_name="Gemini 3.8 Flash",+ provider="open_router",+ creator="google",+ context_window=1048576,+ max_output_tokens=65536,+ price_tier=1,+ cost=CatalogModelCost(+ run_credits=3,+ input_credits_per_1m=112.5,+ output_credits_per_1m=562.5,+ ),+ ),CatalogModel(slug="gryphe/mythomax-l2-13b",display_name="MythoMax L2 13B",diff --git a/autogpt_platform/backend/backend/data/llm_registry/catalog_test.py b/autogpt_platform/backend/backend/data/llm_registry/catalog_test.pyindex a371f8e06e..1bec98eb7c 100644--- a/autogpt_platform/backend/backend/data/llm_registry/catalog_test.py+++ b/autogpt_platform/backend/backend/data/llm_registry/catalog_test.py@@ -198,6 +198,24 @@ def test_claude_fable_5_1_bills_at_authored_rates():assert fable_entry.context_window == 200000+def test_gemini_3_8_flash_bills_at_authored_rates():+ """Gemini 3.8 Flash (OpenRouter, Google intro list price $0.75/$3.75+ per 1M through 2026-12-31) — flat tier and per-1M projections must+ match the authored catalog entry."""+ flash = LLMModel("google/gemini-3.8-flash")+ assert MODEL_COST[flash] == 3+ assert TOKEN_COST[flash].model_dump() == {+ "input": 112.5,+ "output": 562.5,+ "cache_read": 0.0,+ "cache_creation": 0.0,+ }+ assert MODEL_METADATA[flash].max_output_tokens == 65536+ flash_entry = next(m for m in CATALOG.models if m.slug == "google/gemini-3.8-flash")+ assert flash_entry.price_tier == 1+ assert flash_entry.context_window == 1048576++def test_provider_usd_prices_are_all_or_nothing():"""A half-authored provider USD price must refuse to construct — itwould silently underprice against the transport family default."""diff --git a/autogpt_platform/backend/backend/data/llm_registry/llm_models.py b/autogpt_platform/backend/backend/data/llm_registry/llm_models.pyindex 08c88a0e0e..6dd0cfed1f 100644--- a/autogpt_platform/backend/backend/data/llm_registry/llm_models.py+++ b/autogpt_platform/backend/backend/data/llm_registry/llm_models.py@@ -199,6 +199,7 @@ class LLMModel(str, Enum, metaclass=LLMModelMeta):GEMINI_2_5_FLASH = "google/gemini-2.5-flash"GEMINI_2_0_FLASH = "google/gemini-2.0-flash-001"GEMINI_3_1_FLASH_LITE_PREVIEW = "google/gemini-3.1-flash-lite-preview"+ GEMINI_3_8_FLASH = "google/gemini-3.8-flash"GEMINI_2_5_FLASH_LITE = "google/gemini-2.5-flash-lite"GEMINI_2_0_FLASH_LITE = "google/gemini-2.0-flash-lite-001"MISTRAL_LARGE_3 = "mistralai/mistral-large-2512"