风海网 > 杂谈 > 正文

​Gemma 比 Mistral 强?Gemma 多平台使用指南

2025-07-28 03:41 来源:风海网 点击:

Gemma 比 Mistral 强?Gemma 多平台使用指南

2024年2月21日,来自 Google DeepMind 的 Gemma 团队宣布了一个突破性的进展——Gemma,这是基于 Gemini 技术研发的轻量级、前沿的开放模型。

DeepMind 提供了两种规模的 Gemma 模型——20亿参数和70亿参数。

70亿参数模型专为 GPU 和 TPU 的高效部署与开发而设计,而20亿参数模型则为 CPU 和移动设备应用提供了支持。

这两种模型均提供了预训练和细化调整(fine-tuned)的检查点,以便于研究者和开发者使用。

https://blog.google/technology/developers/gemma-open-models/

https://ai.google.dev/gemma

DeepMind 在博文和给出的动态图里展示的数据显示 Gemma 7B 性能出众;但一些博主不这么认为。

https://www.youtube.com/watch?v=1Mn0U6HGLeg

Gemma 使用指南:

1. Perplexity

https://labs.perplexity.ai/

2. Hugging Face

https://huggingface.co/chat

3. Ollama

https://ollama.com/library/gemma/tags

4. LM Studio

5. Apple MLX

https://huggingface.co/mlx-community

对在 Ollama 或 LM Studio里使用 Gemma 不满意的话,可以试下Apple MLX。

Gemma 模型可能一般,但是 Google 提供了一些详细的配套服务。

6. Colab- Gemma 模型入门

https://colab.research.google.com/github/google/generative-ai-docs/blob/main/site/en/gemma/docs/get_started.ipynb

免费用户就可以通过Colab 运行 Gemma。

Colab-用 LORA 对 Gemma 模型进行微调

https://colab.research.google.com/github/google/generative-ai-docs/blob/main/site/en/gemma/docs/lora_tuning.ipynb

在多个GPUs/TPUs上微调 Gemma 模型

https://www.kaggle.com/code/nilaychauhan/keras-gemma-distributed-finetuning-and-inference

7. Google Vertex AI

首次使用 Google Cloud 用户还可以获得300美元积分,积分可用 Gemma 模型部署与训练。

https://console.cloud.google.com/vertex-ai/publishers/google/model-garden/335

谷歌还提供了 Responsible Generative AI 工具包,为使用 Gemma 创建更安全的 AI 应用程序提供了指导和基本工具。

https://ai.google.dev/responsible?utm_source=agd&utm_medium=referral&utm_campaign=explore-responsible&utm_content&hl=zh-cn

就目前我电脑里 Ollama 现有的模型而言,我更喜欢 yi-6b、yi-34b、llava-7b、openhermes-7b-mistral-v2.5 模型。

期待后续基于 Gemma 的模型在 lmsys 榜上有名。

https://huggingface.co/spaces/lmsys/chatbot-arena-leaderboard