thought-based-reasoning

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Thought-Based Reasoning

基于思维的推理

Overview

概述

Core principle: Making reasoning explicit improves accuracy 20-70% on complex tasks.
Instead of jumping to answers, decompose problems into steps. This catches errors, enables backtracking, and produces verifiable reasoning.
核心原则: 将推理过程显性化可使复杂任务的准确率提升20-70%。
不要直接给出答案,而是将问题拆解为多个步骤。这样可以发现错误、支持回溯,并生成可验证的推理过程。

When to Use

使用场景

dot
digraph decide {
  "Problem type?" [shape=diamond];
  "Direct answer worked?" [shape=diamond];
  "Need confidence?" [shape=diamond];
  "Use direct prompting" [shape=box];
  "Use Zero-shot CoT" [shape=box];
  "Use Self-Consistency" [shape=box];
  "Use technique from table" [shape=box];

  "Problem type?" -> "Direct answer worked?" [label="simple"];
  "Problem type?" -> "Use technique from table" [label="math/logic/creative"];
  "Direct answer worked?" -> "Use direct prompting" [label="yes"];
  "Direct answer worked?" -> "Need confidence?" [label="no"];
  "Need confidence?" -> "Use Self-Consistency" [label="yes, high stakes"];
  "Need confidence?" -> "Use Zero-shot CoT" [label="no, just need better"];
}
Use when:
  • Multi-step arithmetic or word problems
  • Logic requiring deduction chains
  • Decisions with multiple factors
  • Creative problems needing exploration
  • Any task where direct answer was wrong
Don't use when:
  • Simple factual recall
  • Single-step operations
  • Time-critical responses where accuracy tradeoff acceptable
dot
digraph decide {
  "Problem type?" [shape=diamond];
  "Direct answer worked?" [shape=diamond];
  "Need confidence?" [shape=diamond];
  "Use direct prompting" [shape=box];
  "Use Zero-shot CoT" [shape=box];
  "Use Self-Consistency" [shape=box];
  "Use technique from table" [shape=box];

  "Problem type?" -> "Direct answer worked?" [label="simple"];
  "Problem type?" -> "Use technique from table" [label="math/logic/creative"];
  "Direct answer worked?" -> "Use direct prompting" [label="yes"];
  "Direct answer worked?" -> "Need confidence?" [label="no"];
  "Need confidence?" -> "Use Self-Consistency" [label="yes, high stakes"];
  "Need confidence?" -> "Use Zero-shot CoT" [label="no, just need better"];
}
适用场景:
  • 多步骤算术题或文字应用题
  • 需要演绎链的逻辑题
  • 涉及多因素的决策
  • 需要探索思路的创造性问题
  • 直接回答错误的任何任务
不适用场景:
  • 简单事实回忆
  • 单步骤操作
  • 可接受准确率与时间权衡的时效性响应

Quick Reference

快速参考

TechniqueTriggerTemplate
Zero-shot CoTQuick reasoning boost"Let's think step by step..."
Self-ConsistencyHigh-stakes decisionRun 3-5 paths, majority vote
Tree of ThoughtsPuzzle/creative blockBranch, evaluate, backtrack
Least-to-MostComplex multi-part problemDecompose → solve subproblems → combine
ReActNeed external factsThought → Action → Observation loop
PALMath with computationGenerate code, execute it
技术触发条件模板
Zero-shot CoT快速提升推理能力"让我们一步步思考..."
Self-Consistency高风险决策运行3-5条推理路径,取多数票
Tree of Thoughts谜题/创造性思维瓶颈分支、评估、回溯
Least-to-Most复杂多部分问题拆解→解决子问题→整合
ReAct需要外部事实思维→行动→观察循环
PAL涉及计算的数学题生成代码并执行

Techniques

技术详解

1. Zero-shot Chain-of-Thought

1. Zero-shot Chain-of-Thought

When: Quick prototype, no examples available
Template:
[Problem statement]

Let's think step by step:
Example:
A store has 45 apples. They sell 12 in the morning and receive a shipment of 30.
Then they sell 18 more. How many apples remain?

