arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2308.11295cs.LG
收藏

通过注意力矩阵的拓扑分析估计Transformer预测的不确定性

Uncertainty Estimation of Transformers' Predictions via Topological Analysis of the Attention Matrices

AIRI

Elizaveta Kostenok, Daniil Cherniavskii, Alexey Zaytsev

AI总结:

针对Transformer语言模型不确定性估计效果不佳的问题,提出从注意力矩阵提取拓扑特征的方法,在相关基准上显著优于现有技术,提供了更高效可解释的解决方案。

摘要:

基于Transformer的语言模型已在广泛的自然语言处理任务中刷新了基准,但可靠估计其预测的不确定性仍是一项重大挑战。现有的不确定性估计(UE)技术在分类任务中往往效果不佳,要么相比基础启发式方法提升极小,要么依赖成本高昂的集成模型。此外,在线性探测场景中尝试利用通用嵌入进行不确定性估计仅取得了有限成效,表明需要探索模型的其他组成部分。\n我们通过利用多头多层注意力图的几何结构来评估模型置信度,以解决这些局限。我们的方法从注意力矩阵中提取拓扑特征,提供了模型内部动态的低维、可解释表示。此外,我们引入拓扑特征来比较不同头和层之间的注意力模式。在可接受性判断和人工智能生成文本检测的基准测试中,我们的方法显著优于现有的不确定性估计技术,为大规模语言模型的不确定性估计提供了一种更高效、更具可解释性的解决方案。

英文摘要:

Transformer-based language models have set new benchmarks across a wide range of NLP tasks, yet reliably estimating the uncertainty of their predictions remains a significant challenge. Existing uncertainty estimation (UE) techniques often fall short in classification tasks, either offering minimal improvements over basic heuristics or relying on costly ensemble models. Moreover, attempts to leverage common embeddings for UE in linear probing scenarios have yielded only modest gains, indicating that alternative model components should be explored. We tackle these limitations by harnessing the geometry of attention maps across multiple heads and layers to assess model confidence. Our approach extracts topological features from attention matrices, providing a low-dimensional, interpretable representation of the model's internal dynamics. Additionally, we introduce topological features to compare attention patterns across heads and layers. Our method significantly outperforms existing UE techniques on benchmarks for acceptability judgments and artificial text detection, offering a more efficient and interpretable solution for uncertainty estimation in large-scale language models.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