{
  "id": "2025/1200",
  "url": "https://opencryptology.org/2025/1200",
  "original_url": "https://eprint.iacr.org/2025/1200",
  "title": "Tricycle: Private Transformer Inference with Tricyclic Encodings",
  "authors": [
    "Lawrence Lim",
    "Vikas Kalagi",
    "Julia Novick",
    "Jiaming Liu",
    "Divyakant Agrawal",
    "Amr El Abbadi"
  ],
  "affiliations": null,
  "abstract": "The growing deployment of large language models (LLMs) in privacy-sensitive settings demands inference mechanisms that preserve data confidentiality. Homomorphic encryption (HE) offers a principled solution by enabling computation directly on encrypted data; however, existing solutions struggle to scale to full LLMs. We present Tricycle, a system for efficient private transformer inference. At its core, Tricycle introduces tricyclic encodings, a novel packing scheme that enables batch matrix multiplications with optimal multiplicative depth while naturally supporting multi-head attention. We demonstrate that Tricycle's matrix multiplications are particularly amenable for integration with other optimizations including Baby-Step Giant-Step optimizations, optimized block matrix multiplications, lazy relinearization, and complexification, which significantly improve performance. We further introduce statistical max estimation, a lightweight method for stabilizing softmax under HE. We implement Tricycle end-to-end on a GPU-accelerated CKKS pipeline and evaluate it on BERT models. For BERT-Base with 128 tokens, Tricycle achieves 100.5 seconds latency on a single GPU, yielding $6\\times$ and $3.4\\times$ speedups over prior state-of-the-art systems, Thor and Powerformer, respectively. These results demonstrate that careful design of packing, algorithms, and optimizations can significantly reduce the cost of private LLM inference, bringing practical deployment closer to reality.",
  "category": "Applications",
  "license": {
    "code": "CC BY",
    "url": "https://creativecommons.org/licenses/by/4.0/",
    "label": "CC BY 4.0",
    "attribution": "“Tricycle: Private Transformer Inference with Tricyclic Encodings” by Lawrence Lim, Vikas Kalagi, Julia Novick, Jiaming Liu, Divyakant Agrawal, Amr El Abbadi, Cryptology ePrint Archive, Paper 2025/1200, https://eprint.iacr.org/2025/1200. Licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/).",
    "retroactive": false,
    "redistribute_verbatim_only": false,
    "non_commercial": false
  },
  "dates": {
    "submitted": "2025-06-27T07:40:55Z",
    "updated": "2026-09-14T22:42:15Z",
    "withdrawn": null
  },
  "withdrawn": false,
  "withdrawn_on": null,
  "pdf": {
    "url": "https://opencryptology.org/2025/1200.pdf",
    "sha256": "3daffd04b39dd1e86be60d4590ddc4c94a287701b02916dbeb5b72ff3dcf5743",
    "size": 1792243,
    "source": "wayback",
    "source_date": "2026-09-22T19:37:47Z",
    "maybe_stale": false,
    "newer_on_eprint": null,
    "withdrawn": false
  },
  "versions": [
    {
      "url": "https://opencryptology.org/2025/1200/versions/20260922T193747Z.pdf",
      "captured_at": "2026-09-22T19:37:47Z",
      "label": "copy captured 2026-09-22",
      "source": "wayback",
      "source_url": "https://web.archive.org/web/20260922193747id_/https://eprint.iacr.org/2025/1200.pdf",
      "size": 1792243,
      "sha256": "3daffd04b39dd1e86be60d4590ddc4c94a287701b02916dbeb5b72ff3dcf5743",
      "is_default_pdf": true
    },
    {
      "url": "https://opencryptology.org/2025/1200/versions/20260428T172000Z.pdf",
      "captured_at": "2026-04-28T17:20:00Z",
      "label": "copy captured 2026-04-28",
      "source": "github-mirror",
      "source_url": "https://raw.githubusercontent.com/arturo-kong/IACR-eprint-mirror/master/2025/1200.pdf",
      "size": 1371843,
      "sha256": "d97d68e2f092f3d4209675fe4dee529608efd9dac01cb8a89bd933c6b5e9c130",
      "is_default_pdf": false
    },
    {
      "url": "https://opencryptology.org/2025/1200/versions/20250630T110254Z.pdf",
      "captured_at": "2025-06-30T11:02:54Z",
      "label": "copy captured 2025-06-30",
      "source": "wayback",
      "source_url": "https://web.archive.org/web/20250630110254id_/https://eprint.iacr.org/2025/1200.pdf",
      "size": 1361993,
      "sha256": "04a3b2e3364830fc51135f353e7719e865b34d9971f1b3be1ac5d073b677482f",
      "is_default_pdf": false
    }
  ],
  "other_sources": [
    {
      "kind": "wayback",
      "url": "https://web.archive.org/web/20260922193747id_/https://eprint.iacr.org/2025/1200.pdf",
      "captured_at": "2026-09-22T19:37:47Z",
      "size": 1752861
    },
    {
      "kind": "github-mirror",
      "url": "https://raw.githubusercontent.com/arturo-kong/IACR-eprint-mirror/master/2025/1200.pdf",
      "captured_at": "2026-04-28T17:20:00Z",
      "size": 1371843
    }
  ],
  "bibtex": "@misc{cryptoeprint:2025/1200,\n      author = {Lawrence Lim and Vikas Kalagi and Julia Novick and Jiaming Liu and Divyakant Agrawal and Amr El Abbadi},\n      title = {Tricycle: Private Transformer Inference with Tricyclic Encodings},\n      howpublished = {Cryptology {ePrint} Archive, Paper 2025/1200},\n      year = {2025},\n      url = {https://eprint.iacr.org/2025/1200}\n}"
}
