Hallucination Detection on a Budget: Efficient Bayesian Estimation of Semantic Entropy

Kamil Ciosek, Nicolò Felicioni, Sina Ghiassian
4/4/2025
cs.LG

No confident code implementation found for this paper.

Abstract

Detecting whether an LLM hallucinates is an important research challenge. One promising way of doing so is to estimate the semantic entropy (Farquhar et al., 2024) of the distribution of generated sequences. We propose a new algorithm for doing that, with two main advantages. First, due to us taking the Bayesian approach, we achieve a much better quality of semantic entropy estimates for a given budget of samples from the LLM. Second, we are able to tune the number of samples adaptively so that `harder' contexts receive more samples. We demonstrate empirically that our approach systematically beats the baselines, requiring only 53% of samples used by Farquhar et al. (2024) to achieve the same quality of hallucination detection as measured by AUROC. Moreover, quite counterintuitively, our estimator is useful even with just one sample from the LLM.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{ciosek2025hallucination,
  title  = {Hallucination Detection on a Budget: Efficient Bayesian Estimation of Semantic Entropy},
  author = {Kamil Ciosek and Nicolò Felicioni and Sina Ghiassian},
  year   = {2025},
  eprint = {2504.03579},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2504.03579v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2504.03579.svg)](https://codeofpaper.com/paper/2504.03579)

Discussion