FHE ML Tuxedo: A Tailored Wrapper Architecture for Homomorphic Encryption in Machine Learning
Martin Nocker, Linus Henke, Pascal Schöttle · 2025
Privacy-preserving machine learning (PPML) commonly utilizes fully homomorphic encryption (FHE). Most FHE libraries are implemented in performance-oriented languages like C++, Go, or Rust, which can hinder adoption in Python-based machine learning (ML). Existing FHE library wrappers are typically naive and inefficient for PPML applications. We introduce the Tailored Wrapper Architecture (TWA) to develop efficient Python frontends for PPML using FHE. TWA does not depend on specific ML use cases or FHE libraries. As a proof of concept, we integrate OpenFHE into the HE-MAN compiler and compare its performance to TenSEAL and a naive OpenFHE wrapper. TWA achieves equal or better classification accuracy with comparable latency to TenSEAL and significant latency improvements over the naive wrapper, with speedups of 21 × and 13 × depending on the activation function.