100% found this document useful (1 vote)
247 views

Chatgpt Slides

ChatGPT grew faster than any other app, reaching 1 million users in just 5 days, while popular apps like Instagram took 2.5 months and Facebook took 10 months to reach the same milestone. The document discusses ChatGPT's unprecedented growth rate compared to other major apps and services, and how quickly it gained widespread adoption within just days of its launch.

Uploaded by

mkranthikumarmca
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
247 views

Chatgpt Slides

ChatGPT grew faster than any other app, reaching 1 million users in just 5 days, while popular apps like Instagram took 2.5 months and Facebook took 10 months to reach the same milestone. The document discusses ChatGPT's unprecedented growth rate compared to other major apps and services, and how quickly it gained widespread adoption within just days of its launch.

Uploaded by

mkranthikumarmca
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 112

The Fastest Growing App Ever

Time it took selected apps & services to gain one million users

ChatGPT 5 days

Instagram 2.5 months

Spotify 5 months

Facebook 10 months

Twitter 2 years

AirBnB 2.5 years

Netflix 3.5 years


ChatGPT PLUS Price & Features
USD 20 / Month

Priority ChatGPT Access Faster Output Generation

Model Selection Early Access


About The Course

Beyond ChatGPT

OpenAI GPT AutoGPT &


APIs LangChain

Other AI Tools Using ChatGPT E!ciently Hands-on Demos

Prompt Content Content


Midjourney Utility Tasks Coding
Engineering Creation Creation

Coding
Foundation

Behind the
Setup Basic Usage
Scenes
Get The Most Out Of The Course!

Watch the Videos Follow Along Actively Help Each Other

At your pace: Use the video Pause & try things on your Ask & answer in the Q&A
player controls own section

On-Demand: Repeat videos Join our amazing Discord


Practice what you learned
& sections as needed community!
Course Prerequisites

No prior ChatGPT No coding experience


Built for everyone!
experience required! required!
!
Important
You will not necessarily be able to reproduce
the responses you see in the videos!
Even when using the exact same prompts.
ChatGPT has a certain degree of “randomness” & the
underlying models will evolve and change.
Understanding ChatGPT
How It Works Under The Hood

How It Works

Features & Limitations


ChatGPT Under The Hood

ChatGPT

based on

GPT LLM
is a Large Language Model
Generative Pretrained Transformer

AI model created & owned by OpenAI A machine learning model that performs
(which, despite the name, isn’t very open) natural language processing (NLP) tasks

ChatGPT can be used via the browser Trained to use probability distributions
over words & sequences of words to
GPT APIs can be used in code generate output
Natural Language Processing
lo How you
H e l
World

are
?
I’m M a x

NLP Model
(e.g., LLM)
What Are LLMs?

A large language model is an AI-powered system, based on a neural


network of “Transformers”, trained on vast amounts of text data to
generate human-like text output by predicting the next word based
on the user input prompt.

1, 2, 3, 4, 5

LLM
The 16th president was Abraham Lincoln
(e.g., GPT)

What’s a LLM? LLM stands for […]


Language Models Complete Sequences

Prompt Prompt
1, 2, 3, Give me a list of three strengths of ChatGPT. Only use one word each.

Output Output
4 Adaptive, Informative, Responsive

Might not look like a sequence

But it is one, once you think about it


LLMs Are Neural Networks
Input Layer Hidden Layers Output Layer

Input 1

Input 2 Output

Input 3

There are di"erent kinds of neural networks for di"erent purposes.


For example, models focused on analyzing images use so-called “Convolutional Neural Networks”.
Large language models use “Transformers” (or “Transfomer Neural Networks”)
LLMs Are Neural Networks

The sun is glass


drop
blue
hot
Large Language Models Are … Large

GPT 3.5 was trained via a Transformer neural


network with 175B parameters across 96 layers

175B

96
Training Data? Everything!

Publicly available text


data from the internet

GPT
Tokens Instead Of Words

Human-readable Words My favorite color is Red .

Token IDs 3666 4004 3124 318 2266 13

