Skip to content

fix(models): restore vertex flex on 3.7 flash - #3651

Merged
steebchen merged 1 commit into
mainfrom
fix/vertex-gemini-37-flash-flex
Aug 17, 2026
Merged

steebchen merged 1 commit into
mainfrom
fix/vertex-gemini-37-flash-flex

Conversation

@steebchen

Copy link
Copy Markdown
Member

Problem

google-vertex/gemini-3.7-flash rejects service_tier: "flex" with
unsupported_service_tier, even though every other Gemini Vertex mapping
in the catalogue offers Flex and Google's Flex PayGo docs list the model
on the global endpoint.

The mapping was added on the model's launch day (#3592), where a live
probe returned 400 "Flex API is not supported for model", so only
priority was declared. That is the same day-one rollout gap that
produced #3170 → #3176 for gemini-3.6-flash.

Fix

Declare serviceTiers: ["flex", "priority"] on the google-vertex
mapping and drop the now-stale comment. Catalogue-only change; the tier
headers, pricing multipliers and e2e cases are all derived from it.

Verification

  • Direct Vertex probe (global endpoint, OAuth,
    X-Vertex-AI-LLM-Request-Type: shared +
    X-Vertex-AI-LLM-Shared-Request-Type: flex): HTTP 200 with
    usageMetadata.trafficType: ON_DEMAND_FLEX, three consecutive runs.
    Priority still returns ON_DEMAND_PRIORITY.
  • Through the gateway (local build, x-no-fallback): flex →
    requested_service_tier: flex, used_service_tier: flex, input cost
    9 × 0.75e-6 × 0.5 = 3.375e-6 (Flex 0.5× multiplier). priority →
    9 × 0.75e-6 × 1.8 = 1.215e-5.
  • E2E: TEST_MODELS="google-vertex/gemini-3.7-flash" FULL_MODE=true pnpm test:e2e — the two new Flex cases (non-streaming + streaming,
    including the multiplier-scaled cost assertion) pass alongside the
    existing Priority ones. The only failures in the scoped run are in
    keys-provider.e2e.ts for unrelated providers whose keys are missing
    from this machine's local env.
  • Unit: 299/301 files pass. The two failures
    (onboarding-sponsorship.spec.ts, and a logs.spec.ts case that
    hardcodes the default gateway port) reproduce on the unmodified
    baseline and on the isolated-stack ports respectively.
  • pnpm format and full pnpm build pass.

🤖 Generated with Claude Code

Vertex now serves Flex PayGo for gemini-3.7-flash on the global
endpoint; the launch-day "Flex API is not supported for model"
rejection no longer reproduces.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings August 17, 2026 11:21

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@steebchen, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 14 minutes

Limit details: You’ve used all 4 included reviews currently available under your plan.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 5de4743a-8eac-4827-82a7-9b4e643ae646

📥 Commits

Reviewing files that changed from the base of the PR and between b202926 and df5e8d4.

📒 Files selected for processing (1)
  • packages/models/src/models/google.ts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@steebchen
steebchen merged commit ea171fe into main Aug 17, 2026
21 checks passed
@steebchen
steebchen deleted the fix/vertex-gemini-37-flash-flex branch August 17, 2026 11:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants