Share your thoughts, 1 month free Claude Pro on usSee more
WorkDL logo mark

Kernel Language Entropy: Fine-grained Uncertainty Quantification for LLMs from Semantic Similarities

About

Uncertainty quantification in Large Language Models (LLMs) is crucial for applications where safety and reliability are important. In particular, uncertainty can be used to improve the trustworthiness of LLMs by detecting factually incorrect model responses, commonly called hallucinations. Critically, one should seek to capture the model's semantic uncertainty, i.e., the uncertainty over the meanings of LLM outputs, rather than uncertainty over lexical or syntactic variations that do not affect answer correctness. To address this problem, we propose Kernel Language Entropy (KLE), a novel method for uncertainty estimation in white- and black-box LLMs. KLE defines positive semidefinite unit trace kernels to encode the semantic similarities of LLM outputs and quantifies uncertainty using the von Neumann entropy. It considers pairwise semantic dependencies between answers (or semantic clusters), providing more fine-grained uncertainty estimates than previous methods based on hard clustering of answers. We theoretically prove that KLE generalizes the previous state-of-the-art method called semantic entropy and empirically demonstrate that it improves uncertainty quantification performance across multiple natural language generation datasets and LLM architectures.

Alexander Nikitin, Jannik Kossen, Yarin Gal, Pekka Marttinen• 2024

Related benchmarks

TaskDatasetResultRank
Question AnsweringTriviaQA
EM70.4
182
Question Answering5 QA tasks
Accuracy54.02
78
Uncertainty EstimationTriviaQA--
77
Multi-answer Question AnsweringMAQA-ΔK−1
KL Divergence0.365
48
Uncertainty QuantificationVision Datasets averaged (test)
AUROC74.7
36
Uncertainty QuantificationLongFact
PCC-0.04
32
Uncertainty QuantificationBio
PCC-0.295
32
SummarizationCNN/DailyMail
Hamming Score-0.276
28
Uncertainty QuantificationWMT 19
COMET AUC0.608
28
Machine TranslationWMT19
COMET Score0.323
28
Showing 10 of 24 rows

Other info

Follow for update