Skip to main content
GW
HomeWorkAI appsPapersAboutNotesStackLabPilotPlan↗ (opens in a new tab)INVST↗ (opens in a new tab)
Govind Waghmare

Finance systems and AI. Building in public from NYC.

Resume (PDF)Book 20 minEmail
HomeNotesWorkAboutStackPapersLabFor founders
XLinkedInGitHubllms.txt
© 2026 · New York City

Keyboard shortcuts

?
Open this list
g then h
Go to Home
g then w
Go to Work
g then n
Go to Notes
g then a
Go to About
c
Ask the AI guide
Esc
Close this list
Original paperSection A, The abstract
Open in new tab (opens in a new tab)
All papers
FoundationsClassic

Show the steps and the model reasons better

Paper: Chain-of-Thought Prompting Elicits Reasoning in Large Language Models

Jason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma, Brian Ichter, Fei Xia, Ed H. Chi, Quoc V. Le, Denny Zhou · NeurIPS 2022 · Posted 28 Jan 2022 · 16 min read · arXiv 2201.11903

Share this paper

LinkedIn (opens in a new tab)X (opens in a new tab)WhatsApp (opens in a new tab)EmailDownload PDFExplainer + original paper (PDF), 1.2 MB

  • Making a model bigger did not fix hard reasoning.
  • Plain few-shot prompts show only questions and answers.
  • Models guess the answer in one jump.
  • Math, commonsense and symbol tasks stayed hard.
57%

of GSM8K math problems solved by PaLM 540B with chain of thought, versus 18% without.

  • They put worked steps in the few-shot examples.
  • They tried 5 models on arithmetic, commonsense and symbol tasks.
  • They turned parts off to see what matters.
  • They had 3 annotators write their own chains.

  • Steps help only at large scale, around 100B parameters.
  • PaLM 540B set a new best on GSM8K, SVAMP and MAWPS.
  • Hard problems gain the most.
  • Plain equations or extra compute alone did not help.

Chain of thought lifts PaLM 540B past finetuned models on GSM8KFrom Figure 2
0255075100GSM8K solve rate (%)Finetuned GPT-3 175B33%Prior best55%PaLM 540B, standard18%PaLM 540B, chain of thought57%

Hover, tap or focus a bar to read its exact value.

SetupSolve rate (%)
Finetuned GPT-3 175B33
Prior best55
PaLM 540B, standard18
PaLM 540B, chain of thought57

  • A chain looks like thinking. The paper says it may not be real reasoning.
  • The reasoning path can be wrong, even when the answer is right.
  • Small models do worse with chains.
  • Large models cost more to serve.

Jump to

  1. A The abstract
  2. 1 Introduction
  3. 2 Chain-of-thought prompting
  4. 3.1 Arithmetic: experimental setup
  5. 3.2 Arithmetic: results
  6. 3.3 Ablation study
  7. 3.4 Robustness of chain of thought
  8. 4 Commonsense reasoning
  9. 5 Symbolic reasoning
  10. 6 Discussion and limits
  11. 7 Related work
  12. 8 Conclusions
  13. App A Appendix A: frequently asked questions
  14. App B Appendix B: all experimental results
  15. App C Appendix C: extended related work
  16. App D Appendix D: additional analysis
  17. App E Appendix E: additional details
  18. App F Appendix F to H: examples and prompts
  19. W Words to know

Every detail from the paper

Cards follow the paper's own order. Dotted words link to Words to know. Numbers match the paper.

The idea

  • A chain of thought is a series of reasoning steps written in plain words.
  • The authors show it helps large language models on hard reasoning tasks.
  • The method is simple: put a few worked examples in the Prompt.

The result

  • They test 3 large models on math, commonsense and symbol tasks.
  • Prompting PaLM 540B with just 8 worked examples sets a new best on GSM8K.
  • It beats even finetuned GPT-3 with a verifier.

The gap

  • Bigger models gain many things.
  • But size alone did not fix arithmetic, commonsense or symbolic reasoning.

