0PricingLogin
AI Prompt Engineering · Lesson

Anatomy of an Image Generation Prompt

Subject, style, medium, lighting, color palette, and composition elements.

Image Prompt as a Recipe

An image generation prompt is a recipe for a visual. Like cooking, the order and balance of ingredients matters. Missing elements produce generic results; wrong elements produce surprising failures. Mastering the anatomy of a prompt gives you predictable creative control.

The Six Core Components

Every strong image prompt contains six components: Subject (what), Style (how it looks), Medium (art form), Lighting (illumination), Color Palette (tone), and Composition (framing). Omitting any component leaves the model to guess — usually with generic defaults.

# Anatomy of an image prompt
prompt_components = {
    'subject':    'A lone lighthouse on a rocky coastline',
    'style':      'dramatic, moody, cinematic',
    'medium':     'oil painting',
    'lighting':   'stormy overcast sky, waves crashing, dramatic side-lighting',
    'color_palette': 'desaturated blues and grays with warm amber light from the lighthouse',
    'composition': 'wide establishing shot, rule of thirds, lighthouse at left third'
}

# Assemble into a prompt string
full_prompt = (
    '{subject}, {style}, {medium}, {lighting}, '
    '{color_palette}, {composition}'
).format(**prompt_components)

print(full_prompt)
# A lone lighthouse on a rocky coastline, dramatic, moody, cinematic,
# oil painting, stormy overcast sky, waves crashing, dramatic side-lighting,
# desaturated blues and grays with warm amber light from the lighthouse,
# wide establishing shot, rule of thirds, lighthouse at left third

All lessons in this course

  1. Anatomy of an Image Generation Prompt
  2. Style and Artistic Medium Specification
  3. Negative Prompts and Exclusions
  4. Iterative Image Prompt Refinement
← Back to AI Prompt Engineering