Let's think step by step:
1. Start: 45 apples
2. Sell 12: 45 - 12 = 33 apples
3. Receive 30: 33 + 30 = 63 apples
4. Sell 18: 63 - 18 = 45 apples

Answer: 45 apples remain.
Accuracy gain: +20-60%

适用场景: 快速原型、无示例可用
模板:
[问题描述]

让我们一步步思考:
示例:
一家商店有45个苹果。上午卖出12个,然后收到30个的补货。之后又卖出18个。还剩多少个苹果?

让我们一步步思考:
1. 初始:45个苹果
2. 上午卖出后:45 - 12 = 33个苹果
3. 补货后:33 + 30 = 63个苹果
4. 下午卖出后:63 - 18 = 45个苹果

答案:还剩45个苹果。
准确率提升: +20-60%

2. Self-Consistency

2. Self-Consistency

When: High-stakes decisions, need confidence measure
Process:
  1. Run Zero-shot CoT 3-5 times (vary temperature if possible)
  2. Collect all final answers
  3. Take majority vote
  4. Report confidence as agreement ratio
Template:
[Problem]

I'll reason through this multiple ways to verify:

Path 1:
[reasoning...]
Answer: X

Path 2:
[reasoning...]
Answer: Y

Path 3:
[reasoning...]
Answer: X

Consensus: X (2/3 agreement = 67% confidence)
Accuracy gain: +10-20% over single CoT

适用场景: 高风险决策、需要置信度衡量
流程:
  1. 运行Zero-shot CoT 3-5次(可能的话调整温度参数)
  2. 收集所有最终答案
  3. 取多数票作为结果
  4. 以一致率作为置信度报告
模板:
[问题]

我将通过多种推理路径验证答案:

路径1:
[推理过程...]
答案: X

路径2:
[推理过程...]
答案: Y

路径3:
[推理过程...]
答案: X

共识: X(2/3一致=67%置信度)
准确率提升: 比单一CoT提升10-20%

3. Tree of Thoughts

3. Tree of Thoughts

When: Puzzles, creative problems, need to explore alternatives
Process:
  1. Generate 2-3 initial approaches
  2. Evaluate each (promising/uncertain/dead-end)
  3. Expand promising branches
  4. Backtrack from dead-ends
  5. Continue until solution found
Template:
[Problem]
适用场景: 谜题、创造性问题、需要探索多种方案
流程:
  1. 生成2-3种初始思路
  2. 评估每种思路(有前景/不确定/死胡同)
  3. 拓展有前景的分支
  4. 从死胡同回溯
  5. 持续直到找到解决方案
模板:
[问题]

Branch 1: [Approach A]

分支1: [思路A]

Evaluation: [promising/uncertain/dead-end] [If promising, continue...]
评估: [有前景/不确定/死胡同] [如果有前景,继续...]

Branch 2: [Approach B]

分支2: [思路B]

Evaluation: [promising/uncertain/dead-end] [If dead-end, note why and stop]
评估: [有前景/不确定/死胡同] [如果是死胡同,说明原因并停止]

Expanding Branch 1:

拓展分支1:

Branch 1.1: [Sub-approach]

分支1.1: [子思路]

...
...

Solution found in Branch 1.1

在分支1.1中找到解决方案


**Example (Game of 24: make 24 from 4, 7, 8, 8):**
Branch 1: Try multiplication first
  • 4 × 7 = 28... need to subtract 4, but only have 8,8
  • Evaluation: uncertain, continue
Branch 2: Try getting 3 × 8 = 24
  • Need to make 3 from 4, 7, 8
  • 7 - 4 = 3 ✓
  • 3 × 8 = 24 ✓
  • Evaluation: SOLUTION
Answer: (7 - 4) × 8 = 24 (using one 8, ignoring other) Wait - must use all numbers. Backtrack.
Branch 3: Use both 8s
  • 8 + 8 = 16, need +8 from 4,7... 7-4=3, not 8
  • 8 × 8 = 64, need to subtract 40 from 4,7... no
  • 8 - 8 = 0, useless
  • 8 / 8 = 1, then 4 × 7 × 1 = 28, not 24
Branch 4: Division approach
  • (8 - 4) = 4
  • 8 / 4 = 2... not useful
  • 4 / (8-8) = undefined