Tokens are not necessarily always entire words!

Tokens / Token IDs are used as inputs for the neural network
Predicting Word By Word Is Not Enough

The woman was very rich

The weather was very nice

I was very close


LLMs Detect Patterns & Relations

The weather was very nice


LLMs Detect Patterns & Relations

The weather was very nice

Two birds are sitting on

a tree . They are

building a nest
Fine-tuning & Moderation

Pre-trained Model Finetuning Moderation API

Capable of predicting Optimized for chat use-


Filters input & output
words case

ChatGPT

Output Prompt

User
ChatGPT Limitations

It’s About Patterns, It Can Only Handle &


Limited Training Data
Not Logic Output Text*

ChatGPT doesn’t really


Only data until September understand you - even It can’t search the internet,
2021 was used for training though it often seems like it can’t execute code etc.
it does

* ChatGPT plugins & third-party tools can extend the functionality


ChatGPT Context Is Limited

GPT ChatGPT

Input Input = Entire chat history

Limited to X tokens
(e.g., to 4,000 tokens)
Introduction & General Usage
Getting Started with ChatGPT

Exploring the User Interface & Writing our First Prompts

Why ChatGPT is NOT always the Single Source of Truth

Using Current Data with ChatGPT Plugins


Comparing ChatGPT 3.5 & ChatGPT 4
GPT 3.5 GPT 4
(Default)

Speed Reasoning Conciseness


Example

Andrew is free from 11 am to 3 pm, Joanne is free from noon to 2 pm and then 3:30 pm to 5 pm.
Hannah is available at noon for half an hour, and then 4 pm to 6 pm. What are some options for start times for
a 30 minute meeting for Andrew, Hannah, and Joanne?
What Should I Use?

GPT 3.5 Simple data request and / or fact based questions.


(Default)

Complex questions, requiring various parameters /


GPT 4
constraints to be considered.
Prompt

Your ChatGPT Input that describes your


Problem or Request
How to Use Prompts - Examples*

Simple Facts Context-Aware Prompts

How many citizens does


What is a Wiener Schnitzel?
Barcelona have?

Who was the first president of


Please give me the recipe.
the United States?

I need a shopping list with all


Who is Michael Jordan? ingredients for the recipe, but I
bought the meat already.

* “Prompt Engineering” will be covered in great detail in the next course module
Beware of Hallucinations!

ChatGPT can create incorrect


or non-context related output
(that still sounds plausible)
Enhance ChatGPT’s Capabilities
With ChatGPT Plugins

Code Execution Internet Access

Write & Execute Code Directly in the Retrieve Latest Data by Connecting
Browser. ChatGPT to the Internet.
Prompt Engineering
Writing Good Prompts & Getting What You Want

Prompt Engineering: Writing Good Prompts

Using Di!erent Prompting Strategies

Examples!
Why Prompt Engineering?
Good Prompts
=
Good Results
Core Prompt Elements

Context
Goal
(Additional Information)
Prompt Elements - A Closer Look

It’s all about providing (helpful) context

Constraints & Extra


Role Goal
Information
Optional Recommended
Goals & Roles

Goal Role

“Write a tweet that “You are an expert,


explains ChatGPT” engaging twitter user”

Defines the main content Controls the perspective


of the generated result and type of response
Constraints & Extra Information

Constraints & Extra


Goal Role
Information

“Write a tweet that “Target a tech-savvy “You are an expert,


explains ChatGPT” audience, avoid emojis” engaging twitter user”

Fine-tunes the result


Defines the main content Controls the perspective
content, structure &
of the generated result and type of response
format

Special Constraint:
Output Format

“Return the result


formatted as JSON”
!
Keep In Mind
ChatGPT Output Is A Starting Point
Fine-tune & adjust as needed
Refine Results Over Time

It’s a chat!

Tell ChatGPT which parts need adjustments

“Add a personal touch or note to the tweet


and also encourage readers to share their
hiking stories”
Adding Meaningful Context

Prefer short, focused sentences

