AI Image Prompt Engineering for Beginners: A Complete Guide to Writing Quality Prompts
Prompts are the core input for AI image generation. Writing good prompts can multiply the quality of outputs. This article systematically explains the principles and techniques of AI image prompt engineering.
1. Basic Prompt Structure
1.1 Universal Formula
A high-quality prompt typically includes these elements:
[Subject] + [Action/Pose] + [Environment/Background] + [Style/Medium] + [Lighting/Color] + [Composition/Angle] + [Quality/Details]
Example:
A white cat sitting on a windowsill, sunlight streaming in, photorealistic style, warm soft tones, close-up shot, 8K ultra HD, depth of field
1.2 Platform Differences
| Platform | Language Preference | Length | Style Word Weight |
|---|---|---|---|
| Midjourney | English best | 60-200 chars | High |
| DALL-E 3 | Natural language | 40-120 chars | Medium |
| Stable Diffusion | English + tagging | 30-100 chars | Very High |
2. Advanced Midjourney Prompts
2.1 Using Parameters
Midjourney supports rich parameter controls:
/imagine prompt: cyberpunk city night --ar 16:9 --v 6 --s 750 --stylize 500
--ar: Aspect ratio (16:9, 4:3, 1:1)--v: Model version (v6 latest)--s: Stylization (0-1000)--stylize: Artistic quality (0-1000)--iw: Image weight (0-2, for image-to-image)
2.2 Style Reference
Use --sref to reference style images:
/imagine prompt: landscape painting --sref [style_image_URL]
2.3 Common Style Keywords
| Style | English Keywords |
|---|---|
| Photorealistic | photorealistic, hyperrealistic, 8K, ultra detailed |
| Cyberpunk | cyberpunk, neon lights, futuristic city |
| Watercolor | watercolor, soft brushstrokes, paper texture |
| Oil Painting | oil painting, impasto, canvas texture |
| Anime | anime style, cel shading, Studio Ghibli |
| Pixel Art | pixel art, 8-bit, retro game |
| 3D Render | 3D render, octane render, C4D |
3. Stable Diffusion Prompt Techniques
3.1 Positive and Negative Prompts
Positive: (masterpiece, best quality, ultra-detailed)
Negative: (nsfw, lowres, bad anatomy, bad hands, text, error, missing fingers)
3.2 Weight Control
(red hair:1.3) — Increase "red hair" weight
(blue eyes:0.8) — Decrease "blue eyes" weight
[tree] — Reduce weight to 0.5x
3.3 Embeddings and LoRA
Using pre-trained Embeddings and LoRA models can significantly improve the generation of specific styles or characters.
4. DALL-E 3 Prompt Techniques
DALL-E 3 has strong natural language understanding. Suggestions:
- Use complete sentences, not tag stacks
- Specify elements to exclude
- Specify colors, materials, lighting details
5. Common Issues and Solutions
| Issue | Solution |
|---|---|
| Distorted hands | Add negative prompt: bad hands, or detail in description |
| Inconsistent style | Reduce style keywords, focus on 1-2 core styles |
| Poor composition | Specify angle (top-down, low-angle, close-up) |
| Color deviation | Specify dominant colors and palette |
6. Recommended Resources
- PromptBase: Buy and sell prompts
- Midjourney Prompt Helper: Online prompt builder
- Civitai: Stable Diffusion model and prompt sharing community