Abstract
Reliable pattern recognition systems should exhibit consistent behavior across similar inputs, and their explanations should remain stable. However, most Explainable AI evaluations remain instance centric and do not explicitly quantify whether attribution patterns are consistent across samples that share the same class or represent small variations of the same input. In this work, we propose a novel metric aimed at assessing the consistency of model explanations, ensuring that models consistently reflect the intended objectives and consistency under label-preserving perturbations. We implement this metric using a pre-trained BERT model on the SST-2 sentiment analysis dataset, with additional robustness tests on RoBERTa, DistilBERT, and IMDB, applying SHAP to compute feature importance for various test samples. The proposed metric quantifies the cosine similarity of SHAP values for inputs with the same label, aiming to detect inconsistent behaviors, such as biased reliance on certain features or failure to maintain consistent reasoning for similar predictions. Through a series of experiments, we evaluate the ability of this metric to identify misaligned predictions and inconsistencies in model explanations. These experiments are compared against standard fidelity metrics to assess whether the new metric can effectively identify when a model's behavior deviates from its intended objectives. The proposed framework provides a deeper understanding of model behavior by enabling more robust verification of rationale stability, which is critical for building trustworthy AI systems. By quantifying whether models rely on consistent attribution patterns for similar inputs, the proposed approach supports more robust evaluation of model behavior in practical pattern recognition pipelines. Our code is publicly available at this https URL.
Abstract (translated)
可靠的模式识别系统应对相似输入表现出一致的行为,且其解释应保持稳定。然而,大多数可解释人工智能评估仍以实例为中心,并未明确量化归因模式在共享相同类别或代表相同输入微小变化的样本间是否一致。在本研究中,我们提出了一种新颖的度量指标,旨在评估模型解释的一致性,确保模型在保标签扰动下始终反映预期目标并保持一致性。我们使用预训练的BERT模型在SST-2情感分析数据集上实现了该指标,并在RoBERTa、DistilBERT和IMDB上进行了额外鲁棒性测试,应用SHAP计算各类测试样本的特征重要性。所提指标量化了相同标签输入的SHAP值之间的余弦相似度,旨在检测不一致行为,例如对某些特征的偏倚依赖,或未能对相似预测保持一致的推理逻辑。通过一系列实验,我们评估了该指标识别模型解释中预测偏差与不一致性的能力。这些实验与标准保真度指标进行对比,以评估新指标是否能有效识别模型行为偏离其预期目标的情况。所提出的框架通过实现对原理稳定性的更鲁棒验证,提供了对模型行为的更深层理解,这对构建可信人工智能系统至关重要。通过量化模型对相似输入是否依赖一致的归因模式,该方法支持在实际模式识别流程中对模型行为进行更稳健的评估。我们的代码已在以下网址公开:https URL。
URL
https://arxiv.org/abs/2604.04456