Add important keywords & avoid


unnecessary information

Define the target audience

Control tone, style & length of the output

Control the output format (text, JSON,


unformatted markdown, …)
Examples & Exercises

Create a short product announcement text for a new AI-


1 powered website generator

Create a Python code snippet that searches & deletes all .png
2 & .jpg files in a given folder

Write an email to a colleague that you need feedback on


3 your submitted prototype until end of the week.
Zero-, One- & Few-Shot Prompting
Providing examples can help fine-tune the result tone, style & content

0 1 N

Zero-Shot One-Shot Few-Shot

Provide no examples Provide one example Provide multiple examples

“Write a tweet that explains the “Write a tweet that explains the
core idea behind ChatGPT. Use a core idea behind ChatGPT. Use a
“Write a tweet that explains the similar tone & structure as I do similar tone & structure as I do
core idea behind ChatGPT.” in my regular tweets. But don’t in my regular tweets. But don’t
use the content. use the content. Here are two
Here’s an example: …” example tweets: …”
Enhance Your Prompts!

Foundation Advanced

Goal + Context More techniques & tricks


Ask-Before-Answer Prompting

Constraints &
Role Goal
Information

“Before answering, I want you to first ask for any extra information
that helps you produce a better answer. If you got no questions,
please provide the answer instead.”
Perspective Prompting

Let ChatGPT Assume Di"erent Perspectives

No Perspective Single Perspective Multiple Perspectives

Assumed via Prompt Assumed via Prompt


Default
Engineering Engineering

“Create a travel itinerary for a 2- “Create a travel itinerary for a 2-


“Create a travel itinerary for a 2- weeks yoga retreat in Austria weeks yoga retreat in Austria
weeks yoga retreat in Austria.” from the perspective of the from the perspectives of a yoga
yoga trainer.” proponent and opponent.”
Examples & Exercises

Define structure &


Create a modern, minimal CV website showing your image
1 and below that a list of your working experience & skills
target output (HTML +
CSS)

Write a newsletter email that mentions two new posts on your Use Ask-Before-
2 website Answer Prompting

Use Python & JavaScript to encode input text (and output


3 that text) by shifting every character one character to the left
Perspective Prompting
More Prompting Techniques

Contextual Emotional Laddering


Prompting Prompting Prompting

Many more!
Contextual Prompting

Context

Extra information on
cultural, historical, or
situational factors

Summarize the evolution of the combustion engine over the


years since its inception.
Also evaluate its impact on society and the environment.

Consider the current shift towards renewable energy and


electric vehicles in your response.
Emotional Prompting

Context

Consider the emotional


state or tone of the user's
query

Write an email response to the following customer


complaint:
“Your products are garbage. The new chair broke 1 day after
it was shipped. You’ll hear from my lawyer.”

When drafting the response, take the sentiment and tone of


the customer into account.
Laddering Prompting

Prompt 1: Solve a part of the problem

Complex Problem Prompt 2: Solve another part of the problem

Prompt 3: Solve another part of the problem

We need a complete NodeJS REST Set up a basic NodeJS API with the following
API that handles user authentication endpoints …
and then supports di!erent routes
for creating events, reading events, Connect a MongoDB database and set up Event &
deleting events and updating User models
events. All routes except for the
“read events” route should be Add the logic for signing users up & logging users in
protected and only accessible by
authenticated users. Add the logic for handling events
Data must be exchanged formatted
as JSON and stored in a MongoDB Protect the non-read event routes against
database on the backend. unauthenticated access
Let ChatGPT Write Better Prompts

Let ChatGPT help you!

Ask ChatGPT which extra information would improve the


result & the generated content

“Which extra information do you need to


create a better tweet?”
Let ChatGPT Evaluate Itself

ChatGPT can criticize & improve


itself

Ask ChatGPT a self-reflective question

“What could be improved about your tweet?”


Ask ChatGPT For Example Prompts

Turn things around: Let ChatGPT


write prompts!

Ask ChatGPT which prompt should be used to produce an


output similar to a provided output

