提出可计算的长度泛化上界,证明特定模型在输入更长时仍能准确预测。
Non-Asymptotic Length Generalization
- 定义长度复杂度,给出学习算法达到最优泛化的理论条件。
- 1层C-RASP模型长度复杂度为O(T²),2层为O(T^{O(K)}),T为精度。
- 揭示上下文无关文法无通用上界,但确定有限自动机有明确上界2n-2。
长度泛化指学习算法能在训练输入长度之外处理更长输入的能力。本文在理想设置下,为多种函数类提供了长度泛化的可证明保证。首先,形式化了非渐近长度泛化框架,要求在给定真值函数复杂度度量下,可计算出确保长度泛化的最小输入长度的上界,称之为长度复杂度。我们证明最小复杂度插值器算法能达到最优长度复杂度。进一步表明,一个函数类是否具备非渐近长度泛化,等价于其语言等价问题的可判定性,这意味着上下文无关文法不存在可计算的长度复杂度上界。正面结果是,确定有限自动机的长度复杂度为2n - 2,其中n为真值自动机的状态数。对于一类与Transformer相关的函数类C-RASP(Yang & Chiang, 2024),我们给出了子类的长度复杂度上界:当真值函数精度为T时,1层C-RASP的长度复杂度为O(T²);当真值函数精度为T且有K个注意力头时,2层C-RASP的长度复杂度为O(T^{O(K)})。
原文摘要 · Abstract (English)
Length generalization is the ability of a learning algorithm to learn a hypothesis which generalizes to longer inputs than the inputs in the training set. In this paper, we provide provable guarantees of length generalization for various classes of functions in an idealized setting. First, we formalize the framework of non-asymptotic length generalization, which requires a computable upper bound for the minimum input length that guarantees length generalization, as a function of the complexity of ground-truth function under some given complexity measure. We refer to this minimum input length to length generalize as length complexity. We show the Minimum-Complexity Interpolator learning algorithm achieves optimal length complexity. We further show that whether a function class admits non-asymptotic length generalization is equivalent to the decidability of its language equivalence problem, which implies that there is no computable upper bound for the length complexity of Context-Free Grammars. On the positive side, we show that the length complexity of Deterministic Finite Automata is $2n - 2$ where $n$ is the number of states of the ground-truth automaton. Our main results are upper bounds of length complexity for a subset of a transformer-related function class called C-RASP (Yang & Chiang, 2024). We show that the length complexity of 1-layer C-RASP functions is $O(T^2)$ when the ground-truth function has precision $T$, and that the length complexity of 2-layer C-RASP functions is $O(T^{O(K)})$ when the ground-truth function has precision $T$ and $K$ heads.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。