Skip to content

[Internal Testing] Promote Gemini 3.1 Flash Lite to GA and support Gemini 3.5 Flash#27705

Open
sripasg wants to merge 2 commits into
release/v0.42.0-nightly.20260512.gc987b9939from
internal_testing_release_branch_35_branch
Open

[Internal Testing] Promote Gemini 3.1 Flash Lite to GA and support Gemini 3.5 Flash#27705
sripasg wants to merge 2 commits into
release/v0.42.0-nightly.20260512.gc987b9939from
internal_testing_release_branch_35_branch

Conversation

@sripasg

@sripasg sripasg commented Jun 6, 2026

Copy link
Copy Markdown
Contributor

Summary

This commit merges and unifies three separate lines of changes onto the release branch:

  1. Gemini 3.1 Flash Lite GA Promotion (PR 27071): Replaces retired preview models (e.g. gemini-3.1-flash-lite-preview / none) with the stable gemini-3.1-flash-lite GA model and updates the default auto-routing and policy chains to use it as the main lightweight fallback/utility tier.
  2. Gemini 3.5 Flash Experiment Hook (PR 27570): Introduces experimental logic (GEMINI_3_5_FLASH_GA_LAUNCHED) and backend capability switches to transition users over to Gemini 3.5 Flash when experiment flag values are present.
  3. Gemini 3.5 Flash GA Backend Support (PR 27645): Fully wires up dynamic model configuration aliases, default policies, and resolver mapping layers to respect backend definition limits and API-key-specific fallback paths for both Gemini 3.5 Flash and gemini-3-flash-preview.
  4. Vertex ai model mapping fix (PR 27749): LOGIN_WITH_GOOGLE and COMPUTE_ADC auth types hit CCPA which routes gemini-3-flash to gemini-3.5-flash on their end, but they do not accept gemini-3.5-flash as the model ID. This updates calls to them as the exception rather than the rule, and sets the default 3.5 flash model to be gemini-3.5-flash and only changes it to gemini-3-flash when it should be hitting CCPA.

Details

1. Core Model Configurations & Resolutions (packages/core/src/config/)

  • models.ts
    • Marked PREVIEW_GEMINI_FLASH_LITE_MODEL as deprecated ('none') and promoted DEFAULT_GEMINI_FLASH_LITE_MODEL ('gemini-3.1-flash-lite') to GA.
    • Added DEFAULT_GEMINI_3_5_FLASH_MODEL ('gemini-3.5-flash') and SECONDARY_GEMINI_3_5_FLASH_MODEL ('gemini-3-flash').
    • Updated resolveModel and resolveClassifierModel to dynamically route alias strings (auto, pro, flash) depending on user preview permissions and 3.5 Flash experiment access flags.
  • defaultModelConfigs.ts
    • Structured new dynamic auto resolutions (auto-gemini-3, auto-gemini-2.5, flash) using conditional contexts matching useGemini3_5Flash and hasAccessToPreview.
    • Configured distinct classifier routing lists for flash and pro tiers that resolve cleanly to gemini-3.5-flash or gemini-3-flash-preview based on user flags.
  • config.ts
    • Added hasGemini35FlashGAAccess() to probe runtime experiments and configure default flash models (setFlashModels).
    • Integrated getReleaseChannel() helper mapping back to the standard version channel.

2. Policy Chains & Fallback Mechanics (packages/core/src/availability/)

  • policyHelpers.ts
    • Updated policy-slicing logic (resolvePolicyChain) to dynamically check for useGemini3_5Flash flags.
    • Added family-based auto-routing fallbacks for Gemini 3 chains to wrap around cleanly when primary choices are exhausted.
  • policyCatalog.ts
    • Updated getModelPolicyChain templates to conditionally load proModel overrides based on the 3.5 Flash GA launch settings.

3. Routing Strategies (packages/core/src/routing/strategies/)

  • Updated classifier strategies (approvalModeStrategy, classifierStrategy, gemmaClassifierStrategy, numericalClassifierStrategy, overrideStrategy) to pass the useGemini3_5Flash access context into all model resolution calls, ensuring aligned and predictable routing behavior across the agent workflow.

4. Frontend & Terminal UI (packages/cli/src/ui/components/)

  • ModelDialog.tsx
    • Updated the manual model selection UI to correctly sort and render the new GA models (gemini-3.1-flash-lite, gemini-3.5-flash).
    • Filtered out retired/retired-preview options (like none) from the selectable list.
  • Updated related UI layouts, snapshot tests, and markdown helper guides to reflect the consolidated model list.

How to Validate

Do Sanity testing with Zed / Jetbrains

