Skip to content

Conversation

@kanpuriyanawab
Copy link
Collaborator

  1. add save_to_preset in qwen3 moe
  2. add one more qwen3 moe checkout

@kanpuriyanawab kanpuriyanawab self-assigned this Oct 4, 2025
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @kanpuriyanawab, 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 enhances the Qwen3 Mixture-of-Experts (MoE) checkpoint conversion script by introducing support for a new model variant, Qwen3-235B-A22B. It also adds the crucial capability to save the converted models to a preset, streamlining the workflow for users. Additionally, the script's internal structure was refactored for better organization and testability.

Highlights

  • New Model Preset Support: Added a new preset, "qwen3_moe_235b_a22b_en", to the conversion script, enabling support for an additional Qwen3 Mixture-of-Experts model variant.
  • Save to Preset Functionality: Implemented the save_to_preset method call within the main conversion logic, allowing the converted Qwen3 MoE model to be saved to a specified preset path.
  • Code Refactoring: Refactored the validate_output function to improve modularity by accepting an already initialized Qwen3MoeCausalLM object, and moved its instantiation to the main execution block.
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 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 counter productive. 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.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

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.

Copy link
Contributor

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

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 a new preset for Qwen3 MoE and implements the save_to_preset functionality in the conversion script. While the main goals are met, a refactoring of the validate_output function has introduced a critical bug that will cause the script to fail with a TypeError. The CausalLM model instance is created after it is needed, and the function call that uses it has not been updated. My review includes a comment on how to fix this issue.

@sachinprasadhs sachinprasadhs merged commit 704a44a into keras-team:master Oct 6, 2025
8 checks passed
amitsrivastava78 pushed a commit to amitsrivastava78/keras-hub that referenced this pull request Oct 8, 2025
* chore- save preset

* format fix

* comments
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