Manifold-based Sampling for In-Context Hallucination Detection in Large Language Models

Bodla Krishna Vamshi, Rohan Bhatnagar, Haizhao Yang
1/8/2026
cs.LGcs.AIcs.CL

No confident code implementation found for this paper. 2 possible matches can be shown below.

Abstract

Large language models (LLMs) frequently generate factually incorrect or unsupported content, commonly referred to as hallucinations. Prior work has explored decoding strategies, retrieval augmentation, and supervised fine-tuning for hallucination detection, while recent studies show that in-context learning (ICL) can substantially influence factual reliability. However, existing ICL demonstration selection methods often rely on surface-level similarity heuristics and exhibit limited robustness across tasks and models. We propose MB-ICL, a manifold-based demonstration sampling framework for selecting in-context demonstrations that leverages latent representations extracted from frozen LLMs. By jointly modeling local manifold structure and class-aware prototype geometry, MB-ICL selects demonstrations based on their proximity to learned prototypes rather than lexical or embedding similarity alone. Across factual verification (FEVER) and hallucination detection (HaluEval) benchmarks, MB-ICL outperforms standard ICL selection baselines in the majority of evaluated settings, with particularly strong gains on dialogue and summarization tasks. The method remains robust under temperature perturbations and model variation, indicating improved stability compared to heuristic retrieval strategies. While lexical retrieval can remain competitive in certain question-answering regimes, our results demonstrate that manifold-based prototype selection provides a reliable and training light approach for hallucination detection without modifying LLM parameters, offering a principled direction for improved ICL demonstration selection.

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. 2 weaker matches are hidden by default — 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{vamshi2026manifoldbased,
  title  = {Manifold-based Sampling for In-Context Hallucination Detection in Large Language Models},
  author = {Bodla Krishna Vamshi and Rohan Bhatnagar and Haizhao Yang},
  year   = {2026},
  eprint = {2601.06196},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2601.06196v2}
}

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/2601.06196.svg)](https://codeofpaper.com/paper/2601.06196)

Discussion