Test-time augmentation, such as Retrieval-Augmented Generation (RAG) or tool use, critically depends on an interplay between a model's parametric knowledge and externally retrieved information. However, the theoretical underpinnings of this relationship remain poorly understood. Specifically, it is not clear how much pre-training knowledge is required to answer queries with a small number of augmentation steps, which is a desirable property in practice. To address this question, we formulate multi-step reasoning as an $s$-$t$ connectivity problem on a knowledge graph. We represent a model's pre-training parametric knowledge as a partial, potentially noisy subgraph. We view augmentation as querying an oracle for true edges that augment the model's knowledge. Then, we characterize the necessary and sufficient number of augmentation steps for the model to generate an accurate answer given partial prior knowledge. One key result shows a phase transition: if the prior knowledge graph over $n$ vertices is disconnected into small components, then finding a path via augmentation is inefficient and requires $Ω(\sqrt{n})$ queries. On the other hand, once the density of correct knowledge surpasses a threshold, forming a giant component, we can find paths with an expected constant number of queries.
翻译:测试时增强(如检索增强生成或工具使用)关键依赖于模型参数知识与外部检索信息之间的相互作用。然而,这种关系的理论基础仍鲜为人知。具体而言,尚不清楚需要多少预训练知识才能通过少量增强步骤回答查询——这在实践中是一个理想特性。为探讨这一问题,我们将多步推理形式化为知识图上的 $s$-$t$ 连通性问题。我们将模型的预训练参数知识表示为一个部分且可能包含噪声的子图,将增强视为查询一个能提供真实边(用于扩充模型知识)的预言机。在此基础上,我们刻画了在给定部分先验知识的情况下,模型生成准确答案所需的充分且必要的增强步骤数。一项关键结果表明存在相变:若 $n$ 个顶点上的先验知识图断裂成小连通分量,则通过增强寻找路径效率低下,需要 $Ω(\sqrt{n})$ 次查询;反之,一旦正确知识的密度超过阈值并形成巨连通分量,我们便能在期望常数次查询内找到路径。