Prompting
How do I get great results?
Generative AI tools allow a conversational style of querying and rely on the user to prompt content to be produced. The quality of results depends on your prompts and the data set the AI tool uses. You can explore prompting techniques by researching, reading or taking a short course but using one or more of the following techniques will assist in producing better results.
- Context: Add context to your prompt - this is generally the simplest and is very powerful. It could be by giving the AI a persona (i.e. ‘act as a University tutor who is expert in Statistical analysis’), by giving it an audience (i.e. ‘you are writing a summary for a high school student’), or by giving it an output format (i.e. ‘give me data in a .CSV file’).
- Multiple examples: Use the few shot technique (sometimes called showing examples). This means giving the AI tool several examples to work from so that it follows the logic. (i.e. Add 7 + 7: 14, Add 13 +9: 22, Add 15 + 19: ) This can work well for classifying qualitative research data and similar activities.
- Use Step-by-step approach: Use chain of thought prompting. This involves including in your prompt a request to go step by step through a process. (i.e. ‘First, create an outline of the steps, then produce a paragraph for each step, then revise the draft and make it better.’)
Similar to searching in a library database, you should be prepared to iterate. Look at the results produced, experiment by adding in more context (such as providing additional information on the style or complexity of writing) and continue until the output is what you need.
Prompting for image creation works slightly differently:
- Context may include a description of your desired subject (i.e. a single hospital room with a patient in a bed in front of a large window, a nurse and a large chair. The patient is propped up on pillows and attached to a heart monitor, the nurse is checking the monitor with a clipboard in their hands) with details such as style of image (i.e. impressionist, cartoon, 1970s photo), colours that you want to predominate or for specific parts of the image (i.e. the nurse's uniform is lilac), any emotions or feelings that you wish to include as well as specific lighting.
- Some image generation tools allow you to input another image (or select an existing image) as a reference for the AI to build on (another way of showing examples).
- For output, you may wish a specific aspect ratio (i.e. if you are using it for a ppt as opposed to in text in a document) or quality (size of image).
When prompting you should be prepared to iterate - some tools have built in options around the style of image and allow you to edit specific elements of the generated image, add text and apply a range of filters.
University of Adelaide Library. (2024, May 6). GenAI Masterclass | Part 3 - Prompt AI [Video]. YouTube. https://youtu.be/WrryYZMx59s?si=YnUZn3gM24M9KMCR&t=1015