
Mastering Prompts: From Basics to Advanced Techniques
Learn how to write effective prompts for AI image generation, with practical tips and advanced strategies

In the world of AI image generation, prompts serve as the language for communicating with AI. A good prompt is more than just a simple description; it’s the key to accurately conveying your creative vision to the AI. Just as an artist needs to master painting techniques or a photographer must understand composition and lighting, mastering the art of writing prompts is just as crucial to producing the ideal AI-generated image.
In this tutorial, we will take you through the art of prompt writing. From the basics of structure and keyword usage to advanced techniques like weight adjustments and scene optimization, these insights will help you better navigate AI image generation tools. Whether you’re a beginner just starting out with AI creativity or an advanced user looking to enhance your skills, this content will bring you closer to your ideal creative outcomes.
- Understand the basic principles and structure of prompts
- Master the selection and combination of keywords
- Learn how to handle common generation issues
- Be able to optimize your prompts for different scenarios
- Develop your own prompt writing system
Let’s embark on this journey of exploring AI creativity.
1. The Basic Elements of Prompts: Structure and Keywords
To write effective prompts, it's essential to understand their core components. Just as building a house requires a foundation, walls, and a roof, a complete prompt also has its basic structure and necessary elements. In this section, we will provide a detailed overview of the basic structure of prompts and the different types of keywords, helping you establish a solid foundation.
To generate an ideal AI image, we need to learn how to clearly describe four aspects in our prompts: subject, scene, style, and technical requirements. Just like a painter must decide what to paint, in what environment, with what style, and using what techniques before starting, we must do the same. Let's understand this through a simple example:
An elegant white cat sitting on the windowsill of a classical library, in an oil painting style, with high-definition details and soft lighting.
Subject description: Tell AI 'what to paint'
The subject description is the core of the entire prompt, just like deciding the main character of a painting. When describing the subject, we not only need to specify 'what it is', but also explain its characteristics. For example, when describing a cat, we can specify its breed (such as a Persian cat), color (such as ginger), and body type (such as elegant and slender). If the subject is doing something, like running or resting, that should be clarified too. Remember, the more detailed the description, the better AI can understand your idea.
Scene description: Set the 'where'
The scene is like the stage for the subject. A cat could be in a cozy living room, on a bustling street, or in a mysterious forest. The scene includes not only the location, but also the time and atmosphere. For example, 'the Tuscan countryside at dusk, with rolling vineyards in the distance, and the sky glowing with golden sunset light,' such a description can make the image more rich and lively. A good scene description will help your subject blend more naturally into the environment.
Style description: Decide 'how to paint'
Style is like the artist’s personal signature. You can choose a realistic style, making the image look like a real photo; an oil painting style, giving the image an artistic feel; or an anime style, making the image more lively and cute. Besides basic artistic styles, you can also specify specific movements, such as the vibrant colors of Impressionism or the futuristic feel of Cyberpunk. Choosing the right style will help better express your creative idea.
Technical parameters: Adjust 'how detailed'
Technical parameters are like the tools and techniques an artist uses. They determine the level of detail and overall effect of the image. For example, you can request high-definition quality (8K, 4K), set light effects (natural light, soft lighting, backlighting, etc.), and specify the composition (close-up, wide shot, aerial view, etc.). Good technical parameters will make your image more refined and perfect.
Real-world application examples
Let’s see the difference in the same idea described in different ways:
Basic version
A cat sitting on a windowsill

Optimized version
An elegant ginger Persian cat sitting gracefully on a stone windowsill covered with ancient vines, with a Tuscan countryside sunset scene outside the window. The overall style is a Renaissance oil painting, with delicate brushstrokes. 8K ultra-high definition, golden sunset light pouring through the window onto the cat, creating a warm atmosphere, with the foreground blurred.

