There’s a lot of hype around ChatGPT and AI models like it. It can take a single prompt and transform it into an entirely new piece of content. It can research virtually any topic, and deliver its findings in the form of poetry, code, lyrics, and more.
And yet, when you fire up ChatGPT and feed it a prompt, it responds with something… far from perfect. It’s too broad, too long, too bland, or misses the mark entirely.
This often happens when we don’t know how to ask, in AI-terms, what we want. In other words, the output is only as good as the input. So, if you want to master AI, knowing how to write a good prompt is key.
Here, I spoke to HubSpot’s SEO team to understand the key elements of a good prompt, along with some helpful prompt writing tips and techniques.
Table of Contents
How to Write the Perfect AI Prompt
How to Write the Perfect AI Prompt
1. Envision your ideal response.
It’s tempting to load up ChatGPT and jump right into the prompt. However, Josh Blyskal, Associate SEO Strategist at HubSpot, recommends a more introspective approach.
“The first thing you should do is figure out what you want. Before I type anything, I always take a moment to envision what the final output will look like,” he told me.
He gives an example of a marketer who wants to generate a marketing plan. Instead of typing “Write me a marketing plan” into ChatGPT, she should take the time to envision what the plan looks like — how many sections it has, how many bullet points are under each section, and what information it contains.
Now that she has a better grasp of the task at hand, it becomes much easier to compose a prompt that checks all the boxes.
2. Write a specific, action-oriented task.
AI models thrive on specificity. If you feed it with vague instructions, you give it room to interpret what it thinks you want.
For example, suppose you prompt ChatGPT to “Rewrite this [article/email/Tweet],” expecting it to write something new and original. Instead, it regurgitates your original message using the same words and phrases.
The solution is to get specific and intentional with your words.
Instead of “Rewrite,” for instance, you might say reimagine, expand, simplify, or modernize. Even a small change in the way you phrase a prompt can significantly change the response.
As Blyskal points out, “A lot of people treat AI like a rigid system that can be hacked with the right words or phrases, but that’s not the case. There are no secret keywords that can guarantee the best results. It’s like playing a game of words, and you have to think intentionally about the ones you use.”
3. Set the stage with context.
You could get away with stopping at the previous step — especially if your request is fairly straightforward (e.g., “Write five knock-knock jokes for kids”).
However, you can supercharge your prompts by padding them with context. This gives the AI model more ingredients to cook up a great response.
Bianca D’Agostino, SEO Specialist at HubSpot, puts it this way: “Suppose your friend asks you to go to the store and pick up a few things. You definitely need more context – which store, what things, what’s the budget, and so on. The more context you get from your friend, the easier it is to do the task. The same goes for AI!”
Let’s look at an example:
Both of these prompts might yield good results, but the second prompt will give you a more detailed and compelling description. This is because the AI model has more context to work with, including the product’s name (‘Squeaky Queen’), its form (a scrub), and its key features (vegan, gluten-free, recyclable packaging).
4. Add clear instructions.
Although Al models are powerful, they still need you to take the lead. Without clear instructions, they’re essentially a chef without a recipe or a new employee without a handbook.
Here’s an example: Imagine you need to write an article about Instagram marketing. Along with the main task (“Write an article about Instagram marketing“), you also instruct ChatGPT to:
“Cover the following sub-topics…”
“Incorporate the following quote/statistic…”
“Add an example to demonstrate…”
Not only are you giving ChatGPT a clear topic, but you’re also guiding and shaping the content itself. You’re adding quotes, statistics, and examples to give the output more texture.
Of course, it’s not just what you say but how you say it. The content of the article might be up to par, but it may lack a unique voice or perspective. This is where style and tones come in.
Adding Style and Tone
For Sylviain Charbit, HubSpot Senior Technical SEO Specialist, adding style to prompts is a multi-step process. He starts by letting the AI tool generate a general answer and then progressively molds its response for style.
“You can ask it to inspire itself from a situation, character, or profession, or provide it with already made examples to emulate,” he told me. Charbit also incorporates tone modifiers, such as “cheerful,” “humorous,” or “authoritative,” to guide the AI further.
Let’s look at some examples:
Other style parameters include length and format. You can specify the length of the response (e.g., “Keep the article under 800 characters”) and its format (e.g., “Create a list of bullet points”).
5. Clarify and Refine
Blyskal follows the 60% Rule.
He told me, “When you generate something and it’s at least 60% of what you want, you should continue refining that specific prompt. But if it falls short of that, it might be time to start from scratch.”
So, if you ask ChatGPT to generate ten blog ideas and you only like two, it’s a good indication to go back to the drawing board. Even if you meet the 60% threshold, you can still refine the output by giving follow-up instructions such as, “Make it sound more conversational” or “Condense this into one paragraph.”
Remember that prompt writing isn’t an exact science. Like any creative process, it often takes multiple revisions to get the right output.
Prompt Writing Techniques
Give It a Role
Role-playing is a technique that involves asking the AI model to adopt a specific role, job, or function.
“When you ask an AI model to play a specific role, you’re giving it a certain level of expertise,” Blyskal told me. “For instance, if you prompt it to act as a professional interviewer, it will look for examples of good interviewing skills and respond with professional-seeming questions.”
By defining a role for the AI model to play— such as a professional interviewer, a graphic designer, or a nutritionist — you’re also tapping into different viewpoints and perspectives, which can be especially helpful for marketers.
For example, let’s say you’re launching a new product, a cold plunge tub. You need to create an ad that appeals to your target audience: specifically, long-distance runners. In this scenario, you ask the AI model to play the role of your target audience and list the key benefits of your product.
Now the AI model will generate responses that align with the needs and preferences of long-distance runners. This gives you valuable insight into your audience, enabling you to create a more compelling and relevant ad.
Chain of Thought
Imagine you’re on a road trip, and you’re relying on GPS to guide you from point A to point B. Throughout the journey, it gives you turn-by-turn directions until you reach your destination.
Chain of thought prompting follows a similar approach. You give the AI model one prompt after another, with each prompt building on the one before it. This keeps the model on track, giving you greater control of the output.
“You’re basically asking the AI model to explain its reasoning at each step. If you don’t like any of the explanations, you can tinker with the output until it’s ready for the next prompt,” Blyskal explains.
This is ideal for tasks that can be broken down into smaller steps. For example, consider a copywriter using AI to create an article. She first prompts it to create an outline. Once she’s happy with the outline, she prompts it to write the article, and then the headline, and then the meta description. She doesn’t move to the next step until she’s satisfied with the current output.
That’s the power of chain prompting. By guiding the model in a logical sequence, you generate more accurate and relevant responses.
Provide Examples
“If there’s any one tip that will take your prompting to the next level, it’s providing examples to the AI model,” Blyskal told me.
You can think of examples as reference points, helping the AI model emulate a certain style, tone, structure, or format. On top of that, AI can analyze a piece of content and offer improvements.
Back to You
Blyskal said it best: “At the core of prompting is conversation.” You don’t engineer or program AI. Instead, you talk to it.
Like any conversation, you naturally adjust your tone, provide ample context, and share details, anecdotes, and examples to give your story texture. These are the same elements that make a really great prompt.