#DecodingOurDaily - Prompt Engineering
top of page
Writer's pictureGreta Aleksandravičiūtė

#DecodingOurDaily - Prompt Engineering

Updated: Oct 24

What is Prompt Engineering? 


Prompt engineering is the process of writing, refining, and optimizing inputs (prompts) to guide generative AI systems in generating meaningful and coherent responses. It plays a pivotal role in crafting queries that help AI models understand not only the language but also the nuance and intent behind the query. In short, prompt engineering is the way we ask an AI to generate something that we want. 


3 Main principles of Prompt Engineering:

 

1. Be specific: The more criteria you give, the more focused the output will be. 


2. Work in steps: Break tasks into small chunks. This returns better results, just as it would with a human. 


3. Iterate and improve: Re-work the inputs and have ChatGPT improve on its own output. 

If you are looking for ways to stimulate critical thinking, encourage deeper exploration of topics, and facilitate the generation of new ideas while working with a text using prompt engineering, you need to learn how to do that by exploring what prompt engineering techniques are there to try. 

  

Techniques that are worth trying:  


Giving context – adding context to Large Language Models (LLMs). It is a super important step but often overlooked. It helps the models give more accurate answers by understanding the topic better, and without enough context, they might end up giving generic and not personalized responses. For instance, if you want the AI to write a letter to your boss as if you had written it, include your age, tone of voice, mannerisms, etc. in the prompt. 


Zero-shot prompting is a technique where a language model is given a task it has not been explicitly trained on, enabling it to generate relevant and coherent responses without prior specific training on that task. This technique is particularly useful as it allows for flexible and versatile use of language models, enabling them to provide meaningful outputs across a wide range of tasks. 

 

One-shot prompting a technique where a model is given just one example to better understand your task, enabling it to generate outputs based on that single input, even though it was not used in the training phase. Your prompt could look like this: “Using this Example 1 as a reference, write a […] script for my […] ”. This method is quite useful since it allows you to provide a model with a single example to help it understand the desired output more clearly. This simplifies the process and saves a ton of time and effort.


Few-shot prompting is a method where a few examples are provided to the language model of the tool you are using (for example, ChatGPT), to help it understand and perform a new task or adapt to a different context. This is how your prompt beginning should look: “Using these Examples 1, 2, and 3 as references <…>”. This strategy is particularly valuable because it enables rapid adaption to new tasks by taking advantage of the model's ability to generalize from a few examples while understanding and performing tasks similarly. For better understanding, you can think of it this way: few-shot prompting is like giving a smart friend a few hints so they can catch on to what you're asking them to do. 


Chain-of-thought (CoT) – a prompting technique where intermediate reasoning steps are provided to large language models (LLMs) to enhance their performance on tasks requiring logical reasoning. A simple phrase: “lets do it step by step” can make wonders in this case. It's comparable to a programmer breaking down a complex problem into smaller, manageable tasks and guiding the model through a step-by-step reasoning process that improves accuracy and makes the model's thought process more transparent and understandable to users. 


Repeat instructions at the end – it is a strategy where instructions are repeated at the conclusion of a prompt, ensuring that these instructions have a stronger influence on the generated output. You can look at it this way: it is like double-checking your work before submission, reinforcing the importance of the task's requirements to ensure they are not overlooked or misinterpreted by the model. 


All in all, although this is not an exhaustive list, the prompting techniques mentioned above, such as giving context, zero-shot, one-shot, and few-shot prompting, chain-of-thought, and repeating instructions at the end, provide innovative ways to improve desired outputs. These methods range from providing models with the necessary context for accurate responses, enabling them to tackle tasks they weren't explicitly trained on, to improving their logical reasoning and ensuring instructions are clearly understood, thereby making LLMs more efficient and adaptable to a wide array of tasks. 

 

Closing note 


At the end of the day, SUPER HOW? looks at prompt engineering as if it is the cornerstone of optimizing AI interactions, ensuring that the bridge between human inquiries and AI-generated responses is both efficient and effective. We believe that prompt engineering and its techniques significantly reduce the need for manual adjustments and accelerate the journey to achieving precise, valuable outcomes, marking a pivotal advancement in how we harness the power of artificial intelligence.  


Found this interesting? Dive even deeper into the world of prompt engineering with our FREE PROMPT ENGINEERING FRAMEWORK and make your life easier with AI now!

57 views0 comments

Recent Posts

See All
bottom of page