How does representation impact in-context learning: An exploration on a synthetic task
Abstract
In-context learning, i.e., learning from in-context samples, is an impressive ability of Transformer. However, the exact mechanism behind this learning process remains unclear. In this study, we aim to explore this aspect from a relatively unexplored perspective of representation learning. In the context of in-context learning scenarios, the representation becomes more complex as it can be influenced by both model weights and in-context samples. We refer to these two conceptual aspects of representation as the in-weight component and the in-context component, respectively. To examine the impact of these two components on in-context learning capabilities, we create a novel synthetic task, which allows us to develop two probes - the in-weights probe and the in-context probe - to evaluate the respective components. Our findings reveal that the quality of the in-context component is closely related to in-context learning performance, signifying the connection between in-context learning and representation learning. Additionally, we discover that a well-developed in-weights component can positively affect the learning of the in-context component, suggesting that in-weights learning should serve as the foundation for in-context learning. To gain a deeper understanding of the in-context learning mechanism and the importance of the in-weights component, we demonstrate through construction that a simple Transformer, using pattern matching and a copy-paste mechanism for in-context learning, can achieve comparable performance to a more complex, best-tuned Transformer under the assumption of a perfect in-weights component. Overall, our discoveries from the perspective of representation learning provide valuable insights into new approaches for enhancing in-context capacity.
BibTeX
@misc{fu2024how,
author = {Jingwen Fu and Tao Yang and Yuwang Wang and Yan Lu and Nanning Zheng},
title = {{How does representation impact in-context learning: An exploration on a synthetic task}},
year = {2024},
url = {https://openreview.net/forum?id=JopVmAPyx6},
howpublished = {OpenReview},
note = {Submitted to ICLR 2024},
}Ask Althea to put this paper to the test.