Branch 5: Fractions
  • 8 / (1 - 7/8) = 8 / (1/8) = 64... no
  • Actually: 8 × (7 - 8/4) = 8 × (7-2) = 8 × 5 = 40
Hmm, trying more systematically...
  • Need operations on 4,7,8,8 = 24
  • (4 - 8/8) × 7 = 3 × 7 = 21
  • 4 × (8 - 8/7)... messy
  • (8 - 4) × (8 - 2)... don't have 2
Let me try: 8 / (8 - 4/7)... no Try: (7 + 8/8) × 4 = 8 × 4 = 32... nope that's wrong Wait: (7 + 1) × 3 = 24, can I make 1 and 3? 8/8 = 1 ✓, but can't make 3 from just 4
Try factoring 24: 1×24, 2×12, 3×8, 4×6
  • 3×8: need 3 from 4,7,8. (4+8)/7 ≈ 1.7, 7-4=3 ✓ but used 8 for the ×8
  • 4×6: need 6 from 7,8,8. 8-8+7=7, (8+8)/7≈2.3, nope
Solution: (8 - 8/4) × 7 = (8 - 2) × 7 = 6 × 7 = 42... no
Actually: 4 × 8 - 8 + 7 - 7 = 32... wait no sevens wrong Let me be systematic: 4 × 8 = 32, 32 - 8 = 24 ✓ What about 7? 32 - 8 × 7/7 = 32 - 8 = 24 ✓
Answer: 4 × 8 - 8 × 7/7 = 32 - 8 = 24 Or simpler: 4 × 8 - 8 + 7 - 7 = 24 (trivially using 7-7=0)

**Accuracy gain:** +50-70% on hard puzzles

---

**示例(24点游戏:用4、7、8、8算出24):**
分支1: 先尝试乘法
  • 4 × 7 = 28... 需要减去4,但只剩8、8
  • 评估: 不确定,继续
分支2: 尝试得到3 × 8 = 24
  • 需要用4、7、8得到3
  • 7 - 4 = 3 ✓
  • 3 × 8 = 24 ✓
  • 评估: 找到解决方案
答案: (7 - 4) × 8 = 24(使用一个8,忽略另一个) 等等 - 必须使用所有数字。回溯。
分支3: 使用两个8
  • 8 + 8 = 16,需要从4、7得到+8... 7-4=3,不是8
  • 8 × 8 = 64,需要从4、7减去40... 不行
  • 8 - 8 = 0,无用
  • 8 / 8 = 1,然后4 × 7 × 1 = 28,不是24
分支4: 除法思路
  • (8 - 4) = 4
  • 8 / 4 = 2... 没用
  • 4 / (8-8) = 无意义
分支5: 分数运算
  • 8 / (1 - 7/8) = 8 / (1/8) = 64... 不行
  • 实际: 8 × (7 - 8/4) = 8 × (7-2) = 8 × 5 = 40
嗯,尝试更系统的方法...
  • 对4、7、8、8进行运算得到24
  • (4 - 8/8) × 7 = 3 × 7 = 21
  • 4 × (8 - 8/7)... 太复杂
  • (8 - 4) × (8 - 2)... 没有2
试试: 8 / (8 - 4/7)... 不行 试试: (7 + 8/8) × 4 = 8 × 4 = 32... 不对 等等: (7 + 1) × 3 = 24,能得到1和3吗? 8/8 = 1 ✓,但无法只用4得到3
试试分解24: 1×24, 2×12, 3×8, 4×6
  • 3×8: 需要用4、7、8得到3。(4+8)/7≈1.7,7-4=3 ✓ 但8已经用来乘8了
  • 4×6: 需要用7、8、8得到6。8-8+7=7,(8+8)/7≈2.3,不行
解决方案: (8 - 8/4) × 7 = (8 - 2) × 7 = 6 × 7 = 42... 不对
实际: 4 × 8 - 8 + 7 - 7 = 32... 不对,7用错了 让我系统化: 4 × 8 = 32, 32 - 8 = 24 ✓ 那7呢?32 - 8 × 7/7 = 32 - 8 = 24 ✓
答案: 4 × 8 - 8 × 7/7 = 32 - 8 = 24 或更简单: 4 × 8 - 8 + 7 - 7 = 24(利用7-7=0的小技巧)

