AI & ChatGPT
An Introduction for Business Users (and some advance use cases)
Disclaimer: Many of the text and images are acquired from the
internet with fair usage under the creative common license
Types of AI
Types of
AI
https://www.neilsahota.com/what-is-artificial-intelligence-how-does-it-work/
Types of
Machine
Learning
What is
Generative
AI and why it
matters to
you
Overview of
ChatGPT
• ChatGPT History
• By OpenAI
• Public release in Nov 2022
• Touted as the fastest app to reach 100M
users (in 2 months)
• Other products include DALE-E,
Whisper, GPT4, Jukebox, Musenet
• What in the name …ChatGPT
• Two parts, CHAT and GPT
• Chat is the application of GPT
• GPT means – Generative Pre-Trained
Transformer
Some ChatGPT facts
• It is a Large Language Model trained using Reinforcement Learning From Human Feedback (RLHF)
– a sort of non-supervised pre-trained model
• Has over 175 Billion parameters and trained on a dataset of over 300B words
• Cost US100,000 to run/day, approximately US3M/month
• Gets approximately 1B queries/day
• Has a “Plus” version at US20/month
• Has API access for free and for US5/month
• Official apps for iOS and now Android worldwide
• Android: https://play.google.com/store/apps/details?id=com.openai.chatgpt&hl=en_US
• iOS: https://apps.apple.com/my/app/chatgpt/id6448311069
• Important: Do not use other 3rd party apps that do the same as above!
ChatGPT
Versions
• https://zeball.com/6430/c
hatgpt-free-vs-chatgpt-plus-
whats-the-difference/
What is
ChatGPT good
at
• All things text related and language agnostic
• Coding (Mainly javascript, python and java ..also C++,
PHP and Ruby/ROR)
• Different languages (100+, including BM)
• Can be used to translate
• Sentiment analysis
• Research facts and data from up to Sept 2021
• Mimic your writing style
• Write different types of topics and scenarios
• And many more…(we’ll explore some interesting ones)
What is
ChatGPT Not
good at
• Data post Sept 2021
• ChatGPT has known erroneous replies when
dealing with nuances
• Mathematics and related domains (without plugins
may incur inaccuracies)
• Factual errors over unpopular topics/subjects or
ambiguous data
• Opinionated/ethical considerations
Recent
announcements
• Custom instructions
• GPT4 api (paid)
• Higher message limits for GPT ¾
• Free = 30 / hour
• Paid = 50 / hour for GPT4 (its unspecified for
GPT3)
• Code interpreter
• Browsing (now disabled )
• Disable chat history
• Many other model improvements
Mastering
Prompts
ChatGPT Schematic Approach
• Techniques for refining
• Role playing
• Writing style
• Defining output
• Chain a conversation
• Inject relatable data to further tune the output to your whim
Define personality
Define
Requests/Constraints
Define scope or
provide examples
Produce additional
data if exist
Define output type
Provide extra data
examples to further
enhance your output
Increase
Effectiveness
• Use new chat sessions to reduce convolution from
previous topics
• Confusing or ambiguous prompts
• Provide context as much as possible to garner best
responses
• Use examples when you require specifics (follow the
schematic guide for best outcome)
• Remember: GIGO
Increase
Effectiveness
• The Better Your Input, The Better The Output
• The ability to “produce better outcome” will
requires further clarification on the question,
right? Maybe we can tell ChatGPT to seek
clarification?
• Reset
• Forget everything above and start anew
• Derive Knowledge from Information
• Explain to me how you deduced this
• Create deviation
• Don’t answer like typical ChatGPT (not all the time
effective, works for bigger text)
ChatGPT
Extensions
• Extensions
• Plugin store (100s!)
• Code interpreter
• Image generator
• Data analysis and visualization
• Files conversion
• Write and execute code
• Solve math problems (same as Mixbox)
• Plugin store examples
• Pdf plugin – AI PDF
• Travel – KAYAK
• Google related ChatGPT
• Mixbox: Math
• And with Zapier, 5000+ functions/integrations
Prompt tips and tricks
Prompts That
Could Be Useful
To You
• Summarizing Content
• Especially useful when dealing with large text
• If you have large text above 8k/16k characters, put them into “pages”
• E.g., I have 10 pages of data exceeding 80,000 words, i will place them here
in 10 pages, denoting page 1 through page 10. At the end, when i am done, i
want you to summarize the entire content when i enter the keyword
"Summ”
• Page 1
• <Text>
• Page 2
• <Text>
Prompts That
Could Be Useful
To You
• Splitting perspectives
• Ask it to give opinions of points in your presentation deck
from multiple perspectives, e.g., from a perspective of an
expert vs perspective of a novice user
Prompts That
Could Be Useful
To You
• Figuring out your customers to invite
• “You are an expert marketeer with 20 years expertise in online
and offline marketing and you are especially good at audience
relationship. You are planning to run an event to introduce
ZeeWall, the world’s most advance firewall. Please produce a list
of customer profiles that you will consider inviting”
Prompts That
Could Be Useful
To You
• Model thinking
• Getting best models for given task
• “You are an expert project management consultant using
strategic models to achieve better thinking in doing tasks in
deploying NagiosXI monitoring solution for customers. Also
state the benefits of this model and create a detailed writeup
how to use it”
Prompts That
Could Be Useful
To You
• Google expert search criteria
• Getting best Google / Bing search questions
• You are expert in Google searches and have over 10 years helping businesses succeed
by training them to use Google search effectively. Give me 10 search ideas for
How to create a hugely successful chef association here in Malaysia.
Make the search terms specific and powerful to help us get to the information we
need faster. Present your response in a table, using the columns "Search Term" and
"Information we're looking for"
Prompts That
Could Be Useful
To You
• Google expert search criteria
• Getting best Google / Bing search questions
• You are expert in Google searches and have over 10 years helping businesses succeed by
training them to use Google search effectively. Give me 10 search ideas for
How to create a hugely successful chef association here in Malaysia.
Make the search terms specific and powerful to help us get to the information we need
faster. Present your response in a table, using the columns "Search Term" and
"Information we're looking for"
Prompts That
Could Be Useful
To You
• Build great SEO topics for your blog (then create blogs, see next slide)
• Blogging/Article helps companies achieve better SEO
• “You are an SEO expert and working for a top consulting company here in
Malaysia. Come up with 5 hot blog topics that will help with my company’s
SEO for the product I carry and that is Woocommerce Pro. Also ensure the
topics are professional and unique”
Prompts That
Could Be Useful
To You
• Improve any text
• Copy and paste and just enter “Improve the following text and
make it sound more profession
• Emails
• WhatsApp text
• Website text
• Documentation
• Etc etc.
Prompts That
Could Be Useful
To You
• Look at life from both sides ….
• Get ChatGPT to give alternative views on your <strong>
opinion about something
• This is also a good method for objection handling
• Or seeing viewpoints of others
Prompts That
Could Be Useful
To You
• Sales ninja
• Try this kind of prompt for your next Sales Pitch
You are a highly successful and experienced sales professional. You know what it is
that encourages people to spend money on a product with a smile on their face. I
want you to help me find and articulate the reasons why people would buy my
product, Zendesk. Please ask me questions one by one to learn about the product
and the audience. Once you have enough information, please create a numbered
table listing the selling points, how they can be articulated and whether they are of
primary, secondary or tertiary importance.
Other cool
prompts and
what they do
The prompt The purpose
Act as <insert profession> Gives you articulation based on that
profession
Act as <linux terminal, sql server, javascript
console>
To test out and play with code (aside from
using codeinterpreter)
Compare <data 1> and <data 2> and come
up with your interpretation as a <insert
profession>
To take two or more data points and
summarize or interpret them, e.g. interpret
them as a cybersecurity professional
Give advice as <profession> for <scenario> E.g. as mental health professional ..
Build <code> to do <function, feature>
written in <programming language>
To build specific code snippets, or you can
also ask it to check the code, optimize it etc
Get medical advice I’ve got this burning sensation when I pee….
Provide ideas for doing <business type> Provide ideas related to business to try and
start “right”
Solve this problem i have with my boss
<problem>
Self explanatory
Programming with
ChatGPT
INTEGRATING CHATGPT
Before integrating ChatGPT into your system, you will need 3 things:
OpenAI API Key
API key is basically an encrypted text that a
developer must obtain in order to access the
API. It is obtainable via creating an OpenAI
account
Token
Tokens can be thought of as pieces of words.
Before the API processes the prompts, the
input is broken down into tokens.
Model
Models are basically the brain for the AI,
each model has it different used for fine-
tuning with different price range.
Slide by ML Scientist Aiman@orencloud.com
Sign up or log in to the official OpenAI
platform.
(https://platform.openai.com/signup)
Login/Signup OpenAI
Click On Personal Tab select View API
Keys and you will lend on API Key page
Go To OpenAI API Tab
Click On Create New Secret Key.
you are all set to integrate ChatGPT into
your system!
Generate API Key
CHATGPT API KEY ACCESS
01 02 03
Slide by ML Scientist Aiman@orencloud.com
"You miss 100% of the shots you don't take"
- Wayne Gretzky
*This quote cost 11 tokens
CHATGPT API TOKEN
• 1 token ~= 4 chars in English
• 1 token ~= ¾ words
• 100 tokens ~= 75 words
• 1-2 sentence ~= 30 tokens
• 1 paragraph ~= 100 tokens
• 1,500 words ~= 2048 tokens
Model Input Output
8K context $0.03 / 1K tokens $0.06 / 1K tokens
32K context $0.06 / 1K tokens $0.12 / 1K tokens
Model Training Usage
Ada $0.0004 / 1K tokens $0.0016 / 1K tokens
Babbage $0.0006 / 1K tokens $0.0024 / 1K tokens
Curie $0.0030 / 1K tokens $0.0120 / 1K tokens
Davinci $0.0300 / 1K tokens $0.1200 / 1K tokens
Slide by ML Scientist Aiman@orencloud.com
Extending ChatGPT (with free tools)
• DocsGPT (GH - https://github.com/arc53/DocsGPT )
• Quivr (GH - https://github.com/StanGirard/quivr )
• Many more in Github which you can try
https://github.com/search?q=ChatGPT&type=repositories&s=stars&o
=desc
• Dumb code example with python next slide
ChatGPT APIs (hello-world sample in python)
#!/usr/bin/python3
import openai
import os
openai.api_key = ‘<redacted>’
os.system('clear')
user_content = input("Please enter your question: ")
response = openai.ChatCompletion.create(
model="gpt-3.5-turbo",
messages=[
{"role": "system", "content": "You are IA Champion BOT"},
{"role": "user", "content": user_content},
]
)
print(response['choices'][0]['message']['content'])
https://platform.openai.com/docs/api-reference/chat/create
Soft considerations
and conclusion
Ethical
considerations
• Copyright? Who does the prompt output belong to?
• Privacy concerns – Can it infiltrate private or personal
info?
• AI Biases – It may not have sentience to deduce what’s
right from wrong
• Source corruption/misinformation? - Must check the
output every time, do not just copy/paste.
• Jailbreaking? – Force it to do things deemed
contraband/illegal
• There aren’t laws to govern use of AI or building AI
models
• Cybersecurity threats?
• Job security?
• ChatGPT is outdated.
Other cool
AI tools for
business
“From Yearning
for Human-Like
Computers to
Aspiring to
Compute Like
Them!”

ChatGPT For Business Use

  • 1.
    AI & ChatGPT AnIntroduction for Business Users (and some advance use cases) Disclaimer: Many of the text and images are acquired from the internet with fair usage under the creative common license
  • 2.
  • 3.
  • 4.
  • 5.
    What is Generative AI andwhy it matters to you
  • 6.
    Overview of ChatGPT • ChatGPTHistory • By OpenAI • Public release in Nov 2022 • Touted as the fastest app to reach 100M users (in 2 months) • Other products include DALE-E, Whisper, GPT4, Jukebox, Musenet • What in the name …ChatGPT • Two parts, CHAT and GPT • Chat is the application of GPT • GPT means – Generative Pre-Trained Transformer
  • 7.
    Some ChatGPT facts •It is a Large Language Model trained using Reinforcement Learning From Human Feedback (RLHF) – a sort of non-supervised pre-trained model • Has over 175 Billion parameters and trained on a dataset of over 300B words • Cost US100,000 to run/day, approximately US3M/month • Gets approximately 1B queries/day • Has a “Plus” version at US20/month • Has API access for free and for US5/month • Official apps for iOS and now Android worldwide • Android: https://play.google.com/store/apps/details?id=com.openai.chatgpt&hl=en_US • iOS: https://apps.apple.com/my/app/chatgpt/id6448311069 • Important: Do not use other 3rd party apps that do the same as above!
  • 8.
  • 9.
    What is ChatGPT good at •All things text related and language agnostic • Coding (Mainly javascript, python and java ..also C++, PHP and Ruby/ROR) • Different languages (100+, including BM) • Can be used to translate • Sentiment analysis • Research facts and data from up to Sept 2021 • Mimic your writing style • Write different types of topics and scenarios • And many more…(we’ll explore some interesting ones)
  • 10.
    What is ChatGPT Not goodat • Data post Sept 2021 • ChatGPT has known erroneous replies when dealing with nuances • Mathematics and related domains (without plugins may incur inaccuracies) • Factual errors over unpopular topics/subjects or ambiguous data • Opinionated/ethical considerations
  • 11.
    Recent announcements • Custom instructions •GPT4 api (paid) • Higher message limits for GPT ¾ • Free = 30 / hour • Paid = 50 / hour for GPT4 (its unspecified for GPT3) • Code interpreter • Browsing (now disabled ) • Disable chat history • Many other model improvements
  • 12.
  • 13.
    ChatGPT Schematic Approach •Techniques for refining • Role playing • Writing style • Defining output • Chain a conversation • Inject relatable data to further tune the output to your whim Define personality Define Requests/Constraints Define scope or provide examples Produce additional data if exist Define output type Provide extra data examples to further enhance your output
  • 14.
    Increase Effectiveness • Use newchat sessions to reduce convolution from previous topics • Confusing or ambiguous prompts • Provide context as much as possible to garner best responses • Use examples when you require specifics (follow the schematic guide for best outcome) • Remember: GIGO
  • 15.
    Increase Effectiveness • The BetterYour Input, The Better The Output • The ability to “produce better outcome” will requires further clarification on the question, right? Maybe we can tell ChatGPT to seek clarification? • Reset • Forget everything above and start anew • Derive Knowledge from Information • Explain to me how you deduced this • Create deviation • Don’t answer like typical ChatGPT (not all the time effective, works for bigger text)
  • 16.
    ChatGPT Extensions • Extensions • Pluginstore (100s!) • Code interpreter • Image generator • Data analysis and visualization • Files conversion • Write and execute code • Solve math problems (same as Mixbox) • Plugin store examples • Pdf plugin – AI PDF • Travel – KAYAK • Google related ChatGPT • Mixbox: Math • And with Zapier, 5000+ functions/integrations
  • 17.
  • 18.
    Prompts That Could BeUseful To You • Summarizing Content • Especially useful when dealing with large text • If you have large text above 8k/16k characters, put them into “pages” • E.g., I have 10 pages of data exceeding 80,000 words, i will place them here in 10 pages, denoting page 1 through page 10. At the end, when i am done, i want you to summarize the entire content when i enter the keyword "Summ” • Page 1 • <Text> • Page 2 • <Text>
  • 19.
    Prompts That Could BeUseful To You • Splitting perspectives • Ask it to give opinions of points in your presentation deck from multiple perspectives, e.g., from a perspective of an expert vs perspective of a novice user
  • 20.
    Prompts That Could BeUseful To You • Figuring out your customers to invite • “You are an expert marketeer with 20 years expertise in online and offline marketing and you are especially good at audience relationship. You are planning to run an event to introduce ZeeWall, the world’s most advance firewall. Please produce a list of customer profiles that you will consider inviting”
  • 21.
    Prompts That Could BeUseful To You • Model thinking • Getting best models for given task • “You are an expert project management consultant using strategic models to achieve better thinking in doing tasks in deploying NagiosXI monitoring solution for customers. Also state the benefits of this model and create a detailed writeup how to use it”
  • 22.
    Prompts That Could BeUseful To You • Google expert search criteria • Getting best Google / Bing search questions • You are expert in Google searches and have over 10 years helping businesses succeed by training them to use Google search effectively. Give me 10 search ideas for How to create a hugely successful chef association here in Malaysia. Make the search terms specific and powerful to help us get to the information we need faster. Present your response in a table, using the columns "Search Term" and "Information we're looking for"
  • 23.
    Prompts That Could BeUseful To You • Google expert search criteria • Getting best Google / Bing search questions • You are expert in Google searches and have over 10 years helping businesses succeed by training them to use Google search effectively. Give me 10 search ideas for How to create a hugely successful chef association here in Malaysia. Make the search terms specific and powerful to help us get to the information we need faster. Present your response in a table, using the columns "Search Term" and "Information we're looking for"
  • 24.
    Prompts That Could BeUseful To You • Build great SEO topics for your blog (then create blogs, see next slide) • Blogging/Article helps companies achieve better SEO • “You are an SEO expert and working for a top consulting company here in Malaysia. Come up with 5 hot blog topics that will help with my company’s SEO for the product I carry and that is Woocommerce Pro. Also ensure the topics are professional and unique”
  • 25.
    Prompts That Could BeUseful To You • Improve any text • Copy and paste and just enter “Improve the following text and make it sound more profession • Emails • WhatsApp text • Website text • Documentation • Etc etc.
  • 26.
    Prompts That Could BeUseful To You • Look at life from both sides …. • Get ChatGPT to give alternative views on your <strong> opinion about something • This is also a good method for objection handling • Or seeing viewpoints of others
  • 27.
    Prompts That Could BeUseful To You • Sales ninja • Try this kind of prompt for your next Sales Pitch You are a highly successful and experienced sales professional. You know what it is that encourages people to spend money on a product with a smile on their face. I want you to help me find and articulate the reasons why people would buy my product, Zendesk. Please ask me questions one by one to learn about the product and the audience. Once you have enough information, please create a numbered table listing the selling points, how they can be articulated and whether they are of primary, secondary or tertiary importance.
  • 28.
    Other cool prompts and whatthey do The prompt The purpose Act as <insert profession> Gives you articulation based on that profession Act as <linux terminal, sql server, javascript console> To test out and play with code (aside from using codeinterpreter) Compare <data 1> and <data 2> and come up with your interpretation as a <insert profession> To take two or more data points and summarize or interpret them, e.g. interpret them as a cybersecurity professional Give advice as <profession> for <scenario> E.g. as mental health professional .. Build <code> to do <function, feature> written in <programming language> To build specific code snippets, or you can also ask it to check the code, optimize it etc Get medical advice I’ve got this burning sensation when I pee…. Provide ideas for doing <business type> Provide ideas related to business to try and start “right” Solve this problem i have with my boss <problem> Self explanatory
  • 29.
  • 30.
    INTEGRATING CHATGPT Before integratingChatGPT into your system, you will need 3 things: OpenAI API Key API key is basically an encrypted text that a developer must obtain in order to access the API. It is obtainable via creating an OpenAI account Token Tokens can be thought of as pieces of words. Before the API processes the prompts, the input is broken down into tokens. Model Models are basically the brain for the AI, each model has it different used for fine- tuning with different price range. Slide by ML Scientist Aiman@orencloud.com
  • 31.
    Sign up orlog in to the official OpenAI platform. (https://platform.openai.com/signup) Login/Signup OpenAI Click On Personal Tab select View API Keys and you will lend on API Key page Go To OpenAI API Tab Click On Create New Secret Key. you are all set to integrate ChatGPT into your system! Generate API Key CHATGPT API KEY ACCESS 01 02 03 Slide by ML Scientist Aiman@orencloud.com
  • 32.
    "You miss 100%of the shots you don't take" - Wayne Gretzky *This quote cost 11 tokens CHATGPT API TOKEN • 1 token ~= 4 chars in English • 1 token ~= ¾ words • 100 tokens ~= 75 words • 1-2 sentence ~= 30 tokens • 1 paragraph ~= 100 tokens • 1,500 words ~= 2048 tokens Model Input Output 8K context $0.03 / 1K tokens $0.06 / 1K tokens 32K context $0.06 / 1K tokens $0.12 / 1K tokens Model Training Usage Ada $0.0004 / 1K tokens $0.0016 / 1K tokens Babbage $0.0006 / 1K tokens $0.0024 / 1K tokens Curie $0.0030 / 1K tokens $0.0120 / 1K tokens Davinci $0.0300 / 1K tokens $0.1200 / 1K tokens Slide by ML Scientist Aiman@orencloud.com
  • 33.
    Extending ChatGPT (withfree tools) • DocsGPT (GH - https://github.com/arc53/DocsGPT ) • Quivr (GH - https://github.com/StanGirard/quivr ) • Many more in Github which you can try https://github.com/search?q=ChatGPT&type=repositories&s=stars&o =desc • Dumb code example with python next slide
  • 34.
    ChatGPT APIs (hello-worldsample in python) #!/usr/bin/python3 import openai import os openai.api_key = ‘<redacted>’ os.system('clear') user_content = input("Please enter your question: ") response = openai.ChatCompletion.create( model="gpt-3.5-turbo", messages=[ {"role": "system", "content": "You are IA Champion BOT"}, {"role": "user", "content": user_content}, ] ) print(response['choices'][0]['message']['content']) https://platform.openai.com/docs/api-reference/chat/create
  • 35.
  • 36.
    Ethical considerations • Copyright? Whodoes the prompt output belong to? • Privacy concerns – Can it infiltrate private or personal info? • AI Biases – It may not have sentience to deduce what’s right from wrong • Source corruption/misinformation? - Must check the output every time, do not just copy/paste. • Jailbreaking? – Force it to do things deemed contraband/illegal • There aren’t laws to govern use of AI or building AI models • Cybersecurity threats? • Job security? • ChatGPT is outdated.
  • 37.
    Other cool AI toolsfor business
  • 38.
    “From Yearning for Human-Like Computersto Aspiring to Compute Like Them!”

Editor's Notes

  • #34 pip install --upgrade openai
  • #35 pip install --upgrade openai