Pre-Merge Checklist

  • [NA] Updated relevant documentation and README (if needed)
  • Added/updated tests (if needed)
  • [NA] Noted breaking changes (if any)
  • Validated on required platforms/methods:
    • MacOS
      • npm run
      • npx
      • Docker
      • Podman
      • Seatbelt
    • Windows
      • npm run
      • npx
      • Docker
    • Linux
      • npm run
      • npx
      • Docker

@sripasg sripasg requested review from a team as code owners June 6, 2026 00:01
@github-actions github-actions Bot added the size/xl An extra large PR label Jun 6, 2026
@github-actions

github-actions Bot commented Jun 6, 2026

Copy link
Copy Markdown

📊 PR Size: size/XL

  • Lines changed: 3321
  • Additions: +2676
  • Deletions: -645
  • Files changed: 78

@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request streamlines the model management lifecycle by promoting Gemini 3.1 Flash Lite to GA and introducing support for Gemini 3.5 Flash. The changes include a significant refactor of the core configuration, policy resolution, and routing strategies to support dynamic model switching based on experiment flags and user permissions. Additionally, legacy preview models have been cleaned up across the codebase to ensure a consistent user experience in the CLI and terminal UI.

Highlights

  • Gemini 3.1 Flash Lite GA Promotion: Promoted Gemini 3.1 Flash Lite to General Availability and updated default routing to utilize it as the primary lightweight model.
  • Gemini 3.5 Flash Integration: Added backend support and experimental hooks for Gemini 3.5 Flash, allowing dynamic model resolution based on user experiment flags.
  • Model Configuration Refactoring: Unified model resolution logic and policy chains to dynamically handle alias routing and fallback paths for the new model tiers.
  • Cleanup and UI Updates: Removed retired preview models from the CLI selection UI and updated documentation to reflect the new GA model landscape.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@github-actions

github-actions Bot commented Jun 6, 2026

Copy link
Copy Markdown

Size Change: +5.43 kB (+0.02%)

Total Size: 34.1 MB

