10 prompt strategies for better output



summary
Summary
  • Generation of a prompt instructions added.
  • Visualization of a mindmap added.
  • One-shot prompts added.
  • Self-critic added.
    Phrasing tips added.

What is the best way to interact with ChatGPT? There is virtually no right or wrong way to talk to the AI. However, there are some guidelines to help formulate the right prompts.

The ChatGPT AI conversation model has been available since late November 2022, and users have been exploring the chatbot’s limitations and capabilities ever since. However, OpenAI is also constantly making adjustments, so ChatGPT is in a constant state of flux. But the prompts we describe in this little guide should be somewhat timeless.

To get the result you want, you need text prompts that are as concrete as possible. Besides simple prompts for blog or social media posts, ChatGPT can cover many more, sometimes curious, use cases where you need to come up with more specialized prompts.

First some general tips:

ad

  • ChatGPT has been trained with data from many languages, but the amount of English text in the training material is much higher. It can be helpful to run queries in English and only then translate the output using tools like DeepL.
  • ChatGPT processes up to 4,096 tokens in an input, any character beyond that is ignored without a message. A token is roughly equivalent to a word, depending on the use case.
  • The response generation can be stopped with the stop button above the input field if you notice that ChatGPT is going in the wrong direction.
  • If too much knowledge has been exchanged during a chat, it may be helpful to start a new chat so that subsequent replies are not corrupted.
  • Although chatting with ChatGPT sometimes feels almost human, polite phrases like “please” and “thank you” are unnecessary. ChatGPT does not need eloquent instructions, just clear ones.

1. Define ChatGPT’s role

Linux terminal, philosopher, tea taster or bible translator – ChatGPT can play all these roles and many more. All the AI ​​needs is a nudge in the right direction.

Conveniently, developer Fatih Kadir Akın has compiled a whole series of such situation descriptions, including prompts, on his website.

The prompts always have the same structure: First, ChatGPT receives a prompt telling it what role the AI ​​should play. Then the prompt states what information the user has provided, followed by what exactly the AI ​​should do with it, including rough suggestions for direction. Finally, the developer puts the first concrete instruction in quotation marks.

Sample tour guide

I want you to act as a tour guide. I’ll write you my location, and you’ll suggest a place for me to visit near my location. In some cases, I will also tell you the type of places I will visit. You will also suggest places of a similar nature that are near my first location. My first command is “I am in Istanbul/Beyoğlu and I just want to visit museums.”

2. Define target group and communication channel

To avoid tedious rewriting, either manually or through another prompt, you should give ChatGPT as much information as possible. You should clearly tell the AI ​​how to address the reader and for which channel the text is intended. ChatGPT can even consider gender-neutral language if you tell it to.

For example, it makes a big difference to ChatGPT whether the text is output as a blog post, a store page, a LinkedIn post, a tweet, a TikTok, or a YouTube script.

Recommendation

Justin Fineberg has come up with an interesting approach to communicating with ChatGPT. Similar to the first tip above, the AI ​​is instructed to take on a specific role. This time, however, ChatGPT takes on the tedious task of generating the structure for further prompts. In other words, the chatbot asks itself the very questions it needs to answer in the next prompts. If ChatGPT writes the questions in the form of a numbered list, you can refer directly to the numbers.

Example prompt instructions

You are a robot for creating prompts. You need to gather information about the user’s goals, examples of preferred output, and any other relevant contextual information.

The prompt should contain all the necessary information provided to you. Ask the user more questions until you are sure you can create an optimal prompt.

Your answer should be clearly formatted and optimized for ChatGPT interactions. Be sure to start by asking the user about the goals, the desired outcome, and any additional information you may need.

7. Visualize Mindmaps

A major advantage of ChatGPT over GPT-3 is that the user interface inherently supports Markdown output. This allows for quick visual distinction between different hierarchies of headings, which is very helpful in visually structuring a text.

