SMASH 2026 · Paper #4 · Result card

Query Logs Are Patient Records: An Unguarded Attack Surface in Clinical RAG, and a Privacy-Preserving Pipeline

Louis Tremblay Thibault, Sofiane Azogagh, Marc-Olivier Killijian, Ulrich Aïvodji · École de Technologie Supérieure · Mila · EURECOM · UQAM · Read the paper

An insider rebuilt 20 of 21 synthetic patient records from the query log. Under encryption, retrieval stayed exact and 4-bit embeddings kept 97% of float nDCG@10.
your query Metastatic renal cell carcinoma, second-line therapy after progressionlogged at 14:15corpus scifact (5,183 docs)bits (encrypted run) 4clip percentile 99.9embedder potion-base-8Mclinic day 24 appointments, lag ≤ 15 min
Patient records rebuilt from the log
20 / 21
diagnosis recovered 95% (chance 1.7%), timestamp join right 100%
nDCG@10 kept at b = 4
97%
0.490 vs 0.506 float on scifact; b = 2: 0.016
Encrypted = plaintext
20 / 20
top-1 identical; scores bit-exact in 20/20 after rounding
Price of privacy (server)
14.8 s
vs 3.0 ms in the clear for 5,183 docs; ≈ 48 min at 1M (no proofs)

From the abstract

In privacy-sensitive applications, the server observes the query and controls which evidence is returned, creating both confidentiality and integrity risks. Our protocol reduces private and verifiable retrieval to multiplication of a committed matrix by an encrypted vector and uses low-bit quantization to make this computation practical.

Evidence

What an insider reads in the provider's log after one (synthetic) clinic day
What an insider reads in the provider's log after one (synthetic) clinic day
Each logged query embedding is inverted by nearest-neighbour search over a 60-diagnosis dictionary and joined to the appointment schedule by timestamp. ✓ = right diagnosis and right patient; ~ = right diagnosis, wrong patient; ✗ = wrong diagnosis. Your query (orange) maps to metastatic renal cell carcinoma. Synthetic schedule and patients.
How coarse can the encrypted embeddings be?
How coarse can the encrypted embeddings be?
Retrieval quality as each embedding dimension is rounded to b bits (needed to fit the cryptographic parameters). Squares = the paper's Table 1; circles = this run on the same public corpus with a small static embedder.
What privacy costs as the corpus grows
What privacy costs as the corpus grows
Server time for both encrypted rounds (scoring + private fetch), measured on this corpus and extrapolated linearly. The paper's numbers include succinct proofs of correct computation on a 48-core machine; ours do not.

Paper vs. your run

MetricPaperYour run
nDCG@10 at b = 4 / float (scifact)BGE-large 0.713 / 0.735; Cohere v3 0.719 / 0.7180.490 / 0.506static model2vec embedder, so lower absolute nDCG
Quality retained at b = 497% (BGE-large)97%clip at 99.9th pct of |x|
nDCG@10 at b = 20.002 (BGE-large), 0.033 (Cohere v3): collapses0.016
Server time per private query4.3–8.7 seconds (verified, SciFact/NFCorpus)14.78 s (5,183 docs)no proofs; TenSEAL CKKS, N = 8192
1M-document corpusroughly 19 minutes and $2.22≈ 48 min (linear extrapolation)no verification; different hardware
Retrieval exactnessevery document is scored … quality is not traded for privacytop-1 match 20/20; PIR fetch exact: yes

Try next

Read this before sharing