# Build an Offline Gemma Translator

> Google Creative Lab's open-source prototype runs speech recognition, Gemma 4 E2B translation and speech synthesis on a Raspberry Pi 5, with no network required after setup.

_Source: Android Authority report cross-checked against the google-gemma/gemma-translator repository · 2026-08-08 · 8 min read · Verified against primary sources_

Canonical: https://iyu.app/e/gemma-4-offline-translator-raspberry-pi

## The 60-second version

Google Creative Lab released a buildable Raspberry Pi voice translator whose recognition, Gemma translation and speech output all run locally after setup.

**Key points**

- The current implementation uses Gemma 4 E2B through LiteRT-LM, correcting early E4B coverage.
- The reference build needs a Raspberry Pi 5 with 8 GB RAM, local audio hardware, a display and at least 6 GB of free storage for model setup.
- The complete bundled voice path supports Arabic, English, Spanish, Japanese, Chinese and Korean.
- Code, setup scripts and enclosure STL files are open under Apache 2.0, but the project is not an officially supported Google product.
- No accuracy, latency, power or battery benchmark has been published, so critical translations still need verification.

**Verdict.** It is a convincing offline edge-AI reference build, not evidence that a Raspberry Pi now replaces a professional interpreter or mature cloud translator.

## Full explainer

> **i** This is an **open-source Google Creative Lab experiment**, not a supported Google product or a new Google Translate appliance. The repository explicitly disclaims official product support.


### The short version — A complete voice pipeline runs on one Pi

The project turns a Raspberry Pi 5 into a two-person voice translator. Once models and dependencies are downloaded, speech recognition, translation and speech synthesis run locally without a network request.

The useful part is not merely that Gemma can translate text. The repository packages the full chain: microphone input, local transcription, Gemma inference, local voice output, a compact interface, deployment scripts and printable enclosure files.


### Architecture — Three local models do different jobs

- **1. Speech to text:** Moonshine transcribes microphone audio locally for the selected source language.
- **2. Translation:** LiteRT-LM runs the instruction-tuned Gemma 4 E2B model on the Raspberry Pi CPU.
- **3. Text to speech:** moonshine-voice synthesizes the translated text using a local language-specific voice.
- **Interface:** A React kiosk presents two language lanes and coordinates push-to-talk, translation and playback.

> **↯** Early coverage called the model **Gemma 4 E4B**. The current README and `download_model.sh` use **Gemma 4 E2B**, which is the version builders will actually download.


### Supported speech — The bundled pipeline has six languages

- **6** — speech languages in the current code
- **8 GB** — RAM on the reference Raspberry Pi 5
- **6 GB** — minimum free space checked before model import

The checked-in frontend and backend map Arabic, English, Spanish, Japanese, Chinese and Korean across recognition and voice output. Gemma may know additional languages, but the complete voice product only works when STT and TTS also support the pair.


### Hardware — What the reference build requires

- **Compute:** Raspberry Pi 5 with 8 GB RAM.
- **Audio input:** A microphone or USB audio capture interface.
- **Audio output:** A speaker, headphones or another supported output device.
- **Display:** A monitor or small touchscreen, with the interface designed for roughly 480 × 320.
- **Enclosure:** Optional STL files are included for a 3D-printed case.
- **Storage:** The downloader expects about 2.6 GB for the download and another 2.6 GB for the imported model, then requires at least 6 GB free.


### Build path — From repository to kiosk

- **1.** Clone `google-gemma/gemma-translator` on Linux, macOS or the Raspberry Pi.
- **2.** Make `setup.sh`, `download_model.sh`, `start.sh` and `deploy-pi.sh` executable.
- **3.** Run `./setup.sh` to create the Python environment and install Node and application dependencies.
- **4.** Run `./download_model.sh` while online to download and import Gemma 4 E2B into LiteRT-LM.
- **5.** Use `./start.sh` for development, or `./deploy-pi.sh` to build a systemd-backed Chromium kiosk on Raspberry Pi OS or Debian.

The current interface is keyboard-driven. In landscape mode, Space switches the active speaker, Z is push-to-talk and the arrow keys rotate languages. Vertical mode gives each speaker a separate set of keys. Physical buttons and a rotary controller can map to those inputs, but touch recording controls are not enabled in the current frontend.


### Why offline matters — Useful without pretending it is magic

- **Connectivity:** Normal translation can continue after setup without Wi-Fi or cellular service.
- **Data path:** Audio, transcript, translation and synthesized speech stay in the local stack during ordinary use.
- **Cost:** There is no per-request cloud inference charge after the hardware and model are installed.
- **Trade-off:** The device is larger, uses more power and may be slower or less accurate than a cloud service.
- **Maintenance:** The owner must update dependencies, secure the device and manage physical access and any local logs.


### Evidence limits — A demo is not a benchmark

> **⚑ Caveat:** The repository does not publish translation accuracy, end-to-end latency, power draw or battery-life measurements. The demo verifies that the pipeline runs, not that it matches professional interpreting or cloud translation quality.

Test every target language pair, speaker accent and noise environment before relying on it. Names, numbers, medical directions, legal terms and emergency instructions should always be repeated or independently checked.

The practical takeaway: this is a strong edge-AI reference design and a buildable travel or field-work tool, but it remains a maker project. Use the source code as a platform, not the demo video as a quality guarantee.


## Primary sources

- [Android Authority — Google built a portable AI translator that works offline](https://www.androidauthority.com/google-offline-ai-translator-gemma-4-3695674/)
- [Google Gemma — Gemma Translator source repository](https://github.com/google-gemma/gemma-translator)
- [Google AI Edge — LiteRT-LM](https://github.com/google-ai-edge/LiteRT-lm)
- [LiteRT community — Gemma 4 E2B instruction model](https://huggingface.co/litert-community/gemma-4-E2B-it-litert-lm)

---
_Published by iyu (https://iyu.app) — the day's AI news, checked against primary sources and rewritten in plain language. Free to quote with attribution and a link to the canonical URL._
