Pith. sign in

REVIEW 4 major objections 4 minor 28 references

Failures Are the Stepping Stones to Success: Enhancing Few-Shot In-Context Learning by Leveraging Negative Samples

T0 review · 4 major / 4 minor · reviewed 2026-08-06 · deepseek-v4-flash

Pith's one-line read Using the examples a model gets wrong to choose the correct ones improves few-shot in-context learning.

desk verdict Genuinely new idea—negative examples as anchors for positive demonstration retrieval—but the experiments miss the control that would prove the mechanism, so treat the empirical claim as suggestive, not established. read the letter →

arxiv 2507.23211 v1 pith:P6RX4H7O submitted 2025-07-31 cs.CL

classification cs.CL
keywords few-shotin-contextlearningnegativesamplesdemonstrationretrievalsemanticsimilaritychain-of-thoughtpromptengineeringerrorcorrectionreasoningtasks
verification ladder T0 review T1 audit T2 compute T3 formal

The pith

A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.

The reading

This paper tries to establish that the examples a language model answers incorrectly are not wasted context: they can be used to choose the correct examples that make up a few-shot prompt. The proposed method splits a dataset into positive and negative corpora by running zero-shot chain-of-thought over half the data, then for each test question retrieves similar examples from both corpora. It then treats each retrieved negative example as an anchor and fetches the most similar positive example, concatenating these newly retrieved positives with the query-similar positives as the final demonstrations. Across seven datasets spanning arithmetic, commonsense, and symbolic reasoning, this construction reports higher accuracy than using only the most similar positive examples. The paper's claim is that the wrong answer closest to a question carries information about the specific error the question invites, and that the correct example closest to that wrong answer supplies the corresponding correction.

What carries the argument

The central mechanism is two-hop semantic retrieval with negative samples as anchors. A negative sample is an example the model answered incorrectly, determined by running Zero-Shot-CoT on half of each k-means cluster and comparing the prediction with the gold answer; the rest of the pipeline uses Sentence-BERT embeddings for similarity. For a query, the first hop selects $k/2$ examples from the positive corpus and $k/2$ from the negative corpus by embedding distance. The second hop takes each selected negative example and retrieves the single most similar positive example from the positive corpus, on the view that the correct answer to a near-miss question is an implicit error-correction exercise. The final demonstration concatenates the first-hop positives and the negative-anchored positives.

What would settle it

Run the same two-hop retrieval with each negative anchor replaced by a random incorrect example of equal similarity to the query; if accuracy does not drop, the effect is due to an extra retrieval hop rather than to the negative sample's content. A second check is to compare against a single-hop baseline that retrieves the same number of positives directly by query similarity at a larger $k$; if that matches the two-hop results, the negative anchor adds nothing beyond more demonstration slots.

Watch

Extended reading notes

Core claim

The paper claims that a demonstration constructed by a two-hop similarity search over a corpus of answered examples outperforms demonstrations built only from the most similar correct examples. In the first hop, the query retrieves its nearest positive and negative examples; in the second hop, each negative example retrieves its own nearest positive from the positive corpus. The final prompt contains the first-hop positives plus these new negative-anchored positives. The best variant, which retrieves two negatives and then two new positives anchored on them, scores 84.1 on SVAMP, 75.9 on CommonsenseQA, 67.2 on StrategyQA, and 83.3 on Last Letter, all above the corresponding similarity-few-shot baselines, and the mixed one-positive-one-new-positive variant beats the baseline on the three arithmetic datasets and on Last Letter. The authors interpret this as evidence that negative samples improve in-context learning by improving positive-sample selection rather than by adding in-context contrastive warnings.

Load-bearing premise

The method assumes that a wrong example that is semantically close to the query is close because it shares the query's specific error pattern, and that the correct example nearest to that wrong example therefore teaches the model how to fix that specific mistake.

Editorial extensions

