Fully Homomorphic Encryption (FHE) patterns for privacy-preserving LLM inference. Covers lattice-based cryptography (LWE/RLWE), FHE scheme selection (BFV, BGV, CKKS), and techniques for running large models on encrypted data. Based on implementation of FHE on Llama 3 for secure computation. Use when: building privacy-preserving AI inference systems, implementing homomorphic encryption for ML models, or designing secure computation pipelines for sensitive data. arXiv: 2604.12168
Scanned 9/11/2026
Install to Claude Code
npx -y skills add hiyenwong/ai_collection --skill fhe-privacy-preserving-llm --agent claude-codeInstalls into .claude/skills of the current project.
Are you the author of Fhe Privacy Preserving Llm?
Add the live security badge to your README — it updates automatically with every re-scan.
[](https://www.skillsdirectory.com/skills/hiyenwong-fhe-privacy-preserving-llm)More formats (shields.io, HTML) on the badges page.
---
name: fhe-privacy-preserving-llm
description: >
Fully Homomorphic Encryption (FHE) patterns for privacy-preserving LLM inference.
Covers lattice-based cryptography (LWE/RLWE), FHE scheme selection (BFV, BGV, CKKS),
and techniques for running large models on encrypted data. Based on implementation
of FHE on Llama 3 for secure computation. Use when: building privacy-preserving
AI inference systems, implementing homomorphic encryption for ML models,
or designing secure computation pipelines for sensitive data.
arXiv: 2604.12168
---
# Fully Homomorphic Encryption for Privacy-Preserving LLM Inference
FHE patterns and methodologies for secure LLM inference on encrypted data.
## Core Architecture
### FHE Scheme Selection
- **BFV/BGV**: Integer arithmetic, exact computation
- **CKKS**: Approximate arithmetic, floating-point support
- **TFHE**: Boolean logic, gate-level operations
### LLM-FHE Integration Patterns
1. **Weight encryption**: Encrypt model weights, compute on plaintext input
2. **Input encryption**: Encrypt user input, compute with plaintext weights
3. **Hybrid approach**: Selective encryption for sensitive layers only
### Performance Optimization
- SIMD batching for parallel computation
- Bootstrapping strategies for depth management
- Approximate activation functions compatible with FHE
## Implementation Workflow
1. Choose FHE scheme based on computation type
2. Quantize model weights for FHE compatibility
3. Implement encrypted matrix multiplication kernels
4. Design bootstrapping schedule for deep networks
5. Benchmark latency and accuracy trade-offs
## Key References
- arXiv:2604.12168 - Fully Homomorphic Encryption on Llama 3 model for privacy preserving LLM inference
- Lattice-based cryptography foundations (LWE, RLWE assumptions)
## Activation Keywords
- fully homomorphic encryption
- FHE LLM inference
- privacy preserving ML
- homomorphic encryption AI
- encrypted model inference
- lattice cryptography
- 全同态加密
- secure computation LLM
Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.
No comments yet. Be the first to comment!