Skip to content

Fix Gemma 4 model loading and fix random outputs - #3968

Open
Zhang-JK wants to merge 3 commits into
huggingface:mainfrom
Zhang-JK:fix/gemma4
Open

Zhang-JK wants to merge 3 commits into
huggingface:mainfrom
Zhang-JK:fix/gemma4

Conversation

@Zhang-JK

@Zhang-JK Zhang-JK commented Sep 9, 2026 •

Copy link
Copy Markdown

fix #3967

changes:

  • update weight loading path to be model.language_model for language model
  • Apply the per-layer embedding for E2Band E4B
  • add shared KV for E4B model
  • fix RMSNorm, gemma 4 does not apply weight+1

verification:
image

This branch has not been deployed

No deployments
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.

Gemma 4 models cannot use

1 participant