-
Notifications
You must be signed in to change notification settings - Fork 36
Gemma3 initial commit #102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 11 commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
5f7d603
Gemma3 initial commit
chapman20j 9434fbe
kv cache
chapman20j 3ddf0b0
Added partial support for sharding
chapman20j 214bc75
sharding
chapman20j 92e690a
access token check for testing
chapman20j 6494de0
hf token test
chapman20j 40bd528
test sharding updates
chapman20j ab31f86
test updates
chapman20j 4f842f8
Merge branch 'main' into gemma3
jenriver 2aa7891
updated make input
chapman20j eec2a85
Merge branch 'main' into gemma3
jenriver e3a5aae
responding to comments
chapman20j eb755a9
put back check_hf_token
chapman20j fc60566
test sharding access token
chapman20j f1d92b1
separate prefill and decode
chapman20j 3b3ab07
update readme
chapman20j 4395971
Update remaining tasks in README
jenriver 1894e5f
Update section headers
jenriver c9f1b0f
Merge branch 'main' into gemma3
jenriver 1207450
ruff cleanup
jenriver File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,26 @@ | ||
| # Qwen3 in JAX | ||
|
|
||
| This directory contains a pure JAX implementation of the [Gemma3 model](https://deepmind.google/models/gemma/gemma-3/), using the [Flax NNX](https://flax.readthedocs.io/en/v0.8.3/experimental/nnx/index.html) API. | ||
|
|
||
| Note that you need an access token to download the model weights. In order to run the scripts, make sure to save an environment variable `HF_TOKEN` with your huggingface access token. | ||
|
|
||
|
|
||
| ## Model Configuration Support Status | ||
|
|
||
|
|
||
| ### Running this model | ||
|
|
||
|
|
||
| ```sh | ||
| python3 -m bonsai.models.gemma3.tests.run_model | ||
| ``` | ||
|
|
||
|
|
||
| ## How to contribute to this model | ||
|
|
||
| ### Remaining Tasks | ||
|
|
||
| 1. Implement with batching. Need this for FSDP. | ||
| 2. Optimize based on the profiling. | ||
| 3. Clean up code (variable names, etc.). Simplify unused configs (marked these with TODO) or use them. | ||
| 4. Update to include other model sizes and optimize parameter loading. | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.