Inferensys

Glossary

Programmable Bootstrapping

An extension of TFHE bootstrapping that simultaneously refreshes ciphertext noise and evaluates a univariate lookup table function, enabling non-linear operations like activation functions on encrypted data.
Data scientist building training data pipeline on laptop, data preprocessing visible, technical workspace.
CRYPTOGRAPHIC OPERATION

What is Programmable Bootstrapping?

Programmable bootstrapping is a core operation in the TFHE fully homomorphic encryption scheme that simultaneously refreshes ciphertext noise and homomorphically evaluates a univariate function.

Programmable bootstrapping is an extension of the standard bootstrapping operation in the TFHE scheme that reduces ciphertext noise while concurrently evaluating a user-defined lookup table (LUT). This single atomic operation resets the noise budget to a fixed baseline level and outputs an encryption of f(m), where f is an arbitrary univariate function encoded in the bootstrapping key.

By integrating function evaluation directly into the noise-refresh cycle, programmable bootstrapping enables efficient homomorphic evaluation of non-linear activation functions like ReLU or sigmoid without costly polynomial approximation. This mechanism is the foundational primitive behind frameworks like Concrete ML, allowing complex encrypted inference circuits to be composed from sequences of bootstrapped gate evaluations.

MECHANICS

Key Features of Programmable Bootstrapping

Programmable Bootstrapping (PBS) extends the standard noise-reduction bootstrapping of TFHE by simultaneously evaluating a univariate function encoded as a lookup table. This enables the efficient execution of non-linear operations, such as activation functions, directly on encrypted data.

01

Noise Refresh with Function Evaluation

PBS uniquely combines two critical operations into a single step. It resets the ciphertext noise budget to a nominal level, enabling unlimited computation depth, while concurrently evaluating an arbitrary univariate function f(x). This function is encoded as a lookup table (LUT) in the bootstrapping key, transforming the ciphertext from an encryption of m to an encryption of f(m) without ever decrypting.

02

Efficient Non-Linear Activation

Standard leveled HE schemes struggle with non-polynomial operations, requiring costly high-degree polynomial approximations. PBS solves this by evaluating the exact function via a lookup table.

  • Exact ReLU: Evaluates max(0, x) precisely, avoiding approximation errors.
  • Sign Function: Directly computes the sign of an encrypted value.
  • Arbitrary Activation: Any univariate function like sigmoid or tanh can be evaluated with the same cost as a simple bootstrap.
03

Lookup Table (LUT) Evaluation

The 'programmable' aspect is achieved by encoding the desired function into a test vector within the bootstrapping key. During bootstrapping, the ciphertext's phase is used to index this vector.

  • Blind Rotation: A homomorphic operation that cyclically shifts the test vector based on the encrypted message.
  • Extraction: The correct LUT entry is extracted as a new, refreshed ciphertext. This mechanism effectively performs a blind, univariate table lookup.
04

Composability and Circuit Depth

PBS is the fundamental building block for constructing deep encrypted neural networks. Because each PBS operation outputs a refreshed ciphertext with low noise, the output can be immediately used in subsequent operations.

  • Unlimited Depth: Enables the evaluation of circuits of arbitrary multiplicative depth.
  • Chaining Operations: A linear layer (additions/multiplications) can be followed by a PBS-based activation, and this pattern can be repeated indefinitely, making it ideal for deep learning inference.
05

Gate Bootstrapping vs. Programmable Bootstrapping

It's crucial to distinguish standard TFHE bootstrapping from PBS.

  • Standard Gate Bootstrapping: Refreshes noise and evaluates a NAND gate to enable binary circuit evaluation.
  • Programmable Bootstrapping: Refreshes noise and evaluates a full univariate function over a larger message space (e.g., 8-bit integers), not just a binary gate. PBS is a generalization that operates on multi-bit messages, making it suitable for arithmetic computations in neural networks.
06

PBS with Multi-Bit Precision

While early PBS implementations operated on single bits, modern schemes like TFHE-rs and Concrete support multi-bit PBS. This allows a single bootstrapping operation to process several bits of precision simultaneously.

  • Throughput: Significantly increases the amortized throughput of encrypted computation.
  • Trade-off: Multi-bit PBS increases the bootstrapping key size and computational cost per operation but reduces the total number of operations required for a given circuit, often resulting in a net latency reduction.
PROGRAMMABLE BOOTSTRAPPING

Frequently Asked Questions

Clear answers to the most common technical questions about the TFHE operation that simultaneously refreshes ciphertext noise and evaluates univariate functions.

Programmable Bootstrapping (PBS) is a cryptographic operation in the TFHE scheme that simultaneously refreshes a ciphertext's exhausted noise budget and evaluates a univariate lookup table (LUT) function on the encrypted plaintext. Unlike standard bootstrapping, which only resets noise, PBS performs a blind rotation of an encrypted test polynomial that encodes the desired function's output values. The operation homomorphically extracts the correct coefficient from the rotated polynomial, producing a fresh ciphertext of the function's output with low noise. This enables the evaluation of arbitrary non-linear functions—such as activation functions, sign checks, or quantization—directly on encrypted data without decryption, making it the foundational primitive for encrypted neural network inference in frameworks like Concrete ML.

Prasad Kumkar

About the author

Prasad Kumkar

CEO & MD, Inference Systems

Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.

His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.