Two ideas

  • Idea 1: write the reasoning in natural language before the answer.
  • Earlier work trained models from scratch or finetuned them to do this.
  • Idea 2: few-shot prompting. Show a few input and output examples in the prompt.
  • It needs no new model per task.

Their limits

  • Rationales are costly to write for a large training set.
  • Plain few-shot prompting works poorly on reasoning tasks.
  • It does not improve much as models grow.

The combination

  • This paper joins both ideas.
  • Each example in the prompt has three parts: input, chain of thought, output.
  • The authors call this chain-of-thought prompting.

Why prompt-only matters

  • Figure 2: PaLM 540B with chain of thought sets a new best on GSM8K.
  • GSM8K is a set of math word problems.
  • A prompt-only method needs no large training set.
  • One model checkpoint can do many tasks.

The goal

  • People break a hard problem into steps.
  • Example: "After Jane gives 2 flowers to her mom she has 10...".
  • The chain ends: "so the answer is 7".
  • The goal is to make models write a similar chain of thought.
  • Large models can do this if the examples show it.
Standard prompting versus chain of thoughtFrom Figure 1
  1. Example: question, then answer only
  2. Model answers new question: 27
  3. Example: question, steps, answer
  4. CoTModel writes steps
  5. Model answers 9: correct

The cafeteria question: 23 apples, use 20, buy 6. The right answer is 9.

The name

  • They call it a chain of thought, not a solution.
  • It copies how a person thinks toward an answer.
  • Solutions normally come after the final answer.

Four good properties, 1 and 2

  • 1. It splits a multi-step problem into steps.
  • More steps means the model can spend more computation.
  • 2. It gives a window into how the model got the answer.
  • You can debug where the reasoning went wrong.
  • Fully explaining the model's computation stays an open question.

Properties 3 and 4

  • 3. It works for math, commonsense and symbol tasks.
  • It may apply to any task a person can solve with language.
  • 4. It needs no training.
  • Add chain-of-thought examples to few-shot prompts of a ready model.

Where tests come next

  • Section 3: arithmetic. Section 4: commonsense. Section 5: symbolic.

Why arithmetic

  • Math word problems are simple for people.
  • Language models often struggle with them.
  • With 540B parameters, chain of thought matches task-specific finetuned models on several tasks.

Five benchmarks

  • 1. GSM8K: math word problems.
  • 2. SVAMP: problems with varying structures.
  • 3. ASDiv: diverse math word problems.
  • 4. AQuA: algebraic word problems.
  • 5. MAWPS: a standard benchmark.

The two prompts

  • Standard prompting: input and output pairs. The model answers directly.
  • Chain of thought: each example also has its reasoning chain.
  • Most datasets have only a test split.
  • So the authors wrote 8 examples with chains by hand.
  • These examples were not tuned. AQuA is multiple choice, so it uses 4.

Five models

  • GPT-3: text-ada-001, text-babbage-001, text-curie-001, text-davinci-002.
  • These are probably 350M, 1.3B, 6.7B and 175B parameters.
  • LaMDA: 422M, 2B, 8B, 68B and 137B.
  • PaLM: 8B, 62B and 540B.
  • UL2: 20B. Codex: code-davinci-002.

How they run it

  • They use greedy decoding.
  • Later work shows majority voting over many samples can do better.
  • LaMDA results average 5 random orders of the examples.
  • Other models use one order, to save compute.

Takeaway 1

  • 1. Emergent with scale. Chain of thought does not help small models.
  • It helps only around 100B parameters.
  • Small models wrote fluent but illogical chains.
  • That scored lower than standard prompting.
Chains of thought only pay off at 68B and above, on LaMDAFrom Table 2
StandardChain of thought
05101520GSM8K solve rate (%)420M2.6%0.4%2B3.6%1.9%8B3.2%1.6%68B5.7%8.2%137B6.5%14.3%

Hover, tap or focus a bar to read its exact value.

