From 685030152bf2ccf203f10b2346c2cafe01952440 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 6 Nov 2026 07:11:21 +0000 Subject: [PATCH] Add GPT-Image-2.6 Flare and Sunburst to the model registry Co-Authored-By: Claude Sonnet 5.5 Claude-Session: https://claude.ai/code/session_01SQvDLywpxRn4h2vDNGowPu --- CLAUDE.md | 4 ++-- README.md | 2 +- tee_gateway/model_registry.py | 35 +++++++++++++++++++++++++++++++++++ tests/test_pricing.py | 15 +++++++++++++++ 4 files changed, 53 insertions(+), 3 deletions(-) diff --git a/CLAUDE.md b/CLAUDE.md index 711f3e4..0f6d171 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -129,7 +129,7 @@ Server configuration: `model_registry.py` is the source of truth; this list mirrors it. Model name prefixes determine routing: -- **OpenAI**: gpt-6-sol, gpt-6-luna, gpt-6-astra, gpt-4.1, gpt-4.1-mini, gpt-5, gpt-5-mini, gpt-5.2, gpt-5.4, gpt-5.4-mini, gpt-5.4-nano, gpt-5.5, gpt-5.6-sol/terra/luna, o3; image generation: gpt-image-2.5-flare, gpt-image-2.5-sunburst, gpt-image-2 +- **OpenAI**: gpt-6-sol, gpt-6-luna, gpt-6-astra, gpt-4.1, gpt-4.1-mini, gpt-5, gpt-5-mini, gpt-5.2, gpt-5.4, gpt-5.4-mini, gpt-5.4-nano, gpt-5.5, gpt-5.6-sol/terra/luna, o3; image generation: gpt-image-2.6-flare, gpt-image-2.6-sunburst, gpt-image-2.5-flare, gpt-image-2.5-sunburst, gpt-image-2 - **Anthropic**: claude-sonnet-4-5/4-6, claude-sonnet-5, claude-sonnet-5-5, claude-haiku-5-5, claude-haiku-4-5, claude-opus-4-5/4-6/4-7/4-8, claude-opus-5, claude-opus-5-5, claude-fable-5, claude-fable-5-1 - **Google**: gemini-4-argon, gemini-3.8-flash, gemini-3.7-flash, gemini-3.6-flash, gemini-3.5-flash, gemini-3.5-flash-lite, gemini-2.5-flash, gemini-2.5-flash-lite, gemini-2.5-pro, gemini-3-flash-preview, gemini-3.1-pro-preview; image generation: gemini-2.5-flash-image, gemini-3.1-flash-image, gemini-nano-banana-2.1 - **xAI**: grok-4.7, grok-4.6, grok-4.5, grok-4.3, grok-4.20-reasoning, grok-4.20-non-reasoning; image generation: grok-2-image, grok-imagine-image-2.0 @@ -161,7 +161,7 @@ OpenRouter delisted it. For OpenRouter models, `openrouter.ai/api/v1/models` is authoritative for availability as well as price; a pricing page keeps quoting a rate after the endpoints are gone. -Image generation via OpenAI (gpt-image-2.5-flare, gpt-image-2.5-sunburst, gpt-image-2), xAI (grok-2-image, grok-imagine-image-2.0), ByteDance +Image generation via OpenAI (gpt-image-2.6-flare, gpt-image-2.6-sunburst, gpt-image-2.5-flare, gpt-image-2.5-sunburst, gpt-image-2), xAI (grok-2-image, grok-imagine-image-2.0), ByteDance (seedream-4.0, seedream-5.0-lite, seedance-4.5, seedance-5.0), and Z.ai (glm-image) is served through a provider `/images/generations` endpoint rather than the chat path (see `image_generation.py`), but is surfaced on `/v1/chat/completions` exactly like diff --git a/README.md b/README.md index 71a2b06..edf9524 100644 --- a/README.md +++ b/README.md @@ -43,7 +43,7 @@ The gateway solves this by running inside a hardware-isolated Nitro Enclave wher | Moonshot AI | kimi-k3.1-pro | Image generation: krea-3 and qwen-image-3.0-pro (via WaveSpeed), gpt-image-2, -gpt-image-2.5-flare, gpt-image-2.5-sunburst, gemini-2.5-flash-image, +gpt-image-2.6-flare, gpt-image-2.6-sunburst, gpt-image-2.5-flare, gpt-image-2.5-sunburst, gemini-2.5-flash-image, gemini-nano-banana-2.1, gemini-3.1-flash-image, grok-2-image, grok-imagine-image-2.0, seedream-4.0, seedream-5.0-lite, seedance-4.5, seedance-5.0, glm-image. diff --git a/tee_gateway/model_registry.py b/tee_gateway/model_registry.py index 5b4f93a..25fcceb 100644 --- a/tee_gateway/model_registry.py +++ b/tee_gateway/model_registry.py @@ -543,6 +543,38 @@ class SupportedModel(Enum): image_aspect_ratios=_GPT_IMAGE_ASPECT_SIZES, image_aspect_ratio_param="size", ) + # GPT-Image-2.6 Sunburst — successor to 2.5 Sunburst (OpenAI model page: text $5/$1.25 cached, + # image in $8/$2 cached, image out $30 per MTok — same as 2.5, so same flat per-image + # approximation). Only /images/generations + /images/edits. + GPT_IMAGE_2_6_SUNBURST = ModelConfig( + provider="openai", + api_name="gpt-image-2.6-sunburst", + input_price_usd=Decimal("0"), + output_price_usd=Decimal("0"), + image_generation=True, + per_image_price_usd=Decimal("0.05"), + image_response_format=None, + image_supports_reference=True, + image_edit_endpoint="/images/edits", + image_extra_params={"quality": "medium"}, + image_aspect_ratios=_GPT_IMAGE_ASPECT_SIZES, + image_aspect_ratio_param="size", + ) + # GPT-Image-2.6 Flare — successor to 2.5 Flare; same endpoints, token rates and request shaping. + GPT_IMAGE_2_6_FLARE = ModelConfig( + provider="openai", + api_name="gpt-image-2.6-flare", + input_price_usd=Decimal("0"), + output_price_usd=Decimal("0"), + image_generation=True, + per_image_price_usd=Decimal("0.05"), + image_response_format=None, + image_supports_reference=True, + image_edit_endpoint="/images/edits", + image_extra_params={"quality": "medium"}, + image_aspect_ratios=_GPT_IMAGE_ASPECT_SIZES, + image_aspect_ratio_param="size", + ) # GPT-Image-2.5 Flare — OpenAI's fastest model for high-quality, everyday # image generation (GA 2026-09-08), positioned as the general-purpose # successor to gpt-image-2 (50% lower latency, better reference-photo @@ -1348,6 +1380,9 @@ class SupportedModel(Enum): "gpt-6-sol": SupportedModel.GPT_6_SOL, "gpt-6-luna": SupportedModel.GPT_6_LUNA, "gpt-image-2": SupportedModel.GPT_IMAGE_2, + "gpt-image-2.6": SupportedModel.GPT_IMAGE_2_6_FLARE, + "gpt-image-2.6-flare": SupportedModel.GPT_IMAGE_2_6_FLARE, + "gpt-image-2.6-sunburst": SupportedModel.GPT_IMAGE_2_6_SUNBURST, "gpt-image-2.5": SupportedModel.GPT_IMAGE_2_5_FLARE, "gpt-image-2.5-flare": SupportedModel.GPT_IMAGE_2_5_FLARE, "gpt-image-2.5-flare-2026-09-08": SupportedModel.GPT_IMAGE_2_5_FLARE, diff --git a/tests/test_pricing.py b/tests/test_pricing.py index 09a4fb6..8e49798 100644 --- a/tests/test_pricing.py +++ b/tests/test_pricing.py @@ -325,6 +325,21 @@ def test_gpt_6_luna_resolves(self): self.assertTrue(cfg.responses_api_for_tools) self.assertFalse(cfg.supports_temperature) + def test_gpt_image_2_6_flare_resolves(self): + cfg = get_model_config("gpt-image-2.6-flare") + self.assertEqual(cfg.provider, "openai") + self.assertEqual(cfg.api_name, "gpt-image-2.6-flare") + self.assertTrue(cfg.image_generation) + self.assertEqual(cfg.per_image_price_usd, Decimal("0.05")) + self.assertEqual(get_model_config("gpt-image-2.6"), cfg) + + def test_gpt_image_2_6_sunburst_resolves(self): + cfg = get_model_config("gpt-image-2.6-sunburst") + self.assertEqual(cfg.provider, "openai") + self.assertEqual(cfg.api_name, "gpt-image-2.6-sunburst") + self.assertTrue(cfg.image_generation) + self.assertEqual(cfg.per_image_price_usd, Decimal("0.05")) + def test_gpt_image_2_5_flare_resolves(self): cfg = get_model_config("gpt-image-2.5-flare") self.assertEqual(cfg.provider, "openai")