By comparing these two versions, we can clearly see that the optimized version is much richer and more specific in every aspect. Such detailed prompts help AI better understand our creative ideas, resulting in images that align more closely with our expectations.
2. The Art of Keywords: Choose Wisely, Achieve More
Just like a painter mastering color, composition, and lighting, we need to use specific keywords in AI-generated art to control these artistic elements. Choosing the right keywords allows AI to better understand the artistic effects we desire. Let’s explore the three most essential types of artistic expression keywords.
Style Keywords: Defining the "Look and Feel"
Style keywords are like selecting the technique for a painting. You can instruct AI to create with the texture of oil painting, the charm of watercolor, or even the futuristic vibe of digital art. For instance, painting a flower with an "oil painting style" gives it a heavy and realistic touch, while a "watercolor style" makes it feel light and airy. On the other hand, a "cyberpunk style" infuses it with a technological, futuristic feel.
Composition Keywords: Shaping "How to View"
Composition keywords are like deciding on the framing when taking a photo. They determine how the viewer observes the elements within the image. Will it be a close-up to highlight details, or a wide shot to showcase the grandeur of the scene? Will it be a top-down view to emphasize spatial depth, or an eye-level perspective to create a sense of realism? A well-thought-out composition enhances the visual appeal of the artwork.
Lighting Keywords: Setting the "Mood"
Lighting keywords are akin to controlling the studio lights during a photoshoot. They not only add depth to the image but also establish specific atmospheres and emotions. Warm sunlight during sunset brings a sense of warmth, while the cold glow of moonlight adds a mysterious vibe. Dramatic lighting, on the other hand, introduces tension and visual impact.
Practical Examples
Let’s explore some concrete examples to see how these keywords influence the final results:
Style Keywords Examples
The skyline of a futuristic city with towering buildings
Realistic Style

The skyline of a futuristic city with towering buildings, realistic style, detailed architectural features, professional photography effect
Oil Painting Style

The skyline of a futuristic city with towering buildings, oil painting style, thick brushstrokes, impressionist art, canvas texture
Cyberpunk Style

The skyline of a futuristic city with towering buildings, cyberpunk style, neon lights, dark tones, futuristic technological vibe
Composition Keywords Examples
A blooming red rose
Close-Up Composition

A blooming red rose, extreme close-up, highlighting petal texture, blurred background
Medium Shot Composition

A blooming red rose, rule of thirds composition, garden background, balanced framing
Wide-Angle Composition

A blooming red rose, wide-angle composition, full garden scene, natural leading lines
Lighting Keywords Examples
A vintage-style living room
Natural Daylight

A vintage-style living room, natural daylight, soft ambient light, morning atmosphere, bright and clear
Golden Hour

A vintage-style living room, golden sunset light, warm rays streaming through the windows, beautiful light and shadows, cozy ambiance
Dramatic Lighting

A vintage-style living room, dramatic lighting, strong contrasts between light and shadow, light beams piercing through, intense atmosphere
3. Prompt Optimization: Making AI Understand Your Creativity Better
After mastering the basic structure and the use of keywords, let's explore some optimization techniques that can make your prompts more precise. Just like a sound engineer fine-tunes each track to present the best sound, we need to organize and optimize our prompts so AI can better understand and execute our creative ideas.
Keyword Organization Order
When writing prompts, we should follow the principle of 'importance first.' Just like when writing an article, we need to prioritize. The usual order is: Subject Description → Scene Setting → Style and Effects → Technical Parameters.
Optimized Examples:
A young woman, wearing a red dress, smiling warmly, standing in a sunlit café, soft natural light pouring in from the window, with an overall cinematic tone.
Examples to Avoid:
Cinematic tone, natural lighting, café scene, a young woman in a red dress.
Negative Keyword Usage Tips
Sometimes, telling AI 'what not to do' is just as important. However, it's important not to overuse negative keywords—typically 2-3 are sufficient. Too many negative keywords can affect the generated result. Common negative keywords include: no text, no blur, no watermark, etc.
Optimized Examples:
A golden retriever running on grass, no blur, no watermark.
Examples to Avoid:
A golden retriever running on grass, no blur, no watermark, no people, no buildings, no cars, no shadows, no clouds.
Controlling Prompt Length
While detailed descriptions help AI better understand our intentions, overly long prompts can make it difficult for AI to grasp the main points. It's recommended to keep a prompt under 100 words, ensuring that each keyword is necessary.
Optimized Examples:
An elegant Siamese cat sitting on the windowsill of a classical library, warm sunlight pouring through the stained-glass window, oil painting style.
Examples to Avoid:
A very elegant and beautiful Siamese cat with beautiful blue eyes and soft fur, leisurely sitting on an ornate wooden windowsill in a classical library, the windowsill covered with a red velvet cushion, warm sunlight pouring through the stained-glass window, creating a dreamy light-and-shadow effect, with an overall delicate oil painting style.
Common Issues and Solutions
When generating images with AI, we often encounter common problems. Let's look at some real examples to see how to solve them:
The Subject Is Not Prominent
A common problem is when the subject is overwhelmed by environmental details, and we need to emphasize the importance of the subject in the prompt.
Before Optimization:
A cat on a bustling city street, surrounded by many pedestrians, tall buildings, street-side shops, and neon billboards.

