Skip to main content
This guide covers the fundamentals behind prompting strategies and discusses some advanced techniques. For in-depth information on prompting, see the Writer prompt crafting guide.

Fundamentals

Directive writing

Be direct and to the point:

Inclusive prompts

Include your audience in your prompt:

Structured formatting

Format your prompt with ### Instruction ###, followed by ### Question ###:

### Instruction ###
Write a poem in the style of Robert Frost.

### Question ###
What’s the poem about?

Task breakdown

Break down complicated tasks into multiple prompts:

Positive language

Use directives like “do” instead of “don’t”:

Mandatory instructions

Use phrases like You MUST:

Penalty warning

Use phrases like You’ll be penalized:

Natural responses

Request a simple response:

Unbiased descriptions

Make sure that your answer is unbiased and doesn’t rely on stereotype:

Educational writing

To write an essay, text, paragraph, article, or any detailed text:

Style consistency

Improve the tone of the text to make the writing style more professional:

Creative writing

I’ll give you the beginning of a story. Finish it and keep the flow consistent:

Linguistic mimicry

Use the same language as the following paragraph to explain the importance of exercise:

Precise instructions

Clearly state the requirements that the model must follow to produce content, in the form of keywords or instructions.

Advanced techniques

Example driven prompts

Use example-driven (few-shot) prompting:

Provide a list of idioms in English, along with their meanings and example sentences.
Here is an example for the output:

An idiom: ‘Break a leg’
Meaning: Good luck
Example sentence: ‘I’m sure you’ll do great in your interview. Break a leg!’

Chain-of-thought Prompts

Combine chain-of-thought (CoT) prompts with few-shot prompts:

System instruction: Create a product detail page for a fictional innovative smartphone by a retailer known as “TechTrend Electronics.”
Prompt 1: Start by describing the unique features of the smartphone, such as its solar-powered battery, triple-lens camera system, and foldable screen technology.
Prompt 2: Next, outline the benefits of these features for users, like extended battery life, exceptional photo quality, and enhanced device portability.
Prompt 3: Conclude with crafting compelling product descriptions and a call-to-action that entices customers to make a purchase during the upcoming holiday sale.

Delimited prompts

Use delimiters to structure text:

Summarize a series of healthcare claims documents for a fictional healthcare company, ‘HealthFirst Solutions’, using the following delimiter \n to separate different sections of the summary:
Claim Number: 123456789 \n
Date of Service: January 1, 2024 \n
Diagnosis: Acute sinusitis \n
Total Claimed: $300 \n
Status: Pending review \n