If this is right

  • If the claim holds, negative examples are informational assets for demonstration construction, so future few-shot retrievers can mine both correct and incorrect corpora instead of ignoring failures.
  • The task-dependent optimum found in the paper suggests that arithmetic and symbolic reasoning want a small dose of error-anchored positives, whereas commonsense reasoning works best when every demonstration is an error-anchored positive.
  • Since the method only needs zero-shot inference and a sentence embedding model, any unlabeled task set can be turned into positive and negative corpora without human annotation.
  • The two-stage design removes the need for an explicit error-correction step from a stronger model; retrieval itself supplies the correction.

Reading between the lines

Editorial extensions of the paper, not claims the author makes directly.

  • A control the paper does not run would test whether the improvement comes specifically from negative information rather than from the extra retrieval step: replace each negative anchor with a randomly chosen wrong example, or with a positive anchor, and compare accuracy.
  • If error types cluster, then the second hop should retrieve positives that fix a specific failure; one testable consequence is that clustering the negative corpus by predicted-error category and requiring retrieval to stay within the same category would tighten the corrections and might further lift accuracy.
  • The authors' 'semantic drift' explanation for too many negatives predicts a monotone decline in the relevance of second-hop positives as the number of anchors grows, which could be measured directly with embedding distance between anchors and retrieved positives.
  • A further extension would apply the same negative-anchored retrieval to larger demonstration counts and to open-source models, to see whether the gains persist outside the single model and $k=2$ setting used here.
Share X Bluesky LinkedIn Reddit HN

Editorial analysis

A structured set of objections, weighed in public.

Desk editor's note, referee report, and a circularity audit.

Referee Report

4 major / 4 minor

Summary. The paper proposes a two-stage method for few-shot in-context learning in which negative samples (incorrectly answered examples) are used as semantic anchors to retrieve additional positive examples. The authors first build positive and negative corpora by running Zero-Shot-CoT on a clustered subset of the training data, then at inference retrieve k/2 query-similar positives and k/2 query-similar negatives, and for each negative retrieve the most similar positive from the positive corpus. The final prompt concatenates the query-similar positives and the negatively-anchored positives. Experiments on seven datasets over arithmetic, commonsense, and symbolic reasoning with GPT-3.5-Turbo are reported in Tables 1 and 2, with the stated conclusion that negative samples improve demonstration selection.

Significance. If the central claim is correct, the paper offers a simple, API-compatible method for improving few-shot ICL without additional training or stronger models, and it would be one of the few demonstrations that incorrect examples carry usable corrective signal for demonstration selection. The manuscript is clearly written, the method is easy to reproduce from the description, and Table 2 makes an initial attempt to study the number of negative anchors. However, the empirical support is currently suggestive rather than conclusive: the central mechanism is not isolated by any control, the headline 'consistently superior' claim is contradicted by several reported numbers, and no variance estimates are given. The significance is therefore conditional on the missing control experiments being added and the claims being appropriately qualified.

major comments (4)
  1. [§2.2 and Tables 1–2] The central claim that negative-sample information drives the gains is not isolated by the experimental design. The proposed method is a two-hop retriever whose intermediate anchors are negative examples, but no control replaces those anchors with equally query-similar positive examples while keeping the two-hop architecture. If such a control matches Ours(2 pos-new), the observed improvements could be caused by the second retrieval hop or by increased demonstration diversity rather than by error-related information in negative samples. The m=0, n=6 row in Table 2 (e.g., 80.0 on CommonsenseQA) makes this concern concrete, because it removes query-similar positives entirely and still performs well.
  2. [§3.2, Table 1] The statement that the proposed approach 'consistently achieves superior performance compared to all baseline methods across all seven datasets' is contradicted by the reported numbers: Ours(1 pos-new) is below Random Few-Shot on CommonsenseQA (75.2 vs 75.7) and below Similarity Few-Shot on CommonsenseQA (75.2 vs 75.6); Ours(2 pos-new) is below Random Few-Shot on AddSub (83.6 vs 85.5) and on GSM8K (77.4 vs 77.7). The claim should be restricted to the best variant per dataset and properly qualified.
  3. [§3.2, Tables 1 and 2] No variance estimates, repeated runs, or significance tests are reported anywhere. Many of the differences are small in absolute terms (e.g., 75.9 vs 75.6 on CommonsenseQA, 83.6 vs 83.0 on AddSub in Table 1), so without error bars it is not possible to determine whether the gains are reliable. This is load-bearing because the paper's headline conclusion is an empirical superiority claim.
  4. [§3.2, Table 2] The analysis in Table 2 conflates the number of negative anchors with the composition of the final demonstration set. In rows such as m=0, n=6, the demonstrations contain only second-hop positives and no query-similar first-hop positives, so comparisons across rows change both the anchor type and the final prompt composition. The interpretation that 'using too many negative examples leads to a performance decline' is therefore not directly supported by the table, because the n=6 condition also removes all first-hop query-similar positives.
