feat(gemma): initial implementation of Gemma model and configs

- Add core Gemma model (architecture, attention, GeGLU, RoPE, RMSNorm, etc)
- Add configs for training and generation: gemma_train.json, gemma_generate.json
- Add Gemma notebook for exploratory analysis and demonstration
- Add __init__.py for Gemma submodule
- Update run_llm_experiment.py to support Gemma experiment configs

test(gemma): add comprehensive unit tests for Gemma

- Test forward pass (with/without cache)
- Test autoregressive generation (greedy, top-k, top-p)
- Test shape correctness and max sequence length errors
- Test multi-layer stack and token embeddings

docs: add documentation notebook for Gemma usage and analysis

Closes: #issue (if applicable)
This commit is contained in:
Sergey Penkovsky
2025-10-21 01:02:15 +03:00
parent 58c4a00b48
commit cfb4b6dfb1
7 changed files with 1905 additions and 0 deletions

1344
notebooks/gemma.ipynb Normal file

File diff suppressed because it is too large Load Diff