Filename Size Change
./bundle/chunk-2VN4JRMH.js 0 B -3.43 kB (removed) 🏆
./bundle/chunk-4QV5LXQH.js 0 B -49.2 kB (removed) 🏆
./bundle/chunk-CBFTUCIV.js 0 B -659 kB (removed) 🏆
./bundle/chunk-IU6WVMXH.js 0 B -12.5 kB (removed) 🏆
./bundle/chunk-NJD7UGDD.js 0 B -19.5 kB (removed) 🏆
./bundle/chunk-QEYXXWKI.js 0 B -3.8 kB (removed) 🏆
./bundle/chunk-SAKTCNAD.js 0 B -1.97 MB (removed) 🏆
./bundle/chunk-UR2LFJNW.js 0 B -14.8 MB (removed) 🏆
./bundle/chunk-YKOOP47M.js 0 B -2.78 MB (removed) 🏆
./bundle/core-2T4WPGHV.js 0 B -49.3 kB (removed) 🏆
./bundle/devtoolsService-Y2DPIT6D.js 0 B -28 kB (removed) 🏆
./bundle/gemini-MWAUDT2F.js 0 B -587 kB (removed) 🏆
./bundle/interactiveCli-NRU4PLGC.js 0 B -1.3 MB (removed) 🏆
./bundle/liteRtServerManager-ZS5CPTH4.js 0 B -2.11 kB (removed) 🏆
./bundle/oauth2-provider-EBVC377F.js 0 B -9.16 kB (removed) 🏆
./bundle/chunk-3UESIFF4.js 19.5 kB +19.5 kB (new file) 🆕
./bundle/chunk-4IX5WQJR.js 3.43 kB +3.43 kB (new file) 🆕
./bundle/chunk-CTHIRQAU.js 3.8 kB +3.8 kB (new file) 🆕
./bundle/chunk-DDCIGEBR.js 12.5 kB +12.5 kB (new file) 🆕
./bundle/chunk-H55PGYQA.js 14.8 MB +14.8 MB (new file) 🆕
./bundle/chunk-MP5GFWFY.js 2.78 MB +2.78 MB (new file) 🆕
./bundle/chunk-O5Y62WHY.js 49.2 kB +49.2 kB (new file) 🆕
./bundle/chunk-SKXVK2D6.js 659 kB +659 kB (new file) 🆕
./bundle/chunk-VZ7AO3SU.js 1.98 MB +1.98 MB (new file) 🆕
./bundle/core-UNH2EQHH.js 49.6 kB +49.6 kB (new file) 🆕
./bundle/devtoolsService-SGDEE745.js 28 kB +28 kB (new file) 🆕
./bundle/gemini-6IOU6SRG.js 587 kB +587 kB (new file) 🆕
./bundle/interactiveCli-USJ4SEMN.js 1.3 MB +1.3 MB (new file) 🆕
./bundle/liteRtServerManager-G7RE67N5.js 2.11 kB +2.11 kB (new file) 🆕
./bundle/oauth2-provider-DZ2UOJ66.js 9.16 kB +9.16 kB (new file) 🆕
ℹ️ View Unchanged
Filename Size Change
./bundle/bundled/third_party/index.js 8 MB 0 B
./bundle/chunk-34MYV7JD.js 2.45 kB 0 B
./bundle/chunk-5AUYMPVF.js 858 B 0 B
./bundle/chunk-5PS3AYFU.js 1.18 kB 0 B
./bundle/chunk-664ZODQF.js 124 kB 0 B
./bundle/chunk-DAHVX5MI.js 206 kB 0 B
./bundle/chunk-IUUIT4SU.js 56.5 kB 0 B
./bundle/chunk-RJTRUG2J.js 39.8 kB 0 B
./bundle/cleanup-XML2LBWT.js 0 B -932 B (removed) 🏆
./bundle/devtools-36NN55EP.js 696 kB 0 B
./bundle/dist-T73EYRDX.js 356 B 0 B
./bundle/events-XB7DADIJ.js 418 B 0 B
./bundle/examples/hooks/scripts/on-start.js 188 B 0 B
./bundle/examples/mcp-server/example.js 1.43 kB 0 B
./bundle/gemini.js 5.1 kB 0 B
./bundle/getMachineId-bsd-TXG52NKR.js 1.55 kB 0 B
./bundle/getMachineId-darwin-7OE4DDZ6.js 1.55 kB 0 B
./bundle/getMachineId-linux-SHIFKOOX.js 1.34 kB 0 B
./bundle/getMachineId-unsupported-5U5DOEYY.js 1.06 kB 0 B
./bundle/getMachineId-win-6KLLGOI4.js 1.72 kB 0 B
./bundle/memoryDiscovery-QD2WWMTN.js 0 B -980 B (removed) 🏆
./bundle/multipart-parser-KPBZEGQU.js 11.7 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/client/main.js 222 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/src/_client-assets.js 229 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/src/index.js 13.4 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/src/types.js 132 B 0 B
./bundle/sandbox-macos-permissive-open.sb 890 B 0 B
./bundle/sandbox-macos-permissive-proxied.sb 1.31 kB 0 B
./bundle/sandbox-macos-restrictive-open.sb 3.36 kB 0 B
./bundle/sandbox-macos-restrictive-proxied.sb 3.56 kB 0 B
./bundle/sandbox-macos-strict-open.sb 4.82 kB 0 B
./bundle/sandbox-macos-strict-proxied.sb 5.02 kB 0 B
./bundle/src-QVCVGIUX.js 47 kB 0 B
./bundle/start-WGLFLTVM.js 0 B -652 B (removed) 🏆
./bundle/tree-sitter-7U6MW5PS.js 274 kB 0 B
./bundle/tree-sitter-bash-34ZGLXVX.js 1.84 MB 0 B
./bundle/cleanup-HKYOLMQ5.js 932 B +932 B (new file) 🆕
./bundle/memoryDiscovery-G4VSTICM.js 980 B +980 B (new file) 🆕
./bundle/start-HDHRP5NL.js 652 B +652 B (new file) 🆕

compressed-size-action

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request adds support for the Gemini 3.5 Flash GA model, updates model routing and resolution logic, and retires the Gemini 3.1 Flash Lite preview model. It also updates configuration documentation, CLI UI components, and shell tool background execution cleanup. The review feedback highlights a parsing bug in llm-judge.ts where lowercase LLM responses are incorrectly stripped, and warns against mutating global module-level variables to set flash models, which introduces severe race conditions in concurrent environments.

Note: Security Review did not run due to the size of the PR.

Comment thread evals/llm-judge.ts Outdated
Comment thread packages/core/src/config/config.ts Outdated
Comment thread packages/core/src/config/models.ts Outdated
@sripasg sripasg force-pushed the internal_testing_release_branch_35_branch branch from 6781a30 to 77dd708 Compare June 9, 2026 20:42
@sripasg sripasg requested a review from a team as a code owner June 9, 2026 20:42
@sripasg sripasg deployed to eval-gate June 9, 2026 20:42 — with GitHub Actions Active
@github-actions

Copy link
Copy Markdown

63 tests passed successfully on gemini-3-flash-preview.

🧠 Model Steering Guidance

This PR modifies files that affect the model's behavior (prompts, tools, or instructions).

  • 🚀 Maintainer Reminder: Please ensure that these changes do not regress results on benchmark evals before merging.

This is an automated guidance message triggered by steering logic signatures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/xl An extra large PR status/need-issue Pull requests that need to have an associated issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants