ChatGPT and Prompt Engineering
Prompt engineering is an AI term. In addition to ChatGPT there is Google's Bard, Microsoft's Bing, etc. The 'T' in ChatGPT was developed by Google, and GPT = generative pre-training transformer. ChatGPT is also used by MSFT.
To make prompts most effective:
- Directional/Instructional prompting: be discriptive as possible (see Output format #2).
- Output format - Ex: List 5 programming languages focused on web development explaining primary purpose for each. Generate output with format: Programming language -> Utilization
- Role-based/System prompting - Ex: You are an urban planner who has created many smart cities. 1. Create presentation slides etc... 2. No more than 3 bullet points per slide, 3. Put motivational quote on smart cities on second slide.
- Few or zero-shot prompting is a technique that leverages the capabilities of Large Language Models (LLMs) to perform specific tasks. By providing a few examples of desired output, known as "shots," you can condition the model to generate similar output, be it text, code, or images.
- Chain of thought prompting: 1) breaking down a complex subject into smaller chunks, 2) ask AI to explain the answer. Please see this pdf to see the fantastic results.
- Question #1: Currently, our company offers etc.
- Question #2: Our company has canvassed the existing marketplace etc.
- Question #3: What workflow design etc.
- Question #4: what technology stack etc.
- Question #5: what future technology etc.
- Question #6: what segment etc.
- Question #7: how would you etc.
- Question #*: what would you etc.
- Tone prompting - ex: Rewrite the following email in the style of Rudyard Kipling and make it rhyme.
- Style prompting - ex: Re-write any email that I paste in here using my style of writing. As a reference I will provide 2-3 samples I wrote: etc... ending with: To repeat, taking these 2-3 emails into account, rewrite any future text that I provide here in that style of writinhg. Got it?
- Structure your data into a markdown table - ex: Marko is working in the IT industry as a QA. He was living in Belgrade, capital of Serbia, but after Covid he moved to Thailand to work remotely.
- Text summarization - ex: Summarize the following text and create a title. Output format: SUMMARY: Text TITLE: Created Title
- Classification text - ex: Classify provided text into three classes: Negative, Positive, Neutral. Output format: [SENTIMENT]: Text
- Coding generation, test your code
ChatGPT Plugins
Plugin other sources of data which then get incorporated into the LLM. There are a lot of plugins, such as Kayak or Zillow, but you gotta have the professional version of ChatGPT. For example, you can use the Bing plugin and then prompt "using the internet as a source, present a list of the latest compositions for viola in the last 10 years."
I upgraded, used Kayak, and then thought I oughta figure out what it would take to develop a PRS plugin... used edX plugin and asked "given the fact that I have a basic understanding of programming in HTML, what are the educational steps I need to take to create a chatgpt plugin?" See answer here.
AI Image generation
They are using Midjourney with Discord. No longer free. There are free image generators. We have, as part of Adobe, Firefly.
- Do you want a photo or a painting?
- What's the subject? Ex: painting of a cat
- What camera angle? Lighting? Background? Ambience? Location?
- You can blend images, etc in Photoshop
- Uploiad an image and ask AI to generate a prompt on that image
- Naming conventions (prefix, suffix)
- Negative prompting (no clouds in background)
- An aspect ratio is a proportional relationship between an image's width and height. For example, 1:1 means width and height are the same.
- Prompt examples: --ar 5:4 --chaos 90 --stop 75
- Dall-e is the chatgpt image generator