Upload folder using huggingface_hub
Browse files- iclr26/2g8vgmyXgQ/appendix_chunks.jsonl +184 -0
- iclr26/2g8vgmyXgQ/appendix_text_v3.txt +551 -0
- iclr26/2g8vgmyXgQ/assets.json +101 -0
- iclr26/2g8vgmyXgQ/assets/_page_14_Figure_11.jpeg +3 -0
- iclr26/2g8vgmyXgQ/assets/_page_14_Figure_9.jpeg +3 -0
- iclr26/2g8vgmyXgQ/assets/_page_15_Figure_2.jpeg +3 -0
- iclr26/2g8vgmyXgQ/assets/_page_15_Figure_3.jpeg +3 -0
- iclr26/2g8vgmyXgQ/assets/_page_15_Figure_8.jpeg +3 -0
- iclr26/2g8vgmyXgQ/assets/_page_15_Figure_9.jpeg +3 -0
- iclr26/2g8vgmyXgQ/assets/_page_16_Figure_1.jpeg +3 -0
- iclr26/2g8vgmyXgQ/assets/_page_16_Figure_2.jpeg +3 -0
- iclr26/2g8vgmyXgQ/assets/_page_8_Figure_1.jpeg +3 -0
- iclr26/2g8vgmyXgQ/chunks_v3_anonymized.jsonl +0 -0
- iclr26/2g8vgmyXgQ/dataset_meta.json +60 -0
- iclr26/2g8vgmyXgQ/main_body_chunks.jsonl +83 -0
- iclr26/2g8vgmyXgQ/marker_meta.json +1821 -0
- iclr26/2g8vgmyXgQ/model_text_v3.txt +248 -0
- iclr26/2g8vgmyXgQ/paper.blocks.json +0 -0
- iclr26/2g8vgmyXgQ/paper.md +1040 -0
- iclr26/2g8vgmyXgQ/parse_report.json +73 -0
- iclr26/2g8vgmyXgQ/reference_chunks.jsonl +9 -0
- iclr26/2g8vgmyXgQ/reference_text_v3.txt +26 -0
- iclr26/2g8vgmyXgQ/sanitization_report.json +56 -0
- iclr26/2g8vgmyXgQ/sanitized_v3.txt +446 -0
iclr26/2g8vgmyXgQ/appendix_chunks.jsonl
ADDED
|
@@ -0,0 +1,184 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0092", "section": "A THE USE OF LLMS FOR POLISHING WRITING", "page_start": 15, "page_end": 15, "type": "Text", "text": "We used a large language model (LLM) tool (e.g., ChatGPT) solely to polish and improve the readability of certain sections of this manuscript—specifically, the introduction, abstract, and several explanatory paragraphs. All research ideas, theoretical derivations, experimental designs, analyses, and conclusions are original to the authors. The LLM was not used to generate technical content, proofs, or results. We reviewed and edited all text produced with LLM assistance to ensure accuracy and consistency with our intended meaning.", "source": "marker_v2", "marker_block_id": "/page/14/Text/6"}
|
| 2 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0093", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 15, "page_end": 15, "type": "Text", "text": "Building on the prediction loss and attention dynamics shown in Figure 1, we provide a more detailed analysis of the 4\\times 4 attention maps in this appendix. Figure 2 and Figure 3 show the attention patterns for the flat (L=0.1) and sharp (L=1) loss landscapes, respectively, under the experimental conditions of Section 6.", "source": "marker_v2", "marker_block_id": "/page/14/Text/8"}
|
| 3 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0094", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 15, "page_end": 15, "type": "FigureGroup", "text": "Figure 2: Dynamics of attention maps under flat L=0.1", "source": "marker_v2", "marker_block_id": "/page/14/FigureGroup/275"}
|
| 4 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0095", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 15, "page_end": 15, "type": "FigureGroup", "text": "Figure 3: Dynamics of attention maps under sharp L=1", "source": "marker_v2", "marker_block_id": "/page/14/FigureGroup/276"}
|
| 5 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0096", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 15, "page_end": 15, "type": "Text", "text": "In the attention maps, each grid position (i,j) corresponds to the attention score Attn_{i,j} , where i,j \\in \\{1,2,3,4\\} are the indices of key and query, respectively. An important property is that the sum of attention scores for each column equals one (\\sum_i Attn_{i,j} = 1) , given the same query v_j . The", "source": "marker_v2", "marker_block_id": "/page/14/Text/13"}
|
| 6 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0097", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 16, "page_end": 16, "type": "Text", "text": "attention maps show a clear trend: the diagonal entries (i,i) become progressively darker over t, indicating that the corresponding self-attention scores \\mathrm{Attn}_i increase for all i \\in \\{1,2,3,4\\} . We observe these scores approaching 1 before t=300 for the flat landscape L=0.1 and before t=200 for the sharp landscape L=1. In contrast, the off-diagonal entries (i,j), where i \\neq j , become lighter, with \\mathrm{Attn}_{i,j} converging toward zero. This behavior supports the theoretical findings presented in Proposition 2 and Proposition 3 and is directly reflected in the attention score dynamics plotted in Figure 1(c) and Figure 1(d).", "source": "marker_v2", "marker_block_id": "/page/15/Text/1"}
|
| 7 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0098", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 16, "page_end": 16, "type": "ListGroup", "text": "(a) Prediction loss for flat L-set under polynomial functions. (b) Prediction loss for sharp L-set under polynomial functions.", "source": "marker_v2", "marker_block_id": "/page/15/ListGroup/320"}
|
| 8 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0099", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 16, "page_end": 16, "type": "Caption", "text": "Figure 4: Training dynamics of prediction losses for two sets of L: flat ( \\{0.1, 0.2, 0.4\\} ) and sharp ( \\{1.0, 1.5, 2.0\\} ) under polynomial functions.", "source": "marker_v2", "marker_block_id": "/page/15/Caption/6"}
|
| 9 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0100", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 16, "page_end": 16, "type": "Text", "text": "To further validate the generality of our theoretical results, we conducted an additional experiment on a different class of nonlinear functions: random second-degree polynomials of the form f(x) = x^{\\top}Ax + b^{\\top}x , where the matrix A and vector b were randomly generated for each task instance. The elements of A and b satisfy A_{ij}, b_i \\sim \\mathcal{N}(0, (\\frac{L}{d})^2) . For this experiment, we relaxed the finite feature set assumption by sampling input features from a continuous Gaussian distribution. In other words, there can be infinitely many feature vectors. For the other parameters, we set d=30, N=150, M=500. The prediction loss, averaged over 30 independent runs, is shown below for both the flat L-regime and the sharp L-regime. The results strongly corroborate our main findings: The flat regime has two training phases, while the sharp regime has three phases. Within both regimes, a larger Lipschitz constant L consistently results in faster convergence of the prediction loss. This provides further evidence that the identified training dynamics and the role of the Lipschitz constant hold for a broader class of nonlinear functions beyond the trigonometric family, and also hold for more general feature set and token sampling process.", "source": "marker_v2", "marker_block_id": "/page/15/Text/7"}
|
| 10 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0101", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 16, "page_end": 16, "type": "ListGroup", "text": "(a) Prediction loss for flat L-set under two-layer transformer. (b) Prediction loss for sharp L-set under two-layer transformer.", "source": "marker_v2", "marker_block_id": "/page/15/ListGroup/321"}
|
| 11 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0102", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 16, "page_end": 16, "type": "Caption", "text": "Figure 5: Training dynamics of prediction losses for two sets of L: flat ( \\{0.1, 0.2, 0.4\\} ) and sharp ( \\{1.0, 1.5, 2.0\\} ) under two-layer transformer.", "source": "marker_v2", "marker_block_id": "/page/15/Caption/12"}
|
| 12 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0103", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 16, "page_end": 16, "type": "Text", "text": "In addition to the single-layer setting analyzed in the main text, we further evaluate whether the curvature-dependent convergence behavior persists in deeper Transformer architectures such as two-layer and four-layer models. To this end, we present experiments using more realistic architectures that contain two or four stacked self-attention layers followed by two or four FFN blocks, under the same", "source": "marker_v2", "marker_block_id": "/page/15/Text/13"}
|
| 13 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0104", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 17, "page_end": 17, "type": "ListGroup", "text": "(a) Prediction loss for flat L-set under four-layer transformer. (b) Prediction loss for sharp L-set under four-layer transformer.", "source": "marker_v2", "marker_block_id": "/page/16/ListGroup/259"}
|
| 14 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0105", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 17, "page_end": 17, "type": "Caption", "text": "Figure 6: Training dynamics of prediction losses for two sets of L: flat ( \\{0.1, 0.2, 0.4\\} ) and sharp ( \\{1.0, 1.5, 2.0\\} ) under four-layer transformer.", "source": "marker_v2", "marker_block_id": "/page/16/Caption/5"}
|
| 15 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0106", "section": "B ADDITIONAL EXPERIMENTAL RESULTS", "page_start": 17, "page_end": 17, "type": "Text", "text": "data and task setup as in Figure 4. As shown in Figure 5 and Figure 6, the deeper Transformers exhibit the same qualitative learning dynamics predicted by our theory, including a clear phase transition between the flat and sharp L-regimes and consistent phase-wise convergence behavior. These results indicate that the core mechanisms identified in our analysis, which were derived for a single-layer model for analytical tractability, naturally extend to multi-layer Transformer architectures.", "source": "marker_v2", "marker_block_id": "/page/16/Text/6"}
|
| 16 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0107", "section": "C PROOF OF LEMMA 1", "page_start": 17, "page_end": 17, "type": "Text", "text": "Recall the definition of the prediction error \\mathcal{L}(P;Q) in Eq. (5):", "source": "marker_v2", "marker_block_id": "/page/16/Text/8"}
|
| 17 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0108", "section": "C PROOF OF LEMMA 1", "page_start": 17, "page_end": 17, "type": "Equation", "text": "\\mathcal{L}(P;Q) = \\frac{1}{2} \\sum_{k=1}^{K} \\mathbb{E} \\left[ \\mathbb{1} \\{ x_{\\text{query}} = v_k \\} (\\hat{y}_{\\text{query}} - f(v_k))^2 \\right] = \\frac{1}{2} \\sum_{k=1}^{K} \\mathbb{E} \\left[ \\mathbb{1} \\{ x_{\\text{query}} = v_k \\} \\left( \\sum_{n \\in [K]} \\operatorname{Attn}_n^{(t)} f(v_n) - f(v_k) \\right)^2 \\right] = \\frac{1}{2} \\sum_{k=1}^{K} \\mathbb{E} \\left[ \\mathbb{1} \\{ x_{\\text{query}} = v_k \\} \\left( \\sum_{n \\in [K]} \\operatorname{Attn}_n^{(t)} (f(v_n) - f(v_k)) \\right)^2 \\right] = \\frac{1}{2} \\sum_{k=1}^{K} \\mathbb{E} \\left[ \\mathbb{1} \\{ x_{\\text{query}} = v_k \\} \\left( \\sum_{n \\neq k} \\operatorname{Attn}_n^{(t)} (f(v_n) - f(v_k)) \\right)^2 \\right]", "source": "marker_v2", "marker_block_id": "/page/16/Equation/9"}
|
| 18 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0109", "section": "C PROOF OF LEMMA 1", "page_start": 17, "page_end": 17, "type": "Text", "text": "where we apply \\sum_{n\\in[K]}\\operatorname{Attn}_n^{(t)}=1 to rewrite f(v_k) as \\sum_{n\\in[K]}\\operatorname{Attn}_n^{(t)}f(v_k) in the third equality.", "source": "marker_v2", "marker_block_id": "/page/16/Text/10"}
|
| 19 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0110", "section": "C PROOF OF LEMMA 1", "page_start": 17, "page_end": 17, "type": "Text", "text": "Next, under the non-degenerate L-Lipschitz condition of the function class (see Eq. (2)), we have \\sum_{n\\neq k} |f(v_n) - f(v_k)| = \\mathcal{O}(L\\Delta) . Therefore, the sum can be bounded (order-wise) as", "source": "marker_v2", "marker_block_id": "/page/16/Text/11"}
|
| 20 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0111", "section": "C PROOF OF LEMMA 1", "page_start": 17, "page_end": 17, "type": "Equation", "text": "\\left| \\sum_{n \\neq k} \\operatorname{Attn}_{n}^{(t)} (f(v_{n}) - f(v_{k})) \\right| = (1 - \\operatorname{Attn}_{k}^{(t)}) \\cdot \\mathcal{O}(L\\Delta)", "source": "marker_v2", "marker_block_id": "/page/16/Equation/12"}
|
| 21 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0112", "section": "C PROOF OF LEMMA 1", "page_start": 17, "page_end": 17, "type": "Text", "text": "and thus", "source": "marker_v2", "marker_block_id": "/page/16/Text/13"}
|
| 22 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0113", "section": "C PROOF OF LEMMA 1", "page_start": 17, "page_end": 17, "type": "Equation", "text": "\\left(\\sum_{n\\neq k}\\operatorname{Attn}_n^{(t)}(f(v_n)-f(v_k))\\right)^2 = (1-\\operatorname{Attn}_k^{(t)})^2 \\cdot \\mathcal{O}(L^2\\Delta^2).", "source": "marker_v2", "marker_block_id": "/page/16/Equation/14"}
|
| 23 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0114", "section": "C PROOF OF LEMMA 1", "page_start": 17, "page_end": 17, "type": "Text", "text": "Putting these together, we obtain:", "source": "marker_v2", "marker_block_id": "/page/16/Text/15"}
|
| 24 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0115", "section": "C PROOF OF LEMMA 1", "page_start": 17, "page_end": 17, "type": "Equation", "text": "\\mathcal{L}(P;Q) = \\frac{1}{2} \\sum_{k=1}^{K} \\mathbb{E}\\left[\\mathbb{1}\\{x_{\\text{query}} = v_k\\}(1 - \\operatorname{Attn}_k^{(t)})^2 \\cdot \\mathcal{O}(L^2 \\Delta^2)\\right].", "source": "marker_v2", "marker_block_id": "/page/16/Equation/16"}
|
| 25 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0116", "section": "C PROOF OF LEMMA 1", "page_start": 18, "page_end": 18, "type": "Text", "text": "This completes the proof of Lemma 1.", "source": "marker_v2", "marker_block_id": "/page/17/Text/1"}
|
| 26 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0117", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Text", "text": "To derive q_k , we first compute the gradient of prediction loss with respect to Q^{(t)} as follows:", "source": "marker_v2", "marker_block_id": "/page/17/Text/4"}
|
| 27 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0118", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Equation", "text": "\\nabla_{Q^{(t)}} \\mathcal{L} = \\mathbb{E} \\Big[ (\\hat{y}_{\\text{query}} - f(v_k))^\\top \\frac{\\partial \\hat{y}_{\\text{query}}}{\\partial Q^{(t)}} \\Big] = \\mathbb{E} \\Big[ (\\hat{y}_{\\text{query}} - f(v_k))^\\top \\sum_{i \\in [N]} \\frac{\\partial \\text{attn}_i}{\\partial Q^{(t)}} y_i \\Big].", "source": "marker_v2", "marker_block_id": "/page/17/Equation/5"}
|
| 28 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0119", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Text", "text": "We then compute the gradient of \\operatorname{attn}_i^{(t)} with respect to Q^{(t)}\\colon", "source": "marker_v2", "marker_block_id": "/page/17/Text/6"}
|
| 29 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0120", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Equation", "text": "\\begin{split} \\frac{\\partial \\text{attn}_{i}^{(t)}}{\\partial Q^{(t)}} &= \\frac{e^{\\bar{X}_{i}^{\\top}Q^{(t)}x_{\\text{query}}} \\cdot \\bar{X}_{i}^{\\top}x_{\\text{query}}^{\\top}(\\sum_{j \\in [N]} e^{\\bar{X}_{j}^{\\top}Q^{(t)}x_{\\text{query}}})^{2}}{(\\sum_{j \\in [N]} e^{\\bar{X}_{j}^{\\top}Q^{(t)}x_{\\text{query}}})^{2}} \\\\ &- \\frac{\\sum_{j \\in [N]} e^{\\bar{X}_{j}^{\\top}Q^{(t)}x_{\\text{query}}} \\cdot \\bar{X}_{j}^{\\top}x_{\\text{query}}^{\\top} \\cdot e^{\\bar{X}_{i}^{\\top}Q^{(t)}x_{\\text{query}}}}{(\\sum_{j \\in [N]} e^{\\bar{X}_{j}^{\\top}Q^{(t)}x_{\\text{query}}})^{2}} \\\\ &= \\text{attn}_{i}^{(t)} \\cdot \\bar{X}_{i}^{\\top}x_{\\text{query}} - \\text{attn}_{i}^{(t)} \\sum_{j \\in [N]} \\text{attn}_{j}^{(t)} \\cdot \\bar{X}_{j}^{\\top}x_{\\text{query}} \\\\ &= \\text{attn}_{i}^{(t)} \\sum_{j \\in [N]} \\text{attn}_{j}^{(t)}(\\bar{X}_{i} - \\bar{X}_{j})x_{\\text{query}}^{\\top}. \\end{split}", "source": "marker_v2", "marker_block_id": "/page/17/Equation/7"}
|
| 30 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0121", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Text", "text": "Substituting into the above expression gives:", "source": "marker_v2", "marker_block_id": "/page/17/Text/8"}
|
| 31 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0122", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Equation", "text": "\\nabla_{Q^{(t)}} \\mathcal{L} = \\mathbb{E}\\Big[ (\\hat{y}_{\\text{query}}^{(t)} - f(v_k)) \\sum_{i,j \\in [N]} \\operatorname{attn}_i^{(t)} \\operatorname{attn}_j^{(t)} (\\bar{X}_i - \\bar{X}_j) x_{\\text{query}}^\\top y_i \\Big].", "source": "marker_v2", "marker_block_id": "/page/17/Equation/9"}
|
| 32 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0123", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Text", "text": "For any feature vectors v_k and v_{k'} , we calculate", "source": "marker_v2", "marker_block_id": "/page/17/Text/10"}
|
| 33 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0124", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Equation", "text": "\\begin{split} v_{k'}^\\top \\nabla_{Q^{(t)}} \\mathcal{L} \\cdot v_k = & \\mathbb{E} \\Big[ \\mathbb{1} \\big\\{ x_{\\text{query}} = v_k \\big\\} \\big( \\hat{y}_{\\text{query}} - f(v_k) \\big) \\sum_{i,j \\in [N]} \\operatorname{attn}_i^{(t)} \\operatorname{attn}_j^{(t)} y_i v_{k'}^\\top (\\bar{X}_i - \\bar{X}_j) \\Big] \\\\ = & \\mathbb{E} \\Big[ \\mathbb{1} \\big\\{ x_{\\text{query}} = v_k \\big\\} \\big( \\hat{y}_{\\text{query}} - f(v_k) \\big) \\sum_{m,n \\in [K]} \\sum_{i \\in \\mathcal{V}_m} \\sum_{j \\in \\mathcal{V}_n} \\operatorname{attn}_i^{(t)} \\operatorname{attn}_j^{(t)} y_i v_{k'}^\\top (v_m - v_n) \\Big] \\\\ = & \\mathbb{E} \\Big[ \\mathbb{1} \\big\\{ x_{\\text{query}} = v_k \\big\\} \\big( \\hat{y}_{\\text{query}} - f(v_k) \\big) \\sum_{n \\in [K]} \\sum_{i \\in \\mathcal{V}_{k'}} \\sum_{j \\in \\mathcal{V}_n} \\operatorname{attn}_i^{(t)} \\operatorname{attn}_j^{(t)} y_i v_{k'}^\\top (v_{k'} - v_n) \\Big] \\\\ + & \\mathbb{E} \\Big[ \\mathbb{1} \\big\\{ x_{\\text{query}} = v_k \\big\\} \\big( \\hat{y}_{\\text{query}} - f(v_k) \\big) \\operatorname{Attn}_{k'}^{(t)} f(v_{k'}) \\sum_{n \\in [K]} \\operatorname{Attn}_n^{(t)} \\big\\} \\\\ = & \\mathbb{E} \\Big[ \\mathbb{1} \\big\\{ x_{\\text{query}} = v_k \\big\\} \\big( \\hat{y}_{\\text{query}} - f(v_k) \\big) \\operatorname{Attn}_{k'}^{(t)} f(v_{k'}) \\sum_{n \\in [K]} \\operatorname{Attn}_m^{(t)} f(v_m) \\Big] \\\\ = & \\mathbb{E} \\Big[ \\mathbb{1} \\big\\{ x_{\\text{query}} = v_k \\big\\} \\big( \\hat{y}_{\\text{query}} - f(v_k) \\big) \\operatorname{Attn}_{k'}^{(t)} \\sum_{m \\in [K]} \\operatorname{Attn}_m^{(t)} f(v_m) \\Big] \\\\ = & \\mathbb{E} \\Big[ \\mathbb{1} \\big\\{ x_{\\text{query}} = v_k \\big\\} \\big( \\hat{y}_{\\text{query}} - f(v_k) \\big) \\operatorname{Attn}_{k'}^{(t)} \\sum_{m \\in [K]} \\operatorname{Attn}_m^{(t)} \\big( f(v_{k'}) - f(v_m) \\big) \\Big]. \\end{split}", "source": "marker_v2", "marker_block_id": "/page/17/Equation/11"}
|
| 34 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0125", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Equation", "text": "Since \\hat{y}_{\\text{query}} = \\sum_{i \\in [N]} \\operatorname{attn}_i y_i = \\sum_{m \\in [K]} \\operatorname{Attn}_m^{(t)} f(v_m) , we obtain v_{k'}^{\\top} \\nabla_{Q^{(t)}} \\mathcal{L} v_k = -\\mathbb{E} \\Big[ \\mathbb{1} \\big\\{ x_{\\text{query}} = v_k \\big\\} \\operatorname{Attn}_{k'}^{(t)} \\sum_{n \\in [K]} \\sum_{m \\in [K]} \\operatorname{Attn}_m^{(t)} \\operatorname{Attn}_n^{(t)} (f(v_k) - f(v_n)) (f(v_{k'}) - f(v_m)) \\Big] \\\\ = -\\mathbb{E} \\Big[ \\mathbb{1} \\big\\{ x_{\\text{query}} = v_k \\big\\} \\operatorname{Attn}_{k'}^{(t)} (f(v_k) - \\sum_{n \\in [K]} \\operatorname{Attn}_n^{(t)} f(v_n)) (f(v_{k'}) - \\sum_{m \\in [K]} \\operatorname{Attn}_m^{(t)} f(v_m)) \\Big].", "source": "marker_v2", "marker_block_id": "/page/17/Equation/12"}
|
| 35 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0126", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Text", "text": "We then derive Eq. (10) by letting v_k = v_{k'} using this expression:", "source": "marker_v2", "marker_block_id": "/page/17/Text/13"}
|
| 36 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0127", "section": "D Proof of Lemma 2", "page_start": 18, "page_end": 18, "type": "Equation", "text": "g_k^{(t)} = -v_k^{\\top} \\nabla_{Q^{(t)}} \\mathcal{L} \\cdot v_k", "source": "marker_v2", "marker_block_id": "/page/17/Equation/14"}
|
| 37 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0128", "section": "D Proof of Lemma 2", "page_start": 19, "page_end": 19, "type": "Equation", "text": "\\begin{split} &= \\mathbb{E}\\left[\\mathbbm{1}\\{x_{\\mathrm{query}} = v_k\\} \\operatorname{Attn}_k^{(t)} \\left(f(v_k) - \\sum_{n \\in [K]} \\operatorname{Attn}_n^{(t)} f(v_n)\\right)^2\\right] \\\\ &= \\mathbb{E}\\left[\\mathbbm{1}\\{x_{\\mathrm{query}} = v_k\\} \\operatorname{Attn}_k^{(t)} \\left(\\sum_{n \\in [K]} \\operatorname{Attn}_n^{(t)} (f(v_k) - f(v_n))\\right)^2\\right] \\\\ &= \\mathbb{E}\\left[\\mathbbm{1}\\{x_{\\mathrm{query}} = v_k\\} \\operatorname{Attn}_k^{(t)} (1 - \\operatorname{Attn}_k^{(t)})^2 \\Theta(L^2 \\Delta^2)\\right], \\end{split}", "source": "marker_v2", "marker_block_id": "/page/18/Equation/1"}
|
| 38 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0129", "section": "D Proof of Lemma 2", "page_start": 19, "page_end": 19, "type": "Text", "text": "where the last equality follows from the non-degenerate L-Lipschitz condition in Eq. (2).", "source": "marker_v2", "marker_block_id": "/page/18/Text/2"}
|
| 39 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0130", "section": "D Proof of Lemma 2", "page_start": 19, "page_end": 19, "type": "Text", "text": "For any k \\neq n , we calculate", "source": "marker_v2", "marker_block_id": "/page/18/Text/3"}
|
| 40 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0131", "section": "D Proof of Lemma 2", "page_start": 19, "page_end": 19, "type": "Equation", "text": "\\begin{split} |g_{k,k'}^{(t)}| &= \\mathbb{E}\\Big[\\mathbbm{1}\\{x_{\\text{query}} = v_k\\} \\text{Attn}_{k'}^{(t)} | f(v_k) - \\sum_{j \\in [K]} \\text{Attn}_{j}^{(t)} f(v_j) | \\cdot | f(v_{k'}) - \\sum_{m \\in [K]} \\text{Attn}_{m}^{(t)} f(v_m) | \\Big] \\\\ &= p_k \\cdot \\mathbb{E}\\Big[\\text{Attn}_{k'}^{(t)} \\Big| \\sum_{j \\in [K]} (\\text{Attn}_{j}^{(t)} f(v_k) - \\text{Attn}_{j}^{(t)} f(v_j)) \\Big| \\cdot \\Big| \\sum_{m \\in [K]} (\\text{Attn}_{m}^{(t)} f(v_{k'}) - \\text{Attn}_{m}^{(t)} f(v_m)) \\Big| \\Big] \\\\ &= p_k \\cdot \\mathbb{E}\\Big[\\text{Attn}_{k'}^{(t)} \\cdot \\sum_{j \\in [K]} \\text{Attn}_{j}^{(t)} | f(v_k) - f(v_j) | \\cdot \\sum_{m \\in [K]} \\text{Attn}_{m}^{(t)} | f(v_{k'}) - f(v_m) | \\Big] \\\\ &= p_k \\cdot \\mathbb{E}\\left[\\text{Attn}_{k'}^{(t)} \\cdot (1 - \\text{Attn}_{k}^{(t)}) \\cdot (1 - \\text{Attn}_{k'}^{(t)}) \\cdot \\Theta(L^2\\Delta^2) \\right]. \\end{split}", "source": "marker_v2", "marker_block_id": "/page/18/Equation/4"}
|
| 41 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0132", "section": "D Proof of Lemma 2", "page_start": 19, "page_end": 19, "type": "Text", "text": "This completes the proof of Lemma 2.", "source": "marker_v2", "marker_block_id": "/page/18/Text/5"}
|
| 42 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0133", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "Text", "text": "Lemma 3. For any t \\in \\{1, ..., T_f^1\\} , if x_{\\text{query}} = v_k , we have:", "source": "marker_v2", "marker_block_id": "/page/18/Text/8"}
|
| 43 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0134", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "ListGroup", "text": "Attn<sub>k</sub><sup>(t)</sup> = \\Omega\\left(\\frac{1}{K}\\right) , 1 \\operatorname{Attn}_{k}^{(t)} = \\Theta(1) , \\operatorname{Attn}_{n}^{(t)} = \\Theta\\left(\\frac{1 \\operatorname{Attn}_{k}^{(t)}}{K}\\right) = \\Theta\\left(\\frac{1}{K}\\right) for all n \\neq k .", "source": "marker_v2", "marker_block_id": "/page/18/ListGroup/272"}
|
| 44 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0135", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "Text", "text": "Proof. Fix any t \\in \\{1, \\dots, T_f^1\\} . By definition,", "source": "marker_v2", "marker_block_id": "/page/18/Text/12"}
|
| 45 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0136", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "Equation", "text": "\\begin{aligned} \\text{Attn}_{k}^{(t)} &= \\frac{|\\mathcal{V}_{k}| e^{v_{k}^{\\top} Q^{(t)} v_{k}}}{\\sum_{j \\in [N]} e^{E_{j}^{x \\top} Q^{(t)} v_{k}}} = \\frac{|\\mathcal{V}_{k}| e^{q_{k}^{(t)}}}{\\sum_{m \\neq k} |\\mathcal{V}_{m}| e^{q_{k,m}^{(t)}} + |\\mathcal{V}_{k}| e^{q_{k}^{(t)}}} \\\\ &= \\frac{1}{\\sum_{m \\neq k} \\frac{|\\mathcal{V}_{m}|}{|\\mathcal{V}_{k}|} \\exp(q_{k,m}^{(t)} - q_{k}^{(t)}) + 1}. \\end{aligned}", "source": "marker_v2", "marker_block_id": "/page/18/Equation/13"}
|
| 46 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0137", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "Text", "text": "By the symmetry property in the initial phase, q_{k,m}^{(t)} = \\Theta\\left(\\frac{q_k^{(t)}}{K}\\right) . Thus,", "source": "marker_v2", "marker_block_id": "/page/18/Text/14"}
|
| 47 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0138", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "Equation", "text": "e^{-(\\log K + \\Theta(\\frac{\\log K}{K}))} \\leq \\exp(q_{k,m}^{(t)} - q_k^{(t)}) \\leq e^{\\Theta(\\frac{\\log K}{K})}.", "source": "marker_v2", "marker_block_id": "/page/18/Equation/15"}
|
| 48 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0139", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "Text", "text": "Define u_k = K(p_k - \\delta) and U_k = K(p_k + \\delta) . Then, from the concentration property (see Eq. (7)), |\\mathcal{V}_k| \\in [\\frac{u_k}{K}N, \\frac{U_k}{K}N] for constants u_k, U_k = \\Theta(1) . Therefore,", "source": "marker_v2", "marker_block_id": "/page/18/Text/16"}
|
| 49 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0140", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "Equation", "text": "\\operatorname{Attn}_k^{(t)} \\geq \\frac{1}{e^{\\Theta(\\frac{\\log K}{K})}(\\frac{N}{|\\mathcal{V}_k|}-1)+1} \\geq \\frac{1}{e^{\\Theta(\\frac{\\log K}{K})}(\\frac{K}{u_k}-1)+1} = \\Omega\\left(\\frac{1}{K}\\right).", "source": "marker_v2", "marker_block_id": "/page/18/Equation/17"}
|
| 50 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0141", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "Text", "text": "For the upper bound,", "source": "marker_v2", "marker_block_id": "/page/18/Text/18"}
|
| 51 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0142", "section": "E.1 Proof of Proposition 2", "page_start": 19, "page_end": 19, "type": "Equation", "text": "Attn_k^{(t)} \\le \\frac{1}{e^{-(\\log K + \\Theta(\\frac{\\log K}{K}))}(\\frac{N}{|\\mathcal{V}_k|} - 1) + 1} \\le \\frac{1}{e^{-1}(\\frac{1}{U_k} - \\frac{1}{K}) + 1},", "source": "marker_v2", "marker_block_id": "/page/18/Equation/19"}
|
| 52 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0143", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "which follows because U_k = \\Theta(1) , and hence", "source": "marker_v2", "marker_block_id": "/page/19/Text/1"}
|
| 53 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0144", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "1 - \\operatorname{Attn}_{k}^{(t)} \\ge \\frac{\\frac{1}{U_{k}} - \\frac{1}{K}}{(\\frac{1}{U_{k}} - \\frac{1}{K}) + e} = \\Theta(1).", "source": "marker_v2", "marker_block_id": "/page/19/Equation/2"}
|
| 54 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0145", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "The reverse bound is similar, showing 1 - \\text{Attn}_k^{(t)} = \\Theta(1) .", "source": "marker_v2", "marker_block_id": "/page/19/Text/3"}
|
| 55 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0146", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "For n \\neq k , by similar calculation,", "source": "marker_v2", "marker_block_id": "/page/19/Text/4"}
|
| 56 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0147", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "Attn_n^{(t)} = \\frac{|\\mathcal{V}_n| \\exp(q_{k,n}^{(t)})}{\\sum_{m \\neq k} |\\mathcal{V}_m| \\exp(q_{k,m}^{(t)}) + |\\mathcal{V}_k| \\exp(q_k^{(t)})},", "source": "marker_v2", "marker_block_id": "/page/19/Equation/5"}
|
| 57 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0148", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "and since |\\mathcal{V}_m|/|\\mathcal{V}_n| = \\Theta(1) and \\exp(q_{k,m}^{(t)} - q_{k,n}^{(t)}) = e^{O(\\frac{\\log K}{K})} ,", "source": "marker_v2", "marker_block_id": "/page/19/Text/6"}
|
| 58 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0149", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "\\frac{\\operatorname{Attn}_{n}^{(t)}}{1 - \\operatorname{Attn}_{k}^{(t)}} = \\frac{|\\mathcal{V}_{n}| \\exp(q_{k,n}^{(t)})}{\\sum_{m \\neq k} |\\mathcal{V}_{m}| \\exp(q_{k,m}^{(t)})} = \\Theta\\left(\\frac{1}{K}\\right).", "source": "marker_v2", "marker_block_id": "/page/19/Equation/7"}
|
| 59 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0150", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "Thus, \\operatorname{Attn}_n^{(t)} = (1 - \\operatorname{Attn}_k^{(t)})\\Theta\\left(\\frac{1}{K}\\right) = \\Theta\\left(\\frac{1}{K}\\right) , since 1 - \\operatorname{Attn}_k^{(t)} = \\Theta(1) .", "source": "marker_v2", "marker_block_id": "/page/19/Equation/8"}
|
| 60 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0151", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "Lemma 4. For any t \\in \\{1, ..., T_f^1\\} , given x_{query} = v_k , we have:", "source": "marker_v2", "marker_block_id": "/page/19/Text/9"}
|
| 61 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0152", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "• g_k^{(t)} = \\Theta\\left(\\frac{L^2\\Delta^2}{K}\\right) ,", "source": "marker_v2", "marker_block_id": "/page/19/Equation/10"}
|
| 62 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0153", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "• |g_{k,n}^{(t)}| = O\\left(\\frac{L^2\\Delta^2}{K^2}\\right) for any n \\neq k .", "source": "marker_v2", "marker_block_id": "/page/19/Equation/11"}
|
| 63 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0154", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "Proof. By the gradient expression from Lemma 2, we have", "source": "marker_v2", "marker_block_id": "/page/19/Text/12"}
|
| 64 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0155", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "g_k^{(t)} = \\mathbb{E}\\left[\\mathbb{1}\\left\\{x_{\\text{query}} = v_k\\right\\} \\operatorname{Attn}_k^{(t)} (1 - \\operatorname{Attn}_k^{(t)})^2 \\Theta(L^2 \\Delta^2)\\right] = p_k \\cdot \\mathbb{E}\\left[\\operatorname{Attn}_k^{(t)} (1 - \\operatorname{Attn}_k^{(t)})^2 \\mid x_{\\text{query}} = v_k\\right] \\cdot \\Theta(L^2 \\Delta^2).", "source": "marker_v2", "marker_block_id": "/page/19/Equation/13"}
|
| 65 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0156", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "By Lemma 3, in Phase I, we have", "source": "marker_v2", "marker_block_id": "/page/19/Text/14"}
|
| 66 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0157", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "p_k = \\Theta(1/K) , \\operatorname{Attn}_k^{(t)} = \\Theta(1) , and 1 - \\operatorname{Attn}_k^{(t)} = \\Theta(1) .", "source": "marker_v2", "marker_block_id": "/page/19/Equation/15"}
|
| 67 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0158", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "Therefore,", "source": "marker_v2", "marker_block_id": "/page/19/Text/16"}
|
| 68 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0159", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "g_k^{(t)} = \\Theta\\left(\\frac{1}{K} \\cdot 1 \\cdot (1)^2 \\cdot L^2 \\Delta^2\\right) = \\Theta\\left(\\frac{L^2 \\Delta^2}{K}\\right).", "source": "marker_v2", "marker_block_id": "/page/19/Equation/17"}
|
| 69 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0160", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "For the cross-gradient term, for n \\neq k ,", "source": "marker_v2", "marker_block_id": "/page/19/Text/18"}
|
| 70 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0161", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "\\begin{split} |g_{k,n}^{(t)}| &= \\mathbb{E}\\Big[\\mathbbm{1}\\{x_{\\mathrm{query}} = v_k\\} \\operatorname{Attn}_n^{(t)} |f(v_k) - \\sum_j \\operatorname{Attn}_j^{(t)} f(v_j)| \\, |f(v_n) - \\sum_m \\operatorname{Attn}_m^{(t)} f(v_m)| \\Big] \\\\ &= p_k \\cdot \\mathbb{E}\\Big[\\operatorname{Attn}_n^{(t)} \\Big| \\sum_j \\operatorname{Attn}_j^{(t)} (f(v_k) - f(v_j)) \\Big| \\, \\Big| \\sum_m \\operatorname{Attn}_m^{(t)} (f(v_n) - f(v_m)) \\Big| \\, | \\, x_{\\mathrm{query}} = v_k \\Big] \\\\ &\\leq p_k \\cdot \\mathbb{E}\\left[\\operatorname{Attn}_n^{(t)} \\cdot \\sum_j \\operatorname{Attn}_j^{(t)} |f(v_k) - f(v_j)| \\cdot \\sum_m \\operatorname{Attn}_m^{(t)} |f(v_n) - f(v_m)| \\right] \\\\ &= p_k \\cdot \\mathbb{E}\\left[\\operatorname{Attn}_n^{(t)} (1 - \\operatorname{Attn}_k^{(t)}) (1 - \\operatorname{Attn}_n^{(t)}) \\mathcal{O}(L^2 \\Delta^2) \\right]. \\end{split}", "source": "marker_v2", "marker_block_id": "/page/19/Equation/19"}
|
| 71 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0162", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "By Lemma 3, \\operatorname{Attn}_n^{(t)} = \\Theta(1/K) and 1 - \\operatorname{Attn}_k^{(t)}, 1 - \\operatorname{Attn}_n^{(t)} = \\Theta(1) , so", "source": "marker_v2", "marker_block_id": "/page/19/Text/20"}
|
| 72 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0163", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "|g_{k,n}^{(t)}| = \\mathcal{O}\\left(\\frac{1}{K} \\cdot \\frac{1}{K} \\cdot 1 \\cdot 1 \\cdot L^2 \\Delta^2\\right) = \\mathcal{O}\\left(\\frac{L^2 \\Delta^2}{K^2}\\right)", "source": "marker_v2", "marker_block_id": "/page/19/Equation/21"}
|
| 73 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0164", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "This completes the proof of Lemma 4.", "source": "marker_v2", "marker_block_id": "/page/19/Text/22"}
|
| 74 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0165", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Text", "text": "Lemma 5. Given \\delta = o(1) , at the end of Phase I (i.e., at t = T_f^1 + 1 ), we have:", "source": "marker_v2", "marker_block_id": "/page/19/Text/23"}
|
| 75 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0166", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "• q_h^{(T_f^1+1)} = \\Theta(\\log K) ,", "source": "marker_v2", "marker_block_id": "/page/19/Equation/24"}
|
| 76 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0167", "section": "E.1 Proof of Proposition 2", "page_start": 20, "page_end": 20, "type": "Equation", "text": "• \\operatorname{Attn}_{k}^{(T_f^1+1)} = \\Omega\\left(\\frac{1}{1+\\delta}\\right) if x_{\\text{query}} = v_k.", "source": "marker_v2", "marker_block_id": "/page/19/Equation/25"}
|
| 77 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0168", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Text", "text": "Proof. By Lemma 4, we have g_k^{(t)} = \\Theta\\left(\\frac{L^2\\Delta^2}{K}\\right) for all t in Phase I. Thus,", "source": "marker_v2", "marker_block_id": "/page/20/Text/1"}
|
| 78 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0169", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Equation", "text": "\\begin{aligned} q_k^{(T_f^1+1)} &= q_k^{(0)} + \\eta \\sum_{t=1}^{T_f^1} g_k^{(t)} \\\\ &= q_k^{(0)} + \\eta \\cdot T_f^1 \\cdot \\Theta\\left(\\frac{L^2 \\Delta^2}{K}\\right) \\\\ &= \\Theta(\\log K), \\end{aligned}", "source": "marker_v2", "marker_block_id": "/page/20/Equation/2"}
|
| 79 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0170", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Text", "text": "where we apply the definition of T_f^1 from the main text.", "source": "marker_v2", "marker_block_id": "/page/20/Text/3"}
|
| 80 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0171", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Text", "text": "For the off-diagonal terms, from Lemma 4, |g_{k,m}^{(t)}| = O\\left(\\frac{L^2\\Delta^2}{K^2}\\right) for any m \\neq k . Hence,", "source": "marker_v2", "marker_block_id": "/page/20/Text/4"}
|
| 81 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0172", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Equation", "text": "\\begin{split} q_{k,m}^{(T_f^1+1)} &\\leq |q_{k,m}^{(0)}| + \\eta \\cdot T_f^1 \\cdot \\mathcal{O}\\left(\\frac{L^2 \\Delta^2}{K^2}\\right) \\\\ &= \\mathcal{O}\\left(\\frac{\\log K}{K}\\right). \\end{split}", "source": "marker_v2", "marker_block_id": "/page/20/Equation/5"}
|
| 82 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0173", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Text", "text": "Therefore, at the end of Phase I,", "source": "marker_v2", "marker_block_id": "/page/20/Text/6"}
|
| 83 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0174", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Equation", "text": "q_k^{(T_f^1+1)} - q_{k,m}^{(T_f^1+1)} = \\Theta(\\log K) - \\mathcal{O}\\left(\\frac{\\log K}{K}\\right) = \\Theta(\\log K).", "source": "marker_v2", "marker_block_id": "/page/20/Equation/7"}
|
| 84 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0175", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Text", "text": "Now, the attention weight for k at time t is", "source": "marker_v2", "marker_block_id": "/page/20/Text/8"}
|
| 85 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0176", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Equation", "text": "Attn_k^{(t)} = \\frac{1}{\\sum_{m \\neq k} \\frac{|\\mathcal{V}_m|}{|\\mathcal{V}_k|} \\exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.", "source": "marker_v2", "marker_block_id": "/page/20/Equation/9"}
|
| 86 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0177", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Text", "text": "Using the above, for t = T_f^1 + 1 ,", "source": "marker_v2", "marker_block_id": "/page/20/Text/10"}
|
| 87 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0178", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Equation", "text": "\\exp(q_{k,m}^{(t)} - q_k^{(t)}) \\leq \\exp\\left(\\mathcal{O}\\left(\\frac{\\log K}{K}\\right) - \\log K\\right) = \\mathcal{O}\\left(\\frac{1}{K}\\right).", "source": "marker_v2", "marker_block_id": "/page/20/Equation/11"}
|
| 88 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0179", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Text", "text": "By the concentration condition in Eq. (7), |\\hat{\\mathcal{V}}_k| \\geq \\frac{u_k}{K} N for some u_k = \\Theta(1) , and N/|\\mathcal{V}_k| = \\Theta(1/\\delta) (since \\delta = o(1) is the imbalance parameter). Thus,", "source": "marker_v2", "marker_block_id": "/page/20/Text/12"}
|
| 89 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0180", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Equation", "text": "\\operatorname{Attn}_{k}^{(t)} \\ge \\frac{1}{\\mathcal{O}\\left(\\frac{1}{K}\\right)\\left(\\frac{N}{|\\mathcal{V}_{k}|} - 1\\right) + 1} \\ge \\frac{1}{\\mathcal{O}\\left(\\frac{1}{u_{k}} - \\frac{1}{K}\\right) + 1} = \\Omega\\left(\\frac{1}{1 + \\delta}\\right),", "source": "marker_v2", "marker_block_id": "/page/20/Equation/13"}
|
| 90 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0181", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Text", "text": "where the last equality follows because 1/u_k - 1/K = \\Theta(\\delta) from Eq. (7).", "source": "marker_v2", "marker_block_id": "/page/20/Text/14"}
|
| 91 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0182", "section": "E.1 Proof of Proposition 2", "page_start": 21, "page_end": 21, "type": "Text", "text": "This completes the proof of Lemma 5 and Proposition 2.", "source": "marker_v2", "marker_block_id": "/page/20/Text/15"}
|
| 92 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0183", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 21, "page_end": 21, "type": "Text", "text": "Lemma 6. For any t \\in \\{T_f^1 + 1, \\dots, T_f^*\\} , given \\delta = o(1) , if x_{\\text{query}} = v_k , we have:", "source": "marker_v2", "marker_block_id": "/page/20/Text/17"}
|
| 93 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0184", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 21, "page_end": 21, "type": "ListGroup", "text": "Attn _k^{(t)} = \\Omega\\left(\\frac{1}{1+\\delta}\\right) , 1 \\operatorname{Attn}_{k}^{(t)} = \\mathcal{O}(\\delta) , \\operatorname{Attn}_n^{(t)} = \\Theta\\left(\\frac{1 \\operatorname{Attn}_k^{(t)}}{K}\\right) = \\Theta\\left(\\frac{\\delta}{K}\\right) for any n \\neq k .", "source": "marker_v2", "marker_block_id": "/page/20/ListGroup/281"}
|
| 94 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0185", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 21, "page_end": 21, "type": "Text", "text": "Proof. By Proposition 2 (see also Lemma 5), for any t \\ge T_f^1 + 1 , we have \\operatorname{Attn}_k^{(t)} = \\Omega\\left(\\frac{1}{1+\\delta}\\right) .", "source": "marker_v2", "marker_block_id": "/page/20/Text/21"}
|
| 95 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0186", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 21, "page_end": 21, "type": "Text", "text": "We now show that 1 - \\operatorname{Attn}_k^{(t)} = \\mathcal{O}(\\delta) . Using the same attention formula as before,", "source": "marker_v2", "marker_block_id": "/page/20/Text/22"}
|
| 96 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0187", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 21, "page_end": 21, "type": "Equation", "text": "Attn_k^{(t)} = \\frac{1}{\\sum_{m \\neq k} \\frac{|\\mathcal{V}_m|}{|\\mathcal{V}_k|} \\exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.", "source": "marker_v2", "marker_block_id": "/page/20/Equation/23"}
|
| 97 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0188", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "From previous bounds, \\exp(q_{k,m}^{(t)}-q_k^{(t)})=O\\left(\\frac{1}{K}\\right) , and |\\mathcal{V}_k|\\geq u_kN/K with 1/u_k-1/K=\\Theta(\\delta) . Therefore,", "source": "marker_v2", "marker_block_id": "/page/21/Text/1"}
|
| 98 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0189", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "\\operatorname{Attn}_{k}^{(t)} \\geq \\frac{1}{\\mathcal{O}\\left(\\frac{1}{K}\\right)\\left(\\frac{N}{|\\mathcal{V}_{k}|} - 1\\right) + 1} \\geq \\frac{1}{\\mathcal{O}\\left(\\frac{1}{u_{k}} - \\frac{1}{K}\\right) + 1} = \\Omega\\left(\\frac{1}{1 + \\delta}\\right).", "source": "marker_v2", "marker_block_id": "/page/21/Equation/2"}
|
| 99 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0190", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "For the upper bound, we compute:", "source": "marker_v2", "marker_block_id": "/page/21/Text/3"}
|
| 100 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0191", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "1 - \\operatorname{Attn}_{k}^{(t)} \\le 1 - \\frac{1}{\\mathcal{O}\\left(\\frac{1}{K}\\right)\\left(\\frac{N}{|\\mathcal{V}_{k}|} - 1\\right) + 1} = \\frac{\\mathcal{O}\\left(\\frac{1}{u_{k}} - \\frac{1}{K}\\right)}{\\mathcal{O}\\left(\\frac{1}{u_{k}} - \\frac{1}{K}\\right) + 1} = \\mathcal{O}(\\delta),", "source": "marker_v2", "marker_block_id": "/page/21/Equation/4"}
|
| 101 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0192", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "where the last equality uses \\frac{1}{u_k} - \\frac{1}{K} = \\Theta(\\delta) from Eq. (7). Thus, 1 - \\operatorname{Attn}_k^{(t)} = \\mathcal{O}(\\delta) .", "source": "marker_v2", "marker_block_id": "/page/21/Text/5"}
|
| 102 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0193", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "Finally, for any n \\neq k , we can use the same method as in Lemma 3 to obtain:", "source": "marker_v2", "marker_block_id": "/page/21/Text/6"}
|
| 103 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0194", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "\\operatorname{Attn}_{n}^{(t)} = \\mathcal{O}\\left(\\frac{1 - \\operatorname{Attn}_{k}^{(t)}}{K}\\right) = \\mathcal{O}\\left(\\frac{\\delta}{K}\\right).", "source": "marker_v2", "marker_block_id": "/page/21/Equation/7"}
|
| 104 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0195", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "This completes the proof.", "source": "marker_v2", "marker_block_id": "/page/21/Text/8"}
|
| 105 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0196", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "Lemma 7. For any t \\in \\{T_f^1 + 1, \\dots, T_f^*\\} and any fixed k \\in [K] , we have:", "source": "marker_v2", "marker_block_id": "/page/21/Text/9"}
|
| 106 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0197", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "• g_k^{(t)} = \\Theta\\left(\\frac{\\delta^2 L^2 \\Delta^2}{K}\\right) ,", "source": "marker_v2", "marker_block_id": "/page/21/Equation/10"}
|
| 107 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0198", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "• |g_{k,n}^{(t)}| = \\mathcal{O}\\left(\\frac{\\delta^2 L^2 \\Delta^2}{K^2}\\right) for all n \\neq k .", "source": "marker_v2", "marker_block_id": "/page/21/Equation/11"}
|
| 108 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0199", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "Proof. Recall from the gradient expression and Lemma 4:", "source": "marker_v2", "marker_block_id": "/page/21/Text/12"}
|
| 109 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0200", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "\\begin{split} g_k^{(t)} &= \\mathbb{E}\\left[\\mathbb{1}\\{x_{\\text{query}} = v_k\\} \\operatorname{Attn}_k^{(t)} (1 - \\operatorname{Attn}_k^{(t)})^2 \\Theta(L^2 \\Delta^2)\\right] \\\\ &= p_k \\cdot \\mathbb{E}\\left[\\operatorname{Attn}_k^{(t)} (1 - \\operatorname{Attn}_k^{(t)})^2 \\mid x_{\\text{query}} = v_k\\right] \\cdot \\Theta(L^2 \\Delta^2). \\end{split}", "source": "marker_v2", "marker_block_id": "/page/21/Equation/13"}
|
| 110 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0201", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "By Lemma 5 and subsequent results for Phase II, we have p_k = \\Theta(1/K) , \\operatorname{Attn}_k^{(t)} = \\Theta(1) , and 1 - \\operatorname{Attn}_k^{(t)} = \\Theta(\\delta) . Therefore,", "source": "marker_v2", "marker_block_id": "/page/21/Text/14"}
|
| 111 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0202", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "g_k^{(t)} = \\Theta\\left(\\frac{1}{K} \\cdot 1 \\cdot \\delta^2 \\cdot L^2 \\Delta^2\\right) = \\Theta\\left(\\frac{\\delta^2 L^2 \\Delta^2}{K}\\right).", "source": "marker_v2", "marker_block_id": "/page/21/Equation/15"}
|
| 112 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0203", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "For the cross-gradient terms with n \\neq k , using the same approach as in Lemma 4, we obtain", "source": "marker_v2", "marker_block_id": "/page/21/Text/16"}
|
| 113 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0204", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "|g_{k,n}^{(t)}| \\le p_k \\cdot \\mathbb{E}\\left[\\operatorname{Attn}_n^{(t)}(1 - \\operatorname{Attn}_k^{(t)})(1 - \\operatorname{Attn}_n^{(t)}) \\cdot \\mathcal{O}(L^2\\Delta^2)\\right].", "source": "marker_v2", "marker_block_id": "/page/21/Equation/17"}
|
| 114 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0205", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "In Phase II, by the previous lemma, we have \\operatorname{Attn}_n^{(t)} = \\Theta(\\delta/K) , 1 - \\operatorname{Attn}_n^{(t)} = \\Theta(1) , and 1 - \\operatorname{Attn}_k^{(t)} = \\Theta(\\delta) . Thus,", "source": "marker_v2", "marker_block_id": "/page/21/Text/18"}
|
| 115 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0206", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "|g_{k,n}^{(t)}| = \\mathcal{O}\\left(\\frac{1}{K} \\cdot \\frac{\\delta}{K} \\cdot \\delta \\cdot 1 \\cdot L^2 \\Delta^2\\right) = \\mathcal{O}\\left(\\frac{\\delta^2 L^2 \\Delta^2}{K^2}\\right).", "source": "marker_v2", "marker_block_id": "/page/21/Equation/19"}
|
| 116 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0207", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "This completes the proof of Lemma 7.", "source": "marker_v2", "marker_block_id": "/page/21/Text/20"}
|
| 117 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0208", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "Lemma 8. At the end of Phase II under the flat L-regime (i.e., t = T_f^* + 1 ), if x_{query} = v_k , we have:", "source": "marker_v2", "marker_block_id": "/page/21/Text/21"}
|
| 118 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0209", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "• q_k^{(T_f^*+1)} = \\Theta\\left(\\frac{\\log K}{\\epsilon}\\right) ,", "source": "marker_v2", "marker_block_id": "/page/21/Equation/22"}
|
| 119 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0210", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "• Attn k (T_f^*+1) = \\Omega\\left(\\frac{1}{1+\\epsilon\\delta}\\right) ,", "source": "marker_v2", "marker_block_id": "/page/21/Equation/23"}
|
| 120 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0211", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "• 1 - \\operatorname{Attn}_{k}^{(T_f^* + 1)} = \\mathcal{O}(\\epsilon \\delta).", "source": "marker_v2", "marker_block_id": "/page/21/Equation/24"}
|
| 121 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0212", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Text", "text": "Proof. By Lemma 7, we have g_k^{(t)} = \\Theta\\left(\\frac{\\delta^2 L^2 \\Delta^2}{K}\\right) in Phase II. Thus,", "source": "marker_v2", "marker_block_id": "/page/21/Text/25"}
|
| 122 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0213", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 22, "page_end": 22, "type": "Equation", "text": "q_k^{(T_f^*+1)} = q_k^{(T_f^1)} + \\eta \\cdot \\Theta\\left(\\frac{L^2 \\Delta^2 \\delta^2}{K}\\right) \\cdot (T_f^* - T_f^1)", "source": "marker_v2", "marker_block_id": "/page/21/Equation/26"}
|
| 123 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0214", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Equation", "text": "1188 = \\Theta(\\log(K\\epsilon^{-1})) 1190 = \\Theta\\left(\\frac{\\log K}{\\epsilon}\\right),", "source": "marker_v2", "marker_block_id": "/page/22/Equation/1"}
|
| 124 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0215", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Text", "text": "where the last step applies the scaling of T_f^* and the learning rate in the flat L-regime.", "source": "marker_v2", "marker_block_id": "/page/22/Text/2"}
|
| 125 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0216", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Text", "text": "For the cross terms, by Lemma 7 again.", "source": "marker_v2", "marker_block_id": "/page/22/Text/3"}
|
| 126 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0217", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Equation", "text": "\\begin{split} q_{k,m}^{(T_f^*+1)} &\\leq |q_{k,m}^{(T_f^1)}| + \\eta \\cdot \\mathcal{O}\\left(\\frac{\\delta^2 L^2 \\Delta^2}{K^2}\\right) \\cdot (T_f^* - T_f^1) \\\\ &= \\Theta\\left(\\frac{\\log(K\\epsilon^{-1})}{K}\\right). \\end{split}", "source": "marker_v2", "marker_block_id": "/page/22/Equation/4"}
|
| 127 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0218", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Text", "text": "Therefore, at t = T_f^* + 1 , we have", "source": "marker_v2", "marker_block_id": "/page/22/Text/5"}
|
| 128 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0219", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Equation", "text": "q_{k,m}^{(T_f^*+1)} - q_k^{(T_f^*+1)} = \\mathcal{O}\\left(\\frac{\\log(K\\epsilon^{-1})}{K}\\right) - \\Theta(\\log(K\\epsilon^{-1})) = -\\Theta(\\log(K\\epsilon^{-1})),", "source": "marker_v2", "marker_block_id": "/page/22/Equation/6"}
|
| 129 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0220", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Text", "text": "and so", "source": "marker_v2", "marker_block_id": "/page/22/Text/7"}
|
| 130 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0221", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Equation", "text": "\\exp(q_{k,m}^{(t)} - q_k^{(t)}) \\leq \\exp\\left(-\\Theta(\\log K)\\right) = \\mathcal{O}\\left(\\frac{1}{K}\\right).", "source": "marker_v2", "marker_block_id": "/page/22/Equation/8"}
|
| 131 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0222", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Text", "text": "The attention weight for k is then", "source": "marker_v2", "marker_block_id": "/page/22/Text/9"}
|
| 132 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0223", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Equation", "text": "\\operatorname{Attn}_k^{(t)} = \\frac{1}{\\sum_{m \\neq k} \\frac{|\\mathcal{V}_m|}{|\\mathcal{V}_k|} \\exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}. Using the bounds above, and |\\mathcal{V}_k| \\geq u_k N/K , with \\frac{1}{u_k} - \\frac{1}{K} = \\Theta(\\delta) (see Eq. (7)), we obtain:", "source": "marker_v2", "marker_block_id": "/page/22/Equation/10"}
|
| 133 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0224", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Equation", "text": "\\operatorname{Attn}_{k}^{(T_{f}^{*}+1)} \\geq \\frac{1}{\\mathcal{O}(\\epsilon) \\cdot \\mathcal{O}\\left(\\frac{1}{u_{k}} - \\frac{1}{K}\\right) + 1} = \\Omega\\left(\\frac{1}{1 + \\epsilon\\delta}\\right).", "source": "marker_v2", "marker_block_id": "/page/22/Equation/12"}
|
| 134 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0225", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Text", "text": "Similarly,", "source": "marker_v2", "marker_block_id": "/page/22/Text/13"}
|
| 135 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0226", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Equation", "text": "1 - \\operatorname{Attn}_{k}^{(T_{f}^{*}+1)} \\leq \\frac{\\mathcal{O}(\\epsilon) \\cdot \\mathcal{O}\\left(\\frac{1}{u_{k}} - \\frac{1}{K}\\right)}{\\mathcal{O}(\\epsilon) \\cdot \\mathcal{O}\\left(\\frac{1}{u_{k}} - \\frac{1}{K}\\right) + 1} = \\mathcal{O}(\\epsilon\\delta).", "source": "marker_v2", "marker_block_id": "/page/22/Equation/14"}
|
| 136 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0227", "section": "E.2 PROOF OF PROPOSITION 3", "page_start": 23, "page_end": 23, "type": "Text", "text": "This completes the proof of Lemma 8 and Proposition 3.", "source": "marker_v2", "marker_block_id": "/page/22/Text/15"}
|
| 137 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0228", "section": "E.3 PROOF OF THEOREM 1", "page_start": 23, "page_end": 23, "type": "Text", "text": "Recall from Lemma 2 and its proof that the prediction error \\mathcal{L}(P;Q) defined in Eq. (5) can be expressed as", "source": "marker_v2", "marker_block_id": "/page/22/Text/17"}
|
| 138 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0229", "section": "E.3 PROOF OF THEOREM 1", "page_start": 23, "page_end": 23, "type": "Equation", "text": "\\mathcal{L}(P;Q) = \\frac{1}{2} \\sum_{k=1}^{K} \\mathbb{E}\\left[\\mathbb{1}\\left\\{x_{\\text{query}} = v_k\\right\\} (1 - \\text{Attn}_k^{(t)})^2 \\mathcal{O}(L^2 \\Delta^2)\\right],", "source": "marker_v2", "marker_block_id": "/page/22/Equation/18"}
|
| 139 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0230", "section": "E.3 PROOF OF THEOREM 1", "page_start": 23, "page_end": 23, "type": "Text", "text": "where we use \\sum_{n \\neq k} \\operatorname{Attn}_n^{(t)} = 1 - \\operatorname{Attn}_k^{(t)} and, by the function class assumption, |f(v_n) - f(v_k)| = 1 \\Theta(L\\Delta) .", "source": "marker_v2", "marker_block_id": "/page/22/Text/19"}
|
| 140 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0231", "section": "E.3 PROOF OF THEOREM 1", "page_start": 23, "page_end": 23, "type": "Text", "text": "At the end of Phase II (i.e., at t=T_f^*+1 ), suppose x_{\\rm query}=v_k . By Lemma 8, we have 1 - \\operatorname{Attn}_{L}^{(T_f^* + 1)} = O(\\epsilon \\delta) . Therefore,", "source": "marker_v2", "marker_block_id": "/page/22/Text/20"}
|
| 141 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0232", "section": "E.3 PROOF OF THEOREM 1", "page_start": 23, "page_end": 23, "type": "Equation", "text": "\\mathcal{L}(P;Q) = \\frac{1}{2} \\sum_{k=1}^{K} \\mathbb{E} \\left[ \\mathbb{1} \\{ x_{\\text{query}} = v_k \\} (1 - \\text{Attn}_k^{(T_f^* + 1)})^2 \\mathcal{O}(L^2 \\Delta^2) \\right] = \\mathbb{E} \\left[ (1 - \\text{Attn}_k^{(T_f^* + 1)})^2 \\mathcal{O}(L^2 \\Delta^2) \\right] = \\mathcal{O}(\\epsilon^2),", "source": "marker_v2", "marker_block_id": "/page/22/Equation/21"}
|
| 142 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0233", "section": "E.3 PROOF OF THEOREM 1", "page_start": 23, "page_end": 23, "type": "Text", "text": "where the last equality uses (1-\\operatorname{Attn}_k^{(T_f^*+1)})^2=\\mathcal{O}(\\epsilon^2\\delta^2) and L^2\\Delta^2=\\mathcal{O}(1/(\\Delta^2\\delta^2))\\cdot\\Delta^2=0 \\mathcal{O}(1/\\delta^2) when L \\leq \\Theta(1/(\\Delta\\delta)) , so the \\delta^2 cancels, leaving \\mathcal{O}(\\epsilon^2) .", "source": "marker_v2", "marker_block_id": "/page/22/Text/22"}
|
| 143 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0234", "section": "E.3 PROOF OF THEOREM 1", "page_start": 23, "page_end": 23, "type": "Text", "text": "This establishes the desired rate and completes the proof of Theorem 1.", "source": "marker_v2", "marker_block_id": "/page/22/Text/23"}
|
| 144 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0235", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "Lemma 9. For any t \\in \\{T_f^* + 1, \\dots, T_s^*\\} and any fixed k \\in [K] , we have:", "source": "marker_v2", "marker_block_id": "/page/23/Text/3"}
|
| 145 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0236", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "• g_k^{(t)} = \\Theta\\left(\\frac{\\delta^2 L^2 \\Delta^2 \\epsilon}{K}\\right) ,", "source": "marker_v2", "marker_block_id": "/page/23/Equation/4"}
|
| 146 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0237", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "• |g_{k,n}^{(t)}| = \\mathcal{O}\\left(\\frac{\\delta^2 L^2 \\Delta^2 \\epsilon}{K^2}\\right) for all n \\neq k .", "source": "marker_v2", "marker_block_id": "/page/23/Equation/5"}
|
| 147 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0238", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "Proof. Recall from the gradient expression:", "source": "marker_v2", "marker_block_id": "/page/23/Text/6"}
|
| 148 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0239", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "g_k^{(t)} = \\mathbb{E}\\left[\\mathbb{1}\\left\\{x_{\\text{query}} = v_k\\right\\} \\operatorname{Attn}_k^{(t)} (1 - \\operatorname{Attn}_k^{(t)})^2 \\Theta(L^2 \\Delta^2)\\right] = p_k \\cdot \\mathbb{E}\\left[\\operatorname{Attn}_k^{(t)} (1 - \\operatorname{Attn}_k^{(t)})^2 \\mid x_{\\text{query}} = v_k\\right] \\cdot \\Theta(L^2 \\Delta^2),", "source": "marker_v2", "marker_block_id": "/page/23/Equation/7"}
|
| 149 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0240", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "where p_k = \\Theta(1/K) .", "source": "marker_v2", "marker_block_id": "/page/23/Text/8"}
|
| 150 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0241", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "By Lemma 8, in this phase \\mathrm{Attn}_k^{(t)} = \\Theta(1) and 1 - \\mathrm{Attn}_k^{(t)} = \\mathcal{O}(\\epsilon \\delta) . Therefore,", "source": "marker_v2", "marker_block_id": "/page/23/Text/9"}
|
| 151 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0242", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "g_k^{(t)} = \\Theta\\left(\\frac{1}{K} \\cdot 1 \\cdot (\\epsilon \\delta)^2 \\cdot L^2 \\Delta^2\\right) = \\Theta\\left(\\frac{\\delta^2 L^2 \\Delta^2 \\epsilon^2}{K}\\right).", "source": "marker_v2", "marker_block_id": "/page/23/Equation/10"}
|
| 152 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0243", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "For the cross-gradient terms (n \\neq k) , by the same argument as in Lemma 7, we have:", "source": "marker_v2", "marker_block_id": "/page/23/Text/11"}
|
| 153 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0244", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "|g_{k,n}^{(t)}| \\le p_k \\cdot \\mathbb{E}\\left[\\operatorname{Attn}_n^{(t)}(1 - \\operatorname{Attn}_k^{(t)})(1 - \\operatorname{Attn}_n^{(t)}) \\cdot \\Theta(L^2\\Delta^2)\\right].", "source": "marker_v2", "marker_block_id": "/page/23/Equation/12"}
|
| 154 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0245", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "In this phase, \\operatorname{Attn}_n^{(t)} = \\Theta(\\delta/K) , 1 - \\operatorname{Attn}_n^{(t)} = \\Theta(1) , and 1 - \\operatorname{Attn}_k^{(t)} = \\mathcal{O}(\\epsilon\\delta) . Therefore,", "source": "marker_v2", "marker_block_id": "/page/23/Text/13"}
|
| 155 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0246", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "|g_{k,n}^{(t)}| \\leq \\Theta\\left(\\frac{1}{K} \\cdot \\frac{\\delta}{K} \\cdot \\epsilon \\delta \\cdot 1 \\cdot L^2 \\Delta^2\\right) = \\mathcal{O}\\left(\\frac{\\delta^2 L^2 \\Delta^2 \\epsilon}{K^2}\\right).", "source": "marker_v2", "marker_block_id": "/page/23/Equation/14"}
|
| 156 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0247", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "This completes the proof of Lemma 9.", "source": "marker_v2", "marker_block_id": "/page/23/Text/15"}
|
| 157 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0248", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "Lemma 10. At the end of Phase II under the sharp L-regime (i.e., at t = T_s^* ), if x_{\\text{query}} = v_k , we have:", "source": "marker_v2", "marker_block_id": "/page/23/Text/16"}
|
| 158 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0249", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "• q_k^{(T_s^*)} = \\Theta\\left(\\frac{\\log(KL\\Delta)}{\\epsilon}\\right) ,", "source": "marker_v2", "marker_block_id": "/page/23/Equation/17"}
|
| 159 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0250", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "• \\operatorname{Attn}_k^{(T_s^*)} = \\Omega\\left(\\frac{1}{1+\\epsilon\\delta}\\right) ,", "source": "marker_v2", "marker_block_id": "/page/23/Equation/18"}
|
| 160 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0251", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "• 1 - \\operatorname{Attn}_{k}^{(T_{s}^{*})} = \\mathcal{O}(\\epsilon \\delta).", "source": "marker_v2", "marker_block_id": "/page/23/Equation/19"}
|
| 161 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0252", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "Proof. By Lemma 9, for t \\in \\{T_f^*+1,\\ldots,T_s^*\\} , we have g_k^{(t)} = \\Theta\\left(\\frac{\\delta^2 L^2 \\Delta^2 \\epsilon}{K}\\right) . Thus,", "source": "marker_v2", "marker_block_id": "/page/23/Text/20"}
|
| 162 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0253", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "q_k^{(T_s^*)} = q_k^{(T_f^*)} + \\eta \\cdot \\Theta\\left(\\frac{L^2 \\Delta^2 \\delta^2 \\epsilon}{K}\\right) \\cdot (T_s^* - T_f^*) = \\Theta(\\log(KL\\Delta \\epsilon^{-1})),", "source": "marker_v2", "marker_block_id": "/page/23/Equation/21"}
|
| 163 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0254", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "using the total number of updates and the scaling of T_s^* . (Here, T_s^* - T_f^* = \\Theta\\left(\\frac{K \\log(KL\\Delta\\epsilon^{-1})}{L^2\\Delta^2\\delta^2\\epsilon}\\right) .)", "source": "marker_v2", "marker_block_id": "/page/23/Text/22"}
|
| 164 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0255", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "Similarly, for the cross-terms, by Lemma 9, |g_{k,m}^{(t)}| = \\mathcal{O}\\left(\\frac{\\delta^2 L^2 \\Delta^2 \\epsilon}{K^2}\\right) for m \\neq k , and hence", "source": "marker_v2", "marker_block_id": "/page/23/Text/23"}
|
| 165 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0256", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "\\begin{split} q_{k,m}^{(T_s^*)} &\\leq |q_{k,m}^{(T_f^*)}| + \\eta \\cdot \\mathcal{O}\\left(\\frac{\\delta^2 L^2 \\Delta^2 \\epsilon}{K^2}\\right) \\cdot (T_s^* - T_f^*) \\\\ &= \\Theta\\left(\\frac{\\log(KL\\Delta \\epsilon^{-1})}{K}\\right). \\end{split}", "source": "marker_v2", "marker_block_id": "/page/23/Equation/24"}
|
| 166 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0257", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Text", "text": "Therefore,", "source": "marker_v2", "marker_block_id": "/page/23/Text/25"}
|
| 167 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0258", "section": "F.1 Proof of Proposition 4", "page_start": 24, "page_end": 24, "type": "Equation", "text": "q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)} = -\\Theta(\\log(KL\\Delta\\epsilon^{-1})),", "source": "marker_v2", "marker_block_id": "/page/23/Equation/26"}
|
| 168 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0259", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Text", "text": "and so", "source": "marker_v2", "marker_block_id": "/page/24/Text/1"}
|
| 169 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0260", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Equation", "text": "\\exp(q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)}) = \\mathcal{O}\\left(\\frac{\\epsilon}{K}\\right),\\,", "source": "marker_v2", "marker_block_id": "/page/24/Equation/2"}
|
| 170 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0261", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Text", "text": "where the scaling in the sharp regime produces the \\epsilon factor", "source": "marker_v2", "marker_block_id": "/page/24/Text/3"}
|
| 171 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0262", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Text", "text": "For the attention, using the property from Lemma 3,", "source": "marker_v2", "marker_block_id": "/page/24/Text/4"}
|
| 172 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0263", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Equation", "text": "\\operatorname{Attn}_k^{(T_s^*)} = \\frac{1}{\\sum_{m \\neq k} \\frac{|\\mathcal{V}_m|}{|\\mathcal{V}_k|} \\exp(q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)}) + 1}. By the previous bounds, and using |\\mathcal{V}_k| \\geq u_k N/K and \\frac{1}{u_k} - \\frac{1}{K} = \\Theta(\\delta) , we obtain:", "source": "marker_v2", "marker_block_id": "/page/24/Equation/5"}
|
| 173 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0264", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Equation", "text": "\\operatorname{Attn}_{k}^{(T_{s}^{*})} \\geq \\frac{1}{\\mathcal{O}(\\epsilon) \\cdot \\mathcal{O}(\\frac{1}{n_{k}} - \\frac{1}{K}) + 1} = \\Omega\\left(\\frac{1}{1 + \\epsilon\\delta}\\right).", "source": "marker_v2", "marker_block_id": "/page/24/Equation/7"}
|
| 174 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0265", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Text", "text": "Finally,", "source": "marker_v2", "marker_block_id": "/page/24/Text/8"}
|
| 175 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0266", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Equation", "text": "1 - \\operatorname{Attn}_{k}^{(T_{s}^{*})} \\leq \\frac{\\mathcal{O}(\\epsilon) \\cdot \\mathcal{O}(\\frac{1}{u_{k}} - \\frac{1}{K})}{\\mathcal{O}(\\epsilon) \\cdot \\mathcal{O}(\\frac{1}{u_{k}} - \\frac{1}{K}) + 1} = \\mathcal{O}(\\epsilon\\delta),", "source": "marker_v2", "marker_block_id": "/page/24/Equation/9"}
|
| 176 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0267", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Text", "text": "which follows because \\frac{1}{u_k} - \\frac{1}{K} = \\Theta(\\delta) .", "source": "marker_v2", "marker_block_id": "/page/24/Text/10"}
|
| 177 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0268", "section": "F.1 Proof of Proposition 4", "page_start": 25, "page_end": 25, "type": "Text", "text": "This completes the proof of Lemma 10 and Proposition 4.", "source": "marker_v2", "marker_block_id": "/page/24/Text/11"}
|
| 178 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0269", "section": "F.2 PROOF OF THEOREM 2", "page_start": 25, "page_end": 25, "type": "Text", "text": "As in the proof of Theorem 1, the prediction error \\mathcal{L}(P;Q) (from Eq. (5)) can be written as", "source": "marker_v2", "marker_block_id": "/page/24/Text/13"}
|
| 179 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0270", "section": "F.2 PROOF OF THEOREM 2", "page_start": 25, "page_end": 25, "type": "Equation", "text": "\\mathcal{L}(P;Q) = \\frac{1}{2} \\sum_{k=1}^{K} \\mathbb{E}\\left[\\mathbb{1}\\left\\{x_{\\text{query}} = v_k\\right\\} (1 - \\text{Attn}_k^{(t)})^2 \\mathcal{O}(L^2 \\Delta^2)\\right].", "source": "marker_v2", "marker_block_id": "/page/24/Equation/14"}
|
| 180 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0271", "section": "F.2 PROOF OF THEOREM 2", "page_start": 25, "page_end": 25, "type": "Text", "text": "Suppose x_{\\text{query}} = v_k at time t = T_s^* . By Lemma 10, we have 1 - \\text{Attn}_k^{(T_s^*)} = O(\\epsilon \\delta) . Therefore,", "source": "marker_v2", "marker_block_id": "/page/24/Text/15"}
|
| 181 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0272", "section": "F.2 PROOF OF THEOREM 2", "page_start": 25, "page_end": 25, "type": "Equation", "text": "\\mathcal{L}^{(T_s^*)}(P;Q) = \\frac{1}{2} \\sum_{k=1}^K \\mathbb{E} \\left[ \\mathbb{1} \\{ x_{\\text{query}} = v_k \\} (1 - \\text{Attn}_k^{(T_s^*)})^2 \\mathcal{O}(L^2 \\Delta^2) \\right] = \\mathbb{E} \\left[ (1 - \\text{Attn}_k^{(T_s^*)})^2 \\mathcal{O}(L^2 \\Delta^2) \\right] = \\mathcal{O}(\\epsilon^2 \\delta^2).", "source": "marker_v2", "marker_block_id": "/page/24/Equation/16"}
|
| 182 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0273", "section": "F.2 PROOF OF THEOREM 2", "page_start": 25, "page_end": 25, "type": "Text", "text": "Under the scaling regime for sharp L, either \\delta = o(1) or \\epsilon = o(1) (since the in-context learning regime assumes both go to zero), and hence \\mathcal{L}^{(T_s^*)}(P;Q) = \\mathcal{O}(\\epsilon^2) as required.", "source": "marker_v2", "marker_block_id": "/page/24/Text/17"}
|
| 183 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0274", "section": "F.2 PROOF OF THEOREM 2", "page_start": 25, "page_end": 25, "type": "Text", "text": "This completes the proof of Theorem 2.", "source": "marker_v2", "marker_block_id": "/page/24/Text/18"}
|
| 184 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0275", "section": "PROOF OF PROPOSITION 1", "page_start": 25, "page_end": 25, "type": "Text", "text": "The result that 1 - \\operatorname{Attn}_k^{(t)} = \\mathcal{O}(\\epsilon) holds under both the flat L regime and the sharp L regime, as established in Lemma 8 and Lemma 10.", "source": "marker_v2", "marker_block_id": "/page/24/Text/20"}
|
iclr26/2g8vgmyXgQ/appendix_text_v3.txt
ADDED
|
@@ -0,0 +1,551 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
[p. 15 | section: A THE USE OF LLMS FOR POLISHING WRITING | type: Text]
|
| 2 |
+
We used a large language model (LLM) tool (e.g., ChatGPT) solely to polish and improve the readability of certain sections of this manuscript—specifically, the introduction, abstract, and several explanatory paragraphs. All research ideas, theoretical derivations, experimental designs, analyses, and conclusions are original to the authors. The LLM was not used to generate technical content, proofs, or results. We reviewed and edited all text produced with LLM assistance to ensure accuracy and consistency with our intended meaning.
|
| 3 |
+
|
| 4 |
+
[p. 15 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: Text]
|
| 5 |
+
Building on the prediction loss and attention dynamics shown in Figure 1, we provide a more detailed analysis of the 4\times 4 attention maps in this appendix. Figure 2 and Figure 3 show the attention patterns for the flat (L=0.1) and sharp (L=1) loss landscapes, respectively, under the experimental conditions of Section 6.
|
| 6 |
+
|
| 7 |
+
[p. 15 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: FigureGroup]
|
| 8 |
+
Figure 2: Dynamics of attention maps under flat L=0.1
|
| 9 |
+
|
| 10 |
+
[p. 15 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: FigureGroup]
|
| 11 |
+
Figure 3: Dynamics of attention maps under sharp L=1
|
| 12 |
+
|
| 13 |
+
[p. 15 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: Text]
|
| 14 |
+
In the attention maps, each grid position (i,j) corresponds to the attention score Attn_{i,j} , where i,j \in \{1,2,3,4\} are the indices of key and query, respectively. An important property is that the sum of attention scores for each column equals one (\sum_i Attn_{i,j} = 1) , given the same query v_j . The
|
| 15 |
+
|
| 16 |
+
[p. 16 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: Text]
|
| 17 |
+
attention maps show a clear trend: the diagonal entries (i,i) become progressively darker over t, indicating that the corresponding self-attention scores \mathrm{Attn}_i increase for all i \in \{1,2,3,4\} . We observe these scores approaching 1 before t=300 for the flat landscape L=0.1 and before t=200 for the sharp landscape L=1. In contrast, the off-diagonal entries (i,j), where i \neq j , become lighter, with \mathrm{Attn}_{i,j} converging toward zero. This behavior supports the theoretical findings presented in Proposition 2 and Proposition 3 and is directly reflected in the attention score dynamics plotted in Figure 1(c) and Figure 1(d).
|
| 18 |
+
|
| 19 |
+
[p. 16 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: ListGroup]
|
| 20 |
+
(a) Prediction loss for flat L-set under polynomial functions. (b) Prediction loss for sharp L-set under polynomial functions.
|
| 21 |
+
|
| 22 |
+
[p. 16 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: Caption]
|
| 23 |
+
Figure 4: Training dynamics of prediction losses for two sets of L: flat ( \{0.1, 0.2, 0.4\} ) and sharp ( \{1.0, 1.5, 2.0\} ) under polynomial functions.
|
| 24 |
+
|
| 25 |
+
[p. 16 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: Text]
|
| 26 |
+
To further validate the generality of our theoretical results, we conducted an additional experiment on a different class of nonlinear functions: random second-degree polynomials of the form f(x) = x^{\top}Ax + b^{\top}x , where the matrix A and vector b were randomly generated for each task instance. The elements of A and b satisfy A_{ij}, b_i \sim \mathcal{N}(0, (\frac{L}{d})^2) . For this experiment, we relaxed the finite feature set assumption by sampling input features from a continuous Gaussian distribution. In other words, there can be infinitely many feature vectors. For the other parameters, we set d=30, N=150, M=500. The prediction loss, averaged over 30 independent runs, is shown below for both the flat L-regime and the sharp L-regime. The results strongly corroborate our main findings: The flat regime has two training phases, while the sharp regime has three phases. Within both regimes, a larger Lipschitz constant L consistently results in faster convergence of the prediction loss. This provides further evidence that the identified training dynamics and the role of the Lipschitz constant hold for a broader class of nonlinear functions beyond the trigonometric family, and also hold for more general feature set and token sampling process.
|
| 27 |
+
|
| 28 |
+
[p. 16 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: ListGroup]
|
| 29 |
+
(a) Prediction loss for flat L-set under two-layer transformer. (b) Prediction loss for sharp L-set under two-layer transformer.
|
| 30 |
+
|
| 31 |
+
[p. 16 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: Caption]
|
| 32 |
+
Figure 5: Training dynamics of prediction losses for two sets of L: flat ( \{0.1, 0.2, 0.4\} ) and sharp ( \{1.0, 1.5, 2.0\} ) under two-layer transformer.
|
| 33 |
+
|
| 34 |
+
[p. 16 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: Text]
|
| 35 |
+
In addition to the single-layer setting analyzed in the main text, we further evaluate whether the curvature-dependent convergence behavior persists in deeper Transformer architectures such as two-layer and four-layer models. To this end, we present experiments using more realistic architectures that contain two or four stacked self-attention layers followed by two or four FFN blocks, under the same
|
| 36 |
+
|
| 37 |
+
[p. 17 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: ListGroup]
|
| 38 |
+
(a) Prediction loss for flat L-set under four-layer transformer. (b) Prediction loss for sharp L-set under four-layer transformer.
|
| 39 |
+
|
| 40 |
+
[p. 17 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: Caption]
|
| 41 |
+
Figure 6: Training dynamics of prediction losses for two sets of L: flat ( \{0.1, 0.2, 0.4\} ) and sharp ( \{1.0, 1.5, 2.0\} ) under four-layer transformer.
|
| 42 |
+
|
| 43 |
+
[p. 17 | section: B ADDITIONAL EXPERIMENTAL RESULTS | type: Text]
|
| 44 |
+
data and task setup as in Figure 4. As shown in Figure 5 and Figure 6, the deeper Transformers exhibit the same qualitative learning dynamics predicted by our theory, including a clear phase transition between the flat and sharp L-regimes and consistent phase-wise convergence behavior. These results indicate that the core mechanisms identified in our analysis, which were derived for a single-layer model for analytical tractability, naturally extend to multi-layer Transformer architectures.
|
| 45 |
+
|
| 46 |
+
[p. 17 | section: C PROOF OF LEMMA 1 | type: Text]
|
| 47 |
+
Recall the definition of the prediction error \mathcal{L}(P;Q) in Eq. (5):
|
| 48 |
+
|
| 49 |
+
[p. 17 | section: C PROOF OF LEMMA 1 | type: Equation]
|
| 50 |
+
\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} (\hat{y}_{\text{query}} - f(v_k))^2 \right] = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} f(v_n) - f(v_k) \right)^2 \right] = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} (f(v_n) - f(v_k)) \right)^2 \right] = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( \sum_{n \neq k} \operatorname{Attn}_n^{(t)} (f(v_n) - f(v_k)) \right)^2 \right]
|
| 51 |
+
|
| 52 |
+
[p. 17 | section: C PROOF OF LEMMA 1 | type: Text]
|
| 53 |
+
where we apply \sum_{n\in[K]}\operatorname{Attn}_n^{(t)}=1 to rewrite f(v_k) as \sum_{n\in[K]}\operatorname{Attn}_n^{(t)}f(v_k) in the third equality.
|
| 54 |
+
|
| 55 |
+
[p. 17 | section: C PROOF OF LEMMA 1 | type: Text]
|
| 56 |
+
Next, under the non-degenerate L-Lipschitz condition of the function class (see Eq. (2)), we have \sum_{n\neq k} |f(v_n) - f(v_k)| = \mathcal{O}(L\Delta) . Therefore, the sum can be bounded (order-wise) as
|
| 57 |
+
|
| 58 |
+
[p. 17 | section: C PROOF OF LEMMA 1 | type: Equation]
|
| 59 |
+
\left| \sum_{n \neq k} \operatorname{Attn}_{n}^{(t)} (f(v_{n}) - f(v_{k})) \right| = (1 - \operatorname{Attn}_{k}^{(t)}) \cdot \mathcal{O}(L\Delta)
|
| 60 |
+
|
| 61 |
+
[p. 17 | section: C PROOF OF LEMMA 1 | type: Text]
|
| 62 |
+
and thus
|
| 63 |
+
|
| 64 |
+
[p. 17 | section: C PROOF OF LEMMA 1 | type: Equation]
|
| 65 |
+
\left(\sum_{n\neq k}\operatorname{Attn}_n^{(t)}(f(v_n)-f(v_k))\right)^2 = (1-\operatorname{Attn}_k^{(t)})^2 \cdot \mathcal{O}(L^2\Delta^2).
|
| 66 |
+
|
| 67 |
+
[p. 17 | section: C PROOF OF LEMMA 1 | type: Text]
|
| 68 |
+
Putting these together, we obtain:
|
| 69 |
+
|
| 70 |
+
[p. 17 | section: C PROOF OF LEMMA 1 | type: Equation]
|
| 71 |
+
\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E}\left[\mathbb{1}\{x_{\text{query}} = v_k\}(1 - \operatorname{Attn}_k^{(t)})^2 \cdot \mathcal{O}(L^2 \Delta^2)\right].
|
| 72 |
+
|
| 73 |
+
[p. 18 | section: C PROOF OF LEMMA 1 | type: Text]
|
| 74 |
+
This completes the proof of Lemma 1.
|
| 75 |
+
|
| 76 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Text]
|
| 77 |
+
To derive q_k , we first compute the gradient of prediction loss with respect to Q^{(t)} as follows:
|
| 78 |
+
|
| 79 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Equation]
|
| 80 |
+
\nabla_{Q^{(t)}} \mathcal{L} = \mathbb{E} \Big[ (\hat{y}_{\text{query}} - f(v_k))^\top \frac{\partial \hat{y}_{\text{query}}}{\partial Q^{(t)}} \Big] = \mathbb{E} \Big[ (\hat{y}_{\text{query}} - f(v_k))^\top \sum_{i \in [N]} \frac{\partial \text{attn}_i}{\partial Q^{(t)}} y_i \Big].
|
| 81 |
+
|
| 82 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Text]
|
| 83 |
+
We then compute the gradient of \operatorname{attn}_i^{(t)} with respect to Q^{(t)}\colon
|
| 84 |
+
|
| 85 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Equation]
|
| 86 |
+
\begin{split} \frac{\partial \text{attn}_{i}^{(t)}}{\partial Q^{(t)}} &= \frac{e^{\bar{X}_{i}^{\top}Q^{(t)}x_{\text{query}}} \cdot \bar{X}_{i}^{\top}x_{\text{query}}^{\top}(\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}})^{2}}{(\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}})^{2}} \\ &- \frac{\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}} \cdot \bar{X}_{j}^{\top}x_{\text{query}}^{\top} \cdot e^{\bar{X}_{i}^{\top}Q^{(t)}x_{\text{query}}}}{(\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}})^{2}} \\ &= \text{attn}_{i}^{(t)} \cdot \bar{X}_{i}^{\top}x_{\text{query}} - \text{attn}_{i}^{(t)} \sum_{j \in [N]} \text{attn}_{j}^{(t)} \cdot \bar{X}_{j}^{\top}x_{\text{query}} \\ &= \text{attn}_{i}^{(t)} \sum_{j \in [N]} \text{attn}_{j}^{(t)}(\bar{X}_{i} - \bar{X}_{j})x_{\text{query}}^{\top}. \end{split}
|
| 87 |
+
|
| 88 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Text]
|
| 89 |
+
Substituting into the above expression gives:
|
| 90 |
+
|
| 91 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Equation]
|
| 92 |
+
\nabla_{Q^{(t)}} \mathcal{L} = \mathbb{E}\Big[ (\hat{y}_{\text{query}}^{(t)} - f(v_k)) \sum_{i,j \in [N]} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} (\bar{X}_i - \bar{X}_j) x_{\text{query}}^\top y_i \Big].
|
| 93 |
+
|
| 94 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Text]
|
| 95 |
+
For any feature vectors v_k and v_{k'} , we calculate
|
| 96 |
+
|
| 97 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Equation]
|
| 98 |
+
\begin{split} v_{k'}^\top \nabla_{Q^{(t)}} \mathcal{L} \cdot v_k = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \sum_{i,j \in [N]} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} y_i v_{k'}^\top (\bar{X}_i - \bar{X}_j) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \sum_{m,n \in [K]} \sum_{i \in \mathcal{V}_m} \sum_{j \in \mathcal{V}_n} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} y_i v_{k'}^\top (v_m - v_n) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \sum_{n \in [K]} \sum_{i \in \mathcal{V}_{k'}} \sum_{j \in \mathcal{V}_n} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} y_i v_{k'}^\top (v_{k'} - v_n) \Big] \\ + & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} f(v_{k'}) \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} \big\} \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} f(v_{k'}) \sum_{n \in [K]} \operatorname{Attn}_m^{(t)} f(v_m) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} f(v_m) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} \big( f(v_{k'}) - f(v_m) \big) \Big]. \end{split}
|
| 99 |
+
|
| 100 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Equation]
|
| 101 |
+
Since \hat{y}_{\text{query}} = \sum_{i \in [N]} \operatorname{attn}_i y_i = \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} f(v_m) , we obtain v_{k'}^{\top} \nabla_{Q^{(t)}} \mathcal{L} v_k = -\mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \operatorname{Attn}_{k'}^{(t)} \sum_{n \in [K]} \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} \operatorname{Attn}_n^{(t)} (f(v_k) - f(v_n)) (f(v_{k'}) - f(v_m)) \Big] \\ = -\mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \operatorname{Attn}_{k'}^{(t)} (f(v_k) - \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} f(v_n)) (f(v_{k'}) - \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} f(v_m)) \Big].
|
| 102 |
+
|
| 103 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Text]
|
| 104 |
+
We then derive Eq. (10) by letting v_k = v_{k'} using this expression:
|
| 105 |
+
|
| 106 |
+
[p. 18 | section: D Proof of Lemma 2 | type: Equation]
|
| 107 |
+
g_k^{(t)} = -v_k^{\top} \nabla_{Q^{(t)}} \mathcal{L} \cdot v_k
|
| 108 |
+
|
| 109 |
+
[p. 19 | section: D Proof of Lemma 2 | type: Equation]
|
| 110 |
+
\begin{split} &= \mathbb{E}\left[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_k^{(t)} \left(f(v_k) - \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} f(v_n)\right)^2\right] \\ &= \mathbb{E}\left[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_k^{(t)} \left(\sum_{n \in [K]} \operatorname{Attn}_n^{(t)} (f(v_k) - f(v_n))\right)^2\right] \\ &= \mathbb{E}\left[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right], \end{split}
|
| 111 |
+
|
| 112 |
+
[p. 19 | section: D Proof of Lemma 2 | type: Text]
|
| 113 |
+
where the last equality follows from the non-degenerate L-Lipschitz condition in Eq. (2).
|
| 114 |
+
|
| 115 |
+
[p. 19 | section: D Proof of Lemma 2 | type: Text]
|
| 116 |
+
For any k \neq n , we calculate
|
| 117 |
+
|
| 118 |
+
[p. 19 | section: D Proof of Lemma 2 | type: Equation]
|
| 119 |
+
\begin{split} |g_{k,k'}^{(t)}| &= \mathbb{E}\Big[\mathbbm{1}\{x_{\text{query}} = v_k\} \text{Attn}_{k'}^{(t)} | f(v_k) - \sum_{j \in [K]} \text{Attn}_{j}^{(t)} f(v_j) | \cdot | f(v_{k'}) - \sum_{m \in [K]} \text{Attn}_{m}^{(t)} f(v_m) | \Big] \\ &= p_k \cdot \mathbb{E}\Big[\text{Attn}_{k'}^{(t)} \Big| \sum_{j \in [K]} (\text{Attn}_{j}^{(t)} f(v_k) - \text{Attn}_{j}^{(t)} f(v_j)) \Big| \cdot \Big| \sum_{m \in [K]} (\text{Attn}_{m}^{(t)} f(v_{k'}) - \text{Attn}_{m}^{(t)} f(v_m)) \Big| \Big] \\ &= p_k \cdot \mathbb{E}\Big[\text{Attn}_{k'}^{(t)} \cdot \sum_{j \in [K]} \text{Attn}_{j}^{(t)} | f(v_k) - f(v_j) | \cdot \sum_{m \in [K]} \text{Attn}_{m}^{(t)} | f(v_{k'}) - f(v_m) | \Big] \\ &= p_k \cdot \mathbb{E}\left[\text{Attn}_{k'}^{(t)} \cdot (1 - \text{Attn}_{k}^{(t)}) \cdot (1 - \text{Attn}_{k'}^{(t)}) \cdot \Theta(L^2\Delta^2) \right]. \end{split}
|
| 120 |
+
|
| 121 |
+
[p. 19 | section: D Proof of Lemma 2 | type: Text]
|
| 122 |
+
This completes the proof of Lemma 2.
|
| 123 |
+
|
| 124 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 125 |
+
Lemma 3. For any t \in \{1, ..., T_f^1\} , if x_{\text{query}} = v_k , we have:
|
| 126 |
+
|
| 127 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: ListGroup]
|
| 128 |
+
Attn<sub>k</sub><sup>(t)</sup> = \Omega\left(\frac{1}{K}\right) , 1 \operatorname{Attn}_{k}^{(t)} = \Theta(1) , \operatorname{Attn}_{n}^{(t)} = \Theta\left(\frac{1 \operatorname{Attn}_{k}^{(t)}}{K}\right) = \Theta\left(\frac{1}{K}\right) for all n \neq k .
|
| 129 |
+
|
| 130 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 131 |
+
Proof. Fix any t \in \{1, \dots, T_f^1\} . By definition,
|
| 132 |
+
|
| 133 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 134 |
+
\begin{aligned} \text{Attn}_{k}^{(t)} &= \frac{|\mathcal{V}_{k}| e^{v_{k}^{\top} Q^{(t)} v_{k}}}{\sum_{j \in [N]} e^{E_{j}^{x \top} Q^{(t)} v_{k}}} = \frac{|\mathcal{V}_{k}| e^{q_{k}^{(t)}}}{\sum_{m \neq k} |\mathcal{V}_{m}| e^{q_{k,m}^{(t)}} + |\mathcal{V}_{k}| e^{q_{k}^{(t)}}} \\ &= \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_{m}|}{|\mathcal{V}_{k}|} \exp(q_{k,m}^{(t)} - q_{k}^{(t)}) + 1}. \end{aligned}
|
| 135 |
+
|
| 136 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 137 |
+
By the symmetry property in the initial phase, q_{k,m}^{(t)} = \Theta\left(\frac{q_k^{(t)}}{K}\right) . Thus,
|
| 138 |
+
|
| 139 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 140 |
+
e^{-(\log K + \Theta(\frac{\log K}{K}))} \leq \exp(q_{k,m}^{(t)} - q_k^{(t)}) \leq e^{\Theta(\frac{\log K}{K})}.
|
| 141 |
+
|
| 142 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 143 |
+
Define u_k = K(p_k - \delta) and U_k = K(p_k + \delta) . Then, from the concentration property (see Eq. (7)), |\mathcal{V}_k| \in [\frac{u_k}{K}N, \frac{U_k}{K}N] for constants u_k, U_k = \Theta(1) . Therefore,
|
| 144 |
+
|
| 145 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 146 |
+
\operatorname{Attn}_k^{(t)} \geq \frac{1}{e^{\Theta(\frac{\log K}{K})}(\frac{N}{|\mathcal{V}_k|}-1)+1} \geq \frac{1}{e^{\Theta(\frac{\log K}{K})}(\frac{K}{u_k}-1)+1} = \Omega\left(\frac{1}{K}\right).
|
| 147 |
+
|
| 148 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 149 |
+
For the upper bound,
|
| 150 |
+
|
| 151 |
+
[p. 19 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 152 |
+
Attn_k^{(t)} \le \frac{1}{e^{-(\log K + \Theta(\frac{\log K}{K}))}(\frac{N}{|\mathcal{V}_k|} - 1) + 1} \le \frac{1}{e^{-1}(\frac{1}{U_k} - \frac{1}{K}) + 1},
|
| 153 |
+
|
| 154 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 155 |
+
which follows because U_k = \Theta(1) , and hence
|
| 156 |
+
|
| 157 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 158 |
+
1 - \operatorname{Attn}_{k}^{(t)} \ge \frac{\frac{1}{U_{k}} - \frac{1}{K}}{(\frac{1}{U_{k}} - \frac{1}{K}) + e} = \Theta(1).
|
| 159 |
+
|
| 160 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 161 |
+
The reverse bound is similar, showing 1 - \text{Attn}_k^{(t)} = \Theta(1) .
|
| 162 |
+
|
| 163 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 164 |
+
For n \neq k , by similar calculation,
|
| 165 |
+
|
| 166 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 167 |
+
Attn_n^{(t)} = \frac{|\mathcal{V}_n| \exp(q_{k,n}^{(t)})}{\sum_{m \neq k} |\mathcal{V}_m| \exp(q_{k,m}^{(t)}) + |\mathcal{V}_k| \exp(q_k^{(t)})},
|
| 168 |
+
|
| 169 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 170 |
+
and since |\mathcal{V}_m|/|\mathcal{V}_n| = \Theta(1) and \exp(q_{k,m}^{(t)} - q_{k,n}^{(t)}) = e^{O(\frac{\log K}{K})} ,
|
| 171 |
+
|
| 172 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 173 |
+
\frac{\operatorname{Attn}_{n}^{(t)}}{1 - \operatorname{Attn}_{k}^{(t)}} = \frac{|\mathcal{V}_{n}| \exp(q_{k,n}^{(t)})}{\sum_{m \neq k} |\mathcal{V}_{m}| \exp(q_{k,m}^{(t)})} = \Theta\left(\frac{1}{K}\right).
|
| 174 |
+
|
| 175 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 176 |
+
Thus, \operatorname{Attn}_n^{(t)} = (1 - \operatorname{Attn}_k^{(t)})\Theta\left(\frac{1}{K}\right) = \Theta\left(\frac{1}{K}\right) , since 1 - \operatorname{Attn}_k^{(t)} = \Theta(1) .
|
| 177 |
+
|
| 178 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 179 |
+
Lemma 4. For any t \in \{1, ..., T_f^1\} , given x_{query} = v_k , we have:
|
| 180 |
+
|
| 181 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 182 |
+
• g_k^{(t)} = \Theta\left(\frac{L^2\Delta^2}{K}\right) ,
|
| 183 |
+
|
| 184 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 185 |
+
• |g_{k,n}^{(t)}| = O\left(\frac{L^2\Delta^2}{K^2}\right) for any n \neq k .
|
| 186 |
+
|
| 187 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 188 |
+
Proof. By the gradient expression from Lemma 2, we have
|
| 189 |
+
|
| 190 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 191 |
+
g_k^{(t)} = \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right] = p_k \cdot \mathbb{E}\left[\operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \mid x_{\text{query}} = v_k\right] \cdot \Theta(L^2 \Delta^2).
|
| 192 |
+
|
| 193 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 194 |
+
By Lemma 3, in Phase I, we have
|
| 195 |
+
|
| 196 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 197 |
+
p_k = \Theta(1/K) , \operatorname{Attn}_k^{(t)} = \Theta(1) , and 1 - \operatorname{Attn}_k^{(t)} = \Theta(1) .
|
| 198 |
+
|
| 199 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 200 |
+
Therefore,
|
| 201 |
+
|
| 202 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 203 |
+
g_k^{(t)} = \Theta\left(\frac{1}{K} \cdot 1 \cdot (1)^2 \cdot L^2 \Delta^2\right) = \Theta\left(\frac{L^2 \Delta^2}{K}\right).
|
| 204 |
+
|
| 205 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 206 |
+
For the cross-gradient term, for n \neq k ,
|
| 207 |
+
|
| 208 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 209 |
+
\begin{split} |g_{k,n}^{(t)}| &= \mathbb{E}\Big[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_n^{(t)} |f(v_k) - \sum_j \operatorname{Attn}_j^{(t)} f(v_j)| \, |f(v_n) - \sum_m \operatorname{Attn}_m^{(t)} f(v_m)| \Big] \\ &= p_k \cdot \mathbb{E}\Big[\operatorname{Attn}_n^{(t)} \Big| \sum_j \operatorname{Attn}_j^{(t)} (f(v_k) - f(v_j)) \Big| \, \Big| \sum_m \operatorname{Attn}_m^{(t)} (f(v_n) - f(v_m)) \Big| \, | \, x_{\mathrm{query}} = v_k \Big] \\ &\leq p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)} \cdot \sum_j \operatorname{Attn}_j^{(t)} |f(v_k) - f(v_j)| \cdot \sum_m \operatorname{Attn}_m^{(t)} |f(v_n) - f(v_m)| \right] \\ &= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)} (1 - \operatorname{Attn}_k^{(t)}) (1 - \operatorname{Attn}_n^{(t)}) \mathcal{O}(L^2 \Delta^2) \right]. \end{split}
|
| 210 |
+
|
| 211 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 212 |
+
By Lemma 3, \operatorname{Attn}_n^{(t)} = \Theta(1/K) and 1 - \operatorname{Attn}_k^{(t)}, 1 - \operatorname{Attn}_n^{(t)} = \Theta(1) , so
|
| 213 |
+
|
| 214 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 215 |
+
|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{1}{K} \cdot \frac{1}{K} \cdot 1 \cdot 1 \cdot L^2 \Delta^2\right) = \mathcal{O}\left(\frac{L^2 \Delta^2}{K^2}\right)
|
| 216 |
+
|
| 217 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 218 |
+
This completes the proof of Lemma 4.
|
| 219 |
+
|
| 220 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 221 |
+
Lemma 5. Given \delta = o(1) , at the end of Phase I (i.e., at t = T_f^1 + 1 ), we have:
|
| 222 |
+
|
| 223 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 224 |
+
• q_h^{(T_f^1+1)} = \Theta(\log K) ,
|
| 225 |
+
|
| 226 |
+
[p. 20 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 227 |
+
• \operatorname{Attn}_{k}^{(T_f^1+1)} = \Omega\left(\frac{1}{1+\delta}\right) if x_{\text{query}} = v_k.
|
| 228 |
+
|
| 229 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 230 |
+
Proof. By Lemma 4, we have g_k^{(t)} = \Theta\left(\frac{L^2\Delta^2}{K}\right) for all t in Phase I. Thus,
|
| 231 |
+
|
| 232 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 233 |
+
\begin{aligned} q_k^{(T_f^1+1)} &= q_k^{(0)} + \eta \sum_{t=1}^{T_f^1} g_k^{(t)} \\ &= q_k^{(0)} + \eta \cdot T_f^1 \cdot \Theta\left(\frac{L^2 \Delta^2}{K}\right) \\ &= \Theta(\log K), \end{aligned}
|
| 234 |
+
|
| 235 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 236 |
+
where we apply the definition of T_f^1 from the main text.
|
| 237 |
+
|
| 238 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 239 |
+
For the off-diagonal terms, from Lemma 4, |g_{k,m}^{(t)}| = O\left(\frac{L^2\Delta^2}{K^2}\right) for any m \neq k . Hence,
|
| 240 |
+
|
| 241 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 242 |
+
\begin{split} q_{k,m}^{(T_f^1+1)} &\leq |q_{k,m}^{(0)}| + \eta \cdot T_f^1 \cdot \mathcal{O}\left(\frac{L^2 \Delta^2}{K^2}\right) \\ &= \mathcal{O}\left(\frac{\log K}{K}\right). \end{split}
|
| 243 |
+
|
| 244 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 245 |
+
Therefore, at the end of Phase I,
|
| 246 |
+
|
| 247 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 248 |
+
q_k^{(T_f^1+1)} - q_{k,m}^{(T_f^1+1)} = \Theta(\log K) - \mathcal{O}\left(\frac{\log K}{K}\right) = \Theta(\log K).
|
| 249 |
+
|
| 250 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 251 |
+
Now, the attention weight for k at time t is
|
| 252 |
+
|
| 253 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 254 |
+
Attn_k^{(t)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.
|
| 255 |
+
|
| 256 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 257 |
+
Using the above, for t = T_f^1 + 1 ,
|
| 258 |
+
|
| 259 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 260 |
+
\exp(q_{k,m}^{(t)} - q_k^{(t)}) \leq \exp\left(\mathcal{O}\left(\frac{\log K}{K}\right) - \log K\right) = \mathcal{O}\left(\frac{1}{K}\right).
|
| 261 |
+
|
| 262 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 263 |
+
By the concentration condition in Eq. (7), |\hat{\mathcal{V}}_k| \geq \frac{u_k}{K} N for some u_k = \Theta(1) , and N/|\mathcal{V}_k| = \Theta(1/\delta) (since \delta = o(1) is the imbalance parameter). Thus,
|
| 264 |
+
|
| 265 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Equation]
|
| 266 |
+
\operatorname{Attn}_{k}^{(t)} \ge \frac{1}{\mathcal{O}\left(\frac{1}{K}\right)\left(\frac{N}{|\mathcal{V}_{k}|} - 1\right) + 1} \ge \frac{1}{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \Omega\left(\frac{1}{1 + \delta}\right),
|
| 267 |
+
|
| 268 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 269 |
+
where the last equality follows because 1/u_k - 1/K = \Theta(\delta) from Eq. (7).
|
| 270 |
+
|
| 271 |
+
[p. 21 | section: E.1 Proof of Proposition 2 | type: Text]
|
| 272 |
+
This completes the proof of Lemma 5 and Proposition 2.
|
| 273 |
+
|
| 274 |
+
[p. 21 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 275 |
+
Lemma 6. For any t \in \{T_f^1 + 1, \dots, T_f^*\} , given \delta = o(1) , if x_{\text{query}} = v_k , we have:
|
| 276 |
+
|
| 277 |
+
[p. 21 | section: E.2 PROOF OF PROPOSITION 3 | type: ListGroup]
|
| 278 |
+
Attn _k^{(t)} = \Omega\left(\frac{1}{1+\delta}\right) , 1 \operatorname{Attn}_{k}^{(t)} = \mathcal{O}(\delta) , \operatorname{Attn}_n^{(t)} = \Theta\left(\frac{1 \operatorname{Attn}_k^{(t)}}{K}\right) = \Theta\left(\frac{\delta}{K}\right) for any n \neq k .
|
| 279 |
+
|
| 280 |
+
[p. 21 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 281 |
+
Proof. By Proposition 2 (see also Lemma 5), for any t \ge T_f^1 + 1 , we have \operatorname{Attn}_k^{(t)} = \Omega\left(\frac{1}{1+\delta}\right) .
|
| 282 |
+
|
| 283 |
+
[p. 21 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 284 |
+
We now show that 1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\delta) . Using the same attention formula as before,
|
| 285 |
+
|
| 286 |
+
[p. 21 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 287 |
+
Attn_k^{(t)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.
|
| 288 |
+
|
| 289 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 290 |
+
From previous bounds, \exp(q_{k,m}^{(t)}-q_k^{(t)})=O\left(\frac{1}{K}\right) , and |\mathcal{V}_k|\geq u_kN/K with 1/u_k-1/K=\Theta(\delta) . Therefore,
|
| 291 |
+
|
| 292 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 293 |
+
\operatorname{Attn}_{k}^{(t)} \geq \frac{1}{\mathcal{O}\left(\frac{1}{K}\right)\left(\frac{N}{|\mathcal{V}_{k}|} - 1\right) + 1} \geq \frac{1}{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \Omega\left(\frac{1}{1 + \delta}\right).
|
| 294 |
+
|
| 295 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 296 |
+
For the upper bound, we compute:
|
| 297 |
+
|
| 298 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 299 |
+
1 - \operatorname{Attn}_{k}^{(t)} \le 1 - \frac{1}{\mathcal{O}\left(\frac{1}{K}\right)\left(\frac{N}{|\mathcal{V}_{k}|} - 1\right) + 1} = \frac{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right)}{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \mathcal{O}(\delta),
|
| 300 |
+
|
| 301 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 302 |
+
where the last equality uses \frac{1}{u_k} - \frac{1}{K} = \Theta(\delta) from Eq. (7). Thus, 1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\delta) .
|
| 303 |
+
|
| 304 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 305 |
+
Finally, for any n \neq k , we can use the same method as in Lemma 3 to obtain:
|
| 306 |
+
|
| 307 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 308 |
+
\operatorname{Attn}_{n}^{(t)} = \mathcal{O}\left(\frac{1 - \operatorname{Attn}_{k}^{(t)}}{K}\right) = \mathcal{O}\left(\frac{\delta}{K}\right).
|
| 309 |
+
|
| 310 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 311 |
+
This completes the proof.
|
| 312 |
+
|
| 313 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 314 |
+
Lemma 7. For any t \in \{T_f^1 + 1, \dots, T_f^*\} and any fixed k \in [K] , we have:
|
| 315 |
+
|
| 316 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 317 |
+
• g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2}{K}\right) ,
|
| 318 |
+
|
| 319 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 320 |
+
• |g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2}{K^2}\right) for all n \neq k .
|
| 321 |
+
|
| 322 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 323 |
+
Proof. Recall from the gradient expression and Lemma 4:
|
| 324 |
+
|
| 325 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 326 |
+
\begin{split} g_k^{(t)} &= \mathbb{E}\left[\mathbb{1}\{x_{\text{query}} = v_k\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right] \\ &= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \mid x_{\text{query}} = v_k\right] \cdot \Theta(L^2 \Delta^2). \end{split}
|
| 327 |
+
|
| 328 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 329 |
+
By Lemma 5 and subsequent results for Phase II, we have p_k = \Theta(1/K) , \operatorname{Attn}_k^{(t)} = \Theta(1) , and 1 - \operatorname{Attn}_k^{(t)} = \Theta(\delta) . Therefore,
|
| 330 |
+
|
| 331 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 332 |
+
g_k^{(t)} = \Theta\left(\frac{1}{K} \cdot 1 \cdot \delta^2 \cdot L^2 \Delta^2\right) = \Theta\left(\frac{\delta^2 L^2 \Delta^2}{K}\right).
|
| 333 |
+
|
| 334 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 335 |
+
For the cross-gradient terms with n \neq k , using the same approach as in Lemma 4, we obtain
|
| 336 |
+
|
| 337 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 338 |
+
|g_{k,n}^{(t)}| \le p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)}(1 - \operatorname{Attn}_k^{(t)})(1 - \operatorname{Attn}_n^{(t)}) \cdot \mathcal{O}(L^2\Delta^2)\right].
|
| 339 |
+
|
| 340 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 341 |
+
In Phase II, by the previous lemma, we have \operatorname{Attn}_n^{(t)} = \Theta(\delta/K) , 1 - \operatorname{Attn}_n^{(t)} = \Theta(1) , and 1 - \operatorname{Attn}_k^{(t)} = \Theta(\delta) . Thus,
|
| 342 |
+
|
| 343 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 344 |
+
|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{1}{K} \cdot \frac{\delta}{K} \cdot \delta \cdot 1 \cdot L^2 \Delta^2\right) = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2}{K^2}\right).
|
| 345 |
+
|
| 346 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 347 |
+
This completes the proof of Lemma 7.
|
| 348 |
+
|
| 349 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 350 |
+
Lemma 8. At the end of Phase II under the flat L-regime (i.e., t = T_f^* + 1 ), if x_{query} = v_k , we have:
|
| 351 |
+
|
| 352 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 353 |
+
• q_k^{(T_f^*+1)} = \Theta\left(\frac{\log K}{\epsilon}\right) ,
|
| 354 |
+
|
| 355 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 356 |
+
• Attn k (T_f^*+1) = \Omega\left(\frac{1}{1+\epsilon\delta}\right) ,
|
| 357 |
+
|
| 358 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 359 |
+
• 1 - \operatorname{Attn}_{k}^{(T_f^* + 1)} = \mathcal{O}(\epsilon \delta).
|
| 360 |
+
|
| 361 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 362 |
+
Proof. By Lemma 7, we have g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2}{K}\right) in Phase II. Thus,
|
| 363 |
+
|
| 364 |
+
[p. 22 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 365 |
+
q_k^{(T_f^*+1)} = q_k^{(T_f^1)} + \eta \cdot \Theta\left(\frac{L^2 \Delta^2 \delta^2}{K}\right) \cdot (T_f^* - T_f^1)
|
| 366 |
+
|
| 367 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 368 |
+
1188 = \Theta(\log(K\epsilon^{-1})) 1190 = \Theta\left(\frac{\log K}{\epsilon}\right),
|
| 369 |
+
|
| 370 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 371 |
+
where the last step applies the scaling of T_f^* and the learning rate in the flat L-regime.
|
| 372 |
+
|
| 373 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 374 |
+
For the cross terms, by Lemma 7 again.
|
| 375 |
+
|
| 376 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 377 |
+
\begin{split} q_{k,m}^{(T_f^*+1)} &\leq |q_{k,m}^{(T_f^1)}| + \eta \cdot \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2}{K^2}\right) \cdot (T_f^* - T_f^1) \\ &= \Theta\left(\frac{\log(K\epsilon^{-1})}{K}\right). \end{split}
|
| 378 |
+
|
| 379 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 380 |
+
Therefore, at t = T_f^* + 1 , we have
|
| 381 |
+
|
| 382 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 383 |
+
q_{k,m}^{(T_f^*+1)} - q_k^{(T_f^*+1)} = \mathcal{O}\left(\frac{\log(K\epsilon^{-1})}{K}\right) - \Theta(\log(K\epsilon^{-1})) = -\Theta(\log(K\epsilon^{-1})),
|
| 384 |
+
|
| 385 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 386 |
+
and so
|
| 387 |
+
|
| 388 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 389 |
+
\exp(q_{k,m}^{(t)} - q_k^{(t)}) \leq \exp\left(-\Theta(\log K)\right) = \mathcal{O}\left(\frac{1}{K}\right).
|
| 390 |
+
|
| 391 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 392 |
+
The attention weight for k is then
|
| 393 |
+
|
| 394 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 395 |
+
\operatorname{Attn}_k^{(t)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}. Using the bounds above, and |\mathcal{V}_k| \geq u_k N/K , with \frac{1}{u_k} - \frac{1}{K} = \Theta(\delta) (see Eq. (7)), we obtain:
|
| 396 |
+
|
| 397 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 398 |
+
\operatorname{Attn}_{k}^{(T_{f}^{*}+1)} \geq \frac{1}{\mathcal{O}(\epsilon) \cdot \mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \Omega\left(\frac{1}{1 + \epsilon\delta}\right).
|
| 399 |
+
|
| 400 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 401 |
+
Similarly,
|
| 402 |
+
|
| 403 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Equation]
|
| 404 |
+
1 - \operatorname{Attn}_{k}^{(T_{f}^{*}+1)} \leq \frac{\mathcal{O}(\epsilon) \cdot \mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right)}{\mathcal{O}(\epsilon) \cdot \mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \mathcal{O}(\epsilon\delta).
|
| 405 |
+
|
| 406 |
+
[p. 23 | section: E.2 PROOF OF PROPOSITION 3 | type: Text]
|
| 407 |
+
This completes the proof of Lemma 8 and Proposition 3.
|
| 408 |
+
|
| 409 |
+
[p. 23 | section: E.3 PROOF OF THEOREM 1 | type: Text]
|
| 410 |
+
Recall from Lemma 2 and its proof that the prediction error \mathcal{L}(P;Q) defined in Eq. (5) can be expressed as
|
| 411 |
+
|
| 412 |
+
[p. 23 | section: E.3 PROOF OF THEOREM 1 | type: Equation]
|
| 413 |
+
\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} (1 - \text{Attn}_k^{(t)})^2 \mathcal{O}(L^2 \Delta^2)\right],
|
| 414 |
+
|
| 415 |
+
[p. 23 | section: E.3 PROOF OF THEOREM 1 | type: Text]
|
| 416 |
+
where we use \sum_{n \neq k} \operatorname{Attn}_n^{(t)} = 1 - \operatorname{Attn}_k^{(t)} and, by the function class assumption, |f(v_n) - f(v_k)| = 1 \Theta(L\Delta) .
|
| 417 |
+
|
| 418 |
+
[p. 23 | section: E.3 PROOF OF THEOREM 1 | type: Text]
|
| 419 |
+
At the end of Phase II (i.e., at t=T_f^*+1 ), suppose x_{\rm query}=v_k . By Lemma 8, we have 1 - \operatorname{Attn}_{L}^{(T_f^* + 1)} = O(\epsilon \delta) . Therefore,
|
| 420 |
+
|
| 421 |
+
[p. 23 | section: E.3 PROOF OF THEOREM 1 | type: Equation]
|
| 422 |
+
\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} (1 - \text{Attn}_k^{(T_f^* + 1)})^2 \mathcal{O}(L^2 \Delta^2) \right] = \mathbb{E} \left[ (1 - \text{Attn}_k^{(T_f^* + 1)})^2 \mathcal{O}(L^2 \Delta^2) \right] = \mathcal{O}(\epsilon^2),
|
| 423 |
+
|
| 424 |
+
[p. 23 | section: E.3 PROOF OF THEOREM 1 | type: Text]
|
| 425 |
+
where the last equality uses (1-\operatorname{Attn}_k^{(T_f^*+1)})^2=\mathcal{O}(\epsilon^2\delta^2) and L^2\Delta^2=\mathcal{O}(1/(\Delta^2\delta^2))\cdot\Delta^2=0 \mathcal{O}(1/\delta^2) when L \leq \Theta(1/(\Delta\delta)) , so the \delta^2 cancels, leaving \mathcal{O}(\epsilon^2) .
|
| 426 |
+
|
| 427 |
+
[p. 23 | section: E.3 PROOF OF THEOREM 1 | type: Text]
|
| 428 |
+
This establishes the desired rate and completes the proof of Theorem 1.
|
| 429 |
+
|
| 430 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 431 |
+
Lemma 9. For any t \in \{T_f^* + 1, \dots, T_s^*\} and any fixed k \in [K] , we have:
|
| 432 |
+
|
| 433 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 434 |
+
• g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K}\right) ,
|
| 435 |
+
|
| 436 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 437 |
+
• |g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right) for all n \neq k .
|
| 438 |
+
|
| 439 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 440 |
+
Proof. Recall from the gradient expression:
|
| 441 |
+
|
| 442 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 443 |
+
g_k^{(t)} = \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right] = p_k \cdot \mathbb{E}\left[\operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \mid x_{\text{query}} = v_k\right] \cdot \Theta(L^2 \Delta^2),
|
| 444 |
+
|
| 445 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 446 |
+
where p_k = \Theta(1/K) .
|
| 447 |
+
|
| 448 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 449 |
+
By Lemma 8, in this phase \mathrm{Attn}_k^{(t)} = \Theta(1) and 1 - \mathrm{Attn}_k^{(t)} = \mathcal{O}(\epsilon \delta) . Therefore,
|
| 450 |
+
|
| 451 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 452 |
+
g_k^{(t)} = \Theta\left(\frac{1}{K} \cdot 1 \cdot (\epsilon \delta)^2 \cdot L^2 \Delta^2\right) = \Theta\left(\frac{\delta^2 L^2 \Delta^2 \epsilon^2}{K}\right).
|
| 453 |
+
|
| 454 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 455 |
+
For the cross-gradient terms (n \neq k) , by the same argument as in Lemma 7, we have:
|
| 456 |
+
|
| 457 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 458 |
+
|g_{k,n}^{(t)}| \le p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)}(1 - \operatorname{Attn}_k^{(t)})(1 - \operatorname{Attn}_n^{(t)}) \cdot \Theta(L^2\Delta^2)\right].
|
| 459 |
+
|
| 460 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 461 |
+
In this phase, \operatorname{Attn}_n^{(t)} = \Theta(\delta/K) , 1 - \operatorname{Attn}_n^{(t)} = \Theta(1) , and 1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\epsilon\delta) . Therefore,
|
| 462 |
+
|
| 463 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 464 |
+
|g_{k,n}^{(t)}| \leq \Theta\left(\frac{1}{K} \cdot \frac{\delta}{K} \cdot \epsilon \delta \cdot 1 \cdot L^2 \Delta^2\right) = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right).
|
| 465 |
+
|
| 466 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 467 |
+
This completes the proof of Lemma 9.
|
| 468 |
+
|
| 469 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 470 |
+
Lemma 10. At the end of Phase II under the sharp L-regime (i.e., at t = T_s^* ), if x_{\text{query}} = v_k , we have:
|
| 471 |
+
|
| 472 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 473 |
+
• q_k^{(T_s^*)} = \Theta\left(\frac{\log(KL\Delta)}{\epsilon}\right) ,
|
| 474 |
+
|
| 475 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 476 |
+
• \operatorname{Attn}_k^{(T_s^*)} = \Omega\left(\frac{1}{1+\epsilon\delta}\right) ,
|
| 477 |
+
|
| 478 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 479 |
+
• 1 - \operatorname{Attn}_{k}^{(T_{s}^{*})} = \mathcal{O}(\epsilon \delta).
|
| 480 |
+
|
| 481 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 482 |
+
Proof. By Lemma 9, for t \in \{T_f^*+1,\ldots,T_s^*\} , we have g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K}\right) . Thus,
|
| 483 |
+
|
| 484 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 485 |
+
q_k^{(T_s^*)} = q_k^{(T_f^*)} + \eta \cdot \Theta\left(\frac{L^2 \Delta^2 \delta^2 \epsilon}{K}\right) \cdot (T_s^* - T_f^*) = \Theta(\log(KL\Delta \epsilon^{-1})),
|
| 486 |
+
|
| 487 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 488 |
+
using the total number of updates and the scaling of T_s^* . (Here, T_s^* - T_f^* = \Theta\left(\frac{K \log(KL\Delta\epsilon^{-1})}{L^2\Delta^2\delta^2\epsilon}\right) .)
|
| 489 |
+
|
| 490 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 491 |
+
Similarly, for the cross-terms, by Lemma 9, |g_{k,m}^{(t)}| = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right) for m \neq k , and hence
|
| 492 |
+
|
| 493 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 494 |
+
\begin{split} q_{k,m}^{(T_s^*)} &\leq |q_{k,m}^{(T_f^*)}| + \eta \cdot \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right) \cdot (T_s^* - T_f^*) \\ &= \Theta\left(\frac{\log(KL\Delta \epsilon^{-1})}{K}\right). \end{split}
|
| 495 |
+
|
| 496 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 497 |
+
Therefore,
|
| 498 |
+
|
| 499 |
+
[p. 24 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 500 |
+
q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)} = -\Theta(\log(KL\Delta\epsilon^{-1})),
|
| 501 |
+
|
| 502 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 503 |
+
and so
|
| 504 |
+
|
| 505 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 506 |
+
\exp(q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)}) = \mathcal{O}\left(\frac{\epsilon}{K}\right),\,
|
| 507 |
+
|
| 508 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 509 |
+
where the scaling in the sharp regime produces the \epsilon factor
|
| 510 |
+
|
| 511 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 512 |
+
For the attention, using the property from Lemma 3,
|
| 513 |
+
|
| 514 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 515 |
+
\operatorname{Attn}_k^{(T_s^*)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)}) + 1}. By the previous bounds, and using |\mathcal{V}_k| \geq u_k N/K and \frac{1}{u_k} - \frac{1}{K} = \Theta(\delta) , we obtain:
|
| 516 |
+
|
| 517 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 518 |
+
\operatorname{Attn}_{k}^{(T_{s}^{*})} \geq \frac{1}{\mathcal{O}(\epsilon) \cdot \mathcal{O}(\frac{1}{n_{k}} - \frac{1}{K}) + 1} = \Omega\left(\frac{1}{1 + \epsilon\delta}\right).
|
| 519 |
+
|
| 520 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 521 |
+
Finally,
|
| 522 |
+
|
| 523 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Equation]
|
| 524 |
+
1 - \operatorname{Attn}_{k}^{(T_{s}^{*})} \leq \frac{\mathcal{O}(\epsilon) \cdot \mathcal{O}(\frac{1}{u_{k}} - \frac{1}{K})}{\mathcal{O}(\epsilon) \cdot \mathcal{O}(\frac{1}{u_{k}} - \frac{1}{K}) + 1} = \mathcal{O}(\epsilon\delta),
|
| 525 |
+
|
| 526 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 527 |
+
which follows because \frac{1}{u_k} - \frac{1}{K} = \Theta(\delta) .
|
| 528 |
+
|
| 529 |
+
[p. 25 | section: F.1 Proof of Proposition 4 | type: Text]
|
| 530 |
+
This completes the proof of Lemma 10 and Proposition 4.
|
| 531 |
+
|
| 532 |
+
[p. 25 | section: F.2 PROOF OF THEOREM 2 | type: Text]
|
| 533 |
+
As in the proof of Theorem 1, the prediction error \mathcal{L}(P;Q) (from Eq. (5)) can be written as
|
| 534 |
+
|
| 535 |
+
[p. 25 | section: F.2 PROOF OF THEOREM 2 | type: Equation]
|
| 536 |
+
\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} (1 - \text{Attn}_k^{(t)})^2 \mathcal{O}(L^2 \Delta^2)\right].
|
| 537 |
+
|
| 538 |
+
[p. 25 | section: F.2 PROOF OF THEOREM 2 | type: Text]
|
| 539 |
+
Suppose x_{\text{query}} = v_k at time t = T_s^* . By Lemma 10, we have 1 - \text{Attn}_k^{(T_s^*)} = O(\epsilon \delta) . Therefore,
|
| 540 |
+
|
| 541 |
+
[p. 25 | section: F.2 PROOF OF THEOREM 2 | type: Equation]
|
| 542 |
+
\mathcal{L}^{(T_s^*)}(P;Q) = \frac{1}{2} \sum_{k=1}^K \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} (1 - \text{Attn}_k^{(T_s^*)})^2 \mathcal{O}(L^2 \Delta^2) \right] = \mathbb{E} \left[ (1 - \text{Attn}_k^{(T_s^*)})^2 \mathcal{O}(L^2 \Delta^2) \right] = \mathcal{O}(\epsilon^2 \delta^2).
|
| 543 |
+
|
| 544 |
+
[p. 25 | section: F.2 PROOF OF THEOREM 2 | type: Text]
|
| 545 |
+
Under the scaling regime for sharp L, either \delta = o(1) or \epsilon = o(1) (since the in-context learning regime assumes both go to zero), and hence \mathcal{L}^{(T_s^*)}(P;Q) = \mathcal{O}(\epsilon^2) as required.
|
| 546 |
+
|
| 547 |
+
[p. 25 | section: F.2 PROOF OF THEOREM 2 | type: Text]
|
| 548 |
+
This completes the proof of Theorem 2.
|
| 549 |
+
|
| 550 |
+
[p. 25 | section: PROOF OF PROPOSITION 1 | type: Text]
|
| 551 |
+
The result that 1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\epsilon) holds under both the flat L regime and the sharp L regime, as established in Lemma 8 and Lemma 10.
|
iclr26/2g8vgmyXgQ/assets.json
ADDED
|
@@ -0,0 +1,101 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
[
|
| 2 |
+
{
|
| 3 |
+
"filename": "_page_14_Figure_11.jpeg",
|
| 4 |
+
"path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/marker_raw/2g8vgmyXgQ/marker_markdown/2g8vgmyXgQ/_page_14_Figure_11.jpeg",
|
| 5 |
+
"bytes": 39681,
|
| 6 |
+
"width": 1136,
|
| 7 |
+
"height": 265,
|
| 8 |
+
"aspect_ratio": 4.286792452830189,
|
| 9 |
+
"keep": true,
|
| 10 |
+
"reject_reason": null,
|
| 11 |
+
"model_path": "assets/_page_14_Figure_11.jpeg"
|
| 12 |
+
},
|
| 13 |
+
{
|
| 14 |
+
"filename": "_page_14_Figure_9.jpeg",
|
| 15 |
+
"path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/marker_raw/2g8vgmyXgQ/marker_markdown/2g8vgmyXgQ/_page_14_Figure_9.jpeg",
|
| 16 |
+
"bytes": 39013,
|
| 17 |
+
"width": 1073,
|
| 18 |
+
"height": 259,
|
| 19 |
+
"aspect_ratio": 4.142857142857143,
|
| 20 |
+
"keep": true,
|
| 21 |
+
"reject_reason": null,
|
| 22 |
+
"model_path": "assets/_page_14_Figure_9.jpeg"
|
| 23 |
+
},
|
| 24 |
+
{
|
| 25 |
+
"filename": "_page_15_Figure_2.jpeg",
|
| 26 |
+
"path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/marker_raw/2g8vgmyXgQ/marker_markdown/2g8vgmyXgQ/_page_15_Figure_2.jpeg",
|
| 27 |
+
"bytes": 20921,
|
| 28 |
+
"width": 504,
|
| 29 |
+
"height": 293,
|
| 30 |
+
"aspect_ratio": 1.7201365187713311,
|
| 31 |
+
"keep": true,
|
| 32 |
+
"reject_reason": null,
|
| 33 |
+
"model_path": "assets/_page_15_Figure_2.jpeg"
|
| 34 |
+
},
|
| 35 |
+
{
|
| 36 |
+
"filename": "_page_15_Figure_3.jpeg",
|
| 37 |
+
"path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/marker_raw/2g8vgmyXgQ/marker_markdown/2g8vgmyXgQ/_page_15_Figure_3.jpeg",
|
| 38 |
+
"bytes": 20720,
|
| 39 |
+
"width": 497,
|
| 40 |
+
"height": 289,
|
| 41 |
+
"aspect_ratio": 1.7197231833910034,
|
| 42 |
+
"keep": true,
|
| 43 |
+
"reject_reason": null,
|
| 44 |
+
"model_path": "assets/_page_15_Figure_3.jpeg"
|
| 45 |
+
},
|
| 46 |
+
{
|
| 47 |
+
"filename": "_page_15_Figure_8.jpeg",
|
| 48 |
+
"path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/marker_raw/2g8vgmyXgQ/marker_markdown/2g8vgmyXgQ/_page_15_Figure_8.jpeg",
|
| 49 |
+
"bytes": 19367,
|
| 50 |
+
"width": 504,
|
| 51 |
+
"height": 302,
|
| 52 |
+
"aspect_ratio": 1.6688741721854305,
|
| 53 |
+
"keep": true,
|
| 54 |
+
"reject_reason": null,
|
| 55 |
+
"model_path": "assets/_page_15_Figure_8.jpeg"
|
| 56 |
+
},
|
| 57 |
+
{
|
| 58 |
+
"filename": "_page_15_Figure_9.jpeg",
|
| 59 |
+
"path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/marker_raw/2g8vgmyXgQ/marker_markdown/2g8vgmyXgQ/_page_15_Figure_9.jpeg",
|
| 60 |
+
"bytes": 18877,
|
| 61 |
+
"width": 503,
|
| 62 |
+
"height": 288,
|
| 63 |
+
"aspect_ratio": 1.7465277777777777,
|
| 64 |
+
"keep": true,
|
| 65 |
+
"reject_reason": null,
|
| 66 |
+
"model_path": "assets/_page_15_Figure_9.jpeg"
|
| 67 |
+
},
|
| 68 |
+
{
|
| 69 |
+
"filename": "_page_16_Figure_1.jpeg",
|
| 70 |
+
"path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/marker_raw/2g8vgmyXgQ/marker_markdown/2g8vgmyXgQ/_page_16_Figure_1.jpeg",
|
| 71 |
+
"bytes": 18818,
|
| 72 |
+
"width": 496,
|
| 73 |
+
"height": 305,
|
| 74 |
+
"aspect_ratio": 1.6262295081967213,
|
| 75 |
+
"keep": true,
|
| 76 |
+
"reject_reason": null,
|
| 77 |
+
"model_path": "assets/_page_16_Figure_1.jpeg"
|
| 78 |
+
},
|
| 79 |
+
{
|
| 80 |
+
"filename": "_page_16_Figure_2.jpeg",
|
| 81 |
+
"path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/marker_raw/2g8vgmyXgQ/marker_markdown/2g8vgmyXgQ/_page_16_Figure_2.jpeg",
|
| 82 |
+
"bytes": 18691,
|
| 83 |
+
"width": 501,
|
| 84 |
+
"height": 295,
|
| 85 |
+
"aspect_ratio": 1.6983050847457628,
|
| 86 |
+
"keep": true,
|
| 87 |
+
"reject_reason": null,
|
| 88 |
+
"model_path": "assets/_page_16_Figure_2.jpeg"
|
| 89 |
+
},
|
| 90 |
+
{
|
| 91 |
+
"filename": "_page_8_Figure_1.jpeg",
|
| 92 |
+
"path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/marker_raw/2g8vgmyXgQ/marker_markdown/2g8vgmyXgQ/_page_8_Figure_1.jpeg",
|
| 93 |
+
"bytes": 39951,
|
| 94 |
+
"width": 1077,
|
| 95 |
+
"height": 237,
|
| 96 |
+
"aspect_ratio": 4.544303797468355,
|
| 97 |
+
"keep": true,
|
| 98 |
+
"reject_reason": null,
|
| 99 |
+
"model_path": "assets/_page_8_Figure_1.jpeg"
|
| 100 |
+
}
|
| 101 |
+
]
|
iclr26/2g8vgmyXgQ/assets/_page_14_Figure_11.jpeg
ADDED
|
Git LFS Details
|
iclr26/2g8vgmyXgQ/assets/_page_14_Figure_9.jpeg
ADDED
|
Git LFS Details
|
iclr26/2g8vgmyXgQ/assets/_page_15_Figure_2.jpeg
ADDED
|
Git LFS Details
|
iclr26/2g8vgmyXgQ/assets/_page_15_Figure_3.jpeg
ADDED
|
Git LFS Details
|
iclr26/2g8vgmyXgQ/assets/_page_15_Figure_8.jpeg
ADDED
|
Git LFS Details
|
iclr26/2g8vgmyXgQ/assets/_page_15_Figure_9.jpeg
ADDED
|
Git LFS Details
|
iclr26/2g8vgmyXgQ/assets/_page_16_Figure_1.jpeg
ADDED
|
Git LFS Details
|
iclr26/2g8vgmyXgQ/assets/_page_16_Figure_2.jpeg
ADDED
|
Git LFS Details
|
iclr26/2g8vgmyXgQ/assets/_page_8_Figure_1.jpeg
ADDED
|
Git LFS Details
|
iclr26/2g8vgmyXgQ/chunks_v3_anonymized.jsonl
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
iclr26/2g8vgmyXgQ/dataset_meta.json
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"paper_id": "2g8vgmyXgQ",
|
| 3 |
+
"pipeline": "Paper2Markdown-V3",
|
| 4 |
+
"ok": true,
|
| 5 |
+
"page_count": 25,
|
| 6 |
+
"chunk_count": 276,
|
| 7 |
+
"main_body_chunk_count": 83,
|
| 8 |
+
"appendix_chunk_count": 184,
|
| 9 |
+
"reference_chunk_count": 9,
|
| 10 |
+
"model_text_chars": 48438,
|
| 11 |
+
"raw_markdown_chars": 95881,
|
| 12 |
+
"sanitized_chars": 92221,
|
| 13 |
+
"page_provenance": {
|
| 14 |
+
"min_page": 1,
|
| 15 |
+
"max_page": 25,
|
| 16 |
+
"invalid_count": 0
|
| 17 |
+
},
|
| 18 |
+
"marker_block_type_counts": {
|
| 19 |
+
"Caption": 4,
|
| 20 |
+
"Equation": 89,
|
| 21 |
+
"Figure": 6,
|
| 22 |
+
"FigureGroup": 3,
|
| 23 |
+
"ListGroup": 10,
|
| 24 |
+
"PageFooter": 25,
|
| 25 |
+
"PageHeader": 25,
|
| 26 |
+
"SectionHeader": 28,
|
| 27 |
+
"Text": 846
|
| 28 |
+
},
|
| 29 |
+
"asset_count_raw": 9,
|
| 30 |
+
"asset_count_model_kept": 9,
|
| 31 |
+
"asset_count_rejected": 0,
|
| 32 |
+
"asset_reject_reasons": {
|
| 33 |
+
"kept": 9
|
| 34 |
+
},
|
| 35 |
+
"artifact_leak_audit": {
|
| 36 |
+
"ok": true,
|
| 37 |
+
"hits": {
|
| 38 |
+
"Anonymous Authors": [],
|
| 39 |
+
"ACKNOWLEDGMENT": [],
|
| 40 |
+
"OpenReview": [],
|
| 41 |
+
"\"accept_label\"": [],
|
| 42 |
+
"\"decision\"": [],
|
| 43 |
+
"\"decision_tier\"": [],
|
| 44 |
+
"\"source_status\"": [],
|
| 45 |
+
"Meta-review": [],
|
| 46 |
+
"Official Review": [],
|
| 47 |
+
"official_reviews": [],
|
| 48 |
+
"meta_reviews": [],
|
| 49 |
+
"suggested_verdict_score": []
|
| 50 |
+
},
|
| 51 |
+
"artifact_count": 2
|
| 52 |
+
},
|
| 53 |
+
"default_model_input": "model_text_v3.txt",
|
| 54 |
+
"appendix_input": "appendix_text_v3.txt",
|
| 55 |
+
"reference_input": "reference_text_v3.txt",
|
| 56 |
+
"source": "iclr2026_test_public",
|
| 57 |
+
"run_name": "iclr26_20260429_1952_all",
|
| 58 |
+
"partial_snapshot": true,
|
| 59 |
+
"snapshot_created_at": "2026-04-30T02:34:47.606558+00:00"
|
| 60 |
+
}
|
iclr26/2g8vgmyXgQ/main_body_chunks.jsonl
ADDED
|
@@ -0,0 +1,83 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0000", "section": "ABSTRACT", "page_start": 1, "page_end": 1, "type": "Text", "text": "The transformer architecture has revolutionized machine learning by processing input sequences into outputs. A defining feature is in-context learning (ICL)—the ability to perform unseen tasks from prompts without updating model parameters. Early theoretical work focused on linear tasks, and recent studies have begun exploring nonlinear functions. Yet a rigorous analysis of the training dynamics—how transformers learn such complex tasks—remains elusive. This paper presents the first formal analysis of ICL training dynamics for a broad class of nonlinear regression functions. We analyze the stage-wise dynamics of attention during training: attention scores between a query token and its target features rise rapidly at first, then gradually converge to one, while attention to irrelevant features decays more slowly and can oscillate. Our analysis explicitly characterizes how general non-degenerate L-Lipschitz task functions shape attention weights, identifying the Lipschitz constant L as the key factor governing the convergence dynamics. Leveraging these insights, for two distinct regimes depending on whether L is below or above a threshold, we derive different time bounds to guarantee nearzero prediction error. Despite convergence time depending on the task, we prove query tokens ultimately focus on highly relevant prompt tokens, demonstrating transformers' robust ICL capability.", "source": "marker_v2", "marker_block_id": "/page/0/Text/4"}
|
| 2 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0001", "section": "1 INTRODUCTION", "page_start": 1, "page_end": 1, "type": "Text", "text": "The transformer architecture (Vaswani et al., 2017) has driven transformative advances across a wide spectrum of machine learning domains, including computer vision (Bi et al., 2021; Han et al., 2022; Goldblum et al., 2024) , natural language processing (Kalyan et al., 2021; Tunstall et al., 2022) , and speech processing (Mehrish et al., 2023; Latif et al., 2023) . A salient feature of transformers is their ability to perform new tasks without updating parameters, simply by conditioning on a few input-output examples—known as prompts. This capability, referred to as in-context learning (ICL) , enables models to generalize to unseen tasks purely through inference (Brown et al., 2020) .", "source": "marker_v2", "marker_block_id": "/page/0/Text/6"}
|
| 3 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0002", "section": "1 INTRODUCTION", "page_start": 1, "page_end": 1, "type": "Text", "text": "ICL has attracted growing interest, with numerous empirical studies examining when transformers succeed or fail at in-context generalization (Xie et al., 2021; Garg et al., 2022; Von Oswald et al., 2023; Wu et al., 2023; Li et al., 2024b; Agarwal et al., 2024; Park et al., 2025) . Notably, Garg et al. (2022) provided preliminary theoretical evidence that transformers trained on specific function classes (e.g., linear) can accurately infer a query function value from prompts containing variable–function pairs, highlighting transformers' surprising ability to \"learn\" within their forward pass and mimic classical function approximation.", "source": "marker_v2", "marker_block_id": "/page/0/Text/7"}
|
| 4 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0003", "section": "1 INTRODUCTION", "page_start": 1, "page_end": 1, "type": "Text", "text": "Building on this foundation, subsequent works have provided theoretical understandings of ICL by characterizing the training dynamics of single-layer attention transformers (Mahankali et al., 2023; Zhang et al., 2024; Huang et al., 2024; Collins et al., 2024; Yang et al., 2024) . For instance, Huang et al. (2024) consider softmax attention to analyze how attention weights evolve during training linear regression problems. More recent studies have theoretically shown that transformers can learn specific nonlinear function classes in-context, such as binary classification, low-degree polynomial regression, and Gaussian single-index models (Li et al., 2024a; Yang et al., 2024; Oko et al., 2024; Sun et al., 2025) . However, these studies do not provide a full theoretical picture of how the step-by-step learning process is governed by the task itself. To date, a formal characterization of the pre-training dynamics for general nonlinear ICL has been a key open problem.", "source": "marker_v2", "marker_block_id": "/page/0/Text/8"}
|
| 5 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0004", "section": "1 INTRODUCTION", "page_start": 2, "page_end": 2, "type": "Text", "text": "In this work, we take a step toward understanding the learning dynamics for ICL on a broad class of nonlinear regression functions. We address two fundamental questions: (1) Which geometric properties of the target function govern the convergence behavior of transformer-based ICL? and (2) Despite nonlinearity and generality, how can a transformer learn in context to achieve low prediction error? We answer both by analyzing transformer training under gradient descent. Our main contributions are summarized below.", "source": "marker_v2", "marker_block_id": "/page/1/Text/1"}
|
| 6 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0005", "section": "1 INTRODUCTION", "page_start": 2, "page_end": 2, "type": "ListGroup", "text": "Broad Class of Nonlinear Functions and Flexible Feature Sets: Our analysis generalizes previous studies in two ways. (i) Unlike prior theoretical works that focus on linear mappings (Zhang et al., 2024; Huang et al., 2024), binary classification (Li et al., 2024a), or low-degree polynomials (Sun et al., 2025), we characterize learning dynamics for a much broader family of non-degenerate L-Lipschitz task functions without assuming low complexity. This class is satisfied by almost any nontrivial L-Lipschitz function (e.g., scaled cosine, piecewise-polynomial, and small neural-network functions) and excludes only degenerate cases. (ii) Our results also hold for general feature embeddings without the restrictive orthonormality assumptions in prior work (Huang et al., 2024; Li et al., 2024a; Chen et al., 2024; Nichani et al., 2024). Phase Transition of Training Dynamics between Flat and Sharp Curvature Regimes: We discover a phase transition in training dynamics governed by the Lipschitz constant L. When L is below a threshold of order \\Theta\\left(\\frac{1}{\\Delta\\delta}\\right) , the flat curvature regime yields smaller gradients and permits larger step sizes to converge. When L exceeds the threshold, the sharp-curvature regime produces larger gradients requiring smaller steps. The two regimes exhibit distinct convergence behaviors: although the flat regime may converge faster at high accuracy, sufficiently large L enhances feature separability, enabling accelerated training in the sharp regime. Convergence Guarantee for ICL with Nonlinear Regression Functions: We provide formal convergence guarantees for a one-layer softmax attention model learning nonlinear regression functions. We prove that gradient descent achieves near-zero training loss in polynomial time across both flat and sharp L-regimes. We also characterize the two-phase training dynamics: an early phase in which attention scores between query tokens and target features rise rapidly, and a later phase in which these scores converge to one while attention to irrelevant features decays more slowly with oscillations. At convergence, query tokens consistently attend to highly relevant prompt tokens, demonstrating the ICL capability of transformers. Novel Analysis Techniques: We develop new proof tools that explicitly connect the curvature of nonlinear task functions to the evolution of attention weights. In particular, we first decompose the prediction loss to explicitly relate it to attention weights and cross-feature gaps under nonlinear functions. We further show that the flat and sharp curvature regimes of the parameter L lead to distinct gradient magnitudes, which in turn drive different convergence rates and shape the overall training dynamics. The impact of function curvature on the magnitude and stability of attention updates is, to our knowledge, not addressed in previous ICL literature (Huang et al., 2024; Oko et al., 2024; Cheng et al., 2024).", "source": "marker_v2", "marker_block_id": "/page/1/ListGroup/206"}
|
| 7 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0006", "section": "2 RELATED WORKS", "page_start": 2, "page_end": 2, "type": "Text", "text": "In-context learning. In-context learning (ICL) has emerged as a fundamental capability of transformer models, enabling dynamic task adaptation without parameter updates. The research community has approached ICL from several distinct yet complementary perspectives.", "source": "marker_v2", "marker_block_id": "/page/1/Text/7"}
|
| 8 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0007", "section": "2 RELATED WORKS", "page_start": 2, "page_end": 2, "type": "Text", "text": "The Bayesian inference perspective, pioneered by Xie et al. (2021) and further developed by Zhang et al. (2023); Wang et al. (2023); Falck et al. (2024), establishes a theoretical framework linking prompting strategies to probabilistic reasoning. This line of work interprets ICL as a form of implicit Bayesian model averaging, where transformers effectively perform approximated inference conditioned on the provided context. Another line of ICL work focuses on Markov chains to study the behavior of induction heads for transformers, which are designed to copy or compare tokens that follow previous occurrences (Nichani et al., 2024; Bietti et al., 2023; Edelman et al., 2024; Rajaraman et al., 2024). The central focus is to understand how transformers recover latent sequence structures (Nichani et al., 2024) and transition rules (Ren & Liu, 2024; Li et al., 2023; Makkuva et al., 2024), using token-level recurrence and dynamics.", "source": "marker_v2", "marker_block_id": "/page/1/Text/8"}
|
| 9 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0008", "section": "2 RELATED WORKS", "page_start": 3, "page_end": 3, "type": "Text", "text": "In contrast, the function learning perspective initiated by Garg et al. (2022) demonstrated transformers' remarkable ability to learn and interpolate simple function classes (particularly linear models) directly from context examples. This work sparked significant interest in understanding the mechanistic underpinnings of ICL, leading to important discoveries by Von Oswald et al. (2023) and Dai et al. (2022), who revealed deep connections between attention mechanisms and gradient-based optimization dynamics. Recent advances have substantially expanded our understanding of ICL mechanisms: Akyürek et al. (2023) provided a rigorous analysis of linear regression tasks, showing that trained transformers can implement both ridge regression gradient descent and exact least-squares solutions. Bai et al. (2023) established comprehensive theoretical results encompassing expressive power, prediction capabilities, and sample complexity, while proposing general mechanisms for algorithmic selection. Cheng et al. (2024) interprets transformers as implementing functional gradient descent for nonlinear regression, but their analysis primarily focuses on the representational capacity and functional viewpoint of the learned predictor, without analyzing the ICL pre-training dynamics.", "source": "marker_v2", "marker_block_id": "/page/2/Text/1"}
|
| 10 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0009", "section": "2 RELATED WORKS", "page_start": 3, "page_end": 3, "type": "Text", "text": "Theoretical analysis of ICL learning dynamics. Recent theoretical work has made significant progress in understanding the pre-training dynamics of ICL in transformers, though important limitations remain (Huang et al., 2024; Li et al., 2024a; Collins et al., 2024; Yang et al., 2024; Sun et al., 2025; Lu et al., 2024; Edelman et al., 2024; Lin & Lee, 2024; Jeon et al., 2024; Park et al., 2025). The foundational work by Huang et al. (2024) established the first rigorous analysis of training dynamics for softmax attention in ICL settings, focusing on a single-head attention layer learning linear regression tasks. Their key theoretical result demonstrates that prompt tokens with features identical to the query token develop dominating attention weights during training. However, this analysis relies critically on strong assumptions about pairwise orthonormality of feature vectors and a normalized function scale, limiting its applicability to more general settings. Our work goes beyond this setting by showing that, for general nonlinear targets, the Lipschitz constant of the underlying function governs both the gradient evolution and the resulting convergence regimes. In this sense, our analysis includes the linear case as a special instance while providing a more fine-grained understanding of how function curvature influences attention-based learning.", "source": "marker_v2", "marker_block_id": "/page/2/Text/2"}
|
| 11 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0010", "section": "2 RELATED WORKS", "page_start": 3, "page_end": 3, "type": "Text", "text": "Subsequent work extended these results to classification tasks (Li et al., 2024a), dual-head settings (Lin & Lee, 2024), and structured or hierarchical functions (Yang et al., 2024; Sun et al., 2025). Some studies explored the implicit bias of gradient descent and attention-based generalization (Collins et al., 2024; Lu et al., 2024), while others examined information-theoretic and dynamical aspects of ICL (Edelman et al., 2024; Jeon et al., 2024). Despite these advances, most analyses still rely on restrictive assumptions, such as orthonormality features, fixed positional encoding, or carefully structured input distributions, limiting their ability to explain ICL under general tasks and practical learning conditions.", "source": "marker_v2", "marker_block_id": "/page/2/Text/3"}
|
| 12 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0011", "section": "2 RELATED WORKS", "page_start": 3, "page_end": 3, "type": "Text", "text": "Notations. In this paper, for a vector \\boldsymbol{v} , we let \\|\\boldsymbol{v}\\|_2 denote its \\ell -2 norm. For some positive constant C_1 and C_2 , we define x = \\Omega(y) if x > C_2|y| , x = \\Theta(y) if C_1|y| < x < C_2|y| , and x = \\mathcal{O}(y) if x < c_1|y| . We also denote by x = o(y) if x/y \\to 0 . We use \\operatorname{poly}(C) to denote large constant degree polynomials of C. For a matrix A, we use A_i to denote the i-th column of A, and A_{i:j} to represent the collection of columns from the i-th to the j-th column (inclusive).", "source": "marker_v2", "marker_block_id": "/page/2/Text/4"}
|
| 13 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0012", "section": "3 System Model", "page_start": 3, "page_end": 3, "type": "Text", "text": "In this section, we formulate our system model, including the problem setup for in-context learning, the transformer architecture, and the associated training process.", "source": "marker_v2", "marker_block_id": "/page/2/Text/6"}
|
| 14 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0013", "section": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP", "page_start": 3, "page_end": 3, "type": "Text", "text": "We consider a standard in-context learning (ICL) framework commonly used in prior studies (Garg et al., 2022; Huang et al., 2024; Yang et al., 2024). The objective is to train a transformer model that can perform ICL over a designated class of functions \\mathcal{F} , where each function f \\in \\mathcal{F} corresponds to one task context. Here, we focus on nonlinear function classes further elaborated below.", "source": "marker_v2", "marker_block_id": "/page/2/Text/8"}
|
| 15 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0014", "section": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP", "page_start": 3, "page_end": 3, "type": "Text", "text": "Given each task (i.e., given one function f randomly sampled from \\mathcal{F} ), a prompt with a sequence of N input-response pairs (x_i, y_i) as well as a query input x_{\\text{query}} are sampled, where x_i \\in \\mathcal{X} \\subseteq \\mathbb{R}^d , and y_i = f(x_i) . Let the input matrix X = (x_1 \\ x_2 \\ \\cdots \\ x_N) \\in \\mathbb{R}^{d \\times N} and the response vector \\mathbf{y} = (y_1 \\ y_2 \\ \\cdots \\ y_N) \\in \\mathbb{R}^{1 \\times N} . We adopt the following standard prompt embedding (Garg et al.,", "source": "marker_v2", "marker_block_id": "/page/2/Text/9"}
|
| 16 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0015", "section": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP", "page_start": 4, "page_end": 4, "type": "Text", "text": "2022: Huang et al., 2024: Yang et al., 2024):", "source": "marker_v2", "marker_block_id": "/page/3/Text/1"}
|
| 17 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0016", "section": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP", "page_start": 4, "page_end": 4, "type": "Equation", "text": "P = \\begin{pmatrix} x_1 & x_2 & \\cdots & x_N & x_{\\text{query}} \\\\ y_1 & y_2 & \\cdots & y_N & 0 \\end{pmatrix} = \\begin{pmatrix} X & x_{\\text{query}} \\\\ \\mathbf{y} & 0 \\end{pmatrix} \\in \\mathbb{R}^{(d+1)\\times(N+1)}. \\tag{1}", "source": "marker_v2", "marker_block_id": "/page/3/Equation/2"}
|
| 18 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0017", "section": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP", "page_start": 4, "page_end": 4, "type": "Text", "text": "Non-degenerate L -Lipschitz Regression Functions. In this work, we focus on regression tasks, where each task is associated with a regression function drawn from the following set", "source": "marker_v2", "marker_block_id": "/page/3/Text/3"}
|
| 19 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0018", "section": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP", "page_start": 4, "page_end": 4, "type": "Equation", "text": "\\mathcal{F} = \\left\\{ f: \\begin{array}{l} |f(x) - f(x')| \\leq L ||x - x'||, & \\forall ||x - x'|| = \\Theta(\\delta_0), \\\\ \\forall v_k \\in \\mathbb{V}, \\exists v_{k'} \\in \\mathbb{V}, \\ k' \\neq k, \\ \\text{such that} \\ |f(v_k) - f(v_{k'})| = \\Theta(L) \\cdot ||v_k - v_{k'}|| \\end{array} \\right\\}, (2)", "source": "marker_v2", "marker_block_id": "/page/3/Equation/4"}
|
| 20 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0019", "section": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP", "page_start": 4, "page_end": 4, "type": "Text", "text": "where L>0 and \\delta_0=\\mathcal{O}(1) . In particular, the functions in the class are said to satisfy non-degenerate L- Lipschitz condition, which imposes two natural requirements on the function class. First, the standard global L-Lipschitz condition ensures that the function f does not change too rapidly, which is common in the literature and includes a wide class of linear and nonlinear functions. Second, the separation requirement guarantees that for any feature v_k in the set \\mathbb{V} , there exists at least one other feature v_{k'} such that the function difference between them achieves the order of variation defined by the Lipschitz constant. This ensures sufficient distinguishability of features by the function class for guaranteed learnability. This mild separation assumption is satisfied by almost any nontrivial L-Lipschitz function (e.g., scaled cosine, piecewise-polynomial, and small neural-network functions) and excludes only degenerate cases. Together, these two conditions ensure that the function class is sufficiently rich for ICL while avoiding unlearnable or trivial scenarios.", "source": "marker_v2", "marker_block_id": "/page/3/Text/5"}
|
| 21 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0020", "section": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP", "page_start": 4, "page_end": 4, "type": "Text", "text": "For each prompt P, the task-specific function f(x) is independently drawn based on a task distribution \\mathcal{D}_f , as long as f(x) satisfies the property for the same L and \\delta_0 in Eq. (2).", "source": "marker_v2", "marker_block_id": "/page/3/Text/6"}
|
| 22 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0021", "section": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP", "page_start": 4, "page_end": 4, "type": "Text", "text": "Feature Embeddings. Let \\mathbb{V}:=\\{v_k\\in\\mathbb{R}^d|k=1,\\cdots,K\\} be the feature embeddings of tokens. For any k\\neq k' , we assume a separation of \\|v_k-v_{k'}\\|=\\Theta(\\Delta) , where \\Delta=\\Theta(1) . Each data sample x is modeled as a noisy perturbation of one of the vectors in \\mathbb{V} . This assumption lets us control the separation \\Delta precisely, simplifying the analysis while retaining the essential geometry of the problem. Such a condition can be satisfied by various feature learning techniques to avoid feature collapse, e.g., disentangled representation learning (Wang et al., 2022; 2024; Higgins et al., 2018). We note that such a condition substantially generalizes the orthonormality assumption taken by the previous study (Huang et al., 2024; Li et al., 2024a; Chen et al., 2024; Nichani et al., 2024). The prompt is sampled as follows. For a randomly chosen v_k , we assume x satisfies \\|x-v_k\\|=O(\\epsilon_x) with probability p_k , where \\epsilon_x=o(1) and p_k=\\Theta(\\frac{1}{K}) . For analytical simplicity, we assume x=v_k whenever this proximity condition holds. In our experiments in Section 6, we further verify that our training dynamic analysis remains valid when tokens are drawn from general continuous distributions.", "source": "marker_v2", "marker_block_id": "/page/3/Text/7"}
|
| 23 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0022", "section": "3.2 One-Layer Transformer", "page_start": 4, "page_end": 4, "type": "Text", "text": "In this work, we adopt a one-layer transformer model for solving the ICL problem, which is commonly used in the existing theoretical ICL literature (e.g., Huang et al. (2024); Li et al. (2024a); Yang et al. (2024); Sun et al. (2025)). A self-attention transformer with width d_e consists of a key matrix W^K \\in \\mathbb{R}^{d_e \\times d_e} , a query matrix W^Q \\in \\mathbb{R}^{d_e \\times d_e} , and a value matrix W^V \\in \\mathbb{R}^{d_e \\times d_e} . For a given prompt P of length N in Eq. (1), the self-attention layer outputs:", "source": "marker_v2", "marker_block_id": "/page/3/Text/9"}
|
| 24 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0023", "section": "3.2 One-Layer Transformer", "page_start": 4, "page_end": 4, "type": "Equation", "text": "F(P; W^K, W^Q, W^V) = W^V P \\times \\operatorname{softmax} \\left( (W^K P)^\\top W^Q P \\right). \\tag{3}", "source": "marker_v2", "marker_block_id": "/page/3/Equation/10"}
|
| 25 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0024", "section": "3.2 One-Layer Transformer", "page_start": 4, "page_end": 4, "type": "Text", "text": "where the softmax(·) function is applied column-wisely, i.e., for a vector input z, the i-th entry of softmax(z) is given by softmax( z_i ) = \\frac{\\exp(z_i)}{\\sum_i \\exp(z_j)} .", "source": "marker_v2", "marker_block_id": "/page/3/Text/11"}
|
| 26 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0025", "section": "3.2 One-Layer Transformer", "page_start": 4, "page_end": 4, "type": "Text", "text": "We further take the following re-parameterization, commonly adopted by the recent theoretical studies of transformers (e.g. Zhang et al. (2024); Huang et al. (2024); Yang et al. (2024); Sun et al. (2025)), which combines the query and key matrices into a single matrix W^{KQ} \\in \\mathbb{R}^{(d+1)\\times (d+1)} , and further specify the weight matrices as follows:", "source": "marker_v2", "marker_block_id": "/page/3/Text/12"}
|
| 27 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0026", "section": "3.2 One-Layer Transformer", "page_start": 4, "page_end": 4, "type": "Equation", "text": "W^V = \\begin{pmatrix} 0_{d \\times d} & 0_d \\\\ 0_d^\\top & 1 \\end{pmatrix}, \\quad W^{KQ} = \\begin{pmatrix} Q & 0_d \\\\ 0_d^\\top & 0 \\end{pmatrix},", "source": "marker_v2", "marker_block_id": "/page/3/Equation/13"}
|
| 28 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0027", "section": "3.2 One-Layer Transformer", "page_start": 4, "page_end": 4, "type": "Text", "text": "where Q \\in \\mathbb{R}^{d \\times d} is the trainable weight matrix. These simplifications, while not capturing the full complexity of deep, multi-head models, are standard in the theoretical literature and serve two crucial purposes. First, they allow for a tractable analysis that isolates the core dynamics of the softmax", "source": "marker_v2", "marker_block_id": "/page/3/Text/14"}
|
| 29 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0028", "section": "3.2 One-Layer Transformer", "page_start": 5, "page_end": 5, "type": "Equation", "text": "F(P;Q) = \\mathbf{y} \\cdot \\operatorname{softmax}(X^{\\top} Q \\bar{X}), \\tag{4}", "source": "marker_v2", "marker_block_id": "/page/4/Equation/2"}
|
| 30 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0029", "section": "3.2 One-Layer Transformer", "page_start": 5, "page_end": 5, "type": "Text", "text": "where we further let \\bar{X}=(x_1 \\quad x_2 \\quad \\cdots \\quad x_N \\quad x_{\\text{query}}) \\in \\mathbb{R}^{d \\times N+1} and \\mathbf{y}=(y_1 \\quad y_2 \\quad \\cdots \\quad y_N) \\in \\mathbb{R}^{d \\times N+1} \\mathbb{R}^{d \\times N} . The prediction \\hat{y}_{\\text{query}} corresponding to x_{\\text{query}} is given by the last entry of F(P;Q)_{N+1} , i.e., \\hat{y}_{\\text{query}} = F(P;Q)_{N+1} . To train the attention model on the ICL problem introduced in Section 3.1, we minimize the following squared loss between the predicted and true responses:", "source": "marker_v2", "marker_block_id": "/page/4/Text/3"}
|
| 31 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0030", "section": "3.2 One-Layer Transformer", "page_start": 5, "page_end": 5, "type": "Equation", "text": "\\mathcal{L}(P;Q) = \\frac{1}{2} \\mathbb{E} \\left[ \\left( F(P;Q)_{N+1} - f(x_{\\text{query}}) \\right)^2 \\right], \\tag{5}", "source": "marker_v2", "marker_block_id": "/page/4/Equation/4"}
|
| 32 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0031", "section": "3.2 One-Layer Transformer", "page_start": 5, "page_end": 5, "type": "Text", "text": "\\mathcal{L}(P;Q) = \\frac{1}{2}\\mathbb{E}\\Big[\\big(F(P;Q)_{N+1} - f(x_{\\text{query}})\\big)^2\\Big], \\tag{5} where the expectation is taken over the randomly sampled prompt \\{x_i\\}_{i=1}^N \\cup \\{x_{\\text{query}}\\} and randomly sampled function f \\in \\mathcal{F} that determines the corresponding ground-truth responses.", "source": "marker_v2", "marker_block_id": "/page/4/Text/5"}
|
| 33 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0032", "section": "3.2 One-Layer Transformer", "page_start": 5, "page_end": 5, "type": "Text", "text": "We optimize this loss via gradient descent (GD). Let vec(Q) denote the vector that stacks all entries of Q. At t = 0, we initialize vec(Q)^{(0)} as the zero matrix 0_{d^2} . The parameter is updated as follows:", "source": "marker_v2", "marker_block_id": "/page/4/Text/6"}
|
| 34 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0033", "section": "3.2 One-Layer Transformer", "page_start": 5, "page_end": 5, "type": "Equation", "text": "\\operatorname{vec}(Q)^{(t+1)} = \\operatorname{vec}(Q)^{(t)} - \\eta \\nabla_{\\operatorname{vec}(Q)} \\mathcal{L}(P; \\operatorname{vec}(Q)^{(t)}). \\tag{6}", "source": "marker_v2", "marker_block_id": "/page/4/Equation/7"}
|
| 35 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0034", "section": "3.2 One-Layer Transformer", "page_start": 5, "page_end": 5, "type": "Text", "text": "where \\eta > 0 is the learning rate. Note that we require \\eta to be smaller than a universal constant (e.g., \\eta < 1 ) to ensure stability of the update and to preserve the convergence behavior analyzed in Section 5. Based on this model setup and training procedure, we proceed to present our main theoretical results concerning ICL under nonlinear regression tasks.", "source": "marker_v2", "marker_block_id": "/page/4/Text/8"}
|
| 36 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0035", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 5, "page_end": 5, "type": "Text", "text": "Our analysis proceeds by decomposing the loss function into interpretable quantities that directly reflect cluster separation and the Lipschitz constant L in Eq. (2). Interestingly, we observe that the flat and sharp regimes of L give rise to distinct convergence dynamics, with a threshold transition separating the two regimes based on the order of magnitude of L. In the flat regime (small L), the gradient on Q matrices remains small, leading to slow but steady concentration of attention weights. In the sharp regime (large L), we show a rapid growth phase where the query-key inner products amplify differences between clusters before settling into a slow fine-tuning phase. For the two regimes, we provide explicit convergence-time bounds and characterize the phase transition. Compared with prior analyses restricted to linear tasks or orthogonal features, our framework extends to general nonlinear Lipschitz tasks and explains qualitatively different dynamics observed in practice.", "source": "marker_v2", "marker_block_id": "/page/4/Text/10"}
|
| 37 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0036", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 5, "page_end": 5, "type": "Text", "text": "Recall from Section 3.1 that each token x_i corresponds to a noisy version of a feature v_k \\in \\mathbb{V} with probability p_k = \\Theta\\left(\\frac{1}{K}\\right) for any k \\in [K] . Let P_{1:N} denote the collection of input tokens in P, i.e., \\{x_i\\}_{i=1}^N , and denote \\mathcal{V}_k \\subset [N] as the index set for input tokens, such that x_i = v_k for i \\in \\mathcal{V}_k . We define the following concentration set of token sequences where each feature appears with approximately the expected frequency:", "source": "marker_v2", "marker_block_id": "/page/4/Text/11"}
|
| 38 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0037", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 5, "page_end": 5, "type": "Equation", "text": "\\mathcal{E}^* := \\left\\{ P_{1:N} : |\\mathcal{V}_k| \\in \\left[ (p_k - \\delta)N, (p_k + \\delta)N \\right] \\text{ for } k \\in [K] \\right\\}, \\tag{7}", "source": "marker_v2", "marker_block_id": "/page/4/Equation/12"}
|
| 39 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0038", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 5, "page_end": 5, "type": "Text", "text": "where \\delta \\geq \\sqrt{\\frac{20K}{N}} . Then, for any 0 < \\epsilon < 1 , suppose N \\geq \\Theta(K^3) and K \\geq \\Theta(\\frac{1}{\\epsilon}) . For any t \\in [T] , we have the concentration probability satisfies \\mathbb{P}(P_{1:N} \\in \\mathcal{E}^*) \\ge 1 - 3 \\exp\\left(-\\frac{\\delta^2 N}{25}\\right) . This implies that, with high probability, each feature class k \\in [K] is approximately equally represented in the prompt P, ensuring a balanced token distribution. Such balance is crucial for the convergence of ICL, as it allows the attention to learn effectively from all feature types without introducing bias. While our analysis is expressed in terms of the population risk in Eq. (5), the concentration event in Eq. (7) ensures that the empirical prompt distribution closely matches the population distribution when N is sufficiently large. Under this event, the curvature-driven attention dynamics characterized later in our theory remain accurate up to standard \\mathcal{O}(1/\\sqrt{N}) fluctuations. Thus, the population-level analysis offers a faithful description of the finite-sample training behavior for prompts of moderate size.", "source": "marker_v2", "marker_block_id": "/page/4/Text/13"}
|
| 40 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0039", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "Given balanced feature inputs, we now quantify how much the query token x_{query} attends to specific input tokens or feature classes. We define the attention score for a query token to attend to the i-th token in the prompt as \\operatorname{attn}_i^{(t)} := \\operatorname{softmax}(x_i^\\top Q^{(t)} x_{\\operatorname{query}}) and the total attention paid to all tokens with feature v_k as \\operatorname{Attn}_k^{(t)} := \\sum_{i:x_i=v_k} \\operatorname{attn}_i^{(t)} . With this notation, the transformer's output at t is", "source": "marker_v2", "marker_block_id": "/page/5/Text/1"}
|
| 41 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0040", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Equation", "text": "\\hat{y}_{\\text{query}} = \\sum_{i \\in [N]} \\operatorname{attn}_{i}^{(t)} y_{i} = \\sum_{k \\in [K]} \\operatorname{Attn}_{k}^{(t)} f(v_{k}). \\tag{8}", "source": "marker_v2", "marker_block_id": "/page/5/Equation/2"}
|
| 42 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0041", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "Building on the expression in Eq. (8), we characterize how the attention scores influence the prediction loss defined in Eq. (5) in the following lemma.", "source": "marker_v2", "marker_block_id": "/page/5/Text/3"}
|
| 43 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0042", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "Lemma 1. Given constants L, \\Delta > 0 , the prediction loss in Eq. (5) can be expressed as:", "source": "marker_v2", "marker_block_id": "/page/5/Text/4"}
|
| 44 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0043", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Equation", "text": "\\mathcal{L}(P;Q) = \\frac{1}{2} \\sum_{k=1}^{K} \\mathbb{E} \\left[ \\mathbb{1} \\{ x_{\\text{query}} = v_k \\} \\left( 1 - \\operatorname{Attn}_{k}^{(t)} \\right)^2 \\cdot \\mathcal{O}(L^2 \\Delta^2) \\right], \\ \\forall t \\in [T], (9) where \\mathbb{1} \\{ x_{\\text{query}} = v_k \\} = 1 is the indicator function that equals 1 if x_{\\text{query}} = v_k and 0 otherwise.", "source": "marker_v2", "marker_block_id": "/page/5/Equation/5"}
|
| 45 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0044", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "The proof of Lemma 1 is given in Appendix C. This expression reveals that loss \\mathcal{L}(P;Q) depends on the Lipschitz constant L, the feature gap \\Delta , and the attention score \\operatorname{Attn}_k^{(t)} associated with the true feature of the query token. The dependence on L, which captures the function's curvature, distinguishes our analysis from prior theoretical work on ICL (e.g., Huang et al. (2024); Oko et al. (2024); Sun et al. (2025)). For a given feature gap \\Delta , different function Lipschitz constants L can lead to distinct convergence behaviors of ICL. In the following theorem, we first provide the \\epsilon^2 -convergence of \\mathcal{L}(P;Q) in the flat L-regime, where L is below a certain threshold.", "source": "marker_v2", "marker_block_id": "/page/5/Text/7"}
|
| 46 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0045", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "Theorem 1 (Flat L-regime). Suppose the function class in Eq. (2) satisfies L \\leq \\Theta\\left(\\frac{1}{\\Delta\\delta}\\right) . Then, for any 0 < \\epsilon < 1 and under N \\geq \\Theta(K^3) and K \\geq \\Theta(\\frac{1}{\\epsilon}) , with at most T_f^* = \\Theta(\\frac{K \\log(K\\epsilon^{-1})}{\\eta \\delta^2 L^2 \\Delta^2}) iterations, we have \\mathcal{L}(P;Q) \\leq \\mathcal{O}(\\epsilon^2) .", "source": "marker_v2", "marker_block_id": "/page/5/Text/8"}
|
| 47 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0046", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "The proof of Theorem 1 is given in Appendix E.3. Theorem 1 indicates that T_f^* decreases (i.e., the convergence is faster) as either the Lipschitz constant L or the feature gap \\Delta increases. Intuitively, a larger function Lipschitz constant L implies that the outputs y_i and y_{i'} corresponding to different features in the prompt P become more distinguishable, which facilitates faster in-context learning. Similarly, a larger feature gap \\Delta improves the separability among features, enabling the query token to more accurately attend to the relevant prompt tokens.", "source": "marker_v2", "marker_block_id": "/page/5/Text/9"}
|
| 48 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0047", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "However, when L exceeds a certain threshold, the caused sharp curvature induces large gradients on the attention weights. As a result, a smaller stepsize is required to stabilize convergence, leading to a convergence rate that differs from that in the flat regime. We next establish the \\epsilon^2 -convergence of \\mathcal{L}(P;Q) in the sharp L regime, where L is above the threshold.", "source": "marker_v2", "marker_block_id": "/page/5/Text/10"}
|
| 49 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0048", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "Theorem 2 (Sharp L-regime). Suppose the function class in Eq. (2) satisfies L = \\Omega(\\frac{1}{\\Delta\\delta}) . Then for any 0 < \\epsilon < 1 , under N = \\Omega(K^3) and K \\ge \\Theta(\\frac{1}{\\epsilon}) , with at most T_s^* = \\Theta(\\frac{K \\log(K\\epsilon^{-1}L\\Delta)}{n\\epsilon\\delta^2L^2\\Delta^2}) iterations, we have \\mathcal{L}(P;Q) = \\mathcal{O}(\\epsilon^2)", "source": "marker_v2", "marker_block_id": "/page/5/Text/11"}
|
| 50 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0049", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "The proof of Theorem 2 is given in Appendix F.2. Theorem 1 and Theorem 2 together reveal an interesting phase transition phenomenon : the convergence dynamics are governed by how the function Lipschitz constant L compares to a threshold of order \\Theta\\left(\\frac{1}{\\Delta\\delta}\\right) . In the flat curvature regime , where L is below this threshold, convergence allows larger step sizes due to smaller gradients, resulting in a convergence rate of \\tilde{\\Theta}\\left(\\frac{K}{\\eta\\delta^2L^2\\Delta^2}\\right) . In contrast, in the sharp curvature regime , where L is above the threshold, the large L incurs large gradients which thus require smaller step sizes to stabilize convergence, yielding a convergence rate of \\tilde{\\Theta}\\left(\\frac{K}{\\eta\\epsilon\\delta^2L^2\\Delta^2}\\right) . Comparing the two convergence upper bounds, neither T_f^* nor T_s^* always dominates. The sharp regime benefits from a larger L, giving a smaller denominator and faster convergence, but its bound also contains an extra \\frac{1}{\\epsilon} factor that can dominate when high accuracy is required. Therefore, depending on the relative scales of L, \\epsilon , and \\Delta , either regime may achieve the smaller convergence upper bound.", "source": "marker_v2", "marker_block_id": "/page/5/Text/12"}
|
| 51 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0050", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 6, "page_end": 6, "type": "Text", "text": "In cases where the query is not a small perturbation of any feature vector, the model must represent the query using a combination of multiple feature clusters rather than relying on a single dominant one. This setting is more challenging because the nonlinear function values evolve over training, causing the optimal attention pattern to shift across clusters. Nevertheless, the curvature-dependent", "source": "marker_v2", "marker_block_id": "/page/5/Text/13"}
|
| 52 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0051", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 7, "page_end": 7, "type": "Text", "text": "gradient behavior established in our analysis continues to govern the convergence rate, even though the precise attention trajectory becomes harder to characterize.", "source": "marker_v2", "marker_block_id": "/page/6/Text/1"}
|
| 53 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0052", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 7, "page_end": 7, "type": "Text", "text": "Based on the convergence results above, we now characterize the behavior of the attention score Attn_k^{(t)} at convergence to explain why the ICL output corresponds to an accurate prediction.", "source": "marker_v2", "marker_block_id": "/page/6/Text/2"}
|
| 54 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0053", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 7, "page_end": 7, "type": "Text", "text": "Proposition 1. After the prediction loss converges to \\mathcal{L}(P;Q) = \\mathcal{O}(\\epsilon^2) for any 0 < \\epsilon < 1 , if the query token satisfies x_{\\text{query}} = v_k , then the attention score associated with feature v_k satisfies 1 - \\operatorname{Attn}_{k}^{(t)} = \\mathcal{O}(\\epsilon).", "source": "marker_v2", "marker_block_id": "/page/6/Text/3"}
|
| 55 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0054", "section": "MAIN RESULTS OF ICL CONVERGENCE", "page_start": 7, "page_end": 7, "type": "Text", "text": "The proof of Proposition 1 is given in Appendix G. This result follows directly from the loss expression in Eq. (9), where \\mathcal{L}(P;Q) = \\Theta((1-\\operatorname{Attn}_k^{(t)})^2) when x_{\\text{query}} = v_k . Intuitively, as Attn_k^{(t)} approaches 1, the attention matrix effectively focuses predominantly on the tokens that share the same feature v_k . As a result, the predicted output \\hat{y}_{query} , given by Eq. (8), closely approximates the true value f(v_k) , leading to high-accuracy predictions.", "source": "marker_v2", "marker_block_id": "/page/6/Text/4"}
|
| 56 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0055", "section": "ANALYSIS OF CONVERGENCE DYNAMICS", "page_start": 7, "page_end": 7, "type": "Text", "text": "As established in Theorem 1 and Theorem 2, different regimes of the Lipschitz constant L lead to distinct convergence behaviors in ICL. In this section, we analyze the training dynamics under both regimes, highlighting how the Lipschitz constant L influences the convergence rate in each case.", "source": "marker_v2", "marker_block_id": "/page/6/Text/6"}
|
| 57 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0056", "section": "GRADIENTS OF ATTENTION WEIGHTS", "page_start": 7, "page_end": 7, "type": "Text", "text": "Based on the prediction output \\hat{y}_{\\text{query}} in Eq. (5), the attention scores \\text{attn}_i play a critical role in determining the final prediction. To precisely characterize these attention scores for any i \\in [N] , it is sufficient to characterize the training dynamics of the attention weights q_{k,k'}^{(t)} := v_{k'}^{\\top} Q^{(t)} v_k for k, k' \\in [K] , which are initialized as q_{k,k'}^{(0)} = 0 for any k, k' \\in [K] . To simplify notations, we denote the q_{k,k}^{(t)} as q_k^{(t)} for k'=k. According to the definition of the attention score \\operatorname{attn}_i^{(t)} in Eq. (8), when x_{\\text{query}}^{(t)} = v_k , the quantity q_k^{(t)} measures how strongly the query token attends to the target feature v_k , while q_{k k'}^{(t)} reflects the attention given to a different feature v_{k'} with k' \\neq k . To achieve the desired attention behavior, effective training should increase q_k^{(t)} while suppressing q_{k,k'}^{(t)}", "source": "marker_v2", "marker_block_id": "/page/6/Text/8"}
|
| 58 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0057", "section": "GRADIENTS OF ATTENTION WEIGHTS", "page_start": 7, "page_end": 7, "type": "Text", "text": "The convergence behavior of the transformer depends on the dynamics of q_k^{(t)} and q_{k,k'}^{(t)} . We therefore proceed to analyze how these quantities evolve during training. To this end, we define the gradient updates for q_k^{(t)} and q_{k,k'}^{(t)} as g_k^{(t)} and g_{k,k'}^{(t)} , respectively. Under gradient descent with learning rate \\eta , the update rules are given by:", "source": "marker_v2", "marker_block_id": "/page/6/Text/9"}
|
| 59 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0058", "section": "GRADIENTS OF ATTENTION WEIGHTS", "page_start": 7, "page_end": 7, "type": "Equation", "text": "q_k^{(t+1)} := q_k^{(t)} + \\eta g_k^{(t)}, \\qquad q_{k k'}^{(t+1)} := q_{k k'}^{(t)} + \\eta g_{k k'}^{(t)}.", "source": "marker_v2", "marker_block_id": "/page/6/Equation/10"}
|
| 60 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0059", "section": "GRADIENTS OF ATTENTION WEIGHTS", "page_start": 7, "page_end": 7, "type": "Text", "text": "q_k^{(t+1)} := q_k^{(t)} + \\eta g_k^{(t)}, \\qquad q_{k,k'}^{(t+1)} := q_{k,k'}^{(t)} + \\eta g_{k,k'}^{(t)}. We now present the following lemma, which provides the exact expressions for the gradient terms g_k^{(t)} and g_{k,k'}^{(t)} for a function class {\\mathcal F} with Lipschitz constant L.", "source": "marker_v2", "marker_block_id": "/page/6/Text/11"}
|
| 61 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0060", "section": "GRADIENTS OF ATTENTION WEIGHTS", "page_start": 7, "page_end": 7, "type": "Text", "text": "Lemma 2. For any t \\in [T] , suppose x_{query} = v_k . Then for any k, k' \\in [K] with k' \\neq k , we obtain", "source": "marker_v2", "marker_block_id": "/page/6/Text/12"}
|
| 62 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0061", "section": "GRADIENTS OF ATTENTION WEIGHTS", "page_start": 7, "page_end": 7, "type": "Equation", "text": "g_k^{(t)} = \\mathbb{E}\\left[\\mathbb{1}\\left\\{x_{\\text{query}} = v_k\\right\\} \\operatorname{Attn}_k^{(t)} \\left(1 - \\operatorname{Attn}_k^{(t)}\\right)^2 \\cdot \\Theta(L^2 \\Delta^2)\\right],\\tag{10}", "source": "marker_v2", "marker_block_id": "/page/6/Equation/13"}
|
| 63 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0062", "section": "GRADIENTS OF ATTENTION WEIGHTS", "page_start": 7, "page_end": 7, "type": "Equation", "text": "|g_{k,k'}^{(t)}| = \\mathbb{E}\\left[\\mathbb{1}\\{x_{\\text{query}}^{(t)} = v_k\\} \\text{Attn}_{k'}^{(t)} \\cdot (1 - \\text{Attn}_{k}^{(t)}) \\cdot (1 - \\text{Attn}_{k'}^{(t)}) \\cdot \\Theta(L^2 \\Delta^2)\\right]. \\tag{11}", "source": "marker_v2", "marker_block_id": "/page/6/Equation/14"}
|
| 64 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0063", "section": "GRADIENTS OF ATTENTION WEIGHTS", "page_start": 7, "page_end": 7, "type": "Text", "text": "The proof of Lemma 2 is given in Appendix D. From Eq. (10), we observe that g_k^{(t)} is always non-negative, implying that the update q_k^{(t)} increases over time. This growth continues until the attention score Attn_k^{(t)} approaches its convergence state near 1. However, g_{k,k'}^{(t)} in Eq. (11) is not necessarily positive and also depends on Attn_{k'}^{(t)} associated with feature vector v_{k'} . However, as Attn_k^{(t)} approaches 1, the residual term in Eq. (11) diminishes, and g_{k,k'}^{(t)} also converges toward zero, facilitating the overall convergence of the system.", "source": "marker_v2", "marker_block_id": "/page/6/Text/15"}
|
| 65 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0064", "section": "GRADIENTS OF ATTENTION WEIGHTS", "page_start": 8, "page_end": 8, "type": "Text", "text": "As also shown in Lemma 2, both gradients scale with the Lipschitz constant L and the feature gap \\Delta , illustrating their influence on the training dynamics. In the following subsections, we analyze how different regimes of the function Lipschitz constant L (with respect to the threshold determined by \\Delta ) affect the evolution of q_k^{(t)} and q_{k,k'}^{(t)} , through the gradients g_k^{(t)} and g_{k,k'}^{(t)} , thereby offering deeper insight into the convergence results established in Theorem 1 and Theorem 2.", "source": "marker_v2", "marker_block_id": "/page/7/Text/1"}
|
| 66 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0065", "section": "5.2 Convergence Dynamics under Flat L-Regime", "page_start": 8, "page_end": 8, "type": "Text", "text": "For ease of exposition, we consider the case where x_{\\mathrm{query}} = v_k in the following. Under the initialization of q_k^{(0)} = q_{k,k'}^{(0)} = 0 , and by the definition of the attention score, we have \\mathrm{attn}_n^{(0)} = \\frac{1}{N} for all n \\in [N] , meaning that the transformer initially attends equally to all input tokens when computing the prediction for x_{\\mathrm{query}} . We then leverage the task distribution in Eq. (2) and the gradient expressions in Lemma 2 to analyze the learning dynamics of q_k^{(t)} and q_{k,k'}^{(t)} .", "source": "marker_v2", "marker_block_id": "/page/7/Text/3"}
|
| 67 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0066", "section": "5.2 Convergence Dynamics under Flat L-Regime", "page_start": 8, "page_end": 8, "type": "Text", "text": "In the initial phase of training, the prediction \\hat{y}_{\\text{query}} is far from the ground truth f(v_k) due to the zero initialization of bilinear weights. According to Eq. (10), this results in a large positive gradient g_k^{(t)} , leading to a rapid increase in q_k^{(t)} . In contrast, the gradient g_{k,k'}^{(t)} may fluctuate in sign depending on the alignment of f(v_k) and f(v_{k'}) at each step, causing q_{k,k'}^{(t)} to oscillate but decrease much more slowly. We formally characterize this phase below.", "source": "marker_v2", "marker_block_id": "/page/7/Text/4"}
|
| 68 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0067", "section": "5.2 Convergence Dynamics under Flat L-Regime", "page_start": 8, "page_end": 8, "type": "Text", "text": "Proposition 2 (Phase I: Fast growth of q_k^{(t)} ). For any t \\in \\{1, \\cdots, T_f^1\\} and k \\in [K] , where T_f^1 = \\Theta(\\frac{K \\log(K)}{\\eta L^2 \\Delta^2}) , the attention weight q_k^{(t)} increases at a rate of \\Theta(\\frac{\\eta L^2 \\Delta^2}{K}) . Meanwhile, q_{k,k'}^{(t)} oscillates at a slower rate of O(\\frac{\\eta L^2 \\Delta^2}{K^2}) and exhibits an overall decreasing trend. By the end of Phase I (i.e., t = T_f^1 + 1 ), we have \\operatorname{Attn}_k^{(T_f^1 + 1)} = \\Omega(\\frac{1}{1 + \\delta}) .", "source": "marker_v2", "marker_block_id": "/page/7/Text/5"}
|
| 69 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0068", "section": "5.2 Convergence Dynamics under Flat L-Regime", "page_start": 8, "page_end": 8, "type": "Text", "text": "The proof of Proposition 2 is given in Appendix E.1. According to Proposition 2, Phase I ends once q_k^{(t)} becomes sufficiently large to reduce the prediction gap between the ICL output and the ground truth function value. After this point, both g_k^{(t)} in Eq. (10) and |g_{k,k'}^{(t)}| in Eq. (11) decrease to smaller orders. During this phase, both g_k^{(t)} and |g_{k,k'}^{(t)}| increase with L, as a larger function Lipschitz constant induces greater residual values in Eq. (10) and Eq. (11). Likewise, a larger feature gap \\Delta amplifies the value difference between f(v_k) and f(v_{k'}) (by Eq. (2)), which in turn accelerates attention learning in Phase I. As a result, the duration T_f^1 decreases with both L and \\Delta .", "source": "marker_v2", "marker_block_id": "/page/7/Text/6"}
|
| 70 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0069", "section": "5.2 Convergence Dynamics under Flat L-Regime", "page_start": 8, "page_end": 8, "type": "Text", "text": "However, at t=T_f^1 , the prediction loss in Eq. (5) may still remain non-negligible. As a result, the attention score \\operatorname{Attn}_k^{(t)} requires a period of steady improvement after t=T_f^1+1 . We now formalize this behavior in the second training phase in the following proposition.", "source": "marker_v2", "marker_block_id": "/page/7/Text/7"}
|
| 71 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0070", "section": "5.2 Convergence Dynamics under Flat L-Regime", "page_start": 8, "page_end": 8, "type": "Text", "text": "Proposition 3 (Phase II: Steady growth of q_k^{(t)} under flat L-regime). For any t \\in \\{T_f^1+1,\\cdots,T_f^*\\} and 0 < \\epsilon < 1 , where T_f^* = \\Theta(\\frac{K \\log(K\\epsilon^{-1})}{\\eta \\delta^2 L^2 \\Delta^2}) , for any k \\in [K] , q_k^{(t)} continues to grow at a steady rate of \\Theta\\left(\\frac{\\eta \\delta^2 L^2 \\Delta^2}{K}\\right) . Meanwhile, q_{k,k'}^{(t)} oscillates at a slower rate of O\\left(\\frac{\\eta \\delta^2 L^2 \\Delta^2}{K^2}\\right) and exhibits an overall decreasing trend. At t = T_f^* + 1 , if L satisfies L \\leq \\Theta(\\frac{1}{\\Delta \\delta}) in Eq. (2), we have \\operatorname{Attn}_k^{(T_f^*+1)} = \\Omega(\\frac{1}{1+\\epsilon\\delta}) .", "source": "marker_v2", "marker_block_id": "/page/7/Text/8"}
|
| 72 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0071", "section": "5.2 Convergence Dynamics under Flat L-Regime", "page_start": 8, "page_end": 8, "type": "Text", "text": "The proof of Proposition 3 is given in Appendix E.2. According to Proposition 3, if the Lipschitz constant is sufficiently small such that L \\leq \\Theta(\\frac{1}{\\Delta\\delta}) , then by the end of Phase II, the attention score satisfies 1 - \\operatorname{Attn}_k^{(T_f^*+1)} = \\mathcal{O}\\left(\\frac{\\epsilon\\delta}{1+\\epsilon\\delta}\\right) = \\mathcal{O}(\\epsilon) , indicating that the transformer has converged.", "source": "marker_v2", "marker_block_id": "/page/7/Text/9"}
|
| 73 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0072", "section": "5.3 Phase Transition under Sharp L-Regime", "page_start": 8, "page_end": 8, "type": "Text", "text": "In the sharp curvature regime where L=\\Omega(\\frac{1}{\\Delta\\delta}) , the update q_k^{(t)} increases at a rate of \\Theta(\\frac{\\eta}{K}) for all t\\leq T_f^* . Let T_s^1 denote the duration of Phase I in this regime. Since this early-stage growth (Phase I) mirrors the dynamics under the flat L-regime before T_f^* , we have T_s^1=T_f^*=\\Theta(\\frac{K\\log(K\\epsilon^{-1})}{\\eta\\delta^2L^2\\Delta^2}) .", "source": "marker_v2", "marker_block_id": "/page/7/Text/11"}
|
| 74 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0073", "section": "5.3 Phase Transition under Sharp L-Regime", "page_start": 9, "page_end": 9, "type": "FigureGroup", "text": "set. L-set. flat <math>L=0.1. sharp L=1.", "source": "marker_v2", "marker_block_id": "/page/8/FigureGroup/386"}
|
| 75 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0074", "section": "5.3 Phase Transition under Sharp L-Regime", "page_start": 9, "page_end": 9, "type": "Caption", "text": "Figure 1: Training dynamics of prediction losses (top) and attention scores (bottom) for two sets of L: flat ( \\{0.1, 0.2, 0.4\\} ) and sharp ( \\{1.0, 1.5, 2.0\\} ).", "source": "marker_v2", "marker_block_id": "/page/8/Caption/3"}
|
| 76 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0075", "section": "5.3 Phase Transition under Sharp L-Regime", "page_start": 9, "page_end": 9, "type": "Text", "text": "However, this initial Phase is insufficient for achieving convergence due to the residual error term proportional to L \\cdot \\Delta in Eq. (9). Consequently, training transitions into a second phase (Phase III), during which both gradient terms g_k^{(t)} and g_{k,k'}^{(t)} become small. This leads to a slower growth rate of q_k^{(t)} compared to the earlier phase. We characterize this slower training phase as follows.", "source": "marker_v2", "marker_block_id": "/page/8/Text/4"}
|
| 77 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0076", "section": "5.3 Phase Transition under Sharp L-Regime", "page_start": 9, "page_end": 9, "type": "Text", "text": "Proposition 4 (Phase III: Slow growth of q_k^{(t)} under sharp L-regime). If L = \\Omega(\\frac{1}{\\Delta\\delta}) , then for any t \\in \\{T_s^1+1,\\cdots,T_s^*\\} and 0 < \\epsilon < 1 , where T_s^* = \\Theta(\\frac{K\\log(KL\\Delta\\epsilon^{-1})}{\\eta\\epsilon\\delta^2L^2\\Delta^2}) , for any k \\in [K] , q_k^{(t)} increases at a rate of \\Theta(\\frac{\\eta\\delta^2L^2\\Delta^2\\epsilon}{K}) . Meanwhile, q_{k,k'}^{(t)} fluctuates at a slower rate of O(\\frac{\\eta\\delta^2L^2\\Delta^2\\epsilon}{K^2}) . By the end of Phase II (i.e. t = T_s^* + 1 ), we have \\operatorname{Attn}_k^{(T_s^*+1)} = \\Omega(\\frac{1}{1+\\epsilon\\delta}) .", "source": "marker_v2", "marker_block_id": "/page/8/Text/5"}
|
| 78 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0077", "section": "5.3 Phase Transition under Sharp L-Regime", "page_start": 9, "page_end": 9, "type": "Text", "text": "The proof of Proposition 4 is given in Appendix F.1. To ensure convergence of the prediction loss, the update step size of q_k^{(t)} decreases to an order dependent on \\epsilon in Phase II. This is because, under the sharp L-regime where \\delta^2 L^2 \\Delta^2 = \\Omega(1) , the gradients become large, as established in Lemma 2. This phase transition further supports the convergence guarantee in Theorem 2, demonstrating that even under sharp curvature, the attention mechanism gradually concentrates on the correct feature vector, ultimately enabling accurate prediction.", "source": "marker_v2", "marker_block_id": "/page/8/Text/6"}
|
| 79 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0078", "section": "6 EXPERIMENTS VERIFICATION", "page_start": 9, "page_end": 9, "type": "Text", "text": "We adopt the data and task distributions from Section 3.1. Each data point is sampled from a fixed feature set v_k \\in \\mathbb{R}^d, k=1,\\ldots,K , with each feature v_k chosen uniformly at random, i.e., p_k=1/K . Each task involves learning a cosine function of the form f(x) = \\frac{L}{c} \\cdot \\cos(c \\cdot x) , where c>0 is a random constant and L is the Lipschitz constant, satisfying Eq. (2). Each prompt consists of N randomly sampled inputs \\{x_i\\}_{i=1}^N and corresponding outputs \\{y_i\\}_{i=1}^N = \\{f(x_i)\\}_{i=1}^N , along with a query token x_{\\text{query}} . We set the parameters as follows: d=15, K=4, N=100, c=0.5, and \\Delta=3 . We generate M=300 prompts and train the model for T=400 epochs. Appendix B presents additional experiments, including attention map dynamics, robustness check with non-uniform feature frequencies, polynomial-function tasks, and deeper transformers.", "source": "marker_v2", "marker_block_id": "/page/8/Text/8"}
|
| 80 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0079", "section": "6 EXPERIMENTS VERIFICATION", "page_start": 9, "page_end": 9, "type": "Text", "text": "We analyze a simplified transformer model comprising a single block with one-head self-attention and a feedforward network, incorporating layer normalization and ReLU activation, followed by a linear output layer. Our analysis focuses on two key metrics shown in Figure 1: (1) prediction loss dynamics and (2) attention score evolution, evaluated under flat ( \\{0.1, 0.2, 0.4\\} ) and sharp ( \\{1.0, 1.5, 2.0\\} ) curvature regimes. The prediction loss is computed as the average squared loss over prompts containing query token v_k . For attention scores, we track v_1 's self-attention score \\operatorname{Attn}_1^{(t)} and other features' attention scores \\operatorname{Attn}_{k-1}^{(t)} ( k \\in \\{2, 3, 4\\} ) on v_1 at each epoch.", "source": "marker_v2", "marker_block_id": "/page/8/Text/9"}
|
| 81 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0080", "section": "6 EXPERIMENTS VERIFICATION", "page_start": 9, "page_end": 9, "type": "Text", "text": "For flat L-regime, as shown in Figure 1(a) and Figure 1(c), we observe two distinct training phases. For example, with L=0.1, the prediction loss rapidly decreases to around 1.0 by epoch t=40, driven by increasing attention on the target feature shown in Figure 1(c). Subsequently, it steadily declines to near zero by t=250. At the same time, \\operatorname{Attn}_1^{(t)} approaches 1 under the transformer parameter \\theta . The convergence time shortens with increasing L due to stronger gradient updates, consistent with Theorem 1, Proposition 1, Proposition 2, and Proposition 3.", "source": "marker_v2", "marker_block_id": "/page/8/Text/10"}
|
| 82 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0081", "section": "6 EXPERIMENTS VERIFICATION", "page_start": 10, "page_end": 10, "type": "Text", "text": "As depicted in Figure 1(b) and Figure 1(d), the sharp L-regime exhibits different three training phases. Specifically, when L=1, the prediction loss drops rapidly to approximately 0.6 by t=30, then decreases steadily to around 0.1 by t=110. After that, it converges slowly toward 0 by t=200. The dynamics of the attention scores in Figure 1(d) exhibit the same three-phase progression. Additionally, under our experiment setting, the convergence upper bounds T_f^* in Theorem 1 and T_s^* in Theorem 2 satisfy T_f^* > T_s^* , indicating that the sharp regime achieves a faster convergence time. These empirical observations are consistent with our theoretical predictions in Theorem 2 and Proposition 4.", "source": "marker_v2", "marker_block_id": "/page/9/Text/1"}
|
| 83 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0082", "section": "7 CONCLUSIONS AND LIMITATIONS", "page_start": 10, "page_end": 10, "type": "Text", "text": "We presented provable results showing how transformers can learn a broad family of nonlinear tasks in context, identifying two distinct training regimes governed by task curvature. These findings illuminate the basic mechanisms-attention concentration and curvature-dependent gradient dynamics—that underpin ICL. By revealing how Lipschitz continuity and feature separation jointly determine convergence and generalization, our theory offers testable predictions for real-world settings (e.g., effects of task smoothness and feature geometry) and provides a principled starting point for extending formal guarantees to more realistic transformer architectures. Although our analysis focuses on a single-layer, single-head model, extending it to multi-head and multi-layer transformers presents substantial challenges due to intertwined cross-head gradients and the recursive evolution of representations across layers. Depth introduces residual connections and nonlinearities that couple representation learning with attention dynamics, making phase-wise analysis significantly more delicate. We view developing such extensions as an important direction for future work, and our curvature-sensitive framework provides a promising starting point.", "source": "marker_v2", "marker_block_id": "/page/9/Text/3"}
|
iclr26/2g8vgmyXgQ/marker_meta.json
ADDED
|
@@ -0,0 +1,1821 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"table_of_contents": [
|
| 3 |
+
{
|
| 4 |
+
"title": "PROVABLE IN-CONTEXT LEARNING OF NONLINEAR\nREGRESSION WITH TRANSFORMERS",
|
| 5 |
+
"heading_level": null,
|
| 6 |
+
"page_id": 0,
|
| 7 |
+
"polygon": [
|
| 8 |
+
[
|
| 9 |
+
107.578125,
|
| 10 |
+
79.6640625
|
| 11 |
+
],
|
| 12 |
+
[
|
| 13 |
+
503.5650939941406,
|
| 14 |
+
79.6640625
|
| 15 |
+
],
|
| 16 |
+
[
|
| 17 |
+
503.5650939941406,
|
| 18 |
+
117.53240966796875
|
| 19 |
+
],
|
| 20 |
+
[
|
| 21 |
+
107.578125,
|
| 22 |
+
117.53240966796875
|
| 23 |
+
]
|
| 24 |
+
]
|
| 25 |
+
},
|
| 26 |
+
{
|
| 27 |
+
"title": "ABSTRACT",
|
| 28 |
+
"heading_level": null,
|
| 29 |
+
"page_id": 0,
|
| 30 |
+
"polygon": [
|
| 31 |
+
[
|
| 32 |
+
277.013671875,
|
| 33 |
+
186.78515625
|
| 34 |
+
],
|
| 35 |
+
[
|
| 36 |
+
333.7167663574219,
|
| 37 |
+
186.78515625
|
| 38 |
+
],
|
| 39 |
+
[
|
| 40 |
+
333.7167663574219,
|
| 41 |
+
199.5054931640625
|
| 42 |
+
],
|
| 43 |
+
[
|
| 44 |
+
277.013671875,
|
| 45 |
+
199.5054931640625
|
| 46 |
+
]
|
| 47 |
+
]
|
| 48 |
+
},
|
| 49 |
+
{
|
| 50 |
+
"title": "1 INTRODUCTION",
|
| 51 |
+
"heading_level": null,
|
| 52 |
+
"page_id": 0,
|
| 53 |
+
"polygon": [
|
| 54 |
+
[
|
| 55 |
+
108.17578125,
|
| 56 |
+
434.3263244628906
|
| 57 |
+
],
|
| 58 |
+
[
|
| 59 |
+
205.99403381347656,
|
| 60 |
+
434.3263244628906
|
| 61 |
+
],
|
| 62 |
+
[
|
| 63 |
+
205.99403381347656,
|
| 64 |
+
446.2815246582031
|
| 65 |
+
],
|
| 66 |
+
[
|
| 67 |
+
108.17578125,
|
| 68 |
+
446.2815246582031
|
| 69 |
+
]
|
| 70 |
+
]
|
| 71 |
+
},
|
| 72 |
+
{
|
| 73 |
+
"title": "2 RELATED WORKS",
|
| 74 |
+
"heading_level": null,
|
| 75 |
+
"page_id": 1,
|
| 76 |
+
"polygon": [
|
| 77 |
+
[
|
| 78 |
+
107.279296875,
|
| 79 |
+
558.80859375
|
| 80 |
+
],
|
| 81 |
+
[
|
| 82 |
+
217.5,
|
| 83 |
+
558.80859375
|
| 84 |
+
],
|
| 85 |
+
[
|
| 86 |
+
217.5,
|
| 87 |
+
568.5
|
| 88 |
+
],
|
| 89 |
+
[
|
| 90 |
+
107.279296875,
|
| 91 |
+
568.5
|
| 92 |
+
]
|
| 93 |
+
]
|
| 94 |
+
},
|
| 95 |
+
{
|
| 96 |
+
"title": "3 System Model",
|
| 97 |
+
"heading_level": null,
|
| 98 |
+
"page_id": 2,
|
| 99 |
+
"polygon": [
|
| 100 |
+
[
|
| 101 |
+
106.681640625,
|
| 102 |
+
555.71484375
|
| 103 |
+
],
|
| 104 |
+
[
|
| 105 |
+
212.25,
|
| 106 |
+
555.71484375
|
| 107 |
+
],
|
| 108 |
+
[
|
| 109 |
+
212.25,
|
| 110 |
+
565.5
|
| 111 |
+
],
|
| 112 |
+
[
|
| 113 |
+
106.681640625,
|
| 114 |
+
565.5
|
| 115 |
+
]
|
| 116 |
+
]
|
| 117 |
+
},
|
| 118 |
+
{
|
| 119 |
+
"title": "3.1 IN-CONTEXT LEARNING PROBLEM SETUP",
|
| 120 |
+
"heading_level": null,
|
| 121 |
+
"page_id": 2,
|
| 122 |
+
"polygon": [
|
| 123 |
+
[
|
| 124 |
+
107.25,
|
| 125 |
+
614.25
|
| 126 |
+
],
|
| 127 |
+
[
|
| 128 |
+
312.0,
|
| 129 |
+
613.5
|
| 130 |
+
],
|
| 131 |
+
[
|
| 132 |
+
312.0,
|
| 133 |
+
623.00390625
|
| 134 |
+
],
|
| 135 |
+
[
|
| 136 |
+
107.25,
|
| 137 |
+
623.00390625
|
| 138 |
+
]
|
| 139 |
+
]
|
| 140 |
+
},
|
| 141 |
+
{
|
| 142 |
+
"title": "3.2 One-Layer Transformer",
|
| 143 |
+
"heading_level": null,
|
| 144 |
+
"page_id": 3,
|
| 145 |
+
"polygon": [
|
| 146 |
+
[
|
| 147 |
+
106.5,
|
| 148 |
+
493.83984375
|
| 149 |
+
],
|
| 150 |
+
[
|
| 151 |
+
252.75,
|
| 152 |
+
493.83984375
|
| 153 |
+
],
|
| 154 |
+
[
|
| 155 |
+
252.75,
|
| 156 |
+
504.0
|
| 157 |
+
],
|
| 158 |
+
[
|
| 159 |
+
106.5,
|
| 160 |
+
504.0
|
| 161 |
+
]
|
| 162 |
+
]
|
| 163 |
+
},
|
| 164 |
+
{
|
| 165 |
+
"title": "MAIN RESULTS OF ICL CONVERGENCE",
|
| 166 |
+
"heading_level": null,
|
| 167 |
+
"page_id": 4,
|
| 168 |
+
"polygon": [
|
| 169 |
+
[
|
| 170 |
+
108.7734375,
|
| 171 |
+
384.0
|
| 172 |
+
],
|
| 173 |
+
[
|
| 174 |
+
328.7109375,
|
| 175 |
+
384.0
|
| 176 |
+
],
|
| 177 |
+
[
|
| 178 |
+
328.7109375,
|
| 179 |
+
393.75
|
| 180 |
+
],
|
| 181 |
+
[
|
| 182 |
+
108.7734375,
|
| 183 |
+
393.75
|
| 184 |
+
]
|
| 185 |
+
]
|
| 186 |
+
},
|
| 187 |
+
{
|
| 188 |
+
"title": "ANALYSIS OF CONVERGENCE DYNAMICS",
|
| 189 |
+
"heading_level": null,
|
| 190 |
+
"page_id": 6,
|
| 191 |
+
"polygon": [
|
| 192 |
+
[
|
| 193 |
+
108.7734375,
|
| 194 |
+
266.0625
|
| 195 |
+
],
|
| 196 |
+
[
|
| 197 |
+
337.5,
|
| 198 |
+
266.0625
|
| 199 |
+
],
|
| 200 |
+
[
|
| 201 |
+
337.5,
|
| 202 |
+
276.75
|
| 203 |
+
],
|
| 204 |
+
[
|
| 205 |
+
108.7734375,
|
| 206 |
+
276.75
|
| 207 |
+
]
|
| 208 |
+
]
|
| 209 |
+
},
|
| 210 |
+
{
|
| 211 |
+
"title": "GRADIENTS OF ATTENTION WEIGHTS",
|
| 212 |
+
"heading_level": null,
|
| 213 |
+
"page_id": 6,
|
| 214 |
+
"polygon": [
|
| 215 |
+
[
|
| 216 |
+
105.78515625,
|
| 217 |
+
336.4453125
|
| 218 |
+
],
|
| 219 |
+
[
|
| 220 |
+
293.25,
|
| 221 |
+
336.4453125
|
| 222 |
+
],
|
| 223 |
+
[
|
| 224 |
+
293.25,
|
| 225 |
+
345.75
|
| 226 |
+
],
|
| 227 |
+
[
|
| 228 |
+
105.78515625,
|
| 229 |
+
345.75
|
| 230 |
+
]
|
| 231 |
+
]
|
| 232 |
+
},
|
| 233 |
+
{
|
| 234 |
+
"title": "5.2 Convergence Dynamics under Flat L-Regime",
|
| 235 |
+
"heading_level": null,
|
| 236 |
+
"page_id": 7,
|
| 237 |
+
"polygon": [
|
| 238 |
+
[
|
| 239 |
+
106.98046875,
|
| 240 |
+
151.98046875
|
| 241 |
+
],
|
| 242 |
+
[
|
| 243 |
+
352.5,
|
| 244 |
+
151.98046875
|
| 245 |
+
],
|
| 246 |
+
[
|
| 247 |
+
352.5,
|
| 248 |
+
161.25
|
| 249 |
+
],
|
| 250 |
+
[
|
| 251 |
+
106.98046875,
|
| 252 |
+
161.25
|
| 253 |
+
]
|
| 254 |
+
]
|
| 255 |
+
},
|
| 256 |
+
{
|
| 257 |
+
"title": "5.3 Phase Transition under Sharp L-Regime",
|
| 258 |
+
"heading_level": null,
|
| 259 |
+
"page_id": 7,
|
| 260 |
+
"polygon": [
|
| 261 |
+
[
|
| 262 |
+
107.25,
|
| 263 |
+
667.08984375
|
| 264 |
+
],
|
| 265 |
+
[
|
| 266 |
+
329.25,
|
| 267 |
+
667.08984375
|
| 268 |
+
],
|
| 269 |
+
[
|
| 270 |
+
329.25,
|
| 271 |
+
676.5
|
| 272 |
+
],
|
| 273 |
+
[
|
| 274 |
+
107.25,
|
| 275 |
+
676.5
|
| 276 |
+
]
|
| 277 |
+
]
|
| 278 |
+
},
|
| 279 |
+
{
|
| 280 |
+
"title": "6 EXPERIMENTS VERIFICATION",
|
| 281 |
+
"heading_level": null,
|
| 282 |
+
"page_id": 8,
|
| 283 |
+
"polygon": [
|
| 284 |
+
[
|
| 285 |
+
107.578125,
|
| 286 |
+
444.33984375
|
| 287 |
+
],
|
| 288 |
+
[
|
| 289 |
+
277.5,
|
| 290 |
+
444.33984375
|
| 291 |
+
],
|
| 292 |
+
[
|
| 293 |
+
277.5,
|
| 294 |
+
456.0
|
| 295 |
+
],
|
| 296 |
+
[
|
| 297 |
+
107.578125,
|
| 298 |
+
456.0
|
| 299 |
+
]
|
| 300 |
+
]
|
| 301 |
+
},
|
| 302 |
+
{
|
| 303 |
+
"title": "7 CONCLUSIONS AND LIMITATIONS",
|
| 304 |
+
"heading_level": null,
|
| 305 |
+
"page_id": 9,
|
| 306 |
+
"polygon": [
|
| 307 |
+
[
|
| 308 |
+
108.17578125,
|
| 309 |
+
175.18359375
|
| 310 |
+
],
|
| 311 |
+
[
|
| 312 |
+
297.75,
|
| 313 |
+
175.18359375
|
| 314 |
+
],
|
| 315 |
+
[
|
| 316 |
+
297.75,
|
| 317 |
+
186.0
|
| 318 |
+
],
|
| 319 |
+
[
|
| 320 |
+
108.17578125,
|
| 321 |
+
186.0
|
| 322 |
+
]
|
| 323 |
+
]
|
| 324 |
+
},
|
| 325 |
+
{
|
| 326 |
+
"title": "REPRODUCIBILITY STATEMENT",
|
| 327 |
+
"heading_level": null,
|
| 328 |
+
"page_id": 9,
|
| 329 |
+
"polygon": [
|
| 330 |
+
[
|
| 331 |
+
106.98046875,
|
| 332 |
+
354.62109375
|
| 333 |
+
],
|
| 334 |
+
[
|
| 335 |
+
269.25,
|
| 336 |
+
354.62109375
|
| 337 |
+
],
|
| 338 |
+
[
|
| 339 |
+
269.25,
|
| 340 |
+
363.12890625
|
| 341 |
+
],
|
| 342 |
+
[
|
| 343 |
+
106.98046875,
|
| 344 |
+
363.12890625
|
| 345 |
+
]
|
| 346 |
+
]
|
| 347 |
+
},
|
| 348 |
+
{
|
| 349 |
+
"title": "REFERENCES",
|
| 350 |
+
"heading_level": null,
|
| 351 |
+
"page_id": 9,
|
| 352 |
+
"polygon": [
|
| 353 |
+
[
|
| 354 |
+
107.25,
|
| 355 |
+
500.02734375
|
| 356 |
+
],
|
| 357 |
+
[
|
| 358 |
+
175.5,
|
| 359 |
+
500.02734375
|
| 360 |
+
],
|
| 361 |
+
[
|
| 362 |
+
175.5,
|
| 363 |
+
510.0
|
| 364 |
+
],
|
| 365 |
+
[
|
| 366 |
+
107.25,
|
| 367 |
+
510.0
|
| 368 |
+
]
|
| 369 |
+
]
|
| 370 |
+
},
|
| 371 |
+
{
|
| 372 |
+
"title": "A THE USE OF LLMS FOR POLISHING WRITING",
|
| 373 |
+
"heading_level": null,
|
| 374 |
+
"page_id": 14,
|
| 375 |
+
"polygon": [
|
| 376 |
+
[
|
| 377 |
+
106.3828125,
|
| 378 |
+
224.25
|
| 379 |
+
],
|
| 380 |
+
[
|
| 381 |
+
362.25,
|
| 382 |
+
224.25
|
| 383 |
+
],
|
| 384 |
+
[
|
| 385 |
+
362.25,
|
| 386 |
+
233.25
|
| 387 |
+
],
|
| 388 |
+
[
|
| 389 |
+
106.3828125,
|
| 390 |
+
233.25
|
| 391 |
+
]
|
| 392 |
+
]
|
| 393 |
+
},
|
| 394 |
+
{
|
| 395 |
+
"title": "B ADDITIONAL EXPERIMENTAL RESULTS",
|
| 396 |
+
"heading_level": null,
|
| 397 |
+
"page_id": 14,
|
| 398 |
+
"polygon": [
|
| 399 |
+
[
|
| 400 |
+
106.98046875,
|
| 401 |
+
323.68359375
|
| 402 |
+
],
|
| 403 |
+
[
|
| 404 |
+
328.5,
|
| 405 |
+
323.68359375
|
| 406 |
+
],
|
| 407 |
+
[
|
| 408 |
+
328.5,
|
| 409 |
+
334.5
|
| 410 |
+
],
|
| 411 |
+
[
|
| 412 |
+
106.98046875,
|
| 413 |
+
334.5
|
| 414 |
+
]
|
| 415 |
+
]
|
| 416 |
+
},
|
| 417 |
+
{
|
| 418 |
+
"title": "C PROOF OF LEMMA 1",
|
| 419 |
+
"heading_level": null,
|
| 420 |
+
"page_id": 16,
|
| 421 |
+
"polygon": [
|
| 422 |
+
[
|
| 423 |
+
107.578125,
|
| 424 |
+
345.33984375
|
| 425 |
+
],
|
| 426 |
+
[
|
| 427 |
+
231.0,
|
| 428 |
+
345.33984375
|
| 429 |
+
],
|
| 430 |
+
[
|
| 431 |
+
231.0,
|
| 432 |
+
356.25
|
| 433 |
+
],
|
| 434 |
+
[
|
| 435 |
+
107.578125,
|
| 436 |
+
356.25
|
| 437 |
+
]
|
| 438 |
+
]
|
| 439 |
+
},
|
| 440 |
+
{
|
| 441 |
+
"title": "D Proof of Lemma 2",
|
| 442 |
+
"heading_level": null,
|
| 443 |
+
"page_id": 17,
|
| 444 |
+
"polygon": [
|
| 445 |
+
[
|
| 446 |
+
107.578125,
|
| 447 |
+
121.5
|
| 448 |
+
],
|
| 449 |
+
[
|
| 450 |
+
232.5,
|
| 451 |
+
121.5
|
| 452 |
+
],
|
| 453 |
+
[
|
| 454 |
+
232.5,
|
| 455 |
+
132.0
|
| 456 |
+
],
|
| 457 |
+
[
|
| 458 |
+
107.578125,
|
| 459 |
+
132.0
|
| 460 |
+
]
|
| 461 |
+
]
|
| 462 |
+
},
|
| 463 |
+
{
|
| 464 |
+
"title": "E PROOFS FOR FLAT L-REGIME",
|
| 465 |
+
"heading_level": null,
|
| 466 |
+
"page_id": 18,
|
| 467 |
+
"polygon": [
|
| 468 |
+
[
|
| 469 |
+
107.578125,
|
| 470 |
+
355.78125
|
| 471 |
+
],
|
| 472 |
+
[
|
| 473 |
+
279.0,
|
| 474 |
+
355.78125
|
| 475 |
+
],
|
| 476 |
+
[
|
| 477 |
+
279.0,
|
| 478 |
+
365.25
|
| 479 |
+
],
|
| 480 |
+
[
|
| 481 |
+
107.578125,
|
| 482 |
+
365.25
|
| 483 |
+
]
|
| 484 |
+
]
|
| 485 |
+
},
|
| 486 |
+
{
|
| 487 |
+
"title": "E.1 Proof of Proposition 2",
|
| 488 |
+
"heading_level": null,
|
| 489 |
+
"page_id": 18,
|
| 490 |
+
"polygon": [
|
| 491 |
+
[
|
| 492 |
+
106.681640625,
|
| 493 |
+
380.25
|
| 494 |
+
],
|
| 495 |
+
[
|
| 496 |
+
244.740234375,
|
| 497 |
+
380.25
|
| 498 |
+
],
|
| 499 |
+
[
|
| 500 |
+
244.740234375,
|
| 501 |
+
389.25
|
| 502 |
+
],
|
| 503 |
+
[
|
| 504 |
+
106.681640625,
|
| 505 |
+
389.25
|
| 506 |
+
]
|
| 507 |
+
]
|
| 508 |
+
},
|
| 509 |
+
{
|
| 510 |
+
"title": "E.2 PROOF OF PROPOSITION 3",
|
| 511 |
+
"heading_level": null,
|
| 512 |
+
"page_id": 20,
|
| 513 |
+
"polygon": [
|
| 514 |
+
[
|
| 515 |
+
107.578125,
|
| 516 |
+
512.40234375
|
| 517 |
+
],
|
| 518 |
+
[
|
| 519 |
+
243.84375,
|
| 520 |
+
512.40234375
|
| 521 |
+
],
|
| 522 |
+
[
|
| 523 |
+
243.84375,
|
| 524 |
+
522.0
|
| 525 |
+
],
|
| 526 |
+
[
|
| 527 |
+
107.578125,
|
| 528 |
+
522.0
|
| 529 |
+
]
|
| 530 |
+
]
|
| 531 |
+
},
|
| 532 |
+
{
|
| 533 |
+
"title": "E.3 PROOF OF THEOREM 1",
|
| 534 |
+
"heading_level": null,
|
| 535 |
+
"page_id": 22,
|
| 536 |
+
"polygon": [
|
| 537 |
+
[
|
| 538 |
+
105.78515625,
|
| 539 |
+
477.0
|
| 540 |
+
],
|
| 541 |
+
[
|
| 542 |
+
228.75,
|
| 543 |
+
477.0
|
| 544 |
+
],
|
| 545 |
+
[
|
| 546 |
+
228.75,
|
| 547 |
+
486.87890625
|
| 548 |
+
],
|
| 549 |
+
[
|
| 550 |
+
105.78515625,
|
| 551 |
+
486.87890625
|
| 552 |
+
]
|
| 553 |
+
]
|
| 554 |
+
},
|
| 555 |
+
{
|
| 556 |
+
"title": "F PROOFS FOR SHARP L-REGIME",
|
| 557 |
+
"heading_level": null,
|
| 558 |
+
"page_id": 23,
|
| 559 |
+
"polygon": [
|
| 560 |
+
[
|
| 561 |
+
105.1875,
|
| 562 |
+
80.82421875
|
| 563 |
+
],
|
| 564 |
+
[
|
| 565 |
+
286.875,
|
| 566 |
+
80.82421875
|
| 567 |
+
],
|
| 568 |
+
[
|
| 569 |
+
286.875,
|
| 570 |
+
92.25
|
| 571 |
+
],
|
| 572 |
+
[
|
| 573 |
+
105.1875,
|
| 574 |
+
92.25
|
| 575 |
+
]
|
| 576 |
+
]
|
| 577 |
+
},
|
| 578 |
+
{
|
| 579 |
+
"title": "F.1 Proof of Proposition 4",
|
| 580 |
+
"heading_level": null,
|
| 581 |
+
"page_id": 23,
|
| 582 |
+
"polygon": [
|
| 583 |
+
[
|
| 584 |
+
105.1875,
|
| 585 |
+
107.25
|
| 586 |
+
],
|
| 587 |
+
[
|
| 588 |
+
242.25,
|
| 589 |
+
107.25
|
| 590 |
+
],
|
| 591 |
+
[
|
| 592 |
+
242.25,
|
| 593 |
+
116.40234375
|
| 594 |
+
],
|
| 595 |
+
[
|
| 596 |
+
105.1875,
|
| 597 |
+
116.40234375
|
| 598 |
+
]
|
| 599 |
+
]
|
| 600 |
+
},
|
| 601 |
+
{
|
| 602 |
+
"title": "F.2 PROOF OF THEOREM 2",
|
| 603 |
+
"heading_level": null,
|
| 604 |
+
"page_id": 24,
|
| 605 |
+
"polygon": [
|
| 606 |
+
[
|
| 607 |
+
104.291015625,
|
| 608 |
+
303.9609375
|
| 609 |
+
],
|
| 610 |
+
[
|
| 611 |
+
228.75,
|
| 612 |
+
303.9609375
|
| 613 |
+
],
|
| 614 |
+
[
|
| 615 |
+
228.75,
|
| 616 |
+
313.5
|
| 617 |
+
],
|
| 618 |
+
[
|
| 619 |
+
104.291015625,
|
| 620 |
+
313.5
|
| 621 |
+
]
|
| 622 |
+
]
|
| 623 |
+
},
|
| 624 |
+
{
|
| 625 |
+
"title": "PROOF OF PROPOSITION 1",
|
| 626 |
+
"heading_level": null,
|
| 627 |
+
"page_id": 24,
|
| 628 |
+
"polygon": [
|
| 629 |
+
[
|
| 630 |
+
106.98046875,
|
| 631 |
+
521.68359375
|
| 632 |
+
],
|
| 633 |
+
[
|
| 634 |
+
261.17578125,
|
| 635 |
+
521.68359375
|
| 636 |
+
],
|
| 637 |
+
[
|
| 638 |
+
261.17578125,
|
| 639 |
+
531.75
|
| 640 |
+
],
|
| 641 |
+
[
|
| 642 |
+
106.98046875,
|
| 643 |
+
531.75
|
| 644 |
+
]
|
| 645 |
+
]
|
| 646 |
+
}
|
| 647 |
+
],
|
| 648 |
+
"page_stats": [
|
| 649 |
+
{
|
| 650 |
+
"page_id": 0,
|
| 651 |
+
"text_extraction_method": "pdftext",
|
| 652 |
+
"block_counts": [
|
| 653 |
+
[
|
| 654 |
+
"Span",
|
| 655 |
+
248
|
| 656 |
+
],
|
| 657 |
+
[
|
| 658 |
+
"Line",
|
| 659 |
+
88
|
| 660 |
+
],
|
| 661 |
+
[
|
| 662 |
+
"Text",
|
| 663 |
+
14
|
| 664 |
+
],
|
| 665 |
+
[
|
| 666 |
+
"SectionHeader",
|
| 667 |
+
3
|
| 668 |
+
],
|
| 669 |
+
[
|
| 670 |
+
"PageHeader",
|
| 671 |
+
1
|
| 672 |
+
],
|
| 673 |
+
[
|
| 674 |
+
"PageFooter",
|
| 675 |
+
1
|
| 676 |
+
]
|
| 677 |
+
],
|
| 678 |
+
"block_metadata": {
|
| 679 |
+
"llm_request_count": 0,
|
| 680 |
+
"llm_error_count": 0,
|
| 681 |
+
"llm_tokens_used": 0,
|
| 682 |
+
"previous_text": "",
|
| 683 |
+
"previous_type": "",
|
| 684 |
+
"previous_order": 0
|
| 685 |
+
}
|
| 686 |
+
},
|
| 687 |
+
{
|
| 688 |
+
"page_id": 1,
|
| 689 |
+
"text_extraction_method": "surya",
|
| 690 |
+
"block_counts": [
|
| 691 |
+
[
|
| 692 |
+
"Line",
|
| 693 |
+
117
|
| 694 |
+
],
|
| 695 |
+
[
|
| 696 |
+
"Span",
|
| 697 |
+
54
|
| 698 |
+
],
|
| 699 |
+
[
|
| 700 |
+
"Text",
|
| 701 |
+
28
|
| 702 |
+
],
|
| 703 |
+
[
|
| 704 |
+
"ListItem",
|
| 705 |
+
4
|
| 706 |
+
],
|
| 707 |
+
[
|
| 708 |
+
"PageHeader",
|
| 709 |
+
1
|
| 710 |
+
],
|
| 711 |
+
[
|
| 712 |
+
"SectionHeader",
|
| 713 |
+
1
|
| 714 |
+
],
|
| 715 |
+
[
|
| 716 |
+
"PageFooter",
|
| 717 |
+
1
|
| 718 |
+
],
|
| 719 |
+
[
|
| 720 |
+
"ListGroup",
|
| 721 |
+
1
|
| 722 |
+
]
|
| 723 |
+
],
|
| 724 |
+
"block_metadata": {
|
| 725 |
+
"llm_request_count": 0,
|
| 726 |
+
"llm_error_count": 0,
|
| 727 |
+
"llm_tokens_used": 0,
|
| 728 |
+
"previous_text": "",
|
| 729 |
+
"previous_type": "",
|
| 730 |
+
"previous_order": 0
|
| 731 |
+
}
|
| 732 |
+
},
|
| 733 |
+
{
|
| 734 |
+
"page_id": 2,
|
| 735 |
+
"text_extraction_method": "surya",
|
| 736 |
+
"block_counts": [
|
| 737 |
+
[
|
| 738 |
+
"Line",
|
| 739 |
+
163
|
| 740 |
+
],
|
| 741 |
+
[
|
| 742 |
+
"Span",
|
| 743 |
+
130
|
| 744 |
+
],
|
| 745 |
+
[
|
| 746 |
+
"Text",
|
| 747 |
+
51
|
| 748 |
+
],
|
| 749 |
+
[
|
| 750 |
+
"SectionHeader",
|
| 751 |
+
2
|
| 752 |
+
],
|
| 753 |
+
[
|
| 754 |
+
"Reference",
|
| 755 |
+
2
|
| 756 |
+
],
|
| 757 |
+
[
|
| 758 |
+
"PageHeader",
|
| 759 |
+
1
|
| 760 |
+
],
|
| 761 |
+
[
|
| 762 |
+
"PageFooter",
|
| 763 |
+
1
|
| 764 |
+
]
|
| 765 |
+
],
|
| 766 |
+
"block_metadata": {
|
| 767 |
+
"llm_request_count": 0,
|
| 768 |
+
"llm_error_count": 0,
|
| 769 |
+
"llm_tokens_used": 0,
|
| 770 |
+
"previous_text": "",
|
| 771 |
+
"previous_type": "",
|
| 772 |
+
"previous_order": 0
|
| 773 |
+
}
|
| 774 |
+
},
|
| 775 |
+
{
|
| 776 |
+
"page_id": 3,
|
| 777 |
+
"text_extraction_method": "surya",
|
| 778 |
+
"block_counts": [
|
| 779 |
+
[
|
| 780 |
+
"Span",
|
| 781 |
+
146
|
| 782 |
+
],
|
| 783 |
+
[
|
| 784 |
+
"Line",
|
| 785 |
+
145
|
| 786 |
+
],
|
| 787 |
+
[
|
| 788 |
+
"Text",
|
| 789 |
+
47
|
| 790 |
+
],
|
| 791 |
+
[
|
| 792 |
+
"Equation",
|
| 793 |
+
4
|
| 794 |
+
],
|
| 795 |
+
[
|
| 796 |
+
"Reference",
|
| 797 |
+
2
|
| 798 |
+
],
|
| 799 |
+
[
|
| 800 |
+
"PageHeader",
|
| 801 |
+
1
|
| 802 |
+
],
|
| 803 |
+
[
|
| 804 |
+
"SectionHeader",
|
| 805 |
+
1
|
| 806 |
+
],
|
| 807 |
+
[
|
| 808 |
+
"PageFooter",
|
| 809 |
+
1
|
| 810 |
+
]
|
| 811 |
+
],
|
| 812 |
+
"block_metadata": {
|
| 813 |
+
"llm_request_count": 0,
|
| 814 |
+
"llm_error_count": 0,
|
| 815 |
+
"llm_tokens_used": 0,
|
| 816 |
+
"previous_text": "",
|
| 817 |
+
"previous_type": "",
|
| 818 |
+
"previous_order": 0
|
| 819 |
+
}
|
| 820 |
+
},
|
| 821 |
+
{
|
| 822 |
+
"page_id": 4,
|
| 823 |
+
"text_extraction_method": "surya",
|
| 824 |
+
"block_counts": [
|
| 825 |
+
[
|
| 826 |
+
"Span",
|
| 827 |
+
167
|
| 828 |
+
],
|
| 829 |
+
[
|
| 830 |
+
"Line",
|
| 831 |
+
97
|
| 832 |
+
],
|
| 833 |
+
[
|
| 834 |
+
"Text",
|
| 835 |
+
46
|
| 836 |
+
],
|
| 837 |
+
[
|
| 838 |
+
"Equation",
|
| 839 |
+
4
|
| 840 |
+
],
|
| 841 |
+
[
|
| 842 |
+
"Reference",
|
| 843 |
+
2
|
| 844 |
+
],
|
| 845 |
+
[
|
| 846 |
+
"PageHeader",
|
| 847 |
+
1
|
| 848 |
+
],
|
| 849 |
+
[
|
| 850 |
+
"SectionHeader",
|
| 851 |
+
1
|
| 852 |
+
],
|
| 853 |
+
[
|
| 854 |
+
"PageFooter",
|
| 855 |
+
1
|
| 856 |
+
]
|
| 857 |
+
],
|
| 858 |
+
"block_metadata": {
|
| 859 |
+
"llm_request_count": 0,
|
| 860 |
+
"llm_error_count": 0,
|
| 861 |
+
"llm_tokens_used": 0,
|
| 862 |
+
"previous_text": "",
|
| 863 |
+
"previous_type": "",
|
| 864 |
+
"previous_order": 0
|
| 865 |
+
}
|
| 866 |
+
},
|
| 867 |
+
{
|
| 868 |
+
"page_id": 5,
|
| 869 |
+
"text_extraction_method": "surya",
|
| 870 |
+
"block_counts": [
|
| 871 |
+
[
|
| 872 |
+
"Span",
|
| 873 |
+
187
|
| 874 |
+
],
|
| 875 |
+
[
|
| 876 |
+
"Line",
|
| 877 |
+
92
|
| 878 |
+
],
|
| 879 |
+
[
|
| 880 |
+
"Text",
|
| 881 |
+
47
|
| 882 |
+
],
|
| 883 |
+
[
|
| 884 |
+
"Reference",
|
| 885 |
+
5
|
| 886 |
+
],
|
| 887 |
+
[
|
| 888 |
+
"Equation",
|
| 889 |
+
2
|
| 890 |
+
],
|
| 891 |
+
[
|
| 892 |
+
"PageHeader",
|
| 893 |
+
1
|
| 894 |
+
],
|
| 895 |
+
[
|
| 896 |
+
"PageFooter",
|
| 897 |
+
1
|
| 898 |
+
]
|
| 899 |
+
],
|
| 900 |
+
"block_metadata": {
|
| 901 |
+
"llm_request_count": 0,
|
| 902 |
+
"llm_error_count": 0,
|
| 903 |
+
"llm_tokens_used": 0,
|
| 904 |
+
"previous_text": "",
|
| 905 |
+
"previous_type": "",
|
| 906 |
+
"previous_order": 0
|
| 907 |
+
}
|
| 908 |
+
},
|
| 909 |
+
{
|
| 910 |
+
"page_id": 6,
|
| 911 |
+
"text_extraction_method": "surya",
|
| 912 |
+
"block_counts": [
|
| 913 |
+
[
|
| 914 |
+
"Span",
|
| 915 |
+
189
|
| 916 |
+
],
|
| 917 |
+
[
|
| 918 |
+
"Line",
|
| 919 |
+
90
|
| 920 |
+
],
|
| 921 |
+
[
|
| 922 |
+
"Text",
|
| 923 |
+
47
|
| 924 |
+
],
|
| 925 |
+
[
|
| 926 |
+
"Reference",
|
| 927 |
+
5
|
| 928 |
+
],
|
| 929 |
+
[
|
| 930 |
+
"Equation",
|
| 931 |
+
3
|
| 932 |
+
],
|
| 933 |
+
[
|
| 934 |
+
"SectionHeader",
|
| 935 |
+
2
|
| 936 |
+
],
|
| 937 |
+
[
|
| 938 |
+
"PageHeader",
|
| 939 |
+
1
|
| 940 |
+
],
|
| 941 |
+
[
|
| 942 |
+
"PageFooter",
|
| 943 |
+
1
|
| 944 |
+
]
|
| 945 |
+
],
|
| 946 |
+
"block_metadata": {
|
| 947 |
+
"llm_request_count": 0,
|
| 948 |
+
"llm_error_count": 0,
|
| 949 |
+
"llm_tokens_used": 0,
|
| 950 |
+
"previous_text": "",
|
| 951 |
+
"previous_type": "",
|
| 952 |
+
"previous_order": 0
|
| 953 |
+
}
|
| 954 |
+
},
|
| 955 |
+
{
|
| 956 |
+
"page_id": 7,
|
| 957 |
+
"text_extraction_method": "surya",
|
| 958 |
+
"block_counts": [
|
| 959 |
+
[
|
| 960 |
+
"Span",
|
| 961 |
+
207
|
| 962 |
+
],
|
| 963 |
+
[
|
| 964 |
+
"Line",
|
| 965 |
+
145
|
| 966 |
+
],
|
| 967 |
+
[
|
| 968 |
+
"Text",
|
| 969 |
+
44
|
| 970 |
+
],
|
| 971 |
+
[
|
| 972 |
+
"SectionHeader",
|
| 973 |
+
2
|
| 974 |
+
],
|
| 975 |
+
[
|
| 976 |
+
"Reference",
|
| 977 |
+
2
|
| 978 |
+
],
|
| 979 |
+
[
|
| 980 |
+
"PageHeader",
|
| 981 |
+
1
|
| 982 |
+
],
|
| 983 |
+
[
|
| 984 |
+
"PageFooter",
|
| 985 |
+
1
|
| 986 |
+
]
|
| 987 |
+
],
|
| 988 |
+
"block_metadata": {
|
| 989 |
+
"llm_request_count": 0,
|
| 990 |
+
"llm_error_count": 0,
|
| 991 |
+
"llm_tokens_used": 0,
|
| 992 |
+
"previous_text": "",
|
| 993 |
+
"previous_type": "",
|
| 994 |
+
"previous_order": 0
|
| 995 |
+
}
|
| 996 |
+
},
|
| 997 |
+
{
|
| 998 |
+
"page_id": 8,
|
| 999 |
+
"text_extraction_method": "surya",
|
| 1000 |
+
"block_counts": [
|
| 1001 |
+
[
|
| 1002 |
+
"Span",
|
| 1003 |
+
177
|
| 1004 |
+
],
|
| 1005 |
+
[
|
| 1006 |
+
"Line",
|
| 1007 |
+
160
|
| 1008 |
+
],
|
| 1009 |
+
[
|
| 1010 |
+
"Text",
|
| 1011 |
+
43
|
| 1012 |
+
],
|
| 1013 |
+
[
|
| 1014 |
+
"Reference",
|
| 1015 |
+
7
|
| 1016 |
+
],
|
| 1017 |
+
[
|
| 1018 |
+
"Caption",
|
| 1019 |
+
2
|
| 1020 |
+
],
|
| 1021 |
+
[
|
| 1022 |
+
"PageHeader",
|
| 1023 |
+
1
|
| 1024 |
+
],
|
| 1025 |
+
[
|
| 1026 |
+
"Figure",
|
| 1027 |
+
1
|
| 1028 |
+
],
|
| 1029 |
+
[
|
| 1030 |
+
"SectionHeader",
|
| 1031 |
+
1
|
| 1032 |
+
],
|
| 1033 |
+
[
|
| 1034 |
+
"PageFooter",
|
| 1035 |
+
1
|
| 1036 |
+
],
|
| 1037 |
+
[
|
| 1038 |
+
"FigureGroup",
|
| 1039 |
+
1
|
| 1040 |
+
]
|
| 1041 |
+
],
|
| 1042 |
+
"block_metadata": {
|
| 1043 |
+
"llm_request_count": 0,
|
| 1044 |
+
"llm_error_count": 0,
|
| 1045 |
+
"llm_tokens_used": 0,
|
| 1046 |
+
"previous_text": "",
|
| 1047 |
+
"previous_type": "",
|
| 1048 |
+
"previous_order": 0
|
| 1049 |
+
}
|
| 1050 |
+
},
|
| 1051 |
+
{
|
| 1052 |
+
"page_id": 9,
|
| 1053 |
+
"text_extraction_method": "surya",
|
| 1054 |
+
"block_counts": [
|
| 1055 |
+
[
|
| 1056 |
+
"Line",
|
| 1057 |
+
161
|
| 1058 |
+
],
|
| 1059 |
+
[
|
| 1060 |
+
"Span",
|
| 1061 |
+
93
|
| 1062 |
+
],
|
| 1063 |
+
[
|
| 1064 |
+
"Text",
|
| 1065 |
+
45
|
| 1066 |
+
],
|
| 1067 |
+
[
|
| 1068 |
+
"Reference",
|
| 1069 |
+
6
|
| 1070 |
+
],
|
| 1071 |
+
[
|
| 1072 |
+
"ListItem",
|
| 1073 |
+
5
|
| 1074 |
+
],
|
| 1075 |
+
[
|
| 1076 |
+
"SectionHeader",
|
| 1077 |
+
3
|
| 1078 |
+
],
|
| 1079 |
+
[
|
| 1080 |
+
"PageHeader",
|
| 1081 |
+
1
|
| 1082 |
+
],
|
| 1083 |
+
[
|
| 1084 |
+
"PageFooter",
|
| 1085 |
+
1
|
| 1086 |
+
],
|
| 1087 |
+
[
|
| 1088 |
+
"ListGroup",
|
| 1089 |
+
1
|
| 1090 |
+
]
|
| 1091 |
+
],
|
| 1092 |
+
"block_metadata": {
|
| 1093 |
+
"llm_request_count": 0,
|
| 1094 |
+
"llm_error_count": 0,
|
| 1095 |
+
"llm_tokens_used": 0,
|
| 1096 |
+
"previous_text": "",
|
| 1097 |
+
"previous_type": "",
|
| 1098 |
+
"previous_order": 0
|
| 1099 |
+
}
|
| 1100 |
+
},
|
| 1101 |
+
{
|
| 1102 |
+
"page_id": 10,
|
| 1103 |
+
"text_extraction_method": "pdftext",
|
| 1104 |
+
"block_counts": [
|
| 1105 |
+
[
|
| 1106 |
+
"Span",
|
| 1107 |
+
225
|
| 1108 |
+
],
|
| 1109 |
+
[
|
| 1110 |
+
"Line",
|
| 1111 |
+
88
|
| 1112 |
+
],
|
| 1113 |
+
[
|
| 1114 |
+
"ListItem",
|
| 1115 |
+
17
|
| 1116 |
+
],
|
| 1117 |
+
[
|
| 1118 |
+
"Reference",
|
| 1119 |
+
17
|
| 1120 |
+
],
|
| 1121 |
+
[
|
| 1122 |
+
"Text",
|
| 1123 |
+
8
|
| 1124 |
+
],
|
| 1125 |
+
[
|
| 1126 |
+
"PageHeader",
|
| 1127 |
+
1
|
| 1128 |
+
],
|
| 1129 |
+
[
|
| 1130 |
+
"PageFooter",
|
| 1131 |
+
1
|
| 1132 |
+
],
|
| 1133 |
+
[
|
| 1134 |
+
"ListGroup",
|
| 1135 |
+
1
|
| 1136 |
+
]
|
| 1137 |
+
],
|
| 1138 |
+
"block_metadata": {
|
| 1139 |
+
"llm_request_count": 0,
|
| 1140 |
+
"llm_error_count": 0,
|
| 1141 |
+
"llm_tokens_used": 0,
|
| 1142 |
+
"previous_text": "",
|
| 1143 |
+
"previous_type": "",
|
| 1144 |
+
"previous_order": 0
|
| 1145 |
+
}
|
| 1146 |
+
},
|
| 1147 |
+
{
|
| 1148 |
+
"page_id": 11,
|
| 1149 |
+
"text_extraction_method": "pdftext",
|
| 1150 |
+
"block_counts": [
|
| 1151 |
+
[
|
| 1152 |
+
"Span",
|
| 1153 |
+
227
|
| 1154 |
+
],
|
| 1155 |
+
[
|
| 1156 |
+
"Line",
|
| 1157 |
+
91
|
| 1158 |
+
],
|
| 1159 |
+
[
|
| 1160 |
+
"ListItem",
|
| 1161 |
+
18
|
| 1162 |
+
],
|
| 1163 |
+
[
|
| 1164 |
+
"Reference",
|
| 1165 |
+
18
|
| 1166 |
+
],
|
| 1167 |
+
[
|
| 1168 |
+
"Text",
|
| 1169 |
+
9
|
| 1170 |
+
],
|
| 1171 |
+
[
|
| 1172 |
+
"PageHeader",
|
| 1173 |
+
1
|
| 1174 |
+
],
|
| 1175 |
+
[
|
| 1176 |
+
"PageFooter",
|
| 1177 |
+
1
|
| 1178 |
+
],
|
| 1179 |
+
[
|
| 1180 |
+
"ListGroup",
|
| 1181 |
+
1
|
| 1182 |
+
]
|
| 1183 |
+
],
|
| 1184 |
+
"block_metadata": {
|
| 1185 |
+
"llm_request_count": 0,
|
| 1186 |
+
"llm_error_count": 0,
|
| 1187 |
+
"llm_tokens_used": 0,
|
| 1188 |
+
"previous_text": "",
|
| 1189 |
+
"previous_type": "",
|
| 1190 |
+
"previous_order": 0
|
| 1191 |
+
}
|
| 1192 |
+
},
|
| 1193 |
+
{
|
| 1194 |
+
"page_id": 12,
|
| 1195 |
+
"text_extraction_method": "pdftext",
|
| 1196 |
+
"block_counts": [
|
| 1197 |
+
[
|
| 1198 |
+
"Span",
|
| 1199 |
+
126
|
| 1200 |
+
],
|
| 1201 |
+
[
|
| 1202 |
+
"Line",
|
| 1203 |
+
57
|
| 1204 |
+
],
|
| 1205 |
+
[
|
| 1206 |
+
"Reference",
|
| 1207 |
+
5
|
| 1208 |
+
],
|
| 1209 |
+
[
|
| 1210 |
+
"Text",
|
| 1211 |
+
4
|
| 1212 |
+
],
|
| 1213 |
+
[
|
| 1214 |
+
"ListItem",
|
| 1215 |
+
2
|
| 1216 |
+
],
|
| 1217 |
+
[
|
| 1218 |
+
"PageHeader",
|
| 1219 |
+
1
|
| 1220 |
+
],
|
| 1221 |
+
[
|
| 1222 |
+
"PageFooter",
|
| 1223 |
+
1
|
| 1224 |
+
],
|
| 1225 |
+
[
|
| 1226 |
+
"ListGroup",
|
| 1227 |
+
1
|
| 1228 |
+
]
|
| 1229 |
+
],
|
| 1230 |
+
"block_metadata": {
|
| 1231 |
+
"llm_request_count": 0,
|
| 1232 |
+
"llm_error_count": 0,
|
| 1233 |
+
"llm_tokens_used": 0,
|
| 1234 |
+
"previous_text": "",
|
| 1235 |
+
"previous_type": "",
|
| 1236 |
+
"previous_order": 0
|
| 1237 |
+
}
|
| 1238 |
+
},
|
| 1239 |
+
{
|
| 1240 |
+
"page_id": 13,
|
| 1241 |
+
"text_extraction_method": "pdftext",
|
| 1242 |
+
"block_counts": [
|
| 1243 |
+
[
|
| 1244 |
+
"Span",
|
| 1245 |
+
146
|
| 1246 |
+
],
|
| 1247 |
+
[
|
| 1248 |
+
"Line",
|
| 1249 |
+
60
|
| 1250 |
+
],
|
| 1251 |
+
[
|
| 1252 |
+
"Text",
|
| 1253 |
+
2
|
| 1254 |
+
],
|
| 1255 |
+
[
|
| 1256 |
+
"PageHeader",
|
| 1257 |
+
1
|
| 1258 |
+
],
|
| 1259 |
+
[
|
| 1260 |
+
"PageFooter",
|
| 1261 |
+
1
|
| 1262 |
+
]
|
| 1263 |
+
],
|
| 1264 |
+
"block_metadata": {
|
| 1265 |
+
"llm_request_count": 0,
|
| 1266 |
+
"llm_error_count": 0,
|
| 1267 |
+
"llm_tokens_used": 0,
|
| 1268 |
+
"previous_text": "",
|
| 1269 |
+
"previous_type": "",
|
| 1270 |
+
"previous_order": 0
|
| 1271 |
+
}
|
| 1272 |
+
},
|
| 1273 |
+
{
|
| 1274 |
+
"page_id": 14,
|
| 1275 |
+
"text_extraction_method": "surya",
|
| 1276 |
+
"block_counts": [
|
| 1277 |
+
[
|
| 1278 |
+
"Line",
|
| 1279 |
+
143
|
| 1280 |
+
],
|
| 1281 |
+
[
|
| 1282 |
+
"Span",
|
| 1283 |
+
87
|
| 1284 |
+
],
|
| 1285 |
+
[
|
| 1286 |
+
"Text",
|
| 1287 |
+
37
|
| 1288 |
+
],
|
| 1289 |
+
[
|
| 1290 |
+
"Reference",
|
| 1291 |
+
4
|
| 1292 |
+
],
|
| 1293 |
+
[
|
| 1294 |
+
"SectionHeader",
|
| 1295 |
+
2
|
| 1296 |
+
],
|
| 1297 |
+
[
|
| 1298 |
+
"Figure",
|
| 1299 |
+
2
|
| 1300 |
+
],
|
| 1301 |
+
[
|
| 1302 |
+
"Caption",
|
| 1303 |
+
2
|
| 1304 |
+
],
|
| 1305 |
+
[
|
| 1306 |
+
"FigureGroup",
|
| 1307 |
+
2
|
| 1308 |
+
],
|
| 1309 |
+
[
|
| 1310 |
+
"PageHeader",
|
| 1311 |
+
1
|
| 1312 |
+
],
|
| 1313 |
+
[
|
| 1314 |
+
"PageFooter",
|
| 1315 |
+
1
|
| 1316 |
+
]
|
| 1317 |
+
],
|
| 1318 |
+
"block_metadata": {
|
| 1319 |
+
"llm_request_count": 0,
|
| 1320 |
+
"llm_error_count": 0,
|
| 1321 |
+
"llm_tokens_used": 0,
|
| 1322 |
+
"previous_text": "",
|
| 1323 |
+
"previous_type": "",
|
| 1324 |
+
"previous_order": 0
|
| 1325 |
+
}
|
| 1326 |
+
},
|
| 1327 |
+
{
|
| 1328 |
+
"page_id": 15,
|
| 1329 |
+
"text_extraction_method": "surya",
|
| 1330 |
+
"block_counts": [
|
| 1331 |
+
[
|
| 1332 |
+
"Line",
|
| 1333 |
+
154
|
| 1334 |
+
],
|
| 1335 |
+
[
|
| 1336 |
+
"Span",
|
| 1337 |
+
119
|
| 1338 |
+
],
|
| 1339 |
+
[
|
| 1340 |
+
"Text",
|
| 1341 |
+
35
|
| 1342 |
+
],
|
| 1343 |
+
[
|
| 1344 |
+
"Figure",
|
| 1345 |
+
4
|
| 1346 |
+
],
|
| 1347 |
+
[
|
| 1348 |
+
"ListItem",
|
| 1349 |
+
4
|
| 1350 |
+
],
|
| 1351 |
+
[
|
| 1352 |
+
"Caption",
|
| 1353 |
+
2
|
| 1354 |
+
],
|
| 1355 |
+
[
|
| 1356 |
+
"ListGroup",
|
| 1357 |
+
2
|
| 1358 |
+
],
|
| 1359 |
+
[
|
| 1360 |
+
"Reference",
|
| 1361 |
+
2
|
| 1362 |
+
],
|
| 1363 |
+
[
|
| 1364 |
+
"PageHeader",
|
| 1365 |
+
1
|
| 1366 |
+
],
|
| 1367 |
+
[
|
| 1368 |
+
"PageFooter",
|
| 1369 |
+
1
|
| 1370 |
+
]
|
| 1371 |
+
],
|
| 1372 |
+
"block_metadata": {
|
| 1373 |
+
"llm_request_count": 0,
|
| 1374 |
+
"llm_error_count": 0,
|
| 1375 |
+
"llm_tokens_used": 0,
|
| 1376 |
+
"previous_text": "",
|
| 1377 |
+
"previous_type": "",
|
| 1378 |
+
"previous_order": 0
|
| 1379 |
+
}
|
| 1380 |
+
},
|
| 1381 |
+
{
|
| 1382 |
+
"page_id": 16,
|
| 1383 |
+
"text_extraction_method": "surya",
|
| 1384 |
+
"block_counts": [
|
| 1385 |
+
[
|
| 1386 |
+
"Line",
|
| 1387 |
+
134
|
| 1388 |
+
],
|
| 1389 |
+
[
|
| 1390 |
+
"Span",
|
| 1391 |
+
80
|
| 1392 |
+
],
|
| 1393 |
+
[
|
| 1394 |
+
"Text",
|
| 1395 |
+
33
|
| 1396 |
+
],
|
| 1397 |
+
[
|
| 1398 |
+
"Equation",
|
| 1399 |
+
4
|
| 1400 |
+
],
|
| 1401 |
+
[
|
| 1402 |
+
"Figure",
|
| 1403 |
+
2
|
| 1404 |
+
],
|
| 1405 |
+
[
|
| 1406 |
+
"ListItem",
|
| 1407 |
+
2
|
| 1408 |
+
],
|
| 1409 |
+
[
|
| 1410 |
+
"Reference",
|
| 1411 |
+
2
|
| 1412 |
+
],
|
| 1413 |
+
[
|
| 1414 |
+
"PageHeader",
|
| 1415 |
+
1
|
| 1416 |
+
],
|
| 1417 |
+
[
|
| 1418 |
+
"Caption",
|
| 1419 |
+
1
|
| 1420 |
+
],
|
| 1421 |
+
[
|
| 1422 |
+
"SectionHeader",
|
| 1423 |
+
1
|
| 1424 |
+
],
|
| 1425 |
+
[
|
| 1426 |
+
"PageFooter",
|
| 1427 |
+
1
|
| 1428 |
+
],
|
| 1429 |
+
[
|
| 1430 |
+
"ListGroup",
|
| 1431 |
+
1
|
| 1432 |
+
]
|
| 1433 |
+
],
|
| 1434 |
+
"block_metadata": {
|
| 1435 |
+
"llm_request_count": 0,
|
| 1436 |
+
"llm_error_count": 0,
|
| 1437 |
+
"llm_tokens_used": 0,
|
| 1438 |
+
"previous_text": "",
|
| 1439 |
+
"previous_type": "",
|
| 1440 |
+
"previous_order": 0
|
| 1441 |
+
}
|
| 1442 |
+
},
|
| 1443 |
+
{
|
| 1444 |
+
"page_id": 17,
|
| 1445 |
+
"text_extraction_method": "surya",
|
| 1446 |
+
"block_counts": [
|
| 1447 |
+
[
|
| 1448 |
+
"Line",
|
| 1449 |
+
124
|
| 1450 |
+
],
|
| 1451 |
+
[
|
| 1452 |
+
"Span",
|
| 1453 |
+
60
|
| 1454 |
+
],
|
| 1455 |
+
[
|
| 1456 |
+
"Text",
|
| 1457 |
+
30
|
| 1458 |
+
],
|
| 1459 |
+
[
|
| 1460 |
+
"Equation",
|
| 1461 |
+
6
|
| 1462 |
+
],
|
| 1463 |
+
[
|
| 1464 |
+
"PageHeader",
|
| 1465 |
+
1
|
| 1466 |
+
],
|
| 1467 |
+
[
|
| 1468 |
+
"SectionHeader",
|
| 1469 |
+
1
|
| 1470 |
+
],
|
| 1471 |
+
[
|
| 1472 |
+
"PageFooter",
|
| 1473 |
+
1
|
| 1474 |
+
],
|
| 1475 |
+
[
|
| 1476 |
+
"Reference",
|
| 1477 |
+
1
|
| 1478 |
+
]
|
| 1479 |
+
],
|
| 1480 |
+
"block_metadata": {
|
| 1481 |
+
"llm_request_count": 0,
|
| 1482 |
+
"llm_error_count": 0,
|
| 1483 |
+
"llm_tokens_used": 0,
|
| 1484 |
+
"previous_text": "",
|
| 1485 |
+
"previous_type": "",
|
| 1486 |
+
"previous_order": 0
|
| 1487 |
+
}
|
| 1488 |
+
},
|
| 1489 |
+
{
|
| 1490 |
+
"page_id": 18,
|
| 1491 |
+
"text_extraction_method": "surya",
|
| 1492 |
+
"block_counts": [
|
| 1493 |
+
[
|
| 1494 |
+
"Line",
|
| 1495 |
+
136
|
| 1496 |
+
],
|
| 1497 |
+
[
|
| 1498 |
+
"Span",
|
| 1499 |
+
88
|
| 1500 |
+
],
|
| 1501 |
+
[
|
| 1502 |
+
"Text",
|
| 1503 |
+
35
|
| 1504 |
+
],
|
| 1505 |
+
[
|
| 1506 |
+
"Equation",
|
| 1507 |
+
6
|
| 1508 |
+
],
|
| 1509 |
+
[
|
| 1510 |
+
"ListItem",
|
| 1511 |
+
3
|
| 1512 |
+
],
|
| 1513 |
+
[
|
| 1514 |
+
"Reference",
|
| 1515 |
+
3
|
| 1516 |
+
],
|
| 1517 |
+
[
|
| 1518 |
+
"SectionHeader",
|
| 1519 |
+
2
|
| 1520 |
+
],
|
| 1521 |
+
[
|
| 1522 |
+
"PageHeader",
|
| 1523 |
+
1
|
| 1524 |
+
],
|
| 1525 |
+
[
|
| 1526 |
+
"PageFooter",
|
| 1527 |
+
1
|
| 1528 |
+
],
|
| 1529 |
+
[
|
| 1530 |
+
"ListGroup",
|
| 1531 |
+
1
|
| 1532 |
+
]
|
| 1533 |
+
],
|
| 1534 |
+
"block_metadata": {
|
| 1535 |
+
"llm_request_count": 0,
|
| 1536 |
+
"llm_error_count": 0,
|
| 1537 |
+
"llm_tokens_used": 0,
|
| 1538 |
+
"previous_text": "",
|
| 1539 |
+
"previous_type": "",
|
| 1540 |
+
"previous_order": 0
|
| 1541 |
+
}
|
| 1542 |
+
},
|
| 1543 |
+
{
|
| 1544 |
+
"page_id": 19,
|
| 1545 |
+
"text_extraction_method": "surya",
|
| 1546 |
+
"block_counts": [
|
| 1547 |
+
[
|
| 1548 |
+
"Line",
|
| 1549 |
+
141
|
| 1550 |
+
],
|
| 1551 |
+
[
|
| 1552 |
+
"Span",
|
| 1553 |
+
85
|
| 1554 |
+
],
|
| 1555 |
+
[
|
| 1556 |
+
"Text",
|
| 1557 |
+
42
|
| 1558 |
+
],
|
| 1559 |
+
[
|
| 1560 |
+
"Equation",
|
| 1561 |
+
13
|
| 1562 |
+
],
|
| 1563 |
+
[
|
| 1564 |
+
"Reference",
|
| 1565 |
+
2
|
| 1566 |
+
],
|
| 1567 |
+
[
|
| 1568 |
+
"PageHeader",
|
| 1569 |
+
1
|
| 1570 |
+
],
|
| 1571 |
+
[
|
| 1572 |
+
"PageFooter",
|
| 1573 |
+
1
|
| 1574 |
+
]
|
| 1575 |
+
],
|
| 1576 |
+
"block_metadata": {
|
| 1577 |
+
"llm_request_count": 0,
|
| 1578 |
+
"llm_error_count": 0,
|
| 1579 |
+
"llm_tokens_used": 0,
|
| 1580 |
+
"previous_text": "",
|
| 1581 |
+
"previous_type": "",
|
| 1582 |
+
"previous_order": 0
|
| 1583 |
+
}
|
| 1584 |
+
},
|
| 1585 |
+
{
|
| 1586 |
+
"page_id": 20,
|
| 1587 |
+
"text_extraction_method": "surya",
|
| 1588 |
+
"block_counts": [
|
| 1589 |
+
[
|
| 1590 |
+
"Line",
|
| 1591 |
+
126
|
| 1592 |
+
],
|
| 1593 |
+
[
|
| 1594 |
+
"Span",
|
| 1595 |
+
105
|
| 1596 |
+
],
|
| 1597 |
+
[
|
| 1598 |
+
"Text",
|
| 1599 |
+
37
|
| 1600 |
+
],
|
| 1601 |
+
[
|
| 1602 |
+
"Equation",
|
| 1603 |
+
7
|
| 1604 |
+
],
|
| 1605 |
+
[
|
| 1606 |
+
"ListItem",
|
| 1607 |
+
3
|
| 1608 |
+
],
|
| 1609 |
+
[
|
| 1610 |
+
"PageHeader",
|
| 1611 |
+
1
|
| 1612 |
+
],
|
| 1613 |
+
[
|
| 1614 |
+
"SectionHeader",
|
| 1615 |
+
1
|
| 1616 |
+
],
|
| 1617 |
+
[
|
| 1618 |
+
"PageFooter",
|
| 1619 |
+
1
|
| 1620 |
+
],
|
| 1621 |
+
[
|
| 1622 |
+
"ListGroup",
|
| 1623 |
+
1
|
| 1624 |
+
],
|
| 1625 |
+
[
|
| 1626 |
+
"Reference",
|
| 1627 |
+
1
|
| 1628 |
+
]
|
| 1629 |
+
],
|
| 1630 |
+
"block_metadata": {
|
| 1631 |
+
"llm_request_count": 0,
|
| 1632 |
+
"llm_error_count": 0,
|
| 1633 |
+
"llm_tokens_used": 0,
|
| 1634 |
+
"previous_text": "",
|
| 1635 |
+
"previous_type": "",
|
| 1636 |
+
"previous_order": 0
|
| 1637 |
+
}
|
| 1638 |
+
},
|
| 1639 |
+
{
|
| 1640 |
+
"page_id": 21,
|
| 1641 |
+
"text_extraction_method": "surya",
|
| 1642 |
+
"block_counts": [
|
| 1643 |
+
[
|
| 1644 |
+
"Line",
|
| 1645 |
+
140
|
| 1646 |
+
],
|
| 1647 |
+
[
|
| 1648 |
+
"Span",
|
| 1649 |
+
95
|
| 1650 |
+
],
|
| 1651 |
+
[
|
| 1652 |
+
"Text",
|
| 1653 |
+
44
|
| 1654 |
+
],
|
| 1655 |
+
[
|
| 1656 |
+
"Equation",
|
| 1657 |
+
13
|
| 1658 |
+
],
|
| 1659 |
+
[
|
| 1660 |
+
"Reference",
|
| 1661 |
+
2
|
| 1662 |
+
],
|
| 1663 |
+
[
|
| 1664 |
+
"PageHeader",
|
| 1665 |
+
1
|
| 1666 |
+
],
|
| 1667 |
+
[
|
| 1668 |
+
"PageFooter",
|
| 1669 |
+
1
|
| 1670 |
+
]
|
| 1671 |
+
],
|
| 1672 |
+
"block_metadata": {
|
| 1673 |
+
"llm_request_count": 0,
|
| 1674 |
+
"llm_error_count": 0,
|
| 1675 |
+
"llm_tokens_used": 0,
|
| 1676 |
+
"previous_text": "",
|
| 1677 |
+
"previous_type": "",
|
| 1678 |
+
"previous_order": 0
|
| 1679 |
+
}
|
| 1680 |
+
},
|
| 1681 |
+
{
|
| 1682 |
+
"page_id": 22,
|
| 1683 |
+
"text_extraction_method": "surya",
|
| 1684 |
+
"block_counts": [
|
| 1685 |
+
[
|
| 1686 |
+
"Span",
|
| 1687 |
+
94
|
| 1688 |
+
],
|
| 1689 |
+
[
|
| 1690 |
+
"Line",
|
| 1691 |
+
84
|
| 1692 |
+
],
|
| 1693 |
+
[
|
| 1694 |
+
"Text",
|
| 1695 |
+
39
|
| 1696 |
+
],
|
| 1697 |
+
[
|
| 1698 |
+
"Equation",
|
| 1699 |
+
9
|
| 1700 |
+
],
|
| 1701 |
+
[
|
| 1702 |
+
"Reference",
|
| 1703 |
+
2
|
| 1704 |
+
],
|
| 1705 |
+
[
|
| 1706 |
+
"PageHeader",
|
| 1707 |
+
1
|
| 1708 |
+
],
|
| 1709 |
+
[
|
| 1710 |
+
"SectionHeader",
|
| 1711 |
+
1
|
| 1712 |
+
],
|
| 1713 |
+
[
|
| 1714 |
+
"PageFooter",
|
| 1715 |
+
1
|
| 1716 |
+
]
|
| 1717 |
+
],
|
| 1718 |
+
"block_metadata": {
|
| 1719 |
+
"llm_request_count": 0,
|
| 1720 |
+
"llm_error_count": 0,
|
| 1721 |
+
"llm_tokens_used": 0,
|
| 1722 |
+
"previous_text": "",
|
| 1723 |
+
"previous_type": "",
|
| 1724 |
+
"previous_order": 0
|
| 1725 |
+
}
|
| 1726 |
+
},
|
| 1727 |
+
{
|
| 1728 |
+
"page_id": 23,
|
| 1729 |
+
"text_extraction_method": "surya",
|
| 1730 |
+
"block_counts": [
|
| 1731 |
+
[
|
| 1732 |
+
"Line",
|
| 1733 |
+
153
|
| 1734 |
+
],
|
| 1735 |
+
[
|
| 1736 |
+
"Span",
|
| 1737 |
+
107
|
| 1738 |
+
],
|
| 1739 |
+
[
|
| 1740 |
+
"Text",
|
| 1741 |
+
41
|
| 1742 |
+
],
|
| 1743 |
+
[
|
| 1744 |
+
"Equation",
|
| 1745 |
+
12
|
| 1746 |
+
],
|
| 1747 |
+
[
|
| 1748 |
+
"Reference",
|
| 1749 |
+
3
|
| 1750 |
+
],
|
| 1751 |
+
[
|
| 1752 |
+
"SectionHeader",
|
| 1753 |
+
2
|
| 1754 |
+
],
|
| 1755 |
+
[
|
| 1756 |
+
"PageHeader",
|
| 1757 |
+
1
|
| 1758 |
+
],
|
| 1759 |
+
[
|
| 1760 |
+
"PageFooter",
|
| 1761 |
+
1
|
| 1762 |
+
]
|
| 1763 |
+
],
|
| 1764 |
+
"block_metadata": {
|
| 1765 |
+
"llm_request_count": 0,
|
| 1766 |
+
"llm_error_count": 0,
|
| 1767 |
+
"llm_tokens_used": 0,
|
| 1768 |
+
"previous_text": "",
|
| 1769 |
+
"previous_type": "",
|
| 1770 |
+
"previous_order": 0
|
| 1771 |
+
}
|
| 1772 |
+
},
|
| 1773 |
+
{
|
| 1774 |
+
"page_id": 24,
|
| 1775 |
+
"text_extraction_method": "surya",
|
| 1776 |
+
"block_counts": [
|
| 1777 |
+
[
|
| 1778 |
+
"Span",
|
| 1779 |
+
91
|
| 1780 |
+
],
|
| 1781 |
+
[
|
| 1782 |
+
"Line",
|
| 1783 |
+
75
|
| 1784 |
+
],
|
| 1785 |
+
[
|
| 1786 |
+
"Text",
|
| 1787 |
+
38
|
| 1788 |
+
],
|
| 1789 |
+
[
|
| 1790 |
+
"Equation",
|
| 1791 |
+
6
|
| 1792 |
+
],
|
| 1793 |
+
[
|
| 1794 |
+
"SectionHeader",
|
| 1795 |
+
2
|
| 1796 |
+
],
|
| 1797 |
+
[
|
| 1798 |
+
"Reference",
|
| 1799 |
+
2
|
| 1800 |
+
],
|
| 1801 |
+
[
|
| 1802 |
+
"PageHeader",
|
| 1803 |
+
1
|
| 1804 |
+
],
|
| 1805 |
+
[
|
| 1806 |
+
"PageFooter",
|
| 1807 |
+
1
|
| 1808 |
+
]
|
| 1809 |
+
],
|
| 1810 |
+
"block_metadata": {
|
| 1811 |
+
"llm_request_count": 0,
|
| 1812 |
+
"llm_error_count": 0,
|
| 1813 |
+
"llm_tokens_used": 0,
|
| 1814 |
+
"previous_text": "",
|
| 1815 |
+
"previous_type": "",
|
| 1816 |
+
"previous_order": 0
|
| 1817 |
+
}
|
| 1818 |
+
}
|
| 1819 |
+
],
|
| 1820 |
+
"debug_data_path": "debug_data/2g8vgmyXgQ"
|
| 1821 |
+
}
|
iclr26/2g8vgmyXgQ/model_text_v3.txt
ADDED
|
@@ -0,0 +1,248 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
[p. 1 | section: ABSTRACT | type: Text]
|
| 2 |
+
The transformer architecture has revolutionized machine learning by processing input sequences into outputs. A defining feature is in-context learning (ICL)—the ability to perform unseen tasks from prompts without updating model parameters. Early theoretical work focused on linear tasks, and recent studies have begun exploring nonlinear functions. Yet a rigorous analysis of the training dynamics—how transformers learn such complex tasks—remains elusive. This paper presents the first formal analysis of ICL training dynamics for a broad class of nonlinear regression functions. We analyze the stage-wise dynamics of attention during training: attention scores between a query token and its target features rise rapidly at first, then gradually converge to one, while attention to irrelevant features decays more slowly and can oscillate. Our analysis explicitly characterizes how general non-degenerate L-Lipschitz task functions shape attention weights, identifying the Lipschitz constant L as the key factor governing the convergence dynamics. Leveraging these insights, for two distinct regimes depending on whether L is below or above a threshold, we derive different time bounds to guarantee nearzero prediction error. Despite convergence time depending on the task, we prove query tokens ultimately focus on highly relevant prompt tokens, demonstrating transformers' robust ICL capability.
|
| 3 |
+
|
| 4 |
+
[p. 1 | section: 1 INTRODUCTION | type: Text]
|
| 5 |
+
The transformer architecture (Vaswani et al., 2017) has driven transformative advances across a wide spectrum of machine learning domains, including computer vision (Bi et al., 2021; Han et al., 2022; Goldblum et al., 2024) , natural language processing (Kalyan et al., 2021; Tunstall et al., 2022) , and speech processing (Mehrish et al., 2023; Latif et al., 2023) . A salient feature of transformers is their ability to perform new tasks without updating parameters, simply by conditioning on a few input-output examples—known as prompts. This capability, referred to as in-context learning (ICL) , enables models to generalize to unseen tasks purely through inference (Brown et al., 2020) .
|
| 6 |
+
|
| 7 |
+
[p. 1 | section: 1 INTRODUCTION | type: Text]
|
| 8 |
+
ICL has attracted growing interest, with numerous empirical studies examining when transformers succeed or fail at in-context generalization (Xie et al., 2021; Garg et al., 2022; Von Oswald et al., 2023; Wu et al., 2023; Li et al., 2024b; Agarwal et al., 2024; Park et al., 2025) . Notably, Garg et al. (2022) provided preliminary theoretical evidence that transformers trained on specific function classes (e.g., linear) can accurately infer a query function value from prompts containing variable–function pairs, highlighting transformers' surprising ability to "learn" within their forward pass and mimic classical function approximation.
|
| 9 |
+
|
| 10 |
+
[p. 1 | section: 1 INTRODUCTION | type: Text]
|
| 11 |
+
Building on this foundation, subsequent works have provided theoretical understandings of ICL by characterizing the training dynamics of single-layer attention transformers (Mahankali et al., 2023; Zhang et al., 2024; Huang et al., 2024; Collins et al., 2024; Yang et al., 2024) . For instance, Huang et al. (2024) consider softmax attention to analyze how attention weights evolve during training linear regression problems. More recent studies have theoretically shown that transformers can learn specific nonlinear function classes in-context, such as binary classification, low-degree polynomial regression, and Gaussian single-index models (Li et al., 2024a; Yang et al., 2024; Oko et al., 2024; Sun et al., 2025) . However, these studies do not provide a full theoretical picture of how the step-by-step learning process is governed by the task itself. To date, a formal characterization of the pre-training dynamics for general nonlinear ICL has been a key open problem.
|
| 12 |
+
|
| 13 |
+
[p. 2 | section: 1 INTRODUCTION | type: Text]
|
| 14 |
+
In this work, we take a step toward understanding the learning dynamics for ICL on a broad class of nonlinear regression functions. We address two fundamental questions: (1) Which geometric properties of the target function govern the convergence behavior of transformer-based ICL? and (2) Despite nonlinearity and generality, how can a transformer learn in context to achieve low prediction error? We answer both by analyzing transformer training under gradient descent. Our main contributions are summarized below.
|
| 15 |
+
|
| 16 |
+
[p. 2 | section: 1 INTRODUCTION | type: ListGroup]
|
| 17 |
+
Broad Class of Nonlinear Functions and Flexible Feature Sets: Our analysis generalizes previous studies in two ways. (i) Unlike prior theoretical works that focus on linear mappings (Zhang et al., 2024; Huang et al., 2024), binary classification (Li et al., 2024a), or low-degree polynomials (Sun et al., 2025), we characterize learning dynamics for a much broader family of non-degenerate L-Lipschitz task functions without assuming low complexity. This class is satisfied by almost any nontrivial L-Lipschitz function (e.g., scaled cosine, piecewise-polynomial, and small neural-network functions) and excludes only degenerate cases. (ii) Our results also hold for general feature embeddings without the restrictive orthonormality assumptions in prior work (Huang et al., 2024; Li et al., 2024a; Chen et al., 2024; Nichani et al., 2024). Phase Transition of Training Dynamics between Flat and Sharp Curvature Regimes: We discover a phase transition in training dynamics governed by the Lipschitz constant L. When L is below a threshold of order \Theta\left(\frac{1}{\Delta\delta}\right) , the flat curvature regime yields smaller gradients and permits larger step sizes to converge. When L exceeds the threshold, the sharp-curvature regime produces larger gradients requiring smaller steps. The two regimes exhibit distinct convergence behaviors: although the flat regime may converge faster at high accuracy, sufficiently large L enhances feature separability, enabling accelerated training in the sharp regime. Convergence Guarantee for ICL with Nonlinear Regression Functions: We provide formal convergence guarantees for a one-layer softmax attention model learning nonlinear regression functions. We prove that gradient descent achieves near-zero training loss in polynomial time across both flat and sharp L-regimes. We also characterize the two-phase training dynamics: an early phase in which attention scores between query tokens and target features rise rapidly, and a later phase in which these scores converge to one while attention to irrelevant features decays more slowly with oscillations. At convergence, query tokens consistently attend to highly relevant prompt tokens, demonstrating the ICL capability of transformers. Novel Analysis Techniques: We develop new proof tools that explicitly connect the curvature of nonlinear task functions to the evolution of attention weights. In particular, we first decompose the prediction loss to explicitly relate it to attention weights and cross-feature gaps under nonlinear functions. We further show that the flat and sharp curvature regimes of the parameter L lead to distinct gradient magnitudes, which in turn drive different convergence rates and shape the overall training dynamics. The impact of function curvature on the magnitude and stability of attention updates is, to our knowledge, not addressed in previous ICL literature (Huang et al., 2024; Oko et al., 2024; Cheng et al., 2024).
|
| 18 |
+
|
| 19 |
+
[p. 2 | section: 2 RELATED WORKS | type: Text]
|
| 20 |
+
In-context learning. In-context learning (ICL) has emerged as a fundamental capability of transformer models, enabling dynamic task adaptation without parameter updates. The research community has approached ICL from several distinct yet complementary perspectives.
|
| 21 |
+
|
| 22 |
+
[p. 2 | section: 2 RELATED WORKS | type: Text]
|
| 23 |
+
The Bayesian inference perspective, pioneered by Xie et al. (2021) and further developed by Zhang et al. (2023); Wang et al. (2023); Falck et al. (2024), establishes a theoretical framework linking prompting strategies to probabilistic reasoning. This line of work interprets ICL as a form of implicit Bayesian model averaging, where transformers effectively perform approximated inference conditioned on the provided context. Another line of ICL work focuses on Markov chains to study the behavior of induction heads for transformers, which are designed to copy or compare tokens that follow previous occurrences (Nichani et al., 2024; Bietti et al., 2023; Edelman et al., 2024; Rajaraman et al., 2024). The central focus is to understand how transformers recover latent sequence structures (Nichani et al., 2024) and transition rules (Ren & Liu, 2024; Li et al., 2023; Makkuva et al., 2024), using token-level recurrence and dynamics.
|
| 24 |
+
|
| 25 |
+
[p. 3 | section: 2 RELATED WORKS | type: Text]
|
| 26 |
+
In contrast, the function learning perspective initiated by Garg et al. (2022) demonstrated transformers' remarkable ability to learn and interpolate simple function classes (particularly linear models) directly from context examples. This work sparked significant interest in understanding the mechanistic underpinnings of ICL, leading to important discoveries by Von Oswald et al. (2023) and Dai et al. (2022), who revealed deep connections between attention mechanisms and gradient-based optimization dynamics. Recent advances have substantially expanded our understanding of ICL mechanisms: Akyürek et al. (2023) provided a rigorous analysis of linear regression tasks, showing that trained transformers can implement both ridge regression gradient descent and exact least-squares solutions. Bai et al. (2023) established comprehensive theoretical results encompassing expressive power, prediction capabilities, and sample complexity, while proposing general mechanisms for algorithmic selection. Cheng et al. (2024) interprets transformers as implementing functional gradient descent for nonlinear regression, but their analysis primarily focuses on the representational capacity and functional viewpoint of the learned predictor, without analyzing the ICL pre-training dynamics.
|
| 27 |
+
|
| 28 |
+
[p. 3 | section: 2 RELATED WORKS | type: Text]
|
| 29 |
+
Theoretical analysis of ICL learning dynamics. Recent theoretical work has made significant progress in understanding the pre-training dynamics of ICL in transformers, though important limitations remain (Huang et al., 2024; Li et al., 2024a; Collins et al., 2024; Yang et al., 2024; Sun et al., 2025; Lu et al., 2024; Edelman et al., 2024; Lin & Lee, 2024; Jeon et al., 2024; Park et al., 2025). The foundational work by Huang et al. (2024) established the first rigorous analysis of training dynamics for softmax attention in ICL settings, focusing on a single-head attention layer learning linear regression tasks. Their key theoretical result demonstrates that prompt tokens with features identical to the query token develop dominating attention weights during training. However, this analysis relies critically on strong assumptions about pairwise orthonormality of feature vectors and a normalized function scale, limiting its applicability to more general settings. Our work goes beyond this setting by showing that, for general nonlinear targets, the Lipschitz constant of the underlying function governs both the gradient evolution and the resulting convergence regimes. In this sense, our analysis includes the linear case as a special instance while providing a more fine-grained understanding of how function curvature influences attention-based learning.
|
| 30 |
+
|
| 31 |
+
[p. 3 | section: 2 RELATED WORKS | type: Text]
|
| 32 |
+
Subsequent work extended these results to classification tasks (Li et al., 2024a), dual-head settings (Lin & Lee, 2024), and structured or hierarchical functions (Yang et al., 2024; Sun et al., 2025). Some studies explored the implicit bias of gradient descent and attention-based generalization (Collins et al., 2024; Lu et al., 2024), while others examined information-theoretic and dynamical aspects of ICL (Edelman et al., 2024; Jeon et al., 2024). Despite these advances, most analyses still rely on restrictive assumptions, such as orthonormality features, fixed positional encoding, or carefully structured input distributions, limiting their ability to explain ICL under general tasks and practical learning conditions.
|
| 33 |
+
|
| 34 |
+
[p. 3 | section: 2 RELATED WORKS | type: Text]
|
| 35 |
+
Notations. In this paper, for a vector \boldsymbol{v} , we let \|\boldsymbol{v}\|_2 denote its \ell -2 norm. For some positive constant C_1 and C_2 , we define x = \Omega(y) if x > C_2|y| , x = \Theta(y) if C_1|y| < x < C_2|y| , and x = \mathcal{O}(y) if x < c_1|y| . We also denote by x = o(y) if x/y \to 0 . We use \operatorname{poly}(C) to denote large constant degree polynomials of C. For a matrix A, we use A_i to denote the i-th column of A, and A_{i:j} to represent the collection of columns from the i-th to the j-th column (inclusive).
|
| 36 |
+
|
| 37 |
+
[p. 3 | section: 3 System Model | type: Text]
|
| 38 |
+
In this section, we formulate our system model, including the problem setup for in-context learning, the transformer architecture, and the associated training process.
|
| 39 |
+
|
| 40 |
+
[p. 3 | section: 3.1 IN-CONTEXT LEARNING PROBLEM SETUP | type: Text]
|
| 41 |
+
We consider a standard in-context learning (ICL) framework commonly used in prior studies (Garg et al., 2022; Huang et al., 2024; Yang et al., 2024). The objective is to train a transformer model that can perform ICL over a designated class of functions \mathcal{F} , where each function f \in \mathcal{F} corresponds to one task context. Here, we focus on nonlinear function classes further elaborated below.
|
| 42 |
+
|
| 43 |
+
[p. 3 | section: 3.1 IN-CONTEXT LEARNING PROBLEM SETUP | type: Text]
|
| 44 |
+
Given each task (i.e., given one function f randomly sampled from \mathcal{F} ), a prompt with a sequence of N input-response pairs (x_i, y_i) as well as a query input x_{\text{query}} are sampled, where x_i \in \mathcal{X} \subseteq \mathbb{R}^d , and y_i = f(x_i) . Let the input matrix X = (x_1 \ x_2 \ \cdots \ x_N) \in \mathbb{R}^{d \times N} and the response vector \mathbf{y} = (y_1 \ y_2 \ \cdots \ y_N) \in \mathbb{R}^{1 \times N} . We adopt the following standard prompt embedding (Garg et al.,
|
| 45 |
+
|
| 46 |
+
[p. 4 | section: 3.1 IN-CONTEXT LEARNING PROBLEM SETUP | type: Text]
|
| 47 |
+
2022: Huang et al., 2024: Yang et al., 2024):
|
| 48 |
+
|
| 49 |
+
[p. 4 | section: 3.1 IN-CONTEXT LEARNING PROBLEM SETUP | type: Equation]
|
| 50 |
+
P = \begin{pmatrix} x_1 & x_2 & \cdots & x_N & x_{\text{query}} \\ y_1 & y_2 & \cdots & y_N & 0 \end{pmatrix} = \begin{pmatrix} X & x_{\text{query}} \\ \mathbf{y} & 0 \end{pmatrix} \in \mathbb{R}^{(d+1)\times(N+1)}. \tag{1}
|
| 51 |
+
|
| 52 |
+
[p. 4 | section: 3.1 IN-CONTEXT LEARNING PROBLEM SETUP | type: Text]
|
| 53 |
+
Non-degenerate L -Lipschitz Regression Functions. In this work, we focus on regression tasks, where each task is associated with a regression function drawn from the following set
|
| 54 |
+
|
| 55 |
+
[p. 4 | section: 3.1 IN-CONTEXT LEARNING PROBLEM SETUP | type: Equation]
|
| 56 |
+
\mathcal{F} = \left\{ f: \begin{array}{l} |f(x) - f(x')| \leq L ||x - x'||, & \forall ||x - x'|| = \Theta(\delta_0), \\ \forall v_k \in \mathbb{V}, \exists v_{k'} \in \mathbb{V}, \ k' \neq k, \ \text{such that} \ |f(v_k) - f(v_{k'})| = \Theta(L) \cdot ||v_k - v_{k'}|| \end{array} \right\}, (2)
|
| 57 |
+
|
| 58 |
+
[p. 4 | section: 3.1 IN-CONTEXT LEARNING PROBLEM SETUP | type: Text]
|
| 59 |
+
where L>0 and \delta_0=\mathcal{O}(1) . In particular, the functions in the class are said to satisfy non-degenerate L- Lipschitz condition, which imposes two natural requirements on the function class. First, the standard global L-Lipschitz condition ensures that the function f does not change too rapidly, which is common in the literature and includes a wide class of linear and nonlinear functions. Second, the separation requirement guarantees that for any feature v_k in the set \mathbb{V} , there exists at least one other feature v_{k'} such that the function difference between them achieves the order of variation defined by the Lipschitz constant. This ensures sufficient distinguishability of features by the function class for guaranteed learnability. This mild separation assumption is satisfied by almost any nontrivial L-Lipschitz function (e.g., scaled cosine, piecewise-polynomial, and small neural-network functions) and excludes only degenerate cases. Together, these two conditions ensure that the function class is sufficiently rich for ICL while avoiding unlearnable or trivial scenarios.
|
| 60 |
+
|
| 61 |
+
[p. 4 | section: 3.1 IN-CONTEXT LEARNING PROBLEM SETUP | type: Text]
|
| 62 |
+
For each prompt P, the task-specific function f(x) is independently drawn based on a task distribution \mathcal{D}_f , as long as f(x) satisfies the property for the same L and \delta_0 in Eq. (2).
|
| 63 |
+
|
| 64 |
+
[p. 4 | section: 3.1 IN-CONTEXT LEARNING PROBLEM SETUP | type: Text]
|
| 65 |
+
Feature Embeddings. Let \mathbb{V}:=\{v_k\in\mathbb{R}^d|k=1,\cdots,K\} be the feature embeddings of tokens. For any k\neq k' , we assume a separation of \|v_k-v_{k'}\|=\Theta(\Delta) , where \Delta=\Theta(1) . Each data sample x is modeled as a noisy perturbation of one of the vectors in \mathbb{V} . This assumption lets us control the separation \Delta precisely, simplifying the analysis while retaining the essential geometry of the problem. Such a condition can be satisfied by various feature learning techniques to avoid feature collapse, e.g., disentangled representation learning (Wang et al., 2022; 2024; Higgins et al., 2018). We note that such a condition substantially generalizes the orthonormality assumption taken by the previous study (Huang et al., 2024; Li et al., 2024a; Chen et al., 2024; Nichani et al., 2024). The prompt is sampled as follows. For a randomly chosen v_k , we assume x satisfies \|x-v_k\|=O(\epsilon_x) with probability p_k , where \epsilon_x=o(1) and p_k=\Theta(\frac{1}{K}) . For analytical simplicity, we assume x=v_k whenever this proximity condition holds. In our experiments in Section 6, we further verify that our training dynamic analysis remains valid when tokens are drawn from general continuous distributions.
|
| 66 |
+
|
| 67 |
+
[p. 4 | section: 3.2 One-Layer Transformer | type: Text]
|
| 68 |
+
In this work, we adopt a one-layer transformer model for solving the ICL problem, which is commonly used in the existing theoretical ICL literature (e.g., Huang et al. (2024); Li et al. (2024a); Yang et al. (2024); Sun et al. (2025)). A self-attention transformer with width d_e consists of a key matrix W^K \in \mathbb{R}^{d_e \times d_e} , a query matrix W^Q \in \mathbb{R}^{d_e \times d_e} , and a value matrix W^V \in \mathbb{R}^{d_e \times d_e} . For a given prompt P of length N in Eq. (1), the self-attention layer outputs:
|
| 69 |
+
|
| 70 |
+
[p. 4 | section: 3.2 One-Layer Transformer | type: Equation]
|
| 71 |
+
F(P; W^K, W^Q, W^V) = W^V P \times \operatorname{softmax} \left( (W^K P)^\top W^Q P \right). \tag{3}
|
| 72 |
+
|
| 73 |
+
[p. 4 | section: 3.2 One-Layer Transformer | type: Text]
|
| 74 |
+
where the softmax(·) function is applied column-wisely, i.e., for a vector input z, the i-th entry of softmax(z) is given by softmax( z_i ) = \frac{\exp(z_i)}{\sum_i \exp(z_j)} .
|
| 75 |
+
|
| 76 |
+
[p. 4 | section: 3.2 One-Layer Transformer | type: Text]
|
| 77 |
+
We further take the following re-parameterization, commonly adopted by the recent theoretical studies of transformers (e.g. Zhang et al. (2024); Huang et al. (2024); Yang et al. (2024); Sun et al. (2025)), which combines the query and key matrices into a single matrix W^{KQ} \in \mathbb{R}^{(d+1)\times (d+1)} , and further specify the weight matrices as follows:
|
| 78 |
+
|
| 79 |
+
[p. 4 | section: 3.2 One-Layer Transformer | type: Equation]
|
| 80 |
+
W^V = \begin{pmatrix} 0_{d \times d} & 0_d \\ 0_d^\top & 1 \end{pmatrix}, \quad W^{KQ} = \begin{pmatrix} Q & 0_d \\ 0_d^\top & 0 \end{pmatrix},
|
| 81 |
+
|
| 82 |
+
[p. 4 | section: 3.2 One-Layer Transformer | type: Text]
|
| 83 |
+
where Q \in \mathbb{R}^{d \times d} is the trainable weight matrix. These simplifications, while not capturing the full complexity of deep, multi-head models, are standard in the theoretical literature and serve two crucial purposes. First, they allow for a tractable analysis that isolates the core dynamics of the softmax
|
| 84 |
+
|
| 85 |
+
[p. 5 | section: 3.2 One-Layer Transformer | type: Equation]
|
| 86 |
+
F(P;Q) = \mathbf{y} \cdot \operatorname{softmax}(X^{\top} Q \bar{X}), \tag{4}
|
| 87 |
+
|
| 88 |
+
[p. 5 | section: 3.2 One-Layer Transformer | type: Text]
|
| 89 |
+
where we further let \bar{X}=(x_1 \quad x_2 \quad \cdots \quad x_N \quad x_{\text{query}}) \in \mathbb{R}^{d \times N+1} and \mathbf{y}=(y_1 \quad y_2 \quad \cdots \quad y_N) \in \mathbb{R}^{d \times N+1} \mathbb{R}^{d \times N} . The prediction \hat{y}_{\text{query}} corresponding to x_{\text{query}} is given by the last entry of F(P;Q)_{N+1} , i.e., \hat{y}_{\text{query}} = F(P;Q)_{N+1} . To train the attention model on the ICL problem introduced in Section 3.1, we minimize the following squared loss between the predicted and true responses:
|
| 90 |
+
|
| 91 |
+
[p. 5 | section: 3.2 One-Layer Transformer | type: Equation]
|
| 92 |
+
\mathcal{L}(P;Q) = \frac{1}{2} \mathbb{E} \left[ \left( F(P;Q)_{N+1} - f(x_{\text{query}}) \right)^2 \right], \tag{5}
|
| 93 |
+
|
| 94 |
+
[p. 5 | section: 3.2 One-Layer Transformer | type: Text]
|
| 95 |
+
\mathcal{L}(P;Q) = \frac{1}{2}\mathbb{E}\Big[\big(F(P;Q)_{N+1} - f(x_{\text{query}})\big)^2\Big], \tag{5} where the expectation is taken over the randomly sampled prompt \{x_i\}_{i=1}^N \cup \{x_{\text{query}}\} and randomly sampled function f \in \mathcal{F} that determines the corresponding ground-truth responses.
|
| 96 |
+
|
| 97 |
+
[p. 5 | section: 3.2 One-Layer Transformer | type: Text]
|
| 98 |
+
We optimize this loss via gradient descent (GD). Let vec(Q) denote the vector that stacks all entries of Q. At t = 0, we initialize vec(Q)^{(0)} as the zero matrix 0_{d^2} . The parameter is updated as follows:
|
| 99 |
+
|
| 100 |
+
[p. 5 | section: 3.2 One-Layer Transformer | type: Equation]
|
| 101 |
+
\operatorname{vec}(Q)^{(t+1)} = \operatorname{vec}(Q)^{(t)} - \eta \nabla_{\operatorname{vec}(Q)} \mathcal{L}(P; \operatorname{vec}(Q)^{(t)}). \tag{6}
|
| 102 |
+
|
| 103 |
+
[p. 5 | section: 3.2 One-Layer Transformer | type: Text]
|
| 104 |
+
where \eta > 0 is the learning rate. Note that we require \eta to be smaller than a universal constant (e.g., \eta < 1 ) to ensure stability of the update and to preserve the convergence behavior analyzed in Section 5. Based on this model setup and training procedure, we proceed to present our main theoretical results concerning ICL under nonlinear regression tasks.
|
| 105 |
+
|
| 106 |
+
[p. 5 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 107 |
+
Our analysis proceeds by decomposing the loss function into interpretable quantities that directly reflect cluster separation and the Lipschitz constant L in Eq. (2). Interestingly, we observe that the flat and sharp regimes of L give rise to distinct convergence dynamics, with a threshold transition separating the two regimes based on the order of magnitude of L. In the flat regime (small L), the gradient on Q matrices remains small, leading to slow but steady concentration of attention weights. In the sharp regime (large L), we show a rapid growth phase where the query-key inner products amplify differences between clusters before settling into a slow fine-tuning phase. For the two regimes, we provide explicit convergence-time bounds and characterize the phase transition. Compared with prior analyses restricted to linear tasks or orthogonal features, our framework extends to general nonlinear Lipschitz tasks and explains qualitatively different dynamics observed in practice.
|
| 108 |
+
|
| 109 |
+
[p. 5 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 110 |
+
Recall from Section 3.1 that each token x_i corresponds to a noisy version of a feature v_k \in \mathbb{V} with probability p_k = \Theta\left(\frac{1}{K}\right) for any k \in [K] . Let P_{1:N} denote the collection of input tokens in P, i.e., \{x_i\}_{i=1}^N , and denote \mathcal{V}_k \subset [N] as the index set for input tokens, such that x_i = v_k for i \in \mathcal{V}_k . We define the following concentration set of token sequences where each feature appears with approximately the expected frequency:
|
| 111 |
+
|
| 112 |
+
[p. 5 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Equation]
|
| 113 |
+
\mathcal{E}^* := \left\{ P_{1:N} : |\mathcal{V}_k| \in \left[ (p_k - \delta)N, (p_k + \delta)N \right] \text{ for } k \in [K] \right\}, \tag{7}
|
| 114 |
+
|
| 115 |
+
[p. 5 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 116 |
+
where \delta \geq \sqrt{\frac{20K}{N}} . Then, for any 0 < \epsilon < 1 , suppose N \geq \Theta(K^3) and K \geq \Theta(\frac{1}{\epsilon}) . For any t \in [T] , we have the concentration probability satisfies \mathbb{P}(P_{1:N} \in \mathcal{E}^*) \ge 1 - 3 \exp\left(-\frac{\delta^2 N}{25}\right) . This implies that, with high probability, each feature class k \in [K] is approximately equally represented in the prompt P, ensuring a balanced token distribution. Such balance is crucial for the convergence of ICL, as it allows the attention to learn effectively from all feature types without introducing bias. While our analysis is expressed in terms of the population risk in Eq. (5), the concentration event in Eq. (7) ensures that the empirical prompt distribution closely matches the population distribution when N is sufficiently large. Under this event, the curvature-driven attention dynamics characterized later in our theory remain accurate up to standard \mathcal{O}(1/\sqrt{N}) fluctuations. Thus, the population-level analysis offers a faithful description of the finite-sample training behavior for prompts of moderate size.
|
| 117 |
+
|
| 118 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 119 |
+
Given balanced feature inputs, we now quantify how much the query token x_{query} attends to specific input tokens or feature classes. We define the attention score for a query token to attend to the i-th token in the prompt as \operatorname{attn}_i^{(t)} := \operatorname{softmax}(x_i^\top Q^{(t)} x_{\operatorname{query}}) and the total attention paid to all tokens with feature v_k as \operatorname{Attn}_k^{(t)} := \sum_{i:x_i=v_k} \operatorname{attn}_i^{(t)} . With this notation, the transformer's output at t is
|
| 120 |
+
|
| 121 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Equation]
|
| 122 |
+
\hat{y}_{\text{query}} = \sum_{i \in [N]} \operatorname{attn}_{i}^{(t)} y_{i} = \sum_{k \in [K]} \operatorname{Attn}_{k}^{(t)} f(v_{k}). \tag{8}
|
| 123 |
+
|
| 124 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 125 |
+
Building on the expression in Eq. (8), we characterize how the attention scores influence the prediction loss defined in Eq. (5) in the following lemma.
|
| 126 |
+
|
| 127 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 128 |
+
Lemma 1. Given constants L, \Delta > 0 , the prediction loss in Eq. (5) can be expressed as:
|
| 129 |
+
|
| 130 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Equation]
|
| 131 |
+
\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( 1 - \operatorname{Attn}_{k}^{(t)} \right)^2 \cdot \mathcal{O}(L^2 \Delta^2) \right], \ \forall t \in [T], (9) where \mathbb{1} \{ x_{\text{query}} = v_k \} = 1 is the indicator function that equals 1 if x_{\text{query}} = v_k and 0 otherwise.
|
| 132 |
+
|
| 133 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 134 |
+
The proof of Lemma 1 is given in Appendix C. This expression reveals that loss \mathcal{L}(P;Q) depends on the Lipschitz constant L, the feature gap \Delta , and the attention score \operatorname{Attn}_k^{(t)} associated with the true feature of the query token. The dependence on L, which captures the function's curvature, distinguishes our analysis from prior theoretical work on ICL (e.g., Huang et al. (2024); Oko et al. (2024); Sun et al. (2025)). For a given feature gap \Delta , different function Lipschitz constants L can lead to distinct convergence behaviors of ICL. In the following theorem, we first provide the \epsilon^2 -convergence of \mathcal{L}(P;Q) in the flat L-regime, where L is below a certain threshold.
|
| 135 |
+
|
| 136 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 137 |
+
Theorem 1 (Flat L-regime). Suppose the function class in Eq. (2) satisfies L \leq \Theta\left(\frac{1}{\Delta\delta}\right) . Then, for any 0 < \epsilon < 1 and under N \geq \Theta(K^3) and K \geq \Theta(\frac{1}{\epsilon}) , with at most T_f^* = \Theta(\frac{K \log(K\epsilon^{-1})}{\eta \delta^2 L^2 \Delta^2}) iterations, we have \mathcal{L}(P;Q) \leq \mathcal{O}(\epsilon^2) .
|
| 138 |
+
|
| 139 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 140 |
+
The proof of Theorem 1 is given in Appendix E.3. Theorem 1 indicates that T_f^* decreases (i.e., the convergence is faster) as either the Lipschitz constant L or the feature gap \Delta increases. Intuitively, a larger function Lipschitz constant L implies that the outputs y_i and y_{i'} corresponding to different features in the prompt P become more distinguishable, which facilitates faster in-context learning. Similarly, a larger feature gap \Delta improves the separability among features, enabling the query token to more accurately attend to the relevant prompt tokens.
|
| 141 |
+
|
| 142 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 143 |
+
However, when L exceeds a certain threshold, the caused sharp curvature induces large gradients on the attention weights. As a result, a smaller stepsize is required to stabilize convergence, leading to a convergence rate that differs from that in the flat regime. We next establish the \epsilon^2 -convergence of \mathcal{L}(P;Q) in the sharp L regime, where L is above the threshold.
|
| 144 |
+
|
| 145 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 146 |
+
Theorem 2 (Sharp L-regime). Suppose the function class in Eq. (2) satisfies L = \Omega(\frac{1}{\Delta\delta}) . Then for any 0 < \epsilon < 1 , under N = \Omega(K^3) and K \ge \Theta(\frac{1}{\epsilon}) , with at most T_s^* = \Theta(\frac{K \log(K\epsilon^{-1}L\Delta)}{n\epsilon\delta^2L^2\Delta^2}) iterations, we have \mathcal{L}(P;Q) = \mathcal{O}(\epsilon^2)
|
| 147 |
+
|
| 148 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 149 |
+
The proof of Theorem 2 is given in Appendix F.2. Theorem 1 and Theorem 2 together reveal an interesting phase transition phenomenon : the convergence dynamics are governed by how the function Lipschitz constant L compares to a threshold of order \Theta\left(\frac{1}{\Delta\delta}\right) . In the flat curvature regime , where L is below this threshold, convergence allows larger step sizes due to smaller gradients, resulting in a convergence rate of \tilde{\Theta}\left(\frac{K}{\eta\delta^2L^2\Delta^2}\right) . In contrast, in the sharp curvature regime , where L is above the threshold, the large L incurs large gradients which thus require smaller step sizes to stabilize convergence, yielding a convergence rate of \tilde{\Theta}\left(\frac{K}{\eta\epsilon\delta^2L^2\Delta^2}\right) . Comparing the two convergence upper bounds, neither T_f^* nor T_s^* always dominates. The sharp regime benefits from a larger L, giving a smaller denominator and faster convergence, but its bound also contains an extra \frac{1}{\epsilon} factor that can dominate when high accuracy is required. Therefore, depending on the relative scales of L, \epsilon , and \Delta , either regime may achieve the smaller convergence upper bound.
|
| 150 |
+
|
| 151 |
+
[p. 6 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 152 |
+
In cases where the query is not a small perturbation of any feature vector, the model must represent the query using a combination of multiple feature clusters rather than relying on a single dominant one. This setting is more challenging because the nonlinear function values evolve over training, causing the optimal attention pattern to shift across clusters. Nevertheless, the curvature-dependent
|
| 153 |
+
|
| 154 |
+
[p. 7 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 155 |
+
gradient behavior established in our analysis continues to govern the convergence rate, even though the precise attention trajectory becomes harder to characterize.
|
| 156 |
+
|
| 157 |
+
[p. 7 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 158 |
+
Based on the convergence results above, we now characterize the behavior of the attention score Attn_k^{(t)} at convergence to explain why the ICL output corresponds to an accurate prediction.
|
| 159 |
+
|
| 160 |
+
[p. 7 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 161 |
+
Proposition 1. After the prediction loss converges to \mathcal{L}(P;Q) = \mathcal{O}(\epsilon^2) for any 0 < \epsilon < 1 , if the query token satisfies x_{\text{query}} = v_k , then the attention score associated with feature v_k satisfies 1 - \operatorname{Attn}_{k}^{(t)} = \mathcal{O}(\epsilon).
|
| 162 |
+
|
| 163 |
+
[p. 7 | section: MAIN RESULTS OF ICL CONVERGENCE | type: Text]
|
| 164 |
+
The proof of Proposition 1 is given in Appendix G. This result follows directly from the loss expression in Eq. (9), where \mathcal{L}(P;Q) = \Theta((1-\operatorname{Attn}_k^{(t)})^2) when x_{\text{query}} = v_k . Intuitively, as Attn_k^{(t)} approaches 1, the attention matrix effectively focuses predominantly on the tokens that share the same feature v_k . As a result, the predicted output \hat{y}_{query} , given by Eq. (8), closely approximates the true value f(v_k) , leading to high-accuracy predictions.
|
| 165 |
+
|
| 166 |
+
[p. 7 | section: ANALYSIS OF CONVERGENCE DYNAMICS | type: Text]
|
| 167 |
+
As established in Theorem 1 and Theorem 2, different regimes of the Lipschitz constant L lead to distinct convergence behaviors in ICL. In this section, we analyze the training dynamics under both regimes, highlighting how the Lipschitz constant L influences the convergence rate in each case.
|
| 168 |
+
|
| 169 |
+
[p. 7 | section: GRADIENTS OF ATTENTION WEIGHTS | type: Text]
|
| 170 |
+
Based on the prediction output \hat{y}_{\text{query}} in Eq. (5), the attention scores \text{attn}_i play a critical role in determining the final prediction. To precisely characterize these attention scores for any i \in [N] , it is sufficient to characterize the training dynamics of the attention weights q_{k,k'}^{(t)} := v_{k'}^{\top} Q^{(t)} v_k for k, k' \in [K] , which are initialized as q_{k,k'}^{(0)} = 0 for any k, k' \in [K] . To simplify notations, we denote the q_{k,k}^{(t)} as q_k^{(t)} for k'=k. According to the definition of the attention score \operatorname{attn}_i^{(t)} in Eq. (8), when x_{\text{query}}^{(t)} = v_k , the quantity q_k^{(t)} measures how strongly the query token attends to the target feature v_k , while q_{k k'}^{(t)} reflects the attention given to a different feature v_{k'} with k' \neq k . To achieve the desired attention behavior, effective training should increase q_k^{(t)} while suppressing q_{k,k'}^{(t)}
|
| 171 |
+
|
| 172 |
+
[p. 7 | section: GRADIENTS OF ATTENTION WEIGHTS | type: Text]
|
| 173 |
+
The convergence behavior of the transformer depends on the dynamics of q_k^{(t)} and q_{k,k'}^{(t)} . We therefore proceed to analyze how these quantities evolve during training. To this end, we define the gradient updates for q_k^{(t)} and q_{k,k'}^{(t)} as g_k^{(t)} and g_{k,k'}^{(t)} , respectively. Under gradient descent with learning rate \eta , the update rules are given by:
|
| 174 |
+
|
| 175 |
+
[p. 7 | section: GRADIENTS OF ATTENTION WEIGHTS | type: Equation]
|
| 176 |
+
q_k^{(t+1)} := q_k^{(t)} + \eta g_k^{(t)}, \qquad q_{k k'}^{(t+1)} := q_{k k'}^{(t)} + \eta g_{k k'}^{(t)}.
|
| 177 |
+
|
| 178 |
+
[p. 7 | section: GRADIENTS OF ATTENTION WEIGHTS | type: Text]
|
| 179 |
+
q_k^{(t+1)} := q_k^{(t)} + \eta g_k^{(t)}, \qquad q_{k,k'}^{(t+1)} := q_{k,k'}^{(t)} + \eta g_{k,k'}^{(t)}. We now present the following lemma, which provides the exact expressions for the gradient terms g_k^{(t)} and g_{k,k'}^{(t)} for a function class {\mathcal F} with Lipschitz constant L.
|
| 180 |
+
|
| 181 |
+
[p. 7 | section: GRADIENTS OF ATTENTION WEIGHTS | type: Text]
|
| 182 |
+
Lemma 2. For any t \in [T] , suppose x_{query} = v_k . Then for any k, k' \in [K] with k' \neq k , we obtain
|
| 183 |
+
|
| 184 |
+
[p. 7 | section: GRADIENTS OF ATTENTION WEIGHTS | type: Equation]
|
| 185 |
+
g_k^{(t)} = \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} \operatorname{Attn}_k^{(t)} \left(1 - \operatorname{Attn}_k^{(t)}\right)^2 \cdot \Theta(L^2 \Delta^2)\right],\tag{10}
|
| 186 |
+
|
| 187 |
+
[p. 7 | section: GRADIENTS OF ATTENTION WEIGHTS | type: Equation]
|
| 188 |
+
|g_{k,k'}^{(t)}| = \mathbb{E}\left[\mathbb{1}\{x_{\text{query}}^{(t)} = v_k\} \text{Attn}_{k'}^{(t)} \cdot (1 - \text{Attn}_{k}^{(t)}) \cdot (1 - \text{Attn}_{k'}^{(t)}) \cdot \Theta(L^2 \Delta^2)\right]. \tag{11}
|
| 189 |
+
|
| 190 |
+
[p. 7 | section: GRADIENTS OF ATTENTION WEIGHTS | type: Text]
|
| 191 |
+
The proof of Lemma 2 is given in Appendix D. From Eq. (10), we observe that g_k^{(t)} is always non-negative, implying that the update q_k^{(t)} increases over time. This growth continues until the attention score Attn_k^{(t)} approaches its convergence state near 1. However, g_{k,k'}^{(t)} in Eq. (11) is not necessarily positive and also depends on Attn_{k'}^{(t)} associated with feature vector v_{k'} . However, as Attn_k^{(t)} approaches 1, the residual term in Eq. (11) diminishes, and g_{k,k'}^{(t)} also converges toward zero, facilitating the overall convergence of the system.
|
| 192 |
+
|
| 193 |
+
[p. 8 | section: GRADIENTS OF ATTENTION WEIGHTS | type: Text]
|
| 194 |
+
As also shown in Lemma 2, both gradients scale with the Lipschitz constant L and the feature gap \Delta , illustrating their influence on the training dynamics. In the following subsections, we analyze how different regimes of the function Lipschitz constant L (with respect to the threshold determined by \Delta ) affect the evolution of q_k^{(t)} and q_{k,k'}^{(t)} , through the gradients g_k^{(t)} and g_{k,k'}^{(t)} , thereby offering deeper insight into the convergence results established in Theorem 1 and Theorem 2.
|
| 195 |
+
|
| 196 |
+
[p. 8 | section: 5.2 Convergence Dynamics under Flat L-Regime | type: Text]
|
| 197 |
+
For ease of exposition, we consider the case where x_{\mathrm{query}} = v_k in the following. Under the initialization of q_k^{(0)} = q_{k,k'}^{(0)} = 0 , and by the definition of the attention score, we have \mathrm{attn}_n^{(0)} = \frac{1}{N} for all n \in [N] , meaning that the transformer initially attends equally to all input tokens when computing the prediction for x_{\mathrm{query}} . We then leverage the task distribution in Eq. (2) and the gradient expressions in Lemma 2 to analyze the learning dynamics of q_k^{(t)} and q_{k,k'}^{(t)} .
|
| 198 |
+
|
| 199 |
+
[p. 8 | section: 5.2 Convergence Dynamics under Flat L-Regime | type: Text]
|
| 200 |
+
In the initial phase of training, the prediction \hat{y}_{\text{query}} is far from the ground truth f(v_k) due to the zero initialization of bilinear weights. According to Eq. (10), this results in a large positive gradient g_k^{(t)} , leading to a rapid increase in q_k^{(t)} . In contrast, the gradient g_{k,k'}^{(t)} may fluctuate in sign depending on the alignment of f(v_k) and f(v_{k'}) at each step, causing q_{k,k'}^{(t)} to oscillate but decrease much more slowly. We formally characterize this phase below.
|
| 201 |
+
|
| 202 |
+
[p. 8 | section: 5.2 Convergence Dynamics under Flat L-Regime | type: Text]
|
| 203 |
+
Proposition 2 (Phase I: Fast growth of q_k^{(t)} ). For any t \in \{1, \cdots, T_f^1\} and k \in [K] , where T_f^1 = \Theta(\frac{K \log(K)}{\eta L^2 \Delta^2}) , the attention weight q_k^{(t)} increases at a rate of \Theta(\frac{\eta L^2 \Delta^2}{K}) . Meanwhile, q_{k,k'}^{(t)} oscillates at a slower rate of O(\frac{\eta L^2 \Delta^2}{K^2}) and exhibits an overall decreasing trend. By the end of Phase I (i.e., t = T_f^1 + 1 ), we have \operatorname{Attn}_k^{(T_f^1 + 1)} = \Omega(\frac{1}{1 + \delta}) .
|
| 204 |
+
|
| 205 |
+
[p. 8 | section: 5.2 Convergence Dynamics under Flat L-Regime | type: Text]
|
| 206 |
+
The proof of Proposition 2 is given in Appendix E.1. According to Proposition 2, Phase I ends once q_k^{(t)} becomes sufficiently large to reduce the prediction gap between the ICL output and the ground truth function value. After this point, both g_k^{(t)} in Eq. (10) and |g_{k,k'}^{(t)}| in Eq. (11) decrease to smaller orders. During this phase, both g_k^{(t)} and |g_{k,k'}^{(t)}| increase with L, as a larger function Lipschitz constant induces greater residual values in Eq. (10) and Eq. (11). Likewise, a larger feature gap \Delta amplifies the value difference between f(v_k) and f(v_{k'}) (by Eq. (2)), which in turn accelerates attention learning in Phase I. As a result, the duration T_f^1 decreases with both L and \Delta .
|
| 207 |
+
|
| 208 |
+
[p. 8 | section: 5.2 Convergence Dynamics under Flat L-Regime | type: Text]
|
| 209 |
+
However, at t=T_f^1 , the prediction loss in Eq. (5) may still remain non-negligible. As a result, the attention score \operatorname{Attn}_k^{(t)} requires a period of steady improvement after t=T_f^1+1 . We now formalize this behavior in the second training phase in the following proposition.
|
| 210 |
+
|
| 211 |
+
[p. 8 | section: 5.2 Convergence Dynamics under Flat L-Regime | type: Text]
|
| 212 |
+
Proposition 3 (Phase II: Steady growth of q_k^{(t)} under flat L-regime). For any t \in \{T_f^1+1,\cdots,T_f^*\} and 0 < \epsilon < 1 , where T_f^* = \Theta(\frac{K \log(K\epsilon^{-1})}{\eta \delta^2 L^2 \Delta^2}) , for any k \in [K] , q_k^{(t)} continues to grow at a steady rate of \Theta\left(\frac{\eta \delta^2 L^2 \Delta^2}{K}\right) . Meanwhile, q_{k,k'}^{(t)} oscillates at a slower rate of O\left(\frac{\eta \delta^2 L^2 \Delta^2}{K^2}\right) and exhibits an overall decreasing trend. At t = T_f^* + 1 , if L satisfies L \leq \Theta(\frac{1}{\Delta \delta}) in Eq. (2), we have \operatorname{Attn}_k^{(T_f^*+1)} = \Omega(\frac{1}{1+\epsilon\delta}) .
|
| 213 |
+
|
| 214 |
+
[p. 8 | section: 5.2 Convergence Dynamics under Flat L-Regime | type: Text]
|
| 215 |
+
The proof of Proposition 3 is given in Appendix E.2. According to Proposition 3, if the Lipschitz constant is sufficiently small such that L \leq \Theta(\frac{1}{\Delta\delta}) , then by the end of Phase II, the attention score satisfies 1 - \operatorname{Attn}_k^{(T_f^*+1)} = \mathcal{O}\left(\frac{\epsilon\delta}{1+\epsilon\delta}\right) = \mathcal{O}(\epsilon) , indicating that the transformer has converged.
|
| 216 |
+
|
| 217 |
+
[p. 8 | section: 5.3 Phase Transition under Sharp L-Regime | type: Text]
|
| 218 |
+
In the sharp curvature regime where L=\Omega(\frac{1}{\Delta\delta}) , the update q_k^{(t)} increases at a rate of \Theta(\frac{\eta}{K}) for all t\leq T_f^* . Let T_s^1 denote the duration of Phase I in this regime. Since this early-stage growth (Phase I) mirrors the dynamics under the flat L-regime before T_f^* , we have T_s^1=T_f^*=\Theta(\frac{K\log(K\epsilon^{-1})}{\eta\delta^2L^2\Delta^2}) .
|
| 219 |
+
|
| 220 |
+
[p. 9 | section: 5.3 Phase Transition under Sharp L-Regime | type: FigureGroup]
|
| 221 |
+
set. L-set. flat <math>L=0.1. sharp L=1.
|
| 222 |
+
|
| 223 |
+
[p. 9 | section: 5.3 Phase Transition under Sharp L-Regime | type: Caption]
|
| 224 |
+
Figure 1: Training dynamics of prediction losses (top) and attention scores (bottom) for two sets of L: flat ( \{0.1, 0.2, 0.4\} ) and sharp ( \{1.0, 1.5, 2.0\} ).
|
| 225 |
+
|
| 226 |
+
[p. 9 | section: 5.3 Phase Transition under Sharp L-Regime | type: Text]
|
| 227 |
+
However, this initial Phase is insufficient for achieving convergence due to the residual error term proportional to L \cdot \Delta in Eq. (9). Consequently, training transitions into a second phase (Phase III), during which both gradient terms g_k^{(t)} and g_{k,k'}^{(t)} become small. This leads to a slower growth rate of q_k^{(t)} compared to the earlier phase. We characterize this slower training phase as follows.
|
| 228 |
+
|
| 229 |
+
[p. 9 | section: 5.3 Phase Transition under Sharp L-Regime | type: Text]
|
| 230 |
+
Proposition 4 (Phase III: Slow growth of q_k^{(t)} under sharp L-regime). If L = \Omega(\frac{1}{\Delta\delta}) , then for any t \in \{T_s^1+1,\cdots,T_s^*\} and 0 < \epsilon < 1 , where T_s^* = \Theta(\frac{K\log(KL\Delta\epsilon^{-1})}{\eta\epsilon\delta^2L^2\Delta^2}) , for any k \in [K] , q_k^{(t)} increases at a rate of \Theta(\frac{\eta\delta^2L^2\Delta^2\epsilon}{K}) . Meanwhile, q_{k,k'}^{(t)} fluctuates at a slower rate of O(\frac{\eta\delta^2L^2\Delta^2\epsilon}{K^2}) . By the end of Phase II (i.e. t = T_s^* + 1 ), we have \operatorname{Attn}_k^{(T_s^*+1)} = \Omega(\frac{1}{1+\epsilon\delta}) .
|
| 231 |
+
|
| 232 |
+
[p. 9 | section: 5.3 Phase Transition under Sharp L-Regime | type: Text]
|
| 233 |
+
The proof of Proposition 4 is given in Appendix F.1. To ensure convergence of the prediction loss, the update step size of q_k^{(t)} decreases to an order dependent on \epsilon in Phase II. This is because, under the sharp L-regime where \delta^2 L^2 \Delta^2 = \Omega(1) , the gradients become large, as established in Lemma 2. This phase transition further supports the convergence guarantee in Theorem 2, demonstrating that even under sharp curvature, the attention mechanism gradually concentrates on the correct feature vector, ultimately enabling accurate prediction.
|
| 234 |
+
|
| 235 |
+
[p. 9 | section: 6 EXPERIMENTS VERIFICATION | type: Text]
|
| 236 |
+
We adopt the data and task distributions from Section 3.1. Each data point is sampled from a fixed feature set v_k \in \mathbb{R}^d, k=1,\ldots,K , with each feature v_k chosen uniformly at random, i.e., p_k=1/K . Each task involves learning a cosine function of the form f(x) = \frac{L}{c} \cdot \cos(c \cdot x) , where c>0 is a random constant and L is the Lipschitz constant, satisfying Eq. (2). Each prompt consists of N randomly sampled inputs \{x_i\}_{i=1}^N and corresponding outputs \{y_i\}_{i=1}^N = \{f(x_i)\}_{i=1}^N , along with a query token x_{\text{query}} . We set the parameters as follows: d=15, K=4, N=100, c=0.5, and \Delta=3 . We generate M=300 prompts and train the model for T=400 epochs. Appendix B presents additional experiments, including attention map dynamics, robustness check with non-uniform feature frequencies, polynomial-function tasks, and deeper transformers.
|
| 237 |
+
|
| 238 |
+
[p. 9 | section: 6 EXPERIMENTS VERIFICATION | type: Text]
|
| 239 |
+
We analyze a simplified transformer model comprising a single block with one-head self-attention and a feedforward network, incorporating layer normalization and ReLU activation, followed by a linear output layer. Our analysis focuses on two key metrics shown in Figure 1: (1) prediction loss dynamics and (2) attention score evolution, evaluated under flat ( \{0.1, 0.2, 0.4\} ) and sharp ( \{1.0, 1.5, 2.0\} ) curvature regimes. The prediction loss is computed as the average squared loss over prompts containing query token v_k . For attention scores, we track v_1 's self-attention score \operatorname{Attn}_1^{(t)} and other features' attention scores \operatorname{Attn}_{k-1}^{(t)} ( k \in \{2, 3, 4\} ) on v_1 at each epoch.
|
| 240 |
+
|
| 241 |
+
[p. 9 | section: 6 EXPERIMENTS VERIFICATION | type: Text]
|
| 242 |
+
For flat L-regime, as shown in Figure 1(a) and Figure 1(c), we observe two distinct training phases. For example, with L=0.1, the prediction loss rapidly decreases to around 1.0 by epoch t=40, driven by increasing attention on the target feature shown in Figure 1(c). Subsequently, it steadily declines to near zero by t=250. At the same time, \operatorname{Attn}_1^{(t)} approaches 1 under the transformer parameter \theta . The convergence time shortens with increasing L due to stronger gradient updates, consistent with Theorem 1, Proposition 1, Proposition 2, and Proposition 3.
|
| 243 |
+
|
| 244 |
+
[p. 10 | section: 6 EXPERIMENTS VERIFICATION | type: Text]
|
| 245 |
+
As depicted in Figure 1(b) and Figure 1(d), the sharp L-regime exhibits different three training phases. Specifically, when L=1, the prediction loss drops rapidly to approximately 0.6 by t=30, then decreases steadily to around 0.1 by t=110. After that, it converges slowly toward 0 by t=200. The dynamics of the attention scores in Figure 1(d) exhibit the same three-phase progression. Additionally, under our experiment setting, the convergence upper bounds T_f^* in Theorem 1 and T_s^* in Theorem 2 satisfy T_f^* > T_s^* , indicating that the sharp regime achieves a faster convergence time. These empirical observations are consistent with our theoretical predictions in Theorem 2 and Proposition 4.
|
| 246 |
+
|
| 247 |
+
[p. 10 | section: 7 CONCLUSIONS AND LIMITATIONS | type: Text]
|
| 248 |
+
We presented provable results showing how transformers can learn a broad family of nonlinear tasks in context, identifying two distinct training regimes governed by task curvature. These findings illuminate the basic mechanisms-attention concentration and curvature-dependent gradient dynamics—that underpin ICL. By revealing how Lipschitz continuity and feature separation jointly determine convergence and generalization, our theory offers testable predictions for real-world settings (e.g., effects of task smoothness and feature geometry) and provides a principled starting point for extending formal guarantees to more realistic transformer architectures. Although our analysis focuses on a single-layer, single-head model, extending it to multi-head and multi-layer transformers presents substantial challenges due to intertwined cross-head gradients and the recursive evolution of representations across layers. Depth introduces residual connections and nonlinearities that couple representation learning with attention dynamics, making phase-wise analysis significantly more delicate. We view developing such extensions as an important direction for future work, and our curvature-sensitive framework provides a promising starting point.
|
iclr26/2g8vgmyXgQ/paper.blocks.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
iclr26/2g8vgmyXgQ/paper.md
ADDED
|
@@ -0,0 +1,1040 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
|
| 2 |
+
|
| 3 |
+
{0}------------------------------------------------
|
| 4 |
+
|
| 5 |
+
# PROVABLE IN-CONTEXT LEARNING OF NONLINEAR REGRESSION WITH TRANSFORMERS
|
| 6 |
+
|
| 7 |
+
Anonymous authors Paper under double-blind review
|
| 8 |
+
|
| 9 |
+
**000**
|
| 10 |
+
|
| 11 |
+
**003 004**
|
| 12 |
+
|
| 13 |
+
**006**
|
| 14 |
+
|
| 15 |
+
**024**
|
| 16 |
+
|
| 17 |
+
**028 029 030**
|
| 18 |
+
|
| 19 |
+
**052 053**
|
| 20 |
+
|
| 21 |
+
# ABSTRACT
|
| 22 |
+
|
| 23 |
+
The transformer architecture has revolutionized machine learning by processing input sequences into outputs. A defining feature is in-context learning (ICL)—the ability to perform unseen tasks from prompts without updating model parameters. Early theoretical work focused on linear tasks, and recent studies have begun exploring nonlinear functions. Yet a rigorous analysis of the training dynamics—how transformers learn such complex tasks—remains elusive. This paper presents the first formal analysis of ICL training dynamics for a broad class of nonlinear regression functions. We analyze the stage-wise dynamics of attention during training: attention scores between a query token and its target features rise rapidly at first, then gradually converge to one, while attention to irrelevant features decays more slowly and can oscillate. Our analysis explicitly characterizes how general non-degenerate L-Lipschitz task functions shape attention weights, identifying the Lipschitz constant L as the key factor governing the convergence dynamics. Leveraging these insights, for two distinct regimes depending on whether L is below or above a threshold, we derive different time bounds to guarantee nearzero prediction error. Despite convergence time depending on the task, we prove query tokens ultimately focus on highly relevant prompt tokens, demonstrating transformers' robust ICL capability.
|
| 24 |
+
|
| 25 |
+
# 1 INTRODUCTION
|
| 26 |
+
|
| 27 |
+
The transformer architecture [\(Vaswani et al., 2017\)](#page-11-0) has driven transformative advances across a wide spectrum of machine learning domains, including computer vision [\(Bi et al., 2021;](#page-9-0) [Han et al., 2022;](#page-10-0) [Goldblum et al., 2024\)](#page-10-1), natural language processing [\(Kalyan et al., 2021;](#page-10-2) [Tunstall et al., 2022\)](#page-11-1), and speech processing [\(Mehrish et al., 2023;](#page-11-2) [Latif et al., 2023\)](#page-10-3). A salient feature of transformers is their ability to perform new tasks without updating parameters, simply by conditioning on a few input-output examples—known as prompts. This capability, referred to as *in-context learning (ICL)*, enables models to generalize to unseen tasks purely through inference [\(Brown et al., 2020\)](#page-10-4).
|
| 28 |
+
|
| 29 |
+
ICL has attracted growing interest, with numerous empirical studies examining when transformers succeed or fail at in-context generalization [\(Xie et al., 2021;](#page-12-0) [Garg et al., 2022;](#page-10-5) [Von Oswald et al.,](#page-11-3) [2023;](#page-11-3) [Wu et al., 2023;](#page-12-1) [Li et al., 2024b;](#page-10-6) [Agarwal et al., 2024;](#page-9-1) [Park et al., 2025\)](#page-11-4). Notably, [Garg et al.](#page-10-5) [\(2022\)](#page-10-5) provided preliminary theoretical evidence that transformers trained on specific function classes (e.g., linear) can accurately infer a query function value from prompts containing variable–function pairs, highlighting transformers' surprising ability to "learn" within their forward pass and mimic classical function approximation.
|
| 30 |
+
|
| 31 |
+
Building on this foundation, subsequent works have provided *theoretical* understandings of ICL by characterizing the training dynamics of single-layer attention transformers [\(Mahankali et al., 2023;](#page-11-5) [Zhang et al., 2024;](#page-12-2) [Huang et al., 2024;](#page-10-7) [Collins et al., 2024;](#page-10-8) [Yang et al., 2024\)](#page-12-3). For instance, [Huang](#page-10-7) [et al.](#page-10-7) [\(2024\)](#page-10-7) consider softmax attention to analyze how attention weights evolve during training linear regression problems. More recent studies have theoretically shown that transformers can learn specific nonlinear function classes in-context, such as binary classification, low-degree polynomial regression, and Gaussian single-index models [\(Li et al., 2024a;](#page-10-9) [Yang et al., 2024;](#page-12-3) [Oko et al., 2024;](#page-11-6) [Sun](#page-11-7) [et al., 2025\)](#page-11-7). However, these studies do not provide a full theoretical picture of how the step-by-step learning process is governed by the task itself. To date, a formal characterization of the pre-training dynamics for general nonlinear ICL has been a key open problem.
|
| 32 |
+
|
| 33 |
+
{1}------------------------------------------------
|
| 34 |
+
|
| 35 |
+
In this work, we take a step toward understanding the *learning dynamics* for ICL on a broad class of nonlinear regression functions. We address two fundamental questions: (1) Which geometric properties of the target function govern the convergence behavior of transformer-based ICL? and (2) Despite nonlinearity and generality, how can a transformer learn in context to achieve low prediction error? We answer both by analyzing transformer training under gradient descent. Our main contributions are summarized below.
|
| 36 |
+
|
| 37 |
+
- Broad Class of Nonlinear Functions and Flexible Feature Sets: Our analysis generalizes previous studies in two ways. (i) Unlike prior theoretical works that focus on linear mappings (Zhang et al., 2024; Huang et al., 2024), binary classification (Li et al., 2024a), or low-degree polynomials (Sun et al., 2025), we characterize learning dynamics for a much broader family of non-degenerate L-Lipschitz task functions without assuming low complexity. This class is satisfied by almost any nontrivial L-Lipschitz function (e.g., scaled cosine, piecewise-polynomial, and small neural-network functions) and excludes only degenerate cases. (ii) Our results also hold for general feature embeddings without the restrictive orthonormality assumptions in prior work (Huang et al., 2024; Li et al., 2024a; Chen et al., 2024; Nichani et al., 2024).
|
| 38 |
+
- Phase Transition of Training Dynamics between Flat and Sharp Curvature Regimes: We discover a phase transition in training dynamics governed by the Lipschitz constant L. When L is below a threshold of order $\Theta\left(\frac{1}{\Delta\delta}\right)$ , the **flat curvature regime** yields smaller gradients and permits larger step sizes to converge. When L exceeds the threshold, the **sharp-curvature regime** produces larger gradients requiring smaller steps. The two regimes exhibit distinct convergence behaviors: although the flat regime may converge faster at high accuracy, sufficiently large L enhances feature separability, enabling accelerated training in the sharp regime.
|
| 39 |
+
- Convergence Guarantee for ICL with Nonlinear Regression Functions: We provide formal convergence guarantees for a one-layer softmax attention model learning nonlinear regression functions. We prove that gradient descent achieves near-zero training loss in polynomial time across both flat and sharp L-regimes. We also characterize the two-phase training dynamics: an early phase in which attention scores between query tokens and target features rise rapidly, and a later phase in which these scores converge to one while attention to irrelevant features decays more slowly with oscillations. At convergence, query tokens consistently attend to highly relevant prompt tokens, demonstrating the ICL capability of transformers.
|
| 40 |
+
- Novel Analysis Techniques: We develop new proof tools that explicitly connect the curvature of nonlinear task functions to the evolution of attention weights. In particular, we first decompose the prediction loss to explicitly relate it to attention weights and cross-feature gaps under nonlinear functions. We further show that the flat and sharp curvature regimes of the parameter L lead to distinct gradient magnitudes, which in turn drive different convergence rates and shape the overall training dynamics. The impact of function curvature on the magnitude and stability of attention updates is, to our knowledge, not addressed in previous ICL literature (Huang et al., 2024; Oko et al., 2024; Cheng et al., 2024).
|
| 41 |
+
|
| 42 |
+
# 2 RELATED WORKS
|
| 43 |
+
|
| 44 |
+
**In-context learning.** In-context learning (ICL) has emerged as a fundamental capability of transformer models, enabling dynamic task adaptation without parameter updates. The research community has approached ICL from several distinct yet complementary perspectives.
|
| 45 |
+
|
| 46 |
+
The Bayesian inference perspective, pioneered by Xie et al. (2021) and further developed by Zhang et al. (2023); Wang et al. (2023); Falck et al. (2024), establishes a theoretical framework linking prompting strategies to probabilistic reasoning. This line of work interprets ICL as a form of implicit Bayesian model averaging, where transformers effectively perform approximated inference conditioned on the provided context. Another line of ICL work focuses on Markov chains to study the behavior of induction heads for transformers, which are designed to copy or compare tokens that follow previous occurrences (Nichani et al., 2024; Bietti et al., 2023; Edelman et al., 2024; Rajaraman et al., 2024). The central focus is to understand how transformers recover latent sequence structures (Nichani et al., 2024) and transition rules (Ren & Liu, 2024; Li et al., 2023; Makkuva et al., 2024), using token-level recurrence and dynamics.
|
| 47 |
+
|
| 48 |
+
{2}------------------------------------------------
|
| 49 |
+
|
| 50 |
+
In contrast, the function learning perspective initiated by Garg et al. (2022) demonstrated transformers' remarkable ability to learn and interpolate simple function classes (particularly linear models) directly from context examples. This work sparked significant interest in understanding the mechanistic underpinnings of ICL, leading to important discoveries by Von Oswald et al. (2023) and Dai et al. (2022), who revealed deep connections between attention mechanisms and gradient-based optimization dynamics. Recent advances have substantially expanded our understanding of ICL mechanisms: Akyürek et al. (2023) provided a rigorous analysis of linear regression tasks, showing that trained transformers can implement both ridge regression gradient descent and exact least-squares solutions. Bai et al. (2023) established comprehensive theoretical results encompassing expressive power, prediction capabilities, and sample complexity, while proposing general mechanisms for algorithmic selection. Cheng et al. (2024) interprets transformers as implementing functional gradient descent for nonlinear regression, but their analysis primarily focuses on the representational capacity and functional viewpoint of the learned predictor, without analyzing the ICL pre-training dynamics.
|
| 51 |
+
|
| 52 |
+
Theoretical analysis of ICL learning dynamics. Recent theoretical work has made significant progress in understanding the pre-training dynamics of ICL in transformers, though important limitations remain (Huang et al., 2024; Li et al., 2024a; Collins et al., 2024; Yang et al., 2024; Sun et al., 2025; Lu et al., 2024; Edelman et al., 2024; Lin & Lee, 2024; Jeon et al., 2024; Park et al., 2025). The foundational work by Huang et al. (2024) established the first rigorous analysis of training dynamics for softmax attention in ICL settings, focusing on a single-head attention layer learning linear regression tasks. Their key theoretical result demonstrates that prompt tokens with features identical to the query token develop dominating attention weights during training. However, this analysis relies critically on strong assumptions about pairwise orthonormality of feature vectors and a normalized function scale, limiting its applicability to more general settings. Our work goes beyond this setting by showing that, for general nonlinear targets, the Lipschitz constant of the underlying function governs both the gradient evolution and the resulting convergence regimes. In this sense, our analysis includes the linear case as a special instance while providing a more fine-grained understanding of how function curvature influences attention-based learning.
|
| 53 |
+
|
| 54 |
+
Subsequent work extended these results to classification tasks (Li et al., 2024a), dual-head settings (Lin & Lee, 2024), and structured or hierarchical functions (Yang et al., 2024; Sun et al., 2025). Some studies explored the implicit bias of gradient descent and attention-based generalization (Collins et al., 2024; Lu et al., 2024), while others examined information-theoretic and dynamical aspects of ICL (Edelman et al., 2024; Jeon et al., 2024). Despite these advances, most analyses still rely on restrictive assumptions, such as orthonormality features, fixed positional encoding, or carefully structured input distributions, limiting their ability to explain ICL under general tasks and practical learning conditions.
|
| 55 |
+
|
| 56 |
+
**Notations.** In this paper, for a vector $\boldsymbol{v}$ , we let $\|\boldsymbol{v}\|_2$ denote its $\ell$ -2 norm. For some positive constant $C_1$ and $C_2$ , we define $x = \Omega(y)$ if $x > C_2|y|$ , $x = \Theta(y)$ if $C_1|y| < x < C_2|y|$ , and $x = \mathcal{O}(y)$ if $x < c_1|y|$ . We also denote by x = o(y) if $x/y \to 0$ . We use $\operatorname{poly}(C)$ to denote large constant degree polynomials of C. For a matrix A, we use $A_i$ to denote the i-th column of A, and $A_{i:j}$ to represent the collection of columns from the i-th to the j-th column (inclusive).
|
| 57 |
+
|
| 58 |
+
# <span id="page-2-1"></span>3 System Model
|
| 59 |
+
|
| 60 |
+
In this section, we formulate our system model, including the problem setup for in-context learning, the transformer architecture, and the associated training process.
|
| 61 |
+
|
| 62 |
+
## <span id="page-2-0"></span>3.1 IN-CONTEXT LEARNING PROBLEM SETUP
|
| 63 |
+
|
| 64 |
+
We consider a standard in-context learning (ICL) framework commonly used in prior studies (Garg et al., 2022; Huang et al., 2024; Yang et al., 2024). The objective is to train a transformer model that can perform ICL over a designated class of functions $\mathcal{F}$ , where each function $f \in \mathcal{F}$ corresponds to one task context. Here, we focus on *nonlinear* function classes further elaborated below.
|
| 65 |
+
|
| 66 |
+
Given each task (i.e., given one function f randomly sampled from $\mathcal{F}$ ), a prompt with a sequence of N input-response pairs $(x_i, y_i)$ as well as a query input $x_{\text{query}}$ are sampled, where $x_i \in \mathcal{X} \subseteq \mathbb{R}^d$ , and $y_i = f(x_i)$ . Let the input matrix $X = (x_1 \ x_2 \ \cdots \ x_N) \in \mathbb{R}^{d \times N}$ and the response vector $\mathbf{y} = (y_1 \ y_2 \ \cdots \ y_N) \in \mathbb{R}^{1 \times N}$ . We adopt the following standard prompt embedding (Garg et al.,
|
| 67 |
+
|
| 68 |
+
{3}------------------------------------------------
|
| 69 |
+
|
| 70 |
+
2022: Huang et al., 2024: Yang et al., 2024):
|
| 71 |
+
|
| 72 |
+
<span id="page-3-1"></span><span id="page-3-0"></span>
|
| 73 |
+
$$P = \begin{pmatrix} x_1 & x_2 & \cdots & x_N & x_{\text{query}} \\ y_1 & y_2 & \cdots & y_N & 0 \end{pmatrix} = \begin{pmatrix} X & x_{\text{query}} \\ \mathbf{y} & 0 \end{pmatrix} \in \mathbb{R}^{(d+1)\times(N+1)}. \tag{1}$$
|
| 74 |
+
|
| 75 |
+
**Non-degenerate** *L***-Lipschitz Regression Functions.** In this work, we focus on regression tasks, where each task is associated with a regression function drawn from the following set
|
| 76 |
+
|
| 77 |
+
$$\mathcal{F} = \left\{ f: \begin{array}{l} |f(x) - f(x')| \leq L ||x - x'||, & \forall ||x - x'|| = \Theta(\delta_0), \\ \forall v_k \in \mathbb{V}, \exists v_{k'} \in \mathbb{V}, \ k' \neq k, \ \text{such that} \ |f(v_k) - f(v_{k'})| = \Theta(L) \cdot ||v_k - v_{k'}|| \end{array} \right\},$$
|
| 78 |
+
|
| 79 |
+
$$(2)$$
|
| 80 |
+
|
| 81 |
+
where L>0 and $\delta_0=\mathcal{O}(1)$ . In particular, the functions in the class are said to satisfy **non-degenerate** L-**Lipschitz** condition, which imposes two natural requirements on the function class. First, the standard global L-Lipschitz condition ensures that the function f does not change too rapidly, which is common in the literature and includes a wide class of linear and nonlinear functions. Second, the separation requirement guarantees that for any feature $v_k$ in the set $\mathbb{V}$ , there exists at least one other feature $v_{k'}$ such that the function difference between them achieves the order of variation defined by the Lipschitz constant. This ensures sufficient distinguishability of features by the function class for guaranteed learnability. This mild separation assumption is satisfied by almost any nontrivial L-Lipschitz function (e.g., scaled cosine, piecewise-polynomial, and small neural-network functions) and excludes only degenerate cases. Together, these two conditions ensure that the function class is sufficiently rich for ICL while avoiding unlearnable or trivial scenarios.
|
| 82 |
+
|
| 83 |
+
For each prompt P, the task-specific function f(x) is independently drawn based on a task distribution $\mathcal{D}_f$ , as long as f(x) satisfies the property for the same L and $\delta_0$ in Eq. (2).
|
| 84 |
+
|
| 85 |
+
Feature Embeddings. Let $\mathbb{V}:=\{v_k\in\mathbb{R}^d|k=1,\cdots,K\}$ be the feature embeddings of tokens. For any $k\neq k'$ , we assume a separation of $\|v_k-v_{k'}\|=\Theta(\Delta)$ , where $\Delta=\Theta(1)$ . Each data sample x is modeled as a noisy perturbation of one of the vectors in $\mathbb{V}$ . This assumption lets us control the separation $\Delta$ precisely, simplifying the analysis while retaining the essential geometry of the problem. Such a condition can be satisfied by various feature learning techniques to avoid feature collapse, e.g., disentangled representation learning (Wang et al., 2022; 2024; Higgins et al., 2018). We note that such a condition substantially generalizes the orthonormality assumption taken by the previous study (Huang et al., 2024; Li et al., 2024a; Chen et al., 2024; Nichani et al., 2024). The prompt is sampled as follows. For a randomly chosen $v_k$ , we assume x satisfies $\|x-v_k\|=O(\epsilon_x)$ with probability $p_k$ , where $\epsilon_x=o(1)$ and $p_k=\Theta(\frac{1}{K})$ . For analytical simplicity, we assume $x=v_k$ whenever this proximity condition holds. In our experiments in Section 6, we further verify that our training dynamic analysis remains valid when tokens are drawn from general continuous distributions.
|
| 86 |
+
|
| 87 |
+
# 3.2 One-Layer Transformer
|
| 88 |
+
|
| 89 |
+
In this work, we adopt a one-layer transformer model for solving the ICL problem, which is commonly used in the existing theoretical ICL literature (e.g., Huang et al. (2024); Li et al. (2024a); Yang et al. (2024); Sun et al. (2025)). A self-attention transformer with width $d_e$ consists of a key matrix $W^K \in \mathbb{R}^{d_e \times d_e}$ , a query matrix $W^Q \in \mathbb{R}^{d_e \times d_e}$ , and a value matrix $W^V \in \mathbb{R}^{d_e \times d_e}$ . For a given prompt P of length N in Eq. (1), the self-attention layer outputs:
|
| 90 |
+
|
| 91 |
+
$$F(P; W^K, W^Q, W^V) = W^V P \times \operatorname{softmax} \left( (W^K P)^\top W^Q P \right). \tag{3}$$
|
| 92 |
+
|
| 93 |
+
where the softmax(·) function is applied column-wisely, i.e., for a vector input z, the i-th entry of softmax(z) is given by softmax( $z_i$ ) = $\frac{\exp(z_i)}{\sum_i \exp(z_j)}$ .
|
| 94 |
+
|
| 95 |
+
We further take the following re-parameterization, commonly adopted by the recent theoretical studies of transformers (e.g. Zhang et al. (2024); Huang et al. (2024); Yang et al. (2024); Sun et al. (2025)), which combines the query and key matrices into a single matrix $W^{KQ} \in \mathbb{R}^{(d+1)\times (d+1)}$ , and further specify the weight matrices as follows:
|
| 96 |
+
|
| 97 |
+
$$W^V = \begin{pmatrix} 0_{d \times d} & 0_d \\ 0_d^\top & 1 \end{pmatrix}, \quad W^{KQ} = \begin{pmatrix} Q & 0_d \\ 0_d^\top & 0 \end{pmatrix},$$
|
| 98 |
+
|
| 99 |
+
where $Q \in \mathbb{R}^{d \times d}$ is the trainable weight matrix. These simplifications, while not capturing the full complexity of deep, multi-head models, are standard in the theoretical literature and serve two crucial purposes. First, they allow for a tractable analysis that isolates the core dynamics of the softmax
|
| 100 |
+
|
| 101 |
+
{4}------------------------------------------------
|
| 102 |
+
|
| 103 |
+
217
|
| 104 |
+
|
| 105 |
+
218
|
| 106 |
+
|
| 107 |
+
219
|
| 108 |
+
|
| 109 |
+
220
|
| 110 |
+
|
| 111 |
+
221
|
| 112 |
+
|
| 113 |
+
222
|
| 114 |
+
|
| 115 |
+
224
|
| 116 |
+
|
| 117 |
+
225 226
|
| 118 |
+
|
| 119 |
+
227
|
| 120 |
+
|
| 121 |
+
229 230
|
| 122 |
+
|
| 123 |
+
231 232
|
| 124 |
+
|
| 125 |
+
233
|
| 126 |
+
|
| 127 |
+
234 235
|
| 128 |
+
|
| 129 |
+
236
|
| 130 |
+
|
| 131 |
+
237
|
| 132 |
+
|
| 133 |
+
238
|
| 134 |
+
|
| 135 |
+
239 240 241
|
| 136 |
+
|
| 137 |
+
242 243
|
| 138 |
+
|
| 139 |
+
244
|
| 140 |
+
|
| 141 |
+
245
|
| 142 |
+
|
| 143 |
+
246
|
| 144 |
+
|
| 145 |
+
247
|
| 146 |
+
|
| 147 |
+
248
|
| 148 |
+
|
| 149 |
+
249
|
| 150 |
+
|
| 151 |
+
250
|
| 152 |
+
|
| 153 |
+
251
|
| 154 |
+
|
| 155 |
+
253
|
| 156 |
+
|
| 157 |
+
254
|
| 158 |
+
|
| 159 |
+
256
|
| 160 |
+
|
| 161 |
+
257
|
| 162 |
+
|
| 163 |
+
258
|
| 164 |
+
|
| 165 |
+
259
|
| 166 |
+
|
| 167 |
+
260 261
|
| 168 |
+
|
| 169 |
+
264
|
| 170 |
+
|
| 171 |
+
265
|
| 172 |
+
|
| 173 |
+
267
|
| 174 |
+
|
| 175 |
+
268
|
| 176 |
+
|
| 177 |
+
attention mechanism, which is central to ICL. Second, this setup follows a line of foundational work that has successfully used similar models to derive key insights into ICL for linear regression. By building on this framework, we can directly investigate the impact of nonlinearity. We acknowledge that extending our analysis to multi-layer and multi-head settings is an important avenue for future work. Such structured matrices separate out the impact of inputs and responses and have been justified to achieve the global or nearly global optimum for both linear and softmax attention models in Zhang et al. (2024) and Huang et al. (2024). Then the self-attention mapping becomes
|
| 178 |
+
|
| 179 |
+
<span id="page-4-0"></span>
|
| 180 |
+
$$F(P;Q) = \mathbf{y} \cdot \operatorname{softmax}(X^{\top} Q \bar{X}), \tag{4}$$
|
| 181 |
+
|
| 182 |
+
where we further let $\bar{X}=(x_1 \quad x_2 \quad \cdots \quad x_N \quad x_{\text{query}}) \in \mathbb{R}^{d \times N+1}$ and $\mathbf{y}=(y_1 \quad y_2 \quad \cdots \quad y_N) \in \mathbb{R}^{d \times N+1}$ $\mathbb{R}^{d \times N}$ . The prediction $\hat{y}_{\text{query}}$ corresponding to $x_{\text{query}}$ is given by the last entry of $F(P;Q)_{N+1}$ , i.e., $\hat{y}_{\text{query}} = F(P;Q)_{N+1}$ . To train the attention model on the ICL problem introduced in Section 3.1, we minimize the following squared loss between the predicted and true responses:
|
| 183 |
+
|
| 184 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \mathbb{E} \left[ \left( F(P;Q)_{N+1} - f(x_{\text{query}}) \right)^2 \right], \tag{5}$$
|
| 185 |
+
|
| 186 |
+
$\mathcal{L}(P;Q) = \frac{1}{2}\mathbb{E}\Big[\big(F(P;Q)_{N+1} - f(x_{\text{query}})\big)^2\Big], \tag{5}$ where the expectation is taken over the randomly sampled prompt $\{x_i\}_{i=1}^N \cup \{x_{\text{query}}\}$ and randomly sampled function $f \in \mathcal{F}$ that determines the corresponding ground-truth responses.
|
| 187 |
+
|
| 188 |
+
We optimize this loss via gradient descent (GD). Let vec(Q) denote the vector that stacks all entries of Q. At t = 0, we initialize $vec(Q)^{(0)}$ as the zero matrix $0_{d^2}$ . The parameter is updated as follows:
|
| 189 |
+
|
| 190 |
+
$$\operatorname{vec}(Q)^{(t+1)} = \operatorname{vec}(Q)^{(t)} - \eta \nabla_{\operatorname{vec}(Q)} \mathcal{L}(P; \operatorname{vec}(Q)^{(t)}). \tag{6}$$
|
| 191 |
+
|
| 192 |
+
where $\eta > 0$ is the learning rate. Note that we require $\eta$ to be smaller than a universal constant (e.g., $\eta < 1$ ) to ensure stability of the update and to preserve the convergence behavior analyzed in Section 5. Based on this model setup and training procedure, we proceed to present our main theoretical results concerning ICL under nonlinear regression tasks.
|
| 193 |
+
|
| 194 |
+
# MAIN RESULTS OF ICL CONVERGENCE
|
| 195 |
+
|
| 196 |
+
Our analysis proceeds by decomposing the loss function into interpretable quantities that directly reflect cluster separation and the Lipschitz constant L in Eq. (2). Interestingly, we observe that the flat and sharp regimes of L give rise to distinct convergence dynamics, with a threshold transition separating the two regimes based on the order of magnitude of L. In the flat regime (small L), the gradient on Q matrices remains small, leading to slow but steady concentration of attention weights. In the sharp regime (large L), we show a rapid growth phase where the query-key inner products amplify differences between clusters before settling into a slow fine-tuning phase. For the two regimes, we provide explicit convergence-time bounds and characterize the phase transition. Compared with prior analyses restricted to linear tasks or orthogonal features, our framework extends to general nonlinear Lipschitz tasks and explains qualitatively different dynamics observed in practice.
|
| 197 |
+
|
| 198 |
+
Recall from Section 3.1 that each token $x_i$ corresponds to a noisy version of a feature $v_k \in \mathbb{V}$ with probability $p_k = \Theta\left(\frac{1}{K}\right)$ for any $k \in [K]$ . Let $P_{1:N}$ denote the collection of input tokens in P, i.e., $\{x_i\}_{i=1}^N$ , and denote $\mathcal{V}_k \subset [N]$ as the index set for input tokens, such that $x_i = v_k$ for $i \in \mathcal{V}_k$ . We define the following concentration set of token sequences where each feature appears with approximately the expected frequency:
|
| 199 |
+
|
| 200 |
+
<span id="page-4-1"></span>
|
| 201 |
+
$$\mathcal{E}^* := \left\{ P_{1:N} : |\mathcal{V}_k| \in \left[ (p_k - \delta)N, (p_k + \delta)N \right] \text{ for } k \in [K] \right\}, \tag{7}$$
|
| 202 |
+
|
| 203 |
+
where $\delta \geq \sqrt{\frac{20K}{N}}$ . Then, for any $0 < \epsilon < 1$ , suppose $N \geq \Theta(K^3)$ and $K \geq \Theta(\frac{1}{\epsilon})$ . For any $t \in [T]$ , we have the concentration probability satisfies $\mathbb{P}(P_{1:N} \in \mathcal{E}^*) \ge 1 - 3 \exp\left(-\frac{\delta^2 N}{25}\right)$ . This implies that, with high probability, each feature class $k \in [K]$ is approximately equally represented in the prompt P, ensuring a balanced token distribution. Such balance is crucial for the convergence of ICL, as it allows the attention to learn effectively from all feature types without introducing bias. While our analysis is expressed in terms of the population risk in Eq. (5), the concentration event in Eq. (7) ensures that the empirical prompt distribution closely matches the population distribution when N is sufficiently large. Under this event, the curvature-driven attention dynamics characterized later in our theory remain accurate up to standard $\mathcal{O}(1/\sqrt{N})$ fluctuations. Thus, the population-level analysis offers a faithful description of the finite-sample training behavior for prompts of moderate size.
|
| 204 |
+
|
| 205 |
+
{5}------------------------------------------------
|
| 206 |
+
|
| 207 |
+
271
|
| 208 |
+
|
| 209 |
+
272
|
| 210 |
+
|
| 211 |
+
273 274
|
| 212 |
+
|
| 213 |
+
275 276
|
| 214 |
+
|
| 215 |
+
277
|
| 216 |
+
|
| 217 |
+
278
|
| 218 |
+
|
| 219 |
+
279
|
| 220 |
+
|
| 221 |
+
280
|
| 222 |
+
|
| 223 |
+
281 282
|
| 224 |
+
|
| 225 |
+
284
|
| 226 |
+
|
| 227 |
+
285
|
| 228 |
+
|
| 229 |
+
286
|
| 230 |
+
|
| 231 |
+
287
|
| 232 |
+
|
| 233 |
+
289
|
| 234 |
+
|
| 235 |
+
290
|
| 236 |
+
|
| 237 |
+
291 292 293
|
| 238 |
+
|
| 239 |
+
295
|
| 240 |
+
|
| 241 |
+
296
|
| 242 |
+
|
| 243 |
+
297
|
| 244 |
+
|
| 245 |
+
298
|
| 246 |
+
|
| 247 |
+
301
|
| 248 |
+
|
| 249 |
+
302
|
| 250 |
+
|
| 251 |
+
303
|
| 252 |
+
|
| 253 |
+
304
|
| 254 |
+
|
| 255 |
+
305 306 307
|
| 256 |
+
|
| 257 |
+
308
|
| 258 |
+
|
| 259 |
+
310
|
| 260 |
+
|
| 261 |
+
311
|
| 262 |
+
|
| 263 |
+
312
|
| 264 |
+
|
| 265 |
+
313 314
|
| 266 |
+
|
| 267 |
+
315 316 317
|
| 268 |
+
|
| 269 |
+
318
|
| 270 |
+
|
| 271 |
+
319
|
| 272 |
+
|
| 273 |
+
320
|
| 274 |
+
|
| 275 |
+
321
|
| 276 |
+
|
| 277 |
+
Given balanced feature inputs, we now quantify how much the query token $x_{query}$ attends to specific input tokens or feature classes. We define the attention score for a query token to attend to the i-th token in the prompt as $\operatorname{attn}_i^{(t)} := \operatorname{softmax}(x_i^\top Q^{(t)} x_{\operatorname{query}})$ and the total attention paid to all tokens with feature $v_k$ as $\operatorname{Attn}_k^{(t)} := \sum_{i:x_i=v_k} \operatorname{attn}_i^{(t)}$ . With this notation, the transformer's output at t is
|
| 278 |
+
|
| 279 |
+
<span id="page-5-4"></span><span id="page-5-0"></span>
|
| 280 |
+
$$\hat{y}_{\text{query}} = \sum_{i \in [N]} \operatorname{attn}_{i}^{(t)} y_{i} = \sum_{k \in [K]} \operatorname{Attn}_{k}^{(t)} f(v_{k}). \tag{8}$$
|
| 281 |
+
|
| 282 |
+
Building on the expression in Eq. (8), we characterize how the attention scores influence the prediction loss defined in Eq. (5) in the following lemma.
|
| 283 |
+
|
| 284 |
+
<span id="page-5-1"></span>**Lemma 1.** Given constants $L, \Delta > 0$ , the prediction loss in Eq. (5) can be expressed as:
|
| 285 |
+
|
| 286 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( 1 - \operatorname{Attn}_{k}^{(t)} \right)^2 \cdot \mathcal{O}(L^2 \Delta^2) \right], \ \forall t \in [T],$$
|
| 287 |
+
(9) where $\mathbb{1} \{ x_{\text{query}} = v_k \} = 1$ is the indicator function that equals 1 if $x_{\text{query}} = v_k$ and 0 otherwise.
|
| 288 |
+
|
| 289 |
+
The proof of Lemma 1 is given in Appendix C. This expression reveals that loss $\mathcal{L}(P;Q)$ depends on the Lipschitz constant L, the feature gap $\Delta$ , and the attention score $\operatorname{Attn}_k^{(t)}$ associated with the true feature of the query token. The dependence on L, which captures the function's curvature, distinguishes our analysis from prior theoretical work on ICL (e.g., Huang et al. (2024); Oko et al. (2024); Sun et al. (2025)). For a given feature gap $\Delta$ , different function Lipschitz constants L can lead to distinct convergence behaviors of ICL. In the following theorem, we first provide the $\epsilon^2$ -convergence of $\mathcal{L}(P;Q)$ in the flat L-regime, where L is below a certain threshold.
|
| 290 |
+
|
| 291 |
+
<span id="page-5-2"></span>**Theorem 1** (Flat L-regime). Suppose the function class in Eq. (2) satisfies $L \leq \Theta\left(\frac{1}{\Delta\delta}\right)$ . Then, for any $0 < \epsilon < 1$ and under $N \geq \Theta(K^3)$ and $K \geq \Theta(\frac{1}{\epsilon})$ , with at most $T_f^* = \Theta(\frac{K \log(K\epsilon^{-1})}{\eta \delta^2 L^2 \Delta^2})$ iterations, we have $\mathcal{L}(P;Q) \leq \mathcal{O}(\epsilon^2)$ .
|
| 292 |
+
|
| 293 |
+
The proof of Theorem 1 is given in Appendix E.3. Theorem 1 indicates that $T_f^*$ decreases (i.e., the convergence is faster) as either the Lipschitz constant L or the feature gap $\Delta$ increases. Intuitively, a larger function Lipschitz constant L implies that the outputs $y_i$ and $y_{i'}$ corresponding to different features in the prompt P become more distinguishable, which facilitates faster in-context learning. Similarly, a larger feature gap $\Delta$ improves the separability among features, enabling the query token to more accurately attend to the relevant prompt tokens.
|
| 294 |
+
|
| 295 |
+
However, when L exceeds a certain threshold, the caused sharp curvature induces large gradients on the attention weights. As a result, a smaller stepsize is required to stabilize convergence, leading to a convergence rate that differs from that in the flat regime. We next establish the $\epsilon^2$ -convergence of $\mathcal{L}(P;Q)$ in the sharp L regime, where L is above the threshold.
|
| 296 |
+
|
| 297 |
+
<span id="page-5-3"></span>**Theorem 2** (Sharp L-regime). Suppose the function class in Eq. (2) satisfies $L = \Omega(\frac{1}{\Delta\delta})$ . Then for any $0 < \epsilon < 1$ , under $N = \Omega(K^3)$ and $K \ge \Theta(\frac{1}{\epsilon})$ , with at most $T_s^* = \Theta(\frac{K \log(K\epsilon^{-1}L\Delta)}{n\epsilon\delta^2L^2\Delta^2})$ iterations, we have $\mathcal{L}(P;Q) = \mathcal{O}(\epsilon^2)$
|
| 298 |
+
|
| 299 |
+
The proof of Theorem 2 is given in Appendix F.2. Theorem 1 and Theorem 2 together reveal an interesting **phase transition phenomenon**: the convergence dynamics are governed by how the function Lipschitz constant L compares to a threshold of order $\Theta\left(\frac{1}{\Delta\delta}\right)$ . In the **flat curvature regime**, where L is below this threshold, convergence allows larger step sizes due to smaller gradients, resulting in a convergence rate of $\tilde{\Theta}\left(\frac{K}{\eta\delta^2L^2\Delta^2}\right)$ . In contrast, in the **sharp curvature regime**, where L is above the threshold, the large L incurs large gradients which thus require smaller step sizes to stabilize convergence, yielding a convergence rate of $\tilde{\Theta}\left(\frac{K}{\eta\epsilon\delta^2L^2\Delta^2}\right)$ . Comparing the two convergence upper bounds, neither $T_f^*$ nor $T_s^*$ always dominates. The sharp regime benefits from a larger L, giving a smaller denominator and faster convergence, but its bound also contains an extra $\frac{1}{\epsilon}$ factor that can dominate when high accuracy is required. Therefore, depending on the relative scales of $L, \epsilon$ , and $\Delta$ , either regime may achieve the smaller convergence upper bound.
|
| 300 |
+
|
| 301 |
+
In cases where the query is not a small perturbation of any feature vector, the model must represent the query using a combination of multiple feature clusters rather than relying on a single dominant one. This setting is more challenging because the nonlinear function values evolve over training, causing the optimal attention pattern to shift across clusters. Nevertheless, the curvature-dependent
|
| 302 |
+
|
| 303 |
+
{6}------------------------------------------------
|
| 304 |
+
|
| 305 |
+
325
|
| 306 |
+
|
| 307 |
+
326
|
| 308 |
+
|
| 309 |
+
327
|
| 310 |
+
|
| 311 |
+
328
|
| 312 |
+
|
| 313 |
+
330
|
| 314 |
+
|
| 315 |
+
332 333
|
| 316 |
+
|
| 317 |
+
334
|
| 318 |
+
|
| 319 |
+
335
|
| 320 |
+
|
| 321 |
+
336
|
| 322 |
+
|
| 323 |
+
338 339
|
| 324 |
+
|
| 325 |
+
340 341
|
| 326 |
+
|
| 327 |
+
342
|
| 328 |
+
|
| 329 |
+
343
|
| 330 |
+
|
| 331 |
+
344 345
|
| 332 |
+
|
| 333 |
+
346 347
|
| 334 |
+
|
| 335 |
+
348 349
|
| 336 |
+
|
| 337 |
+
350
|
| 338 |
+
|
| 339 |
+
351
|
| 340 |
+
|
| 341 |
+
352 353
|
| 342 |
+
|
| 343 |
+
354
|
| 344 |
+
|
| 345 |
+
355
|
| 346 |
+
|
| 347 |
+
356 357
|
| 348 |
+
|
| 349 |
+
358
|
| 350 |
+
|
| 351 |
+
359 360 361
|
| 352 |
+
|
| 353 |
+
362
|
| 354 |
+
|
| 355 |
+
364
|
| 356 |
+
|
| 357 |
+
366
|
| 358 |
+
|
| 359 |
+
367
|
| 360 |
+
|
| 361 |
+
368
|
| 362 |
+
|
| 363 |
+
369
|
| 364 |
+
|
| 365 |
+
370 371
|
| 366 |
+
|
| 367 |
+
372
|
| 368 |
+
|
| 369 |
+
373
|
| 370 |
+
|
| 371 |
+
374 375
|
| 372 |
+
|
| 373 |
+
376
|
| 374 |
+
|
| 375 |
+
377
|
| 376 |
+
|
| 377 |
+
gradient behavior established in our analysis continues to govern the convergence rate, even though the precise attention trajectory becomes harder to characterize.
|
| 378 |
+
|
| 379 |
+
Based on the convergence results above, we now characterize the behavior of the attention score $Attn_k^{(t)}$ at convergence to explain why the ICL output corresponds to an accurate prediction.
|
| 380 |
+
|
| 381 |
+
<span id="page-6-1"></span>**Proposition 1.** After the prediction loss converges to $\mathcal{L}(P;Q) = \mathcal{O}(\epsilon^2)$ for any $0 < \epsilon < 1$ , if the query token satisfies $x_{\text{query}} = v_k$ , then the attention score associated with feature $v_k$ satisfies $1 - \operatorname{Attn}_{k}^{(t)} = \mathcal{O}(\epsilon).$
|
| 382 |
+
|
| 383 |
+
The proof of Proposition 1 is given in Appendix G. This result follows directly from the loss expression in Eq. (9), where $\mathcal{L}(P;Q) = \Theta((1-\operatorname{Attn}_k^{(t)})^2)$ when $x_{\text{query}} = v_k$ . Intuitively, as $Attn_k^{(t)}$ approaches 1, the attention matrix effectively focuses predominantly on the tokens that share the same feature $v_k$ . As a result, the predicted output $\hat{y}_{query}$ , given by Eq. (8), closely approximates the true value $f(v_k)$ , leading to high-accuracy predictions.
|
| 384 |
+
|
| 385 |
+
# <span id="page-6-0"></span>ANALYSIS OF CONVERGENCE DYNAMICS
|
| 386 |
+
|
| 387 |
+
As established in Theorem 1 and Theorem 2, different regimes of the Lipschitz constant L lead to distinct convergence behaviors in ICL. In this section, we analyze the training dynamics under both regimes, highlighting how the Lipschitz constant L influences the convergence rate in each case.
|
| 388 |
+
|
| 389 |
+
#### **GRADIENTS OF ATTENTION WEIGHTS**
|
| 390 |
+
|
| 391 |
+
Based on the prediction output $\hat{y}_{\text{query}}$ in Eq. (5), the attention scores $\text{attn}_i$ play a critical role in determining the final prediction. To precisely characterize these attention scores for any $i \in [N]$ , it is sufficient to characterize the training dynamics of the attention weights $q_{k,k'}^{(t)} := v_{k'}^{\top} Q^{(t)} v_k$ for $k, k' \in [K]$ , which are initialized as $q_{k,k'}^{(0)} = 0$ for any $k, k' \in [K]$ . To simplify notations, we denote the $q_{k,k}^{(t)}$ as $q_k^{(t)}$ for k'=k. According to the definition of the attention score $\operatorname{attn}_i^{(t)}$ in Eq. (8), when $x_{\text{query}}^{(t)} = v_k$ , the quantity $q_k^{(t)}$ measures how strongly the query token attends to the target feature $v_k$ , while $q_{k k'}^{(t)}$ reflects the attention given to a different feature $v_{k'}$ with $k' \neq k$ . To achieve the desired attention behavior, effective training should increase $q_k^{(t)}$ while suppressing $q_{k,k'}^{(t)}$
|
| 392 |
+
|
| 393 |
+
The convergence behavior of the transformer depends on the dynamics of $q_k^{(t)}$ and $q_{k,k'}^{(t)}$ . We therefore proceed to analyze how these quantities evolve during training. To this end, we define the gradient updates for $q_k^{(t)}$ and $q_{k,k'}^{(t)}$ as $g_k^{(t)}$ and $g_{k,k'}^{(t)}$ , respectively. Under gradient descent with learning rate $\eta$ , the update rules are given by:
|
| 394 |
+
|
| 395 |
+
<span id="page-6-4"></span><span id="page-6-3"></span>
|
| 396 |
+
$$q_k^{(t+1)} := q_k^{(t)} + \eta g_k^{(t)}, \qquad q_{k k'}^{(t+1)} := q_{k k'}^{(t)} + \eta g_{k k'}^{(t)}.$$
|
| 397 |
+
|
| 398 |
+
$q_k^{(t+1)} := q_k^{(t)} + \eta g_k^{(t)}, \qquad q_{k,k'}^{(t+1)} := q_{k,k'}^{(t)} + \eta g_{k,k'}^{(t)}.$ We now present the following lemma, which provides the exact expressions for the gradient terms $g_k^{(t)}$ and $g_{k,k'}^{(t)}$ for a function class ${\mathcal F}$ with Lipschitz constant L.
|
| 399 |
+
|
| 400 |
+
<span id="page-6-2"></span>**Lemma 2.** For any $t \in [T]$ , suppose $x_{query} = v_k$ . Then for any $k, k' \in [K]$ with $k' \neq k$ , we obtain
|
| 401 |
+
|
| 402 |
+
$$g_k^{(t)} = \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} \operatorname{Attn}_k^{(t)} \left(1 - \operatorname{Attn}_k^{(t)}\right)^2 \cdot \Theta(L^2 \Delta^2)\right],\tag{10}$$
|
| 403 |
+
|
| 404 |
+
$$|g_{k,k'}^{(t)}| = \mathbb{E}\left[\mathbb{1}\{x_{\text{query}}^{(t)} = v_k\} \text{Attn}_{k'}^{(t)} \cdot (1 - \text{Attn}_{k}^{(t)}) \cdot (1 - \text{Attn}_{k'}^{(t)}) \cdot \Theta(L^2 \Delta^2)\right]. \tag{11}$$
|
| 405 |
+
|
| 406 |
+
The proof of Lemma 2 is given in Appendix D. From Eq. (10), we observe that $g_k^{(t)}$ is always non-negative, implying that the update $q_k^{(t)}$ increases over time. This growth continues until the attention score $Attn_k^{(t)}$ approaches its convergence state near 1. However, $g_{k,k'}^{(t)}$ in Eq. (11) is not necessarily positive and also depends on $Attn_{k'}^{(t)}$ associated with feature vector $v_{k'}$ . However, as $Attn_k^{(t)}$ approaches 1, the residual term in Eq. (11) diminishes, and $g_{k,k'}^{(t)}$ also converges toward zero, facilitating the overall convergence of the system.
|
| 407 |
+
|
| 408 |
+
{7}------------------------------------------------
|
| 409 |
+
|
| 410 |
+
As also shown in Lemma 2, both gradients scale with the Lipschitz constant L and the feature gap $\Delta$ , illustrating their influence on the training dynamics. In the following subsections, we analyze how different regimes of the function Lipschitz constant L (with respect to the threshold determined by $\Delta$ ) affect the evolution of $q_k^{(t)}$ and $q_{k,k'}^{(t)}$ , through the gradients $g_k^{(t)}$ and $g_{k,k'}^{(t)}$ , thereby offering deeper insight into the convergence results established in Theorem 1 and Theorem 2.
|
| 411 |
+
|
| 412 |
+
#### 5.2 Convergence Dynamics under Flat L-Regime
|
| 413 |
+
|
| 414 |
+
For ease of exposition, we consider the case where $x_{\mathrm{query}} = v_k$ in the following. Under the initialization of $q_k^{(0)} = q_{k,k'}^{(0)} = 0$ , and by the definition of the attention score, we have $\mathrm{attn}_n^{(0)} = \frac{1}{N}$ for all $n \in [N]$ , meaning that the transformer initially attends equally to all input tokens when computing the prediction for $x_{\mathrm{query}}$ . We then leverage the task distribution in Eq. (2) and the gradient expressions in Lemma 2 to analyze the learning dynamics of $q_k^{(t)}$ and $q_{k,k'}^{(t)}$ .
|
| 415 |
+
|
| 416 |
+
In the initial phase of training, the prediction $\hat{y}_{\text{query}}$ is far from the ground truth $f(v_k)$ due to the zero initialization of bilinear weights. According to Eq. (10), this results in a large positive gradient $g_k^{(t)}$ , leading to a rapid increase in $q_k^{(t)}$ . In contrast, the gradient $g_{k,k'}^{(t)}$ may fluctuate in sign depending on the alignment of $f(v_k)$ and $f(v_{k'})$ at each step, causing $q_{k,k'}^{(t)}$ to oscillate but decrease much more slowly. We formally characterize this phase below.
|
| 417 |
+
|
| 418 |
+
<span id="page-7-0"></span>**Proposition 2** (Phase I: Fast growth of $q_k^{(t)}$ ). For any $t \in \{1, \cdots, T_f^1\}$ and $k \in [K]$ , where $T_f^1 = \Theta(\frac{K \log(K)}{\eta L^2 \Delta^2})$ , the attention weight $q_k^{(t)}$ increases at a rate of $\Theta(\frac{\eta L^2 \Delta^2}{K})$ . Meanwhile, $q_{k,k'}^{(t)}$ oscillates at a slower rate of $O(\frac{\eta L^2 \Delta^2}{K^2})$ and exhibits an overall decreasing trend. By the end of Phase I (i.e., $t = T_f^1 + 1$ ), we have $\operatorname{Attn}_k^{(T_f^1 + 1)} = \Omega(\frac{1}{1 + \delta})$ .
|
| 419 |
+
|
| 420 |
+
The proof of Proposition 2 is given in Appendix E.1. According to Proposition 2, Phase I ends once $q_k^{(t)}$ becomes sufficiently large to reduce the prediction gap between the ICL output and the ground truth function value. After this point, both $g_k^{(t)}$ in Eq. (10) and $|g_{k,k'}^{(t)}|$ in Eq. (11) decrease to smaller orders. During this phase, both $g_k^{(t)}$ and $|g_{k,k'}^{(t)}|$ increase with L, as a larger function Lipschitz constant induces greater residual values in Eq. (10) and Eq. (11). Likewise, a larger feature gap $\Delta$ amplifies the value difference between $f(v_k)$ and $f(v_{k'})$ (by Eq. (2)), which in turn accelerates attention learning in Phase I. As a result, the duration $T_f^1$ decreases with both L and $\Delta$ .
|
| 421 |
+
|
| 422 |
+
However, at $t=T_f^1$ , the prediction loss in Eq. (5) may still remain non-negligible. As a result, the attention score $\operatorname{Attn}_k^{(t)}$ requires a period of steady improvement after $t=T_f^1+1$ . We now formalize this behavior in the second training phase in the following proposition.
|
| 423 |
+
|
| 424 |
+
<span id="page-7-1"></span>**Proposition 3** (Phase II: Steady growth of $q_k^{(t)}$ under flat L-regime). For any $t \in \{T_f^1+1,\cdots,T_f^*\}$ and $0 < \epsilon < 1$ , where $T_f^* = \Theta(\frac{K \log(K\epsilon^{-1})}{\eta \delta^2 L^2 \Delta^2})$ , for any $k \in [K]$ , $q_k^{(t)}$ continues to grow at a steady rate of $\Theta\left(\frac{\eta \delta^2 L^2 \Delta^2}{K}\right)$ . Meanwhile, $q_{k,k'}^{(t)}$ oscillates at a slower rate of $O\left(\frac{\eta \delta^2 L^2 \Delta^2}{K^2}\right)$ and exhibits an overall decreasing trend. At $t = T_f^* + 1$ , if L satisfies $L \leq \Theta(\frac{1}{\Delta \delta})$ in Eq. (2), we have $\operatorname{Attn}_k^{(T_f^*+1)} = \Omega(\frac{1}{1+\epsilon\delta})$ .
|
| 425 |
+
|
| 426 |
+
The proof of Proposition 3 is given in Appendix E.2. According to Proposition 3, if the Lipschitz constant is sufficiently small such that $L \leq \Theta(\frac{1}{\Delta\delta})$ , then by the end of Phase II, the attention score satisfies $1 - \operatorname{Attn}_k^{(T_f^*+1)} = \mathcal{O}\left(\frac{\epsilon\delta}{1+\epsilon\delta}\right) = \mathcal{O}(\epsilon)$ , indicating that the transformer has converged.
|
| 427 |
+
|
| 428 |
+
### 5.3 Phase Transition under Sharp L-Regime
|
| 429 |
+
|
| 430 |
+
In the sharp curvature regime where $L=\Omega(\frac{1}{\Delta\delta})$ , the update $q_k^{(t)}$ increases at a rate of $\Theta(\frac{\eta}{K})$ for all $t\leq T_f^*$ . Let $T_s^1$ denote the duration of Phase I in this regime. Since this early-stage growth (Phase I) mirrors the dynamics under the flat L-regime before $T_f^*$ , we have $T_s^1=T_f^*=\Theta(\frac{K\log(K\epsilon^{-1})}{\eta\delta^2L^2\Delta^2})$ .
|
| 431 |
+
|
| 432 |
+
{8}------------------------------------------------
|
| 433 |
+
|
| 434 |
+
<span id="page-8-2"></span>
|
| 435 |
+
|
| 436 |
+
<span id="page-8-6"></span><span id="page-8-5"></span><span id="page-8-4"></span><span id="page-8-3"></span>set. L-set. flat <math>L=0.1. sharp L=1.
|
| 437 |
+
|
| 438 |
+
Figure 1: Training dynamics of prediction losses (top) and attention scores (bottom) for two sets of L: flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ).
|
| 439 |
+
|
| 440 |
+
However, this initial Phase is insufficient for achieving convergence due to the residual error term proportional to $L \cdot \Delta$ in Eq. (9). Consequently, training transitions into a second phase (Phase III), during which both gradient terms $g_k^{(t)}$ and $g_{k,k'}^{(t)}$ become small. This leads to a slower growth rate of $q_k^{(t)}$ compared to the earlier phase. We characterize this slower training phase as follows.
|
| 441 |
+
|
| 442 |
+
<span id="page-8-1"></span>**Proposition 4** (Phase III: Slow growth of $q_k^{(t)}$ under sharp L-regime). If $L = \Omega(\frac{1}{\Delta\delta})$ , then for any $t \in \{T_s^1+1,\cdots,T_s^*\}$ and $0 < \epsilon < 1$ , where $T_s^* = \Theta(\frac{K\log(KL\Delta\epsilon^{-1})}{\eta\epsilon\delta^2L^2\Delta^2})$ , for any $k \in [K]$ , $q_k^{(t)}$ increases at a rate of $\Theta(\frac{\eta\delta^2L^2\Delta^2\epsilon}{K})$ . Meanwhile, $q_{k,k'}^{(t)}$ fluctuates at a slower rate of $O(\frac{\eta\delta^2L^2\Delta^2\epsilon}{K^2})$ . By the end of Phase II (i.e. $t = T_s^* + 1$ ), we have $\operatorname{Attn}_k^{(T_s^*+1)} = \Omega(\frac{1}{1+\epsilon\delta})$ .
|
| 443 |
+
|
| 444 |
+
The proof of Proposition 4 is given in Appendix F.1. To ensure convergence of the prediction loss, the update step size of $q_k^{(t)}$ decreases to an order dependent on $\epsilon$ in Phase II. This is because, under the sharp L-regime where $\delta^2 L^2 \Delta^2 = \Omega(1)$ , the gradients become large, as established in Lemma 2. This phase transition further supports the convergence guarantee in Theorem 2, demonstrating that even under sharp curvature, the attention mechanism gradually concentrates on the correct feature vector, ultimately enabling accurate prediction.
|
| 445 |
+
|
| 446 |
+
# <span id="page-8-0"></span>6 EXPERIMENTS VERIFICATION
|
| 447 |
+
|
| 448 |
+
We adopt the data and task distributions from Section 3.1. Each data point is sampled from a fixed feature set $v_k \in \mathbb{R}^d, k=1,\ldots,K$ , with each feature $v_k$ chosen uniformly at random, i.e., $p_k=1/K$ . Each task involves learning a cosine function of the form $f(x) = \frac{L}{c} \cdot \cos(c \cdot x)$ , where c>0 is a random constant and L is the Lipschitz constant, satisfying Eq. (2). Each prompt consists of N randomly sampled inputs $\{x_i\}_{i=1}^N$ and corresponding outputs $\{y_i\}_{i=1}^N = \{f(x_i)\}_{i=1}^N$ , along with a query token $x_{\text{query}}$ . We set the parameters as follows: d=15, K=4, N=100, c=0.5, and $\Delta=3$ . We generate M=300 prompts and train the model for T=400 epochs. Appendix B presents additional experiments, including attention map dynamics, robustness check with non-uniform feature frequencies, polynomial-function tasks, and deeper transformers.
|
| 449 |
+
|
| 450 |
+
We analyze a simplified transformer model comprising a single block with one-head self-attention and a feedforward network, incorporating layer normalization and ReLU activation, followed by a linear output layer. Our analysis focuses on two key metrics shown in Figure 1: (1) prediction loss dynamics and (2) attention score evolution, evaluated under flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ) curvature regimes. The prediction loss is computed as the average squared loss over prompts containing query token $v_k$ . For attention scores, we track $v_1$ 's self-attention score $\operatorname{Attn}_1^{(t)}$ and other features' attention scores $\operatorname{Attn}_{k-1}^{(t)}$ ( $k \in \{2, 3, 4\}$ ) on $v_1$ at each epoch.
|
| 451 |
+
|
| 452 |
+
For flat L-regime, as shown in Figure 1(a) and Figure 1(c), we observe two distinct training phases. For example, with L=0.1, the prediction loss rapidly decreases to around 1.0 by epoch t=40, driven by increasing attention on the target feature shown in Figure 1(c). Subsequently, it steadily declines to near zero by t=250. At the same time, $\operatorname{Attn}_1^{(t)}$ approaches 1 under the transformer parameter $\theta$ . The convergence time shortens with increasing L due to stronger gradient updates, consistent with Theorem 1, Proposition 1, Proposition 2, and Proposition 3.
|
| 453 |
+
|
| 454 |
+
{9}------------------------------------------------
|
| 455 |
+
|
| 456 |
+
As depicted in Figure 1(b) and Figure 1(d), the sharp L-regime exhibits different three training phases. Specifically, when L=1, the prediction loss drops rapidly to approximately 0.6 by t=30, then decreases steadily to around 0.1 by t=110. After that, it converges slowly toward 0 by t=200. The dynamics of the attention scores in Figure 1(d) exhibit the same three-phase progression. Additionally, under our experiment setting, the convergence upper bounds $T_f^*$ in Theorem 1 and $T_s^*$ in Theorem 2 satisfy $T_f^* > T_s^*$ , indicating that the sharp regime achieves a faster convergence time. These empirical observations are consistent with our theoretical predictions in Theorem 2 and Proposition 4.
|
| 457 |
+
|
| 458 |
+
# <span id="page-9-5"></span>7 CONCLUSIONS AND LIMITATIONS
|
| 459 |
+
|
| 460 |
+
<span id="page-9-1"></span>
|
| 461 |
+
|
| 462 |
+
<span id="page-9-3"></span>
|
| 463 |
+
|
| 464 |
+
<span id="page-9-4"></span>
|
| 465 |
+
|
| 466 |
+
<span id="page-9-0"></span>
|
| 467 |
+
|
| 468 |
+
<span id="page-9-2"></span>
|
| 469 |
+
|
| 470 |
+
We presented provable results showing how transformers can learn a broad family of nonlinear tasks in context, identifying two distinct training regimes governed by task curvature. These findings illuminate the basic mechanisms-attention concentration and curvature-dependent gradient dynamics—that underpin ICL. By revealing how Lipschitz continuity and feature separation jointly determine convergence and generalization, our theory offers testable predictions for real-world settings (e.g., effects of task smoothness and feature geometry) and provides a principled starting point for extending formal guarantees to more realistic transformer architectures. Although our analysis focuses on a single-layer, single-head model, extending it to multi-head and multi-layer transformers presents substantial challenges due to intertwined cross-head gradients and the recursive evolution of representations across layers. Depth introduces residual connections and nonlinearities that couple representation learning with attention dynamics, making phase-wise analysis significantly more delicate. We view developing such extensions as an important direction for future work, and our curvature-sensitive framework provides a promising starting point.
|
| 471 |
+
|
| 472 |
+
#### REPRODUCIBILITY STATEMENT
|
| 473 |
+
|
| 474 |
+
We are committed to ensuring the reproducibility of our work. All theoretical claims made in this paper are supported by detailed, step-by-step proofs, which can be found in Appendices B through G. The key assumptions underlying our analysis, including the non-degenerate L-Lipschitz function class and the one-layer transformer architecture, are formally defined in the System Model (Section 3), and we have added additional discussion in Section 7. For our empirical validation, the setup, hyperparameters, and task details for the main experiments are described in Section 6 and Appendix B. To facilitate direct replication of all figures and results, we have included the complete source code, which contains the model implementation, data generation, and training procedures, as part of the supplementary materials. Together, these materials satisfy the ICLR guidelines for reproducibility and allow others to reproduce our theoretical analyses and empirical findings.
|
| 475 |
+
|
| 476 |
+
# REFERENCES
|
| 477 |
+
|
| 478 |
+
- Rishabh Agarwal, Avi Singh, Lei Zhang, Bernd Bohnet, Luis Rosias, Stephanie Chan, Biao Zhang, Ankesh Anand, Zaheer Abbas, Azade Nova, et al. Many-shot in-context learning. *Advances in Neural Information Processing Systems*, 37:76930–76966, 2024.
|
| 479 |
+
- Ekin Akyürek, Dale Schuurmans, Jacob Andreas, Tengyu Ma, and Denny Zhou. What learning algorithm is in-context learning? investigations with linear models. In *International Conference on Learning Representations*, 2023.
|
| 480 |
+
- Yu Bai, Fan Chen, Huan Wang, Caiming Xiong, and Song Mei. Transformers as statisticians: Provable in-context learning with in-context algorithm selection. *Advances in neural information processing systems*, 36:57125–57211, 2023.
|
| 481 |
+
- Jiarui Bi, Zengliang Zhu, and Qinglong Meng. Transformer in computer vision. In 2021 IEEE International Conference on Computer Dcience, Electronic Information Engineering and Intelligent Control Technology (CEI), pp. 178–188. IEEE, 2021.
|
| 482 |
+
- Alberto Bietti, Vivien Cabannes, Diane Bouchacourt, Herve Jegou, and Leon Bottou. Birth of a transformer: A memory viewpoint. *Advances in Neural Information Processing Systems*, 36: 1560–1588, 2023.
|
| 483 |
+
|
| 484 |
+
{10}------------------------------------------------
|
| 485 |
+
|
| 486 |
+
<span id="page-10-14"></span><span id="page-10-13"></span><span id="page-10-12"></span><span id="page-10-8"></span>**558 559 560**
|
| 487 |
+
|
| 488 |
+
<span id="page-10-5"></span><span id="page-10-1"></span><span id="page-10-0"></span>**564**
|
| 489 |
+
|
| 490 |
+
<span id="page-10-16"></span><span id="page-10-15"></span><span id="page-10-9"></span><span id="page-10-7"></span><span id="page-10-6"></span><span id="page-10-3"></span><span id="page-10-2"></span>**579**
|
| 491 |
+
|
| 492 |
+
- <span id="page-10-11"></span><span id="page-10-10"></span><span id="page-10-4"></span>Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. *Advances in Neural Information Processing Systems*, 33:1877–1901, 2020.
|
| 493 |
+
- Siyu Chen, Heejune Sheen, Tianhao Wang, and Zhuoran Yang. Training dynamics of multi-head softmax attention for in-context learning: Emergence, convergence, and optimality. *arXiv preprint arXiv:2402.19442*, 2024.
|
| 494 |
+
- Xiang Cheng, Yuxin Chen, and Suvrit Sra. Transformers implement functional gradient descent to learn non-linear functions in context. In *Proceedings of the 41st International Conference on Machine Learning*, pp. 8002–8037, 2024.
|
| 495 |
+
- Liam Collins, Advait Parulekar, Aryan Mokhtari, Sujay Sanghavi, and Sanjay Shakkottai. In-context learning with transformers: Softmax attention adapts to function lipschitzness. *arXiv preprint arXiv:2402.11639*, 2024.
|
| 496 |
+
- Damai Dai, Yutao Sun, Li Dong, Yaru Hao, Shuming Ma, Zhifang Sui, and Furu Wei. Why can gpt learn in-context? language models implicitly perform gradient descent as meta-optimizers. *arXiv preprint arXiv:2212.10559*, 2022.
|
| 497 |
+
- Ezra Edelman, Nikolaos Tsilivis, Benjamin Edelman, Eran Malach, and Surbhi Goel. The evolution of statistical induction heads: In-context learning markov chains. *Advances in Neural Information Processing Systems*, 37:64273–64311, 2024.
|
| 498 |
+
- Fabian Falck, Ziyu Wang, and Chris Holmes. Is in-context learning in large language models bayesian? a martingale perspective. *arXiv preprint arXiv:2406.00793*, 2024.
|
| 499 |
+
- Shivam Garg, Dimitris Tsipras, Percy S Liang, and Gregory Valiant. What can transformers learn in-context? a case study of simple function classes. *Advances in Neural Information Processing Systems*, 35:30583–30598, 2022.
|
| 500 |
+
- Micah Goldblum, Hossein Souri, Renkun Ni, Manli Shu, Viraj Prabhu, Gowthami Somepalli, Prithvijit Chattopadhyay, Mark Ibrahim, Adrien Bardes, Judy Hoffman, et al. Battle of the backbones: A large-scale comparison of pretrained models across computer vision tasks. *Advances in Neural Information Processing Systems*, 36, 2024.
|
| 501 |
+
- Kai Han, Yunhe Wang, Hanting Chen, Xinghao Chen, Jianyuan Guo, Zhenhua Liu, Yehui Tang, An Xiao, Chunjing Xu, Yixing Xu, et al. A survey on vision transformer. *IEEE Transactions on Pattern Analysis and Machine Intelligence*, 45(1):87–110, 2022.
|
| 502 |
+
- Irina Higgins, David Amos, David Pfau, Sebastien Racaniere, Loic Matthey, Danilo Rezende, and Alexander Lerchner. Towards a definition of disentangled representations. *arXiv preprint arXiv:1812.02230*, 2018.
|
| 503 |
+
- Yu Huang, Yuan Cheng, and Yingbin Liang. In-context convergence of transformers. In *International Conference on Machine Learning*. PMLR, 2024.
|
| 504 |
+
- Hong Jun Jeon, Jason D Lee, Qi Lei, and Benjamin Van Roy. An information-theoretic analysis of in-context learning. *arXiv preprint arXiv:2401.15530*, 2024.
|
| 505 |
+
- Katikapalli Subramanyam Kalyan, Ajit Rajasekharan, and Sivanesan Sangeetha. Ammus: A survey of transformer-based pretrained models in natural language processing. *arXiv preprint arXiv:2108.05542*, 2021.
|
| 506 |
+
- Siddique Latif, Aun Zaidi, Heriberto Cuayahuitl, Fahad Shamshad, Moazzam Shoukat, and Junaid Qadir. Transformers in speech processing: A survey. *arXiv preprint arXiv:2303.11607*, 2023.
|
| 507 |
+
- Hongkang Li, Meng Wang, Songtao Lu, Xiaodong Cui, and Pin-Yu Chen. How do nonlinear transformers learn and generalize in in-context learning? In *International Conference on Machine Learning*, 2024a.
|
| 508 |
+
- Tianle Li, Ge Zhang, Quy Duc Do, Xiang Yue, and Wenhu Chen. Long-context llms struggle with long in-context learning. *arXiv preprint arXiv:2404.02060*, 2024b.
|
| 509 |
+
|
| 510 |
+
{11}------------------------------------------------
|
| 511 |
+
|
| 512 |
+
<span id="page-11-14"></span><span id="page-11-13"></span><span id="page-11-5"></span><span id="page-11-2"></span>**604 605 606**
|
| 513 |
+
|
| 514 |
+
<span id="page-11-8"></span><span id="page-11-6"></span><span id="page-11-4"></span>**617**
|
| 515 |
+
|
| 516 |
+
<span id="page-11-11"></span><span id="page-11-10"></span>**619**
|
| 517 |
+
|
| 518 |
+
<span id="page-11-7"></span><span id="page-11-1"></span><span id="page-11-0"></span>**634**
|
| 519 |
+
|
| 520 |
+
<span id="page-11-17"></span><span id="page-11-16"></span><span id="page-11-9"></span><span id="page-11-3"></span>**636**
|
| 521 |
+
|
| 522 |
+
- <span id="page-11-15"></span><span id="page-11-12"></span>Yuchen Li, Yuanzhi Li, and Andrej Risteski. How do transformers learn topic structure: Towards a mechanistic understanding. In *International Conference on Machine Learning*, pp. 19689–19729. PMLR, 2023.
|
| 523 |
+
- Ziqian Lin and Kangwook Lee. Dual operating modes of in-context learning. In *Forty-first International Conference on Machine Learning*, 2024.
|
| 524 |
+
- Yue M Lu, Mary I Letey, Jacob A Zavatone-Veth, Anindita Maiti, and Cengiz Pehlevan. Asymptotic theory of in-context learning by linear attention. *arXiv preprint arXiv:2405.11751*, 2024.
|
| 525 |
+
- Arvind Mahankali, Tatsunori B Hashimoto, and Tengyu Ma. One step of gradient descent is provably the optimal in-context learner with one layer of linear self-attention. *arXiv preprint arXiv:2307.03576*, 2023.
|
| 526 |
+
- Ashok Vardhan Makkuva, Marco Bondaschi, Adway Girish, Alliot Nagle, Hyeji Kim, Michael Gastpar, and Chanakya Ekbote. Local to global: Learning dynamics and effect of initialization for transformers. *Advances in Neural Information Processing Systems*, 37:86243–86308, 2024.
|
| 527 |
+
- Ambuj Mehrish, Navonil Majumder, Rishabh Bharadwaj, Rada Mihalcea, and Soujanya Poria. A review of deep learning techniques for speech processing. *Information Fusion*, 99:101869, 2023.
|
| 528 |
+
- Eshaan Nichani, Alex Damian, and Jason D Lee. How transformers learn causal structure with gradient descent. In *International Conference on Machine Learning*, 2024.
|
| 529 |
+
- Kazusato Oko, Yujin Song, Taiji Suzuki, and Denny Wu. Pretrained transformer efficiently learns low-dimensional target functions in-context. *Advances in Neural Information Processing Systems*, 37:77316–77365, 2024.
|
| 530 |
+
- Core Francisco Park, Andrew Lee, Ekdeep Singh Lubana, Yongyi Yang, Maya Okawa, Kento Nishi, Martin Wattenberg, and Hidenori Tanaka. Iclr: In-context learning of representations. In *International Conference on Learning Representations*, 2025.
|
| 531 |
+
- Nived Rajaraman, Marco Bondaschi, Ashok Vardhan Makkuva, Kannan Ramchandran, and Michael Gastpar. Transformers on markov data: Constant depth suffices. *Advances in Neural Information Processing Systems*, 37:137521–137556, 2024.
|
| 532 |
+
- Ruifeng Ren and Yong Liu. Towards understanding how transformers learn in-context through a representation learning lens. *Advances in Neural Information Processing Systems*, 37:892–933, 2024.
|
| 533 |
+
- Haoyuan Sun, Ali Jadbabaie, and Navid Azizan. In-context learning of polynomial kernel regression in transformers with glu layers. *arXiv preprint arXiv:2501.18187*, 2025.
|
| 534 |
+
- Lewis Tunstall, Leandro Von Werra, and Thomas Wolf. *Natural language processing with transformers*. " O'Reilly Media, Inc.", 2022.
|
| 535 |
+
- Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. *Advances in Neural Information Processing Systems*, 30, 2017.
|
| 536 |
+
- Johannes Von Oswald, Eyvind Niklasson, Ettore Randazzo, João Sacramento, Alexander Mordvintsev, Andrey Zhmoginov, and Max Vladymyrov. Transformers learn in-context by gradient descent. In *International Conference on Machine Learning*, pp. 35151–35174. PMLR, 2023.
|
| 537 |
+
- Xin Wang, Hong Chen, Yuwei Zhou, Jianxin Ma, and Wenwu Zhu. Disentangled representation learning for recommendation. *IEEE Transactions on Pattern Analysis and Machine Intelligence*, 45(1):408–424, 2022.
|
| 538 |
+
- Xin Wang, Hong Chen, Si'ao Tang, Zihao Wu, and Wenwu Zhu. Disentangled representation learning. *IEEE Transactions on Pattern Analysis and Machine Intelligence*, 2024.
|
| 539 |
+
- Xinyi Wang, Wanrong Zhu, and William Yang Wang. Large language models are implicitly topic models: Explaining and finding good demonstrations for in-context learning. *arXiv preprint arXiv:2301.11916*, 1:15, 2023.
|
| 540 |
+
|
| 541 |
+
{12}------------------------------------------------
|
| 542 |
+
|
| 543 |
+
- <span id="page-12-4"></span><span id="page-12-3"></span><span id="page-12-2"></span><span id="page-12-1"></span><span id="page-12-0"></span> Zhiyong Wu, Yaoxiang Wang, Jiacheng Ye, and Lingpeng Kong. Self-adaptive in-context learning: An information compression perspective for in-context example selection and ordering. In *Annual Meeting of the Association for Computational Linguistics*, pp. 1423–1436, 2023. Sang Michael Xie, Aditi Raghunathan, Percy Liang, and Tengyu Ma. An explanation of in-context learning as implicit bayesian inference. *arXiv preprint arXiv:2111.02080*, 2021. Tong Yang, Yu Huang, Yingbin Liang, and Yuejie Chi. In-context learning with representations: Contextual generalization of trained transformers. *Advances in Neural Information Processing Systems*, 2024. Ruiqi Zhang, Spencer Frei, and Peter L Bartlett. Trained transformers learn linear models in-context. *Journal of Machine Learning Research*, 25(49):1–55, 2024.
|
| 544 |
+
- Yufeng Zhang, Fengzhuo Zhang, Zhuoran Yang, and Zhaoran Wang. What and how does in-context learning learn? bayesian model averaging, parameterization, and generalization. *arXiv preprint arXiv:2305.19420*, 2023.
|
| 545 |
+
|
| 546 |
+
{13}------------------------------------------------
|
| 547 |
+
|
| 548 |
+
APPENDIX [A The Use of LLMs for Polishing Writing](#page-14-1) 15 [B Additional Experimental Results](#page-14-0) 15 [C Proof of Lemma 1](#page-16-0) 17 [D Proof of Lemma 2](#page-17-0) 18 [E Proofs for Flat](#page-18-1) L-Regime 19 [E.1 Proof of Proposition 2](#page-18-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 [E.2 Proof of Proposition 3](#page-20-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 [E.3 Proof of Theorem 1](#page-22-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 [F Proofs for Sharp](#page-22-1) L-Regime 24 [F.1 Proof of Proposition 4](#page-23-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 [F.2 Proof of Theorem 2](#page-24-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 [G Proof of Proposition 1](#page-24-1) 25
|
| 549 |
+
|
| 550 |
+
{14}------------------------------------------------
|
| 551 |
+
|
| 552 |
+
In the appendices, we first present additional experimental results in Appendix B. Then we present detailed proofs of Lemma 1 and Lemma 2 in Appendix C and Appendix D. For ease of exposition, before establishing the two main theorems, we separately analyze the convergence dynamics under both the flat L-regime and the sharp L-regime.
|
| 553 |
+
|
| 554 |
+
Specifically, following the proof of Lemma 1, we prove Proposition 2 (see Appendix E.1) and Proposition 3 (see Appendix E.2) as preliminaries for the proof of Theorem 1 in the flat L-regime (see Appendix E.3).
|
| 555 |
+
|
| 556 |
+
We then proceed to prove Proposition 4 (see Appendix F.1) as a preliminary for Theorem 2 (see Appendix F.2) in the sharp L-regime.
|
| 557 |
+
|
| 558 |
+
<span id="page-14-1"></span>Finally, based on Theorem 1 and Theorem 2, we prove Proposition 1 (see Appendix G).
|
| 559 |
+
|
| 560 |
+
#### A THE USE OF LLMS FOR POLISHING WRITING
|
| 561 |
+
|
| 562 |
+
We used a large language model (LLM) tool (e.g., ChatGPT) solely to polish and improve the readability of certain sections of this manuscript—specifically, the introduction, abstract, and several explanatory paragraphs. All research ideas, theoretical derivations, experimental designs, analyses, and conclusions are original to the authors. The LLM was not used to generate technical content, proofs, or results. We reviewed and edited all text produced with LLM assistance to ensure accuracy and consistency with our intended meaning.
|
| 563 |
+
|
| 564 |
+
# <span id="page-14-0"></span>B ADDITIONAL EXPERIMENTAL RESULTS
|
| 565 |
+
|
| 566 |
+
Building on the prediction loss and attention dynamics shown in Figure 1, we provide a more detailed analysis of the $4\times 4$ attention maps in this appendix. Figure 2 and Figure 3 show the attention patterns for the flat (L=0.1) and sharp (L=1) loss landscapes, respectively, under the experimental conditions of Section 6.
|
| 567 |
+
|
| 568 |
+

|
| 569 |
+
|
| 570 |
+
<span id="page-14-2"></span>Figure 2: Dynamics of attention maps under flat L=0.1
|
| 571 |
+
|
| 572 |
+

|
| 573 |
+
|
| 574 |
+
<span id="page-14-3"></span>Figure 3: Dynamics of attention maps under sharp L=1
|
| 575 |
+
|
| 576 |
+
In the attention maps, each grid position (i,j) corresponds to the attention score $Attn_{i,j}$ , where $i,j \in \{1,2,3,4\}$ are the indices of key and query, respectively. An important property is that the sum of attention scores for each column equals one $(\sum_i Attn_{i,j} = 1)$ , given the same query $v_j$ . The
|
| 577 |
+
|
| 578 |
+
{15}------------------------------------------------
|
| 579 |
+
|
| 580 |
+
attention maps show a clear trend: the diagonal entries (i,i) become progressively darker over t, indicating that the corresponding self-attention scores $\mathrm{Attn}_i$ increase for all $i \in \{1,2,3,4\}$ . We observe these scores approaching 1 before t=300 for the flat landscape L=0.1 and before t=200 for the sharp landscape L=1. In contrast, the off-diagonal entries (i,j), where $i \neq j$ , become lighter, with $\mathrm{Attn}_{i,j}$ converging toward zero. This behavior supports the theoretical findings presented in Proposition 2 and Proposition 3 and is directly reflected in the attention score dynamics plotted in Figure 1(c) and Figure 1(d).
|
| 581 |
+
|
| 582 |
+

|
| 583 |
+
|
| 584 |
+

|
| 585 |
+
|
| 586 |
+
- (a) Prediction loss for flat L-set under polynomial functions.
|
| 587 |
+
- <span id="page-15-0"></span>(b) Prediction loss for sharp L-set under polynomial functions.
|
| 588 |
+
|
| 589 |
+
Figure 4: Training dynamics of prediction losses for two sets of L: flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ) under polynomial functions.
|
| 590 |
+
|
| 591 |
+
To further validate the generality of our theoretical results, we conducted an additional experiment on a different class of nonlinear functions: random second-degree polynomials of the form $f(x) = x^{\top}Ax + b^{\top}x$ , where the matrix A and vector b were randomly generated for each task instance. The elements of A and b satisfy $A_{ij}, b_i \sim \mathcal{N}(0, (\frac{L}{d})^2)$ . For this experiment, we relaxed the finite feature set assumption by sampling input features from a continuous Gaussian distribution. In other words, there can be infinitely many feature vectors. For the other parameters, we set d=30, N=150, M=500. The prediction loss, averaged over 30 independent runs, is shown below for both the flat L-regime and the sharp L-regime. The results strongly corroborate our main findings: The flat regime has two training phases, while the sharp regime has three phases. Within both regimes, a larger Lipschitz constant L consistently results in faster convergence of the prediction loss. This provides further evidence that the identified training dynamics and the role of the Lipschitz constant hold for a broader class of nonlinear functions beyond the trigonometric family, and also hold for more general feature set and token sampling process.
|
| 592 |
+
|
| 593 |
+

|
| 594 |
+
|
| 595 |
+

|
| 596 |
+
|
| 597 |
+
- (a) Prediction loss for flat L-set under two-layer transformer.
|
| 598 |
+
- <span id="page-15-1"></span>(b) Prediction loss for sharp L-set under two-layer transformer.
|
| 599 |
+
|
| 600 |
+
Figure 5: Training dynamics of prediction losses for two sets of L: flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ) under two-layer transformer.
|
| 601 |
+
|
| 602 |
+
In addition to the single-layer setting analyzed in the main text, we further evaluate whether the curvature-dependent convergence behavior persists in deeper Transformer architectures such as two-layer and four-layer models. To this end, we present experiments using more realistic architectures that contain two or four stacked self-attention layers followed by two or four FFN blocks, under the same
|
| 603 |
+
|
| 604 |
+
{16}------------------------------------------------
|
| 605 |
+
|
| 606 |
+

|
| 607 |
+
|
| 608 |
+

|
| 609 |
+
|
| 610 |
+
- (a) Prediction loss for flat L-set under four-layer transformer.
|
| 611 |
+
- <span id="page-16-1"></span>(b) Prediction loss for sharp L-set under four-layer transformer.
|
| 612 |
+
|
| 613 |
+
Figure 6: Training dynamics of prediction losses for two sets of L: flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ) under four-layer transformer.
|
| 614 |
+
|
| 615 |
+
data and task setup as in Figure 4. As shown in Figure 5 and Figure 6, the deeper Transformers exhibit the same qualitative learning dynamics predicted by our theory, including a clear phase transition between the flat and sharp L-regimes and consistent phase-wise convergence behavior. These results indicate that the core mechanisms identified in our analysis, which were derived for a single-layer model for analytical tractability, naturally extend to multi-layer Transformer architectures.
|
| 616 |
+
|
| 617 |
+
# <span id="page-16-0"></span>C PROOF OF LEMMA 1
|
| 618 |
+
|
| 619 |
+
Recall the definition of the prediction error $\mathcal{L}(P;Q)$ in Eq. (5):
|
| 620 |
+
|
| 621 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} (\hat{y}_{\text{query}} - f(v_k))^2 \right]$$
|
| 622 |
+
|
| 623 |
+
$$= \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} f(v_n) - f(v_k) \right)^2 \right]$$
|
| 624 |
+
|
| 625 |
+
$$= \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} (f(v_n) - f(v_k)) \right)^2 \right]$$
|
| 626 |
+
|
| 627 |
+
$$= \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( \sum_{n \neq k} \operatorname{Attn}_n^{(t)} (f(v_n) - f(v_k)) \right)^2 \right]$$
|
| 628 |
+
|
| 629 |
+
where we apply $\sum_{n\in[K]}\operatorname{Attn}_n^{(t)}=1$ to rewrite $f(v_k)$ as $\sum_{n\in[K]}\operatorname{Attn}_n^{(t)}f(v_k)$ in the third equality.
|
| 630 |
+
|
| 631 |
+
Next, under the non-degenerate L-Lipschitz condition of the function class (see Eq. (2)), we have $\sum_{n\neq k} |f(v_n) - f(v_k)| = \mathcal{O}(L\Delta)$ . Therefore, the sum can be bounded (order-wise) as
|
| 632 |
+
|
| 633 |
+
$$\left| \sum_{n \neq k} \operatorname{Attn}_{n}^{(t)} (f(v_{n}) - f(v_{k})) \right| = (1 - \operatorname{Attn}_{k}^{(t)}) \cdot \mathcal{O}(L\Delta)$$
|
| 634 |
+
|
| 635 |
+
and thus
|
| 636 |
+
|
| 637 |
+
$$\left(\sum_{n\neq k}\operatorname{Attn}_n^{(t)}(f(v_n)-f(v_k))\right)^2 = (1-\operatorname{Attn}_k^{(t)})^2 \cdot \mathcal{O}(L^2\Delta^2).$$
|
| 638 |
+
|
| 639 |
+
Putting these together, we obtain:
|
| 640 |
+
|
| 641 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E}\left[\mathbb{1}\{x_{\text{query}} = v_k\}(1 - \operatorname{Attn}_k^{(t)})^2 \cdot \mathcal{O}(L^2 \Delta^2)\right].$$
|
| 642 |
+
|
| 643 |
+
{17}------------------------------------------------
|
| 644 |
+
|
| 645 |
+
<span id="page-17-0"></span>This completes the proof of Lemma 1.
|
| 646 |
+
|
| 647 |
+
# D Proof of Lemma 2
|
| 648 |
+
|
| 649 |
+
To derive $q_k$ , we first compute the gradient of prediction loss with respect to $Q^{(t)}$ as follows:
|
| 650 |
+
|
| 651 |
+
$$\nabla_{Q^{(t)}} \mathcal{L} = \mathbb{E} \Big[ (\hat{y}_{\text{query}} - f(v_k))^\top \frac{\partial \hat{y}_{\text{query}}}{\partial Q^{(t)}} \Big] = \mathbb{E} \Big[ (\hat{y}_{\text{query}} - f(v_k))^\top \sum_{i \in [N]} \frac{\partial \text{attn}_i}{\partial Q^{(t)}} y_i \Big].$$
|
| 652 |
+
|
| 653 |
+
We then compute the gradient of $\operatorname{attn}_i^{(t)}$ with respect to $Q^{(t)}\colon$
|
| 654 |
+
|
| 655 |
+
$$\begin{split} \frac{\partial \text{attn}_{i}^{(t)}}{\partial Q^{(t)}} &= \frac{e^{\bar{X}_{i}^{\top}Q^{(t)}x_{\text{query}}} \cdot \bar{X}_{i}^{\top}x_{\text{query}}^{\top}(\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}})^{2}}{(\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}})^{2}} \\ &- \frac{\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}} \cdot \bar{X}_{j}^{\top}x_{\text{query}}^{\top} \cdot e^{\bar{X}_{i}^{\top}Q^{(t)}x_{\text{query}}}}{(\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}})^{2}} \\ &= \text{attn}_{i}^{(t)} \cdot \bar{X}_{i}^{\top}x_{\text{query}} - \text{attn}_{i}^{(t)} \sum_{j \in [N]} \text{attn}_{j}^{(t)} \cdot \bar{X}_{j}^{\top}x_{\text{query}} \\ &= \text{attn}_{i}^{(t)} \sum_{j \in [N]} \text{attn}_{j}^{(t)}(\bar{X}_{i} - \bar{X}_{j})x_{\text{query}}^{\top}. \end{split}$$
|
| 656 |
+
|
| 657 |
+
Substituting into the above expression gives:
|
| 658 |
+
|
| 659 |
+
$$\nabla_{Q^{(t)}} \mathcal{L} = \mathbb{E}\Big[ (\hat{y}_{\text{query}}^{(t)} - f(v_k)) \sum_{i,j \in [N]} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} (\bar{X}_i - \bar{X}_j) x_{\text{query}}^\top y_i \Big].$$
|
| 660 |
+
|
| 661 |
+
For any feature vectors $v_k$ and $v_{k'}$ , we calculate
|
| 662 |
+
|
| 663 |
+
$$\begin{split} v_{k'}^\top \nabla_{Q^{(t)}} \mathcal{L} \cdot v_k = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \sum_{i,j \in [N]} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} y_i v_{k'}^\top (\bar{X}_i - \bar{X}_j) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \sum_{m,n \in [K]} \sum_{i \in \mathcal{V}_m} \sum_{j \in \mathcal{V}_n} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} y_i v_{k'}^\top (v_m - v_n) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \sum_{n \in [K]} \sum_{i \in \mathcal{V}_{k'}} \sum_{j \in \mathcal{V}_n} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} y_i v_{k'}^\top (v_{k'} - v_n) \Big] \\ + & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} f(v_{k'}) \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} \big\} \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} f(v_{k'}) \sum_{n \in [K]} \operatorname{Attn}_m^{(t)} f(v_m) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} f(v_m) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} \big( f(v_{k'}) - f(v_m) \big) \Big]. \end{split}$$
|
| 664 |
+
|
| 665 |
+
Since
|
| 666 |
+
$$\hat{y}_{\text{query}} = \sum_{i \in [N]} \operatorname{attn}_i y_i = \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} f(v_m)$$
|
| 667 |
+
, we obtain
|
| 668 |
+
$$v_{k'}^{\top} \nabla_{Q^{(t)}} \mathcal{L} v_k = -\mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \operatorname{Attn}_{k'}^{(t)} \sum_{n \in [K]} \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} \operatorname{Attn}_n^{(t)} (f(v_k) - f(v_n)) (f(v_{k'}) - f(v_m)) \Big] \\ = -\mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \operatorname{Attn}_{k'}^{(t)} (f(v_k) - \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} f(v_n)) (f(v_{k'}) - \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} f(v_m)) \Big].$$
|
| 669 |
+
|
| 670 |
+
We then derive Eq. (10) by letting $v_k = v_{k'}$ using this expression:
|
| 671 |
+
|
| 672 |
+
$$g_k^{(t)} = -v_k^{\top} \nabla_{Q^{(t)}} \mathcal{L} \cdot v_k$$
|
| 673 |
+
|
| 674 |
+
{18}------------------------------------------------
|
| 675 |
+
|
| 676 |
+
$$\begin{split} &= \mathbb{E}\left[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_k^{(t)} \left(f(v_k) - \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} f(v_n)\right)^2\right] \\ &= \mathbb{E}\left[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_k^{(t)} \left(\sum_{n \in [K]} \operatorname{Attn}_n^{(t)} (f(v_k) - f(v_n))\right)^2\right] \\ &= \mathbb{E}\left[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right], \end{split}$$
|
| 677 |
+
|
| 678 |
+
where the last equality follows from the non-degenerate L-Lipschitz condition in Eq. (2).
|
| 679 |
+
|
| 680 |
+
For any $k \neq n$ , we calculate
|
| 681 |
+
|
| 682 |
+
$$\begin{split} |g_{k,k'}^{(t)}| &= \mathbb{E}\Big[\mathbbm{1}\{x_{\text{query}} = v_k\} \text{Attn}_{k'}^{(t)} | f(v_k) - \sum_{j \in [K]} \text{Attn}_{j}^{(t)} f(v_j) | \cdot | f(v_{k'}) - \sum_{m \in [K]} \text{Attn}_{m}^{(t)} f(v_m) | \Big] \\ &= p_k \cdot \mathbb{E}\Big[\text{Attn}_{k'}^{(t)} \Big| \sum_{j \in [K]} (\text{Attn}_{j}^{(t)} f(v_k) - \text{Attn}_{j}^{(t)} f(v_j)) \Big| \cdot \Big| \sum_{m \in [K]} (\text{Attn}_{m}^{(t)} f(v_{k'}) - \text{Attn}_{m}^{(t)} f(v_m)) \Big| \Big] \\ &= p_k \cdot \mathbb{E}\Big[\text{Attn}_{k'}^{(t)} \cdot \sum_{j \in [K]} \text{Attn}_{j}^{(t)} | f(v_k) - f(v_j) | \cdot \sum_{m \in [K]} \text{Attn}_{m}^{(t)} | f(v_{k'}) - f(v_m) | \Big] \\ &= p_k \cdot \mathbb{E}\left[\text{Attn}_{k'}^{(t)} \cdot (1 - \text{Attn}_{k}^{(t)}) \cdot (1 - \text{Attn}_{k'}^{(t)}) \cdot \Theta(L^2\Delta^2) \right]. \end{split}$$
|
| 683 |
+
|
| 684 |
+
<span id="page-18-1"></span>This completes the proof of Lemma 2.
|
| 685 |
+
|
| 686 |
+
## E PROOFS FOR FLAT L-REGIME
|
| 687 |
+
|
| 688 |
+
#### <span id="page-18-0"></span>E.1 Proof of Proposition 2
|
| 689 |
+
|
| 690 |
+
<span id="page-18-2"></span>**Lemma 3.** For any $t \in \{1, ..., T_f^1\}$ , if $x_{\text{query}} = v_k$ , we have:
|
| 691 |
+
|
| 692 |
+
- Attn<sub>k</sub><sup>(t)</sup> = $\Omega\left(\frac{1}{K}\right)$ ,
|
| 693 |
+
- $1 \operatorname{Attn}_{k}^{(t)} = \Theta(1)$ ,
|
| 694 |
+
- $\operatorname{Attn}_{n}^{(t)} = \Theta\left(\frac{1 \operatorname{Attn}_{k}^{(t)}}{K}\right) = \Theta\left(\frac{1}{K}\right)$ for all $n \neq k$ .
|
| 695 |
+
|
| 696 |
+
*Proof.* Fix any $t \in \{1, \dots, T_f^1\}$ . By definition,
|
| 697 |
+
|
| 698 |
+
$$\begin{aligned} \text{Attn}_{k}^{(t)} &= \frac{|\mathcal{V}_{k}| e^{v_{k}^{\top} Q^{(t)} v_{k}}}{\sum_{j \in [N]} e^{E_{j}^{x \top} Q^{(t)} v_{k}}} = \frac{|\mathcal{V}_{k}| e^{q_{k}^{(t)}}}{\sum_{m \neq k} |\mathcal{V}_{m}| e^{q_{k,m}^{(t)}} + |\mathcal{V}_{k}| e^{q_{k}^{(t)}}} \\ &= \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_{m}|}{|\mathcal{V}_{k}|} \exp(q_{k,m}^{(t)} - q_{k}^{(t)}) + 1}. \end{aligned}$$
|
| 699 |
+
|
| 700 |
+
By the symmetry property in the initial phase, $q_{k,m}^{(t)} = \Theta\left(\frac{q_k^{(t)}}{K}\right)$ . Thus,
|
| 701 |
+
|
| 702 |
+
$$e^{-(\log K + \Theta(\frac{\log K}{K}))} \leq \exp(q_{k,m}^{(t)} - q_k^{(t)}) \leq e^{\Theta(\frac{\log K}{K})}.$$
|
| 703 |
+
|
| 704 |
+
Define $u_k = K(p_k - \delta)$ and $U_k = K(p_k + \delta)$ . Then, from the concentration property (see Eq. (7)), $|\mathcal{V}_k| \in [\frac{u_k}{K}N, \frac{U_k}{K}N]$ for constants $u_k, U_k = \Theta(1)$ . Therefore,
|
| 705 |
+
|
| 706 |
+
$$\operatorname{Attn}_k^{(t)} \geq \frac{1}{e^{\Theta(\frac{\log K}{K})}(\frac{N}{|\mathcal{V}_k|}-1)+1} \geq \frac{1}{e^{\Theta(\frac{\log K}{K})}(\frac{K}{u_k}-1)+1} = \Omega\left(\frac{1}{K}\right).$$
|
| 707 |
+
|
| 708 |
+
For the upper bound,
|
| 709 |
+
|
| 710 |
+
$$Attn_k^{(t)} \le \frac{1}{e^{-(\log K + \Theta(\frac{\log K}{K}))}(\frac{N}{|\mathcal{V}_k|} - 1) + 1} \le \frac{1}{e^{-1}(\frac{1}{U_k} - \frac{1}{K}) + 1},$$
|
| 711 |
+
|
| 712 |
+
{19}------------------------------------------------
|
| 713 |
+
|
| 714 |
+
which follows because $U_k = \Theta(1)$ , and hence
|
| 715 |
+
|
| 716 |
+
$$1 - \operatorname{Attn}_{k}^{(t)} \ge \frac{\frac{1}{U_{k}} - \frac{1}{K}}{(\frac{1}{U_{k}} - \frac{1}{K}) + e} = \Theta(1).$$
|
| 717 |
+
|
| 718 |
+
The reverse bound is similar, showing $1 - \text{Attn}_k^{(t)} = \Theta(1)$ .
|
| 719 |
+
|
| 720 |
+
For $n \neq k$ , by similar calculation,
|
| 721 |
+
|
| 722 |
+
$$Attn_n^{(t)} = \frac{|\mathcal{V}_n| \exp(q_{k,n}^{(t)})}{\sum_{m \neq k} |\mathcal{V}_m| \exp(q_{k,m}^{(t)}) + |\mathcal{V}_k| \exp(q_k^{(t)})},$$
|
| 723 |
+
|
| 724 |
+
and since $|\mathcal{V}_m|/|\mathcal{V}_n| = \Theta(1)$ and $\exp(q_{k,m}^{(t)} - q_{k,n}^{(t)}) = e^{O(\frac{\log K}{K})}$ ,
|
| 725 |
+
|
| 726 |
+
$$\frac{\operatorname{Attn}_{n}^{(t)}}{1 - \operatorname{Attn}_{k}^{(t)}} = \frac{|\mathcal{V}_{n}| \exp(q_{k,n}^{(t)})}{\sum_{m \neq k} |\mathcal{V}_{m}| \exp(q_{k,m}^{(t)})} = \Theta\left(\frac{1}{K}\right).$$
|
| 727 |
+
|
| 728 |
+
Thus,
|
| 729 |
+
$$\operatorname{Attn}_n^{(t)} = (1 - \operatorname{Attn}_k^{(t)})\Theta\left(\frac{1}{K}\right) = \Theta\left(\frac{1}{K}\right)$$
|
| 730 |
+
, since $1 - \operatorname{Attn}_k^{(t)} = \Theta(1)$ .
|
| 731 |
+
|
| 732 |
+
<span id="page-19-0"></span>**Lemma 4.** For any $t \in \{1, ..., T_f^1\}$ , given $x_{query} = v_k$ , we have:
|
| 733 |
+
|
| 734 |
+
•
|
| 735 |
+
$$g_k^{(t)} = \Theta\left(\frac{L^2\Delta^2}{K}\right)$$
|
| 736 |
+
,
|
| 737 |
+
|
| 738 |
+
•
|
| 739 |
+
$$|g_{k,n}^{(t)}| = O\left(\frac{L^2\Delta^2}{K^2}\right)$$
|
| 740 |
+
for any $n \neq k$ .
|
| 741 |
+
|
| 742 |
+
Proof. By the gradient expression from Lemma 2, we have
|
| 743 |
+
|
| 744 |
+
$$g_k^{(t)} = \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right]$$
|
| 745 |
+
$$= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \mid x_{\text{query}} = v_k\right] \cdot \Theta(L^2 \Delta^2).$$
|
| 746 |
+
|
| 747 |
+
By Lemma 3, in Phase I, we have
|
| 748 |
+
|
| 749 |
+
$$p_k = \Theta(1/K)$$
|
| 750 |
+
, $\operatorname{Attn}_k^{(t)} = \Theta(1)$ , and $1 - \operatorname{Attn}_k^{(t)} = \Theta(1)$ .
|
| 751 |
+
|
| 752 |
+
Therefore,
|
| 753 |
+
|
| 754 |
+
$$g_k^{(t)} = \Theta\left(\frac{1}{K} \cdot 1 \cdot (1)^2 \cdot L^2 \Delta^2\right) = \Theta\left(\frac{L^2 \Delta^2}{K}\right).$$
|
| 755 |
+
|
| 756 |
+
For the cross-gradient term, for $n \neq k$ ,
|
| 757 |
+
|
| 758 |
+
$$\begin{split} |g_{k,n}^{(t)}| &= \mathbb{E}\Big[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_n^{(t)} |f(v_k) - \sum_j \operatorname{Attn}_j^{(t)} f(v_j)| \, |f(v_n) - \sum_m \operatorname{Attn}_m^{(t)} f(v_m)| \Big] \\ &= p_k \cdot \mathbb{E}\Big[\operatorname{Attn}_n^{(t)} \Big| \sum_j \operatorname{Attn}_j^{(t)} (f(v_k) - f(v_j)) \Big| \, \Big| \sum_m \operatorname{Attn}_m^{(t)} (f(v_n) - f(v_m)) \Big| \, | \, x_{\mathrm{query}} = v_k \Big] \\ &\leq p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)} \cdot \sum_j \operatorname{Attn}_j^{(t)} |f(v_k) - f(v_j)| \cdot \sum_m \operatorname{Attn}_m^{(t)} |f(v_n) - f(v_m)| \right] \\ &= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)} (1 - \operatorname{Attn}_k^{(t)}) (1 - \operatorname{Attn}_n^{(t)}) \mathcal{O}(L^2 \Delta^2) \right]. \end{split}$$
|
| 759 |
+
|
| 760 |
+
By Lemma 3, $\operatorname{Attn}_n^{(t)} = \Theta(1/K)$ and $1 - \operatorname{Attn}_k^{(t)}, 1 - \operatorname{Attn}_n^{(t)} = \Theta(1)$ , so
|
| 761 |
+
|
| 762 |
+
$$|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{1}{K} \cdot \frac{1}{K} \cdot 1 \cdot 1 \cdot L^2 \Delta^2\right) = \mathcal{O}\left(\frac{L^2 \Delta^2}{K^2}\right)$$
|
| 763 |
+
|
| 764 |
+
This completes the proof of Lemma 4.
|
| 765 |
+
|
| 766 |
+
<span id="page-19-1"></span>**Lemma 5.** Given $\delta = o(1)$ , at the end of Phase I (i.e., at $t = T_f^1 + 1$ ), we have:
|
| 767 |
+
|
| 768 |
+
•
|
| 769 |
+
$$q_h^{(T_f^1+1)} = \Theta(\log K)$$
|
| 770 |
+
,
|
| 771 |
+
|
| 772 |
+
•
|
| 773 |
+
$$\operatorname{Attn}_{k}^{(T_f^1+1)} = \Omega\left(\frac{1}{1+\delta}\right) if x_{\text{query}} = v_k.$$
|
| 774 |
+
|
| 775 |
+
{20}------------------------------------------------
|
| 776 |
+
|
| 777 |
+
*Proof.* By Lemma 4, we have $g_k^{(t)} = \Theta\left(\frac{L^2\Delta^2}{K}\right)$ for all t in Phase I. Thus,
|
| 778 |
+
|
| 779 |
+
$$\begin{aligned} q_k^{(T_f^1+1)} &= q_k^{(0)} + \eta \sum_{t=1}^{T_f^1} g_k^{(t)} \\ &= q_k^{(0)} + \eta \cdot T_f^1 \cdot \Theta\left(\frac{L^2 \Delta^2}{K}\right) \\ &= \Theta(\log K), \end{aligned}$$
|
| 780 |
+
|
| 781 |
+
where we apply the definition of $T_f^1$ from the main text.
|
| 782 |
+
|
| 783 |
+
For the off-diagonal terms, from Lemma 4, $|g_{k,m}^{(t)}| = O\left(\frac{L^2\Delta^2}{K^2}\right)$ for any $m \neq k$ . Hence,
|
| 784 |
+
|
| 785 |
+
$$\begin{split} q_{k,m}^{(T_f^1+1)} &\leq |q_{k,m}^{(0)}| + \eta \cdot T_f^1 \cdot \mathcal{O}\left(\frac{L^2 \Delta^2}{K^2}\right) \\ &= \mathcal{O}\left(\frac{\log K}{K}\right). \end{split}$$
|
| 786 |
+
|
| 787 |
+
Therefore, at the end of Phase I,
|
| 788 |
+
|
| 789 |
+
$$q_k^{(T_f^1+1)} - q_{k,m}^{(T_f^1+1)} = \Theta(\log K) - \mathcal{O}\left(\frac{\log K}{K}\right) = \Theta(\log K).$$
|
| 790 |
+
|
| 791 |
+
Now, the attention weight for k at time t is
|
| 792 |
+
|
| 793 |
+
$$Attn_k^{(t)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.$$
|
| 794 |
+
|
| 795 |
+
Using the above, for $t = T_f^1 + 1$ ,
|
| 796 |
+
|
| 797 |
+
$$\exp(q_{k,m}^{(t)} - q_k^{(t)}) \leq \exp\left(\mathcal{O}\left(\frac{\log K}{K}\right) - \log K\right) = \mathcal{O}\left(\frac{1}{K}\right).$$
|
| 798 |
+
|
| 799 |
+
By the concentration condition in Eq. (7), $|\hat{\mathcal{V}}_k| \geq \frac{u_k}{K} N$ for some $u_k = \Theta(1)$ , and $N/|\mathcal{V}_k| = \Theta(1/\delta)$ (since $\delta = o(1)$ is the imbalance parameter). Thus,
|
| 800 |
+
|
| 801 |
+
$$\operatorname{Attn}_{k}^{(t)} \ge \frac{1}{\mathcal{O}\left(\frac{1}{K}\right)\left(\frac{N}{|\mathcal{V}_{k}|} - 1\right) + 1} \ge \frac{1}{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \Omega\left(\frac{1}{1 + \delta}\right),$$
|
| 802 |
+
|
| 803 |
+
where the last equality follows because $1/u_k - 1/K = \Theta(\delta)$ from Eq. (7).
|
| 804 |
+
|
| 805 |
+
This completes the proof of Lemma 5 and Proposition 2.
|
| 806 |
+
|
| 807 |
+
## <span id="page-20-0"></span>E.2 PROOF OF PROPOSITION 3
|
| 808 |
+
|
| 809 |
+
**Lemma 6.** For any $t \in \{T_f^1 + 1, \dots, T_f^*\}$ , given $\delta = o(1)$ , if $x_{\text{query}} = v_k$ , we have:
|
| 810 |
+
|
| 811 |
+
- Attn $_k^{(t)} = \Omega\left(\frac{1}{1+\delta}\right)$ ,
|
| 812 |
+
- $1 \operatorname{Attn}_{k}^{(t)} = \mathcal{O}(\delta)$ ,
|
| 813 |
+
- $\operatorname{Attn}_n^{(t)} = \Theta\left(\frac{1 \operatorname{Attn}_k^{(t)}}{K}\right) = \Theta\left(\frac{\delta}{K}\right)$ for any $n \neq k$ .
|
| 814 |
+
|
| 815 |
+
*Proof.* By Proposition 2 (see also Lemma 5), for any $t \ge T_f^1 + 1$ , we have $\operatorname{Attn}_k^{(t)} = \Omega\left(\frac{1}{1+\delta}\right)$ .
|
| 816 |
+
|
| 817 |
+
We now show that $1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\delta)$ . Using the same attention formula as before,
|
| 818 |
+
|
| 819 |
+
$$Attn_k^{(t)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.$$
|
| 820 |
+
|
| 821 |
+
{21}------------------------------------------------
|
| 822 |
+
|
| 823 |
+
From previous bounds, $\exp(q_{k,m}^{(t)}-q_k^{(t)})=O\left(\frac{1}{K}\right)$ , and $|\mathcal{V}_k|\geq u_kN/K$ with $1/u_k-1/K=\Theta(\delta)$ . Therefore,
|
| 824 |
+
|
| 825 |
+
$$\operatorname{Attn}_{k}^{(t)} \geq \frac{1}{\mathcal{O}\left(\frac{1}{K}\right)\left(\frac{N}{|\mathcal{V}_{k}|} - 1\right) + 1} \geq \frac{1}{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \Omega\left(\frac{1}{1 + \delta}\right).$$
|
| 826 |
+
|
| 827 |
+
For the upper bound, we compute:
|
| 828 |
+
|
| 829 |
+
$$1 - \operatorname{Attn}_{k}^{(t)} \le 1 - \frac{1}{\mathcal{O}\left(\frac{1}{K}\right)\left(\frac{N}{|\mathcal{V}_{k}|} - 1\right) + 1} = \frac{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right)}{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \mathcal{O}(\delta),$$
|
| 830 |
+
|
| 831 |
+
where the last equality uses $\frac{1}{u_k} - \frac{1}{K} = \Theta(\delta)$ from Eq. (7). Thus, $1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\delta)$ .
|
| 832 |
+
|
| 833 |
+
Finally, for any $n \neq k$ , we can use the same method as in Lemma 3 to obtain:
|
| 834 |
+
|
| 835 |
+
$$\operatorname{Attn}_{n}^{(t)} = \mathcal{O}\left(\frac{1 - \operatorname{Attn}_{k}^{(t)}}{K}\right) = \mathcal{O}\left(\frac{\delta}{K}\right).$$
|
| 836 |
+
|
| 837 |
+
This completes the proof.
|
| 838 |
+
|
| 839 |
+
<span id="page-21-0"></span>**Lemma 7.** For any $t \in \{T_f^1 + 1, \dots, T_f^*\}$ and any fixed $k \in [K]$ , we have:
|
| 840 |
+
|
| 841 |
+
•
|
| 842 |
+
$$g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2}{K}\right)$$
|
| 843 |
+
,
|
| 844 |
+
|
| 845 |
+
•
|
| 846 |
+
$$|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2}{K^2}\right)$$
|
| 847 |
+
for all $n \neq k$ .
|
| 848 |
+
|
| 849 |
+
*Proof.* Recall from the gradient expression and Lemma 4:
|
| 850 |
+
|
| 851 |
+
$$\begin{split} g_k^{(t)} &= \mathbb{E}\left[\mathbb{1}\{x_{\text{query}} = v_k\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right] \\ &= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \mid x_{\text{query}} = v_k\right] \cdot \Theta(L^2 \Delta^2). \end{split}$$
|
| 852 |
+
|
| 853 |
+
By Lemma 5 and subsequent results for Phase II, we have $p_k = \Theta(1/K)$ , $\operatorname{Attn}_k^{(t)} = \Theta(1)$ , and $1 - \operatorname{Attn}_k^{(t)} = \Theta(\delta)$ . Therefore,
|
| 854 |
+
|
| 855 |
+
$$g_k^{(t)} = \Theta\left(\frac{1}{K} \cdot 1 \cdot \delta^2 \cdot L^2 \Delta^2\right) = \Theta\left(\frac{\delta^2 L^2 \Delta^2}{K}\right).$$
|
| 856 |
+
|
| 857 |
+
For the cross-gradient terms with $n \neq k$ , using the same approach as in Lemma 4, we obtain
|
| 858 |
+
|
| 859 |
+
$$|g_{k,n}^{(t)}| \le p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)}(1 - \operatorname{Attn}_k^{(t)})(1 - \operatorname{Attn}_n^{(t)}) \cdot \mathcal{O}(L^2\Delta^2)\right].$$
|
| 860 |
+
|
| 861 |
+
In Phase II, by the previous lemma, we have $\operatorname{Attn}_n^{(t)} = \Theta(\delta/K)$ , $1 - \operatorname{Attn}_n^{(t)} = \Theta(1)$ , and $1 - \operatorname{Attn}_k^{(t)} = \Theta(\delta)$ . Thus,
|
| 862 |
+
|
| 863 |
+
$$|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{1}{K} \cdot \frac{\delta}{K} \cdot \delta \cdot 1 \cdot L^2 \Delta^2\right) = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2}{K^2}\right).$$
|
| 864 |
+
|
| 865 |
+
This completes the proof of Lemma 7.
|
| 866 |
+
|
| 867 |
+
<span id="page-21-1"></span>**Lemma 8.** At the end of Phase II under the flat L-regime (i.e., $t = T_f^* + 1$ ), if $x_{query} = v_k$ , we have:
|
| 868 |
+
|
| 869 |
+
•
|
| 870 |
+
$$q_k^{(T_f^*+1)} = \Theta\left(\frac{\log K}{\epsilon}\right)$$
|
| 871 |
+
,
|
| 872 |
+
|
| 873 |
+
• Attn<sub>k</sub><sup>$$(T_f^*+1)$$</sup> = $\Omega\left(\frac{1}{1+\epsilon\delta}\right)$ ,
|
| 874 |
+
|
| 875 |
+
•
|
| 876 |
+
$$1 - \operatorname{Attn}_{k}^{(T_f^* + 1)} = \mathcal{O}(\epsilon \delta).$$
|
| 877 |
+
|
| 878 |
+
*Proof.* By Lemma 7, we have $g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2}{K}\right)$ in Phase II. Thus,
|
| 879 |
+
|
| 880 |
+
$$q_k^{(T_f^*+1)} = q_k^{(T_f^1)} + \eta \cdot \Theta\left(\frac{L^2 \Delta^2 \delta^2}{K}\right) \cdot (T_f^* - T_f^1)$$
|
| 881 |
+
|
| 882 |
+
{22}------------------------------------------------
|
| 883 |
+
|
| 884 |
+
1188
|
| 885 |
+
$$= \Theta(\log(K\epsilon^{-1}))$$
|
| 886 |
+
1190
|
| 887 |
+
$$= \Theta\left(\frac{\log K}{\epsilon}\right),$$
|
| 888 |
+
|
| 889 |
+
where the last step applies the scaling of $T_f^*$ and the learning rate in the flat L-regime.
|
| 890 |
+
|
| 891 |
+
For the cross terms, by Lemma 7 again.
|
| 892 |
+
|
| 893 |
+
$$\begin{split} q_{k,m}^{(T_f^*+1)} &\leq |q_{k,m}^{(T_f^1)}| + \eta \cdot \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2}{K^2}\right) \cdot (T_f^* - T_f^1) \\ &= \Theta\left(\frac{\log(K\epsilon^{-1})}{K}\right). \end{split}$$
|
| 894 |
+
|
| 895 |
+
Therefore, at $t = T_f^* + 1$ , we have
|
| 896 |
+
|
| 897 |
+
$$q_{k,m}^{(T_f^*+1)} - q_k^{(T_f^*+1)} = \mathcal{O}\left(\frac{\log(K\epsilon^{-1})}{K}\right) - \Theta(\log(K\epsilon^{-1})) = -\Theta(\log(K\epsilon^{-1})),$$
|
| 898 |
+
|
| 899 |
+
and so
|
| 900 |
+
|
| 901 |
+
$$\exp(q_{k,m}^{(t)} - q_k^{(t)}) \leq \exp\left(-\Theta(\log K)\right) = \mathcal{O}\left(\frac{1}{K}\right).$$
|
| 902 |
+
|
| 903 |
+
The attention weight for k is then
|
| 904 |
+
|
| 905 |
+
$$\operatorname{Attn}_k^{(t)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.$$
|
| 906 |
+
Using the bounds above, and $|\mathcal{V}_k| \geq u_k N/K$ , with $\frac{1}{u_k} - \frac{1}{K} = \Theta(\delta)$ (see Eq. (7)), we obtain:
|
| 907 |
+
|
| 908 |
+
$$\operatorname{Attn}_{k}^{(T_{f}^{*}+1)} \geq \frac{1}{\mathcal{O}(\epsilon) \cdot \mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \Omega\left(\frac{1}{1 + \epsilon\delta}\right).$$
|
| 909 |
+
|
| 910 |
+
Similarly,
|
| 911 |
+
|
| 912 |
+
$$1 - \operatorname{Attn}_{k}^{(T_{f}^{*}+1)} \leq \frac{\mathcal{O}(\epsilon) \cdot \mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right)}{\mathcal{O}(\epsilon) \cdot \mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \mathcal{O}(\epsilon\delta).$$
|
| 913 |
+
|
| 914 |
+
This completes the proof of Lemma 8 and Proposition 3.
|
| 915 |
+
|
| 916 |
+
# <span id="page-22-0"></span>E.3 PROOF OF THEOREM 1
|
| 917 |
+
|
| 918 |
+
Recall from Lemma 2 and its proof that the prediction error $\mathcal{L}(P;Q)$ defined in Eq. (5) can be expressed as
|
| 919 |
+
|
| 920 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} (1 - \text{Attn}_k^{(t)})^2 \mathcal{O}(L^2 \Delta^2)\right],$$
|
| 921 |
+
|
| 922 |
+
where we use $\sum_{n \neq k} \operatorname{Attn}_n^{(t)} = 1 - \operatorname{Attn}_k^{(t)}$ and, by the function class assumption, $|f(v_n) - f(v_k)| = 1$ $\Theta(L\Delta)$ .
|
| 923 |
+
|
| 924 |
+
At the end of Phase II (i.e., at $t=T_f^*+1$ ), suppose $x_{\rm query}=v_k$ . By Lemma 8, we have $1 - \operatorname{Attn}_{L}^{(T_f^* + 1)} = O(\epsilon \delta)$ . Therefore,
|
| 925 |
+
|
| 926 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} (1 - \text{Attn}_k^{(T_f^* + 1)})^2 \mathcal{O}(L^2 \Delta^2) \right]$$
|
| 927 |
+
$$= \mathbb{E} \left[ (1 - \text{Attn}_k^{(T_f^* + 1)})^2 \mathcal{O}(L^2 \Delta^2) \right]$$
|
| 928 |
+
$$= \mathcal{O}(\epsilon^2),$$
|
| 929 |
+
|
| 930 |
+
where the last equality uses $(1-\operatorname{Attn}_k^{(T_f^*+1)})^2=\mathcal{O}(\epsilon^2\delta^2)$ and $L^2\Delta^2=\mathcal{O}(1/(\Delta^2\delta^2))\cdot\Delta^2=0$ $\mathcal{O}(1/\delta^2)$ when $L \leq \Theta(1/(\Delta\delta))$ , so the $\delta^2$ cancels, leaving $\mathcal{O}(\epsilon^2)$ .
|
| 931 |
+
|
| 932 |
+
<span id="page-22-1"></span>This establishes the desired rate and completes the proof of Theorem 1.
|
| 933 |
+
|
| 934 |
+
{23}------------------------------------------------
|
| 935 |
+
|
| 936 |
+
# F PROOFS FOR SHARP L-REGIME
|
| 937 |
+
|
| 938 |
+
#### <span id="page-23-0"></span>F.1 Proof of Proposition 4
|
| 939 |
+
|
| 940 |
+
<span id="page-23-1"></span>**Lemma 9.** For any $t \in \{T_f^* + 1, \dots, T_s^*\}$ and any fixed $k \in [K]$ , we have:
|
| 941 |
+
|
| 942 |
+
•
|
| 943 |
+
$$g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K}\right)$$
|
| 944 |
+
,
|
| 945 |
+
|
| 946 |
+
•
|
| 947 |
+
$$|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right)$$
|
| 948 |
+
for all $n \neq k$ .
|
| 949 |
+
|
| 950 |
+
*Proof.* Recall from the gradient expression:
|
| 951 |
+
|
| 952 |
+
$$g_k^{(t)} = \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right]$$
|
| 953 |
+
$$= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \mid x_{\text{query}} = v_k\right] \cdot \Theta(L^2 \Delta^2),$$
|
| 954 |
+
|
| 955 |
+
where $p_k = \Theta(1/K)$ .
|
| 956 |
+
|
| 957 |
+
By Lemma 8, in this phase $\mathrm{Attn}_k^{(t)} = \Theta(1)$ and $1 - \mathrm{Attn}_k^{(t)} = \mathcal{O}(\epsilon \delta)$ . Therefore,
|
| 958 |
+
|
| 959 |
+
$$g_k^{(t)} = \Theta\left(\frac{1}{K} \cdot 1 \cdot (\epsilon \delta)^2 \cdot L^2 \Delta^2\right) = \Theta\left(\frac{\delta^2 L^2 \Delta^2 \epsilon^2}{K}\right).$$
|
| 960 |
+
|
| 961 |
+
For the cross-gradient terms $(n \neq k)$ , by the same argument as in Lemma 7, we have:
|
| 962 |
+
|
| 963 |
+
$$|g_{k,n}^{(t)}| \le p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)}(1 - \operatorname{Attn}_k^{(t)})(1 - \operatorname{Attn}_n^{(t)}) \cdot \Theta(L^2\Delta^2)\right].$$
|
| 964 |
+
|
| 965 |
+
In this phase, $\operatorname{Attn}_n^{(t)} = \Theta(\delta/K)$ , $1 - \operatorname{Attn}_n^{(t)} = \Theta(1)$ , and $1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\epsilon\delta)$ . Therefore,
|
| 966 |
+
|
| 967 |
+
$$|g_{k,n}^{(t)}| \leq \Theta\left(\frac{1}{K} \cdot \frac{\delta}{K} \cdot \epsilon \delta \cdot 1 \cdot L^2 \Delta^2\right) = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right).$$
|
| 968 |
+
|
| 969 |
+
This completes the proof of Lemma 9.
|
| 970 |
+
|
| 971 |
+
<span id="page-23-2"></span>**Lemma 10.** At the end of Phase II under the sharp L-regime (i.e., at $t = T_s^*$ ), if $x_{\text{query}} = v_k$ , we have:
|
| 972 |
+
|
| 973 |
+
•
|
| 974 |
+
$$q_k^{(T_s^*)} = \Theta\left(\frac{\log(KL\Delta)}{\epsilon}\right)$$
|
| 975 |
+
,
|
| 976 |
+
|
| 977 |
+
•
|
| 978 |
+
$$\operatorname{Attn}_k^{(T_s^*)} = \Omega\left(\frac{1}{1+\epsilon\delta}\right)$$
|
| 979 |
+
,
|
| 980 |
+
|
| 981 |
+
•
|
| 982 |
+
$$1 - \operatorname{Attn}_{k}^{(T_{s}^{*})} = \mathcal{O}(\epsilon \delta).$$
|
| 983 |
+
|
| 984 |
+
*Proof.* By Lemma 9, for $t \in \{T_f^*+1,\ldots,T_s^*\}$ , we have $g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K}\right)$ . Thus,
|
| 985 |
+
|
| 986 |
+
$$q_k^{(T_s^*)} = q_k^{(T_f^*)} + \eta \cdot \Theta\left(\frac{L^2 \Delta^2 \delta^2 \epsilon}{K}\right) \cdot (T_s^* - T_f^*)$$
|
| 987 |
+
$$= \Theta(\log(KL\Delta \epsilon^{-1})),$$
|
| 988 |
+
|
| 989 |
+
using the total number of updates and the scaling of $T_s^*$ . (Here, $T_s^* - T_f^* = \Theta\left(\frac{K \log(KL\Delta\epsilon^{-1})}{L^2\Delta^2\delta^2\epsilon}\right)$ .)
|
| 990 |
+
|
| 991 |
+
Similarly, for the cross-terms, by Lemma 9, $|g_{k,m}^{(t)}| = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right)$ for $m \neq k$ , and hence
|
| 992 |
+
|
| 993 |
+
$$\begin{split} q_{k,m}^{(T_s^*)} &\leq |q_{k,m}^{(T_f^*)}| + \eta \cdot \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right) \cdot (T_s^* - T_f^*) \\ &= \Theta\left(\frac{\log(KL\Delta \epsilon^{-1})}{K}\right). \end{split}$$
|
| 994 |
+
|
| 995 |
+
Therefore,
|
| 996 |
+
|
| 997 |
+
$$q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)} = -\Theta(\log(KL\Delta\epsilon^{-1})),$$
|
| 998 |
+
|
| 999 |
+
{24}------------------------------------------------
|
| 1000 |
+
|
| 1001 |
+
and so
|
| 1002 |
+
|
| 1003 |
+
$$\exp(q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)}) = \mathcal{O}\left(\frac{\epsilon}{K}\right),\,$$
|
| 1004 |
+
|
| 1005 |
+
where the scaling in the sharp regime produces the $\epsilon$ factor
|
| 1006 |
+
|
| 1007 |
+
For the attention, using the property from Lemma 3,
|
| 1008 |
+
|
| 1009 |
+
$$\operatorname{Attn}_k^{(T_s^*)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)}) + 1}.$$
|
| 1010 |
+
By the previous bounds, and using $|\mathcal{V}_k| \geq u_k N/K$ and $\frac{1}{u_k} - \frac{1}{K} = \Theta(\delta)$ , we obtain:
|
| 1011 |
+
|
| 1012 |
+
$$\operatorname{Attn}_{k}^{(T_{s}^{*})} \geq \frac{1}{\mathcal{O}(\epsilon) \cdot \mathcal{O}(\frac{1}{n_{k}} - \frac{1}{K}) + 1} = \Omega\left(\frac{1}{1 + \epsilon\delta}\right).$$
|
| 1013 |
+
|
| 1014 |
+
Finally,
|
| 1015 |
+
|
| 1016 |
+
$$1 - \operatorname{Attn}_{k}^{(T_{s}^{*})} \leq \frac{\mathcal{O}(\epsilon) \cdot \mathcal{O}(\frac{1}{u_{k}} - \frac{1}{K})}{\mathcal{O}(\epsilon) \cdot \mathcal{O}(\frac{1}{u_{k}} - \frac{1}{K}) + 1} = \mathcal{O}(\epsilon\delta),$$
|
| 1017 |
+
|
| 1018 |
+
which follows because $\frac{1}{u_k} - \frac{1}{K} = \Theta(\delta)$ .
|
| 1019 |
+
|
| 1020 |
+
This completes the proof of Lemma 10 and Proposition 4.
|
| 1021 |
+
|
| 1022 |
+
## <span id="page-24-0"></span>F.2 PROOF OF THEOREM 2
|
| 1023 |
+
|
| 1024 |
+
As in the proof of Theorem 1, the prediction error $\mathcal{L}(P;Q)$ (from Eq. (5)) can be written as
|
| 1025 |
+
|
| 1026 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} (1 - \text{Attn}_k^{(t)})^2 \mathcal{O}(L^2 \Delta^2)\right].$$
|
| 1027 |
+
|
| 1028 |
+
Suppose $x_{\text{query}} = v_k$ at time $t = T_s^*$ . By Lemma 10, we have $1 - \text{Attn}_k^{(T_s^*)} = O(\epsilon \delta)$ . Therefore,
|
| 1029 |
+
|
| 1030 |
+
$$\mathcal{L}^{(T_s^*)}(P;Q) = \frac{1}{2} \sum_{k=1}^K \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} (1 - \text{Attn}_k^{(T_s^*)})^2 \mathcal{O}(L^2 \Delta^2) \right]$$
|
| 1031 |
+
$$= \mathbb{E} \left[ (1 - \text{Attn}_k^{(T_s^*)})^2 \mathcal{O}(L^2 \Delta^2) \right]$$
|
| 1032 |
+
$$= \mathcal{O}(\epsilon^2 \delta^2).$$
|
| 1033 |
+
|
| 1034 |
+
Under the scaling regime for sharp L, either $\delta = o(1)$ or $\epsilon = o(1)$ (since the in-context learning regime assumes both go to zero), and hence $\mathcal{L}^{(T_s^*)}(P;Q) = \mathcal{O}(\epsilon^2)$ as required.
|
| 1035 |
+
|
| 1036 |
+
<span id="page-24-1"></span>This completes the proof of Theorem 2.
|
| 1037 |
+
|
| 1038 |
+
# **PROOF OF PROPOSITION 1**
|
| 1039 |
+
|
| 1040 |
+
The result that $1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\epsilon)$ holds under both the flat L regime and the sharp L regime, as established in Lemma 8 and Lemma 10.
|
iclr26/2g8vgmyXgQ/parse_report.json
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"paper_id": "2g8vgmyXgQ",
|
| 3 |
+
"pipeline": "marker_non_llm_v3",
|
| 4 |
+
"parser": "marker_single",
|
| 5 |
+
"formats": [
|
| 6 |
+
"markdown",
|
| 7 |
+
"chunks"
|
| 8 |
+
],
|
| 9 |
+
"llm_enabled": false,
|
| 10 |
+
"pdf_path": "/network/scratch/j/jianan.zhao/ReviewAgent/data/processed_papers/iclr26_20260429_1952_all/raw/2g8vgmyXgQ.pdf",
|
| 11 |
+
"pdf_sha256": "602943fa6e9ed62e4b40ca2ab90360db1f39fdad337c7bfedb40c7e9978ed819",
|
| 12 |
+
"bytes": 1419286,
|
| 13 |
+
"source": "https://openreview.net/pdf?id=2g8vgmyXgQ",
|
| 14 |
+
"page_count": 25,
|
| 15 |
+
"ok": true,
|
| 16 |
+
"elapsed_seconds": 282.78,
|
| 17 |
+
"paper2markdown_v3": {
|
| 18 |
+
"paper_id": "2g8vgmyXgQ",
|
| 19 |
+
"pipeline": "Paper2Markdown-V3",
|
| 20 |
+
"ok": true,
|
| 21 |
+
"page_count": 25,
|
| 22 |
+
"chunk_count": 276,
|
| 23 |
+
"main_body_chunk_count": 83,
|
| 24 |
+
"appendix_chunk_count": 184,
|
| 25 |
+
"reference_chunk_count": 9,
|
| 26 |
+
"model_text_chars": 48438,
|
| 27 |
+
"raw_markdown_chars": 95881,
|
| 28 |
+
"sanitized_chars": 92221,
|
| 29 |
+
"page_provenance": {
|
| 30 |
+
"min_page": 1,
|
| 31 |
+
"max_page": 25,
|
| 32 |
+
"invalid_count": 0
|
| 33 |
+
},
|
| 34 |
+
"marker_block_type_counts": {
|
| 35 |
+
"Caption": 4,
|
| 36 |
+
"Equation": 89,
|
| 37 |
+
"Figure": 6,
|
| 38 |
+
"FigureGroup": 3,
|
| 39 |
+
"ListGroup": 10,
|
| 40 |
+
"PageFooter": 25,
|
| 41 |
+
"PageHeader": 25,
|
| 42 |
+
"SectionHeader": 28,
|
| 43 |
+
"Text": 846
|
| 44 |
+
},
|
| 45 |
+
"asset_count_raw": 9,
|
| 46 |
+
"asset_count_model_kept": 9,
|
| 47 |
+
"asset_count_rejected": 0,
|
| 48 |
+
"asset_reject_reasons": {
|
| 49 |
+
"kept": 9
|
| 50 |
+
},
|
| 51 |
+
"artifact_leak_audit": {
|
| 52 |
+
"ok": true,
|
| 53 |
+
"hits": {
|
| 54 |
+
"Anonymous Authors": [],
|
| 55 |
+
"ACKNOWLEDGMENT": [],
|
| 56 |
+
"OpenReview": [],
|
| 57 |
+
"\"accept_label\"": [],
|
| 58 |
+
"\"decision\"": [],
|
| 59 |
+
"\"decision_tier\"": [],
|
| 60 |
+
"\"source_status\"": [],
|
| 61 |
+
"Meta-review": [],
|
| 62 |
+
"Official Review": [],
|
| 63 |
+
"official_reviews": [],
|
| 64 |
+
"meta_reviews": [],
|
| 65 |
+
"suggested_verdict_score": []
|
| 66 |
+
},
|
| 67 |
+
"artifact_count": 2
|
| 68 |
+
},
|
| 69 |
+
"default_model_input": "model_text_v3.txt",
|
| 70 |
+
"appendix_input": "appendix_text_v3.txt",
|
| 71 |
+
"reference_input": "reference_text_v3.txt"
|
| 72 |
+
}
|
| 73 |
+
}
|
iclr26/2g8vgmyXgQ/reference_chunks.jsonl
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0083", "section": "REFERENCES", "page_start": 10, "page_end": 10, "type": "ListGroup", "text": "Rishabh Agarwal, Avi Singh, Lei Zhang, Bernd Bohnet, Luis Rosias, Stephanie Chan, Biao Zhang, Ankesh Anand, Zaheer Abbas, Azade Nova, et al. Many-shot in-context learning. Advances in Neural Information Processing Systems , 37:76930–76966, 2024. Ekin Akyürek, Dale Schuurmans, Jacob Andreas, Tengyu Ma, and Denny Zhou. What learning algorithm is in-context learning? investigations with linear models. In International Conference on Learning Representations , 2023. Yu Bai, Fan Chen, Huan Wang, Caiming Xiong, and Song Mei. Transformers as statisticians: Provable in-context learning with in-context algorithm selection. Advances in neural information processing systems , 36:57125–57211, 2023. Jiarui Bi, Zengliang Zhu, and Qinglong Meng. Transformer in computer vision. In 2021 IEEE International Conference on Computer Dcience, Electronic Information Engineering and Intelligent Control Technology (CEI), pp. 178–188. IEEE, 2021. Alberto Bietti, Vivien Cabannes, Diane Bouchacourt, Herve Jegou, and Leon Bottou. Birth of a transformer: A memory viewpoint. Advances in Neural Information Processing Systems , 36: 1560–1588, 2023.", "source": "marker_v2", "marker_block_id": "/page/9/ListGroup/309"}
|
| 2 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0084", "section": "REFERENCES", "page_start": 11, "page_end": 11, "type": "ListGroup", "text": "Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. Advances in Neural Information Processing Systems , 33:1877–1901, 2020. Siyu Chen, Heejune Sheen, Tianhao Wang, and Zhuoran Yang. Training dynamics of multi-head softmax attention for in-context learning: Emergence, convergence, and optimality. arXiv preprint arXiv:2402.19442 , 2024. Xiang Cheng, Yuxin Chen, and Suvrit Sra. Transformers implement functional gradient descent to learn non-linear functions in context. In Proceedings of the 41st International Conference on Machine Learning , pp. 8002–8037, 2024. Liam Collins, Advait Parulekar, Aryan Mokhtari, Sujay Sanghavi, and Sanjay Shakkottai. In-context learning with transformers: Softmax attention adapts to function lipschitzness. arXiv preprint arXiv:2402.11639 , 2024. Damai Dai, Yutao Sun, Li Dong, Yaru Hao, Shuming Ma, Zhifang Sui, and Furu Wei. Why can gpt learn in-context? language models implicitly perform gradient descent as meta-optimizers. arXiv preprint arXiv:2212.10559 , 2022. Ezra Edelman, Nikolaos Tsilivis, Benjamin Edelman, Eran Malach, and Surbhi Goel. The evolution of statistical induction heads: In-context learning markov chains. Advances in Neural Information Processing Systems , 37:64273–64311, 2024. Fabian Falck, Ziyu Wang, and Chris Holmes. Is in-context learning in large language models bayesian? a martingale perspective. arXiv preprint arXiv:2406.00793 , 2024. Shivam Garg, Dimitris Tsipras, Percy S Liang, and Gregory Valiant. What can transformers learn in-context? a case study of simple function classes. Advances in Neural Information Processing Systems , 35:30583–30598, 2022. Micah Goldblum, Hossein Souri, Renkun Ni, Manli Shu, Viraj Prabhu, Gowthami Somepalli, Prithvijit Chattopadhyay, Mark Ibrahim, Adrien Bardes, Judy Hoffman, et al. Battle of the backbones: A large-scale comparison of pretrained models across computer vision tasks. Advances in Neural Information Processing Systems , 36, 2024. Kai Han, Yunhe Wang, Hanting Chen, Xinghao Chen, Jianyuan Guo, Zhenhua Liu, Yehui Tang, An Xiao, Chunjing Xu, Yixing Xu, et al. A survey on vision transformer. IEEE Transactions on Pattern Analysis and Machine Intelligence , 45(1):87–110, 2022. Irina Higgins, David Amos, David Pfau, Sebastien Racaniere, Loic Matthey, Danilo Rezende, and Alexander Lerchner. Towards a definition of disentangled representations. arXiv preprint arXiv:1812.02230 , 2018. Yu Huang, Yuan Cheng, and Yingbin Liang. In-context convergence of transformers. In International Conference on Machine Learning . PMLR, 2024. Hong Jun Jeon, Jason D Lee, Qi Lei, and Benjamin Van Roy. An information-theoretic analysis of in-context learning. arXiv preprint arXiv:2401.15530 , 2024. Katikapalli Subramanyam Kalyan, Ajit Rajasekharan, and Sivanesan Sangeetha. Ammus: A survey of transformer-based pretrained models in natural language processing. arXiv preprint arXiv:2108.05542 , 2021. Siddique Latif, Aun Zaidi, Heriberto Cuayahuitl, Fahad Shamshad, Moazzam Shoukat, and Junaid Qadir. Transformers in speech processing: A survey. arXiv preprint arXiv:2303.11607 , 2023. Hongkang Li, Meng Wang, Songtao Lu, Xiaodong Cui, and Pin-Yu Chen. How do nonlinear transformers learn and generalize in in-context learning? In International Conference on Machine Learning , 2024a. Tianle Li, Ge Zhang, Quy Duc Do, Xiang Yue, and Wenhu Chen. Long-context llms struggle with long in-context learning. arXiv preprint arXiv:2404.02060 , 2024b.", "source": "marker_v2", "marker_block_id": "/page/10/ListGroup/340"}
|
| 3 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0085", "section": "REFERENCES", "page_start": 12, "page_end": 12, "type": "ListGroup", "text": "Yuchen Li, Yuanzhi Li, and Andrej Risteski. How do transformers learn topic structure: Towards a mechanistic understanding. In International Conference on Machine Learning , pp. 19689–19729. PMLR, 2023. Ziqian Lin and Kangwook Lee. Dual operating modes of in-context learning. In Forty-first Interna tional Conference on Machine Learning , 2024. Yue M Lu, Mary I Letey, Jacob A Zavatone-Veth, Anindita Maiti, and Cengiz Pehlevan. Asymptotic theory of in-context learning by linear attention. arXiv preprint arXiv:2405.11751 , 2024. Arvind Mahankali, Tatsunori B Hashimoto, and Tengyu Ma. One step of gradient descent is provably the optimal in-context learner with one layer of linear self-attention. arXiv preprint arXiv:2307.03576 , 2023. Ashok Vardhan Makkuva, Marco Bondaschi, Adway Girish, Alliot Nagle, Hyeji Kim, Michael Gastpar, and Chanakya Ekbote. Local to global: Learning dynamics and effect of initialization for transformers. Advances in Neural Information Processing Systems , 37:86243–86308, 2024. Ambuj Mehrish, Navonil Majumder, Rishabh Bharadwaj, Rada Mihalcea, and Soujanya Poria. A review of deep learning techniques for speech processing. Information Fusion , 99:101869, 2023. Eshaan Nichani, Alex Damian, and Jason D Lee. How transformers learn causal structure with gradient descent. In International Conference on Machine Learning , 2024. Kazusato Oko, Yujin Song, Taiji Suzuki, and Denny Wu. Pretrained transformer efficiently learns low-dimensional target functions in-context. Advances in Neural Information Processing Systems , 37:77316–77365, 2024. Core Francisco Park, Andrew Lee, Ekdeep Singh Lubana, Yongyi Yang, Maya Okawa, Kento Nishi, Martin Wattenberg, and Hidenori Tanaka. Iclr: In-context learning of representations. In International Conference on Learning Representations , 2025. Nived Rajaraman, Marco Bondaschi, Ashok Vardhan Makkuva, Kannan Ramchandran, and Michael Gastpar. Transformers on markov data: Constant depth suffices. Advances in Neural Information Processing Systems , 37:137521–137556, 2024. Ruifeng Ren and Yong Liu. Towards understanding how transformers learn in-context through a representation learning lens. Advances in Neural Information Processing Systems , 37:892–933, 2024. Haoyuan Sun, Ali Jadbabaie, and Navid Azizan. In-context learning of polynomial kernel regression in transformers with glu layers. arXiv preprint arXiv:2501.18187 , 2025. Lewis Tunstall, Leandro Von Werra, and Thomas Wolf. Natural language processing with transform ers . \" O'Reilly Media, Inc.\", 2022. Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. Advances in Neural Information Processing Systems , 30, 2017. Johannes Von Oswald, Eyvind Niklasson, Ettore Randazzo, João Sacramento, Alexander Mordvintsev, Andrey Zhmoginov, and Max Vladymyrov. Transformers learn in-context by gradient descent. In International Conference on Machine Learning , pp. 35151–35174. PMLR, 2023. Xin Wang, Hong Chen, Yuwei Zhou, Jianxin Ma, and Wenwu Zhu. Disentangled representation learning for recommendation. IEEE Transactions on Pattern Analysis and Machine Intelligence , 45(1):408–424, 2022. Xin Wang, Hong Chen, Si'ao Tang, Zihao Wu, and Wenwu Zhu. Disentangled representation learning. IEEE Transactions on Pattern Analysis and Machine Intelligence , 2024. Xinyi Wang, Wanrong Zhu, and William Yang Wang. Large language models are implicitly topic models: Explaining and finding good demonstrations for in-context learning. arXiv preprint arXiv:2301.11916 , 1:15, 2023.", "source": "marker_v2", "marker_block_id": "/page/11/ListGroup/347"}
|
| 4 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0086", "section": "REFERENCES", "page_start": 13, "page_end": 13, "type": "ListGroup", "text": "Zhiyong Wu, Yaoxiang Wang, Jiacheng Ye, and Lingpeng Kong. Self-adaptive in-context learning: An information compression perspective for in-context example selection and ordering. In Annual Meeting of the Association for Computational Linguistics , pp. 1423–1436, 2023. Sang Michael Xie, Aditi Raghunathan, Percy Liang, and Tengyu Ma. An explanation of in-context learning as implicit bayesian inference. arXiv preprint arXiv:2111.02080 , 2021. Tong Yang, Yu Huang, Yingbin Liang, and Yuejie Chi. In-context learning with representations: Contextual generalization of trained transformers. Advances in Neural Information Processing Systems , 2024. Ruiqi Zhang, Spencer Frei, and Peter L Bartlett. Trained transformers learn linear models in-context. Journal of Machine Learning Research , 25(49):1–55, 2024. Yufeng Zhang, Fengzhuo Zhang, Zhuoran Yang, and Zhaoran Wang. What and how does in-context learning learn? bayesian model averaging, parameterization, and generalization. arXiv preprint arXiv:2305.19420 , 2023.", "source": "marker_v2", "marker_block_id": "/page/12/ListGroup/191"}
|
| 5 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0087", "section": "REFERENCES", "page_start": 14, "page_end": 14, "type": "Text", "text": "APPENDIX A The Use of LLMs for Polishing Writing 15 B Additional Experimental Results 15 C Proof of Lemma 1 17 D Proof of Lemma 2 18 E Proofs for Flat L-Regime 19 E.1 Proof of Proposition 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 E.2 Proof of Proposition 3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 E.3 Proof of Theorem 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 F Proofs for Sharp L-Regime 24 F.1 Proof of Proposition 4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 F.2 Proof of Theorem 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 G Proof of Proposition 1 25", "source": "marker_v2", "marker_block_id": "/page/13/Text/1"}
|
| 6 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0088", "section": "REFERENCES", "page_start": 15, "page_end": 15, "type": "Text", "text": "In the appendices, we first present additional experimental results in Appendix B. Then we present detailed proofs of Lemma 1 and Lemma 2 in Appendix C and Appendix D. For ease of exposition, before establishing the two main theorems, we separately analyze the convergence dynamics under both the flat L-regime and the sharp L-regime.", "source": "marker_v2", "marker_block_id": "/page/14/Text/1"}
|
| 7 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0089", "section": "REFERENCES", "page_start": 15, "page_end": 15, "type": "Text", "text": "Specifically, following the proof of Lemma 1, we prove Proposition 2 (see Appendix E.1) and Proposition 3 (see Appendix E.2) as preliminaries for the proof of Theorem 1 in the flat L-regime (see Appendix E.3).", "source": "marker_v2", "marker_block_id": "/page/14/Text/2"}
|
| 8 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0090", "section": "REFERENCES", "page_start": 15, "page_end": 15, "type": "Text", "text": "We then proceed to prove Proposition 4 (see Appendix F.1) as a preliminary for Theorem 2 (see Appendix F.2) in the sharp L-regime.", "source": "marker_v2", "marker_block_id": "/page/14/Text/3"}
|
| 9 |
+
{"paper_id": "2g8vgmyXgQ", "chunk_id": "2g8vgmyXgQ:0091", "section": "REFERENCES", "page_start": 15, "page_end": 15, "type": "Text", "text": "Finally, based on Theorem 1 and Theorem 2, we prove Proposition 1 (see Appendix G).", "source": "marker_v2", "marker_block_id": "/page/14/Text/4"}
|
iclr26/2g8vgmyXgQ/reference_text_v3.txt
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
[p. 10 | section: REFERENCES | type: ListGroup]
|
| 2 |
+
Rishabh Agarwal, Avi Singh, Lei Zhang, Bernd Bohnet, Luis Rosias, Stephanie Chan, Biao Zhang, Ankesh Anand, Zaheer Abbas, Azade Nova, et al. Many-shot in-context learning. Advances in Neural Information Processing Systems , 37:76930–76966, 2024. Ekin Akyürek, Dale Schuurmans, Jacob Andreas, Tengyu Ma, and Denny Zhou. What learning algorithm is in-context learning? investigations with linear models. In International Conference on Learning Representations , 2023. Yu Bai, Fan Chen, Huan Wang, Caiming Xiong, and Song Mei. Transformers as statisticians: Provable in-context learning with in-context algorithm selection. Advances in neural information processing systems , 36:57125–57211, 2023. Jiarui Bi, Zengliang Zhu, and Qinglong Meng. Transformer in computer vision. In 2021 IEEE International Conference on Computer Dcience, Electronic Information Engineering and Intelligent Control Technology (CEI), pp. 178–188. IEEE, 2021. Alberto Bietti, Vivien Cabannes, Diane Bouchacourt, Herve Jegou, and Leon Bottou. Birth of a transformer: A memory viewpoint. Advances in Neural Information Processing Systems , 36: 1560–1588, 2023.
|
| 3 |
+
|
| 4 |
+
[p. 11 | section: REFERENCES | type: ListGroup]
|
| 5 |
+
Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. Advances in Neural Information Processing Systems , 33:1877–1901, 2020. Siyu Chen, Heejune Sheen, Tianhao Wang, and Zhuoran Yang. Training dynamics of multi-head softmax attention for in-context learning: Emergence, convergence, and optimality. arXiv preprint arXiv:2402.19442 , 2024. Xiang Cheng, Yuxin Chen, and Suvrit Sra. Transformers implement functional gradient descent to learn non-linear functions in context. In Proceedings of the 41st International Conference on Machine Learning , pp. 8002–8037, 2024. Liam Collins, Advait Parulekar, Aryan Mokhtari, Sujay Sanghavi, and Sanjay Shakkottai. In-context learning with transformers: Softmax attention adapts to function lipschitzness. arXiv preprint arXiv:2402.11639 , 2024. Damai Dai, Yutao Sun, Li Dong, Yaru Hao, Shuming Ma, Zhifang Sui, and Furu Wei. Why can gpt learn in-context? language models implicitly perform gradient descent as meta-optimizers. arXiv preprint arXiv:2212.10559 , 2022. Ezra Edelman, Nikolaos Tsilivis, Benjamin Edelman, Eran Malach, and Surbhi Goel. The evolution of statistical induction heads: In-context learning markov chains. Advances in Neural Information Processing Systems , 37:64273–64311, 2024. Fabian Falck, Ziyu Wang, and Chris Holmes. Is in-context learning in large language models bayesian? a martingale perspective. arXiv preprint arXiv:2406.00793 , 2024. Shivam Garg, Dimitris Tsipras, Percy S Liang, and Gregory Valiant. What can transformers learn in-context? a case study of simple function classes. Advances in Neural Information Processing Systems , 35:30583–30598, 2022. Micah Goldblum, Hossein Souri, Renkun Ni, Manli Shu, Viraj Prabhu, Gowthami Somepalli, Prithvijit Chattopadhyay, Mark Ibrahim, Adrien Bardes, Judy Hoffman, et al. Battle of the backbones: A large-scale comparison of pretrained models across computer vision tasks. Advances in Neural Information Processing Systems , 36, 2024. Kai Han, Yunhe Wang, Hanting Chen, Xinghao Chen, Jianyuan Guo, Zhenhua Liu, Yehui Tang, An Xiao, Chunjing Xu, Yixing Xu, et al. A survey on vision transformer. IEEE Transactions on Pattern Analysis and Machine Intelligence , 45(1):87–110, 2022. Irina Higgins, David Amos, David Pfau, Sebastien Racaniere, Loic Matthey, Danilo Rezende, and Alexander Lerchner. Towards a definition of disentangled representations. arXiv preprint arXiv:1812.02230 , 2018. Yu Huang, Yuan Cheng, and Yingbin Liang. In-context convergence of transformers. In International Conference on Machine Learning . PMLR, 2024. Hong Jun Jeon, Jason D Lee, Qi Lei, and Benjamin Van Roy. An information-theoretic analysis of in-context learning. arXiv preprint arXiv:2401.15530 , 2024. Katikapalli Subramanyam Kalyan, Ajit Rajasekharan, and Sivanesan Sangeetha. Ammus: A survey of transformer-based pretrained models in natural language processing. arXiv preprint arXiv:2108.05542 , 2021. Siddique Latif, Aun Zaidi, Heriberto Cuayahuitl, Fahad Shamshad, Moazzam Shoukat, and Junaid Qadir. Transformers in speech processing: A survey. arXiv preprint arXiv:2303.11607 , 2023. Hongkang Li, Meng Wang, Songtao Lu, Xiaodong Cui, and Pin-Yu Chen. How do nonlinear transformers learn and generalize in in-context learning? In International Conference on Machine Learning , 2024a. Tianle Li, Ge Zhang, Quy Duc Do, Xiang Yue, and Wenhu Chen. Long-context llms struggle with long in-context learning. arXiv preprint arXiv:2404.02060 , 2024b.
|
| 6 |
+
|
| 7 |
+
[p. 12 | section: REFERENCES | type: ListGroup]
|
| 8 |
+
Yuchen Li, Yuanzhi Li, and Andrej Risteski. How do transformers learn topic structure: Towards a mechanistic understanding. In International Conference on Machine Learning , pp. 19689–19729. PMLR, 2023. Ziqian Lin and Kangwook Lee. Dual operating modes of in-context learning. In Forty-first Interna tional Conference on Machine Learning , 2024. Yue M Lu, Mary I Letey, Jacob A Zavatone-Veth, Anindita Maiti, and Cengiz Pehlevan. Asymptotic theory of in-context learning by linear attention. arXiv preprint arXiv:2405.11751 , 2024. Arvind Mahankali, Tatsunori B Hashimoto, and Tengyu Ma. One step of gradient descent is provably the optimal in-context learner with one layer of linear self-attention. arXiv preprint arXiv:2307.03576 , 2023. Ashok Vardhan Makkuva, Marco Bondaschi, Adway Girish, Alliot Nagle, Hyeji Kim, Michael Gastpar, and Chanakya Ekbote. Local to global: Learning dynamics and effect of initialization for transformers. Advances in Neural Information Processing Systems , 37:86243–86308, 2024. Ambuj Mehrish, Navonil Majumder, Rishabh Bharadwaj, Rada Mihalcea, and Soujanya Poria. A review of deep learning techniques for speech processing. Information Fusion , 99:101869, 2023. Eshaan Nichani, Alex Damian, and Jason D Lee. How transformers learn causal structure with gradient descent. In International Conference on Machine Learning , 2024. Kazusato Oko, Yujin Song, Taiji Suzuki, and Denny Wu. Pretrained transformer efficiently learns low-dimensional target functions in-context. Advances in Neural Information Processing Systems , 37:77316–77365, 2024. Core Francisco Park, Andrew Lee, Ekdeep Singh Lubana, Yongyi Yang, Maya Okawa, Kento Nishi, Martin Wattenberg, and Hidenori Tanaka. Iclr: In-context learning of representations. In International Conference on Learning Representations , 2025. Nived Rajaraman, Marco Bondaschi, Ashok Vardhan Makkuva, Kannan Ramchandran, and Michael Gastpar. Transformers on markov data: Constant depth suffices. Advances in Neural Information Processing Systems , 37:137521–137556, 2024. Ruifeng Ren and Yong Liu. Towards understanding how transformers learn in-context through a representation learning lens. Advances in Neural Information Processing Systems , 37:892–933, 2024. Haoyuan Sun, Ali Jadbabaie, and Navid Azizan. In-context learning of polynomial kernel regression in transformers with glu layers. arXiv preprint arXiv:2501.18187 , 2025. Lewis Tunstall, Leandro Von Werra, and Thomas Wolf. Natural language processing with transform ers . " O'Reilly Media, Inc.", 2022. Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. Advances in Neural Information Processing Systems , 30, 2017. Johannes Von Oswald, Eyvind Niklasson, Ettore Randazzo, João Sacramento, Alexander Mordvintsev, Andrey Zhmoginov, and Max Vladymyrov. Transformers learn in-context by gradient descent. In International Conference on Machine Learning , pp. 35151–35174. PMLR, 2023. Xin Wang, Hong Chen, Yuwei Zhou, Jianxin Ma, and Wenwu Zhu. Disentangled representation learning for recommendation. IEEE Transactions on Pattern Analysis and Machine Intelligence , 45(1):408–424, 2022. Xin Wang, Hong Chen, Si'ao Tang, Zihao Wu, and Wenwu Zhu. Disentangled representation learning. IEEE Transactions on Pattern Analysis and Machine Intelligence , 2024. Xinyi Wang, Wanrong Zhu, and William Yang Wang. Large language models are implicitly topic models: Explaining and finding good demonstrations for in-context learning. arXiv preprint arXiv:2301.11916 , 1:15, 2023.
|
| 9 |
+
|
| 10 |
+
[p. 13 | section: REFERENCES | type: ListGroup]
|
| 11 |
+
Zhiyong Wu, Yaoxiang Wang, Jiacheng Ye, and Lingpeng Kong. Self-adaptive in-context learning: An information compression perspective for in-context example selection and ordering. In Annual Meeting of the Association for Computational Linguistics , pp. 1423–1436, 2023. Sang Michael Xie, Aditi Raghunathan, Percy Liang, and Tengyu Ma. An explanation of in-context learning as implicit bayesian inference. arXiv preprint arXiv:2111.02080 , 2021. Tong Yang, Yu Huang, Yingbin Liang, and Yuejie Chi. In-context learning with representations: Contextual generalization of trained transformers. Advances in Neural Information Processing Systems , 2024. Ruiqi Zhang, Spencer Frei, and Peter L Bartlett. Trained transformers learn linear models in-context. Journal of Machine Learning Research , 25(49):1–55, 2024. Yufeng Zhang, Fengzhuo Zhang, Zhuoran Yang, and Zhaoran Wang. What and how does in-context learning learn? bayesian model averaging, parameterization, and generalization. arXiv preprint arXiv:2305.19420 , 2023.
|
| 12 |
+
|
| 13 |
+
[p. 14 | section: REFERENCES | type: Text]
|
| 14 |
+
APPENDIX A The Use of LLMs for Polishing Writing 15 B Additional Experimental Results 15 C Proof of Lemma 1 17 D Proof of Lemma 2 18 E Proofs for Flat L-Regime 19 E.1 Proof of Proposition 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 E.2 Proof of Proposition 3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 E.3 Proof of Theorem 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 F Proofs for Sharp L-Regime 24 F.1 Proof of Proposition 4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 F.2 Proof of Theorem 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 G Proof of Proposition 1 25
|
| 15 |
+
|
| 16 |
+
[p. 15 | section: REFERENCES | type: Text]
|
| 17 |
+
In the appendices, we first present additional experimental results in Appendix B. Then we present detailed proofs of Lemma 1 and Lemma 2 in Appendix C and Appendix D. For ease of exposition, before establishing the two main theorems, we separately analyze the convergence dynamics under both the flat L-regime and the sharp L-regime.
|
| 18 |
+
|
| 19 |
+
[p. 15 | section: REFERENCES | type: Text]
|
| 20 |
+
Specifically, following the proof of Lemma 1, we prove Proposition 2 (see Appendix E.1) and Proposition 3 (see Appendix E.2) as preliminaries for the proof of Theorem 1 in the flat L-regime (see Appendix E.3).
|
| 21 |
+
|
| 22 |
+
[p. 15 | section: REFERENCES | type: Text]
|
| 23 |
+
We then proceed to prove Proposition 4 (see Appendix F.1) as a preliminary for Theorem 2 (see Appendix F.2) in the sharp L-regime.
|
| 24 |
+
|
| 25 |
+
[p. 15 | section: REFERENCES | type: Text]
|
| 26 |
+
Finally, based on Theorem 1 and Theorem 2, we prove Proposition 1 (see Appendix G).
|
iclr26/2g8vgmyXgQ/sanitization_report.json
ADDED
|
@@ -0,0 +1,56 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"paper_id": "2g8vgmyXgQ",
|
| 3 |
+
"pipeline": "Paper2Markdown-V3",
|
| 4 |
+
"ok": true,
|
| 5 |
+
"page_count": 25,
|
| 6 |
+
"chunk_count": 276,
|
| 7 |
+
"main_body_chunk_count": 83,
|
| 8 |
+
"appendix_chunk_count": 184,
|
| 9 |
+
"reference_chunk_count": 9,
|
| 10 |
+
"model_text_chars": 48438,
|
| 11 |
+
"raw_markdown_chars": 95881,
|
| 12 |
+
"sanitized_chars": 92221,
|
| 13 |
+
"page_provenance": {
|
| 14 |
+
"min_page": 1,
|
| 15 |
+
"max_page": 25,
|
| 16 |
+
"invalid_count": 0
|
| 17 |
+
},
|
| 18 |
+
"marker_block_type_counts": {
|
| 19 |
+
"Caption": 4,
|
| 20 |
+
"Equation": 89,
|
| 21 |
+
"Figure": 6,
|
| 22 |
+
"FigureGroup": 3,
|
| 23 |
+
"ListGroup": 10,
|
| 24 |
+
"PageFooter": 25,
|
| 25 |
+
"PageHeader": 25,
|
| 26 |
+
"SectionHeader": 28,
|
| 27 |
+
"Text": 846
|
| 28 |
+
},
|
| 29 |
+
"asset_count_raw": 9,
|
| 30 |
+
"asset_count_model_kept": 9,
|
| 31 |
+
"asset_count_rejected": 0,
|
| 32 |
+
"asset_reject_reasons": {
|
| 33 |
+
"kept": 9
|
| 34 |
+
},
|
| 35 |
+
"artifact_leak_audit": {
|
| 36 |
+
"ok": true,
|
| 37 |
+
"hits": {
|
| 38 |
+
"Anonymous Authors": [],
|
| 39 |
+
"ACKNOWLEDGMENT": [],
|
| 40 |
+
"OpenReview": [],
|
| 41 |
+
"\"accept_label\"": [],
|
| 42 |
+
"\"decision\"": [],
|
| 43 |
+
"\"decision_tier\"": [],
|
| 44 |
+
"\"source_status\"": [],
|
| 45 |
+
"Meta-review": [],
|
| 46 |
+
"Official Review": [],
|
| 47 |
+
"official_reviews": [],
|
| 48 |
+
"meta_reviews": [],
|
| 49 |
+
"suggested_verdict_score": []
|
| 50 |
+
},
|
| 51 |
+
"artifact_count": 2
|
| 52 |
+
},
|
| 53 |
+
"default_model_input": "model_text_v3.txt",
|
| 54 |
+
"appendix_input": "appendix_text_v3.txt",
|
| 55 |
+
"reference_input": "reference_text_v3.txt"
|
| 56 |
+
}
|
iclr26/2g8vgmyXgQ/sanitized_v3.txt
ADDED
|
@@ -0,0 +1,446 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{0}
|
| 2 |
+
# ABSTRACT
|
| 3 |
+
The transformer architecture has revolutionized machine learning by processing input sequences into outputs. A defining feature is in-context learning (ICL)—the ability to perform unseen tasks from prompts without updating model parameters. Early theoretical work focused on linear tasks, and recent studies have begun exploring nonlinear functions. Yet a rigorous analysis of the training dynamics—how transformers learn such complex tasks—remains elusive. This paper presents the first formal analysis of ICL training dynamics for a broad class of nonlinear regression functions. We analyze the stage-wise dynamics of attention during training: attention scores between a query token and its target features rise rapidly at first, then gradually converge to one, while attention to irrelevant features decays more slowly and can oscillate. Our analysis explicitly characterizes how general non-degenerate L-Lipschitz task functions shape attention weights, identifying the Lipschitz constant L as the key factor governing the convergence dynamics. Leveraging these insights, for two distinct regimes depending on whether L is below or above a threshold, we derive different time bounds to guarantee nearzero prediction error. Despite convergence time depending on the task, we prove query tokens ultimately focus on highly relevant prompt tokens, demonstrating transformers' robust ICL capability.
|
| 4 |
+
# 1 INTRODUCTION
|
| 5 |
+
The transformer architecture [\(Vaswani et al., 2017\)](#page-11-0) has driven transformative advances across a wide spectrum of machine learning domains, including computer vision [\(Bi et al., 2021;](#page-9-0) [Han et al., 2022;](#page-10-0) [Goldblum et al., 2024\)](#page-10-1), natural language processing [\(Kalyan et al., 2021;](#page-10-2) [Tunstall et al., 2022\)](#page-11-1), and speech processing [\(Mehrish et al., 2023;](#page-11-2) [Latif et al., 2023\)](#page-10-3). A salient feature of transformers is their ability to perform new tasks without updating parameters, simply by conditioning on a few input-output examples—known as prompts. This capability, referred to as *in-context learning (ICL)*, enables models to generalize to unseen tasks purely through inference [\(Brown et al., 2020\)](#page-10-4).
|
| 6 |
+
ICL has attracted growing interest, with numerous empirical studies examining when transformers succeed or fail at in-context generalization [\(Xie et al., 2021;](#page-12-0) [Garg et al., 2022;](#page-10-5) [Von Oswald et al.,](#page-11-3) [2023;](#page-11-3) [Wu et al., 2023;](#page-12-1) [Li et al., 2024b;](#page-10-6) [Agarwal et al., 2024;](#page-9-1) [Park et al., 2025\)](#page-11-4). Notably, [Garg et al.](#page-10-5) [\(2022\)](#page-10-5) provided preliminary theoretical evidence that transformers trained on specific function classes (e.g., linear) can accurately infer a query function value from prompts containing variable–function pairs, highlighting transformers' surprising ability to "learn" within their forward pass and mimic classical function approximation.
|
| 7 |
+
Building on this foundation, subsequent works have provided *theoretical* understandings of ICL by characterizing the training dynamics of single-layer attention transformers [\(Mahankali et al., 2023;](#page-11-5) [Zhang et al., 2024;](#page-12-2) [Huang et al., 2024;](#page-10-7) [Collins et al., 2024;](#page-10-8) [Yang et al., 2024\)](#page-12-3). For instance, [Huang](#page-10-7) [et al.](#page-10-7) [\(2024\)](#page-10-7) consider softmax attention to analyze how attention weights evolve during training linear regression problems. More recent studies have theoretically shown that transformers can learn specific nonlinear function classes in-context, such as binary classification, low-degree polynomial regression, and Gaussian single-index models [\(Li et al., 2024a;](#page-10-9) [Yang et al., 2024;](#page-12-3) [Oko et al., 2024;](#page-11-6) [Sun](#page-11-7) [et al., 2025\)](#page-11-7). However, these studies do not provide a full theoretical picture of how the step-by-step learning process is governed by the task itself. To date, a formal characterization of the pre-training dynamics for general nonlinear ICL has been a key open problem.
|
| 8 |
+
{1}------------------------------------------------
|
| 9 |
+
In this work, we take a step toward understanding the *learning dynamics* for ICL on a broad class of nonlinear regression functions. We address two fundamental questions: (1) Which geometric properties of the target function govern the convergence behavior of transformer-based ICL? and (2) Despite nonlinearity and generality, how can a transformer learn in context to achieve low prediction error? We answer both by analyzing transformer training under gradient descent. Our main contributions are summarized below.
|
| 10 |
+
- Broad Class of Nonlinear Functions and Flexible Feature Sets: Our analysis generalizes previous studies in two ways. (i) Unlike prior theoretical works that focus on linear mappings (Zhang et al., 2024; Huang et al., 2024), binary classification (Li et al., 2024a), or low-degree polynomials (Sun et al., 2025), we characterize learning dynamics for a much broader family of non-degenerate L-Lipschitz task functions without assuming low complexity. This class is satisfied by almost any nontrivial L-Lipschitz function (e.g., scaled cosine, piecewise-polynomial, and small neural-network functions) and excludes only degenerate cases. (ii) Our results also hold for general feature embeddings without the restrictive orthonormality assumptions in prior work (Huang et al., 2024; Li et al., 2024a; Chen et al., 2024; Nichani et al., 2024).
|
| 11 |
+
- Phase Transition of Training Dynamics between Flat and Sharp Curvature Regimes: We discover a phase transition in training dynamics governed by the Lipschitz constant L. When L is below a threshold of order $\Theta\left(\frac{1}{\Delta\delta}\right)$ , the **flat curvature regime** yields smaller gradients and permits larger step sizes to converge. When L exceeds the threshold, the **sharp-curvature regime** produces larger gradients requiring smaller steps. The two regimes exhibit distinct convergence behaviors: although the flat regime may converge faster at high accuracy, sufficiently large L enhances feature separability, enabling accelerated training in the sharp regime.
|
| 12 |
+
- Convergence Guarantee for ICL with Nonlinear Regression Functions: We provide formal convergence guarantees for a one-layer softmax attention model learning nonlinear regression functions. We prove that gradient descent achieves near-zero training loss in polynomial time across both flat and sharp L-regimes. We also characterize the two-phase training dynamics: an early phase in which attention scores between query tokens and target features rise rapidly, and a later phase in which these scores converge to one while attention to irrelevant features decays more slowly with oscillations. At convergence, query tokens consistently attend to highly relevant prompt tokens, demonstrating the ICL capability of transformers.
|
| 13 |
+
- Novel Analysis Techniques: We develop new proof tools that explicitly connect the curvature of nonlinear task functions to the evolution of attention weights. In particular, we first decompose the prediction loss to explicitly relate it to attention weights and cross-feature gaps under nonlinear functions. We further show that the flat and sharp curvature regimes of the parameter L lead to distinct gradient magnitudes, which in turn drive different convergence rates and shape the overall training dynamics. The impact of function curvature on the magnitude and stability of attention updates is, to our knowledge, not addressed in previous ICL literature (Huang et al., 2024; Oko et al., 2024; Cheng et al., 2024).
|
| 14 |
+
# 2 RELATED WORKS
|
| 15 |
+
**In-context learning.** In-context learning (ICL) has emerged as a fundamental capability of transformer models, enabling dynamic task adaptation without parameter updates. The research community has approached ICL from several distinct yet complementary perspectives.
|
| 16 |
+
The Bayesian inference perspective, pioneered by Xie et al. (2021) and further developed by Zhang et al. (2023); Wang et al. (2023); Falck et al. (2024), establishes a theoretical framework linking prompting strategies to probabilistic reasoning. This line of work interprets ICL as a form of implicit Bayesian model averaging, where transformers effectively perform approximated inference conditioned on the provided context. Another line of ICL work focuses on Markov chains to study the behavior of induction heads for transformers, which are designed to copy or compare tokens that follow previous occurrences (Nichani et al., 2024; Bietti et al., 2023; Edelman et al., 2024; Rajaraman et al., 2024). The central focus is to understand how transformers recover latent sequence structures (Nichani et al., 2024) and transition rules (Ren & Liu, 2024; Li et al., 2023; Makkuva et al., 2024), using token-level recurrence and dynamics.
|
| 17 |
+
{2}------------------------------------------------
|
| 18 |
+
In contrast, the function learning perspective initiated by Garg et al. (2022) demonstrated transformers' remarkable ability to learn and interpolate simple function classes (particularly linear models) directly from context examples. This work sparked significant interest in understanding the mechanistic underpinnings of ICL, leading to important discoveries by Von Oswald et al. (2023) and Dai et al. (2022), who revealed deep connections between attention mechanisms and gradient-based optimization dynamics. Recent advances have substantially expanded our understanding of ICL mechanisms: Akyürek et al. (2023) provided a rigorous analysis of linear regression tasks, showing that trained transformers can implement both ridge regression gradient descent and exact least-squares solutions. Bai et al. (2023) established comprehensive theoretical results encompassing expressive power, prediction capabilities, and sample complexity, while proposing general mechanisms for algorithmic selection. Cheng et al. (2024) interprets transformers as implementing functional gradient descent for nonlinear regression, but their analysis primarily focuses on the representational capacity and functional viewpoint of the learned predictor, without analyzing the ICL pre-training dynamics.
|
| 19 |
+
Theoretical analysis of ICL learning dynamics. Recent theoretical work has made significant progress in understanding the pre-training dynamics of ICL in transformers, though important limitations remain (Huang et al., 2024; Li et al., 2024a; Collins et al., 2024; Yang et al., 2024; Sun et al., 2025; Lu et al., 2024; Edelman et al., 2024; Lin & Lee, 2024; Jeon et al., 2024; Park et al., 2025). The foundational work by Huang et al. (2024) established the first rigorous analysis of training dynamics for softmax attention in ICL settings, focusing on a single-head attention layer learning linear regression tasks. Their key theoretical result demonstrates that prompt tokens with features identical to the query token develop dominating attention weights during training. However, this analysis relies critically on strong assumptions about pairwise orthonormality of feature vectors and a normalized function scale, limiting its applicability to more general settings. Our work goes beyond this setting by showing that, for general nonlinear targets, the Lipschitz constant of the underlying function governs both the gradient evolution and the resulting convergence regimes. In this sense, our analysis includes the linear case as a special instance while providing a more fine-grained understanding of how function curvature influences attention-based learning.
|
| 20 |
+
Subsequent work extended these results to classification tasks (Li et al., 2024a), dual-head settings (Lin & Lee, 2024), and structured or hierarchical functions (Yang et al., 2024; Sun et al., 2025). Some studies explored the implicit bias of gradient descent and attention-based generalization (Collins et al., 2024; Lu et al., 2024), while others examined information-theoretic and dynamical aspects of ICL (Edelman et al., 2024; Jeon et al., 2024). Despite these advances, most analyses still rely on restrictive assumptions, such as orthonormality features, fixed positional encoding, or carefully structured input distributions, limiting their ability to explain ICL under general tasks and practical learning conditions.
|
| 21 |
+
**Notations.** In this paper, for a vector $\boldsymbol{v}$ , we let $\|\boldsymbol{v}\|_2$ denote its $\ell$ -2 norm. For some positive constant $C_1$ and $C_2$ , we define $x = \Omega(y)$ if $x > C_2|y|$ , $x = \Theta(y)$ if $C_1|y| < x < C_2|y|$ , and $x = \mathcal{O}(y)$ if $x < c_1|y|$ . We also denote by x = o(y) if $x/y \to 0$ . We use $\operatorname{poly}(C)$ to denote large constant degree polynomials of C. For a matrix A, we use $A_i$ to denote the i-th column of A, and $A_{i:j}$ to represent the collection of columns from the i-th to the j-th column (inclusive).
|
| 22 |
+
# <span id="page-2-1"></span>3 System Model
|
| 23 |
+
In this section, we formulate our system model, including the problem setup for in-context learning, the transformer architecture, and the associated training process.
|
| 24 |
+
## <span id="page-2-0"></span>3.1 IN-CONTEXT LEARNING PROBLEM SETUP
|
| 25 |
+
We consider a standard in-context learning (ICL) framework commonly used in prior studies (Garg et al., 2022; Huang et al., 2024; Yang et al., 2024). The objective is to train a transformer model that can perform ICL over a designated class of functions $\mathcal{F}$ , where each function $f \in \mathcal{F}$ corresponds to one task context. Here, we focus on *nonlinear* function classes further elaborated below.
|
| 26 |
+
Given each task (i.e., given one function f randomly sampled from $\mathcal{F}$ ), a prompt with a sequence of N input-response pairs $(x_i, y_i)$ as well as a query input $x_{\text{query}}$ are sampled, where $x_i \in \mathcal{X} \subseteq \mathbb{R}^d$ , and $y_i = f(x_i)$ . Let the input matrix $X = (x_1 \ x_2 \ \cdots \ x_N) \in \mathbb{R}^{d \times N}$ and the response vector $\mathbf{y} = (y_1 \ y_2 \ \cdots \ y_N) \in \mathbb{R}^{1 \times N}$ . We adopt the following standard prompt embedding (Garg et al.,
|
| 27 |
+
{3}------------------------------------------------
|
| 28 |
+
2022: Huang et al., 2024: Yang et al., 2024):
|
| 29 |
+
<span id="page-3-1"></span><span id="page-3-0"></span>
|
| 30 |
+
$$P = \begin{pmatrix} x_1 & x_2 & \cdots & x_N & x_{\text{query}} \\ y_1 & y_2 & \cdots & y_N & 0 \end{pmatrix} = \begin{pmatrix} X & x_{\text{query}} \\ \mathbf{y} & 0 \end{pmatrix} \in \mathbb{R}^{(d+1)\times(N+1)}. \tag{1}$$
|
| 31 |
+
**Non-degenerate** *L***-Lipschitz Regression Functions.** In this work, we focus on regression tasks, where each task is associated with a regression function drawn from the following set
|
| 32 |
+
$$\mathcal{F} = \left\{ f: \begin{array}{l} |f(x) - f(x')| \leq L ||x - x'||, & \forall ||x - x'|| = \Theta(\delta_0), \\ \forall v_k \in \mathbb{V}, \exists v_{k'} \in \mathbb{V}, \ k' \neq k, \ \text{such that} \ |f(v_k) - f(v_{k'})| = \Theta(L) \cdot ||v_k - v_{k'}|| \end{array} \right\},$$
|
| 33 |
+
$$(2)$$
|
| 34 |
+
where L>0 and $\delta_0=\mathcal{O}(1)$ . In particular, the functions in the class are said to satisfy **non-degenerate** L-**Lipschitz** condition, which imposes two natural requirements on the function class. First, the standard global L-Lipschitz condition ensures that the function f does not change too rapidly, which is common in the literature and includes a wide class of linear and nonlinear functions. Second, the separation requirement guarantees that for any feature $v_k$ in the set $\mathbb{V}$ , there exists at least one other feature $v_{k'}$ such that the function difference between them achieves the order of variation defined by the Lipschitz constant. This ensures sufficient distinguishability of features by the function class for guaranteed learnability. This mild separation assumption is satisfied by almost any nontrivial L-Lipschitz function (e.g., scaled cosine, piecewise-polynomial, and small neural-network functions) and excludes only degenerate cases. Together, these two conditions ensure that the function class is sufficiently rich for ICL while avoiding unlearnable or trivial scenarios.
|
| 35 |
+
For each prompt P, the task-specific function f(x) is independently drawn based on a task distribution $\mathcal{D}_f$ , as long as f(x) satisfies the property for the same L and $\delta_0$ in Eq. (2).
|
| 36 |
+
Feature Embeddings. Let $\mathbb{V}:=\{v_k\in\mathbb{R}^d|k=1,\cdots,K\}$ be the feature embeddings of tokens. For any $k\neq k'$ , we assume a separation of $\|v_k-v_{k'}\|=\Theta(\Delta)$ , where $\Delta=\Theta(1)$ . Each data sample x is modeled as a noisy perturbation of one of the vectors in $\mathbb{V}$ . This assumption lets us control the separation $\Delta$ precisely, simplifying the analysis while retaining the essential geometry of the problem. Such a condition can be satisfied by various feature learning techniques to avoid feature collapse, e.g., disentangled representation learning (Wang et al., 2022; 2024; Higgins et al., 2018). We note that such a condition substantially generalizes the orthonormality assumption taken by the previous study (Huang et al., 2024; Li et al., 2024a; Chen et al., 2024; Nichani et al., 2024). The prompt is sampled as follows. For a randomly chosen $v_k$ , we assume x satisfies $\|x-v_k\|=O(\epsilon_x)$ with probability $p_k$ , where $\epsilon_x=o(1)$ and $p_k=\Theta(\frac{1}{K})$ . For analytical simplicity, we assume $x=v_k$ whenever this proximity condition holds. In our experiments in Section 6, we further verify that our training dynamic analysis remains valid when tokens are drawn from general continuous distributions.
|
| 37 |
+
# 3.2 One-Layer Transformer
|
| 38 |
+
In this work, we adopt a one-layer transformer model for solving the ICL problem, which is commonly used in the existing theoretical ICL literature (e.g., Huang et al. (2024); Li et al. (2024a); Yang et al. (2024); Sun et al. (2025)). A self-attention transformer with width $d_e$ consists of a key matrix $W^K \in \mathbb{R}^{d_e \times d_e}$ , a query matrix $W^Q \in \mathbb{R}^{d_e \times d_e}$ , and a value matrix $W^V \in \mathbb{R}^{d_e \times d_e}$ . For a given prompt P of length N in Eq. (1), the self-attention layer outputs:
|
| 39 |
+
$$F(P; W^K, W^Q, W^V) = W^V P \times \operatorname{softmax} \left( (W^K P)^\top W^Q P \right). \tag{3}$$
|
| 40 |
+
where the softmax(·) function is applied column-wisely, i.e., for a vector input z, the i-th entry of softmax(z) is given by softmax( $z_i$ ) = $\frac{\exp(z_i)}{\sum_i \exp(z_j)}$ .
|
| 41 |
+
We further take the following re-parameterization, commonly adopted by the recent theoretical studies of transformers (e.g. Zhang et al. (2024); Huang et al. (2024); Yang et al. (2024); Sun et al. (2025)), which combines the query and key matrices into a single matrix $W^{KQ} \in \mathbb{R}^{(d+1)\times (d+1)}$ , and further specify the weight matrices as follows:
|
| 42 |
+
$$W^V = \begin{pmatrix} 0_{d \times d} & 0_d \\ 0_d^\top & 1 \end{pmatrix}, \quad W^{KQ} = \begin{pmatrix} Q & 0_d \\ 0_d^\top & 0 \end{pmatrix},$$
|
| 43 |
+
where $Q \in \mathbb{R}^{d \times d}$ is the trainable weight matrix. These simplifications, while not capturing the full complexity of deep, multi-head models, are standard in the theoretical literature and serve two crucial purposes. First, they allow for a tractable analysis that isolates the core dynamics of the softmax
|
| 44 |
+
{4}------------------------------------------------
|
| 45 |
+
<span id="page-4-0"></span>
|
| 46 |
+
$$F(P;Q) = \mathbf{y} \cdot \operatorname{softmax}(X^{\top} Q \bar{X}), \tag{4}$$
|
| 47 |
+
where we further let $\bar{X}=(x_1 \quad x_2 \quad \cdots \quad x_N \quad x_{\text{query}}) \in \mathbb{R}^{d \times N+1}$ and $\mathbf{y}=(y_1 \quad y_2 \quad \cdots \quad y_N) \in \mathbb{R}^{d \times N+1}$ $\mathbb{R}^{d \times N}$ . The prediction $\hat{y}_{\text{query}}$ corresponding to $x_{\text{query}}$ is given by the last entry of $F(P;Q)_{N+1}$ , i.e., $\hat{y}_{\text{query}} = F(P;Q)_{N+1}$ . To train the attention model on the ICL problem introduced in Section 3.1, we minimize the following squared loss between the predicted and true responses:
|
| 48 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \mathbb{E} \left[ \left( F(P;Q)_{N+1} - f(x_{\text{query}}) \right)^2 \right], \tag{5}$$
|
| 49 |
+
$\mathcal{L}(P;Q) = \frac{1}{2}\mathbb{E}\Big[\big(F(P;Q)_{N+1} - f(x_{\text{query}})\big)^2\Big], \tag{5}$ where the expectation is taken over the randomly sampled prompt $\{x_i\}_{i=1}^N \cup \{x_{\text{query}}\}$ and randomly sampled function $f \in \mathcal{F}$ that determines the corresponding ground-truth responses.
|
| 50 |
+
We optimize this loss via gradient descent (GD). Let vec(Q) denote the vector that stacks all entries of Q. At t = 0, we initialize $vec(Q)^{(0)}$ as the zero matrix $0_{d^2}$ . The parameter is updated as follows:
|
| 51 |
+
$$\operatorname{vec}(Q)^{(t+1)} = \operatorname{vec}(Q)^{(t)} - \eta \nabla_{\operatorname{vec}(Q)} \mathcal{L}(P; \operatorname{vec}(Q)^{(t)}). \tag{6}$$
|
| 52 |
+
where $\eta > 0$ is the learning rate. Note that we require $\eta$ to be smaller than a universal constant (e.g., $\eta < 1$ ) to ensure stability of the update and to preserve the convergence behavior analyzed in Section 5. Based on this model setup and training procedure, we proceed to present our main theoretical results concerning ICL under nonlinear regression tasks.
|
| 53 |
+
# MAIN RESULTS OF ICL CONVERGENCE
|
| 54 |
+
Our analysis proceeds by decomposing the loss function into interpretable quantities that directly reflect cluster separation and the Lipschitz constant L in Eq. (2). Interestingly, we observe that the flat and sharp regimes of L give rise to distinct convergence dynamics, with a threshold transition separating the two regimes based on the order of magnitude of L. In the flat regime (small L), the gradient on Q matrices remains small, leading to slow but steady concentration of attention weights. In the sharp regime (large L), we show a rapid growth phase where the query-key inner products amplify differences between clusters before settling into a slow fine-tuning phase. For the two regimes, we provide explicit convergence-time bounds and characterize the phase transition. Compared with prior analyses restricted to linear tasks or orthogonal features, our framework extends to general nonlinear Lipschitz tasks and explains qualitatively different dynamics observed in practice.
|
| 55 |
+
Recall from Section 3.1 that each token $x_i$ corresponds to a noisy version of a feature $v_k \in \mathbb{V}$ with probability $p_k = \Theta\left(\frac{1}{K}\right)$ for any $k \in [K]$ . Let $P_{1:N}$ denote the collection of input tokens in P, i.e., $\{x_i\}_{i=1}^N$ , and denote $\mathcal{V}_k \subset [N]$ as the index set for input tokens, such that $x_i = v_k$ for $i \in \mathcal{V}_k$ . We define the following concentration set of token sequences where each feature appears with approximately the expected frequency:
|
| 56 |
+
<span id="page-4-1"></span>
|
| 57 |
+
$$\mathcal{E}^* := \left\{ P_{1:N} : |\mathcal{V}_k| \in \left[ (p_k - \delta)N, (p_k + \delta)N \right] \text{ for } k \in [K] \right\}, \tag{7}$$
|
| 58 |
+
where $\delta \geq \sqrt{\frac{20K}{N}}$ . Then, for any $0 < \epsilon < 1$ , suppose $N \geq \Theta(K^3)$ and $K \geq \Theta(\frac{1}{\epsilon})$ . For any $t \in [T]$ , we have the concentration probability satisfies $\mathbb{P}(P_{1:N} \in \mathcal{E}^*) \ge 1 - 3 \exp\left(-\frac{\delta^2 N}{25}\right)$ . This implies that, with high probability, each feature class $k \in [K]$ is approximately equally represented in the prompt P, ensuring a balanced token distribution. Such balance is crucial for the convergence of ICL, as it allows the attention to learn effectively from all feature types without introducing bias. While our analysis is expressed in terms of the population risk in Eq. (5), the concentration event in Eq. (7) ensures that the empirical prompt distribution closely matches the population distribution when N is sufficiently large. Under this event, the curvature-driven attention dynamics characterized later in our theory remain accurate up to standard $\mathcal{O}(1/\sqrt{N})$ fluctuations. Thus, the population-level analysis offers a faithful description of the finite-sample training behavior for prompts of moderate size.
|
| 59 |
+
{5}------------------------------------------------
|
| 60 |
+
Given balanced feature inputs, we now quantify how much the query token $x_{query}$ attends to specific input tokens or feature classes. We define the attention score for a query token to attend to the i-th token in the prompt as $\operatorname{attn}_i^{(t)} := \operatorname{softmax}(x_i^\top Q^{(t)} x_{\operatorname{query}})$ and the total attention paid to all tokens with feature $v_k$ as $\operatorname{Attn}_k^{(t)} := \sum_{i:x_i=v_k} \operatorname{attn}_i^{(t)}$ . With this notation, the transformer's output at t is
|
| 61 |
+
<span id="page-5-4"></span><span id="page-5-0"></span>
|
| 62 |
+
$$\hat{y}_{\text{query}} = \sum_{i \in [N]} \operatorname{attn}_{i}^{(t)} y_{i} = \sum_{k \in [K]} \operatorname{Attn}_{k}^{(t)} f(v_{k}). \tag{8}$$
|
| 63 |
+
Building on the expression in Eq. (8), we characterize how the attention scores influence the prediction loss defined in Eq. (5) in the following lemma.
|
| 64 |
+
<span id="page-5-1"></span>**Lemma 1.** Given constants $L, \Delta > 0$ , the prediction loss in Eq. (5) can be expressed as:
|
| 65 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( 1 - \operatorname{Attn}_{k}^{(t)} \right)^2 \cdot \mathcal{O}(L^2 \Delta^2) \right], \ \forall t \in [T],$$
|
| 66 |
+
(9) where $\mathbb{1} \{ x_{\text{query}} = v_k \} = 1$ is the indicator function that equals 1 if $x_{\text{query}} = v_k$ and 0 otherwise.
|
| 67 |
+
The proof of Lemma 1 is given in Appendix C. This expression reveals that loss $\mathcal{L}(P;Q)$ depends on the Lipschitz constant L, the feature gap $\Delta$ , and the attention score $\operatorname{Attn}_k^{(t)}$ associated with the true feature of the query token. The dependence on L, which captures the function's curvature, distinguishes our analysis from prior theoretical work on ICL (e.g., Huang et al. (2024); Oko et al. (2024); Sun et al. (2025)). For a given feature gap $\Delta$ , different function Lipschitz constants L can lead to distinct convergence behaviors of ICL. In the following theorem, we first provide the $\epsilon^2$ -convergence of $\mathcal{L}(P;Q)$ in the flat L-regime, where L is below a certain threshold.
|
| 68 |
+
<span id="page-5-2"></span>**Theorem 1** (Flat L-regime). Suppose the function class in Eq. (2) satisfies $L \leq \Theta\left(\frac{1}{\Delta\delta}\right)$ . Then, for any $0 < \epsilon < 1$ and under $N \geq \Theta(K^3)$ and $K \geq \Theta(\frac{1}{\epsilon})$ , with at most $T_f^* = \Theta(\frac{K \log(K\epsilon^{-1})}{\eta \delta^2 L^2 \Delta^2})$ iterations, we have $\mathcal{L}(P;Q) \leq \mathcal{O}(\epsilon^2)$ .
|
| 69 |
+
The proof of Theorem 1 is given in Appendix E.3. Theorem 1 indicates that $T_f^*$ decreases (i.e., the convergence is faster) as either the Lipschitz constant L or the feature gap $\Delta$ increases. Intuitively, a larger function Lipschitz constant L implies that the outputs $y_i$ and $y_{i'}$ corresponding to different features in the prompt P become more distinguishable, which facilitates faster in-context learning. Similarly, a larger feature gap $\Delta$ improves the separability among features, enabling the query token to more accurately attend to the relevant prompt tokens.
|
| 70 |
+
However, when L exceeds a certain threshold, the caused sharp curvature induces large gradients on the attention weights. As a result, a smaller stepsize is required to stabilize convergence, leading to a convergence rate that differs from that in the flat regime. We next establish the $\epsilon^2$ -convergence of $\mathcal{L}(P;Q)$ in the sharp L regime, where L is above the threshold.
|
| 71 |
+
<span id="page-5-3"></span>**Theorem 2** (Sharp L-regime). Suppose the function class in Eq. (2) satisfies $L = \Omega(\frac{1}{\Delta\delta})$ . Then for any $0 < \epsilon < 1$ , under $N = \Omega(K^3)$ and $K \ge \Theta(\frac{1}{\epsilon})$ , with at most $T_s^* = \Theta(\frac{K \log(K\epsilon^{-1}L\Delta)}{n\epsilon\delta^2L^2\Delta^2})$ iterations, we have $\mathcal{L}(P;Q) = \mathcal{O}(\epsilon^2)$
|
| 72 |
+
The proof of Theorem 2 is given in Appendix F.2. Theorem 1 and Theorem 2 together reveal an interesting **phase transition phenomenon**: the convergence dynamics are governed by how the function Lipschitz constant L compares to a threshold of order $\Theta\left(\frac{1}{\Delta\delta}\right)$ . In the **flat curvature regime**, where L is below this threshold, convergence allows larger step sizes due to smaller gradients, resulting in a convergence rate of $\tilde{\Theta}\left(\frac{K}{\eta\delta^2L^2\Delta^2}\right)$ . In contrast, in the **sharp curvature regime**, where L is above the threshold, the large L incurs large gradients which thus require smaller step sizes to stabilize convergence, yielding a convergence rate of $\tilde{\Theta}\left(\frac{K}{\eta\epsilon\delta^2L^2\Delta^2}\right)$ . Comparing the two convergence upper bounds, neither $T_f^*$ nor $T_s^*$ always dominates. The sharp regime benefits from a larger L, giving a smaller denominator and faster convergence, but its bound also contains an extra $\frac{1}{\epsilon}$ factor that can dominate when high accuracy is required. Therefore, depending on the relative scales of $L, \epsilon$ , and $\Delta$ , either regime may achieve the smaller convergence upper bound.
|
| 73 |
+
In cases where the query is not a small perturbation of any feature vector, the model must represent the query using a combination of multiple feature clusters rather than relying on a single dominant one. This setting is more challenging because the nonlinear function values evolve over training, causing the optimal attention pattern to shift across clusters. Nevertheless, the curvature-dependent
|
| 74 |
+
{6}------------------------------------------------
|
| 75 |
+
gradient behavior established in our analysis continues to govern the convergence rate, even though the precise attention trajectory becomes harder to characterize.
|
| 76 |
+
Based on the convergence results above, we now characterize the behavior of the attention score $Attn_k^{(t)}$ at convergence to explain why the ICL output corresponds to an accurate prediction.
|
| 77 |
+
<span id="page-6-1"></span>**Proposition 1.** After the prediction loss converges to $\mathcal{L}(P;Q) = \mathcal{O}(\epsilon^2)$ for any $0 < \epsilon < 1$ , if the query token satisfies $x_{\text{query}} = v_k$ , then the attention score associated with feature $v_k$ satisfies $1 - \operatorname{Attn}_{k}^{(t)} = \mathcal{O}(\epsilon).$
|
| 78 |
+
The proof of Proposition 1 is given in Appendix G. This result follows directly from the loss expression in Eq. (9), where $\mathcal{L}(P;Q) = \Theta((1-\operatorname{Attn}_k^{(t)})^2)$ when $x_{\text{query}} = v_k$ . Intuitively, as $Attn_k^{(t)}$ approaches 1, the attention matrix effectively focuses predominantly on the tokens that share the same feature $v_k$ . As a result, the predicted output $\hat{y}_{query}$ , given by Eq. (8), closely approximates the true value $f(v_k)$ , leading to high-accuracy predictions.
|
| 79 |
+
# <span id="page-6-0"></span>ANALYSIS OF CONVERGENCE DYNAMICS
|
| 80 |
+
As established in Theorem 1 and Theorem 2, different regimes of the Lipschitz constant L lead to distinct convergence behaviors in ICL. In this section, we analyze the training dynamics under both regimes, highlighting how the Lipschitz constant L influences the convergence rate in each case.
|
| 81 |
+
#### **GRADIENTS OF ATTENTION WEIGHTS**
|
| 82 |
+
Based on the prediction output $\hat{y}_{\text{query}}$ in Eq. (5), the attention scores $\text{attn}_i$ play a critical role in determining the final prediction. To precisely characterize these attention scores for any $i \in [N]$ , it is sufficient to characterize the training dynamics of the attention weights $q_{k,k'}^{(t)} := v_{k'}^{\top} Q^{(t)} v_k$ for $k, k' \in [K]$ , which are initialized as $q_{k,k'}^{(0)} = 0$ for any $k, k' \in [K]$ . To simplify notations, we denote the $q_{k,k}^{(t)}$ as $q_k^{(t)}$ for k'=k. According to the definition of the attention score $\operatorname{attn}_i^{(t)}$ in Eq. (8), when $x_{\text{query}}^{(t)} = v_k$ , the quantity $q_k^{(t)}$ measures how strongly the query token attends to the target feature $v_k$ , while $q_{k k'}^{(t)}$ reflects the attention given to a different feature $v_{k'}$ with $k' \neq k$ . To achieve the desired attention behavior, effective training should increase $q_k^{(t)}$ while suppressing $q_{k,k'}^{(t)}$
|
| 83 |
+
The convergence behavior of the transformer depends on the dynamics of $q_k^{(t)}$ and $q_{k,k'}^{(t)}$ . We therefore proceed to analyze how these quantities evolve during training. To this end, we define the gradient updates for $q_k^{(t)}$ and $q_{k,k'}^{(t)}$ as $g_k^{(t)}$ and $g_{k,k'}^{(t)}$ , respectively. Under gradient descent with learning rate $\eta$ , the update rules are given by:
|
| 84 |
+
<span id="page-6-4"></span><span id="page-6-3"></span>
|
| 85 |
+
$$q_k^{(t+1)} := q_k^{(t)} + \eta g_k^{(t)}, \qquad q_{k k'}^{(t+1)} := q_{k k'}^{(t)} + \eta g_{k k'}^{(t)}.$$
|
| 86 |
+
$q_k^{(t+1)} := q_k^{(t)} + \eta g_k^{(t)}, \qquad q_{k,k'}^{(t+1)} := q_{k,k'}^{(t)} + \eta g_{k,k'}^{(t)}.$ We now present the following lemma, which provides the exact expressions for the gradient terms $g_k^{(t)}$ and $g_{k,k'}^{(t)}$ for a function class ${\mathcal F}$ with Lipschitz constant L.
|
| 87 |
+
<span id="page-6-2"></span>**Lemma 2.** For any $t \in [T]$ , suppose $x_{query} = v_k$ . Then for any $k, k' \in [K]$ with $k' \neq k$ , we obtain
|
| 88 |
+
$$g_k^{(t)} = \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} \operatorname{Attn}_k^{(t)} \left(1 - \operatorname{Attn}_k^{(t)}\right)^2 \cdot \Theta(L^2 \Delta^2)\right],\tag{10}$$
|
| 89 |
+
$$|g_{k,k'}^{(t)}| = \mathbb{E}\left[\mathbb{1}\{x_{\text{query}}^{(t)} = v_k\} \text{Attn}_{k'}^{(t)} \cdot (1 - \text{Attn}_{k}^{(t)}) \cdot (1 - \text{Attn}_{k'}^{(t)}) \cdot \Theta(L^2 \Delta^2)\right]. \tag{11}$$
|
| 90 |
+
The proof of Lemma 2 is given in Appendix D. From Eq. (10), we observe that $g_k^{(t)}$ is always non-negative, implying that the update $q_k^{(t)}$ increases over time. This growth continues until the attention score $Attn_k^{(t)}$ approaches its convergence state near 1. However, $g_{k,k'}^{(t)}$ in Eq. (11) is not necessarily positive and also depends on $Attn_{k'}^{(t)}$ associated with feature vector $v_{k'}$ . However, as $Attn_k^{(t)}$ approaches 1, the residual term in Eq. (11) diminishes, and $g_{k,k'}^{(t)}$ also converges toward zero, facilitating the overall convergence of the system.
|
| 91 |
+
{7}------------------------------------------------
|
| 92 |
+
As also shown in Lemma 2, both gradients scale with the Lipschitz constant L and the feature gap $\Delta$ , illustrating their influence on the training dynamics. In the following subsections, we analyze how different regimes of the function Lipschitz constant L (with respect to the threshold determined by $\Delta$ ) affect the evolution of $q_k^{(t)}$ and $q_{k,k'}^{(t)}$ , through the gradients $g_k^{(t)}$ and $g_{k,k'}^{(t)}$ , thereby offering deeper insight into the convergence results established in Theorem 1 and Theorem 2.
|
| 93 |
+
#### 5.2 Convergence Dynamics under Flat L-Regime
|
| 94 |
+
For ease of exposition, we consider the case where $x_{\mathrm{query}} = v_k$ in the following. Under the initialization of $q_k^{(0)} = q_{k,k'}^{(0)} = 0$ , and by the definition of the attention score, we have $\mathrm{attn}_n^{(0)} = \frac{1}{N}$ for all $n \in [N]$ , meaning that the transformer initially attends equally to all input tokens when computing the prediction for $x_{\mathrm{query}}$ . We then leverage the task distribution in Eq. (2) and the gradient expressions in Lemma 2 to analyze the learning dynamics of $q_k^{(t)}$ and $q_{k,k'}^{(t)}$ .
|
| 95 |
+
In the initial phase of training, the prediction $\hat{y}_{\text{query}}$ is far from the ground truth $f(v_k)$ due to the zero initialization of bilinear weights. According to Eq. (10), this results in a large positive gradient $g_k^{(t)}$ , leading to a rapid increase in $q_k^{(t)}$ . In contrast, the gradient $g_{k,k'}^{(t)}$ may fluctuate in sign depending on the alignment of $f(v_k)$ and $f(v_{k'})$ at each step, causing $q_{k,k'}^{(t)}$ to oscillate but decrease much more slowly. We formally characterize this phase below.
|
| 96 |
+
<span id="page-7-0"></span>**Proposition 2** (Phase I: Fast growth of $q_k^{(t)}$ ). For any $t \in \{1, \cdots, T_f^1\}$ and $k \in [K]$ , where $T_f^1 = \Theta(\frac{K \log(K)}{\eta L^2 \Delta^2})$ , the attention weight $q_k^{(t)}$ increases at a rate of $\Theta(\frac{\eta L^2 \Delta^2}{K})$ . Meanwhile, $q_{k,k'}^{(t)}$ oscillates at a slower rate of $O(\frac{\eta L^2 \Delta^2}{K^2})$ and exhibits an overall decreasing trend. By the end of Phase I (i.e., $t = T_f^1 + 1$ ), we have $\operatorname{Attn}_k^{(T_f^1 + 1)} = \Omega(\frac{1}{1 + \delta})$ .
|
| 97 |
+
The proof of Proposition 2 is given in Appendix E.1. According to Proposition 2, Phase I ends once $q_k^{(t)}$ becomes sufficiently large to reduce the prediction gap between the ICL output and the ground truth function value. After this point, both $g_k^{(t)}$ in Eq. (10) and $|g_{k,k'}^{(t)}|$ in Eq. (11) decrease to smaller orders. During this phase, both $g_k^{(t)}$ and $|g_{k,k'}^{(t)}|$ increase with L, as a larger function Lipschitz constant induces greater residual values in Eq. (10) and Eq. (11). Likewise, a larger feature gap $\Delta$ amplifies the value difference between $f(v_k)$ and $f(v_{k'})$ (by Eq. (2)), which in turn accelerates attention learning in Phase I. As a result, the duration $T_f^1$ decreases with both L and $\Delta$ .
|
| 98 |
+
However, at $t=T_f^1$ , the prediction loss in Eq. (5) may still remain non-negligible. As a result, the attention score $\operatorname{Attn}_k^{(t)}$ requires a period of steady improvement after $t=T_f^1+1$ . We now formalize this behavior in the second training phase in the following proposition.
|
| 99 |
+
<span id="page-7-1"></span>**Proposition 3** (Phase II: Steady growth of $q_k^{(t)}$ under flat L-regime). For any $t \in \{T_f^1+1,\cdots,T_f^*\}$ and $0 < \epsilon < 1$ , where $T_f^* = \Theta(\frac{K \log(K\epsilon^{-1})}{\eta \delta^2 L^2 \Delta^2})$ , for any $k \in [K]$ , $q_k^{(t)}$ continues to grow at a steady rate of $\Theta\left(\frac{\eta \delta^2 L^2 \Delta^2}{K}\right)$ . Meanwhile, $q_{k,k'}^{(t)}$ oscillates at a slower rate of $O\left(\frac{\eta \delta^2 L^2 \Delta^2}{K^2}\right)$ and exhibits an overall decreasing trend. At $t = T_f^* + 1$ , if L satisfies $L \leq \Theta(\frac{1}{\Delta \delta})$ in Eq. (2), we have $\operatorname{Attn}_k^{(T_f^*+1)} = \Omega(\frac{1}{1+\epsilon\delta})$ .
|
| 100 |
+
The proof of Proposition 3 is given in Appendix E.2. According to Proposition 3, if the Lipschitz constant is sufficiently small such that $L \leq \Theta(\frac{1}{\Delta\delta})$ , then by the end of Phase II, the attention score satisfies $1 - \operatorname{Attn}_k^{(T_f^*+1)} = \mathcal{O}\left(\frac{\epsilon\delta}{1+\epsilon\delta}\right) = \mathcal{O}(\epsilon)$ , indicating that the transformer has converged.
|
| 101 |
+
### 5.3 Phase Transition under Sharp L-Regime
|
| 102 |
+
In the sharp curvature regime where $L=\Omega(\frac{1}{\Delta\delta})$ , the update $q_k^{(t)}$ increases at a rate of $\Theta(\frac{\eta}{K})$ for all $t\leq T_f^*$ . Let $T_s^1$ denote the duration of Phase I in this regime. Since this early-stage growth (Phase I) mirrors the dynamics under the flat L-regime before $T_f^*$ , we have $T_s^1=T_f^*=\Theta(\frac{K\log(K\epsilon^{-1})}{\eta\delta^2L^2\Delta^2})$ .
|
| 103 |
+
{8}------------------------------------------------
|
| 104 |
+
<span id="page-8-2"></span>
|
| 105 |
+
<span id="page-8-6"></span><span id="page-8-5"></span><span id="page-8-4"></span><span id="page-8-3"></span>set. L-set. flat <math>L=0.1. sharp L=1.
|
| 106 |
+
Figure 1: Training dynamics of prediction losses (top) and attention scores (bottom) for two sets of L: flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ).
|
| 107 |
+
However, this initial Phase is insufficient for achieving convergence due to the residual error term proportional to $L \cdot \Delta$ in Eq. (9). Consequently, training transitions into a second phase (Phase III), during which both gradient terms $g_k^{(t)}$ and $g_{k,k'}^{(t)}$ become small. This leads to a slower growth rate of $q_k^{(t)}$ compared to the earlier phase. We characterize this slower training phase as follows.
|
| 108 |
+
<span id="page-8-1"></span>**Proposition 4** (Phase III: Slow growth of $q_k^{(t)}$ under sharp L-regime). If $L = \Omega(\frac{1}{\Delta\delta})$ , then for any $t \in \{T_s^1+1,\cdots,T_s^*\}$ and $0 < \epsilon < 1$ , where $T_s^* = \Theta(\frac{K\log(KL\Delta\epsilon^{-1})}{\eta\epsilon\delta^2L^2\Delta^2})$ , for any $k \in [K]$ , $q_k^{(t)}$ increases at a rate of $\Theta(\frac{\eta\delta^2L^2\Delta^2\epsilon}{K})$ . Meanwhile, $q_{k,k'}^{(t)}$ fluctuates at a slower rate of $O(\frac{\eta\delta^2L^2\Delta^2\epsilon}{K^2})$ . By the end of Phase II (i.e. $t = T_s^* + 1$ ), we have $\operatorname{Attn}_k^{(T_s^*+1)} = \Omega(\frac{1}{1+\epsilon\delta})$ .
|
| 109 |
+
The proof of Proposition 4 is given in Appendix F.1. To ensure convergence of the prediction loss, the update step size of $q_k^{(t)}$ decreases to an order dependent on $\epsilon$ in Phase II. This is because, under the sharp L-regime where $\delta^2 L^2 \Delta^2 = \Omega(1)$ , the gradients become large, as established in Lemma 2. This phase transition further supports the convergence guarantee in Theorem 2, demonstrating that even under sharp curvature, the attention mechanism gradually concentrates on the correct feature vector, ultimately enabling accurate prediction.
|
| 110 |
+
# <span id="page-8-0"></span>6 EXPERIMENTS VERIFICATION
|
| 111 |
+
We adopt the data and task distributions from Section 3.1. Each data point is sampled from a fixed feature set $v_k \in \mathbb{R}^d, k=1,\ldots,K$ , with each feature $v_k$ chosen uniformly at random, i.e., $p_k=1/K$ . Each task involves learning a cosine function of the form $f(x) = \frac{L}{c} \cdot \cos(c \cdot x)$ , where c>0 is a random constant and L is the Lipschitz constant, satisfying Eq. (2). Each prompt consists of N randomly sampled inputs $\{x_i\}_{i=1}^N$ and corresponding outputs $\{y_i\}_{i=1}^N = \{f(x_i)\}_{i=1}^N$ , along with a query token $x_{\text{query}}$ . We set the parameters as follows: d=15, K=4, N=100, c=0.5, and $\Delta=3$ . We generate M=300 prompts and train the model for T=400 epochs. Appendix B presents additional experiments, including attention map dynamics, robustness check with non-uniform feature frequencies, polynomial-function tasks, and deeper transformers.
|
| 112 |
+
We analyze a simplified transformer model comprising a single block with one-head self-attention and a feedforward network, incorporating layer normalization and ReLU activation, followed by a linear output layer. Our analysis focuses on two key metrics shown in Figure 1: (1) prediction loss dynamics and (2) attention score evolution, evaluated under flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ) curvature regimes. The prediction loss is computed as the average squared loss over prompts containing query token $v_k$ . For attention scores, we track $v_1$ 's self-attention score $\operatorname{Attn}_1^{(t)}$ and other features' attention scores $\operatorname{Attn}_{k-1}^{(t)}$ ( $k \in \{2, 3, 4\}$ ) on $v_1$ at each epoch.
|
| 113 |
+
For flat L-regime, as shown in Figure 1(a) and Figure 1(c), we observe two distinct training phases. For example, with L=0.1, the prediction loss rapidly decreases to around 1.0 by epoch t=40, driven by increasing attention on the target feature shown in Figure 1(c). Subsequently, it steadily declines to near zero by t=250. At the same time, $\operatorname{Attn}_1^{(t)}$ approaches 1 under the transformer parameter $\theta$ . The convergence time shortens with increasing L due to stronger gradient updates, consistent with Theorem 1, Proposition 1, Proposition 2, and Proposition 3.
|
| 114 |
+
{9}------------------------------------------------
|
| 115 |
+
As depicted in Figure 1(b) and Figure 1(d), the sharp L-regime exhibits different three training phases. Specifically, when L=1, the prediction loss drops rapidly to approximately 0.6 by t=30, then decreases steadily to around 0.1 by t=110. After that, it converges slowly toward 0 by t=200. The dynamics of the attention scores in Figure 1(d) exhibit the same three-phase progression. Additionally, under our experiment setting, the convergence upper bounds $T_f^*$ in Theorem 1 and $T_s^*$ in Theorem 2 satisfy $T_f^* > T_s^*$ , indicating that the sharp regime achieves a faster convergence time. These empirical observations are consistent with our theoretical predictions in Theorem 2 and Proposition 4.
|
| 116 |
+
# <span id="page-9-5"></span>7 CONCLUSIONS AND LIMITATIONS
|
| 117 |
+
<span id="page-9-1"></span>
|
| 118 |
+
<span id="page-9-3"></span>
|
| 119 |
+
<span id="page-9-4"></span>
|
| 120 |
+
<span id="page-9-0"></span>
|
| 121 |
+
<span id="page-9-2"></span>
|
| 122 |
+
We presented provable results showing how transformers can learn a broad family of nonlinear tasks in context, identifying two distinct training regimes governed by task curvature. These findings illuminate the basic mechanisms-attention concentration and curvature-dependent gradient dynamics—that underpin ICL. By revealing how Lipschitz continuity and feature separation jointly determine convergence and generalization, our theory offers testable predictions for real-world settings (e.g., effects of task smoothness and feature geometry) and provides a principled starting point for extending formal guarantees to more realistic transformer architectures. Although our analysis focuses on a single-layer, single-head model, extending it to multi-head and multi-layer transformers presents substantial challenges due to intertwined cross-head gradients and the recursive evolution of representations across layers. Depth introduces residual connections and nonlinearities that couple representation learning with attention dynamics, making phase-wise analysis significantly more delicate. We view developing such extensions as an important direction for future work, and our curvature-sensitive framework provides a promising starting point.
|
| 123 |
+
# REFERENCES
|
| 124 |
+
- Rishabh Agarwal, Avi Singh, Lei Zhang, Bernd Bohnet, Luis Rosias, Stephanie Chan, Biao Zhang, Ankesh Anand, Zaheer Abbas, Azade Nova, et al. Many-shot in-context learning. *Advances in Neural Information Processing Systems*, 37:76930–76966, 2024.
|
| 125 |
+
- Ekin Akyürek, Dale Schuurmans, Jacob Andreas, Tengyu Ma, and Denny Zhou. What learning algorithm is in-context learning? investigations with linear models. In *International Conference on Learning Representations*, 2023.
|
| 126 |
+
- Yu Bai, Fan Chen, Huan Wang, Caiming Xiong, and Song Mei. Transformers as statisticians: Provable in-context learning with in-context algorithm selection. *Advances in neural information processing systems*, 36:57125–57211, 2023.
|
| 127 |
+
- Jiarui Bi, Zengliang Zhu, and Qinglong Meng. Transformer in computer vision. In 2021 IEEE International Conference on Computer Dcience, Electronic Information Engineering and Intelligent Control Technology (CEI), pp. 178–188. IEEE, 2021.
|
| 128 |
+
- Alberto Bietti, Vivien Cabannes, Diane Bouchacourt, Herve Jegou, and Leon Bottou. Birth of a transformer: A memory viewpoint. *Advances in Neural Information Processing Systems*, 36: 1560–1588, 2023.
|
| 129 |
+
{10}------------------------------------------------
|
| 130 |
+
<span id="page-10-14"></span><span id="page-10-13"></span><span id="page-10-12"></span><span id="page-10-8"></span>**558 559 560**
|
| 131 |
+
<span id="page-10-5"></span><span id="page-10-1"></span><span id="page-10-0"></span>**564**
|
| 132 |
+
<span id="page-10-16"></span><span id="page-10-15"></span><span id="page-10-9"></span><span id="page-10-7"></span><span id="page-10-6"></span><span id="page-10-3"></span><span id="page-10-2"></span>**579**
|
| 133 |
+
- <span id="page-10-11"></span><span id="page-10-10"></span><span id="page-10-4"></span>Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. *Advances in Neural Information Processing Systems*, 33:1877–1901, 2020.
|
| 134 |
+
- Siyu Chen, Heejune Sheen, Tianhao Wang, and Zhuoran Yang. Training dynamics of multi-head softmax attention for in-context learning: Emergence, convergence, and optimality. *arXiv preprint arXiv:2402.19442*, 2024.
|
| 135 |
+
- Xiang Cheng, Yuxin Chen, and Suvrit Sra. Transformers implement functional gradient descent to learn non-linear functions in context. In *Proceedings of the 41st International Conference on Machine Learning*, pp. 8002–8037, 2024.
|
| 136 |
+
- Liam Collins, Advait Parulekar, Aryan Mokhtari, Sujay Sanghavi, and Sanjay Shakkottai. In-context learning with transformers: Softmax attention adapts to function lipschitzness. *arXiv preprint arXiv:2402.11639*, 2024.
|
| 137 |
+
- Damai Dai, Yutao Sun, Li Dong, Yaru Hao, Shuming Ma, Zhifang Sui, and Furu Wei. Why can gpt learn in-context? language models implicitly perform gradient descent as meta-optimizers. *arXiv preprint arXiv:2212.10559*, 2022.
|
| 138 |
+
- Ezra Edelman, Nikolaos Tsilivis, Benjamin Edelman, Eran Malach, and Surbhi Goel. The evolution of statistical induction heads: In-context learning markov chains. *Advances in Neural Information Processing Systems*, 37:64273–64311, 2024.
|
| 139 |
+
- Fabian Falck, Ziyu Wang, and Chris Holmes. Is in-context learning in large language models bayesian? a martingale perspective. *arXiv preprint arXiv:2406.00793*, 2024.
|
| 140 |
+
- Shivam Garg, Dimitris Tsipras, Percy S Liang, and Gregory Valiant. What can transformers learn in-context? a case study of simple function classes. *Advances in Neural Information Processing Systems*, 35:30583–30598, 2022.
|
| 141 |
+
- Micah Goldblum, Hossein Souri, Renkun Ni, Manli Shu, Viraj Prabhu, Gowthami Somepalli, Prithvijit Chattopadhyay, Mark Ibrahim, Adrien Bardes, Judy Hoffman, et al. Battle of the backbones: A large-scale comparison of pretrained models across computer vision tasks. *Advances in Neural Information Processing Systems*, 36, 2024.
|
| 142 |
+
- Kai Han, Yunhe Wang, Hanting Chen, Xinghao Chen, Jianyuan Guo, Zhenhua Liu, Yehui Tang, An Xiao, Chunjing Xu, Yixing Xu, et al. A survey on vision transformer. *IEEE Transactions on Pattern Analysis and Machine Intelligence*, 45(1):87–110, 2022.
|
| 143 |
+
- Irina Higgins, David Amos, David Pfau, Sebastien Racaniere, Loic Matthey, Danilo Rezende, and Alexander Lerchner. Towards a definition of disentangled representations. *arXiv preprint arXiv:1812.02230*, 2018.
|
| 144 |
+
- Yu Huang, Yuan Cheng, and Yingbin Liang. In-context convergence of transformers. In *International Conference on Machine Learning*. PMLR, 2024.
|
| 145 |
+
- Hong Jun Jeon, Jason D Lee, Qi Lei, and Benjamin Van Roy. An information-theoretic analysis of in-context learning. *arXiv preprint arXiv:2401.15530*, 2024.
|
| 146 |
+
- Katikapalli Subramanyam Kalyan, Ajit Rajasekharan, and Sivanesan Sangeetha. Ammus: A survey of transformer-based pretrained models in natural language processing. *arXiv preprint arXiv:2108.05542*, 2021.
|
| 147 |
+
- Siddique Latif, Aun Zaidi, Heriberto Cuayahuitl, Fahad Shamshad, Moazzam Shoukat, and Junaid Qadir. Transformers in speech processing: A survey. *arXiv preprint arXiv:2303.11607*, 2023.
|
| 148 |
+
- Hongkang Li, Meng Wang, Songtao Lu, Xiaodong Cui, and Pin-Yu Chen. How do nonlinear transformers learn and generalize in in-context learning? In *International Conference on Machine Learning*, 2024a.
|
| 149 |
+
- Tianle Li, Ge Zhang, Quy Duc Do, Xiang Yue, and Wenhu Chen. Long-context llms struggle with long in-context learning. *arXiv preprint arXiv:2404.02060*, 2024b.
|
| 150 |
+
{11}------------------------------------------------
|
| 151 |
+
<span id="page-11-14"></span><span id="page-11-13"></span><span id="page-11-5"></span><span id="page-11-2"></span>**604 605 606**
|
| 152 |
+
<span id="page-11-8"></span><span id="page-11-6"></span><span id="page-11-4"></span>**617**
|
| 153 |
+
<span id="page-11-11"></span><span id="page-11-10"></span>**619**
|
| 154 |
+
<span id="page-11-7"></span><span id="page-11-1"></span><span id="page-11-0"></span>**634**
|
| 155 |
+
<span id="page-11-17"></span><span id="page-11-16"></span><span id="page-11-9"></span><span id="page-11-3"></span>**636**
|
| 156 |
+
- <span id="page-11-15"></span><span id="page-11-12"></span>Yuchen Li, Yuanzhi Li, and Andrej Risteski. How do transformers learn topic structure: Towards a mechanistic understanding. In *International Conference on Machine Learning*, pp. 19689–19729. PMLR, 2023.
|
| 157 |
+
- Ziqian Lin and Kangwook Lee. Dual operating modes of in-context learning. In *Forty-first International Conference on Machine Learning*, 2024.
|
| 158 |
+
- Yue M Lu, Mary I Letey, Jacob A Zavatone-Veth, Anindita Maiti, and Cengiz Pehlevan. Asymptotic theory of in-context learning by linear attention. *arXiv preprint arXiv:2405.11751*, 2024.
|
| 159 |
+
- Arvind Mahankali, Tatsunori B Hashimoto, and Tengyu Ma. One step of gradient descent is provably the optimal in-context learner with one layer of linear self-attention. *arXiv preprint arXiv:2307.03576*, 2023.
|
| 160 |
+
- Ashok Vardhan Makkuva, Marco Bondaschi, Adway Girish, Alliot Nagle, Hyeji Kim, Michael Gastpar, and Chanakya Ekbote. Local to global: Learning dynamics and effect of initialization for transformers. *Advances in Neural Information Processing Systems*, 37:86243–86308, 2024.
|
| 161 |
+
- Ambuj Mehrish, Navonil Majumder, Rishabh Bharadwaj, Rada Mihalcea, and Soujanya Poria. A review of deep learning techniques for speech processing. *Information Fusion*, 99:101869, 2023.
|
| 162 |
+
- Eshaan Nichani, Alex Damian, and Jason D Lee. How transformers learn causal structure with gradient descent. In *International Conference on Machine Learning*, 2024.
|
| 163 |
+
- Kazusato Oko, Yujin Song, Taiji Suzuki, and Denny Wu. Pretrained transformer efficiently learns low-dimensional target functions in-context. *Advances in Neural Information Processing Systems*, 37:77316–77365, 2024.
|
| 164 |
+
- Core Francisco Park, Andrew Lee, Ekdeep Singh Lubana, Yongyi Yang, Maya Okawa, Kento Nishi, Martin Wattenberg, and Hidenori Tanaka. Iclr: In-context learning of representations. In *International Conference on Learning Representations*, 2025.
|
| 165 |
+
- Nived Rajaraman, Marco Bondaschi, Ashok Vardhan Makkuva, Kannan Ramchandran, and Michael Gastpar. Transformers on markov data: Constant depth suffices. *Advances in Neural Information Processing Systems*, 37:137521–137556, 2024.
|
| 166 |
+
- Ruifeng Ren and Yong Liu. Towards understanding how transformers learn in-context through a representation learning lens. *Advances in Neural Information Processing Systems*, 37:892–933, 2024.
|
| 167 |
+
- Haoyuan Sun, Ali Jadbabaie, and Navid Azizan. In-context learning of polynomial kernel regression in transformers with glu layers. *arXiv preprint arXiv:2501.18187*, 2025.
|
| 168 |
+
- Lewis Tunstall, Leandro Von Werra, and Thomas Wolf. *Natural language processing with transformers*. " O'Reilly Media, Inc.", 2022.
|
| 169 |
+
- Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. *Advances in Neural Information Processing Systems*, 30, 2017.
|
| 170 |
+
- Johannes Von Oswald, Eyvind Niklasson, Ettore Randazzo, João Sacramento, Alexander Mordvintsev, Andrey Zhmoginov, and Max Vladymyrov. Transformers learn in-context by gradient descent. In *International Conference on Machine Learning*, pp. 35151–35174. PMLR, 2023.
|
| 171 |
+
- Xin Wang, Hong Chen, Yuwei Zhou, Jianxin Ma, and Wenwu Zhu. Disentangled representation learning for recommendation. *IEEE Transactions on Pattern Analysis and Machine Intelligence*, 45(1):408–424, 2022.
|
| 172 |
+
- Xin Wang, Hong Chen, Si'ao Tang, Zihao Wu, and Wenwu Zhu. Disentangled representation learning. *IEEE Transactions on Pattern Analysis and Machine Intelligence*, 2024.
|
| 173 |
+
- Xinyi Wang, Wanrong Zhu, and William Yang Wang. Large language models are implicitly topic models: Explaining and finding good demonstrations for in-context learning. *arXiv preprint arXiv:2301.11916*, 1:15, 2023.
|
| 174 |
+
{12}------------------------------------------------
|
| 175 |
+
- <span id="page-12-4"></span><span id="page-12-3"></span><span id="page-12-2"></span><span id="page-12-1"></span><span id="page-12-0"></span> Zhiyong Wu, Yaoxiang Wang, Jiacheng Ye, and Lingpeng Kong. Self-adaptive in-context learning: An information compression perspective for in-context example selection and ordering. In *Annual Meeting of the Association for Computational Linguistics*, pp. 1423–1436, 2023. Sang Michael Xie, Aditi Raghunathan, Percy Liang, and Tengyu Ma. An explanation of in-context learning as implicit bayesian inference. *arXiv preprint arXiv:2111.02080*, 2021. Tong Yang, Yu Huang, Yingbin Liang, and Yuejie Chi. In-context learning with representations: Contextual generalization of trained transformers. *Advances in Neural Information Processing Systems*, 2024. Ruiqi Zhang, Spencer Frei, and Peter L Bartlett. Trained transformers learn linear models in-context. *Journal of Machine Learning Research*, 25(49):1–55, 2024.
|
| 176 |
+
- Yufeng Zhang, Fengzhuo Zhang, Zhuoran Yang, and Zhaoran Wang. What and how does in-context learning learn? bayesian model averaging, parameterization, and generalization. *arXiv preprint arXiv:2305.19420*, 2023.
|
| 177 |
+
{13}------------------------------------------------
|
| 178 |
+
APPENDIX [A The Use of LLMs for Polishing Writing](#page-14-1) 15 [B Additional Experimental Results](#page-14-0) 15 [C Proof of Lemma 1](#page-16-0) 17 [D Proof of Lemma 2](#page-17-0) 18 [E Proofs for Flat](#page-18-1) L-Regime 19 [E.1 Proof of Proposition 2](#page-18-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 [E.2 Proof of Proposition 3](#page-20-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 [E.3 Proof of Theorem 1](#page-22-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 [F Proofs for Sharp](#page-22-1) L-Regime 24 [F.1 Proof of Proposition 4](#page-23-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 [F.2 Proof of Theorem 2](#page-24-0) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 [G Proof of Proposition 1](#page-24-1) 25
|
| 179 |
+
{14}------------------------------------------------
|
| 180 |
+
In the appendices, we first present additional experimental results in Appendix B. Then we present detailed proofs of Lemma 1 and Lemma 2 in Appendix C and Appendix D. For ease of exposition, before establishing the two main theorems, we separately analyze the convergence dynamics under both the flat L-regime and the sharp L-regime.
|
| 181 |
+
Specifically, following the proof of Lemma 1, we prove Proposition 2 (see Appendix E.1) and Proposition 3 (see Appendix E.2) as preliminaries for the proof of Theorem 1 in the flat L-regime (see Appendix E.3).
|
| 182 |
+
We then proceed to prove Proposition 4 (see Appendix F.1) as a preliminary for Theorem 2 (see Appendix F.2) in the sharp L-regime.
|
| 183 |
+
<span id="page-14-1"></span>Finally, based on Theorem 1 and Theorem 2, we prove Proposition 1 (see Appendix G).
|
| 184 |
+
#### A THE USE OF LLMS FOR POLISHING WRITING
|
| 185 |
+
We used a large language model (LLM) tool (e.g., ChatGPT) solely to polish and improve the readability of certain sections of this manuscript—specifically, the introduction, abstract, and several explanatory paragraphs. All research ideas, theoretical derivations, experimental designs, analyses, and conclusions are original to the authors. The LLM was not used to generate technical content, proofs, or results. We reviewed and edited all text produced with LLM assistance to ensure accuracy and consistency with our intended meaning.
|
| 186 |
+
# <span id="page-14-0"></span>B ADDITIONAL EXPERIMENTAL RESULTS
|
| 187 |
+
Building on the prediction loss and attention dynamics shown in Figure 1, we provide a more detailed analysis of the $4\times 4$ attention maps in this appendix. Figure 2 and Figure 3 show the attention patterns for the flat (L=0.1) and sharp (L=1) loss landscapes, respectively, under the experimental conditions of Section 6.
|
| 188 |
+

|
| 189 |
+
<span id="page-14-2"></span>Figure 2: Dynamics of attention maps under flat L=0.1
|
| 190 |
+

|
| 191 |
+
<span id="page-14-3"></span>Figure 3: Dynamics of attention maps under sharp L=1
|
| 192 |
+
In the attention maps, each grid position (i,j) corresponds to the attention score $Attn_{i,j}$ , where $i,j \in \{1,2,3,4\}$ are the indices of key and query, respectively. An important property is that the sum of attention scores for each column equals one $(\sum_i Attn_{i,j} = 1)$ , given the same query $v_j$ . The
|
| 193 |
+
{15}------------------------------------------------
|
| 194 |
+
attention maps show a clear trend: the diagonal entries (i,i) become progressively darker over t, indicating that the corresponding self-attention scores $\mathrm{Attn}_i$ increase for all $i \in \{1,2,3,4\}$ . We observe these scores approaching 1 before t=300 for the flat landscape L=0.1 and before t=200 for the sharp landscape L=1. In contrast, the off-diagonal entries (i,j), where $i \neq j$ , become lighter, with $\mathrm{Attn}_{i,j}$ converging toward zero. This behavior supports the theoretical findings presented in Proposition 2 and Proposition 3 and is directly reflected in the attention score dynamics plotted in Figure 1(c) and Figure 1(d).
|
| 195 |
+

|
| 196 |
+

|
| 197 |
+
- (a) Prediction loss for flat L-set under polynomial functions.
|
| 198 |
+
- <span id="page-15-0"></span>(b) Prediction loss for sharp L-set under polynomial functions.
|
| 199 |
+
Figure 4: Training dynamics of prediction losses for two sets of L: flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ) under polynomial functions.
|
| 200 |
+
To further validate the generality of our theoretical results, we conducted an additional experiment on a different class of nonlinear functions: random second-degree polynomials of the form $f(x) = x^{\top}Ax + b^{\top}x$ , where the matrix A and vector b were randomly generated for each task instance. The elements of A and b satisfy $A_{ij}, b_i \sim \mathcal{N}(0, (\frac{L}{d})^2)$ . For this experiment, we relaxed the finite feature set assumption by sampling input features from a continuous Gaussian distribution. In other words, there can be infinitely many feature vectors. For the other parameters, we set d=30, N=150, M=500. The prediction loss, averaged over 30 independent runs, is shown below for both the flat L-regime and the sharp L-regime. The results strongly corroborate our main findings: The flat regime has two training phases, while the sharp regime has three phases. Within both regimes, a larger Lipschitz constant L consistently results in faster convergence of the prediction loss. This provides further evidence that the identified training dynamics and the role of the Lipschitz constant hold for a broader class of nonlinear functions beyond the trigonometric family, and also hold for more general feature set and token sampling process.
|
| 201 |
+

|
| 202 |
+

|
| 203 |
+
- (a) Prediction loss for flat L-set under two-layer transformer.
|
| 204 |
+
- <span id="page-15-1"></span>(b) Prediction loss for sharp L-set under two-layer transformer.
|
| 205 |
+
Figure 5: Training dynamics of prediction losses for two sets of L: flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ) under two-layer transformer.
|
| 206 |
+
In addition to the single-layer setting analyzed in the main text, we further evaluate whether the curvature-dependent convergence behavior persists in deeper Transformer architectures such as two-layer and four-layer models. To this end, we present experiments using more realistic architectures that contain two or four stacked self-attention layers followed by two or four FFN blocks, under the same
|
| 207 |
+
{16}------------------------------------------------
|
| 208 |
+

|
| 209 |
+

|
| 210 |
+
- (a) Prediction loss for flat L-set under four-layer transformer.
|
| 211 |
+
- <span id="page-16-1"></span>(b) Prediction loss for sharp L-set under four-layer transformer.
|
| 212 |
+
Figure 6: Training dynamics of prediction losses for two sets of L: flat ( $\{0.1, 0.2, 0.4\}$ ) and sharp ( $\{1.0, 1.5, 2.0\}$ ) under four-layer transformer.
|
| 213 |
+
data and task setup as in Figure 4. As shown in Figure 5 and Figure 6, the deeper Transformers exhibit the same qualitative learning dynamics predicted by our theory, including a clear phase transition between the flat and sharp L-regimes and consistent phase-wise convergence behavior. These results indicate that the core mechanisms identified in our analysis, which were derived for a single-layer model for analytical tractability, naturally extend to multi-layer Transformer architectures.
|
| 214 |
+
# <span id="page-16-0"></span>C PROOF OF LEMMA 1
|
| 215 |
+
Recall the definition of the prediction error $\mathcal{L}(P;Q)$ in Eq. (5):
|
| 216 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} (\hat{y}_{\text{query}} - f(v_k))^2 \right]$$
|
| 217 |
+
$$= \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} f(v_n) - f(v_k) \right)^2 \right]$$
|
| 218 |
+
$$= \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} (f(v_n) - f(v_k)) \right)^2 \right]$$
|
| 219 |
+
$$= \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} \left( \sum_{n \neq k} \operatorname{Attn}_n^{(t)} (f(v_n) - f(v_k)) \right)^2 \right]$$
|
| 220 |
+
where we apply $\sum_{n\in[K]}\operatorname{Attn}_n^{(t)}=1$ to rewrite $f(v_k)$ as $\sum_{n\in[K]}\operatorname{Attn}_n^{(t)}f(v_k)$ in the third equality.
|
| 221 |
+
Next, under the non-degenerate L-Lipschitz condition of the function class (see Eq. (2)), we have $\sum_{n\neq k} |f(v_n) - f(v_k)| = \mathcal{O}(L\Delta)$ . Therefore, the sum can be bounded (order-wise) as
|
| 222 |
+
$$\left| \sum_{n \neq k} \operatorname{Attn}_{n}^{(t)} (f(v_{n}) - f(v_{k})) \right| = (1 - \operatorname{Attn}_{k}^{(t)}) \cdot \mathcal{O}(L\Delta)$$
|
| 223 |
+
and thus
|
| 224 |
+
$$\left(\sum_{n\neq k}\operatorname{Attn}_n^{(t)}(f(v_n)-f(v_k))\right)^2 = (1-\operatorname{Attn}_k^{(t)})^2 \cdot \mathcal{O}(L^2\Delta^2).$$
|
| 225 |
+
Putting these together, we obtain:
|
| 226 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E}\left[\mathbb{1}\{x_{\text{query}} = v_k\}(1 - \operatorname{Attn}_k^{(t)})^2 \cdot \mathcal{O}(L^2 \Delta^2)\right].$$
|
| 227 |
+
{17}------------------------------------------------
|
| 228 |
+
<span id="page-17-0"></span>This completes the proof of Lemma 1.
|
| 229 |
+
# D Proof of Lemma 2
|
| 230 |
+
To derive $q_k$ , we first compute the gradient of prediction loss with respect to $Q^{(t)}$ as follows:
|
| 231 |
+
$$\nabla_{Q^{(t)}} \mathcal{L} = \mathbb{E} \Big[ (\hat{y}_{\text{query}} - f(v_k))^\top \frac{\partial \hat{y}_{\text{query}}}{\partial Q^{(t)}} \Big] = \mathbb{E} \Big[ (\hat{y}_{\text{query}} - f(v_k))^\top \sum_{i \in [N]} \frac{\partial \text{attn}_i}{\partial Q^{(t)}} y_i \Big].$$
|
| 232 |
+
We then compute the gradient of $\operatorname{attn}_i^{(t)}$ with respect to $Q^{(t)}\colon$
|
| 233 |
+
$$\begin{split} \frac{\partial \text{attn}_{i}^{(t)}}{\partial Q^{(t)}} &= \frac{e^{\bar{X}_{i}^{\top}Q^{(t)}x_{\text{query}}} \cdot \bar{X}_{i}^{\top}x_{\text{query}}^{\top}(\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}})^{2}}{(\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}})^{2}} \\ &- \frac{\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}} \cdot \bar{X}_{j}^{\top}x_{\text{query}}^{\top} \cdot e^{\bar{X}_{i}^{\top}Q^{(t)}x_{\text{query}}}}{(\sum_{j \in [N]} e^{\bar{X}_{j}^{\top}Q^{(t)}x_{\text{query}}})^{2}} \\ &= \text{attn}_{i}^{(t)} \cdot \bar{X}_{i}^{\top}x_{\text{query}} - \text{attn}_{i}^{(t)} \sum_{j \in [N]} \text{attn}_{j}^{(t)} \cdot \bar{X}_{j}^{\top}x_{\text{query}} \\ &= \text{attn}_{i}^{(t)} \sum_{j \in [N]} \text{attn}_{j}^{(t)}(\bar{X}_{i} - \bar{X}_{j})x_{\text{query}}^{\top}. \end{split}$$
|
| 234 |
+
Substituting into the above expression gives:
|
| 235 |
+
$$\nabla_{Q^{(t)}} \mathcal{L} = \mathbb{E}\Big[ (\hat{y}_{\text{query}}^{(t)} - f(v_k)) \sum_{i,j \in [N]} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} (\bar{X}_i - \bar{X}_j) x_{\text{query}}^\top y_i \Big].$$
|
| 236 |
+
For any feature vectors $v_k$ and $v_{k'}$ , we calculate
|
| 237 |
+
$$\begin{split} v_{k'}^\top \nabla_{Q^{(t)}} \mathcal{L} \cdot v_k = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \sum_{i,j \in [N]} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} y_i v_{k'}^\top (\bar{X}_i - \bar{X}_j) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \sum_{m,n \in [K]} \sum_{i \in \mathcal{V}_m} \sum_{j \in \mathcal{V}_n} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} y_i v_{k'}^\top (v_m - v_n) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \sum_{n \in [K]} \sum_{i \in \mathcal{V}_{k'}} \sum_{j \in \mathcal{V}_n} \operatorname{attn}_i^{(t)} \operatorname{attn}_j^{(t)} y_i v_{k'}^\top (v_{k'} - v_n) \Big] \\ + & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} f(v_{k'}) \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} \big\} \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} f(v_{k'}) \sum_{n \in [K]} \operatorname{Attn}_m^{(t)} f(v_m) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} f(v_m) \Big] \\ = & \mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \big( \hat{y}_{\text{query}} - f(v_k) \big) \operatorname{Attn}_{k'}^{(t)} \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} \big( f(v_{k'}) - f(v_m) \big) \Big]. \end{split}$$
|
| 238 |
+
Since
|
| 239 |
+
$$\hat{y}_{\text{query}} = \sum_{i \in [N]} \operatorname{attn}_i y_i = \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} f(v_m)$$
|
| 240 |
+
, we obtain
|
| 241 |
+
$$v_{k'}^{\top} \nabla_{Q^{(t)}} \mathcal{L} v_k = -\mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \operatorname{Attn}_{k'}^{(t)} \sum_{n \in [K]} \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} \operatorname{Attn}_n^{(t)} (f(v_k) - f(v_n)) (f(v_{k'}) - f(v_m)) \Big] \\ = -\mathbb{E} \Big[ \mathbb{1} \big\{ x_{\text{query}} = v_k \big\} \operatorname{Attn}_{k'}^{(t)} (f(v_k) - \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} f(v_n)) (f(v_{k'}) - \sum_{m \in [K]} \operatorname{Attn}_m^{(t)} f(v_m)) \Big].$$
|
| 242 |
+
We then derive Eq. (10) by letting $v_k = v_{k'}$ using this expression:
|
| 243 |
+
$$g_k^{(t)} = -v_k^{\top} \nabla_{Q^{(t)}} \mathcal{L} \cdot v_k$$
|
| 244 |
+
{18}------------------------------------------------
|
| 245 |
+
$$\begin{split} &= \mathbb{E}\left[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_k^{(t)} \left(f(v_k) - \sum_{n \in [K]} \operatorname{Attn}_n^{(t)} f(v_n)\right)^2\right] \\ &= \mathbb{E}\left[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_k^{(t)} \left(\sum_{n \in [K]} \operatorname{Attn}_n^{(t)} (f(v_k) - f(v_n))\right)^2\right] \\ &= \mathbb{E}\left[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right], \end{split}$$
|
| 246 |
+
where the last equality follows from the non-degenerate L-Lipschitz condition in Eq. (2).
|
| 247 |
+
For any $k \neq n$ , we calculate
|
| 248 |
+
$$\begin{split} |g_{k,k'}^{(t)}| &= \mathbb{E}\Big[\mathbbm{1}\{x_{\text{query}} = v_k\} \text{Attn}_{k'}^{(t)} | f(v_k) - \sum_{j \in [K]} \text{Attn}_{j}^{(t)} f(v_j) | \cdot | f(v_{k'}) - \sum_{m \in [K]} \text{Attn}_{m}^{(t)} f(v_m) | \Big] \\ &= p_k \cdot \mathbb{E}\Big[\text{Attn}_{k'}^{(t)} \Big| \sum_{j \in [K]} (\text{Attn}_{j}^{(t)} f(v_k) - \text{Attn}_{j}^{(t)} f(v_j)) \Big| \cdot \Big| \sum_{m \in [K]} (\text{Attn}_{m}^{(t)} f(v_{k'}) - \text{Attn}_{m}^{(t)} f(v_m)) \Big| \Big] \\ &= p_k \cdot \mathbb{E}\Big[\text{Attn}_{k'}^{(t)} \cdot \sum_{j \in [K]} \text{Attn}_{j}^{(t)} | f(v_k) - f(v_j) | \cdot \sum_{m \in [K]} \text{Attn}_{m}^{(t)} | f(v_{k'}) - f(v_m) | \Big] \\ &= p_k \cdot \mathbb{E}\left[\text{Attn}_{k'}^{(t)} \cdot (1 - \text{Attn}_{k}^{(t)}) \cdot (1 - \text{Attn}_{k'}^{(t)}) \cdot \Theta(L^2\Delta^2) \right]. \end{split}$$
|
| 249 |
+
<span id="page-18-1"></span>This completes the proof of Lemma 2.
|
| 250 |
+
## E PROOFS FOR FLAT L-REGIME
|
| 251 |
+
#### <span id="page-18-0"></span>E.1 Proof of Proposition 2
|
| 252 |
+
<span id="page-18-2"></span>**Lemma 3.** For any $t \in \{1, ..., T_f^1\}$ , if $x_{\text{query}} = v_k$ , we have:
|
| 253 |
+
- Attn<sub>k</sub><sup>(t)</sup> = $\Omega\left(\frac{1}{K}\right)$ ,
|
| 254 |
+
- $1 \operatorname{Attn}_{k}^{(t)} = \Theta(1)$ ,
|
| 255 |
+
- $\operatorname{Attn}_{n}^{(t)} = \Theta\left(\frac{1 \operatorname{Attn}_{k}^{(t)}}{K}\right) = \Theta\left(\frac{1}{K}\right)$ for all $n \neq k$ .
|
| 256 |
+
*Proof.* Fix any $t \in \{1, \dots, T_f^1\}$ . By definition,
|
| 257 |
+
$$\begin{aligned} \text{Attn}_{k}^{(t)} &= \frac{|\mathcal{V}_{k}| e^{v_{k}^{\top} Q^{(t)} v_{k}}}{\sum_{j \in [N]} e^{E_{j}^{x \top} Q^{(t)} v_{k}}} = \frac{|\mathcal{V}_{k}| e^{q_{k}^{(t)}}}{\sum_{m \neq k} |\mathcal{V}_{m}| e^{q_{k,m}^{(t)}} + |\mathcal{V}_{k}| e^{q_{k}^{(t)}}} \\ &= \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_{m}|}{|\mathcal{V}_{k}|} \exp(q_{k,m}^{(t)} - q_{k}^{(t)}) + 1}. \end{aligned}$$
|
| 258 |
+
By the symmetry property in the initial phase, $q_{k,m}^{(t)} = \Theta\left(\frac{q_k^{(t)}}{K}\right)$ . Thus,
|
| 259 |
+
$$e^{-(\log K + \Theta(\frac{\log K}{K}))} \leq \exp(q_{k,m}^{(t)} - q_k^{(t)}) \leq e^{\Theta(\frac{\log K}{K})}.$$
|
| 260 |
+
Define $u_k = K(p_k - \delta)$ and $U_k = K(p_k + \delta)$ . Then, from the concentration property (see Eq. (7)), $|\mathcal{V}_k| \in [\frac{u_k}{K}N, \frac{U_k}{K}N]$ for constants $u_k, U_k = \Theta(1)$ . Therefore,
|
| 261 |
+
$$\operatorname{Attn}_k^{(t)} \geq \frac{1}{e^{\Theta(\frac{\log K}{K})}(\frac{N}{|\mathcal{V}_k|}-1)+1} \geq \frac{1}{e^{\Theta(\frac{\log K}{K})}(\frac{K}{u_k}-1)+1} = \Omega\left(\frac{1}{K}\right).$$
|
| 262 |
+
For the upper bound,
|
| 263 |
+
$$Attn_k^{(t)} \le \frac{1}{e^{-(\log K + \Theta(\frac{\log K}{K}))}(\frac{N}{|\mathcal{V}_k|} - 1) + 1} \le \frac{1}{e^{-1}(\frac{1}{U_k} - \frac{1}{K}) + 1},$$
|
| 264 |
+
{19}------------------------------------------------
|
| 265 |
+
which follows because $U_k = \Theta(1)$ , and hence
|
| 266 |
+
$$1 - \operatorname{Attn}_{k}^{(t)} \ge \frac{\frac{1}{U_{k}} - \frac{1}{K}}{(\frac{1}{U_{k}} - \frac{1}{K}) + e} = \Theta(1).$$
|
| 267 |
+
The reverse bound is similar, showing $1 - \text{Attn}_k^{(t)} = \Theta(1)$ .
|
| 268 |
+
For $n \neq k$ , by similar calculation,
|
| 269 |
+
$$Attn_n^{(t)} = \frac{|\mathcal{V}_n| \exp(q_{k,n}^{(t)})}{\sum_{m \neq k} |\mathcal{V}_m| \exp(q_{k,m}^{(t)}) + |\mathcal{V}_k| \exp(q_k^{(t)})},$$
|
| 270 |
+
and since $|\mathcal{V}_m|/|\mathcal{V}_n| = \Theta(1)$ and $\exp(q_{k,m}^{(t)} - q_{k,n}^{(t)}) = e^{O(\frac{\log K}{K})}$ ,
|
| 271 |
+
$$\frac{\operatorname{Attn}_{n}^{(t)}}{1 - \operatorname{Attn}_{k}^{(t)}} = \frac{|\mathcal{V}_{n}| \exp(q_{k,n}^{(t)})}{\sum_{m \neq k} |\mathcal{V}_{m}| \exp(q_{k,m}^{(t)})} = \Theta\left(\frac{1}{K}\right).$$
|
| 272 |
+
Thus,
|
| 273 |
+
$$\operatorname{Attn}_n^{(t)} = (1 - \operatorname{Attn}_k^{(t)})\Theta\left(\frac{1}{K}\right) = \Theta\left(\frac{1}{K}\right)$$
|
| 274 |
+
, since $1 - \operatorname{Attn}_k^{(t)} = \Theta(1)$ .
|
| 275 |
+
<span id="page-19-0"></span>**Lemma 4.** For any $t \in \{1, ..., T_f^1\}$ , given $x_{query} = v_k$ , we have:
|
| 276 |
+
•
|
| 277 |
+
$$g_k^{(t)} = \Theta\left(\frac{L^2\Delta^2}{K}\right)$$
|
| 278 |
+
,
|
| 279 |
+
•
|
| 280 |
+
$$|g_{k,n}^{(t)}| = O\left(\frac{L^2\Delta^2}{K^2}\right)$$
|
| 281 |
+
for any $n \neq k$ .
|
| 282 |
+
Proof. By the gradient expression from Lemma 2, we have
|
| 283 |
+
$$g_k^{(t)} = \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right]$$
|
| 284 |
+
$$= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \mid x_{\text{query}} = v_k\right] \cdot \Theta(L^2 \Delta^2).$$
|
| 285 |
+
By Lemma 3, in Phase I, we have
|
| 286 |
+
$$p_k = \Theta(1/K)$$
|
| 287 |
+
, $\operatorname{Attn}_k^{(t)} = \Theta(1)$ , and $1 - \operatorname{Attn}_k^{(t)} = \Theta(1)$ .
|
| 288 |
+
Therefore,
|
| 289 |
+
$$g_k^{(t)} = \Theta\left(\frac{1}{K} \cdot 1 \cdot (1)^2 \cdot L^2 \Delta^2\right) = \Theta\left(\frac{L^2 \Delta^2}{K}\right).$$
|
| 290 |
+
For the cross-gradient term, for $n \neq k$ ,
|
| 291 |
+
$$\begin{split} |g_{k,n}^{(t)}| &= \mathbb{E}\Big[\mathbbm{1}\{x_{\mathrm{query}} = v_k\} \operatorname{Attn}_n^{(t)} |f(v_k) - \sum_j \operatorname{Attn}_j^{(t)} f(v_j)| \, |f(v_n) - \sum_m \operatorname{Attn}_m^{(t)} f(v_m)| \Big] \\ &= p_k \cdot \mathbb{E}\Big[\operatorname{Attn}_n^{(t)} \Big| \sum_j \operatorname{Attn}_j^{(t)} (f(v_k) - f(v_j)) \Big| \, \Big| \sum_m \operatorname{Attn}_m^{(t)} (f(v_n) - f(v_m)) \Big| \, | \, x_{\mathrm{query}} = v_k \Big] \\ &\leq p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)} \cdot \sum_j \operatorname{Attn}_j^{(t)} |f(v_k) - f(v_j)| \cdot \sum_m \operatorname{Attn}_m^{(t)} |f(v_n) - f(v_m)| \right] \\ &= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)} (1 - \operatorname{Attn}_k^{(t)}) (1 - \operatorname{Attn}_n^{(t)}) \mathcal{O}(L^2 \Delta^2) \right]. \end{split}$$
|
| 292 |
+
By Lemma 3, $\operatorname{Attn}_n^{(t)} = \Theta(1/K)$ and $1 - \operatorname{Attn}_k^{(t)}, 1 - \operatorname{Attn}_n^{(t)} = \Theta(1)$ , so
|
| 293 |
+
$$|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{1}{K} \cdot \frac{1}{K} \cdot 1 \cdot 1 \cdot L^2 \Delta^2\right) = \mathcal{O}\left(\frac{L^2 \Delta^2}{K^2}\right)$$
|
| 294 |
+
This completes the proof of Lemma 4.
|
| 295 |
+
<span id="page-19-1"></span>**Lemma 5.** Given $\delta = o(1)$ , at the end of Phase I (i.e., at $t = T_f^1 + 1$ ), we have:
|
| 296 |
+
•
|
| 297 |
+
$$q_h^{(T_f^1+1)} = \Theta(\log K)$$
|
| 298 |
+
,
|
| 299 |
+
•
|
| 300 |
+
$$\operatorname{Attn}_{k}^{(T_f^1+1)} = \Omega\left(\frac{1}{1+\delta}\right) if x_{\text{query}} = v_k.$$
|
| 301 |
+
{20}------------------------------------------------
|
| 302 |
+
*Proof.* By Lemma 4, we have $g_k^{(t)} = \Theta\left(\frac{L^2\Delta^2}{K}\right)$ for all t in Phase I. Thus,
|
| 303 |
+
$$\begin{aligned} q_k^{(T_f^1+1)} &= q_k^{(0)} + \eta \sum_{t=1}^{T_f^1} g_k^{(t)} \\ &= q_k^{(0)} + \eta \cdot T_f^1 \cdot \Theta\left(\frac{L^2 \Delta^2}{K}\right) \\ &= \Theta(\log K), \end{aligned}$$
|
| 304 |
+
where we apply the definition of $T_f^1$ from the main text.
|
| 305 |
+
For the off-diagonal terms, from Lemma 4, $|g_{k,m}^{(t)}| = O\left(\frac{L^2\Delta^2}{K^2}\right)$ for any $m \neq k$ . Hence,
|
| 306 |
+
$$\begin{split} q_{k,m}^{(T_f^1+1)} &\leq |q_{k,m}^{(0)}| + \eta \cdot T_f^1 \cdot \mathcal{O}\left(\frac{L^2 \Delta^2}{K^2}\right) \\ &= \mathcal{O}\left(\frac{\log K}{K}\right). \end{split}$$
|
| 307 |
+
Therefore, at the end of Phase I,
|
| 308 |
+
$$q_k^{(T_f^1+1)} - q_{k,m}^{(T_f^1+1)} = \Theta(\log K) - \mathcal{O}\left(\frac{\log K}{K}\right) = \Theta(\log K).$$
|
| 309 |
+
Now, the attention weight for k at time t is
|
| 310 |
+
$$Attn_k^{(t)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.$$
|
| 311 |
+
Using the above, for $t = T_f^1 + 1$ ,
|
| 312 |
+
$$\exp(q_{k,m}^{(t)} - q_k^{(t)}) \leq \exp\left(\mathcal{O}\left(\frac{\log K}{K}\right) - \log K\right) = \mathcal{O}\left(\frac{1}{K}\right).$$
|
| 313 |
+
By the concentration condition in Eq. (7), $|\hat{\mathcal{V}}_k| \geq \frac{u_k}{K} N$ for some $u_k = \Theta(1)$ , and $N/|\mathcal{V}_k| = \Theta(1/\delta)$ (since $\delta = o(1)$ is the imbalance parameter). Thus,
|
| 314 |
+
$$\operatorname{Attn}_{k}^{(t)} \ge \frac{1}{\mathcal{O}\left(\frac{1}{K}\right)\left(\frac{N}{|\mathcal{V}_{k}|} - 1\right) + 1} \ge \frac{1}{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \Omega\left(\frac{1}{1 + \delta}\right),$$
|
| 315 |
+
where the last equality follows because $1/u_k - 1/K = \Theta(\delta)$ from Eq. (7).
|
| 316 |
+
This completes the proof of Lemma 5 and Proposition 2.
|
| 317 |
+
## <span id="page-20-0"></span>E.2 PROOF OF PROPOSITION 3
|
| 318 |
+
**Lemma 6.** For any $t \in \{T_f^1 + 1, \dots, T_f^*\}$ , given $\delta = o(1)$ , if $x_{\text{query}} = v_k$ , we have:
|
| 319 |
+
- Attn $_k^{(t)} = \Omega\left(\frac{1}{1+\delta}\right)$ ,
|
| 320 |
+
- $1 \operatorname{Attn}_{k}^{(t)} = \mathcal{O}(\delta)$ ,
|
| 321 |
+
- $\operatorname{Attn}_n^{(t)} = \Theta\left(\frac{1 \operatorname{Attn}_k^{(t)}}{K}\right) = \Theta\left(\frac{\delta}{K}\right)$ for any $n \neq k$ .
|
| 322 |
+
*Proof.* By Proposition 2 (see also Lemma 5), for any $t \ge T_f^1 + 1$ , we have $\operatorname{Attn}_k^{(t)} = \Omega\left(\frac{1}{1+\delta}\right)$ .
|
| 323 |
+
We now show that $1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\delta)$ . Using the same attention formula as before,
|
| 324 |
+
$$Attn_k^{(t)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.$$
|
| 325 |
+
{21}------------------------------------------------
|
| 326 |
+
From previous bounds, $\exp(q_{k,m}^{(t)}-q_k^{(t)})=O\left(\frac{1}{K}\right)$ , and $|\mathcal{V}_k|\geq u_kN/K$ with $1/u_k-1/K=\Theta(\delta)$ . Therefore,
|
| 327 |
+
$$\operatorname{Attn}_{k}^{(t)} \geq \frac{1}{\mathcal{O}\left(\frac{1}{K}\right)\left(\frac{N}{|\mathcal{V}_{k}|} - 1\right) + 1} \geq \frac{1}{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \Omega\left(\frac{1}{1 + \delta}\right).$$
|
| 328 |
+
For the upper bound, we compute:
|
| 329 |
+
$$1 - \operatorname{Attn}_{k}^{(t)} \le 1 - \frac{1}{\mathcal{O}\left(\frac{1}{K}\right)\left(\frac{N}{|\mathcal{V}_{k}|} - 1\right) + 1} = \frac{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right)}{\mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \mathcal{O}(\delta),$$
|
| 330 |
+
where the last equality uses $\frac{1}{u_k} - \frac{1}{K} = \Theta(\delta)$ from Eq. (7). Thus, $1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\delta)$ .
|
| 331 |
+
Finally, for any $n \neq k$ , we can use the same method as in Lemma 3 to obtain:
|
| 332 |
+
$$\operatorname{Attn}_{n}^{(t)} = \mathcal{O}\left(\frac{1 - \operatorname{Attn}_{k}^{(t)}}{K}\right) = \mathcal{O}\left(\frac{\delta}{K}\right).$$
|
| 333 |
+
This completes the proof.
|
| 334 |
+
<span id="page-21-0"></span>**Lemma 7.** For any $t \in \{T_f^1 + 1, \dots, T_f^*\}$ and any fixed $k \in [K]$ , we have:
|
| 335 |
+
•
|
| 336 |
+
$$g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2}{K}\right)$$
|
| 337 |
+
,
|
| 338 |
+
•
|
| 339 |
+
$$|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2}{K^2}\right)$$
|
| 340 |
+
for all $n \neq k$ .
|
| 341 |
+
*Proof.* Recall from the gradient expression and Lemma 4:
|
| 342 |
+
$$\begin{split} g_k^{(t)} &= \mathbb{E}\left[\mathbb{1}\{x_{\text{query}} = v_k\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right] \\ &= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \mid x_{\text{query}} = v_k\right] \cdot \Theta(L^2 \Delta^2). \end{split}$$
|
| 343 |
+
By Lemma 5 and subsequent results for Phase II, we have $p_k = \Theta(1/K)$ , $\operatorname{Attn}_k^{(t)} = \Theta(1)$ , and $1 - \operatorname{Attn}_k^{(t)} = \Theta(\delta)$ . Therefore,
|
| 344 |
+
$$g_k^{(t)} = \Theta\left(\frac{1}{K} \cdot 1 \cdot \delta^2 \cdot L^2 \Delta^2\right) = \Theta\left(\frac{\delta^2 L^2 \Delta^2}{K}\right).$$
|
| 345 |
+
For the cross-gradient terms with $n \neq k$ , using the same approach as in Lemma 4, we obtain
|
| 346 |
+
$$|g_{k,n}^{(t)}| \le p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)}(1 - \operatorname{Attn}_k^{(t)})(1 - \operatorname{Attn}_n^{(t)}) \cdot \mathcal{O}(L^2\Delta^2)\right].$$
|
| 347 |
+
In Phase II, by the previous lemma, we have $\operatorname{Attn}_n^{(t)} = \Theta(\delta/K)$ , $1 - \operatorname{Attn}_n^{(t)} = \Theta(1)$ , and $1 - \operatorname{Attn}_k^{(t)} = \Theta(\delta)$ . Thus,
|
| 348 |
+
$$|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{1}{K} \cdot \frac{\delta}{K} \cdot \delta \cdot 1 \cdot L^2 \Delta^2\right) = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2}{K^2}\right).$$
|
| 349 |
+
This completes the proof of Lemma 7.
|
| 350 |
+
<span id="page-21-1"></span>**Lemma 8.** At the end of Phase II under the flat L-regime (i.e., $t = T_f^* + 1$ ), if $x_{query} = v_k$ , we have:
|
| 351 |
+
•
|
| 352 |
+
$$q_k^{(T_f^*+1)} = \Theta\left(\frac{\log K}{\epsilon}\right)$$
|
| 353 |
+
,
|
| 354 |
+
• Attn<sub>k</sub><sup>$$(T_f^*+1)$$</sup> = $\Omega\left(\frac{1}{1+\epsilon\delta}\right)$ ,
|
| 355 |
+
•
|
| 356 |
+
$$1 - \operatorname{Attn}_{k}^{(T_f^* + 1)} = \mathcal{O}(\epsilon \delta).$$
|
| 357 |
+
*Proof.* By Lemma 7, we have $g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2}{K}\right)$ in Phase II. Thus,
|
| 358 |
+
$$q_k^{(T_f^*+1)} = q_k^{(T_f^1)} + \eta \cdot \Theta\left(\frac{L^2 \Delta^2 \delta^2}{K}\right) \cdot (T_f^* - T_f^1)$$
|
| 359 |
+
{22}------------------------------------------------
|
| 360 |
+
$$= \Theta(\log(K\epsilon^{-1}))$$
|
| 361 |
+
$$= \Theta\left(\frac{\log K}{\epsilon}\right),$$
|
| 362 |
+
where the last step applies the scaling of $T_f^*$ and the learning rate in the flat L-regime.
|
| 363 |
+
For the cross terms, by Lemma 7 again.
|
| 364 |
+
$$\begin{split} q_{k,m}^{(T_f^*+1)} &\leq |q_{k,m}^{(T_f^1)}| + \eta \cdot \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2}{K^2}\right) \cdot (T_f^* - T_f^1) \\ &= \Theta\left(\frac{\log(K\epsilon^{-1})}{K}\right). \end{split}$$
|
| 365 |
+
Therefore, at $t = T_f^* + 1$ , we have
|
| 366 |
+
$$q_{k,m}^{(T_f^*+1)} - q_k^{(T_f^*+1)} = \mathcal{O}\left(\frac{\log(K\epsilon^{-1})}{K}\right) - \Theta(\log(K\epsilon^{-1})) = -\Theta(\log(K\epsilon^{-1})),$$
|
| 367 |
+
and so
|
| 368 |
+
$$\exp(q_{k,m}^{(t)} - q_k^{(t)}) \leq \exp\left(-\Theta(\log K)\right) = \mathcal{O}\left(\frac{1}{K}\right).$$
|
| 369 |
+
The attention weight for k is then
|
| 370 |
+
$$\operatorname{Attn}_k^{(t)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(t)} - q_k^{(t)}) + 1}.$$
|
| 371 |
+
Using the bounds above, and $|\mathcal{V}_k| \geq u_k N/K$ , with $\frac{1}{u_k} - \frac{1}{K} = \Theta(\delta)$ (see Eq. (7)), we obtain:
|
| 372 |
+
$$\operatorname{Attn}_{k}^{(T_{f}^{*}+1)} \geq \frac{1}{\mathcal{O}(\epsilon) \cdot \mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \Omega\left(\frac{1}{1 + \epsilon\delta}\right).$$
|
| 373 |
+
Similarly,
|
| 374 |
+
$$1 - \operatorname{Attn}_{k}^{(T_{f}^{*}+1)} \leq \frac{\mathcal{O}(\epsilon) \cdot \mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right)}{\mathcal{O}(\epsilon) \cdot \mathcal{O}\left(\frac{1}{u_{k}} - \frac{1}{K}\right) + 1} = \mathcal{O}(\epsilon\delta).$$
|
| 375 |
+
This completes the proof of Lemma 8 and Proposition 3.
|
| 376 |
+
# <span id="page-22-0"></span>E.3 PROOF OF THEOREM 1
|
| 377 |
+
Recall from Lemma 2 and its proof that the prediction error $\mathcal{L}(P;Q)$ defined in Eq. (5) can be expressed as
|
| 378 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} (1 - \text{Attn}_k^{(t)})^2 \mathcal{O}(L^2 \Delta^2)\right],$$
|
| 379 |
+
where we use $\sum_{n \neq k} \operatorname{Attn}_n^{(t)} = 1 - \operatorname{Attn}_k^{(t)}$ and, by the function class assumption, $|f(v_n) - f(v_k)| = 1$ $\Theta(L\Delta)$ .
|
| 380 |
+
At the end of Phase II (i.e., at $t=T_f^*+1$ ), suppose $x_{\rm query}=v_k$ . By Lemma 8, we have $1 - \operatorname{Attn}_{L}^{(T_f^* + 1)} = O(\epsilon \delta)$ . Therefore,
|
| 381 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} (1 - \text{Attn}_k^{(T_f^* + 1)})^2 \mathcal{O}(L^2 \Delta^2) \right]$$
|
| 382 |
+
$$= \mathbb{E} \left[ (1 - \text{Attn}_k^{(T_f^* + 1)})^2 \mathcal{O}(L^2 \Delta^2) \right]$$
|
| 383 |
+
$$= \mathcal{O}(\epsilon^2),$$
|
| 384 |
+
where the last equality uses $(1-\operatorname{Attn}_k^{(T_f^*+1)})^2=\mathcal{O}(\epsilon^2\delta^2)$ and $L^2\Delta^2=\mathcal{O}(1/(\Delta^2\delta^2))\cdot\Delta^2=0$ $\mathcal{O}(1/\delta^2)$ when $L \leq \Theta(1/(\Delta\delta))$ , so the $\delta^2$ cancels, leaving $\mathcal{O}(\epsilon^2)$ .
|
| 385 |
+
<span id="page-22-1"></span>This establishes the desired rate and completes the proof of Theorem 1.
|
| 386 |
+
{23}------------------------------------------------
|
| 387 |
+
# F PROOFS FOR SHARP L-REGIME
|
| 388 |
+
#### <span id="page-23-0"></span>F.1 Proof of Proposition 4
|
| 389 |
+
<span id="page-23-1"></span>**Lemma 9.** For any $t \in \{T_f^* + 1, \dots, T_s^*\}$ and any fixed $k \in [K]$ , we have:
|
| 390 |
+
•
|
| 391 |
+
$$g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K}\right)$$
|
| 392 |
+
,
|
| 393 |
+
•
|
| 394 |
+
$$|g_{k,n}^{(t)}| = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right)$$
|
| 395 |
+
for all $n \neq k$ .
|
| 396 |
+
*Proof.* Recall from the gradient expression:
|
| 397 |
+
$$g_k^{(t)} = \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} \operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \Theta(L^2 \Delta^2)\right]$$
|
| 398 |
+
$$= p_k \cdot \mathbb{E}\left[\operatorname{Attn}_k^{(t)} (1 - \operatorname{Attn}_k^{(t)})^2 \mid x_{\text{query}} = v_k\right] \cdot \Theta(L^2 \Delta^2),$$
|
| 399 |
+
where $p_k = \Theta(1/K)$ .
|
| 400 |
+
By Lemma 8, in this phase $\mathrm{Attn}_k^{(t)} = \Theta(1)$ and $1 - \mathrm{Attn}_k^{(t)} = \mathcal{O}(\epsilon \delta)$ . Therefore,
|
| 401 |
+
$$g_k^{(t)} = \Theta\left(\frac{1}{K} \cdot 1 \cdot (\epsilon \delta)^2 \cdot L^2 \Delta^2\right) = \Theta\left(\frac{\delta^2 L^2 \Delta^2 \epsilon^2}{K}\right).$$
|
| 402 |
+
For the cross-gradient terms $(n \neq k)$ , by the same argument as in Lemma 7, we have:
|
| 403 |
+
$$|g_{k,n}^{(t)}| \le p_k \cdot \mathbb{E}\left[\operatorname{Attn}_n^{(t)}(1 - \operatorname{Attn}_k^{(t)})(1 - \operatorname{Attn}_n^{(t)}) \cdot \Theta(L^2\Delta^2)\right].$$
|
| 404 |
+
In this phase, $\operatorname{Attn}_n^{(t)} = \Theta(\delta/K)$ , $1 - \operatorname{Attn}_n^{(t)} = \Theta(1)$ , and $1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\epsilon\delta)$ . Therefore,
|
| 405 |
+
$$|g_{k,n}^{(t)}| \leq \Theta\left(\frac{1}{K} \cdot \frac{\delta}{K} \cdot \epsilon \delta \cdot 1 \cdot L^2 \Delta^2\right) = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right).$$
|
| 406 |
+
This completes the proof of Lemma 9.
|
| 407 |
+
<span id="page-23-2"></span>**Lemma 10.** At the end of Phase II under the sharp L-regime (i.e., at $t = T_s^*$ ), if $x_{\text{query}} = v_k$ , we have:
|
| 408 |
+
•
|
| 409 |
+
$$q_k^{(T_s^*)} = \Theta\left(\frac{\log(KL\Delta)}{\epsilon}\right)$$
|
| 410 |
+
,
|
| 411 |
+
•
|
| 412 |
+
$$\operatorname{Attn}_k^{(T_s^*)} = \Omega\left(\frac{1}{1+\epsilon\delta}\right)$$
|
| 413 |
+
,
|
| 414 |
+
•
|
| 415 |
+
$$1 - \operatorname{Attn}_{k}^{(T_{s}^{*})} = \mathcal{O}(\epsilon \delta).$$
|
| 416 |
+
*Proof.* By Lemma 9, for $t \in \{T_f^*+1,\ldots,T_s^*\}$ , we have $g_k^{(t)} = \Theta\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K}\right)$ . Thus,
|
| 417 |
+
$$q_k^{(T_s^*)} = q_k^{(T_f^*)} + \eta \cdot \Theta\left(\frac{L^2 \Delta^2 \delta^2 \epsilon}{K}\right) \cdot (T_s^* - T_f^*)$$
|
| 418 |
+
$$= \Theta(\log(KL\Delta \epsilon^{-1})),$$
|
| 419 |
+
using the total number of updates and the scaling of $T_s^*$ . (Here, $T_s^* - T_f^* = \Theta\left(\frac{K \log(KL\Delta\epsilon^{-1})}{L^2\Delta^2\delta^2\epsilon}\right)$ .)
|
| 420 |
+
Similarly, for the cross-terms, by Lemma 9, $|g_{k,m}^{(t)}| = \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right)$ for $m \neq k$ , and hence
|
| 421 |
+
$$\begin{split} q_{k,m}^{(T_s^*)} &\leq |q_{k,m}^{(T_f^*)}| + \eta \cdot \mathcal{O}\left(\frac{\delta^2 L^2 \Delta^2 \epsilon}{K^2}\right) \cdot (T_s^* - T_f^*) \\ &= \Theta\left(\frac{\log(KL\Delta \epsilon^{-1})}{K}\right). \end{split}$$
|
| 422 |
+
Therefore,
|
| 423 |
+
$$q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)} = -\Theta(\log(KL\Delta\epsilon^{-1})),$$
|
| 424 |
+
{24}------------------------------------------------
|
| 425 |
+
and so
|
| 426 |
+
$$\exp(q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)}) = \mathcal{O}\left(\frac{\epsilon}{K}\right),\,$$
|
| 427 |
+
where the scaling in the sharp regime produces the $\epsilon$ factor
|
| 428 |
+
For the attention, using the property from Lemma 3,
|
| 429 |
+
$$\operatorname{Attn}_k^{(T_s^*)} = \frac{1}{\sum_{m \neq k} \frac{|\mathcal{V}_m|}{|\mathcal{V}_k|} \exp(q_{k,m}^{(T_s^*)} - q_k^{(T_s^*)}) + 1}.$$
|
| 430 |
+
By the previous bounds, and using $|\mathcal{V}_k| \geq u_k N/K$ and $\frac{1}{u_k} - \frac{1}{K} = \Theta(\delta)$ , we obtain:
|
| 431 |
+
$$\operatorname{Attn}_{k}^{(T_{s}^{*})} \geq \frac{1}{\mathcal{O}(\epsilon) \cdot \mathcal{O}(\frac{1}{n_{k}} - \frac{1}{K}) + 1} = \Omega\left(\frac{1}{1 + \epsilon\delta}\right).$$
|
| 432 |
+
Finally,
|
| 433 |
+
$$1 - \operatorname{Attn}_{k}^{(T_{s}^{*})} \leq \frac{\mathcal{O}(\epsilon) \cdot \mathcal{O}(\frac{1}{u_{k}} - \frac{1}{K})}{\mathcal{O}(\epsilon) \cdot \mathcal{O}(\frac{1}{u_{k}} - \frac{1}{K}) + 1} = \mathcal{O}(\epsilon\delta),$$
|
| 434 |
+
which follows because $\frac{1}{u_k} - \frac{1}{K} = \Theta(\delta)$ .
|
| 435 |
+
This completes the proof of Lemma 10 and Proposition 4.
|
| 436 |
+
## <span id="page-24-0"></span>F.2 PROOF OF THEOREM 2
|
| 437 |
+
As in the proof of Theorem 1, the prediction error $\mathcal{L}(P;Q)$ (from Eq. (5)) can be written as
|
| 438 |
+
$$\mathcal{L}(P;Q) = \frac{1}{2} \sum_{k=1}^{K} \mathbb{E}\left[\mathbb{1}\left\{x_{\text{query}} = v_k\right\} (1 - \text{Attn}_k^{(t)})^2 \mathcal{O}(L^2 \Delta^2)\right].$$
|
| 439 |
+
Suppose $x_{\text{query}} = v_k$ at time $t = T_s^*$ . By Lemma 10, we have $1 - \text{Attn}_k^{(T_s^*)} = O(\epsilon \delta)$ . Therefore,
|
| 440 |
+
$$\mathcal{L}^{(T_s^*)}(P;Q) = \frac{1}{2} \sum_{k=1}^K \mathbb{E} \left[ \mathbb{1} \{ x_{\text{query}} = v_k \} (1 - \text{Attn}_k^{(T_s^*)})^2 \mathcal{O}(L^2 \Delta^2) \right]$$
|
| 441 |
+
$$= \mathbb{E} \left[ (1 - \text{Attn}_k^{(T_s^*)})^2 \mathcal{O}(L^2 \Delta^2) \right]$$
|
| 442 |
+
$$= \mathcal{O}(\epsilon^2 \delta^2).$$
|
| 443 |
+
Under the scaling regime for sharp L, either $\delta = o(1)$ or $\epsilon = o(1)$ (since the in-context learning regime assumes both go to zero), and hence $\mathcal{L}^{(T_s^*)}(P;Q) = \mathcal{O}(\epsilon^2)$ as required.
|
| 444 |
+
<span id="page-24-1"></span>This completes the proof of Theorem 2.
|
| 445 |
+
# **PROOF OF PROPOSITION 1**
|
| 446 |
+
The result that $1 - \operatorname{Attn}_k^{(t)} = \mathcal{O}(\epsilon)$ holds under both the flat L regime and the sharp L regime, as established in Lemma 8 and Lemma 10.
|