“Given the below example output, which


prompt would’ve yielded a similar output?”
“Super Prompts”

CAN DAN

(Code Anything Now) (Do Anything Now)

Prompt that Jailbreak ChatGPT →


“optimizes” ChatGPT Respond in unintended
for coding ways

Experiment with such prompts but don’t focus on them!

Keep in mind: ChatGPT does not truly understand you!

Focus on general prompting techniques instead


Using ChatGPT for Daily Tasks
Some Practical Implementations

Researching, Summarizing & Translating Information

Proofreading, Improving & Enhancing Text

Creating Simple Utility Tools with ChatGPT


Research
Summarizing Information
Translation & Tone Adjustment
Proofreading & Enhancing Text
Writing Utility Tools / Scripts
Using ChatGPT for Content Creation
Exploring a New Level of Creativity

Creating Blog Posts, Articles & Video Scripts

Boosting Your Social Media Posts, Writing Cover Letters & More

Generating Sample Data with ChatGPT


Writing an article / a blogpost about…

The history of the iPhone from its first


presentation until 2021.

Simplified Structured
(simple prompt) (complex prompt)
Adding Constraints

Target Audience

Topic Related Keywords

Highlight Significant Improvements

Article Length

Adding Images
Your Options are Unlimited!
Tutorials

Technology Unlocking the Power of Artificial Intelligence: A Beginner's Guide to Machine Learning

The Ultimate Guide to Cybersecurity: Protecting Your Digital Life in the 21st Century

Fitness & Sports Maximizing Your Endurance: Tips and Tricks for Long Distance Running

The Ultimate Guide to Building Muscle Mass for Beginners

Beauty & Fashion Mastering the Art of Contouring: Tips and Tricks for a Flawless Face

10 Easy Hairstyles to Try at Home for a Chic and E!ortless Look


Your Options are Unlimited!
Opinions

Recent Developments Why I Believe the Push for Renewable Energy is More Important Than Ever

Why Mental Health Should Be a Priority in Today's Society

Pros & Cons The Great Debate: Is College Education Really Worth the Investment?

The Controversy Surrounding Cryptocurrencies: Should You Invest or Stay Away?

What Impacts our Lives? The Dark Side of Social Media: How it's Destroying our Mental Health

The Dangers of Fast Fashion: How Our Addiction to Cheap Clothing is Destroying the Planet
Your Options are Unlimited!
Deep Dives

Historical Developments From Slavery to Freedom: A Historical Journey of the Civil Rights Movement

The Rise and Fall of Empires: Understanding the Historical Significance of Ancient Civilizations

How Technology Evolved From Pong to PlayStation: The Evolution of Video Game Technology

From the Abacus to AI: Tracing the Evolution of Computing Technology

Social & Econ. Research The Hidden Costs of Income Inequality: A Comprehensive Analysis of the Social and Economic
Impacts

The Power of Diversity in the Workplace: Examining the Research on Social and Economic
Benefits
And So Much More!
Adding Constraints

Video Length

Engaging & Fast-Paced Video Style

Video Footage

Background Music
Copywriting

Writing the Written Content (“Copy”)


for Marketing Materials
Understand Target Promote Product
Audience / Service

Website Content Social Media Emails

Signup for Newsletter Visit Website Buy Product


Revolutionizing Job-Related Writing

Employees Standout CVs Compelling Cover Letters

Employers Job O"ers Contracts

Emails
Diving Into Midjourney Prompts
Getting Full Control of the Images Created

Creating a Prompting Template

Using Midjourney to Create & Control Di!erent Image Styles

Creating Reusable Styles with /prefer


Midjourney Versions

“Unopinionated”
V5.1
V4 V5
RAW
Detailed Descriptions
Required

Realistic Individuals Finger Count Sharper Images

“Opinionated”
V5.1
AI Executes Idea Based
on Short Prompts
/imagine prompt photo of an elephant walking through the desert
Define the Basics &
Control the Details of the Output
that Should be Generated
5 Key Areas to Generate Amazing Output

