Low-Rank Softmax Can Have Unargmaxable Classes in Theory but Rarely in Practice

Andreas Grivas, Nikolay Bogoychev, Adam Lopez


Abstract
Classifiers in natural language processing (NLP) often have a large number of output classes. For example, neural language models (LMs) and machine translation (MT) models both predict tokens from a vocabulary of thousands. The Softmax output layer of these models typically receives as input a dense feature representation, which has much lower dimensionality than the output. In theory, the result is some words may be impossible to be predicted via argmax, irrespective of input features, and empirically, there is evidence this happens in small language models (Demeter et al., 2020). In this paper we ask whether it can happen in practical large language models and translation models. To do so, we develop algorithms to detect such unargmaxable tokens in public models. We find that 13 out of 150 models do indeed have such tokens; however, they are very infrequent and unlikely to impact model quality. We release our algorithms and code to the public.
Anthology ID:
2022.acl-long.465
Volume:
Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers)
Month:
May
Year:
2022
Address:
Dublin, Ireland
Editors:
Smaranda Muresan, Preslav Nakov, Aline Villavicencio
Venue:
ACL
SIG:
Publisher:
Association for Computational Linguistics
Note:
Pages:
6738–6758
Language:
URL:
https://aclanthology.org/2022.acl-long.465
DOI:
10.18653/v1/2022.acl-long.465
Bibkey:
Cite (ACL):
Andreas Grivas, Nikolay Bogoychev, and Adam Lopez. 2022. Low-Rank Softmax Can Have Unargmaxable Classes in Theory but Rarely in Practice. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 6738–6758, Dublin, Ireland. Association for Computational Linguistics.
Cite (Informal):
Low-Rank Softmax Can Have Unargmaxable Classes in Theory but Rarely in Practice (Grivas et al., ACL 2022)
Copy Citation:
PDF:
https://aclanthology.org/2022.acl-long.465.pdf
Software:
 2022.acl-long.465.software.zip
Video:
 https://aclanthology.org/2022.acl-long.465.mp4
Code
 andreasgrv/unargmaxable