The subject description is too simple, and the environmental details are too detailed, causing the subject to be overshadowed.
After Optimization:
An elegant orange tabby cat, with a watchful pose and bright green eyes, strolling on a city street, the background is a blurred urban scene.

The subject description is strengthened, while environmental details are minimized, making the subject more prominent.
Details Are Not Ideal
Adding appropriate detail keywords can make the image more refined.
Before Optimization:
A bouquet of roses in a vase.

The description is too simple and lacks detail.
After Optimization:
A bouquet of blooming red roses, with dewdrops on the petals, placed in a transparent glass vase, with clear details and a realistic texture.

Specific details are added, making the image more vivid.
The Composition Is Messy
Clear composition instructions can make the image more organized and appealing.
Before Optimization:
A group of birds in a park.

Lack of composition guidance could result in a cluttered scene.
After Optimization:
Five white swans elegantly swimming on a calm lake, with a three-part composition, the foreground showing rippling water, and the background featuring blurred trees.

Composition method and element positions are clearly specified.
The Style Is Not Consistent
Choosing suitable and consistent style keywords can make the image more harmonious.
Before Optimization:
A castle, watercolor style, cyberpunk, retro nostalgia, anime style.

Mixing multiple conflicting styles.
After Optimization:
A medieval castle, watercolor painting style, soft color transitions, hand-drawn texture, with an artistic feel.

Maintaining a consistent artistic style.
4. Practical Exercise: From Concept to Final Image
After mastering the basics of prompt crafting, keyword usage, and optimization techniques, let's apply these skills through practical case studies. Just like a chef improves their cooking skills through continuous practice, we too need to hone our ability to write effective prompts through real-world scenarios. In this section, we will showcase how to go from an initial creative idea to the final desired image.
Creative Process: The Four-Step Method
To create the ideal AI image, we can follow a simple four-step workflow: Ideation, Writing, Generation, and Optimization. This process helps us approach the creation in a more organized way.
Step 1: Ideation
The first step is to clearly define what we want to create. Consider the following questions: What is the subject? What is the setting? What kind of atmosphere do we want? What artistic style are we aiming for? Listing these elements will make the prompt writing process much clearer.
Ideation Example
Creation theme: A cat in a café - Subject: Elegant white Persian cat - Setting: Cozy vintage café - Atmosphere: Lazy afternoon - Style: Warm, film-like
Step 2: Writing
Based on the ideation list, organize the prompts following the structure we've learned. Remember to prioritize the 'importance first' principle and carefully choose and combine the keywords.
Writing Example
An elegant white Persian cat, with fluffy fur, lazily lying on a wooden counter in a vintage café. The afternoon sun shines through the floor-to-ceiling window onto the cat. The café is decorated with retro coffee equipment and old posters, all with a warm, film-like aesthetic, natural lighting, and a moderate depth of field.
Step 3: Generation
During the generation phase, carefully observe the results. Analyze what meets your expectations and what needs adjustment. This stage requires patience, as achieving the perfect result often involves multiple iterations.
- Pay attention to whether the subject is portrayed accurately.
- Check if the scene details align with expectations.
- Ensure the overall style is cohesive.
- Examine if the lighting and shadow effects are well executed.
Step 4: Optimization
Optimize the prompt based on the generated results. You may need to adjust keyword weight, add or remove certain descriptions, or change the word order. This is an iterative process, and each adjustment brings us closer to the ideal outcome.
Before Optimization
A white Persian cat in a café.

