Locating Demographic Bias at the Attention-Head Level in CLIP's Vision Encoder

📄 arXiv: 2603.11793v1 📥 PDF

作者: Alaa Yasser, Kittipat Phunjanna, Marcos Escudero Viñolo, Catarina Barata, Jenny Benois-Pineau

分类: cs.CV, cs.AI, cs.CY

发布日期: 2026-03-12

备注: 14 pages, 6 tables, 2 figures. Work conducted during IPCV-AI Erasmus Mundus Master


💡 一句话要点

提出一种机械公平性审计方法,定位CLIP视觉编码器中注意力头的偏见。

🎯 匹配领域: 支柱九:具身大模型 (Embodied Foundation Models)

关键词: 公平性审计 机械可解释性 CLIP 视觉Transformer 注意力机制 偏见定位 深度学习

📋 核心要点

  1. 现有公平性审计方法只能量化模型的偏见程度,无法定位偏见在网络中的具体位置,缺乏可解释性。
  2. 该论文提出一种机械公平性审计方法,通过分解残差流、概念激活向量和TextSpan分析,定位视觉Transformer中注意力头的偏见。
  3. 在CLIP ViT-L-14上的实验表明,该方法能有效定位性别偏见,消融特定注意力头可降低偏见并略微提升准确率,但年龄偏见定位效果较弱。

📝 摘要(中文)

本文提出了一种机械公平性审计方法,该方法结合了投影残差流分解、零样本概念激活向量和偏见增强的TextSpan分析,旨在定位视觉Transformer中各个注意力头的偏见。以CLIP ViT-L-14编码器在FACET基准的42个职业类别上的性别和年龄偏见审计为例,验证了该方法的可行性。对于性别偏见,该方法识别出四个末层注意力头,消融这些头可以降低全局偏见(Cramer's V: 0.381 -> 0.362),同时略微提高准确率(+0.42%)。随机对照实验证实了这种效果是特定于所识别的头的。对于年龄偏见,该方法也识别出候选头,但消融效果较弱且不一致,表明年龄偏见在该模型中比性别偏见更分散。这些结果初步证明了对于判别式视觉编码器,头级别偏见定位是可行的,并且可定位程度可能因受保护属性而异。

🔬 方法详解

问题定义:论文旨在解决现有公平性审计方法无法定位深度学习模型(特别是视觉Transformer)中偏见来源的问题。现有的方法只能评估模型整体的偏见程度,而无法确定偏见存在于网络的哪些特定部分(例如,哪些注意力头)。这使得难以采取有针对性的措施来减轻或消除偏见。

核心思路:论文的核心思路是将机械可解释性技术应用于公平性审计。通过分析模型的内部表示(即注意力头的激活),来识别哪些头对特定人群(例如,特定性别或年龄)的偏见预测贡献最大。这种方法允许更精确地定位和理解偏见的来源。

技术框架:该方法包含以下主要步骤:1) 投影残差流分解:用于分析信息在网络中的流动,确定哪些注意力头对最终预测影响最大。2) 零样本概念激活向量 (CAV):用于量化注意力头与特定概念(例如,性别或年龄)的相关性。3) 偏见增强的TextSpan分析:用于分析与偏见相关的文本片段如何影响注意力头的激活。通过结合这些技术,该方法能够定位对偏见预测贡献最大的注意力头。

关键创新:该方法的主要创新在于将机械可解释性技术应用于公平性审计,从而实现了对模型偏见的细粒度定位。与传统的公平性审计方法相比,该方法不仅可以量化模型的偏见程度,还可以确定偏见在网络中的具体位置。

关键设计:论文使用了CLIP ViT-L-14模型,并在FACET基准数据集上进行了实验。Cramer's V系数被用作衡量偏见程度的指标。为了验证所识别的注意力头的重要性,论文进行了消融实验,即移除这些头并观察模型性能的变化。同时,使用随机对照实验来确保消融特定头的效果不是偶然的。

🖼️ 关键图片

fig_0
fig_1

📊 实验亮点

实验结果表明,该方法能够有效定位CLIP ViT-L-14模型中的性别偏见。消融四个末层注意力头可以将全局偏见(Cramer's V)从0.381降低到0.362,同时略微提高准确率(+0.42%)。随机对照实验证实了这种效果是特定于所识别的头的。对于年龄偏见,该方法虽然也能识别出候选头,但消融效果较弱,表明年龄偏见的编码更为分散。

🎯 应用场景

该研究成果可应用于提升图像分类、目标检测等视觉任务的公平性,尤其是在人脸识别、招聘筛选等敏感领域。通过定位并消除模型中的偏见,可以减少算法歧视,提高模型在不同人群中的泛化能力,最终促进人工智能技术的公平和负责任发展。

📄 摘要(原文)

Standard fairness audits of foundation models quantify that a model is biased, but not where inside the network the bias resides. We propose a mechanistic fairness audit that combines projected residual-stream decomposition, zero-shot Concept Activation Vectors, and bias-augmented TextSpan analysis to locate demographic bias at the level of individual attention heads in vision transformers. As a feasibility case study, we apply this pipeline to the CLIP ViT-L-14 encoder on 42 profession classes of the FACET benchmark, auditing both gender and age bias. For gender, the pipeline identifies four terminal-layer heads whose ablation reduces global bias (Cramer's V: 0.381 -> 0.362) while marginally improving accuracy (+0.42%); a layer-matched random control confirms that this effect is specific to the identified heads. A single head in the final layer contributes to the majority of the reduction in the most stereotyped classes, and class-level analysis shows that corrected predictions shift toward the correct occupation. For age, the same pipeline identifies candidate heads, but ablation produces weaker and less consistent effects, suggesting that age bias is encoded more diffusely than gender bias in this model. These results provide preliminary evidence that head-level bias localisation is feasible for discriminative vision encoders and that the degree of localisability may vary across protected attributes. keywords: Bias . CLIP . Mechanistic Interpretability . Vision Transformer . Fairness