Hugging Face Blog

Towards Encrypted Large Language Models with FHE

arXiv Machine Learning
Oct 19

Practical and Private Hybrid ML Inference with Fully Homomorphic Encryption

arXiv:2509.01253v2 Announce Type: replace-cross Abstract: In contemporary cloud-based services, protecting users' sensitive data and ensuring the confidentiality of the server's model are critical. F...

By Sayan Biswas, Philippe Chartier, Akash Dhasade, Tom Jurien, David Kerriou, Anne-Marie Kerrmarec, Mohammed Lemou, Franklin Tranie, Martijn de Vos, Milos Vujasinovic
arXiv AI
1d ago

Felid: A Flexible and Efficient Design for Transformer Fine-Tuning over Encrypted Data

Felid introduces a flexible packing strategy and operation‑specific matrix evaluation algorithms to reduce ciphertext rotations, relinearizations, and bootstrapping calls in fully homomorphic encryption (FHE) for transformer fine‑tuning. The framework achieves a 30× reduction in rotations and relinearizations and a 2.5× reduction in bootstrapping invocations, enabling a 2‑layer BERT‑style model to fine‑tune in 650 seconds—an 8× speedup over prior work.

By Linru Zhang, Jun Jie Sim, Xiangning Wang, Jiahao Zhong, Kaiyu Zhou, Huanyi Ye, Yongsen Zheng, Lushan Song, Xiaojian Liang, Yingting Liu, Yujing Sun, Huaxiong Wang, Pu Duan, Kwok-Yan Lam
arXiv AI
Sep 11

Arbitrary Cipher Attacks Against Large Language Models Do Not Require Fine-Tuning

The paper reports that large language models can acquire cipher-based covert communication skills without fine‑tuning, using prompting or in‑context learning instead. This enables new jailbreak attacks that bypass alignment safeguards by encrypting harmful requests, making them appear as nonsensical text to harmfulness classifiers. The authors demonstrate successful attacks against frontier models from Anthropic, Google, and OpenAI.

By Thomas Rivasseau
arXiv AI
Sep 3

HEAT: Faster Fully Homomorphic Inference via Approximations-Weights Co-Adaptation

HEAT introduces a fine‑tuning method that treats the number of iterations used to approximate nonlinearities in fully homomorphic encryption (FHE) as learnable parameters, allowing them to co‑adapt with model weights. By optimizing iteration counts per nonlinearity, HEAT reduces the required iterations, bootstraps, and overall latency for encrypted GPT‑2 decoding while improving decode agreement. The approach achieves a 3.1× reduction in iterations, a 1.6× reduction in bootstraps, and a 1.4× speed‑up in end‑to‑end latency without changing the model architecture or requiring retraining from scratch.

By Alessandro Zirilli, Davide Marincione, Evgenios M. Kornaropoulos, Giuseppe Ateniese, Emanuele Rodol\`a
arXiv AI
Oct 27

Pacifo: An Efficient Fully Homomorphic Encryption-based Lightweight ResNet for Trustworthy Machine Learning as a Service

Pacifo is a framework that adapts fine‑tuning strategies to efficiently run the ResNet20 model using Fully Homomorphic Encryption (FHE). It introduces a public‑private layer partitioning scheme and an efficient ReLU approximation, reducing private layers and costly FHE operations during inference. Compared to state‑of‑the‑art FHE implementations, Pacifo achieves a 3.7–21.7× speedup while preserving 95–99 % of the original plaintext model accuracy.

By Yang Li, Gang He, Ruichen Zhang, Guangyuan Liu, Yinqiu Liu
arXiv AI
Oct 26

TensorCommitments: A Lightweight Verifiable Inference for Large Language Models

TensorCommitments (TCs) is a lightweight, tensor-native proof‑of‑inference scheme designed to enable verifiable inference for large language models (LLMs). It binds each LLM inference to a commitment using multivariate Terkle Trees, ensuring that any tampering breaks the commitment. For the LLaMA2 model, TC adds only 0.97% overhead for the prover and 0.12% for the verifier, while improving robustness to tailored attacks by up to 48% compared to prior work that requires a verifier GPU.

By Oguzhan Baser, Elahe Sadeghi, Eric Wang, Nico Vergauwen, Sam Kazemian, Hong Kang, Sandeep P. Chinchali, Sriram Vishwanath