Gemma is considered a light version of Gemini. Classic Gemma is a lightweight Google model with 2 and 7 billion parameters that can be run on personal computers or mobile devices.
The Gemma group of models is free for personal and business use and capable of performing a wide range of tasks, such as text generation and summarization, image-to-text processing, code generation, debugging, and more.
It is loved by businesses and individuals for its customization capabilities and modest system requirements, allowing for performant outputs on purchasable computers like the Mac M series.
In this article, you’ll learn about the system requirements, tools, and workflows allowing you to run Gemma on Mac to achieve your personal or business AI goals.
Let’s get started!
Gemma’s collection of language models
Since the adoption of machine learning has surged, companies like Meta, Google, Mistral, and others have experimented with models’ architectures to create capable, lightweight solutions that will be perfect for individuals and SMBs.
The Gemma family of models is one of such experiments. It consists of several variants, each optimized for specific tasks.
Here is their short description:
Gemma: This is the first version of the model, available in 2B and 7B parameters, trained on math materials and English-language online content.
Gemma 2: This is the next generation of Gemma models, which is believed to perform better than the first. It was trained on English-language texts and science articles.
CodeGemma: CodeGemma is fine-tuned for coding tasks and was trained on the coding languages C++, C#, Go, Java, JavaScript, Kotlin, Python, and Rust. Hugging Face has a 7B CodeGemma pretrained variant for code completion and generation, a 2B pre-trained model for swift code completion, and a 7B instruction-tuned variant for coding.
DataGemma is a model that supplements its responses with data from Google Data Commons, a repository for statistical data. The DataGemma models use retrieval-augmented generation (RAG) to augment their responses with statistical data.
PaliGemma is a vision-language model that accepts images and texts and outputs ready-made texts. It is perfect for generating image descriptions, detecting objects within images, or reading embedded text.
Each model is presented on Hugging Face in several pre-trained variations, so before installing Gemma on Mac, you can select the model that best fits your specific use case.
System requirements to run Gemma on Mac
To run Gemma on your Mac, you need the following:
- A Mac, preferably from the M series
- 16GB of RAM
- 50 GB of storage
The Mac M series computers are designed to sustain machine learning workloads, yet you still need a version with at least 16 GB of RAM to run 7B or 12B Gemma models. Lighter models like Gemma 2B or CodeGemma 2B will be quite performant on Macs with 8GB RAM.
If you need a more complex model, you can rent a Mac with higher specs and run LLM remotely. This way, you can run weightier models even if your computer is not designed for computing-hungry tasks.
Tools needed for Gemma installation on Mac
The best tool to run Gemma on Mac is LM Studio. It is a beginner-level application in terms of its user-friendly interface, yet it allows you to do a wide range of tasks with LLMs.
LM Studio is integrated with Hugging Face. You can download any model directly in the app and run it from there in the chat interface.
How to run Gemma on Mac
Running Gemma on a Mac requires several steps, which are:
- Download LM Studio on your Mac
- Find the Gemma model in the list
- Download the selected model
- Load and run the model locally.
Let’s review these steps closely.
Download LM Studio on your Mac
LM Studio has a clear and straightforward setup process, which consists of several steps:
Step 1. Go to the official LM studio website and download the app on your laptop.
Step 2. Transfer the app to the Applications folder to install it.
Step 3. Find LM Studio in the Applications and run it from there.
Find the Gemma model in the list
Based on your task, find the model you need in LM Studio. For text generation, use the base Gemma and Gemma 2 models. If you need coding assistance, search for CodeGemma, and so on.
To search for the model, you should follow these steps:
Step 1. Go to the search bar.
Step 2. Type the name of the model you need in the search bar.
Step 3. Select the model with the number of parameters you need.
Download the selected model
Once you find the model you need, press the download button. The Download window will show the status of the process.
Load and run Gemma Locally
At the last stage of the process, load the model.
After this, the chat interface is launched. There, you can interact with Gemma through instructions and outputs.
Gemma use cases
Gemma is designed for natural language processing and understanding tasks, so it is perfect for the following use cases.
Research
Gemma is perfect for answering questions and research, and the DataGemma variation simplifies working with statistical data. The possibilities for text summarization enable quicker processing of research papers and reports, as well as editing and proofreading of texts.
Business
Gemma’s text summarization possibilities allow the generation of texts such as emails, ad copies, social media posts, and other business materials.
Software development
CodeGemma is a text-to-code model that enables non-techies to generate code without prior experience. Mac M4 Gemma’s performance enables frictionless code generation, completion, testing, and debugging. It is a great tool for developing Android or iOS apps.
Personal use
You can use Gemma to summarize personal documents, proofread emails, or answer questions about various matters.
Why run Gemma locally on your computer?
Running Gemma locally on your computer gives a wide range of benefits, like:
Privacy: A local model guarantees privacy as it doesn’t share data with third parties.
Offline access: You can run the downloaded model autonomously.
Capability: The Llama models make an excellent basis for various business, research, and study use cases.
Free: You can save your projects, experiment, and get great results without paying to use the model.
Summing up
Gemma excels in tasks such as development, text generation, research, and beyond. Its efficient design and capabilities allow any Mac user or business to take advantage of LLMs.
In case you want to join the AI bandwagon and test Gemma’s possibilities but lack a computer with the needed tech specs, we have a solution!
You can rent a Mac online and get access to the latest Mac M4 with 16 GB RAM for flawless experimenting with Gemma models!