Prompt engineering

HHow to Give Instructions to AI, Specifically ChatGPT? Essentially, it’s much like giving directions to a fellow human.

I often say, “Prompt engineering = AI psychology” in all my talks and consultations. The ability to craft clever instructions for artificial intelligence reflects how clearly and effectively we can communicate tasks. Let me break it down.

AI language models learn from humans: they absorb text responses and transcripts of conversations that people find valuable. When AI notices that certain types of prompts lead to more creative and accurate answers, it tends to follow that lead, mimicking our behavior.

Be Clear in Your Communication

For a long time, I thought prompt engineering was just a quirk of the system. I tried to talk myself out of being polite with a machine, but some experimentation—backed later by scientific evidence—revealed that being courteous pays off. Adding a “please” to a prompt or learning to communicate clearly with the machine can make a big difference. One takeaway is that I’ve successfully conveyed a task when the AI understands it, roughly akin to asking a capable high school student for help. Did I clearly articulate my request to a colleague? If the AI gets it, chances are I did; if ChatGPT misinterprets it, I likely didn’t express the task well.

Motivation

What motivational tools can we use to inspire AI?

  • Well-structured, logical questions. Longer prompts should be clearly segmented, with distinct parts.
  • If we’re looking for ideas or inspiration, avoid over-explaining the task; let it unfold naturally. In subsequent rounds, we can refine our vision.
  • Including a “please” can lead to a more detailed and better response, but being overly polite can be counterproductive (for example, expecting better results from saying “pretty please”).
  • We can specify what type of response we want, the style, and the length.
  • AI enjoys playing roles and can embody one or multiple characters.
  • If necessary, reiterate key elements throughout a long prompt.
  • Phrases like “on a beautiful energetic May day,” offering a $1,000 reward, or saying “you’re working for Steve Jobs” can be effective motivators.
  • For recurring tasks, it might be worthwhile to create an agent (GPT).
  • If a conversation starts to stall, it’s a good idea to start fresh.

Reading through some prompts can help you get a feel for it, but don’t expect miracles. However, it’s crucial to remember that there’s no need to overthink the art of giving instructions. AI is creative and fundamentally eager. If all you want is for it to keep going, sometimes a simple “continue” is all that’s needed.