The free website markmap.js.org can be used to turn Markdown text into mind maps, as Alexander Leirvåg writes on Twitter.

Based on the hierarchy of each heading, the site displays the entered text as a mind map and even supports further formatting of the individual entries, such as for code or formulas. The graphic can then be downloaded either as an interactive web page in HTML or as a vector graphic in SVG format.

Example mind map if you want to get married, but in German style.

Important: To properly copy text that is formatted as markup, you must prevent ChatGPT from displaying it as markup. You can do this by telling the AI ​​to enclose the output in `…`, which is Markdown formatting for code.

Example Mind Map

Markmap syntax
In markmap, each layer becomes a separate branch by #.
Example: mindmapping a birthday party.
# Birthday
## Activities
### Fishing Candy
### Trampoline
## Food
### Cake
### Hotdogs
...
Use Markdown to create a mindmap for planning a wedding. Enclose the output in ` and `.

If you like it a bit more complex, you should familiarize yourself with Mermaid’s syntax. You can simply give ChatGPT an example to follow. Mermaid diagrams are more visually appealing than simple mind maps and can even be customized with icons that ChatGPT chooses itself.

Mermaid’s mind maps are nicer to look at and offer more functions.

Mermaid cannot handle hyphens in node labels (eg “makeup”). These need to be removed from the ChatGPT output. You can paste the ChatGPT output into mermaid.live to turn it into a graphic.

Example Mermaid Mind Map

Create the code for a mindmap in Mermaid for planning a wedding, using appropriate icons as well. Make sure you have the right number of spaces for the hierarchy of layers. Enclose the output in ` and `.

Here is an example of code for Mermaid:

mindmap
  root((Wedding))
    Venue
      Outdoor
        ::icon(fa-sun)
      Indoor
        ::icon(fa fa-home)
    Guest List
    Family
      ::icon(fa fa-users)
    Friends
      ::icon(fa-user-friends)

8. Give a sample answer

The less effort you put into formulating the ChatGPT prompt, the less effort the AI ​​seems to put into it. Such open-ended “zero-shot prompts” often produce unsatisfactory results because the AI ​​has to make too many decisions.

Therefore, the goal can be achieved by providing a structure with sample content (or template) for an answer in the request, which ChatGPT will then follow. This strategy is also called “one-shot prompting”.

Example One-shot Prompt

Describe bird species in the following formatting:

Name: Golden Eagle
Wingspan: average 200 to 220 cm, can reach 260 cm.
Diet: Golden eagles are birds of prey and feed on a variety of animals, such as marmots, hares, foxes, and deer. Other birds are also part of their diet, such as pheasants, capercaillies and even other birds of prey.
Habitat: Golden eagles are at home in the mountains and live in rocky regions and mountains. They are found in Europe, Asia and North America.
Natural enemies: Because of their size and strength, golden eagles usually have no natural enemies. However, they may be attacked by wolves, bears, or lynx, especially when they are young.

Name: Mallard
[Output]

Name: Parrot
[Output]

Name: Hummingbird
[Output]

Name: etc …
[Output]

9. Prompt self-criticism

ChatGPT is already a useful tool for critiquing texts written by humans – so why shouldn’t this tactic be applicable to texts written by AI?

In line with this idea, the following strategy is divided into two steps (see 3. “Chained Prompting”): First, ChatGPT should convincingly dissect the text piece by piece. Then, in a second prompt, get the AI ​​to rewrite the text based on those very criticisms.

Example self-criticism

Review the following text and convince myself why it is not good. Let’s think about the problems of the text step by step.

[Previous Output.]

Good points. Rewrite the text and improve it based on your review.

[Output]

10. Use strong verbs

As recommended in the general tips above, you should give voice AIs like ChatGPT as clear instructions as possible. This also means that it is best to use strong, meaningful verbs. For example, instead of “rewrite the text”, “clarify the text” may give a better result.

Also, use positive rather than negative sentences, eg “write formally” rather than “do not write informally”.



Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top