Skip to main content
QUICK REVIEW

[論文レビュー] Do LLMs Know about Hallucination? An Empirical Investigation of LLM's Hidden States

Hanyu Duan, Yi Yang|arXiv (Cornell University)|Feb 15, 2024
Insurance and Financial Risk Management被引用数 4
ひとこと要約

この論文は、大規模言語モデル(LLMs)が応答生成中の隠れ状態を分析することで、幻覚について内部的に認識しているかを調査している。LLaMAモデルを用いた、正しい回答と幻覚的な回答を比較する制御された実験フレームワークを用いて、著者らは、真実の応答と捏造された応答の両方に対して、LLMsが明確に異なる隠れ状態のダイナミクスを示すことを発見した。これにより、幻覚認識度を測る指標が導出され、学習された正しい応答方向を用いた活性化工学による新たな幻覚緩和戦略が可能になった。

ABSTRACT

Large Language Models (LLMs) can make up answers that are not real, and this is known as hallucination. This research aims to see if, how, and to what extent LLMs are aware of hallucination. More specifically, we check whether and how an LLM reacts differently in its hidden states when it answers a question right versus when it hallucinates. To do this, we introduce an experimental framework which allows examining LLM's hidden states in different hallucination situations. Building upon this framework, we conduct a series of experiments with language models in the LLaMA family (Touvron et al., 2023). Our empirical findings suggest that LLMs react differently when processing a genuine response versus a fabricated one. We then apply various model interpretation techniques to help understand and explain the findings better. Moreover, informed by the empirical observations, we show great potential of using the guidance derived from LLM's hidden representation space to mitigate hallucination. We believe this work provides insights into how LLMs produce hallucinated answers and how to make them occur less often.

研究の動機と目的

  • 隠れ表現を分析することで、LLMsが幻覚について内部的に認識しているかを調査すること。
  • 同一の質問条件下で、正しい応答と幻覚的な応答を処理する際の隠れ状態遷移を比較すること。
  • 隠れ状態の差に基づいて、LLMsの幻覚認識度を定量化可能な指標として開発すること。
  • 隠れ状態表現から得られるガイダンスが、LLMsの出力における幻覚を低減できるかを検討すること。
  • 学習された正しい応答方向を用いた活性化工学の有効性を、LLMsの真実性への応答を指向させるために評価すること。

提案手法

  • 同じ質問を持つが、一方は正しい回答、他方は幻覚的な回答を持つ二入力の実験フレームワークを設計する。
  • 最終トランスフォーマーレイヤーから、3つの主要な隠れ状態を抽出する:s₁(質問のみ)、s₂(質問+幻覚的応答)、s₃(質問+正しい応答)。
  • 主成分分析(PCA)を用いて、隠れ状態空間における主要な方向を特定する:d_corr(正しい遷移方向)とd_halluc(幻覚的遷移方向)。
  • 各デコードステップで、スケーリングされたd_corrベクトル(α=100)を最終隠れ状態に加えることで、活性化工学を適用し、真実性への指向を促進する。
  • TruthfulQAおよびHaluEvalデータセット上で、d_corrオフセットを適用した場合としない場合のモデル出力を比較し、緩和効果を評価する。
  • 解釈可能性技術(例:PCA、アテンション解析)を用いて、隠れ状態の差を説明し、認識度指標の妥当性を検証する。
Figure 1: Experimental framework, including two independent inputs (i.e., hallucinated input and correct input) and three critical hidden states ( $\bm{s_{1}}$ , $\bm{s_{2}}$ , and $\bm{s_{3}}$ ). <Question> and <Answer> are templates that are adaptable and can be customized to suit various tasks.
Figure 1: Experimental framework, including two independent inputs (i.e., hallucinated input and correct input) and three critical hidden states ( $\bm{s_{1}}$ , $\bm{s_{2}}$ , and $\bm{s_{3}}$ ). <Question> and <Answer> are templates that are adaptable and can be customized to suit various tasks.

実験結果

リサーチクエスチョン

  • RQ1LLMsは、正しい応答と幻覚的な応答を処理する際、異なる隠れ状態のダイナミクスを示すか?
  • RQ2隠れ状態表現は、LLMsの幻覚認識の内部的認識をどの程度反映できるか?
  • RQ3正しい応答への隠れ状態遷移方向を特定し、モデル行動の指向に利用できるか?
  • RQ4正しい応答遷移方向を隠れ状態に注入することで、LLMsの応答における幻覚が低減するか?
  • RQ5幻覚認識度の水準は、モデルの不確実性と応答の信頼性とどの程度相関するか?

主な発見

  • LLMsは、正しい応答と幻覚的な応答を処理する際、顕著に異なる隠れ状態の遷移を示しており、幻覚についての内部的認識があることを示唆している。
  • 最終隠れ状態は、幻覚的応答よりも正しい応答に対してより感受性が高く、真実性との強い内部信号の整合性があることを示している。
  • 隠れ状態の差から導出された幻覚認識度指標は、モデルの不確実性と応答の信頼性と相関している。
  • 正しい応答遷移方向(d_corr)を戦略的に隠れ状態に注入することで、幻覚が低減し、テスト例の100%で真実との整合性が向上した。
  • 活性化工学アプローチにより、33%のケース(例:例#1)で誤った応答が正しいものに逆転し、他のケースでは要約の簡潔さと包括性が向上した。
  • 正しい遷移と幻覚的遷移の間の効果量の差(e_corr - e_halluc)は、中程度から上位のトランスフォーマーレイヤーで最も顕著であり、95%信頼区間では一貫した傾向が確認された。
Figure 2: Awareness score distributions. We mark the average score for each model in red.
Figure 2: Awareness score distributions. We mark the average score for each model in red.

より良い研究を、今すぐ始めましょう

論文の読解から最終レビューまで、研究時間を劇的に削減しましょう。

クレジットカード登録不要

このレビューはAIが作成し、人間の編集者が確認しました。