Skip to content
Chain-of-Thought Prompting Elicits Reasoning in Large Language Models 3 min

Jason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma, Brian Ichter, Fei Xia, Ed H. Chi, Quoc V. Le, Denny Zhou · NeurIPS 2022

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

Why asking a model to show its steps makes it better at math and logic. See a standard and a chain-of-thought prompt, and hunt for the wrong step.

Read the original paper

AI & ML · White Belt · Pro · 3 min read

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

Try this in your head: "Tom has 5 apples and buys 3 bags with 4 apples each. How many does he have?" Most people do not leap to the answer. They say "three bags of four is twelve, and five plus twelve is seventeen." Writing out the steps is how humans solve multi-step problems.

For years, large language models were asked to answer such problems directly, and they often failed. This 2022 paper from Google researchers asked a simple question: what if the prompt shows the model how to reason, by including worked examples with the steps written out? The answer changed how people talk to language models.

In chain-of-thought prompting, each example in the prompt includes the intermediate reasoning steps before the answer. Large models then write their own steps for a new question, and their accuracy on math, commonsense and symbolic reasoning tasks improves, sometimes dramatically.

What is a chain of thought?

The paper defines a chain of thought as a series of intermediate natural language reasoning steps that lead to the final output. In standard few-shot prompting, you show the model a few question and answer pairs. In chain-of-thought prompting, each answer in your examples also contains the reasoning that gets there.

With chain-of-thought prompting the model writes out intermediate steps before the final answer, so each step is small and easy to get right, instead of making one big leap.

Nothing is retrained. The only thing that changes is the text in the prompt, which makes the method cheap to try with any model you can already call.

It is like the difference between a teacher who shows only the answer key and a teacher who shows worked solutions. Students given worked solutions learn the method, and then write out their own working.

Keep reading with Pro

This paper is part of Pro. Pro and Architect open the full breakdown, with animated diagrams, interactive elements you can play with and a quiz. A few papers stay free to read in full.

Still to read

2 more sections, 1 more diagram and 3 interactive elements to play with

  • What the experiments show
  • Reading a chain, and where it goes wrong

Found this breakdown useful?

Share it with someone else wrestling with this paper.

Discussion0

Join the Discussion

Sign in to leave comments, reply to others, or like insights.

Sign In to ScaleDojo

No comments yet. Be the first to start the thread!

Enjoyed this? Get more like it.

New paper breakdowns, levels, and one concept worth knowing, straight to your inbox.

No spam, ever. Unsubscribe in one click.

Enjoyed this content?

Your support keeps us creating free resources

We put a lot of hours into researching and writing these guides. If it helped you, consider buying us a coffee. Every bit goes toward keeping ScaleDojo's content free and growing.

$

One-time payment via Stripe. ScaleDojo account required.