Skip to main content
QUICK REVIEW

[논문 리뷰] INSIDE: LLMs' Internal States Retain the Power of Hallucination Detection

Chao Chen, Kai Liu|arXiv (Cornell University)|2024. 02. 06.
Academic Publishing and Open AccessDecision Sciences인용 수 3
한 줄 요약

이 논문은 대규모 언어 모델의 내부 상태를 활용하여 의미 일관성의 정도를 측정하기 위해 임bedding 공분산 고유값 기반의 EigenScore를 사용하고, 테스트 시 특징 클리핑을 적용하여 과신된 생성을 줄이는 프레임워크 INSIDE를 제안한다. 이 방법은 후행적 언어 수준의 일관성 검사에 의존하지 않고 밀도 높은 의미 표현을 직접 분석함으로써 다양한 QA 벤치마크에서 최신 기술 수준의 성능을 달성한다.

ABSTRACT

Knowledge hallucination have raised widespread concerns for the security and reliability of deployed LLMs. Previous efforts in detecting hallucinations have been employed at logit-level uncertainty estimation or language-level self-consistency evaluation, where the semantic information is inevitably lost during the token-decoding procedure. Thus, we propose to explore the dense semantic information retained within LLMs' extbf{IN}ternal extbf{S}tates for halluc extbf{I}nation extbf{DE}tection ( extbf{INSIDE}). In particular, a simple yet effective extbf{EigenScore} metric is proposed to better evaluate responses' self-consistency, which exploits the eigenvalues of responses' covariance matrix to measure the semantic consistency/diversity in the dense embedding space. Furthermore, from the perspective of self-consistent hallucination detection, a test time feature clipping approach is explored to truncate extreme activations in the internal states, which reduces overconfident generations and potentially benefits the detection of overconfident hallucinations. Extensive experiments and ablation studies are performed on several popular LLMs and question-answering (QA) benchmarks, showing the effectiveness of our proposal.

연구 동기 및 목표

  • 디코딩 과정에서 의미 정보를 손실하는 로짓 수준 및 언어 수준의 환각 탐지 방법의 한계를 해결하기 위해.
  • LLM의 내부 상태에 유지되는 밀도 높은 의미 정보가 더 정확한 환각 탐지에 기여할 수 있는지 탐색하기 위해.
  • 임베딩 공간의 성질을 분석하여 일관성 없는 환각과 과신된 환각을 모두 탐지하는 방법을 개발하기 위해.
  • 외부 모델이 필요 없이 사실적으로 잘못된 생성을 식별함으로써 실생활 응용에서 LLM의 신뢰도를 향상시키기 위해.

제안 방법

  • 디코딩된 텍스트나 로짓에 의존하지 않고 LLM의 내부 상태를 사용하는 일반화된 프레임워크인 INSIDE를 제안한다.
  • 다중 응답 임베딩의 공분산 행렬의 고유값을 계산하여 밀도 높은 임베딩 공간 내의 의미 일관성/다양성을 측정하는 지표인 EigenScore를 도입한다.
  • EigenScore가 임베딩 공간 내의 미분 엔트로피와 상관이 있음을 입증하여 불확실성의 대체 지표로 기능함을 보여준다.
  • 내부 상태의 극단적 활성화를 잘라내는 테스트 시 특징 클리핑 기법을 적용하여 과신된 생성을 감소시킨다.
  • 각 프롬프트당 다수의 생성을 통해 자동회귀 디코딩을 수행하고 EigenScore를 계산하며 일관성 불일치를 탐지한다.
  • AUROC 및 정확도 측정을 통한 평가를 위해 표준 QA 벤치마크(예: CoQA, LLaMA-7B)를 사용하며, 다양한 임계값 하에서 성능을 분석한다.
Figure 1: Illustration of our proposed hallucination detection pipeline. During inference time, for a given question, the extreme features in the penultimate layer are truncated and the EigenScore is computed based on the sentence embeddings across multiple responses.
Figure 1: Illustration of our proposed hallucination detection pipeline. During inference time, for a given question, the extreme features in the penultimate layer are truncated and the EigenScore is computed based on the sentence embeddings across multiple responses.

실험 결과

연구 질문

  • RQ1LLM의 내부 상태가 후행적 언어 수준의 방법보다 환각을 더 효과적으로 탐지할 수 있도록 충분한 의미 정보를 유지할 수 있는가?
  • RQ2임베딩 공분산 고유값에서 유도된 EigenScore 지표는 의미 일관성을 어떻게 반영하고 환각을 탐지하는가?
  • RQ3추론 중 특징 클리핑을 적용하면 일관성 기반 방법이 놓치는 과신된 환각을 감소시킬 수 있는가?
  • RQ4제안된 방법은 온도 및 top-k와 같은 다양한 LLM 및 하이퍼파라미터에 대해 얼마나 강건한가?

주요 결과

  • EigenScore는 CoQA 및 LLaMA-7B에서 모든 정확도 임계값에서 퍼즐리티, LN-엔트로피, 어휘 유사도와 같은 베이스라인 방법보다 뛰어난 성능을 보이며, 0.9 유사도 임계값에서 AUROC 80.4를 달성한다.
  • 이 방법은 다양한 모델과 벤치마크에서 뛰어난 성능을 보이며 특정 아키텍처에 국한되지 않는 광범위한 적용 가능성을 시사한다.
  • 특징 클리핑은 극단적 활성화를 감소시켜 과신된 환각 탐지에 크게 기여하며, 특히 고온 설정에서 두드러진 효과를 보인다.
  • 민감도 분석 결과 성능는 온도에 매우 민감한 반면 top-k에는 덜 민감하며, 최적의 성능는 0.1~1.0 범위에서 관찰된다.
  • EigenScore 지표는 임베딩 공간 내의 미분 엔트로피를 효과적으로 포착하여 이론적 기반으로서의 일관성 측정의 타당성을 입증한다.
  • 추가 모델이나 파인튜닝 없이도 최신 기술 수준의 환각 탐지 성능을 달성한다.
(a) Neuron Activation
(a) Neuron Activation

더 나은 연구,지금 바로 시작하세요

논문 읽기부터 검토까지, 연구 시간을 획기적으로 줄여보세요.

카드 등록 없음 · 무료 플랜 제공

이 리뷰는 AI가 만들고, 인간 에디터가 검토했습니다.