AI Newsway

Google Open-Sources HEIR, a Compiler That Runs AI Models on Encrypted Data

Four working demos aim to move homomorphic encryption from cryptography research to ordinary engineering

|3 min read0
AI Summary
Google released HEIR, an open-source compiler toolchain that converts pre-trained AI models to run on homomorphically encrypted data so servers process ciphertext without seeing inputs. It published four working private-inference demos, including a recommendation model, a credit card fraud detector, a Kitsune network anomaly detector and a hotword detector, all measured on a single-threaded CPU. Hardware partners such as Belfort, Niobium, Cornami and Optalysys are building accelerators to lower the cost.
Source code on screen, representing the HEIR compiler toolchain that rewrites AI models to operate on encrypted inputs
Source code on screen, representing the HEIR compiler toolchain that rewrites AI models to operate on encrypted inputs

Google has released HEIR, an open-source compiler toolchain designed to make homomorphic encryption usable by developers who are not cryptographers. The project, detailed on the company's security blog, can take a pre-trained AI model built to operate on ordinary data and convert it to run on encrypted inputs instead.

Homomorphic encryption allows computation to be performed directly on ciphertext. A server can process encrypted data and return an encrypted result without ever seeing what it worked on. Google's framing is that this reshapes a familiar trade-off: rather than choosing between protecting user data and offering features that depend on it, the question becomes one of cost, and that cost is falling.

The Trade-Off HEIR Targets

Standard end-to-end encryption protects data from breaches but locks the provider out of features such as spam or virus detection. Regulated sectors including healthcare and finance are especially constrained, with rules limiting how institutions share data. Running models locally instead is capped by device capability and creates a second problem, since shipping a proprietary model to a handset risks leaking it.

The obstacle has been usability rather than theory. Converting an existing program to run efficiently under homomorphic encryption has historically required a team of specialists. HEIR, short for Homomorphic Encryption Intermediate Representation, aims to collapse that into a compiler pass. Google describes the goal as a one-click path that lets non-experts add encrypted inference to production systems.

Four Working Demonstrations

To show the technology's current state, Google published four private inference applications, all compiled with HEIR and measured on a single-threaded CPU, with source code in the project's GitHub repository.

  • A deep learning recommendation model, built with Belfort Labs, LG and New York University, that serves content recommendations without the provider seeing user features.
  • A credit card fraud detector developed with Niobium and hardshell.ai.
  • An adaptation of the Kitsune anomaly detection system, also with Niobium, which flags suspicious network traffic without exposing packet contents to the service provider.
  • A hotword detector built with Belfort Labs, allowing a voice-triggered agent to recognise its wake word while the underlying audio stays private.

An Ecosystem, Not Just a Tool

Since Google signalled its intentions in 2023, HEIR has attracted partners building dedicated hardware accelerators, including Belfort, Niobium, Cornami and Optalysys. The company says it plans to demonstrate the latency gains from that silicon in the near future.

It has also become a research substrate. By building on shared infrastructure for testing and benchmarking, cryptographers can concentrate on individual optimisations rather than rebuilding a toolchain each time. Collaborations span Georgia Tech, Carnegie Mellon, UC Santa Barbara, Illinois Institute of Technology, Purdue, the University of Edinburgh and Tsinghua University, and four peer-reviewed papers have been built on the project so far.

Where This Sits

HEIR joins a privacy portfolio that already includes differential privacy, private set membership, private information retrieval and secure enclaves on Google Cloud. The distinction the company draws is that homomorphic encryption's guarantees are purely cryptographic, unlike hardware-based approaches that ultimately depend on trusting a chip vendor's isolation.

Performance remains the open question. Encrypted inference still carries meaningful overhead, and the published figures come from single-threaded CPU runs rather than tuned production deployments. Independent write-ups of the toolchain describe compiling a small TensorFlow Lite model to run under encryption with inference measured in seconds, which is workable for narrow tasks and far from interactive for large ones.

The direction is nonetheless clear. With the compiler barrier lowered and accelerators arriving from four hardware partners, private inference is shifting from a cryptography research problem toward something an ordinary engineering team can realistically evaluate.

How do you feel about this article?

SJ

Discussion

Sign in to post
Loading...

Related articles

DeepMind Precomputed 9 Billion DNA Variants Into a 1-Petabyte Atlas
AI & Machine Learning

DeepMind Precomputed 9 Billion DNA Variants Into a 1-Petabyte Atlas

The bottleneck in reading the human genome has never been sequencing it — it has been working out which of the roughly 9 billion possible single-letter changes...

Seung Jung3 days ago
Thomson Reuters Built Its Own Frontier Model for $40 Million
AI & Machine Learning

Thomson Reuters Built Its Own Frontier Model for $40 Million

Thomson Reuters launched Thomson, an in-house LLM trained for $40 million on Westlaw and Reuters archives, and says it rivals frontier models.

Seung Jung23 days ago
A Researcher Quit Anthropic Over Extinction Risk. His Safety Lead Agreed in Public.
AI & Machine Learning

A Researcher Quit Anthropic Over Extinction Risk. His Safety Lead Agreed in Public.

Jacob Coxon resigned from Anthropic over extinction risk. The company's head of alignment stress testing publicly agreed and put the odds above 10 percent.

Seung Jung7 days ago
OpenAI Says It Hit Its Automated Research Intern Goal. The Caveats Are in the Data
AI & Machine Learning

OpenAI Says It Hit Its Automated Research Intern Goal. The Caveats Are in the Data

OpenAI says agents now run 3.1 workdays of effort per human workday in its research org, but most long successful tasks still need human intervention.

Seung Jung5 days ago
A 25-Turn Pressure Test Shows LLMs Fold While Their Reasoning Holds
AI & Machine Learning

A 25-Turn Pressure Test Shows LLMs Fold While Their Reasoning Holds

A new arXiv benchmark called SPINE argues with models for up to 25 turns and finds collapse rates rise with conversation length for all seven systems tested.

Seung Jung3 days ago
An AI Cracked a 373-Year-Old Cipher. Then Someone Checked the Microfilm.
AI & Machine Learning

An AI Cracked a 373-Year-Old Cipher. Then Someone Checked the Microfilm.

Vals AI reported Claude Fable 5.1 solved a 373-year-old cipher in 44 minutes. An independent replication reports 8 of 64 letters match — chance level.

Seung Jung3 days ago