Towards Fully Exploiting LLM Internal States to Enhance Knowledge Boundary Perception

Shiyu Ni, Keping Bi, Jiafeng Guo, Lulu Yu, Baolong Bi +1 more
2/17/2025
cs.CL

No official code found. Best implementation: Trustworthy-Information-Access/LLM-Knowledge-Boundary-Perception-via-Internal-States (21 stars, last commit 2025-08-05).

Abstract

Large language models (LLMs) exhibit impressive performance across diverse tasks but often struggle to accurately gauge their knowledge boundaries, leading to confident yet incorrect responses. This paper explores leveraging LLMs' internal states to enhance their perception of knowledge boundaries from efficiency and risk perspectives. We investigate whether LLMs can estimate their confidence using internal states before response generation, potentially saving computational resources. Our experiments on datasets like Natural Questions, HotpotQA, and MMLU reveal that LLMs demonstrate significant pre-generation perception, which is further refined post-generation, with perception gaps remaining stable across varying conditions. To mitigate risks in critical domains, we introduce Confidence Consistency-based Calibration ($C^3$), which assesses confidence consistency through question reformulation. $C^3$ significantly improves LLMs' ability to recognize their knowledge gaps, enhancing the unknown perception rate by 5.6% on NQ and 4.9% on HotpotQA. Our findings suggest that pre-generation confidence estimation can optimize efficiency, while $C^3$ effectively controls output risks, advancing the reliability of LLMs in practical applications.

View on arXivView PDF

Code Implementations(1)

Official code for the paper Towards Fully Exploiting LLM Internal States to Enhance Knowledge Boundary Perception. The code is based on transformers.

211Shell, PythonApr 27, 20241 years ago

Similar Papers

Cite this paper

@article{ni2025towards,
  title  = {Towards Fully Exploiting LLM Internal States to Enhance Knowledge Boundary Perception},
  author = {Shiyu Ni and Keping Bi and Jiafeng Guo and Lulu Yu and Baolong Bi and Xueqi Cheng},
  year   = {2025},
  eprint = {2502.11677},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2502.11677v2}
}

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

Discussion