-: Certain tasks are best described in a step-by-step manner.
It's possible for us to tell a language model,
such as GPT-4 or ChatGPT,
a step-by-step approach,
which we have predetermined or predefined.
Let's have a look at how this works inside of an example.
In this prompt, we've specified two steps
that we'd like ChatGPT to follow.
The first step, Step 1, is:
The user will hand over a chunk of text
enclosed in triple quotes.
So we're gonna enclose our text in triple quotes.
Your task is to condense this text into a single sentence
starting with the phrase summary.
Step two, translate the summarization you made in step one
into Spanish, leading the translation
with the phrase, translation.
And then we've got this saying,
I love learning about prompt engineering.
It's pretty interesting, let's keep going.
Chat GPT has effectively done both steps sequentially.
Firstly, we've got one sentence we've summary.
The user expresses interest in enthusiasm in learning
about prompt engineering, and we've also got a translation.
Also, notice that it utilized our prefixes, summary,
and translation.
So if you have a task that you think needs
to be done in a series of steps, you could specify
the steps beforehand,
insert these into a prompt,
and that would encourage the language model
to follow that chain of thought.