Skip to content

Conversation

@ThomasK33
Copy link
Member

@ThomasK33 ThomasK33 commented Nov 18, 2025

Add Google as a model provider with support for Gemini 3.

Changes

  • Add @ai-sdk/google dependency
  • Add Google provider creation in AIService with lazy loading pattern matching Anthropic/OpenAI
  • Add GoogleProviderOptions to MuxProviderOptions type system
  • Add GOOGLE_API_KEY and GOOGLE_BASE_URL environment variable support
  • Add GEMINI_3_PRO to KNOWN_MODELS with gemini-2.5-pro tokenizer
  • Add Google fallback to tokenizer (google/gemini-2.5-pro)
  • Add test coverage for Gemini 3 tokenization and thinking policy

Usage

Configure via ~/.mux/providers.jsonc:

{
  "google": {
    "apiKey": "YOUR_GOOGLE_API_KEY"
  }
}

Or via environment variable:

export GOOGLE_API_KEY="your-api-key"

Reference the model as:

  • google:gemini-3-pro-preview
  • gemini-3 (alias)
  • gemini-3-pro (alias)

Infrastructure

The following infrastructure already supported Google:

  • ✅ Tool definitions (google_search)
  • ✅ Slash command registry
  • ✅ Model display formatting

Testing

  • ✅ Tokenizer tests pass
  • ✅ Thinking policy tests pass
  • ✅ Type checking passes

Generated with mux

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ThomasK33 ThomasK33 force-pushed the gemini-3 branch 2 times, most recently from d7900cb to dbd3cb0 Compare November 18, 2025 17:00
@ThomasK33
Copy link
Member Author

@codex review

1 similar comment
@ThomasK33
Copy link
Member Author

@codex review

@ThomasK33 ThomasK33 force-pushed the gemini-3 branch 2 times, most recently from 110cc66 to ed356d3 Compare November 18, 2025 17:09
@ThomasK33
Copy link
Member Author

@codex review

@ThomasK33 ThomasK33 force-pushed the gemini-3 branch 2 times, most recently from d709c89 to f106a23 Compare November 18, 2025 17:14
@chatgpt-codex-connector
Copy link

Codex Review: Didn't find any major issues. Hooray!

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ThomasK33
Copy link
Member Author

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ThomasK33
Copy link
Member Author

@codex review

@ThomasK33 ThomasK33 force-pushed the gemini-3 branch 3 times, most recently from 159011d to 6f9eeaf Compare November 18, 2025 17:36
@coder coder deleted a comment from chatgpt-codex-connector bot Nov 18, 2025
@ThomasK33
Copy link
Member Author

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ThomasK33 ThomasK33 added this pull request to the merge queue Nov 18, 2025
@ThomasK33 ThomasK33 removed this pull request from the merge queue due to a manual request Nov 18, 2025
@ThomasK33 ThomasK33 force-pushed the gemini-3 branch 3 times, most recently from 920bb07 to cab4532 Compare November 18, 2025 18:16
- Add @ai-sdk/google dependency
- Add Google provider creation logic with lazy loading
- Add GOOGLE_API_KEY and GOOGLE_BASE_URL environment variable support
- Add Gemini 3 model (google:gemini-3-pro-preview-11-2025) to knownModels
- Configure Gemini 3 to use gemini-2.5-pro tokenizer
- Add Google fallback tokenizer (gemini-2.5-pro)
- Add GoogleProviderOptions interface for future extensions
- Add test coverage for Gemini 3 tokenizer and thinking policy

_Generated with `mux`_

Change-Id: I818b008d5a2528f600298e622e1cca63a80fe2a2
Signed-off-by: Thomas Kosiewski <tk@coder.com>
@ThomasK33 ThomasK33 enabled auto-merge November 18, 2025 18:17
@ThomasK33 ThomasK33 added this pull request to the merge queue Nov 18, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Nov 18, 2025
@ThomasK33 ThomasK33 added this pull request to the merge queue Nov 18, 2025
Merged via the queue into main with commit 5e96883 Nov 18, 2025
15 checks passed
@ThomasK33 ThomasK33 deleted the gemini-3 branch November 18, 2025 18: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.

1 participant