Prompting for Image Generation
In prompt engineering for image generation, there are two main aspects to consider: the content and the formatting of the image.
Description of image content
Pay attention to the level of detail you're providing in your prompt. A helpful tip to keep in mind is to describe the image you want in the level of detail you'd describe something in front of you to someone who cannot see it. When prompting for 'a university professor' or 'a nurse', most image generators will provide you with an old white man or a young white woman, respectively. This can largely be explained by bias in the training data (i.e., there are more pictures of old, white, male professors than of young, Black, female ones). This can be prevented by specifying more detail, e.g. on the gender, age, time period, skin colour, etc. of the person you want to visualise.
Image formatting and style
In image generation, the formatting and style possibilities are endless. Below are some examples of the options available.
Art style
You could specify the art style of the output. For example, do you want a pencil drawing, an oil painting, or a photorealistic image?
Amplification
You could add (subjective) adjectives or adverbs to change the output: beautiful, sweet, etc.
Angle and lighting
Especially in photorealistic images, it might be helpful to specify the angle and type of lighting you want. For example, a bird's eye view, or a portrait - soft side lighting or a spotlight.
Positive and negative prompting
Some image generators, like StableDiffusion, have introduced the concept of 'negative prompting' on top of positive prompts (i.e. telling the model what you want to see in its output). In negative prompting, you can specify what you don't want to see.
The text of this page is based largely on a document written by Tijmen Kerstens.