potentialpaper

One-Layer Transformers Provably Learn In-Context K-Nearest Neighbor Prediction with Chain-of-Thought

Import NeurIPS 2026 submission KRMF9RmzSJ: 8 notes

@openreview[bot] · 2026-11-22 17:55 UTC · 8729824d35e0

Evidence

.gitattributes added

+++ b/.gitattributes
@@ -0,0 +1,10 @@
+# PDFs and pictures are kept with Git LFS (https://git-lfs.com). With it installed (`git lfs install`),
+# a clone has the files, and `git add` of one stores a pointer. This file is the same on every page.
+/.potentialpaper/*.pdf filter=lfs diff=lfs merge=lfs -text
+/versions/*.pdf filter=lfs diff=lfs merge=lfs -text
+/thumbnail.png filter=lfs diff=lfs merge=lfs -text
+/thumbnail.jpg filter=lfs diff=lfs merge=lfs -text
+/thumbnail.jpeg filter=lfs diff=lfs merge=lfs -text
+/thumbnail.gif filter=lfs diff=lfs merge=lfs -text
+/thumbnail.webp filter=lfs diff=lfs merge=lfs -text
+/thumbnail.avif filter=lfs diff=lfs merge=lfs -text

.potentialpaper/metadata.json added

+++ b/.potentialpaper/metadata.json
@@ -0,0 +1,22 @@
+{
+ "layout": 5,
+ "identifiers": [
+ {
+ "scheme": "openreview",
+ "value": "KRMF9RmzSJ"
+ }
+ ],
+ "title": "One-Layer Transformers Provably Learn In-Context K-Nearest Neighbor Prediction with Chain-of-Thought",
+ "authors": [
+ "Lyumin Wu",
+ "Yuan Cao"
+ ],
+ "abstract": "Chain-of-Thought (CoT) enables transformers to solve complex reasoning tasks by generating intermediate reasoning steps. Despite strong empirical success, the mechanisms by which such reasoning abilities emerge during training remain poorly understood, particularly from a theoretical perspective. In this work, we study this question in a stylized yet fully analyzable setting: in-context $\\mathrm{K}$-nearest-neighbor ($\\mathrm{K}$-NN) prediction with a one-layer transformer. Earlier work has demonstrated that one-layer transformers can be trained to perform $1$-NN without CoT [26] by having the softmax attention attend to the nearest neighbor in context. However, this result on $1$-NN cannot be extended to $\\mathrm{K}$-NN for $K>1$, as softmax attention is much less naturally suited to attending to the 2nd through $K$-th nearest neighbors. We first give a rigorous negative result showing that this limitation already appears on a well-separated class of binary classification tasks for odd $K>1$. We then give an explicit construction of a one-layer transformer, and show that it can solve $\\mathrm{K}$-NN via CoT reasoning. We further prove that, under a stylized training setup, gradient descent can recover this construction, thereby showing that transformers can acquire the capability to solve $\\mathrm{K}$-NN through training. In addition, we show that the resulting trained model applies to a broader test class than that assumed in the training analysis. Our results shed light on how CoT expands the ability of transformers to learn and solve tasks that are otherwise hard to solve.",
+ "year": 2026,
+ "venue": "NeurIPS 2026",
+ "source": "openreview",
+ "license": {
+ "metadata": "CC0-1.0",
+ "abstract": "CC0-1.0"
+ }
+}

community/10-tl-dr.md added

+++ b/community/10-tl-dr.md

community/20-summary.md added

+++ b/community/20-summary.md

community/30-why-it-matters.md added

+++ b/community/30-why-it-matters.md

community/40-critique.md added

+++ b/community/40-critique.md

community/50-errata.md added

+++ b/community/50-errata.md

community/60-reproductions.md added

+++ b/community/60-reproductions.md

community/70-follow-ups.md added

+++ b/community/70-follow-ups.md

owners/10-tl-dr.md added

+++ b/owners/10-tl-dr.md

owners/20-overview.md added

+++ b/owners/20-overview.md

owners/30-results.md added

+++ b/owners/30-results.md

owners/40-demos.md added

+++ b/owners/40-demos.md

owners/50-code-and-data.md added

+++ b/owners/50-code-and-data.md

owners/60-talks.md added

+++ b/owners/60-talks.md

prek.toml added

+++ b/prek.toml
@@ -0,0 +1,36 @@
+# Checks run before each commit, with prek (https://prek.j178.dev): `prek install` once in this clone.
+# The site checks every push again; these catch mistakes before you commit. The same on every page.
+
+[[repos]]
+repo = "builtin"
+hooks = [
+ { id = "check-json" },
+ { id = "pretty-format-json", args = ["--autofix", "--no-sort-keys", "--no-ensure-ascii"], exclude = '^demos/' },
+ { id = "end-of-file-fixer", exclude = '^demos/' },
+ { id = "trailing-whitespace", args = ["--markdown-linebreak-ext=md"], exclude = '^demos/' },
+ { id = "check-case-conflict" },
+ { id = "check-illegal-windows-names" },
+ { id = "check-added-large-files", args = ["--maxkb=256"], exclude = '^demos/' },
+]
+
+# Each JSON file against its schema (https://papers.potentialhedge.com/schemas/).
+[[repos]]
+repo = "https://github.com/python-jsonschema/check-jsonschema"
+rev = "0.39.0"
+hooks = [
+ { id = "check-jsonschema", name = "author section plugins files", files = '^owners/plugins\.json$', args = ["--schemafile", "https://papers.potentialhedge.com/schemas/authorPlugins.json"] },
+ { id = "check-jsonschema", name = "venue files", files = '^venue\.json$', args = ["--schemafile", "https://papers.potentialhedge.com/schemas/venue.json"] },
+ { id = "check-jsonschema", name = "topic files", files = '^topic\.json$', args = ["--schemafile", "https://papers.potentialhedge.com/schemas/topic.json"] },
+ { id = "check-jsonschema", name = "organisation files", files = '^org\.json$', args = ["--schemafile", "https://papers.potentialhedge.com/schemas/org.json"] },
+ { id = "check-jsonschema", name = "link files", files = '^links/[^/]+\.json$', args = ["--schemafile", "https://papers.potentialhedge.com/schemas/link.json"] },
+ { id = "check-jsonschema", name = "version files", files = '^versions/[^/]+\.json$', args = ["--schemafile", "https://papers.potentialhedge.com/schemas/version.json"] },
+ { id = "check-jsonschema", name = "picture files", files = '^thumbnail\.json$', args = ["--schemafile", "https://papers.potentialhedge.com/schemas/thumbnail.json"] },
+]
+
+# Sections formatted the way the web editor formats them.
+[[repos]]
+repo = "https://github.com/rbubley/mirrors-prettier"
+rev = "v3.9.9"
+hooks = [
+ { id = "prettier", files = '^(owners|community)/.*\.md$' },
+]

reviews/openreview/krmf9rmzsj/forms.json added

+++ b/reviews/openreview/krmf9rmzsj/forms.json
@@ -0,0 +1,227 @@
+{
+ "schema": "forms/1",
+ "forms": {
+ "Meta_Review": {
+ "label": "Meta-review",
+ "fields": [
+ {
+ "key": "metareview",
+ "label": "Meta-review",
+ "type": "text"
+ }
+ ]
+ },
+ "Decision": {
+ "label": "Decision",
+ "fields": [
+ {
+ "key": "title",
+ "label": "Title",
+ "hidden": true
+ },
+ {
+ "key": "decision",
+ "label": "Decision",
+ "type": "choice"
+ },
+ {
+ "key": "comment",
+ "label": "Comment",
+ "type": "text"
+ },
+ {
+ "key": "metareview",
+ "label": "Meta-review",
+ "type": "text"
+ },
+ {
+ "key": "final_justification",
+ "label": "Final justification",
+ "type": "text"
+ }
+ ]
+ },
+ "Official_Comment": {
+ "label": "Comment",
+ "fields": [
+ {
+ "key": "title",
+ "label": "Title",
+ "type": "choice"
+ },
+ {
+ "key": "comment",
+ "label": "Comment",
+ "type": "text"
+ }
+ ]
+ },
+ "Public_Comment": {
+ "label": "Public comment",
+ "fields": [
+ {
+ "key": "title",
+ "label": "Title",
+ "type": "choice"
+ },
+ {
+ "key": "comment",
+ "label": "Comment",
+ "type": "text"
+ }
+ ]
+ },
+ "Withdrawal": {
+ "label": "Withdrawal",
+ "fields": [
+ {
+ "key": "withdrawal_confirmation",
+ "label": "Confirmation",
+ "hidden": true
+ }
+ ]
+ },
+ "Desk_Rejection": {
+ "label": "Desk rejection",
+ "fields": [
+ {
+ "key": "desk_reject_comments",
+ "label": "Reason",
+ "type": "text"
+ }
+ ]
+ },
+ "Official_Review": {
+ "label": "Official review",
+ "summary": [
+ "rating",
+ "confidence",
+ "quality",
+ "clarity",
+ "significance",
+ "originality"
+ ],
+ "fields": [
+ {
+ "key": "rating",
+ "label": "Rating",
+ "type": "score",
+ "min": 1,
+ "max": 6
+ },
+ {
+ "key": "confidence",
+ "label": "Confidence",
+ "type": "score",
+ "min": 1,
+ "max": 5
+ },
+ {
+ "key": "quality",
+ "label": "Quality",
+ "type": "score",
+ "min": 1,
+ "max": 4
+ },
+ {
+ "key": "clarity",
+ "label": "Clarity",
+ "type": "score",
+ "min": 1,
+ "max": 4
+ },
+ {
+ "key": "significance",
+ "label": "Significance",
+ "type": "score",
+ "min": 1,
+ "max": 4
+ },
+ {
+ "key": "originality",
+ "label": "Originality",
+ "type": "score",
+ "min": 1,
+ "max": 4
+ },
+ {
+ "key": "contribution_type",
+ "label": "Contribution type",
+ "type": "choice"
+ },
+ {
+ "key": "summary",
+ "label": "Summary",
+ "type": "text"
+ },
+ {
+ "key": "strengths_and_weaknesses",
+ "label": "Strengths and weaknesses",
+ "type": "text"
+ },
+ {
+ "key": "questions",
+ "label": "Questions",
+ "type": "text"
+ },
+ {
+ "key": "limitations",
+ "label": "Limitations",
+ "type": "text"
+ },
+ {
+ "key": "final_justification",
+ "label": "Final justification",
+ "type": "text"
+ },
+ {
+ "key": "paper_formatting_concerns",
+ "label": "Formatting concerns",
+ "type": "text"
+ },
+ {
+ "key": "ethical_concerns",
+ "label": "Ethical concerns",
+ "type": "choice"
+ },
+ {
+ "key": "code_of_conduct_acknowledgement",
+ "label": "Code of conduct",
+ "hidden": true
+ },
+ {
+ "key": "responsible_reviewing_acknowledgement",
+ "label": "Responsible reviewing",
+ "hidden": true
+ }
+ ]
+ },
+ "Rebuttal": {
+ "label": "Rebuttal",
+ "fields": [
+ {
+ "key": "rebuttal",
+ "label": "Rebuttal",
+ "type": "text"
+ }
+ ]
+ },
+ "Ethics_Review": {
+ "label": "Ethics review",
+ "fields": [
+ {
+ "key": "scope_of_ethics_concerns",
+ "label": "Scope",
+ "type": "choice"
+ },
+ {
+ "key": "ethics_review",
+ "label": "Ethics review",
+ "type": "text"
+ }
+ ]
+ }
+ },
+ "url": "https://openreview.net/group?id=NeurIPS.cc%2F2026%2FConference",
+ "license": "CC-BY-4.0"
+}

reviews/openreview/krmf9rmzsj/notes/3lsykar8dr.json added

+++ b/reviews/openreview/krmf9rmzsj/notes/3lsykar8dr.json
@@ -0,0 +1,32 @@
+{
+ "schema": "review/1",
+ "id": "3LsYKaR8Dr",
+ "replyTo": null,
+ "kind": "review",
+ "invitation": "Official_Review",
+ "signature": "Reviewer RhHp",
+ "content": {
+ "summary": "The paper provides a rigorous theoretical analysis of how Chain-of-Thought (CoT) reasoning enables one-layer transformers to perform in-context $K$-nearest-neighbor ($K$-NN) (binary) classification. In the process, it constructs a negative result showing that direct inference by a one-layer transformer fails for odd $K > 1$ on well-separated inputs. The paper's central claim, demonstrating CoT enables K-NN via sequential nearest-neighbor selection using stochastic positional encodings, comes with a training dynamics result showing that gradient descent on a one-step supervision objective recovers their underlying construction, with loss converging to zero.",
+ "contribution_type": "theory",
+ "strengths_and_weaknesses": "> ### Strengths\n- The paper is well-written, easy to follow, and well-organized. The proof machinery is substantial and carefully executed. The training dynamics analysis (Appendix E) is particularly impressive. The authors reduce the full matrix gradient descent problem to a @D scalar system via symmetry arguments, specifically by exploiting rotational invariance in feature space, label sign symmetry, and the signed-permutation symmetry of the stochastic positional encodings.\n- I found the boundary-layer asymptotic analysis in Section E.5, treating the logistic kernels as approximate identities concentrating around the critical threshold $\\lambda$ quite interesting.\n- In terms of overall impact, it is fair to say that this work addresses the central challenge that [1] left open; their 1-NN result relied on softmax attention, naturally concentrating on the single maximum-inner-product token, a property that breaks for $K > 1$.\n\n[1] Li, Z., Cao, Y., Gao, C., He, Y., Liu, H., Klusowski, J.M., Fan, J. and Wang, M., 2024. One-layer transformer provably learns one-nearest neighbor in context. Advances in Neural Information Processing Systems, 37, pp.82166-82204.\n\n---\n\n> ### Weaknesses\n- The paper's central technical device: stochastic positional encodings with random signed permutations, is non-standard and seems only to serve the theoretical construct. The authors attempt to justify its relatability in practice by enabling the symmetry arguments for training analysis; however, the encoding scheme raises serious questions. It is not clear how sensitive the results are to the specific structure of these encodings. Would natural alternatives (learned positional encodings, RoPE, etc.) support an analogous mechanism? \n\n- Fixing $V$ throughout training (Section 4) is a significant constraint (though commonly referred to in literature). It pre-encodes the output structure (the label and positional components are automatically passed through), which makes the model do less work than a real transformer, where $V$ must also be learned.\n\n- The training distribution requires $x_i, x_q$ uniform on the sphere, labels satisfying $\\mathbb{E}[y_i y_j | x_{1:q}] = 0$ for $i \\neq j$, and specific rotation and sign symmetries. This is quite restrictive. The condition covers the case where labels are i.i.d. uniform $±1$ independent of features: arguably a setting where $K$-NN prediction is nearly vacuous (the label of $x_q$ is independent of its neighbors).\n\n- The construction and following arguments of the paper hinge on the binary classification problem, with little discussion regarding generalizability towards a multi-class setup.",
+ "quality": 3,
+ "clarity": 3,
+ "significance": 3,
+ "originality": 3,
+ "questions": "- The value $−2$ seems to emerge from the geometry of the unit sphere. Is this ratio stable, in the sense that if the data lived on a sphere of radius $r \\neq 1$ or were drawn from a different distribution, would the critical ratio change correspondingly? How generalizable is the approach?\n- The training objective supervises the full target vector $(x_q^\\top, y_{\\pi(1)}, p_{N+1}^\\top + p_{\\pi(1)}^\\top)^\\top$. This includes the positional component, which encodes which neighbor was selected. At test time, this target vector is not available, and the model must generate it autoregressively. How does the training objective guarantee that the positional component learned during training generalizes to the autoregressive rollout? \n- Figure 2 shows that the learned $V$ converges to the theoretical construction. Does the joint training converge at the same rate as fixed-$V$ training?\n- Can the authors comment on the tightness/lower bound on the CoT steps required (as in Theorem 3.1: $K-1$)?",
+ "limitations": "The paper does a good job of pointing out technical limitations throughout the discussion.",
+ "rating": 4,
+ "confidence": 4,
+ "ethical_concerns": [
+ "NO or VERY MINOR ethics concerns only"
+ ],
+ "paper_formatting_concerns": "There are no immediate formatting lapses.",
+ "code_of_conduct_acknowledgement": "Yes",
+ "responsible_reviewing_acknowledgement": "Yes",
+ "final_justification": "Based on the author's responses to my questions and taking into consideration other discussions, the merit of the paper outweighs the concerns raised. Hence, I stand by my initial score."
+ },
+ "createdAt": "2026-06-25T19:00:42.984Z",
+ "modifiedAt": "2026-11-18T13:44:36.706Z",
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ&noteId=3LsYKaR8Dr",
+ "license": "CC-BY-4.0"
+}

reviews/openreview/krmf9rmzsj/notes/acrt2pgjmk.json added

+++ b/reviews/openreview/krmf9rmzsj/notes/acrt2pgjmk.json
@@ -0,0 +1,19 @@
+{
+ "schema": "review/1",
+ "id": "ACRt2pgjmk",
+ "replyTo": null,
+ "kind": "decision",
+ "invitation": "Decision",
+ "signature": "Program Chairs",
+ "content": {
+ "title": "Paper Decision",
+ "decision": "Accept (poster)",
+ "comment": "",
+ "metareview": "Initial Meta-Review\n\nI would like the rebuttal to focus on the following prioritized points:\n- ffVj-W1 (one-layer Transformer) ~USTL-W3\n - I think it is acceptable, but provide some discussion.\n- ffVj-W2 (stochastic position encoding) ~RhHp-W1, USTL-W2\n - All reviewers identified this as a significant weakness. Please provide a discussion addressing this concern. \n- ffVj-W3 (limited convergence analysis)\n - Please provide some discussion.\n- RhHp-W2/3 (restrictive assumptions: Fixing V; training distribution)\n - This is also a crucial point. Please provide more discussion.\n- RhHp-W4 (multiclass setup)\n - I think it is acceptable to focus on the binary setting, but please provide some discussion on a multiclass setup.\n- USTL-W1 (Need for broader comparison with prior work)\n - Please provide a broader comparison with prior work.\n\n---\nFinal Meta-Review\n\nThe most important reason for the decision is that this paper establishes an expressiveness gap between direct inference and CoT: a one-layer transformer without CoT cannot perform K-NN via direct inference, whereas the same architecture can solve K-NN via CoT. \nThe authors well responded to the concerns raised by the reviewers, particularly as described below. Overall I recommend accept.\n- ffVj-W2 (stochastic position encoding) ~RhHp-W1, USTL-W2\n- RhHp-W2/3 (restrictive assumptions: Fixing V; training distribution)\n - After the rebuttal, the reviewers think the settings and the assumptions are overall necessary or acceptable as they are used to simplify the complicated theoretical analysis of GD with transformers.",
+ "final_justification": "See the Meta-Review."
+ },
+ "createdAt": "2026-09-24T11:27:08.506Z",
+ "modifiedAt": "2026-11-18T14:59:05.535Z",
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ&noteId=ACRt2pgjmk",
+ "license": "CC-BY-4.0"
+}

reviews/openreview/krmf9rmzsj/notes/lkjcygs5bm.json added

+++ b/reviews/openreview/krmf9rmzsj/notes/lkjcygs5bm.json
@@ -0,0 +1,15 @@
+{
+ "schema": "review/1",
+ "id": "LkJCYgS5BM",
+ "replyTo": null,
+ "kind": "meta_review",
+ "invitation": "Meta_Review",
+ "signature": "Area Chair AyxU",
+ "content": {
+ "metareview": "Initial Meta-Review\n\nI would like the rebuttal to focus on the following prioritized points:\n- ffVj-W1 (one-layer Transformer) ~USTL-W3\n - I think it is acceptable, but provide some discussion.\n- ffVj-W2 (stochastic position encoding) ~RhHp-W1, USTL-W2\n - All reviewers identified this as a significant weakness. Please provide a discussion addressing this concern. \n- ffVj-W3 (limited convergence analysis)\n - Please provide some discussion.\n- RhHp-W2/3 (restrictive assumptions: Fixing V; training distribution)\n - This is also a crucial point. Please provide more discussion.\n- RhHp-W4 (multiclass setup)\n - I think it is acceptable to focus on the binary setting, but please provide some discussion on a multiclass setup.\n- USTL-W1 (Need for broader comparison with prior work)\n - Please provide a broader comparison with prior work.\n\n---\nFinal Meta-Review\n\nThe most important reason for the decision is that this paper establishes an expressiveness gap between direct inference and CoT: a one-layer transformer without CoT cannot perform K-NN via direct inference, whereas the same architecture can solve K-NN via CoT. \nThe authors well responded to the concerns raised by the reviewers, particularly as described below. Overall I recommend accept.\n- ffVj-W2 (stochastic position encoding) ~RhHp-W1, USTL-W2\n- RhHp-W2/3 (restrictive assumptions: Fixing V; training distribution)\n - After the rebuttal, the reviewers think the settings and the assumptions are overall necessary or acceptable as they are used to simplify the complicated theoretical analysis of GD with transformers."
+ },
+ "createdAt": "2026-07-22T03:53:33.673Z",
+ "modifiedAt": "2026-11-18T15:25:09.111Z",
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ&noteId=LkJCYgS5BM",
+ "license": "CC-BY-4.0"
+}

reviews/openreview/krmf9rmzsj/notes/ontshqrcpw.json added

+++ b/reviews/openreview/krmf9rmzsj/notes/ontshqrcpw.json
@@ -0,0 +1,32 @@
+{
+ "schema": "review/1",
+ "id": "OnTSHqRCpW",
+ "replyTo": null,
+ "kind": "review",
+ "invitation": "Official_Review",
+ "signature": "Reviewer USTL",
+ "content": {
+ "summary": "This paper studies the expressivity and learning guarantees of a one-layer transformer with and without Chain of Thought (CoT). The authors show that a one-layer transformer fails to implement k-Nearest Neighbors (kNN) even for well-separated cases when k is odd, and show that a single-layer, transformer-only network can implement kNN with CoT. Further, they show that gradient descent applied to the population loss recovers the parameters that implement the intermediate tokens that realize kNN.",
+ "contribution_type": "theory",
+ "strengths_and_weaknesses": "**Strengths.**\n* The paper is very well-written, and its core ideas are communicated effectively. \n* It presents a clear operational view of transformers, both with and without Chain of Thought (CoT). \n\n**Weaknesses**\n* *Need for broader comparison with prior work:* The core idea, that a recursively applied transformer circuit can express iterative algorithms, is very close to recent studies such as Huang et al. (2025) [15], which explored single-step versus multi-step gradient descent. In this paper, the algorithm implements k-NN through a sequential nearest-neighbor selection procedure (Lines 171–173). Given this conceptual similarity, could you explicitly compare your work with this earlier literature to clarify your exact contributions?\n* *Unclear embedding construction:* The embedding construction used in this setting is not fully explained and feels somewhat ad hoc. For example, why are stochastic positional encodings necessary?\n* *Limited scope of experiments:* The simulation results focus exclusively on one-layer transformers. Further experiments are needed to determine if the proposed mechanism scales to larger models and more realistic datasets.\n\n---\n\nIn light of these points, I urge the authors to expand the comparison with prior work to better isolate their conceptual contributions. Additionally, extending the experimental section to demonstrate the applicability of the presented mechanism in larger models would significantly strengthen the paper.",
+ "quality": 3,
+ "clarity": 4,
+ "significance": 3,
+ "originality": 2,
+ "questions": "NA",
+ "limitations": "Yes",
+ "rating": 3,
+ "confidence": 3,
+ "ethical_concerns": [
+ "NO or VERY MINOR ethics concerns only"
+ ],
+ "paper_formatting_concerns": "Na",
+ "code_of_conduct_acknowledgement": "Yes",
+ "responsible_reviewing_acknowledgement": "Yes",
+ "final_justification": "Based on our discussion, I have decided to keep my score the same. My justification is as follows:\n\n* From what I could follow, the proof idea and the conceptual approach (implementing iterative methods with CoT) have already been covered in earlier literature, which means that the paper's primary potential contribution should lie in the context of implementing and learning $k$-NN.\n\n* Regarding the discussion on $k$-NN, I find it difficult to believe that scaling up the model does not help in learning $k$-NN for larger values of $k$ in practice. Therefore, it is still not obvious to me how the CoT approach implemented here will help at a larger scale. Ultimately, the discussion and the experiments need to be expanded to establish a clearer picture of how CoT improves $k$-NN."
+ },
+ "createdAt": "2026-06-24T21:47:14.713Z",
+ "modifiedAt": "2026-11-18T13:44:38.512Z",
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ&noteId=OnTSHqRCpW",
+ "license": "CC-BY-4.0"
+}

reviews/openreview/krmf9rmzsj/notes/paehb8iefq.json added

+++ b/reviews/openreview/krmf9rmzsj/notes/paehb8iefq.json
@@ -0,0 +1,15 @@
+{
+ "schema": "review/1",
+ "id": "pAEHB8iEFQ",
+ "replyTo": "Y8jXHM7SOk",
+ "kind": "comment",
+ "invitation": "Rebuttal",
+ "signature": "Authors",
+ "content": {
+ "rebuttal": "Thank you for your thoughtful feedback, and we sincerely appreciate your comments.\n\n**W1&Q1&Q2**. Only one-layer Transformers. Extensions to multi-layer or multi-head Transformers and empirical results?\n\n**A1.** We acknowledge that focusing on the one-layer case is a limitation of the present work.\n\nNevertheless, most existing training-theoretic studies of CoT reasoning [3–5] and in-context 1-NN prediction [6] also focus on one-layer Transformer architectures. As our work builds directly on these two lines of research and establishes a direct comparison with [6] in Proposition 2.2, we consider the one-layer softmax Transformer a natural and well-motivated setting for isolating the mechanism studied here.\n\nMoreover, from an expressivity perspective, the extension to multi-layer or multi-head Transformers is immediate. A multi-layer, multi-head Transformer can reproduce our one-layer, one-head construction by using a single layer and a single head to implement the proposed mechanism while setting the remaining components to be inactive. Therefore, our positive expressivity result continues to hold for these richer architectures.\n\nExtending the training-dynamics analysis is beyond the scope of the current proof. In a multi-head Transformer, different heads may interact or specialize in different functions. In a multi-layer Transformer, each layer transforms the representations passed to subsequent layers, introducing additional dependencies across layers. These interactions are not captured by our current analysis and would require different proof techniques.\n\nWhile extending the training analysis to more practical architectures is an important direction, we believe that the present contribution should be assessed in the context of comparable theoretical studies on the training dynamics of Transformers, most of which likewise focus on the one-layer setting [3-6].\n\nRegarding experiments, we conduct experiments with $N=40$, $d=10$, replacing the single-head, single-layer Transformer with either a four-head, one-layer model or a single-head, two-layer model. Both variants are successfully optimized, exhibiting substantial decreases in training loss and achieving high test accuracy across different values of $K$. These results suggest that both multi-head and multi-layer Transformers can learn the proposed sequential $K$-NN mechanism, indicating that our theoretical setting captures key aspects of more diverse architectures.\n\n|Model|Training loss, 2k|Training loss, 4k|Training loss, 6k|Training loss, 8k|Training loss, 10k|Test acc. $K=1$|Test acc. $K=3$|Test acc. $K=5$|\n|:-:|:-:|:-:|:-:|:-:|:-:|:-:|:-:|:-:|\n|4-head, 1-layer|0.14465|0.10737|0.09930|0.08658|0.08927|100.0|99.7| 98.2|\n|1-head, 2-layer|0.23258|0.15614|0.15273|0.14034|0.15023|100.0|99.1| 92.8|\n\n**W2&Q3&Q5**. stochastic positional encoding? existing theoretical work or practical setting using it? First-step target supervision? How about last-step supervision [7]?\n\n**A2**. Thank you for these thoughtful questions. We address them in detail as follows. \n\n* **stochastic positional encoding**:\n - Our use of stochastic positional encodings follows [1-2]. Specifically, [1] introduces stochastic positional encodings as an alternative to fixed absolute positional encodings, which may generalize poorly to unseen sequence lengths. More closely related to our setting, [2] theoretically analyzes the training dynamics of one-layer Transformers with near-orthogonal stochastic positional encodings. \n - A key observation in [2] is that stochastic positional encoding improves length generalization while inducing distributional symmetry that simplifies the characterization of gradient-descent trajectories. Our analysis builds on the same principle: randomness in the positional encodings induces a signed-permutation symmetry in the positional block, allowing us to show in Appendix E.2 that gradient descent remains confined to a low-dimensional invariant manifold.\n - Our expressive power guarantees (Theorem 3.1, Proposition 3.2) can be directly extended to any mutually orthogonal positional encodings. However, our training analysis relies on the signed-permutation symmetry of stochastic positional encodings used in Appendix E.2; without this symmetry, an analogous guarantee would require a substantially different analysis of the full positional block. We will clarify this distinction in the revision.\n\n* **first-step target supervision**:\n The motivation for considering first-step target supervision is two-fold:\n - First, our work directly extends [6], which shows that a one-layer Transformer without CoT can be trained to perform 1-NN. The setting of first-step target supervision essentially also directly teaches the model to perform 1-NN retrieval, and therefore makes our setting more comparable with [6].\n - Second, prior theoretical studies of one-layer Transformers with CoT [3–5] typically supervise multiple intermediate states through teacher forcing, and multi-step supervision essentially provides repeated examples of a shared transition rule. We observe that such supervision may help optimization analysis, but may not be necessary to identify the rule itself. Our result shows that, for $K$-NN, supervising only the first target state is sufficient to learn a mechanism that can be applied autoregressively over multiple steps. We view this result as a theoretically interesting observation.\n* **last-step supervision**:\n - We also thank the reviewer for suggesting the practically relevant alternative of last-step supervision [7], which is more directly aligned with the final prediction objective. We will cite and discuss [7] in the revision. In our setting, given $q^{(0)},\\ldots,q^{(K-1)}$, the model would similarly be trained to predict $q^{(K)}$, effectively identifying the $K$-th nearest neighbor after excluding the first $K-1$. This relies on the same mechanism as our current analysis—feature similarity ranks the context points, while the accumulated positional state suppresses previously selected neighbors. We therefore expect that a similar analysis may yield an analogous reduced parameterization of $W$, although a formal proof requires additional work.\n\n**W3&Q4**. No characterization of the required number of iterations.\n\n**A3**. You are right that Theorem 4.2 is asymptotic and does not provide an explicit iteration-complexity bound. This asymptotic formulation enables a clean characterization of the limiting parameter regime selected by gradient descent.\n\nSeveral key steps in the proof rely on qualitative arguments that do not yield finite-time estimates. Specifically, Appendix E.3 establishes the divergence of $\\alpha^{(t)}$ and $\\beta^{(t)}$ through contradiction and compactness arguments, while Appendices E.5-E.6 prove the convergence of $\\lambda_t=-\\beta^{(t)}/\\alpha^{(t)}$ to 2 using asymptotic drift and crossing arguments (see also the proof sketch in Section 5). We believe that these two key steps are technically challenging, and our current proof techniques for the asymptotic results are already highly involved. Extending these results to the non-asymptotic regime would require additional theoretical tools and an even more complex proof.\n\nWe will revise the paper to clarify that Theorem 4.2 provides an asymptotic characterization of the recovery of the sharp-attention CoT regime and does not establish a finite-time optimization guarantee.\n\n**Q6**. Can ICL learn K-NN empirically? Comparison between ICL and CoT, empirically and theoretically?\n\n**A4.** We thank the reviewer for this question. We clarify that both settings studied in our paper are forms of in-context learning: at test time, the model receives labeled context examples and a query and predicts without parameter updates. The relevant distinction is between **direct-answer ICL**, which predicts in a single forward pass, and **CoT-augmented ICL**, which autoregressively generates intermediate states before producing the final prediction.\n\nTheoretically, Proposition 2.2 shows that direct-answer ICL cannot uniformly implement odd-$K$ NN over the well-separated class $X_\\gamma$: for any fixed finite parameter setting, there exists an input on which it fails. In contrast, Theorem 3.1 and Proposition 3.2 show that the same one-layer architecture can implement $K$-NN using $K-1$ CoT steps.\n\nEmpirically, we remove CoT supervision and train the Transformer to predict the final state $q^{(K)}=[x_q^\\top,\\sum_{i=1}^{K}y_{\\pi(i)},p_{N+1}^\\top+\\sum_{i=1}^{K}p_{\\pi(i)}^\\top]^\\top$ in a single forward pass. Across all evaluated configurations, the training loss remains approximately between $1.62$ and $1.77$ and shows no consistent decrease over $10000$ steps. Under the same experimental protocol, the direct-answer model therefore fails to learn the $K$-NN target, whereas the CoT-augmented model converges successfully, consistent with our theoretical separation.\n\n|$(N,d)$|Step 2000|Step 4000|Step 6000|Step 8000|Step 10000|\n|:-:|-:|-:|-:|-:|-:|\n|$(20,5)$|1.617138|1.692581|1.674053|1.630763|1.663558|\n|$(20,10)$|1.682409|1.700712|1.695117|1.743311|1.677553|\n|$(40,10)$|1.670989|1.703986|1.705789|1.753437|1.736894|\n|$(40,20)$|1.766365|1.745283|1.713068|1.766397|1.754815|\n\n**References:**\n\n[1] Positional description matters for transformers arithmetic. ArXiv 2023\n\n[2] Transformers Provably Learn Sparse Token Selection While Fully-Connected Nets Cannot. ICML 2024\n\n[3] Transformers Learn to Implement Multi-step Gradient Descent with Chain of Thought. ICLR 2025\n\n[4] Transformers Provably Learn Chain-of-Thought Reasoning with Length Generalization. NeurIPS 2025\n\n[5] Multi-head Transformers Provably Learn Symbolic Multi-step Reasoning via Gradient Descent. NeurIPS 2025\n\n[6] One-Layer Transformer Provably Learns One-Nearest Neighbor In Context. NeurIPS 2024\n\n[7] Dissecting Chain-of-Thought: Compositionality through In-Context Filtering and Learning. NeurIPS 2023"
+ },
+ "createdAt": "2026-07-28T10:18:23.734Z",
+ "modifiedAt": "2026-11-18T17:20:39.300Z",
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ&noteId=pAEHB8iEFQ",
+ "license": "CC-BY-4.0"
+}

reviews/openreview/krmf9rmzsj/notes/tndivmugbr.json added

+++ b/reviews/openreview/krmf9rmzsj/notes/tndivmugbr.json
@@ -0,0 +1,15 @@
+{
+ "schema": "review/1",
+ "id": "tNDiVMuGbr",
+ "replyTo": "OnTSHqRCpW",
+ "kind": "comment",
+ "invitation": "Rebuttal",
+ "signature": "Authors",
+ "content": {
+ "rebuttal": "We sincerely appreciate your thoughtful feedback. Below, we respond to the weaknesses you identified and provide detailed answers to your questions.\n\n**W1**. Comparison with Huang et al. (2025) [3]. Could you explicitly compare your work with this earlier literature to clarify your exact contributions?\n\n**A1**. Thank you for pointing out this important connection. Both our work and Huang et al. [3] study how a learned single-step Transformer computation can be recursively applied to produce a multi-step algorithm. The underlying tasks and mechanisms, however, are substantially different.\n\nHuang et al. [3] consider linear regression, for which gradient descent is already a canonical iterative algorithm. Each CoT step is trained to reproduce one gradient-descent update, and repeatedly applying the same update rule naturally yields a multi-step optimization procedure. By contrast, $K$-NN is conventionally formulated as a direct top-$K$ retrieval-and-aggregation rule rather than as an iterative process. Our work identifies a non-obvious sequential realization of $K$-NN: at each step, the Transformer retrieves the nearest context point that has not yet been selected, while the generated positional state records the selected neighbors and suppresses them in subsequent attention computations. Recursively applying this transition therefore converts a nominally non-iterative prediction rule into a sequential retrieval algorithm.\n\nA second distinction concerns supervision. Huang et al. [3] supervise the intermediate computation step by step, whereas our training objective supervises only the first target state. At test time, the learned transition is applied autoregressively to generate the remaining intermediate states and recover the full $K$-NN prediction. Thus, our result shows that first-step supervision can be sufficient to identify a reusable transition rule whose repeated application implements a longer reasoning process. We view this as an interesting observation.\n\nMoreover, Huang et al. [3] analyze linear attention, which is a simplification of softmax attention, and establish convergence to a finite parameter limit. The nonlinearity of softmax commonly makes the corresponding loss and gradient difficult to express in a tractable closed form. In our setting, we must first use distributional symmetries to prove that gradient descent remains on the invariant manifold $W^{(t)}=\\operatorname{diag}(\\alpha^{(t)}I_d,0,\\beta^{(t)}I_{N+1})$. After this reduction, the parameters do not converge to finite values: Appendix E.3 proves $\\alpha^{(t)}\\to+\\infty$ and $\\beta^{(t)}\\to-\\infty$ through contradiction and compactness arguments, while Appendices E.5-E.6 prove that their relative scale converges, $-\\beta^{(t)}/\\alpha^{(t)}\\to2$, using drift estimates and crossing arguments. Therefore, although both works establish convergence results, characterizing the divergent softmax dynamics and identifying its limiting direction is technically more involved.\n\nWe will revise the related-work discussion to make this comparison explicit.\n\n**W2**. Embedding construction is not fully explained and feels somewhat ad hoc. Why are stochastic positional encodings necessary?\n\n**A2**. We thank the reviewer for this comment.\n\nRegarding the embedding construction, please note that our setting is consistent with existing work on in-context learning [4–7], where the embedding consists of a feature block, a label block, and a positional encoding block.\n\nRegarding the positional encoding, our use of stochastic positional encodings follows [1-2]. Specifically, [1] introduces stochastic positional encodings as an alternative to fixed absolute positional encodings, which may generalize poorly to unseen sequence lengths. More closely related to our setting, [2] theoretically analyzes the training dynamics of one-layer Transformers with near-orthogonal stochastic positional encodings.\n\nA key observation in [2] is that stochastic positional encoding improves length generalization while inducing distributional symmetry that simplifies the characterization of gradient-descent trajectories. Our analysis builds on the same principle: randomness in the positional encodings induces a signed-permutation symmetry in the positional block, allowing us to show in Appendix E.2 that gradient descent remains confined to a low-dimensional invariant manifold.\n\nOur expressive power guarantees (Theorem 3.1, Proposition 3.2) can be directly extended to any mutually orthogonal positional encodings, since the proof primarily uses orthogonality and is otherwise unchanged. However, our training analysis relies on the signed-permutation symmetry of stochastic positional encodings used in Appendix E.2; without this symmetry, an analogous guarantee would require a substantially different analysis of the full positional block. We will clarify this distinction in the revision.\n\n**W3**. Limited scope of experiments.\n\n**A3**. We conduct additional experiments with $N=40$, $d=10$, replacing the single-head, single-layer Transformer with either a four-head, one-layer model or a single-head, two-layer model. Both variants are successfully optimized, exhibiting substantial decreases in training loss and achieving high test accuracy across different values of $K$. These results suggest that both multi-head and multi-layer Transformers can learn the proposed sequential $K$-NN mechanism, indicating that the mechanism is not empirically restricted to the one-layer architecture analyzed in the paper.\n\n|Model|Training loss, 2k|Training loss, 4k|Training loss, 6k|Training loss, 8k|Training loss, 10k|Test acc. $K=1$|Test acc. $K=3$|Test acc. $K=5$|\n|:-|-:|-:|-:|-:|-:|-:|-:|-:|\n|4-head, 1-layer|0.14465|0.10737|0.09930|0.08658|0.08927|100.0|99.7| 98.2|\n|1-head, 2-layer|0.23258|0.15614|0.15273|0.14034|0.15023|100.0|99.1| 92.8|\n\n**References:**\n\n[1] Positional description matters for transformers arithmetic. ArXiv 2023\n\n[2] Transformers Provably Learn Sparse Token Selection While Fully-Connected Nets Cannot. ICML 2024\n\n[3] Transformers Learn to Implement Multi-step Gradient Descent with Chain of Thought. ICLR 2025\n\n[4] One-Layer Transformer Provably Learns One-Nearest Neighbor In Context. NeurIPS 2024\n\n[5] Transformers as Statisticians: Provable In-Context Learning with\nIn-Context Algorithm Selection\n\n[6] In-context Learning on Function Classes Unveiled for Transformers. ICML 2024\n\n[7] In-Context Deep Learning via Transformer Models. ICML 2025"
+ },
+ "createdAt": "2026-07-28T10:30:48.247Z",
+ "modifiedAt": "2026-11-18T17:20:39.189Z",
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ&noteId=tNDiVMuGbr",
+ "license": "CC-BY-4.0"
+}

reviews/openreview/krmf9rmzsj/notes/ud5o0vpv0m.json added

+++ b/reviews/openreview/krmf9rmzsj/notes/ud5o0vpv0m.json
@@ -0,0 +1,15 @@
+{
+ "schema": "review/1",
+ "id": "uD5o0VPV0m",
+ "replyTo": "3LsYKaR8Dr",
+ "kind": "comment",
+ "invitation": "Rebuttal",
+ "signature": "Authors",
+ "content": {
+ "rebuttal": "Thank you for the careful review. Below, we address your concerns regarding the weaknesses and provide detailed answers to your questions.\n\n**W1**. Stochastic positional encodings are non-standard. Sensitivity to these encodings? Alternatives?\n\n**A1**. Thanks for the comment. Below we clarify the motivation for using the stochastic positional encodings and discuss potential alternatives.\n\n* Our use of stochastic positional encodings follows [1-2]. Specifically, [1] introduces stochastic positional encodings as an alternative to fixed absolute positional encodings, which may generalize poorly to unseen sequence lengths. More closely related to our setting, [2] theoretically analyzes the training dynamics of one-layer Transformers with near-orthogonal stochastic positional encodings. \n* A key observation in [2] is that stochastic positional encoding improves length generalization while inducing distributional symmetry that simplifies the characterization of gradient-descent trajectories. Our analysis builds on the same principle: randomness in the positional encodings induces a signed-permutation symmetry in the positional block, allowing us to show in Appendix E.2 that gradient descent remains confined to a low-dimensional invariant manifold.\n* Our expressive power guarantees (Theorem 3.1, Proposition 3.2) can be directly extended to any mutually orthogonal positional encodings, since the proof primarily uses orthogonality and is otherwise unchanged. However, the training-dynamics result is more restrictive: Appendix E.2 relies on the signed-permutation symmetry of stochastic positional encodings to reduce the dynamics to a few scalar variables. This symmetry is generally absent for fixed, learned, and rotary encodings, so extending the training guarantee would require different proof techniques.\n\n**W2**. Fixing $V$ is a limitation.\n\n**A2.** Fixing $V$ throughout training is indeed a limitation of our theoretical analysis. Nevertheless, it is a standard simplification in the literature on Transformer training dynamics [3–6], commonly used to isolate the learning dynamics of attention.\n\nWe would like to point out that the mechanism underlying CoT reasoning identified in our work is governed primarily by $W^{(t)}=\\operatorname{diag}(\\alpha^{(t)}I,0,\\beta^{(t)}I)$. The positive $\\alpha^{(t)}$ amplifies similarity differences and selects the nearest context point, while the negative coefficient $\\beta^{(t)}$ penalizes previously selected tokens, effectively acting as a learned mask. Thus, fixing $V$ preserves the central learning problem: gradient descent must recover the invariant structure of $W$, drive $\\alpha^{(t)}\\to\\infty$ and $\\beta^{(t)}\\to-\\infty$, and establish the limiting ratio $\\beta^{(t)}/\\alpha^{(t)}\\to-2$ required to balance nearest-neighbor selection against suppression of previously retrieved points. Characterizing these coupled dynamics remains highly nontrivial.\n\nWe also provide experiments (Appendix F) in which $W$ and $V$ are jointly trained from random initialization. The model still develops the predicted parameter structure and achieves high CoT $K$-NN accuracy, suggesting that fixing $V$ is primarily an analytical device rather than an empirical requirement. Extending the theory to jointly learned $W$ and $V$ would require analyzing a more complex coupled matrix dynamical system, which we leave for future work.\n\n**W3**. training distribution is restrictive, covering i.i.d. uniform $\\pm 1$ labels independent of features where $K$-NN prediction is nearly vacuous\n\n**A3**. These training assumptions are adapted from [4], which studies the in-context 1-NN problem, and also covers the setting of i.i.d. uniform $\\pm 1$ labels independent of features.\n\nWe would like to clarify that $K$-NN prediction is not vacuous in this setting. Even when $x_i$ and $y_i$ are independent, the context dataset they form still gives a well-defined $K$-NN prediction task, as the $K$-NN predictor relies on feature proximity, rather than label-feature correlations, to make predictions.\n\nIn fact, this special case where $x_i$ and $y_i$ are independent is useful for isolating the learning of a clean nearest-neighbor prediction rule. If the data contain more complex feature-label dependencies, the Transformer may reduce the population loss by exploiting those dependencies directly rather than learning pure nearest-neighbor retrieval. For example, it may learn a mixture of in-context regression and in-context nearest-neighbor prediction. Such behavior may be practically meaningful, but it would make the specific CoT retrieval mechanism studied here more difficult and less clean. We believe this is the main reason why previous work [4] and our work both cover such settings.\n\nWe will add more discussion in the revision.\n\n**W4**. Extensions to a multi-class setup?\n\n**A4**. We agree that extending our analysis to multi-class classification is an important direction. The binary-label setting is not essential to the CoT expressivity results in Theorem 3.1 and Proposition 3.2. For a $C$-class problem, $y_i \\in \\\\{\\pm1\\\\}$ can be replaced by a one-hot encoding $e_{y_i} \\in \\mathbb{R}^C$, with the label block adjusted accordingly. Then, Theorem 3.1 and Proposition 3.2 still hold with $V=\\operatorname{diag}(0_{d\\times d},I_{C},I_{N+1})$, $W=\\operatorname{diag}(\\alpha I_d,0_{C\\times C},\\beta I_{N+1})$. Since neighbor selection depends primarily on the feature and positional blocks, the attention mechanism remains unchanged. After $K$ steps, the accumulated label state $\\sum_{k=1}^{K} e_{y_{\\pi(k)}}$ yields the standard plurality-vote $K$-NN prediction through its largest coordinate.\n\nExtending the training-dynamics theorem requires additional work, as the binary sign-flip symmetry must be replaced by class-permutation symmetry and the reduced dynamics rederived for vector-valued labels. We will discuss this multi-class extension in the revision.\n\n**Q1**. Does the value $2$ emerge from the unit sphere setting? If the data lived on a sphere of radius $r\\neq 1$ or were drawn from a different distribution, would the ratio change? How generalizable is the approach?\n\n**A5**. You are right that $2$ emerges from the geometry of the unit sphere.\nOur analysis can be directly extended to the case when all inputs lie on a sphere of radius $r$, and we can expect the same argument to give the critical ratio $2r^2$. We also expect the analysis to extend approximately to high-dimensional isotropic Gaussian data, whose norms concentrate around a common value. After appropriate rescaling, concentration bounds and perturbation analysis may recover the spherical threshold. For more general distributions, however, the critical ratio may depend on additional geometric properties and may not reduce to a single universal ratio. A rigorous treatment is left for future work.\n\n**Q2**. How does the training objective guarantee that the positional component learned during training generalizes to the autoregressive rollout?\n\n**A6.** The guarantee follows from the parameter structure recovered by gradient descent. Theorem 4.2 shows training yields $W^{(t)}=\\operatorname{diag}(\\alpha^{(t)}I_d,0,\\beta^{(t)}I_{N+1})$, where $\\alpha^{(t)}\\to\\infty$ and $\\beta^{(t)}/\\alpha^{(t)}\\to-2$. This structure implements an attention rule that selects the context vector $(x_{\\pi(k)}^\\top,y_{\\pi(k)},p_{\\pi(k)}^\\top)^\\top$ of the nearest unselected neighbor, including its positional component. \n\nAt test time, given the initial input embedding matrix, the first step identifies $\\pi(1)$ through attention and selects its entire context vector; the generated state is then used to select the vector corresponding to $\\pi(2)$, and this process continues autoregressively. Thus, neither the target vector nor the indices $\\pi(k)$ are required to be known at test time. Lemma 3.3 formalizes this autoregressive rollout using the model’s own generated states.\n\n**Q3**. Does the joint training converge at the same rate as fixed-$V$ training?\n\n**A7.** The following table reports the training losses after 10000 iterations for joint $W,V$ training and fixed-$V$ training under the same experimental setup as in the paper.\n\n|$(N,d)$|$(20,5)$|$(20,10)$|$(40,10)$|$(40,20)$|\n|:-:|-:|-:|-:|-:|\n|Joint Train|0.084868|0.105870|0.135849|0.161082|\n|Fixed Train|0.069993|0.078814|0.117389|0.139270|\n\nJoint training consistently gives slightly higher training loss than fixed-$V$ training under the same setup, suggesting slightly slower convergence. Intuitively, fixed-$V$ training starts from the correct value-projection structure, whereas joint training must first identify the appropriate pattern of $V$ while optimizing $W$. After $V$ approaches the theoretical construction, the subsequent optimization behavior becomes similar to the fixed-$V$ case.\n\n**Q4**. Tightness/lower bound on the CoT steps?\n\n**A8.** Proposition 2.2 provides a weak lower bound: for odd $K>1$, the one-layer transformer considered in our paper cannot uniformly solve $K$-NN through direct single-pass inference. Thus, zero CoT steps are insufficient in this setting.\n\nTo our knowledge, a general lower bound on the CoT length is currently unknown. Determining whether $K-1$ is tight, or whether a different CoT mechanism can achieve sublinear reasoning length, is an interesting direction for future work.\n\n**References:**\n\n[1] Positional description matters for transformers arithmetic. ArXiv 2023\n\n[2] Transformers Provably Learn Sparse Token Selection While Fully-Connected Nets Cannot. ICML 2024\n\n[3] Multi-head Transformers Provably Learn Symbolic Multi-step Reasoning via Gradient Descent. NeurIPS 2025\n\n[4] One-Layer Transformer Provably Learns One-Nearest Neighbor In Context. NeurIPS 2024\n\n[5] Can Looped Transformers Learn to Implement Multi-step Gradient Descent for In-context Learning? ICML 2024\n\n[6] How transformers learn diverse attention correlations in masked vision pretraining. ICML 2024 Workshop"
+ },
+ "createdAt": "2026-07-28T10:26:15.615Z",
+ "modifiedAt": "2026-11-18T17:20:39.185Z",
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ&noteId=uD5o0VPV0m",
+ "license": "CC-BY-4.0"
+}

reviews/openreview/krmf9rmzsj/notes/y8jxhm7sok.json added

+++ b/reviews/openreview/krmf9rmzsj/notes/y8jxhm7sok.json
@@ -0,0 +1,32 @@
+{
+ "schema": "review/1",
+ "id": "Y8jXHM7SOk",
+ "replyTo": null,
+ "kind": "review",
+ "invitation": "Official_Review",
+ "signature": "Reviewer ffVj",
+ "content": {
+ "summary": "This work studies one-layer Transformers in learning In-context K nearest neighbors by Chain-of-Thought. The authors show that one-layer Transformers can be constructed to solve KNN problems by CoT, while without CoT, they cannot. The authors also provide a convergence analysis of the population loss for one-layer Transformers trained by gradient descent. Experiments are conducted to verify the consistency between the construction and the convergence analysis.",
+ "contribution_type": "theory",
+ "strengths_and_weaknesses": "Strengths:\n\n1. The theoretical analysis is solid and impressive. The studied problem is a reasonable extension from 1-NN using ICL to K-NN using CoT. \n\n2. The paper is easy to follow and well-organized, from expressive power to convergence analysis. Figure 1 (b) verifies the constructed Transformer, which bridges the gap between the two parts of the analysis. \n\nWeaknesses:\n\n1. The experiments are only for one-layer Transformers together with the theoretical analysis. It may restrict the significance of this work. \n\n2. The setting of the stochastic positional encoding looks strange and requires motivation and explanation. I have a similar concern for the training based on the first-step target supervision. \n\n3. The convergence analysis only deals with limiting cases without a characterization of the required number of iterations. \n\nPlease see Questions for more details.",
+ "quality": 3,
+ "clarity": 3,
+ "significance": 2,
+ "originality": 3,
+ "questions": "1. Can your theoretical analysis be extended to multi-layer or multi-head Transformers?\n\n2. What happens if you use multi-layer or multi-head Transformers for training empirically? Will the results be different?\n\n3. Why do you consider stochastic positional encodings, which may differ between different training iterations if my understanding is correct (line 103)? Is there any existing theoretical work or practical setting that uses this formulation?\n\n4. The convergence analysis only characterizes when $t\\rightarrow \\infty$. Can you characterize the required number of iterations or the convergence rate?\n\n5. The authors seem to treat the supervision on the first-step target state vector (lines 66 and 205) as a contribution. However, how is it motivated by practice or existing works? I know in practice people may use the LAST-step as supervision, like the CoT-I in https://arxiv.org/pdf/2305.18869. This is somehow more reasonable since people care about the final output of reasoning. In your problem setting, the task will become whether we can learn the $K$-th nearest neighbor by learning the list of the first $K$ nearest neighbors. Can your analysis be extended to consider the last-step supervision?\n\n6. Can ICL learn K-NN empirically? Can you discuss the comparison between ICL and CoT in your problem setting empirically and theoretically?",
+ "limitations": "Yes.",
+ "rating": 4,
+ "confidence": 4,
+ "ethical_concerns": [
+ "NO or VERY MINOR ethics concerns only"
+ ],
+ "paper_formatting_concerns": "N/A",
+ "code_of_conduct_acknowledgement": "Yes",
+ "responsible_reviewing_acknowledgement": "Yes",
+ "final_justification": "After the rebuttal, I think most of the concerns have been addressed. Although I still think supervising the first-step outcome for K-NN task is a little strange, I agree that this work has an additional theoretical contribution compared to [1], and this work especially characterizes the mechanism of selecting the relevant token and masking previously selected tokens. Therefore, I have increased my rating to 4.\n\n[1] One-Layer Transformer Provably Learns One-Nearest Neighbor In Context. NeurIPS 2024"
+ },
+ "createdAt": "2026-06-28T17:30:49.525Z",
+ "modifiedAt": "2026-11-18T13:44:35.104Z",
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ&noteId=Y8jXHM7SOk",
+ "license": "CC-BY-4.0"
+}

reviews/openreview/krmf9rmzsj/submission.json added

+++ b/reviews/openreview/krmf9rmzsj/submission.json
@@ -0,0 +1,12 @@
+{
+ "schema": "submission/1",
+ "id": "KRMF9RmzSJ",
+ "venue": {
+ "id": "NeurIPS.cc/2026/Conference",
+ "name": "NeurIPS 2026",
+ "url": "https://openreview.net/group?id=NeurIPS.cc%2F2026%2FConference"
+ },
+ "number": 30429,
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ",
+ "license": "CC-BY-4.0"
+}

versions/v_6jum9ggy.json added

+++ b/versions/v_6jum9ggy.json
@@ -0,0 +1,22 @@
+{
+ "date": "2026-05-05",
+ "kind": "submitted",
+ "label": "NeurIPS 2026",
+ "submissions": [
+ {
+ "venue": "NeurIPS 2026",
+ "status": "accepted",
+ "decision": "Accept (poster)",
+ "number": 30429,
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ",
+ "reviews": "openreview/krmf9rmzsj",
+ "evidence": [
+ "https://openreview.net/forum?id=KRMF9RmzSJ"
+ ]
+ }
+ ],
+ "url": "https://openreview.net/forum?id=KRMF9RmzSJ",
+ "evidence": [
+ "https://openreview.net/forum?id=KRMF9RmzSJ"
+ ]
+}