From Language Modeling to Instruction Following: Understanding the Behavior Shift in LLMs after Instruction Tuning
Wu, Xuansheng, Yao, Wenlin, Chen, Jianshu, Pan, Xiaoman, Wang, Xiaoyang, Liu, Ninghao, Yu, Dong
–arXiv.org Artificial Intelligence
Large Language Models (LLMs) have achieved remarkable success, demonstrating powerful instruction-following capabilities across diverse tasks. Instruction fine-tuning is critical in enabling LLMs to align with user intentions and effectively follow instructions. In this work, we investigate how instruction fine-tuning modifies pre-trained models, focusing on two perspectives: instruction recognition and knowledge evolution. To study the behavior shift of LLMs, we employ a suite of local and global explanation methods, including a gradient-based approach for input-output attribution and techniques for interpreting patterns and concepts in self-attention and feed-forward layers. Our findings reveal three significant impacts of instruction fine-tuning: 1) It empowers LLMs to better recognize the instruction parts from user prompts, thereby facilitating high-quality response generation and addressing the ``lost-in-the-middle'' issue observed in pre-trained models; 2) It aligns the knowledge stored in feed-forward layers with user-oriented tasks, exhibiting minimal shifts across linguistic levels. 3) It facilitates the learning of word-word relations with instruction verbs through the self-attention mechanism, particularly in the lower and middle layers, indicating enhanced recognition of instruction words. These insights contribute to a deeper understanding of the behavior shifts in LLMs after instruction fine-tuning and lay the groundwork for future research aimed at interpreting and optimizing LLMs for various applications. We will release our code and data soon.
arXiv.org Artificial Intelligence
Sep-30-2023
- Country:
- Africa
- Ghana > Central Region
- Cape Coast (0.04)
- Middle East > Egypt (0.04)
- Ghana > Central Region
- Asia
- Europe
- Finland (0.04)
- France (0.04)
- Greece (0.04)
- Netherlands > North Holland
- Amsterdam (0.04)
- Sweden > Stockholm
- Stockholm (0.04)
- Switzerland > Zürich
- Zürich (0.14)
- United Kingdom (0.04)
- North America
- Canada > Quebec
- Montreal (0.04)
- United States
- Massachusetts > Dukes County (0.04)
- Colorado (0.04)
- Illinois (0.04)
- Virginia (0.04)
- Ohio (0.04)
- Tennessee (0.04)
- California > Santa Clara County
- Palo Alto (0.04)
- Maryland (0.04)
- Arizona (0.04)
- Canada > Quebec
- South America
- Brazil (0.04)
- Chile > Santiago Metropolitan Region
- Santiago Province > Santiago (0.04)
- Peru (0.04)
- Africa
- Genre:
- Research Report > New Finding (1.00)
- Industry:
- Health & Medicine (0.46)
- Technology: