Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- **Images** — OpenAI image edits send `mask` and `reference_images` (up to 16 input images) instead of warning and dropping them; edits use the JSON `images` body, and generation with `reference_images` is served by `/images/edits` (#568).
- **Images** — OpenAI `gpt-image-2`, `gpt-image-2.5-flare` and `gpt-image-2.5-sunburst` accept any documented `WIDTHxHEIGHT` size (multiples of 16, 1:3 to 3:1, at most 3840 per edge, 655,360–8,294,400 pixels) with the standard sizes kept as presets, instead of eight fixed sizes (#564).
- **Text** — Anthropic on Claude on Google Cloud (GoogleADC) sends image and document inputs as base64 sources; the route accepts no URL sources (#570).
- **Videos** — Google `veo-3.1-generate-preview` is no longer registered: the Gemini API shut it down on October 22, 2026 and now answers 404 `NOT_FOUND`. No Veo model remains registered; Google's replacement is `gemini-omni-1.2-flash` (#585).

---

Expand Down
24 changes: 1 addition & 23 deletions src/celeste/modalities/videos/providers/google/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,29 +15,7 @@
]

# Veo API models (predictLongRunning)
GOOGLE_VEO_MODELS: list[Model] = [
Model(
id="veo-3.1-generate-preview",
provider=Provider.GOOGLE,
display_name="Veo 3.1 (Preview)",
operations={Modality.VIDEOS: {Operation.GENERATE}},
parameter_constraints={
VideoParameter.ASPECT_RATIO: Choice(options=["16:9", "9:16"]),
VideoParameter.RESOLUTION: Choice(options=["720p", "1080p", "4k"]),
VideoParameter.DURATION: Choice(options=[4, 6, 8]),
VideoParameter.REFERENCE_IMAGES: ImagesConstraint(
supported_mime_types=GOOGLE_SUPPORTED_MIME_TYPES,
max_count=3,
),
VideoParameter.FIRST_FRAME: ImageConstraint(
supported_mime_types=GOOGLE_SUPPORTED_MIME_TYPES,
),
VideoParameter.LAST_FRAME: ImageConstraint(
supported_mime_types=GOOGLE_SUPPORTED_MIME_TYPES,
),
},
),
]
GOOGLE_VEO_MODELS: list[Model] = []

# Interactions API models (Gemini Omni)
GOOGLE_OMNI_MODELS: list[Model] = [
Expand Down
17 changes: 12 additions & 5 deletions tests/unit_tests/test_google_transport.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,25 @@
import httpx
import pytest

from celeste import Modality, Provider, create_client
from celeste import Modality, Model, Provider, create_client
from celeste.artifacts import VideoArtifact
from celeste.auth import AuthHeader
from celeste.modalities.videos.providers.google.interactions import (
GoogleInteractionsVideosClient,
)
from celeste.modalities.videos.providers.google.veo import GoogleVeoVideosClient
from celeste.providers.google.auth import GoogleADC

from ._http_helpers import _mock_http, _sse


@pytest.mark.parametrize(
"model", ["veo-3.1-generate-preview", "gemini-omni-flash-preview"]
"client_type", [GoogleVeoVideosClient, GoogleInteractionsVideosClient]
)
@pytest.mark.parametrize("adc", [False, True])
async def test_google_download_auth_is_scoped_to_each_hops_origin(
model: str, adc: bool
client_type: type[GoogleVeoVideosClient | GoogleInteractionsVideosClient],
adc: bool,
) -> None:
credentials = (
{"Authorization": "Bearer test", "x-goog-user-project": "test-project"}
Expand All @@ -47,8 +52,10 @@ def handle(request: httpx.Request) -> httpx.Response:
)
return httpx.Response(200, content=b"video")

client = create_client(
modality=Modality.VIDEOS, provider=Provider.GOOGLE, model=model, auth=auth
client = client_type(
model=Model(id="test", provider=Provider.GOOGLE, display_name="test"),
provider=Provider.GOOGLE,
auth=auth,
)
async with _mock_http(handle):
with patch.object(GoogleADC, "get_headers", return_value=credentials):
Expand Down
12 changes: 8 additions & 4 deletions tests/unit_tests/test_google_videos_interactions.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,12 @@ def _client(model_id: str) -> GoogleVideosClient:
)


def test_veo_model_dispatches_to_veo_strategy() -> None:
client = _client("veo-3.1-generate-preview")
def test_veo_model_dispatches_to_veo_strategy(monkeypatch: pytest.MonkeyPatch) -> None:
monkeypatch.setattr(
"celeste.modalities.videos.providers.google.client._VEO_MODEL_IDS",
frozenset({"veo-test"}),
)
client = _client("veo-test")
assert isinstance(client._strategy, GoogleVeoVideosClient)
assert client._generate_endpoint == client._strategy._generate_endpoint
assert client._edit_endpoint == client._strategy._edit_endpoint
Expand All @@ -47,8 +51,8 @@ def test_veo_model_dispatches_to_veo_strategy() -> None:
"video", [{"gcsUri": "gs://bucket/result.mp4"}, {"bytesBase64Encoded": "dmlk"}]
)
def test_vertex_veo_parses_video_without_mutating_response(video: dict) -> None:
client = GoogleVideosClient(
model=_model("veo-3.1-generate-preview"),
client = GoogleVeoVideosClient(
model=_model("veo-test"),
provider=Provider.GOOGLE,
auth=GoogleADC(project_id="test"),
)
Expand Down
Loading