After Optimization
An elegant white Persian cat, with fluffy fur, looking lazy, resting on the vintage café’s wooden counter, bathed in warm afternoon sunlight streaming through the floor-to-ceiling window, creating a soft lighting effect. The café features antique coffee machines and retro posters, creating a cozy atmosphere. The style is film-like, with natural saturation and medium depth of field.

Case Studies
Let’s explore three specific cases to see how we can apply this workflow:
Case 1: Portrait
Create a retro-style portrait of a woman.
Ideation Points
- Subject: Young woman, retro style - Setting: Minimalistic solid color background - Atmosphere: Elegant and vintage - Style: Similar to Hollywood’s golden age portraits
Final Prompt
An elegant young woman with retro curly hair, wearing a 1950s style dress, gazing gently at the camera. The photograph adopts a Hollywood golden age portrait style, with soft side lighting, in black and white, and a minimalistic blurred background, highlighting her expression and features.

Tips and Techniques:
- Focus on describing the subject’s expression and pose.
- Emphasize lighting effects and atmosphere.
- Include period-specific details to enhance authenticity.
Case 2: Landscape
Create a stunning mountain landscape scene.
Ideation Points
- Subject: Majestic mountain range - Setting: Sunrise - Atmosphere: Majestic and awe-inspiring - Style: Landscape photography
Final Prompt
A majestic snow-capped mountain range, with golden sunlight of the morning bathing the peaks, while clouds swirl in the valleys below. In the foreground, a lush green pine forest contrasts with the mountains. The composition uses an ultra-wide angle, with fine details and emphasis on the light and shadow play.

Tips and Techniques:
- Focus on describing spatial layers.
- Highlight lighting and weather effects.
- Arrange foreground, middle-ground, and background effectively.
Case 3: Concept Art
Create a futuristic cityscape.
Ideation Points
- Subject: Futuristic city - Setting: Night street - Atmosphere: Techno-futuristic - Style: Cyberpunk
Final Prompt
A bustling futuristic street in a city, with towering glass buildings glowing with neon lights. Hovering cars stream along the road, while holographic ads light up the night sky. The street is lined with high-tech shops, and passersby are dressed in futuristic clothing. The style is cyberpunk, with a nighttime atmosphere and rich lighting effects.

Tips and Techniques:
- Balance futuristic elements with realistic foundations.
- Focus on building atmosphere.
- Add technological details appropriately.
Common Mistakes and Solutions
Throughout the practice process, we often encounter typical issues. Let's take a look at how to avoid these pitfalls:
Vague Descriptions
Many people tend to use vague words like 'beautiful' or 'pretty', which are too subjective for AI.
Solution:Use specific and objective descriptive words, such as shapes, colors, and textures that can be quantified.
Keyword Overload
Simply stacking numerous keywords in hopes of getting better results often backfires and confuses the AI.
Solution:Organize the keywords logically, ensuring each word is necessary and avoid redundancy.
Ignoring Overall Consistency
Mixing different styles or contradictory descriptions in a single prompt leads to chaotic results.
Solution:Ensure all keywords are consistent in style and logic, avoiding conflicting descriptions.
Conclusion
Through these practical case studies, we can see that creating great AI images requires not only mastering the basics of prompt crafting but also accumulating experience through practice. Each attempt is a learning opportunity, and by continually adjusting and optimizing, we will be able to better control the AI tools and create the ideal works we envision.
- Be patient—good works often require multiple attempts.
- Build your own keyword library to record successful combinations.
- Observe successful examples from others and learn from them.
- Summarize your experience and develop your own creative methods.
Now that you've mastered various prompt writing techniques, are you ready to start practicing?
Start creating now