Week 2: LLM Foundations for Agents

Chain-of-Thought, Tree-of-Thoughts, prompting strategies

Week 2 of 12

Learning Objectives

  • Implement CoT, ToT, and Self-Consistency
  • Compare prompting strategies on reasoning tasks
  • Analyze accuracy vs. cost trade-offs

Topics Covered

  • Chain-of-Thought prompting
  • Self-Consistency decoding
  • Tree-of-Thoughts reasoning
  • Zero-shot vs few-shot approaches

Resources

Jupyter Notebooks

Open Prompting Strategies in Colab Prompting Strategies

Required Readings

PaperAuthorsYearLink
Chain-of-Thought Prompting Elicits Reasoning Wei et al. 2022 arXiv
Tree of Thoughts Yao et al. 2023 arXiv

Reading Guide: Chain-of-Thought Paper

1-2 hours Chain-of-Thought Reasoning steps Emergent abilities

Analysis of Chain-of-Thought prompting and its role in agent reasoning

Primary Paper

Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
Wei, J., Wang, X., Schuurmans, D., et al. (2022)
NeurIPS 2022 arXiv

Exercise: Prompt Engineering

100 Points 4-6 hours Intermediate

Compare prompting strategies on reasoning tasks

Learning Objectives

  • Apply: Implement CoT, ToT, and Self-Consistency
  • Analyze: Compare accuracy vs cost trade-offs
  • Evaluate: Select optimal strategy for task type

Tasks

TaskPointsDescription
CoT Implementation 30 Implement chain-of-thought prompting
ToT Implementation 30 Implement tree-of-thoughts reasoning
Strategy Comparison 40 Benchmark and compare strategies

Exercise

Compare prompting strategies on a set of reasoning problems:

  1. Implement zero-shot, few-shot, and Chain-of-Thought prompting
  2. Measure accuracy and token usage
  3. Analyze when each strategy is most effective

Discussion Questions

  1. When should you use Self-Consistency over standard CoT?
  2. How does Tree-of-Thoughts trade off exploration vs. exploitation?
  3. What role does temperature play in reasoning quality?

Additional Resources

Discussion & Questions

Join the Conversation

Have questions about this week's material? Want to discuss concepts with fellow students?



Back to top