Is In-Context Learning in Large Language Models Bayesian? A Martingale Perspective
Not on the map. Why?
Abstract (arXiv)
In-context learning (ICL) has emerged as a particularly remarkable characteristic of Large Language Models (LLM): given a pretrained LLM and an observed dataset, LLMs can make predictions for new data points from the same distribution without fine-tuning. Numerous works have postulated ICL as approximately Bayesian inference, rendering this a natural hypothesis. In this work, we analyse this hypothesis from a new angle through the martingale property, a fundamental requirement of a Bayesian learning system for exchangeable data. We show that the martingale property is a necessary condition for unambiguous predictions in such scenarios, and enables a principled, decomposed notion of uncertainty vital in trustworthy, safety-critical systems. We derive actionable checks with corresponding theory and test statistics which must hold if the martingale property is satisfied. We also examine if uncertainty in LLMs decreases as expected in Bayesian learning when more data is observed. In three experiments, we provide evidence for violations of the martingale property, and deviations from a Bayesian scaling behaviour of uncertainty, falsifying the hypothesis that ICL is Bayesian.
Key facts. Cited by 51 papers in the map (data through 7 Oct 2026). Builds on 32 of its 55 references that are in the map. First posted on arXiv 2 Jun 2024.
Builds on
32 of 55 references.
References · 32
- 2020Language Models are Few-Shot Learnerscited by 32,199
- 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,160
- 2022Training language models to follow instructions with human feedbackcited by 15,712
- 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 12,865
- 2022Chain-of-Thought Prompting Elicits Reasoning in Large Language Modelscited by 12,302
- 2023Mistral 7Bcited by 3,065
- 2023A Survey of Large Language Modelscited by 2,537
- 2021Calibrate Before Use: Improving Few-Shot Performance of Language Modelscited by 1,371
- 2021Fantastically Ordered Prompts and Where to Find Them: Overcoming Few-Shot Prompt Order Sensitivitycited by 1,122
- 2021An Explanation of In-context Learning as Implicit Bayesian Inferencecited by 915
- 2023Time-LLM: Time Series Forecasting by Reprogramming Large Language Modelscited by 680
- 2022What learning algorithm is in-context learning? Investigations with linear modelscited by 671
20 more
- 2023Large Language Models Are Zero-Shot Time Series Forecasterscited by 491
- 2021MetaICL: Learning to Learn In Contextcited by 450
- 2023Transformers as Statisticians: Provable In-Context Learning with In-Context Algorithm Selectioncited by 291
- 2022Language Models are Realistic Tabular Data Generatorscited by 290
- 2023Does Synthetic Data Generation of LLMs Help Clinical Text Mining?cited by 151
- 2023Large Language Models Are Latent Variable Models: Explaining and Finding Good Demonstrations for In-Context Learningcited by 149
- 2023Pretraining task diversity and the emergence of non-Bayesian in-context learning for regressioncited by 138
- 2023Calibrated Language Models Must Hallucinatecited by 114
- 2023What and How does In-Context Learning Learn? Bayesian Model Averaging, Parameterization, and Generalizationcited by 112
- 2022Uncertainty Quantification with Pre-trained Language Models: A Large-Scale Empirical Analysiscited by 104
- 2023Synthetic Data Generation with Large Language Models for Text Classification: Potential and Limitationscited by 96
- 2023A Theory of Emergent In-Context Learning as Implicit Structure Inductioncited by 86
- 2023In-Context Learning through the Bayesian Prismcited by 78
- 2023The Transient Nature of Emergent In-Context Learning in Transformerscited by 72
- 2024Making Pre-trained Language Models Great on Tabular Predictioncited by 56
- 2021Martingale posterior distributionscited by 43
- 2023A Latent Space Theory for Emergent Abilities in Large Language Modelscited by 42
- 2023Generating Faithful Synthetic Data with Large Language Models: A Case Study in Computational Social Sciencecited by 37
- 2023Language models are weak learnerscited by 21
- 2023Deep de Finetti: Recovering Topic Distributions from Large Language Modelscited by 7
Built on by
Citing papers per year: 2024: 8; 2025: 21; 2026: 22.
51 papers.
Sort:
By area:
- 2025Plan and Budget: Effective and Efficient Test-Time Scaling on Reasoning Large Language Modelscited by 30
- 2025BED-LLM: Intelligent Information Gathering with LLMs and Bayesian Experimental Designcited by 21
- 2024Estimating the Hallucination Rate of Generative AIcited by 20
- 2025Enough Coin Flips Can Make LLMs Act Bayesiancited by 19
- 2025Position: The Future of Bayesian Prediction Is Prior-Fittedcited by 19
- 2024Bayesian scaling laws for in-context learningcited by 18
- 2024Bayesian Concept Bottleneck Models with LLM Priorscited by 16
- 2024AutoElicit: Using Large Language Models for Expert Prior Elicitation in Predictive Modellingcited by 15
- 2024Everything Everywhere All at Once: LLMs can In-Context Learn Multiple Tasks in Superpositioncited by 13
- 2025Are Large Language Models Reliable AI Scientists? Assessing Reverse-Engineering of Black-Box Systemscited by 13
- 2025Probabilistic operator learning: generative modeling and uncertainty quantification for foundation models of differential equationscited by 9
- 2026Agentic Forecasting using Sequential Bayesian Updating of Linguistic Beliefscited by 9
38 more
- 2024Transformers Handle Endogeneity in In-Context Linear Regressioncited by 8
- 2026From Zero to Hero: Advancing Zero-Shot Foundation Models for Tabular Outlier Detectioncited by 8
- 2025TabMGP: Martingale Posterior with TabPFNcited by 6
- 2025Martingale Score: An Unsupervised Metric for Bayesian Rationality in LLM Reasoningcited by 5
- 2025In-Context Parametric Inference: Point or Distribution Estimators?cited by 4
- 2025Uncertainty Quantification for Prior-Data Fitted Networks using Martingale Posteriorscited by 4
- 2025Counterfactual reasoning: an analysis of in-context emergencecited by 4
- 2025Provable In-Context Learning of Nonlinear Regression with Transformerscited by 4
- 2026Verbalizing LLM's Higher-order Uncertainty via Imprecise Probabilitiescited by 4
- 2024DeFine: Decision-Making with Analogical Reasoning over Factor Profilescited by 3
- 2025The Initialization Determines Whether In-Context Learning Is Gradient Descentcited by 3
- 2026Rethinking Zero-Shot Time Series Classification: From Task-specific Classifiers to In-Context Inferencecited by 3
- 2026Position: agentic AI orchestration should be Bayes-consistentcited by 3
- 2026VIP-COP: Context Optimization for Tabular Foundation Modelscited by 3
- 2024Can Generative AI Solve Your In-Context Learning Problem? A Martingale Perspectivecited by 2
- 2025Architectural and Inferential Inductive Biases For Exchangeable Sequence Modelingcited by 2
- 2025From predictions to confidence intervals: an empirical study of conformal prediction methods for in-context learningcited by 2
- 2025Predictable Compression Failures: Order Sensitivity and Information Budgeting for Evidence-Grounded Binary Adjudicationcited by 2
- 2025Evaluating the Use of Large Language Models as Synthetic Social Agents in Social Science Researchcited by 2
- 2026From Drift to Coherence: Stabilizing Beliefs in LLMscited by 2
- 2026Partition, Prompt, Aggregate: Statistical Self-Consistency in Language Modelscited by 2
- 2025Semantic Anchors in In-Context Learning: Why Small LLMs Cannot Flip Their Labelscited by 1
- 2026Hallucination-Resistant Security Planning with a Large Language Modelcited by 1
- 2026Learning to Remember, Learn, and Forget in Attention-Based Modelscited by 1
- 2026Reasonably reasoning AI agents can avoid game-theoretic failures in zero-shot, provablycited by 1
- 2026Can AI Scientist Agents Learn from Lab-in-the-Loop Feedback? Evidence from Iterative Perturbation Discoverycited by 1
- 2026What does a Bayes-filtered transformer believe? A predictive Monte Carlo approachcited by 1
- 2025Exploring Imbalanced Annotations for Effective In-Context Learningcited by 0
- 2025LLMs are Bayesian, In Expectation, Not in Realizationcited by 0
- 2025Aligning Probabilistic Beliefs under Informative Missingness: LLM Steerability in Clinical Reasoningcited by 0
- 2026In-Context Function Learning in Large Language Modelscited by 0
- 2026Toward Privileged Foundation Models:LUPI for Accelerated and Improved Learningcited by 0
- 2026Variational predictive resamplingcited by 0
- 2026Quantifying Aleatoric Uncertainty of In-Context Learning for Robust Measure of LLM Prediction Confidencecited by 0
- 2026Can In-Context Learning Support Intrinsic Curiosity?cited by 0
- 2026Bayesian Intelligence from the Outsidecited by 0
- 2026Small transformers track Bayesian evidence for latent common causes via a context-invariant mechanismcited by 0
- 2026Diagnosing and Improving Probabilistic Reasoning in Large Language Modelscited by 0
50 most cited of 51 All 51 (JSON)
- 2026Bayesian Fine-tuning Yields Language Models that are as Bayesian as their Beliefs Allow30 Sep 2026
- 2026Diagnosing and Improving Probabilistic Reasoning in Large Language Models29 Sep 2026
- 2026Small transformers track Bayesian evidence for latent common causes via a context-invariant mechanism28 Sep 2026
- 2026Bayesian Intelligence from the Outside13 Sep 2026
- 2026What does a Bayes-filtered transformer believe? A predictive Monte Carlo approach19 Jul 2026
- 2026Partition, Prompt, Aggregate: Statistical Self-Consistency in Language Models16 Jul 2026
- 2026Can In-Context Learning Support Intrinsic Curiosity?17 Jun 2026
- 2026From Drift to Coherence: Stabilizing Beliefs in LLMs16 Jun 2026
- 2026VIP-COP: Context Optimization for Tabular Foundation Models13 May 2026
- 2026Variational predictive resampling11 May 2026
- 2026Toward Privileged Foundation Models:LUPI for Accelerated and Improved Learning8 May 2026
- 2026Position: agentic AI orchestration should be Bayes-consistent1 May 2026
38 more
- 2026Quantifying Aleatoric Uncertainty of In-Context Learning for Robust Measure of LLM Prediction Confidence28 Apr 2026
- 2026Agentic Forecasting using Sequential Bayesian Updating of Linguistic Beliefs20 Apr 2026
- 2026Can AI Scientist Agents Learn from Lab-in-the-Loop Feedback? Evidence from Iterative Perturbation Discovery27 Mar 2026
- 2026Reasonably reasoning AI agents can avoid game-theoretic failures in zero-shot, provably19 Mar 2026
- 2026Verbalizing LLM's Higher-order Uncertainty via Imprecise Probabilities11 Mar 2026
- 2026In-Context Function Learning in Large Language Models12 Feb 2026
- 2026Learning to Remember, Learn, and Forget in Attention-Based Models9 Feb 2026
- 2026Hallucination-Resistant Security Planning with a Large Language Model5 Feb 2026
- 2026From Zero to Hero: Advancing Zero-Shot Foundation Models for Tabular Outlier Detection3 Feb 2026
- 2026Rethinking Zero-Shot Time Series Classification: From Task-specific Classifiers to In-Context Inference31 Jan 2026
- 2025The Initialization Determines Whether In-Context Learning Is Gradient Descent3 Dec 2025
- 2025Martingale Score: An Unsupervised Metric for Bayesian Rationality in LLM Reasoning2 Dec 2025
- 2025Aligning Probabilistic Beliefs under Informative Missingness: LLM Steerability in Clinical Reasoning29 Nov 2025
- 2025Semantic Anchors in In-Context Learning: Why Small LLMs Cannot Flip Their Labels26 Nov 2025
- 2025TabMGP: Martingale Posterior with TabPFN29 Oct 2025
- 2025Evaluating the Use of Large Language Models as Synthetic Social Agents in Social Science Research30 Sep 2025
- 2025Predictable Compression Failures: Order Sensitivity and Information Budgeting for Evidence-Grounded Binary Adjudication14 Sep 2025
- 2025Probabilistic operator learning: generative modeling and uncertainty quantification for foundation models of differential equations5 Sep 2025
- 2025BED-LLM: Intelligent Information Gathering with LLMs and Bayesian Experimental Design28 Aug 2025
- 2025Provable In-Context Learning of Nonlinear Regression with Transformers28 Jul 2025
- 2025LLMs are Bayesian, In Expectation, Not in Realization15 Jul 2025
- 2025Counterfactual reasoning: an analysis of in-context emergence5 Jun 2025
- 2025Position: The Future of Bayesian Prediction Is Prior-Fitted29 May 2025
- 2025Are Large Language Models Reliable AI Scientists? Assessing Reverse-Engineering of Black-Box Systems23 May 2025
- 2025Plan and Budget: Effective and Efficient Test-Time Scaling on Reasoning Large Language Models22 May 2025
- 2025Uncertainty Quantification for Prior-Data Fitted Networks using Martingale Posteriors16 May 2025
- 2025From predictions to confidence intervals: an empirical study of conformal prediction methods for in-context learning22 Apr 2025
- 2025Enough Coin Flips Can Make LLMs Act Bayesian6 Mar 2025
- 2025Architectural and Inferential Inductive Biases For Exchangeable Sequence Modeling3 Mar 2025
- 2025In-Context Parametric Inference: Point or Distribution Estimators?17 Feb 2025
- 2025Exploring Imbalanced Annotations for Effective In-Context Learning6 Feb 2025
- 2024Can Generative AI Solve Your In-Context Learning Problem? A Martingale Perspective8 Dec 2024
- 2024AutoElicit: Using Large Language Models for Expert Prior Elicitation in Predictive Modelling26 Nov 2024
- 2024Bayesian scaling laws for in-context learning21 Oct 2024
- 2024Bayesian Concept Bottleneck Models with LLM Priors21 Oct 2024
- 2024Everything Everywhere All at Once: LLMs can In-Context Learn Multiple Tasks in Superposition8 Oct 2024
- 2024DeFine: Decision-Making with Analogical Reasoning over Factor Profiles2 Oct 2024
- 2024Transformers Handle Endogeneity in In-Context Linear Regression2 Oct 2024
50 newest of 51 All 51 (JSON)
- 2025Plan and Budget: Effective and Efficient Test-Time Scaling on Reasoning Large Language Modelscited by 30
- 2025Martingale Score: An Unsupervised Metric for Bayesian Rationality in LLM Reasoningcited by 5
- 2025Counterfactual reasoning: an analysis of in-context emergencecited by 4
- 2024DeFine: Decision-Making with Analogical Reasoning over Factor Profilescited by 3
- 2026Partition, Prompt, Aggregate: Statistical Self-Consistency in Language Modelscited by 2
- 2026Reasonably reasoning AI agents can avoid game-theoretic failures in zero-shot, provablycited by 1
- 2025Aligning Probabilistic Beliefs under Informative Missingness: LLM Steerability in Clinical Reasoningcited by 0
- 2026Diagnosing and Improving Probabilistic Reasoning in Large Language Modelscited by 0
- 2026Diagnosing and Improving Probabilistic Reasoning in Large Language Models29 Sep 2026
- 2026Partition, Prompt, Aggregate: Statistical Self-Consistency in Language Models16 Jul 2026
- 2026Reasonably reasoning AI agents can avoid game-theoretic failures in zero-shot, provably19 Mar 2026
- 2025Martingale Score: An Unsupervised Metric for Bayesian Rationality in LLM Reasoning2 Dec 2025
- 2025Aligning Probabilistic Beliefs under Informative Missingness: LLM Steerability in Clinical Reasoning29 Nov 2025
- 2025Counterfactual reasoning: an analysis of in-context emergence5 Jun 2025
- 2025Plan and Budget: Effective and Efficient Test-Time Scaling on Reasoning Large Language Models22 May 2025
- 2024DeFine: Decision-Making with Analogical Reasoning over Factor Profiles2 Oct 2024
- 2026Agentic Forecasting using Sequential Bayesian Updating of Linguistic Beliefscited by 9
- 2026Position: agentic AI orchestration should be Bayes-consistentcited by 3
- 2025Evaluating the Use of Large Language Models as Synthetic Social Agents in Social Science Researchcited by 2
- 2026Can AI Scientist Agents Learn from Lab-in-the-Loop Feedback? Evidence from Iterative Perturbation Discoverycited by 1
- 2026Position: agentic AI orchestration should be Bayes-consistent1 May 2026
- 2026Agentic Forecasting using Sequential Bayesian Updating of Linguistic Beliefs20 Apr 2026
- 2026Can AI Scientist Agents Learn from Lab-in-the-Loop Feedback? Evidence from Iterative Perturbation Discovery27 Mar 2026
- 2025Evaluating the Use of Large Language Models as Synthetic Social Agents in Social Science Research30 Sep 2025
- 2024Bayesian scaling laws for in-context learningcited by 18
- 2024Bayesian scaling laws for in-context learning21 Oct 2024
- 2026Can In-Context Learning Support Intrinsic Curiosity?cited by 0
- 2026Can In-Context Learning Support Intrinsic Curiosity?17 Jun 2026
- 2025BED-LLM: Intelligent Information Gathering with LLMs and Bayesian Experimental Designcited by 21
- 2024Estimating the Hallucination Rate of Generative AIcited by 20
- 2025Enough Coin Flips Can Make LLMs Act Bayesiancited by 19
- 2025Position: The Future of Bayesian Prediction Is Prior-Fittedcited by 19
- 2024Bayesian Concept Bottleneck Models with LLM Priorscited by 16
- 2024AutoElicit: Using Large Language Models for Expert Prior Elicitation in Predictive Modellingcited by 15
- 2024Everything Everywhere All at Once: LLMs can In-Context Learn Multiple Tasks in Superpositioncited by 13
- 2025Are Large Language Models Reliable AI Scientists? Assessing Reverse-Engineering of Black-Box Systemscited by 13
- 2025Probabilistic operator learning: generative modeling and uncertainty quantification for foundation models of differential equationscited by 9
- 2024Transformers Handle Endogeneity in In-Context Linear Regressioncited by 8
- 2026From Zero to Hero: Advancing Zero-Shot Foundation Models for Tabular Outlier Detectioncited by 8
- 2025TabMGP: Martingale Posterior with TabPFNcited by 6
12 most cited of 37 All 37 (JSON)
- 2026Bayesian Fine-tuning Yields Language Models that are as Bayesian as their Beliefs Allow30 Sep 2026
- 2026Small transformers track Bayesian evidence for latent common causes via a context-invariant mechanism28 Sep 2026
- 2026Bayesian Intelligence from the Outside13 Sep 2026
- 2026What does a Bayes-filtered transformer believe? A predictive Monte Carlo approach19 Jul 2026
- 2026From Drift to Coherence: Stabilizing Beliefs in LLMs16 Jun 2026
- 2026VIP-COP: Context Optimization for Tabular Foundation Models13 May 2026
- 2026Variational predictive resampling11 May 2026
- 2026Toward Privileged Foundation Models:LUPI for Accelerated and Improved Learning8 May 2026
- 2026Quantifying Aleatoric Uncertainty of In-Context Learning for Robust Measure of LLM Prediction Confidence28 Apr 2026
- 2026Verbalizing LLM's Higher-order Uncertainty via Imprecise Probabilities11 Mar 2026
- 2026In-Context Function Learning in Large Language Models12 Feb 2026
- 2026Learning to Remember, Learn, and Forget in Attention-Based Models9 Feb 2026
12 newest of 37 All 37 (JSON)