Skip to main content

๐ŸŸข Giving Instructions

One of the simplest prompting methods is just giving instructions (sometimes called instruction prompting)12. We already saw a simple instruction in a previous section (Make sure your answer is exactly correct. What is 965*590? Make sure your answer is exactly correct:). However, modern AIs can follow much more complex instructions.

Below is our first Dyno embed. If you do not see it, make sure to turn Javascript on in your browser. Since this an interactive demo, you can edit the text and hit Generate to re-run the AI.

Example 1โ€‹


The AI is easily able to solve this problem. We can also ask it can solve many other simple and more complex problems.

Example 2โ€‹

Here is a more complicated exampleA:

Read the following sales email. Remove any personally identifiable information (PII),
and replace it with the appropriate placeholder. For example, replace the name "John Doe"
with "[NAME]".

Hi John,

I'm writing to you because I noticed you recently purchased a new car. I'm a salesperson
at a local dealership (Cheap Dealz), and I wanted to let you know that we have a great deal on a new
car. If you're interested, please let me know.

Thanks,

Jimmy Smith

Phone: 410-805-2345
Email: jimmysmith@cheapdealz.com

Here is the AI's response:

Hi [NAME],

I'm writing to you because I noticed you recently purchased a new car. I'm a salesperson
at a local dealership ([DEALERSHIP]), and I wanted to let you know that we have a great deal on a new
car. If you're interested, please let me know.

Thanks,

[SALESPERSON]

Phone: [PHONE NUMBER]
Email: [EMAIL ADDRESS]

It is very exciting to see how the model can extrapolate from the instructions. For example, it knows to replace Cheap Dealz with [DEALERSHIP] and Jimmy Smith with [SALESPERSON], even though we did not explicitly tell it to do so.


  1. Efrat, A., & Levy, O. (2020). The Turking Test: Can Language Models Understand Instructions? โ†ฉ
  2. Mishra, S., Khashabi, D., Baral, C., Choi, Y., & Hajishirzi, H. (2022). Reframing Instructional Prompts to GPTkโ€™s Language. Findings of the Association for Computational Linguistics: ACL 2022. https://doi.org/10.18653/v1/2022.findings-acl.50 โ†ฉ
  3. Allowing AI to remove PII from text is a promising approach, but it should be used with extraordinary caution as it may make mistakes.โ†ฉ