Do neural networks, trained on well-understood algorithmic tasks, reliably rediscover known algorithms for solving those tasks? Several recent studies, on tasks ranging from group arithmetic to in-context linear regression, have suggested that the answer is yes. Using modular addition as a prototypical problem, we show that algorithm discovery in neural networks is sometimes more complex. Small changes to model hyperparameters and initializations can induce the discovery of qualitatively different algorithms from a fixed training set, and even parallel implementations of multiple such algorithms. Some networks trained to perform modular addition implement a familiar Clock algorithm; others implement a previously undescribed, less intuitive, but comprehensible procedure which we term the Pizza algorithm, or a variety of even more complex procedures. Our results show that even simple learning problems can admit a surprising diversity of solutions, motivating the development of new tools for characterizing the behavior of neural networks across their algorithmic phase space.
翻译:在理解透彻的算法任务上训练的神经网络,是否总能可靠地重新发现已知的求解算法?从群运算到上下文线性回归等多项近期研究表明,答案是肯定的。以模加法为典型问题,我们发现神经网络的算法发现有时更为复杂。模型超参数与初始化的微小变化,就能从固定训练集中诱导出性质迥异的算法,甚至催生多种算法的并行实现。部分用于执行模加法的网络实现了熟悉的"时钟算法";另一些则实现了此前未被描述、直觉性较弱但可理解的程序(我们称之为"披萨算法"),甚至更为复杂的多种程序。我们的结果表明,即便是简单的学习问题也能产生惊人的算法多样性,这促使我们开发新工具来刻画神经网络在其算法相空间中的行为特征。