Tree of Thoughts & Self-Consistency
Explore branching reasoning paths and majority-vote strategies to dramatically improve accuracy on hard problems.
Chain-of-thought prompting follows a single reasoning path. But what if that path is wrong? Tree of Thoughts (ToT) and Self-Consistency both address this by exploring multiple reasoning paths, then selecting or combining the best results.
Self-Consistency is the simplest multi-path technique. You run the same prompt multiple times at a moderate temperature (0.5–0.7), collect several answers, and take the majority vote. Research shows this improves accuracy by 5–15% on math and logic benchmarks compared to single-shot chain-of-thought.
ToT structures reasoning as a tree where each node is a partial solution. The model generates multiple candidate next-steps at each node, evaluates which branches are promising, and prunes dead ends. This is particularly effective for planning, puzzles, and multi-constraint problems.
Prompt Templates
Self-Consistency Voting
Simulates self-consistency within a single prompt by requesting multiple independent reasoning paths.
Solve this problem using 3 independent reasoning approaches. For each approach, show your work step by step. After all 3 approaches, compare the answers and select the one with the most agreement. Problem: [PROBLEM]
Tree of Thoughts Explorer
Guides the model through branching exploration with evaluation at each node.
I need to solve: [PROBLEM] Step 1: Generate 3 possible approaches. For each, rate feasibility (1-5) with a one-line rationale. Step 2: Take the highest-rated approach and generate 3 possible next steps. Rate each. Step 3: Continue with the best path until you reach a solution. Step 4: State the final answer and your confidence level.
Test Your Knowledge
Knowledge Check
1 / 2
How does Self-Consistency improve reasoning accuracy?
Key Takeaways
- ✓Self-Consistency improves accuracy by 5–15% through majority voting across multiple reasoning paths
- ✓Tree of Thoughts structures reasoning as a search tree with evaluation and pruning at each step
- ✓Both techniques trade token cost for accuracy — use them when correctness matters most
Continue Learning
ReAct & Reflexion
Learn how interleaving reasoning with actions and self-reflection loops push model capabilities further.
Program-Aided Language Models
Combine natural language reasoning with executable code to solve math, data, and logic problems accurately.
Embeddings & Vector Stores
Understand how text becomes searchable vectors and how vector databases power semantic search.