Model sizeStandard (%)Chain of thought (%)
420M2.60.4
2B3.61.9
8B3.21.6
68B5.78.2
137B6.514.3

Takeaway 2

  • 2. Bigger gains on harder problems.
  • GSM8K has the lowest baseline of the five.
  • Performance more than doubled for the largest GPT and PaLM models.
  • SingleOp, the easiest MAWPS subset, saw small or negative change.

Takeaway 3

  • 3. It rivals the prior best.
  • PaLM 540B sets a new best on GSM8K, SVAMP and MAWPS.
  • Standard prompting already passed the prior best for SVAMP.
  • On AQuA and ASDiv, PaLM is within 2% of the best.
Do the chains make sense? Error analysis

Right answers

  • They read 50 random LaMDA 137B answers that were right on GSM8K.
  • All chains were correct except two, which got lucky.

Wrong answers

  • They read 50 random wrong answers.
  • 46% of chains were almost right.
  • Small slips: a calculator error, a symbol mapping error, or one missing step.
  • The other 54% had major errors in understanding or coherence.

Why scale helps

  • They checked PaLM 62B errors and whether 540B fixed them.
  • Scaling to 540B fixes a large share of missing-step and understanding errors.

The question

  • An ablation turns off one part to see what matters.
  • They test three variants on LaMDA 137B and PaLM 540B (Figure 5).

Variant 1

  • Equation only: the model writes only the math equation.
  • It does not help much on GSM8K.
  • The questions are too hard to turn into an equation directly.
  • It helps on datasets with one or two steps.

Variant 2

  • Variable compute only: the model writes dots, one per equation character.
  • It scores about the same as the baseline.
  • So extra computation alone is not the reason it works.
  • Writing steps in natural language matters.

Variant 3

  • Chain of thought after the answer: the chain comes after the answer.
  • It scores about the same as the baseline.
  • So chain of thought is not just a way to recall knowledge.
  • The step order matters.
Only a real chain of thought lifts GSM8K; the ablations do notFrom Table 6
0481216GSM8K solve rate, LaMDA 137BStandard6.5%Equation only5.4%Variable compute only6.4%Reasoning after answer6.1%Chain of thought14.3%

Hover, tap or focus a bar to read its exact value.

PromptSolve rate (%)
Standard6.5
Equation only5.4
Variable compute only6.4
Reasoning after answer6.1
Chain of thought14.3

Why check

  • Prompts can be fragile.
  • Changing example order moved GPT-3 on SST-2 from 54.3% to 93.4%.

Different writers

  • Annotator A wrote the main chains.
  • Annotators B and C, two other authors, wrote their own.
  • Annotator A also wrote a more concise version.

Result

  • Results vary, as expected.
  • All sets beat standard prompting by a large margin.
  • So chain of thought does not depend on one writing style.

Other exemplars

  • They also sampled 3 sets of 8 examples from the GSM8K training set.
  • Those came from crowd workers with no machine learning background.
  • They scored about the same as the hand-written chains.
  • Chain of thought also held up across example orders and example counts (Appendix A.2).

Why it fits

  • Chain of thought is made of language.
  • So it also applies to commonsense reasoning about physical and human things.

Five benchmarks

  • CSQA: commonsense questions about the world.
  • StrategyQA: the model must infer a multi-step strategy.
  • Date Understanding: infer a date from context.
  • Sports Understanding: is a sports sentence plausible?
  • SayCan: map an instruction to robot actions.

Prompts

  • Same setup as before.
  • CSQA and StrategyQA: random training examples with hand-written chains.
  • The two BIG-bench tasks have no training set.
  • So they use the first 10 examples as the few-shot examples.
  • SayCan uses 6 training examples with hand-written chains.

Results

  • Scale helped standard prompting on all tasks.
  • Chain of thought added more, most for PaLM 540B.
  • PaLM 540B beat the prior best on StrategyQA: 75.6% versus 69.4%.
  • It beat an unaided sports enthusiast on sports understanding: 95.4% versus 84%.
  • The gain on CSQA was minimal.