**准确率提升:** 在高难度谜题上提升50-70%

---

4. Least-to-Most Prompting

4. Least-to-Most Prompting

When: Complex problem with subproblems
Process:
  1. Decompose into subproblems
  2. Solve easiest first
  3. Use solutions to solve harder ones
  4. Combine for final answer
Template:
[Complex problem]
适用场景: 包含子问题的复杂问题
流程:
  1. 将问题拆解为子问题
  2. 先解决最简单的子问题
  3. 用子问题的答案解决更难的问题
  4. 整合所有答案得到最终结果
模板:
[复杂问题]

Subproblems (easiest to hardest):

子问题(从易到难):

  1. [Subproblem A]
  2. [Subproblem B, may need A's answer]
  3. [Subproblem C, needs A and B]
  1. [子问题A]
  2. [子问题B,可能需要A的答案]
  3. [子问题C,需要A和B的答案]

Solutions:

解决方案:

Subproblem 1:

子问题1:

[solve...] Answer: [X]
[解决过程...] 答案: [X]

Subproblem 2 (using X):

子问题2(使用X的结果):

[solve...] Answer: [Y]
[解决过程...] 答案: [Y]

Subproblem 3 (using X, Y):

子问题3(使用X和Y的结果):

[solve...]
[解决过程...]

Final Answer:

最终答案:

[Combine solutions]

**Accuracy gain:** +30-80% on compositional tasks

---
[整合所有子问题的解决方案]

**准确率提升:** 在组合任务上提升30-80%

---

5. ReAct (Reasoning + Acting)

5. ReAct (Reasoning + Acting)

When: Need external information, reduce hallucination
Process:
  1. Thought: reason about what's needed
  2. Action: query external source
  3. Observation: record result
  4. Repeat until solved
Template:
Question: [Question requiring external info]

Thought 1: I need to find [X] to answer this.
Action 1: Search/Lookup [X]
Observation 1: [Result]

Thought 2: Now I know X. I also need [Y].
Action 2: Search/Lookup [Y]
Observation 2: [Result]

Thought 3: With X and Y, I can now answer.
Answer: [Final answer grounded in observations]
Accuracy gain: +15-35%, major hallucination reduction

适用场景: 需要外部信息、减少幻觉
流程:
  1. 思维: 思考需要什么信息
  2. 行动: 查询外部来源
  3. 观察: 记录结果
  4. 重复直到问题解决
模板:
问题: [需要外部信息的问题]

思维1: 我需要找到[X]来回答这个问题。
行动1: 搜索/查找[X]
观察1: [结果]

思维2: 现在我知道了X,还需要[Y]。
行动2: 搜索/查找[Y]
观察2: [结果]

思维3: 有了X和Y,我可以回答问题了。
答案: [基于观察的最终答案]
准确率提升: +15-35%,大幅减少幻觉

6. PAL (Program-Aided Language)

6. PAL (Program-Aided Language)

When: Math with computation, eliminate arithmetic errors
Process:
  1. Translate problem to code
  2. Execute code
  3. Return result
Template:
[Math problem]

Let me write code to solve this:

```python
适用场景: 涉及计算的数学题、消除算术错误
流程:
  1. 将问题转化为代码
  2. 执行代码
  3. 返回结果
模板:
[数学问题]

让我写代码来解决这个问题:

```python

[Problem restated as comments]

[问题重述为注释]

initial = 45 after_morning_sales = initial - 12 after_shipment = after_morning_sales + 30 after_afternoon_sales = after_shipment - 18 print(f"Remaining: {after_afternoon_sales}")

[Execute]
Output: Remaining: 45

Answer: 45
Accuracy gain: Eliminates arithmetic errors entirely
initial = 45 after_morning_sales = initial - 12 after_shipment = after_morning_sales + 30 after_afternoon_sales = after_shipment - 18 print(f"剩余: {after_afternoon_sales}")

[执行]
输出: 剩余: 45

答案: 45
准确率提升: 完全消除算术错误

Decision Matrix

决策矩阵

SituationBest Technique
Quick reasoning, no examplesZero-shot CoT
High-stakes, need confidenceSelf-Consistency
Puzzle, creative, exploration neededTree of Thoughts
Multi-part with dependenciesLeast-to-Most
Need facts, reduce hallucinationReAct
Math with many calculationsPAL
Iterative improvementReflexion (run, critique, retry)
场景最佳技术
快速推理、无示例Zero-shot CoT
高风险、需要置信度Self-Consistency
谜题、创造性、需要探索Tree of Thoughts
多部分且有依赖关系Least-to-Most
需要事实、减少幻觉ReAct
包含大量计算的数学题PAL
迭代改进Reflexion(运行、评估、重试)

Common Mistakes

常见错误

MistakeFix
Using CoT for simple queriesDirect answer is fine for 1-step problems
Not showing workExplicit steps catch errors
Stopping at first answerSelf-consistency finds better answers
Linear thinking on puzzlesTree of Thoughts enables backtracking
Computing mentallyPAL eliminates arithmetic errors
Guessing factsReAct grounds in external sources
错误修复方案
对简单查询使用CoT单步骤问题直接回答即可
不展示推理过程显性步骤可发现错误
得到第一个答案就停止自一致性可找到更优答案
对谜题使用线性思维Tree of Thoughts支持回溯
心算PAL可消除算术错误
猜测事实ReAct基于外部来源确保准确性

Combining Techniques

技术组合

For maximum accuracy on hard problems:
1. Least-to-Most: decompose into subproblems
2. For each subproblem:
   - PAL if computational
   - ReAct if needs facts
   - Tree of Thoughts if exploratory
3. Self-Consistency on final assembly

针对高难度问题实现最高准确率:
1. Least-to-Most: 将问题拆解为子问题
2. 对每个子问题:
   - 涉及计算时使用PAL
   - 需要事实时使用ReAct
   - 需要探索时使用Tree of Thoughts
3. 对最终整合结果使用Self-Consistency

What Claude Does vs What You Decide

Claude的职责与你的决策

Claude handlesYou provide
Selecting appropriate reasoning techniqueProblem statement and constraints
Executing multi-step reasoning chainsVerification of intermediate steps
Generating multiple reasoning pathsSelection of best answer
Backtracking from dead-endsJudgment on acceptable confidence
Computing via PAL when neededReal-world validation of results

Claude负责你提供
选择合适的推理技术问题描述与约束
执行多步骤推理链验证中间步骤
生成多条推理路径选择最优答案
从死胡同回溯判断可接受的置信度
必要时通过PAL计算结果的现实验证

Skill Boundaries

技能边界

This skill excels for:

本技能擅长:

  • Math and logic problems with multiple steps
  • Decisions with competing factors
  • Puzzles requiring exploration
  • Tasks where initial answers were wrong
  • 多步骤数学与逻辑问题
  • 存在竞争因素的决策
  • 需要探索的谜题
  • 初始答案错误的任务

This skill is NOT ideal for:

本技能不适合:

  • Simple factual recall → Direct answer is faster
  • Creative writing → Different techniques apply
  • Time-critical responses → CoT adds latency

  • 简单事实回忆 → 直接回答更快
  • 创意写作 → 需要不同技术
  • 时效性响应 → CoT会增加延迟

Skill Metadata

技能元数据

yaml
name: thought-based-reasoning
category: thinking
version: 2.0
author: GUIA
source_expert: Wei et al. (CoT), Yao et al. (ToT), Kojima et al. (Zero-shot CoT)
difficulty: intermediate
mode: both
tags: [reasoning, cot, tot, react, pal, logic, math, problem-solving]
created: 2026-02-03
updated: 2026-02-03
yaml
name: thought-based-reasoning
category: thinking
version: 2.0
author: GUIA
source_expert: Wei et al. (CoT), Yao et al. (ToT), Kojima et al. (Zero-shot CoT)
difficulty: intermediate
mode: both
tags: [reasoning, cot, tot, react, pal, logic, math, problem-solving]
created: 2026-02-03
updated: 2026-02-03