Skip to Content

The art of Prompt Crafting – Interactive Prompting and the role of Acting Roles

Jeroen Egelmeers
Jan 30, 2024

The concept of interactive prompting and the use of (customized) acting roles are helpful in enhancing productivity and precision in communication with GenAI models. This blog delves into these advanced aspects of prompt engineering, providing insights into their practical applications. Please note that this is based on the Crafting AI Prompts Framework. Make sure you have read the previous blog in this series regarding the framework.

Interactive Prompts: enhancing dialogue with GenAI

Interactive prompts involve creating a dynamic conversation flow with AI tools like ChatGPT. This method fosters a back-and-forth exchange, allowing for more refined and contextually relevant responses. By designing prompts that build upon previous inputs, you enable ChatGPT to respond with awareness of the ongoing conversation. This leads to more coherent and pertinent outputs. This is also why it’s an essential part of the Crafting AI Prompts Framework (i). Let’s explore some examples and how to apply an interactive approach in your prompts.

Unique IDs

Assigning unique IDs to each part of the output is a powerful technique in interactive prompting. For instance, let ChatGPT generate a table with ideas, but start each row in the table with a unique ID. This organizes the conversation, making it easier to reference specific responses or interactions. If you appreciate the idea suggested by ChatGPT in the third row of your table, you can simply refer to its ID in the next prompt.

Seed Numbers from images

Another key example is when generating images. When ChatGPT (or, in this case, DALL-E 3) generates images, it assigns a “seed number” to store the image. This seed number is the unique ID that refers to the generated image. When you generate an image and ask in your prompt to also return the seed number, it will help you refer to this image later on in the conversation. In ChatGPT, I have for example added a Custom Instruction that when generating images, it should always return the seed number below the image. This way, I don’t have to think about it anymore and can interact super-fast with earlier created images.

Both methods are particularly useful in scenarios involving multiple interactions or complex dialogue sequences, enhancing the overall clarity and efficiency of the communication.

Customized Acting Roles

Creating customized acting roles in ChatGPT allows for more personalized interaction. You can define specific personas or roles for ChatGPT to adopt, ensuring that the responses align with the desired expertise or perspective.

First, let’s look again at what an acting role is: following the Crafting AI Prompts Framework, we should instruct ChatGPT to use an acting role. For example, when writing a LinkedIn post: instructing ChatGPT to act as a “LinkedIn expert with 10 years of experience” can be beneficial. This will, for example, automatically influence the model to adopt a confident and knowledgeable tone, suited for professional networking contexts, and use hashtags, a nice title for your post, etc., all of which it learned from its training data of LinkedIn experts.

The use of acting roles significantly influences the style and content of ChatGPT’s responses. Different roles, such as an expert with 5, 10, or 20 years of experience, can lead to variations in the output, from the tone of confidence to the type of information provided. Understanding and experimenting with these roles can lead to more tailored and effective communication strategies. Simply asking ChatGPT what output format it will use when adopting a specific acting role can provide useful information and a better understanding of the expected output.

It is also possible to refine those acting roles. Begin by mentioning which acting role it should mimic, and then refine it by specifying certain attributes, such as: “act as a LinkedIn expert with 10 years of experience but use a {specified tone of voice},” for example.

Finally, you can define your own acting role. For instance, you can add a Custom Instruction (or manually enter it at the beginning of each conversation if required) with specific acting roles such as: “If I ask you to ‘act as {your name},’ use a formal tone,” etc. Now, every time you ask it to act like {your name}, it will take the instructions you defined into account.

Predefine your own writing style in an Acting Role

The previous example is highly valuable for mimicking your own writing style (craft – r) every time you use your own predefined acting role (craft – a). For example, copy some content you wrote earlier into ChatGPT and ask it to describe your writing style. Then, incorporate this writing style into your predefined acting role. Every time you use this acting role, it will now mimic your writing style and thus will provide more authentic content. When using this method, please be aware of the context window of the model. More about this in my next blog.

Conclusion

Interactive prompting and the use of customized acting roles in AI tools like ChatGPT represent significant advancements in the field of prompt engineering. These techniques offer a more nuanced and personalized approach to AI interactions, allowing for more precise and relevant communication. By mastering these methods, users can significantly enhance their productivity and the effectiveness of their AI-driven tasks, unlocking new potentials in AI-driven communication.

In the next series of this blog, we’ll explore the Context Window of models and Prompting Techniques!

About the author

Jeroen Egelmeers

Prompt Engineering Advocate & Trainer | Netherlands
Jeroen Egelmeers is a Prompt Engineering Advocate at Sogeti Netherlands. Jeroen also serves as a Software Engineer Trainer. 

    Leave a Reply

    Your email address will not be published. Required fields are marked *