minor comments (4)
  1. [§3.1] There are several typographical errors that should be fixed: 'Similarty-Based Few-Shot CoT' should be 'Similarity-Based Few-Shot CoT', Table 2's header 'ComonSenseQA' should be 'CommonsenseQA', and Figure 2 contains 'Postive Example' and 'Tset Question'.
  2. [Figure 1] Figure 1 and the surrounding text contain garbled or illegible character sequences that appear to be a rendering artifact; these should be repaired before publication.
  3. [References] References [3] and [4] are the same arXiv paper (2310.20689) listed twice; they should be consolidated.
  4. [§3.1] The choices of cluster counts (4, 6, 8, 10 for different datasets) and the fixed k=2 are introduced without justification; a brief sentence on why these values were chosen, or a sensitivity check, would strengthen the presentation.

Circularity Check

0 steps flagged · score 0.0 of 10

No significant circularity: the claimed gains are empirical measurements, and no load-bearing step reduces to its own input by definition or self-citation.

full rationale

The paper's central claim is an empirical result, not a derivation: Table 1 reports accuracy on held-out test portions of seven datasets. The method constructs demonstrations by clustering and splitting the data, using Zero-Shot-CoT to label positives and negatives on the training portion, retrieving query-similar positives and negatives, then retrieving a second set of positives most similar to those negatives. None of the seven circularity patterns applies. A 'negative sample' is defined by prediction-gold mismatch, not by the outcome being explained, so there is no self-definitional loop. No fitted parameter is renamed as a prediction: the only 'parameters' are k and cluster counts, and the result is a direct measurement rather than a quantity forced by the fit. The two self-citations ([13] and [14]) appear as background examples of LLM applications and are not load-bearing for the negative-sample claim. No uniqueness theorem is imported from the authors' prior work, and no ansatz is smuggled in via citation; the method is explicitly proposed in this paper. The absence of an anchor-type control (e.g., two-hop retrieval with equally query-similar positive anchors) is a legitimate experimental-design limitation, but it is not circularity: the conclusion that negative-sample information drives the gain is not guaranteed by construction. The negative corpus being produced by the same model family is part of the proposed procedure, not a circular justification. Thus the appropriate finding is no significant circularity.

Assumptions & free parameters 4 free parameters · 4 assumptions · 0 invented entities

The method's effectiveness rests on several unvalidated assumptions about semantic similarity and error transfer. Free parameters (k, cluster counts, split ratio, and post-hoc optimal m/n) are hand-set or selected on test data; none are justified by sensitivity analysis. No invented entities are introduced.

free parameters (4)
  • k (number of demonstrations) = 2
    Set to 2 because of API pricing, not tuned or justified; all main results use k=2.
  • Cluster count per dataset = AddSub 4, SingleEq 4, Last Letter 4, GSM8K 8, CommonsenseQA 8, SVAMP 6, StrategyQA 10
    Chosen by hand based on dataset size; no selection criterion or sensitivity analysis is reported.
  • Train/test split ratio = 1/2 per cluster
    Randomly half of each cluster is used for the corpus; no justification or ablation for the split ratio.
  • m and n counts in Table 2 = Per-dataset optimal chosen post hoc, e.g., AddSub m=5,n=1; Last Letter m=4,n=2; CommonsenseQA m=0,n=6
    The analysis selects the best number of negative anchors on the test set and reports task-specific recommendations without held-out validation.
