CHAPTER 2
CRAFTING CONTEXTUAL PROMPTS
For AI-powered communication, crafting contextual prompts is akin to composing a well-crafted question or preparing an engaging conversation. Contextual prompts lay the foundation for eliciting coherent and relevant responses from ChatGPT. In this chapter, we delve into the art of designing prompts that effectively guide the model to provide nuanced and targeted replies.
2.1 LEVERAGING CONTEXT FOR MORE RELEVANT RESPONSES
Effective communication hinges on understanding context, and ChatGPT is no exception. By infusing prompts with context, we guide the model to better comprehend the conversation’s trajectory. Whether it is referring to prior messages in a chat or incorporating domain-specific cues, contextual ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access