TaskStandard (%)Chain of thought (%)
CSQA78.179.9
StrategyQA68.677.8
Date understanding49.065.3
Sports understanding80.595.4
SayCan80.891.7

PaLM 540B on commonsense tasks

The aim

  • Symbol tasks are easy for people and hard for models.
  • Chain of thought also helps with longer inputs than the examples show.

Two toy tasks

  • Last letter concatenation: join the last letters of a name's words. "Amy Brown" gives "yn".
  • Coin flip: people flip or skip a coin. Is it still heads up?
  • Names come from the top one thousand first and last names.
The length testFrom Section 5
  1. Examples show 2-word names
  2. In-domain test: 2 words
  3. Out-of-domain test: 3 and 4 words
  4. Chain of thought still scales

Coin flip works the same way, with more flips.

In-domain results

  • PaLM 540B with chain of thought nears 100% in-domain.
  • Standard prompting already solves coin flip for PaLM 540B, but not for LaMDA 137B.
  • These are toy tasks. The chains give the full solution pattern.
  • Yet small models still fail. The skill appears at about 100B parameters.

Out-of-domain results

  • Standard prompting fails on both out-of-domain tasks.
  • With chain of thought, results rise with scale, but stay below in-domain.
TaskStandard (%)Chain of thought (%)
Letter concat, 2 words7.699.4
Letter concat, 3 words (OOD)0.294.8
Letter concat, 4 words (OOD)0.063.0
Coin flip, 298.1100.0
Coin flip, 3 (OOD)49.398.6
Coin flip, 4 (OOD)54.890.2

PaLM 540B on symbolic tasks

OOD means out of domain: longer than the examples.

What they showed

  • Chain of thought raises arithmetic scores by a large margin.
  • It is robust to writers, examples and models.
  • It suits commonsense tasks because it is made of language.
  • It helps symbol tasks reach longer inputs.
  • No model was finetuned for this paper.

The bigger point

  • Where standard prompting is flat with scale, chain of thought rises sharply.
  • Standard prompting gives only a lower bound on what models can do.
  • Open questions: how far will scale push reasoning?
  • What other prompts could expand what models solve?

Four limits

  • 1. A chain imitates thinking. That does not prove the network reasons.
  • 2. Writing chains costs little for few-shot prompts.
  • It could cost too much for finetuning. Synthetic data may help.
  • 3. The reasoning path may be wrong. Correct and incorrect paths both occur.
  • 4. It only emerges at large scale, so serving it is costly.

Intermediate steps

  • Ling et al. used natural language steps for math word problems.
  • Cobbe et al. built a bigger dataset and finetuned a model.
  • Nye et al. had models predict program results line by line.

Prompting

  • Other work learns prompts or gives models task instructions.
  • Those improve the input part of the prompt.
  • Chain of thought improves the output part.

Takeaway

  • Chain-of-thought prompting is simple and broadly useful.
  • Reasoning is an emergent property of model scale.
  • It lets large models do tasks that had flat scaling curves.
  • The authors hope for more language-based reasoning work.

A.1 Why does scale help?

  • Chain of thought hurts most models under 10B parameters.
  • They read 45 errors from PaLM 62B.
  • 20 were semantic understanding errors. 18 were one step missing. 7 were other.
  • Scaling to 540B fixed 6, 12 and 4 of them.
  • Small models also fail at symbol mapping and arithmetic.
  • They often give no parseable final answer.

A.2 Prompt engineering

  • Annotators got no style rules. Chain of thought won with all of them.
  • Order of examples had small effect, except for coin flip.
  • Gains held with varying numbers of examples, on five datasets.
  • Going from 8 to 16 standard examples did not close the gap.
  • It did not help CSQA and StrategyQA for GPT-3.
  • Coin flip ranged from 99.6% to 71.4% across annotators.
  • Prompt writing still matters.

