顺序积分梯度:一种简单而有效的语言模型解释方法
Sequential Integrated Gradients: a simple but effective method for explaining language models
AI总结:
针对积分梯度在语言模型解释中因同时插值所有词而导致语义失真问题,提出顺序积分梯度SIG,逐词插值并用mask替换pad基线,在多种模型和数据集上验证了其有效性。
摘要:
多种解释方法(如积分梯度(IG))可被归类为基于路径的方法,因为它们依赖于数据与一个无信息基线之间的直线。然而,当应用于语言模型时,这些方法会同时为句子中的每个单词生成一条路径,这可能导致由插值单词构成的句子要么没有明确含义,要么与原始句子相比含义显著不同。为了使这些句子的含义尽可能接近原始句子,我们提出了顺序积分梯度(SIG),该方法通过固定所有其他单词,仅在基线与目标单词之间进行插值,来计算句子中每个单词的重要性。此外,受多种语言模型训练过程的启发,我们还提出用训练得到的“mask”标记替换基线标记“pad”。尽管SIG只是对原始IG方法的简单改进,但我们在多种模型和数据集上证明,SIG是一种非常有效的语言模型解释方法。
英文摘要:
Several explanation methods such as Integrated Gradients (IG) can be characterised as path-based methods, as they rely on a straight line between the data and an uninformative baseline. However, when applied to language models, these methods produce a path for each word of a sentence simultaneously, which could lead to creating sentences from interpolated words either having no clear meaning, or having a significantly different meaning compared to the original sentence. In order to keep the meaning of these sentences as close as possible to the original one, we propose Sequential Integrated Gradients (SIG), which computes the importance of each word in a sentence by keeping fixed every other words, only creating interpolations between the baseline and the word of interest. Moreover, inspired by the training procedure of several language models, we also propose to replace the baseline token "pad" with the trained token "mask". While being a simple improvement over the original IG method, we show on various models and datasets that SIG proves to be a very effective method for explaining language models.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。