Skip to content
TopicTracker
From HackerNewsView original
TranslationTranslation

Gemma 4 in the browser with WebGPU

Google's Gemma 4 model is now available to run directly in the browser using WebGPU, enabling on-device AI inference with hardware acceleration through a Hugging Face Space and custom kernels for improved performance.

Background

- Google's Gemma 4 is a family of open-weight AI language models (successor to Gemma 2 and 3) that can run on consumer hardware. This demo shows them running entirely inside a web browser, using WebGPU — a modern browser API that gives web apps direct access to a computer's graphics card for accelerated compute. - WebGPU is designed for graphics and general-purpose GPU (GPGPU) computation on the web; it's the successor to WebGL and enables running neural networks locally without sending data to a cloud server. - "WebML" (Web Machine Learning) is a community effort to make inference (running models, not training them) happen in-browser, enabling offline-capable, private AI applications that don't require server backends. - The practical significance: users can run a capable, state-of-the-art LLM directly in their browser tab, at no cost, with data staying local. This sidesteps privacy concerns, latency, and API fees associated with cloud-based ChatGPT-style services.

Related stories