5 Prompting Techniques II

 

This chapter covers

  • A few more prompting techniques that build upon the ones we covered in Chapter 4 with illustrated examples of using them to interact with models.
  • An insight into the newly released reasoning models, such as o3-mini from Open AI, Google's Flash thinking, and DeepSeek-R1.
  • A deep insight into more complex prompting techniques and their workings and illustrated code examples of each technique with their results.
  • The limitations of each technique and how they affect the model’s performance.
  • Ways to mitigate the limitations by leveraging one or more techniques and prompt patterns.

Chapter 4 discussed zero-shot, few-shot, multi-shot, Chain-of-thought, and ReAct prompting techniques. We also covered prompt chaining, which enables you to chain several prompts to break down a complex problem into smaller problems and add validation/verification/transformation steps between each prompt to achieve the end goal. In this Chapter, we will discuss a few complex prompting techniques that deal with text and video and build upon the methods we have already seen. We will leverage LangChain to build examples that closely relate to real-world applications and showcase how to use each technique to solve real-world use cases.

5.1 Open AI’s O3-mini Reasoning Model

5.2 DeepSeek-R1

5.3 Gemini 2.0 Flash Thinking

5.4 Advanced Chain of Thought Prompting

5.4.1 Automatic Chain of Thought

5.4.2 Tree of Thought Prompting

5.5 Generated Knowledge Prompting

5.6 Graph of Thought Prompting

5.7 Multi-modal Prompting

5.8 Automatic Prompt Engineering

5.9 Summary