0% found this document useful (0 votes)
43 views

Introduction to Prompt Engineering

The document introduces a course on prompt engineering, led by Atul Kulkarni, who has extensive experience in software development and AI. It outlines the course logistics, including duration, examination structure, and project requirements, while explaining the concept of prompts and prompt engineering for large language models (LLMs). Additionally, it provides examples of various types of prompts for business analysis, creative writing, educational content creation, and technical problem-solving.

Uploaded by

pathakpritee20
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
43 views

Introduction to Prompt Engineering

The document introduces a course on prompt engineering, led by Atul Kulkarni, who has extensive experience in software development and AI. It outlines the course logistics, including duration, examination structure, and project requirements, while explaining the concept of prompts and prompt engineering for large language models (LLMs). Additionally, it provides examples of various types of prompts for business analysis, creative writing, educational content creation, and technical problem-solving.

Uploaded by

pathakpritee20
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 15

Introduction to Prompt

Engineering
How to talk to LLMs?
Who am I?
Name: Atul Kulkarni

Professional Experience: I have over 19 years of professional software


development experience. I currently work for Amazon, leading teams that build the
Amazon AI Shopping Assistant called Rufus.

Education: I did my bachelors (2001) and masters (2003) in computer science


from Pune University. I also completed my MS from University of Minnesota
Duluth (2007-09)

I can speak English, Marathi & Hindi fluently…


Logistics
● This is a 10 - 12 weeks long course.
● We will have 2 examinations - mid-term and final.
● 80% of both the exam questions will be multiple choice questions, 20% will be
longer answers.
● You will be given homework every week, homework will need to be turned in
before the start of the first lecture of next week.
● You will be need to complete a project at the end of course.
● One lecture of each week starting week 2 or week 3 will be about project idea
discussion
● You grade will be combination of 2 exams (40%), homeworks (40%) and
project (20%)
Understanding the Class
● How many of you have access to a personal computer during class?
● Do you know what is Discord?
○ How many of you have access to the discord after class for communication with others
on the class?
● Questions?
Introduction To Prompt Engineering
Let us learn about the basics…
● What is an LLM?
● How many of you have heard of or used an LLM?
● What are some common LLM based applications?
● How do you use them?
What is a Prompt?

Definition: A prompt for an LLM is a piece of text input that serves as instructions
or a query to guide the AI model in generating a relevant response.
Structure of a Prompt

● It can be a question, a statement, or a set of instructions.

● Prompts can range from a single word to several


paragraphs.
Purpose of the Prompt

Provide Context to the LLM


Provide instructions to the LLM
Components of a Typical Prompt

● Context: What background information should the LLM


keep in mind while answering the question?
● Instruction: What is the task that needs to be performed
by the LLM?
● Input: What is the input data if any to work on?
● Output: How should the output be generated?
Input and Output ARE OPTIONAL!
What is Prompt Engineering

Definition: Prompt engineering is the practice of designing and refining input


prompts to effectively communicate with and guide AI models to produce desired
outputs.
Basic Concepts:
● It's about crafting clear, specific instructions or queries for AI systems.
● Involves understanding how AI interprets language and context.
● Combines elements of natural language processing, psychology, and domain
expertise.
Example: Business Analysis Prompt
Business Analysis Prompt:

"You are a business analyst AI specializing in market trends. Analyze the impact of
remote work on the commercial real estate market in major U.S. cities. Use the
following data points: [Insert 3-5 key statistics about remote work adoption and
office occupancy rates]. Provide your analysis in a 5-point summary, each point no
longer than 3 sentences. Include one potential long-term consequence and one
potential opportunity for investors. Avoid technical jargon and explain concepts in
layman's terms."
Example: Creative Writing Prompt
Creative Writing Prompt

"As a storytelling AI, write a 500-word short story that combines elements of
science fiction and romance. The story should be set on a space station orbiting
Jupiter in the year 2150. Include at least two characters: a human scientist and an
AI assistant. The central conflict should involve an unexpected discovery about
Jupiter's atmosphere. Structure the story with a clear beginning, middle, and end.
Use vivid descriptive language and incorporate at least one dialogue exchange.
The tone should be hopeful yet mysterious."
Example: Educational Content Creation Prompt
"Assume the role of a history teacher creating content for 8th-grade students. Develop a
lesson plan on the Industrial Revolution. The plan should include:
A brief overview (100 words)
Three main learning objectives
A timeline of 5 key events
Two discussion questions
One hands-on activity idea Ensure the content is engaging and appropriate for 13-14
year olds. Use simple language and avoid complex historical terms without explanation.
The total length should not exceed 500 words. Format your response with clear headings
for each section."
Example: Technical Problem Solver
"You are an AI assistant specializing in software development. A junior developer is facing the
following issue: Their Python web scraping script works fine for small websites but crashes when
trying to scrape larger sites with thousands of pages. They're using the requests library and
BeautifulSoup.
Provide a step-by-step troubleshooting guide (maximum 7 steps) to help identify and resolve the
issue. For each step, explain:
● What to check
● Why it's important
● How to implement the solution
Include code snippets where relevant. Assume the developer has basic Python knowledge but is
new to web scraping. Avoid advanced concepts without explanation. End your response with two
best practices for efficient web scraping of large sites."

You might also like