A.3 Will it help my task?

  • It helps most when three things hold.
  • The task needs several reasoning steps.
  • The model is large.
  • The scaling curve is flat.
  • Gains are small on easy MAWPS subsets, where PaLM 540B scores 90% or more.

A.4 Why equation only is not enough

  • Equation only helps on one-step and two-step sets, such as SVAMP.
  • On GSM8K the question is too hard to turn into one equation.
  • Example: the ping pong question gives 6 with an equation and 9 with a chain.

Calculator

  • An external calculator fixes arithmetic slips in the chains.
  • It boosts chain of thought on most tasks.
ModelStandardChain of thoughtChain of thought + calculator
UL2 20B4.14.46.9
LaMDA 137B6.514.317.8
GPT-3 175B15.646.949.6
Codex19.763.165.4
PaLM 540B17.956.958.6

GSM8K by model (Table 1)

The prior best is 55 (finetuning).

The other tables

  • Table 2: all model sizes on all five math sets.
  • Table 3: the four MAWPS subsets. Gains are minimal on easy ones.
  • Table 4: commonsense, all models. Table 5: symbolic, all models.
  • Tables 6 and 7: ablations and robustness on LaMDA 137B.

Table 6 highlights

  • Equation only on GSM8K: 5.4. Variable compute only: 6.4.
  • Chain of thought from annotator C on GSM8K: 17.6.

Summary

  • Five areas inspire the work.
  • They are prompting, natural language explanations, and program synthesis.
  • The other two are numeric and logical reasoning, and intermediate steps.
  • Instructions augment the input. Chain of thought augments the output.
  • A user study with 20 people found chaining model outputs improves outcomes.

D.1 Correct chains

  • Of 50 correct LaMDA answers, 49 had correct logic and math.
  • 1 was correct by chance.
  • 5 had minor imperfections.

D.2 Wrong chains

  • Of 50 wrong answers, 8% were right except for a calculator slip.
  • 16% had only a symbol mapping error.
  • 22% were missing one step.
  • A calculator lifted LaMDA 137B on GSM8K from 14.3% to 17.3%.

D.3 Number of examples

  • Eight examples were the limit set by a 1024 token input.
  • Gains held across numbers of examples (Figure 11).

Reproducibility and resources

  • Version notes: V2 added PaLM. V3 added GPT-3, SVAMP, AQuA and SayCan.
  • V5 added Codex and UL2.
  • No finetuning was done. LaMDA used TPU v3. PaLM used TPU v4.
  • Prompts for all tasks are in Tables 20 to 27.
  • Dataset licenses are listed for the arithmetic and commonsense sets.

Examples

  • Appendix F: example right and wrong chains from LaMDA 137B and PaLM 540B.
  • Appendix G: the full few-shot prompts (Tables 20 to 28).
  • Appendix H: chains written by other annotators (Tables 29 and 30).
  • This write-up covers the main paper in full and each appendix at summary level.

Words to know

  • Ablation: A test that removes one part to see what it did.
  • Chain of thought: Reasoning steps written in plain words before the answer.
  • Emergent ability: A skill that appears only above a certain model size.
  • Few-shot prompting: Putting a few worked examples in the prompt.
  • Greedy decoding: Always pick the single most likely next word.
  • Language model: A program that predicts the next word of text.
  • Parameter: A number inside the model that training adjusts.
  • Prompt: The text you give a model to start its answer.
  • Solve rate: The share of problems the model answers correctly.

Share this paper

LinkedIn (opens in a new tab)X (opens in a new tab)WhatsApp (opens in a new tab)EmailDownload PDFExplainer + original paper (PDF), 1.2 MB

Ask AI about this paper

Stuck on a word or an idea? Ask in plain words. The answer comes from the write-up on this page.

Read the original paper on arXiv: Chain-of-Thought Prompting Elicits Reasoning in Large Language Models (opens in a new tab)

Jump to

One paper a week, in plain English

Every Monday: the new AI papers worth your time. Short lines, the key number, and what to do with it.

One email a week. Unsubscribe with one click. No spam.