{"id":13478015,"url":"https://github.com/google-deepmind/gemma","last_synced_at":"2025-05-12T13:32:32.656Z","repository":{"id":223716031,"uuid":"760683276","full_name":"google-deepmind/gemma","owner":"google-deepmind","description":"Gemma open-weight LLM library, from Google DeepMind","archived":false,"fork":false,"pushed_at":"2025-05-08T16:52:10.000Z","size":808,"stargazers_count":3244,"open_issues_count":76,"forks_count":441,"subscribers_count":38,"default_branch":"main","last_synced_at":"2025-05-08T17:46:45.262Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://gemma-llm.readthedocs.io","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/google-deepmind.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-02-20T18:39:01.000Z","updated_at":"2025-05-08T10:42:01.000Z","dependencies_parsed_at":"2024-07-31T02:41:38.920Z","dependency_job_id":"6e1977e3-6131-4822-8d4c-9b8b90ee581e","html_url":"https://github.com/google-deepmind/gemma","commit_stats":null,"previous_names":["google-deepmind/gemma"],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google-deepmind%2Fgemma","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google-deepmind%2Fgemma/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google-deepmind%2Fgemma/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google-deepmind%2Fgemma/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/google-deepmind","download_url":"https://codeload.github.com/google-deepmind/gemma/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253748007,"owners_count":21957848,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-31T16:01:51.301Z","updated_at":"2025-05-12T13:32:32.472Z","avatar_url":"https://github.com/google-deepmind.png","language":"Jupyter Notebook","funding_links":[],"categories":["Python","🧠 基盤モデル 2026","Repos","Jupyter Notebook","Materials","🧠 Open-Source Models for Agents","🏭 Industrial / Production Model Reports","2. Open Foundation Models"],"sub_categories":["Google DeepMind","GitHub repositories","Benchmarks","🔁 Iterative Self-Bootstrapping"],"readme":"# Gemma\n\n[![Unittests](https://github.com/google-deepmind/gemma/actions/workflows/pytest_and_autopublish.yml/badge.svg)](https://github.com/google-deepmind/gemma/actions/workflows/pytest_and_autopublish.yml)\n[![PyPI version](https://badge.fury.io/py/gemma.svg)](https://badge.fury.io/py/gemma)\n[![Documentation Status](https://readthedocs.org/projects/gemma-llm/badge/?version=latest)](https://gemma-llm.readthedocs.io/en/latest/?badge=latest)\n\n[Gemma](https://ai.google.dev/gemma) is a family of open-weights Large Language\nModel (LLM) by [Google DeepMind](https://deepmind.google/), based on Gemini\nresearch and technology.\n\nThis repository contains the implementation of the\n[`gemma`](https://pypi.org/project/gemma/) PyPI package. A\n[JAX](https://github.com/jax-ml/jax) library to use and fine-tune Gemma.\n\nFor examples and use cases, see our\n[documentation](https://gemma-llm.readthedocs.io/). Please\nreport issues and feedback in\n[our GitHub](https://github.com/google-deepmind/gemma/issues).\n\n### Installation\n\n1.  Install JAX for CPU, GPU or TPU. Follow the instructions on\n    [the JAX website](https://jax.readthedocs.io/en/latest/installation.html).\n1.  Run\n\n    ```sh\n    pip install gemma\n    ```\n\n### Examples\n\nHere is a minimal example to have a multi-turn, multi-modal conversation with\nGemma:\n\n```python\nfrom gemma import gm\n\n# Model and parameters\nmodel = gm.nn.Gemma3_4B()\nparams = gm.ckpts.load_params(gm.ckpts.CheckpointPath.GEMMA3_4B_IT)\n\n# Example of multi-turn conversation\nsampler = gm.text.ChatSampler(\n    model=model,\n    params=params,\n    multi_turn=True,\n)\n\nprompt = \"\"\"Which of the two images do you prefer?\n\nImage 1: \u003cstart_of_image\u003e\nImage 2: \u003cstart_of_image\u003e\n\nWrite your answer as a poem.\"\"\"\nout0 = sampler.chat(prompt, images=[image1, image2])\n\nout1 = sampler.chat('What about the other image ?')\n```\n\nOur documentation contains various Colabs and tutorials, including:\n\n* [Sampling](https://gemma-llm.readthedocs.io/en/latest/colab_sampling.html)\n* [Multi-modal](https://gemma-llm.readthedocs.io/en/latest/colab_multimodal.html)\n* [Fine-tuning](https://gemma-llm.readthedocs.io/en/latest/colab_finetuning.html)\n* [LoRA](https://gemma-llm.readthedocs.io/en/latest/colab_lora_sampling.html)\n* ...\n\nAdditionally, our\n[examples/](https://github.com/google-deepmind/gemma/tree/main/examples) folder\ncontain additional scripts to fine-tune and sample with Gemma.\n\n### Learn more about Gemma\n\n* To use this library: [Gemma documentation](https://gemma-llm.readthedocs.io/)\n* Technical reports for metrics and model capabilities:\n  * [Gemma 1](https://goo.gle/GemmaReport)\n  * [Gemma 2](https://goo.gle/gemma2report)\n  * [Gemma 3](https://storage.googleapis.com/deepmind-media/gemma/Gemma3Report.pdf)\n* Other Gemma implementations and doc on the\n  [Gemma ecosystem](https://ai.google.dev/gemma/docs)\n\n### Downloading the models\n\nTo download the model weights. See\n[our documentation](https://gemma-llm.readthedocs.io/en/latest/checkpoints.html).\n\n### System Requirements\n\nGemma can run on a CPU, GPU and TPU. For GPU, we recommend 8GB+ RAM on GPU for\nThe 2B checkpoint and 24GB+ RAM on GPU are used for the 7B checkpoint.\n\n### Contributing\n\nWe welcome contributions! Please read our [Contributing Guidelines](./CONTRIBUTING.md) before submitting a pull request.\n\n*This is not an official Google product.*\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoogle-deepmind%2Fgemma","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgoogle-deepmind%2Fgemma","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoogle-deepmind%2Fgemma/lists"}