assumptions (4)
  • domain assumption Semantic similarity in Sentence-BERT embedding space is a valid proxy for demonstration usefulness for the query.
    Used throughout Section 2.2 to select both positive and negative examples and to anchor new-positive retrieval; no validation or calibration is provided.
  • domain assumption The LLM's incorrect predictions on the training half are informative signals about which test queries will be hard, i.e., error patterns transfer.
    The method builds negative corpora from zero-shot CoT errors and assumes those negatives serve as anchors to correct similar test queries.
  • domain assumption The random half-split per k-means cluster yields a corpus representative enough for retrieval.
    Section 2.1; if clusters are not semantically coherent or the split is unlucky, retrieved items may be irrelevant.
  • domain assumption Zero-shot-CoT with the answer-cleaning technique from Kojima et al. produces reliable positive/negative labels without human annotation.
    The whole corpus construction depends on this labeling being accurate enough for the positive and negative pools.

how reviews work

0 comments
Cite this review

Pith. "Pith review of Failures Are the Stepping Stones to Success: Enhancing Few-Shot In-Context Learning by Leveraging Negative Samples." pith.science (2026). https://pith.science/paper/P6RX4H7O

@misc{pith2026250723211,
  author       = {Pith},
  title        = {Pith review of: Failures Are the Stepping Stones to Success: Enhancing Few-Shot In-Context Learning by Leveraging Negative Samples},
  year         = {2026},
  howpublished = {\url{https://pith.science/paper/P6RX4H7O}},
  note         = {Machine review of arXiv:2507.23211}
}
read the original abstract

Large Language Models exhibit powerful few-shot in-context learning (ICL) capabilities, but the performance is highly sensitive to provided examples. Recent research has focused on retrieving corresponding examples for each input query, not only enhancing the efficiency and scalability of the learning process but also mitigating inherent biases in manual example selection. However, these studies have primarily emphasized leveraging Positive samples while overlooking the additional information within Negative samples for contextual learning. We propose a novel method that utilizes Negative samples to better select Positive sample examples, thereby enhancing the performance of few-shot ICL. Initially, we construct Positive and Negative sample corpora based on Zero-Shot-Cot. Then, during inference, we employ a semantic similarity-based approach to select the most similar examples from both the Positive and Negative corpora for a given query. Subsequently, we further retrieve Positive examples from the Positive sample corpus based on semantic similarity to the Negative examples, then concatenating them with the previously selected Positive examples to serve as ICL demonstrations. Experimental results demonstrate that our approach surpasses methods solely relying on the most similar positive examples for context, validating that the additional information in negative samples aids in enhancing ICL performance through improved Positive sample selection.

Figures

Figures reproduced from arXiv: 2507.23211 by the authors.

Figure 1
Figure 1. The process of corpus construction. 2.2 Negative samples enhance demonstrations construction [PITH_FULL_IMAGE:figures/full_fig_p003_1.png] view at source ↗
Figure 2
Figure 2. The process of constructing demonstrations with the aid of negative samples. 3 Experiments And Results 3.1 Experimental Setup Tasks and Datasets. Our proposed approach was assessed across seven benchmark datasets, corresponding to three different reasoning tasks: arithmetic reasoning, common sense reasoning, and symbolic reasoning. The datasets AddSub [8], GSM8K [6], SingleEq [10], and SVAMP [18] were utilized for t… view at source ↗

Discussion (0). Sign in to comment.

Reference graph

Works this paper leans on

28 extracted references · 15 canonical work pages

  1. [1]

    arXiv preprint arXiv:2212.02437 (2022)

    Agrawal, S., Zhou, C., Lewis, M., Zettlemoyer, L., Ghazvi ninejad, M.: In-context examples selection for machine translation. arXiv preprint arXiv:2212.02437 (2022)

  2. [2]

    In: Findings of the Asso ciation for Computational Linguistics: EMNLP 2024

    An, S., Ma, Z., Cai, S., Lin, Z., Zheng, N., Lou, J.G., Chen, W.: Can llms learn from mistakes? an empirical study on reasoning tasks. In: Findings of the Asso ciation for Computational Linguistics: EMNLP 2024. pp. 833–854 (2024)

  3. [4]

    arXiv preprint arXiv:2310.20689 (2023)

    An, S., Ma, Z., Lin, Z., Zheng, N., Lou, J.G., Chen, W.: Lear ning from mistakes makes llm better reasoner. arXiv preprint arXiv:2310.20689 (2023)

  4. [5]

    arXiv pr eprint arXiv:2211.12588 (2022)

    Chen, W., Ma, X., Wang, X., Cohen, W.W.: Program of thought s prompting: Disentangling computa- tion from reasoning for numerical reasoning tasks. arXiv pr eprint arXiv:2211.12588 (2022)

  5. [6]

    arXiv preprint arXiv:2110.14168 (2021)

    Cobbe, K., Kosaraju, V., Bavarian, M., Chen, M., Jun, H., K aiser, L., Plappert, M., Tworek, J., Hilton, J., Nakano, R., et al.: Training verifiers to solve math word p roblems. arXiv preprint arXiv:2110.14168 (2021)

  6. [7]

    T ransactions of the Association for Computa- tional Linguistics 9, 346–361 (2021)

    Geva, M., Khashabi, D., Segal, E., Khot, T., Roth, D., Bera nt, J.: Did aristotle use a laptop? a question answering benchmark with implicit reasoning strategies. T ransactions of the Association for Computa- tional Linguistics 9, 346–361 (2021)

  7. [8]

    : Learning to solve arithmetic word problems with verb categorization

    Hosseini, M.J., Hajishirzi, H., Etzioni, O., Kushman, N. : Learning to solve arithmetic word problems with verb categorization. In: Proceedings of the 2014 confe rence on empirical methods in natural lan- guage processing (EMNLP). pp. 523–533 (2014)

  8. [9]

    Advances in neural information processing systems 35, 22199–22213 (2022) Title Suppressed Due to Excessive Length 9

    Kojima, T., Gu, S.S., Reid, M., Matsuo, Y., Iwasawa, Y.: La rge language models are zero-shot reasoners. Advances in neural information processing systems 35, 22199–22213 (2022) Title Suppressed Due to Excessive Length 9

Show all 28 references
  1. [10]

    Transactions of the Association f or Computational Linguistics 3, 585–597 (2015)

    Koncel-Kedziorski, R., Hajishirzi, H., Sabharwal, A., Etzioni, O., Ang, S.D.: Parsing algebraic word problems into equations. Transactions of the Association f or Computational Linguistics 3, 585–597 (2015)

  2. [11]

    CoRR (2023)

    Li, X., Qiu, X.: Mot: Pre-thinking and recalling enable c hatgpt to self-improve with memory-of-thoughts. CoRR (2023)

  3. [12]

    In: Proceedings of the AAAI Conference on Artificial Intelligence

    Li, Y., Yuan, P., Feng, S., Pan, B., Sun, B., Wang, X., Wang , H., Li, K.: Turning dust into gold: Distilling complex reasoning capabilities from llms by lev eraging negative data. In: Proceedings of the AAAI Conference on Artificial Intelligence. vol. 38, pp. 185 91–18599 (2024)

  4. [13]

    In: International Conference on Intelligent Computing

    Liang, Y., Gan, C., Ying, R., Cui, Z.: Exploring behavior -driven development for code generation. In: International Conference on Intelligent Computing. pp. 41 –51. Springer (2025)

  5. [14]

    In: International Conference on Intelligent Computing

    Liang, Y., Ying, R., Taniguchi, T., Gan, C., Cui, Z.: Reco de: Leveraging reliable self-generated tests and fine-grained execution feedback to enhance llm-based co de generation. In: International Conference on Intelligent Computing. pp. 510–521. Springer (2025)

  6. [15]

    : Fantastically ordered prompts and where to find them: Overcoming few-shot prompt order sensitivity

    Lu, Y., Bartolo, M., Moore, A., Riedel, S., Stenetorp, P. : Fantastically ordered prompts and where to find them: Overcoming few-shot prompt order sensitivity. ar Xiv preprint arXiv:2104.08786 (2021)

  7. [16]

    icl: Demonstration-retrieved in-context learning

    Luo, M., Xu, X., Dai, Z., Pasupat, P., Kazemi, M., Baral, C ., Imbrasaite, V., Zhao, V.Y.: Dr. icl: Demonstration-retrieved in-context learning. arXiv prep rint arXiv:2305.14128 (2023)

  8. [17]

    arXiv pr eprint arXiv:2204.13074 (2022)

    Mishra, B.D., Tafjord, O., Clark, P.: Towards teachable reasoning systems: Using a dynamic memory of user feedback for continual system improvement. arXiv pr eprint arXiv:2204.13074 (2022)

  9. [18]

    Patel, A., Bhattamishra, S., Goyal, N.: Are nlp models re ally able to solve simple math word problems? arXiv preprint arXiv:2103.07191 (2021)

  10. [19]

    OpenAI blog 1(8), 9 (2019)

    Radford, A., Wu, J., Child, R., Luan, D., Amodei, D., Suts kever, I., et al.: Language models are unsupervised multitask learners. OpenAI blog 1(8), 9 (2019)

  11. [20]

    arXiv preprint arXiv:1908.10084 (2019)

    Reimers, N., Gurevych, I.: Sentence-bert: Sentence emb eddings using siamese bert-networks. arXiv preprint arXiv:1908.10084 (2019)

  12. [21]

    In: Extended abstracts of the 2021 CHI conference on human factors in computing systems

    Reynolds, L., McDonell, K.: Prompt programming for larg e language models: Beyond the few-shot paradigm. In: Extended abstracts of the 2021 CHI conference on human factors in computing systems. pp. 1–7 (2021)

  13. [22]

    arXiv preprint arXiv:2112.08633 (2021)

    Rubin, O., Herzig, J., Berant, J.: Learning to retrieve p rompts for in-context learning. arXiv preprint arXiv:2112.08633 (2021)

  14. [23]

    arXiv preprint arXiv:1811.00937 ( 2018)

    Talmor, A., Herzig, J., Lourie, N., Berant, J.: Commonse nseqa: A question answering challenge targeting commonsense knowledge. arXiv preprint arXiv:1811.00937 ( 2018)

  15. [24]

    arXiv preprint arXiv:2302.13971 (2023)

    Touvron, H., Lavril, T., Izacard, G., Martinet, X., Lach aux, M.A., Lacroix, T., Rozière, B., Goyal, N., Hambro, E., Azhar, F., et al.: Llama: Open and efficient founda tion language models. arXiv preprint arXiv:2302.13971 (2023)

  16. [25]

    arXiv preprint arXiv:2203.11171 (2022)

    Wang, X., Wei, J., Schuurmans, D., Le, Q., Chi, E., Narang , S., Chowdhery, A., Zhou, D.: Self- consistency improves chain of thought reasoning in languag e models. arXiv preprint arXiv:2203.11171 (2022)

  17. [26]

    ACM Transactions on Knowledge Discovery from Data 18(6), 1–32 (2024)

    Yang, J., Jin, H., Tang, R., Han, X., Feng, Q., Jiang, H., Z hong, S., Yin, B., Hu, X.: Harnessing the power of llms in practice: A survey on chatgpt and beyond. ACM Transactions on Knowledge Discovery from Data 18(6), 1–32 (2024)

  18. [27]

    In: Inter- national Conference on Machine Learning

    Ye, J., Wu, Z., Feng, J., Yu, T., Kong, L.: Compositional e xemplars for in-context learning. In: Inter- national Conference on Machine Learning. pp. 39818–39833. PMLR (2023)

  19. [28]

    Advances in neural information processing systems 35, 30378–30392 (2022)

    Ye, X., Durrett, G.: The unreliability of explanations i n few-shot prompting for textual reasoning. Advances in neural information processing systems 35, 30378–30392 (2022)

  20. [29]

    arXiv preprint arX iv:2303.18223 1(2) (2023)

    Zhao, W.X., Zhou, K., Li, J., Tang, T., Wang, X., Hou, Y., M in, Y., Zhang, B., Zhang, J., Dong, Z., et al.: A survey of large language models. arXiv preprint arX iv:2303.18223 1(2) (2023)

Pith tools

Reviewed August 6, 2026 · model on record in the stance chip above.