/imagine prompt

Medium /
Subject Setting Background Atmosphere
Art Style

the ocean
cinematic
a photo of a pirate close-up in the
lighting
background

Main Content Details


Defining the Main Content

Medium / photo of sketch of


Art Style oil painting of 3d animation of
watercolored painting of cartoon of
illustration of film noir of
flat illustration of manga of
acrylic painting of 8 bit pixel art

Subject an old smiling pirate standing on his boat


Defining the Details

close-up selfie
Setting Perspective
mid-range fish-eye
fullbody panorama
portrait bird-eye view

simpsons style gtav style


Style
disney style paw patrol style
pixar style canon style
game of thrones style 35mm style
depth of field style cyberpunk style

Background the stormy ocean with high waves in the background


Describing the Details

Atmosphere sunrise golden colours


twilight vibrant colors
natural lighting black and white
cinematic lighting spring
neon lighting snowfall
studio lighting sunshine
global illumination energetic
Adding Parameters

/imagine

prompt a tiger running through the jungle, close-up, colourful —ar 16:9 —style raw

Text Prompt Parameters


Hands-On: ChatGPT Content Creation
Practicing How To Generate Content With ChatGPT

Create & Advertise a Realistic Blog Post

SEO

Add Images (Midjourney)

Creating a Video Script


Creating Content with ChatGPT
Plan a Blog Post
Topic
Keywords + Outline
Understanding ChatGPT & How It
Write the Blog Post Works Behind The Scenes

Add Images
(incl. Thumbnail)

SEO

Format as Markdown

Create YouTube Video Script


(based on Blog Post)

Create Newsletter Email

Create Marketing Tweets


ChatGPT For Programming
Writing Code with ChatGPT

Generating Code With & Without Programming Experience

Debugging & Optimizing Code

Explaining & Refactoring Code


ChatGPT Is Great For Everyone!

Non-Developers Developers

Build basic Boost your


programs (utility productivity,
scripts) & websites outsource the boring
with zero parts, generate
development dummy data & code
experience faster
ChatGPT For Non-Developers

Initial Task
(e.g., create a program that renames files)

Execute Program
(ask for help, if needed)
Iterative process until
the program is done

Report errors or missing features


Exercise Time!

Let ChatGPT build a basic website!

Starting Page CV Page

Your name List with career history

Image

List of hobbies

Website should have a modern, clean, dark-mode styling.


!
Be Careful
Code you don’t know could cause harm!
Depending on your request & prompt it
could delete files, erase data, crash your
system etc.
ChatGPT ! Developers

As a developer, you can


massively boost your
productivity by using ChatGPT!
ChatGPT For Developers

Building Block 1

Building Block 2 Combine manually


(or with additional
Entire Application
help from
Building Block 3 ChatGPT)

Building Block 4

Don’t ask ChatGPT for entire Instead, prefer asking for


applications or websites individual building blocks
ChatGPT For Developers

Building Blocks > Entire Apps Iterative Development

Use ChatGPT to speed up the development of Add more and more features by splitting your
the individual application building blocks requests across multiple prompts

Refine Code Manually Use ChatGPT For Debugging

Instead of deriving fancy prompts, consider Report errors & bugs (+ relevant code
performing fine-tuning tasks manually snippets) to ChatGPT to speed up debugging

Explain Code Use ChatGPT for Refactoring

Instruct ChatGPT to quickly explain & Let ChatGPT refactor code or use ChatGPT to
summarize unfamiliar code get improvement ideas
Don’t Limit Yourself To Just ChatGPT!

ChatGPT GitHub Copilot

Great for generating smaller


Great for generating entire
code snippets “on the fly” & fine-
building blocks
tuning your code
Useful Prompting Techniques

If Code Gets Cut O" Skip Explanations

“Provide just the code without any extra


“Output ‘Continuing’ and continue”
explanations or text.”

Add Context To Errors Let ChatGPT Improve Itself

“The user authentication code seems to


break the program with the following “How could the code be improved?”
error message: [message]”
Generate Dummy Data with ChatGPT

