1 Introduction to Prompt Engineering

 

This chapter covers

  • Prompt Engineering basics and its importance.
  • Large Language Models (LLMs) and how they work.
  • Single and multi-modal prompting.
  • How does prompt engineering vary by LLMs?
  • What languages and tools are great for Prompt Engineering?

Prompt engineering is the process of crafting effective prompts for Artificial Intelligence (AI) models to obtain desired results. In many ways, Prompt Engineering is like building software using data structures and algorithms. The better the data structure and the applicable algorithms you use for a given problem, the better your software can utilize the underlying compute infrastructure and deliver the best performance possible. Along the same lines, a well-designed or engineered prompt will help unlock the true potential of any LLM (Large Language Model).

Prompt engineering aims to enable users to communicate and illustrate the question or problem statement, structure the prompt by defining the context, and then use an LLM to test the prompt and its expected response. The LLM chosen can affect the output generated and the inputs required to interact. This is particularly important because every Large Language Model has its own tradeoffs. Some are best suited for academia, others for general purposes, and others for mathematics, cybersecurity, etc.

1.1 What is a Prompt?

 
 
 

1.2 Why is Prompt Engineering Important?

 
 

1.2.1 Optimizing AI Interactions

 
 
 
 

1.2.2 Enhancing AI Model Training

 
 
 
 

1.2.3 Customization and Personalization

 
 
 

1.2.4 Navigating Ethical and Societal Implications

 
 
 
 

1.2.5 Interdisciplinary Innovation

 
 
 

1.3 How to use Prompts?

 
 
 

1.3.1 Contextual Prompts

 
 

1.3.2 Summarization & Translation Prompts

 
 
 

1.3.3 Sentiment Analysis Prompts

 
 
 

1.3.4 Code Generation Prompts

 
 
 

1.4 What is a Large Language Model

 

1.5 Distinguishing LLMs from Other Generative AI Models

 
 

1.6 Insights into the Transformer Architecture

 

1.7 How does Prompt Engineering vary by LLMs?

 
 
 

1.8 What language and tools are great for Prompt engineering?

 
 

1.8.1 Open AI Playground

 

1.8.2 LangChain

 
 

1.9 Summary

 
 
 
sitemap

Unable to load book!

The book could not be loaded.

(try again in a couple of minutes)

manning.com homepage
test yourself with a liveTest