ATTEXPLAINER: Explain Transformer via Attention by Reinforcement Learning

被引:0
|
作者
Niu, Runliang [1 ]
Wei, Zhepei [1 ]
Wang, Yan [1 ,2 ]
Wang, Qi [1 ]
机构
[1] Jilin Univ, Sch Artificial Intelligence, Changchun, Peoples R China
[2] Jilin Univ, Minist Educ, Coll Comp Sci & Technol, Key Lab Symbol Computat & Knowledge Engn, Changchun, Peoples R China
基金
中国国家自然科学基金;
关键词
D O I
暂无
中图分类号
TP18 [人工智能理论];
学科分类号
081104 ; 0812 ; 0835 ; 1405 ;
摘要
Transformer and its variants, built based on attention mechanisms, have recently achieved remarkable performance in many NLP tasks. Most existing works on Transformer explanation tend to reveal and utilize the attention matrix with human subjective intuitions in a qualitative manner. However, the huge size of dimensions directly challenges these methods to quantitatively analyze the attention matrix. Therefore, in this paper, we propose a novel reinforcement learning (RL) based framework for Transformer explanation via attention matrix, namely ATTEXPLAINER. The RL agent learns to perform step-by-step masking operations by observing the change in attention matrices. We have adapted our method to two scenarios, perturbation-based model explanation and text adversarial attack. Experiments on three widely used text classification benchmarks validate the effectiveness of the proposed method compared to state-of-the-art baselines. Additional studies show that our method is highly transferable and consistent with human intuition. The code of this paper is available at https://github.com/niuzaisheng/AttExplainer.
引用
收藏
页码:724 / 731
页数:8
相关论文
共 50 条
  • [31] Learning by neurones: role of attention, reinforcement and behaviour
    Sara, S. J.
    Comptes Rendus De L'Academie Des Sciences. Serie III, Sciences De La Vie, 321 (2-3):
  • [32] Relational Reinforcement Learning applied to Shared Attention
    da Silva, Renato R.
    Policastro, Claudio A.
    Romero, Roseli A. F.
    IJCNN: 2009 INTERNATIONAL JOINT CONFERENCE ON NEURAL NETWORKS, VOLS 1- 6, 2009, : 1074 - 1080
  • [33] Unsupervised Visual Attention and Invariance for Reinforcement Learning
    Wang, Xudong
    Lian, Long
    Yu, Stella X.
    2021 IEEE/CVF CONFERENCE ON COMPUTER VISION AND PATTERN RECOGNITION, CVPR 2021, 2021, : 6673 - 6683
  • [34] Holistic Reinforcement Learning: The Role of Structure and Attention
    Radulescu, Angela
    Niv, Yael
    Ballard, Ian
    TRENDS IN COGNITIVE SCIENCES, 2019, 23 (04) : 278 - 292
  • [35] A Reinforcement Learning Approach for Sequential Spatial Transformer Networks
    Azimi, Fatemeh
    Raue, Federico
    Hees, Joern
    Dengel, Andreas
    ARTIFICIAL NEURAL NETWORKS AND MACHINE LEARNING - ICANN 2019: THEORETICAL NEURAL COMPUTATION, PT I, 2019, 11727 : 585 - 597
  • [36] Reinforcement Learning Transformer for Image Captioning Generation Model
    Yan, Zhaojie
    FIFTEENTH INTERNATIONAL CONFERENCE ON MACHINE VISION, ICMV 2022, 2023, 12701
  • [37] Video captioning based on vision transformer and reinforcement learning
    Zhao, Hong
    Chen, Zhiwen
    Guo, Lan
    Han, Zeyu
    PEERJ COMPUTER SCIENCE, 2022, 8
  • [38] Video captioning based on vision transformer and reinforcement learning
    Zhao H.
    Chen Z.
    Guo L.
    Han Z.
    PeerJ Computer Science, 2022, 8
  • [39] Feedback Decision Transformer: Offline Reinforcement Learning With Feedback
    Giladi, Liad
    Katz, Gilad
    23RD IEEE INTERNATIONAL CONFERENCE ON DATA MINING, ICDM 2023, 2023, : 1037 - 1042
  • [40] TERL: Transformer Enhanced Reinforcement Learning for Relation Extraction
    Wang, Yashen
    Shi, Tuo
    Ouyang, Xiaoye
    Guo, Dayu
    CHINESE COMPUTATIONAL LINGUISTICS, CCL 2023, 2023, 14232 : 192 - 206