You’re not limited to generating code

Generate dummy data with ChatGPT


(e.g., dummy users)
Hands-On: Programming & ChatGPT
Practicing How To Write Code With ChatGPT

Non-Developer Example: Building a “Monster Slayer” Game

Developer Example: Building a Meetups REST API


Building a “Monster Slayer” Game
Using ChatGPT with no / minimal
programming experience

Building a text-based / command-line


based game: “Monster Slayer”

Description
It’s a turn-based game where the user (= player) fights a monster (= computer).
During every turn, the player can perform a regular or strong attack or heal.
The strong attack should only be available every three turns. Healing should only be
available every five turns.
After each turn, the monster attacks.
Damage & heal values are calculated randomly.
The first participant to go below 0 health loses.
Both participants start with 100 health.
Once the game is over, the winner should be displayed on the screen and the player should
be asked if a new game should be started.
Enhancing The “Monster Slayer” Game

Add Username Add Di!culty Levels Manage High Score

Allow the user to choose a Adjust damage & heal


Save the number of
username when the values based on chosen
required turns in text file
program starts level

Display the current high


score after every game
!
Results May Deviate
The Code You Get Will Likely Di"er
Because of built-in randomness, di!erent
prompts & GPT model evolution, you will
very likely not get the same results!
Building a “Meetups” REST API
Using ChatGPT with programming
experience

Building a NodeJS REST API

Description

It’s a REST API with the following endpoints:


POST /meetups → Create a new meetup
GET /meetups → Fetch meetups
PATCH /meetups/<id> → Update existing meetup
DELETE /meetups/<id> → Delete existing meetup

Every meetup has an id, title, summary & address.


Meetup data should be stored in a meetups.json file, incoming data must be validated.
Data should be exchanged in JSON format.
Enhancing The “Meetups” REST API

Add Authentication Handle Errors

Add POST /signup & POST / Throw errors & use generic
login routes error handling middleware

Use appropriate error


Implement JWT-based
status codes (e.g., 401 if not
authentication
authenticated)

Protect all routes except for


GET /meetups
The ChatGPT APIs
Integrating ChatGPT Into Your Own Apps

Why Would I Use an API Instead of ChatGPT?

Understanding & Configuring the API

Hands-On: Using the API in Your Own Applications


Application Programming Interface
Communication Between Two Applications
Using Requests & Responses
Request

ChatGPT API

Response
User Interface
User Interface = Your Website / Application

Request

ChatGPT API

Response
Recommended API Models

Understand & Generate Natural Language or Code

Model Sets

GPT-4 GPT-3.5

gpt-4 gpt-3.5-turbo
More Complex Tasks
Limited Beta Access Only
gpt-4-32k
Best Model to Get Started
Token
1 Token ~ 0.75 Words
or 4 Characters
https://platform.openai.com/tokenizer
gpt-4
8,192
gpt-4-32k
32,768
gpt-3.5-turbo
4,096

Context Limit for Prompts & Answers


Prerequisites to Use the API with Python

Python

Package Manager
e.g. pip

Open AI Library
pip install openai
API Endpoints

Completion Chat Completion

openai.ChatCompletion.create(
openai.Completion.create( model =“gpt-3.5-turbo”,
model =“text-davinci-003”, messages= [
prompt=“My Prompt”, {“role”: “user”, “content: “My Prompt”}
… ],
) …
)
Building Automated AI Workflows
Just Define The Goal, Not The Steps

Get Started with AutoGPT

Explore LangChain For Custom AI Workflows


What Is AutoGPT?

Define the Goal

AutoGPT derives & Has internet & file


executes steps access
AutoGPT Can Be Awesome

AutoGPT can get stuck in loops

Automating Tasks with AI can


But
simplify your life

Results can be wrong

e.g., automate research,


content generation & much
more!
What Is LangChain?

A Framework For Building Your Own Automated AI Workflows

Requires coding skills!

Create any kind of AI workflow

Build an email Build a web


Build anything!
generator research tool

You might also like