Prompt Engineering

Prompt engineering in the context of Generative AI and the Stable Diffusion model, is the art of crafting specific textual inputs or “prompts” that guide the AI model in generating desired outputs. In the case of SketchUp Diffusion, input prompts that describe the visual elements a user wants in their image, are coupled with the image of SketchUp’s 3D model viewport. This process enables users, even those unfamiliar with Generative AI, to seamlessly create unique and customized images by providing clear instructions through natural language prompts. It empowers users to interact intuitively with the AI model, bridging the gap between their creative vision and the powerful capabilities of Stable Diffusion for generating stunning visuals from 3D models within SketchUp.

Here are some tips for beginners in the world of prompt engineering:

1. Start with a Concept: Initiate your design process with a clear concept before enhancing it. Example: "Sustainable urban design"
2. Balanced Prompts: Maintain a balance between precision and creativity in your prompts; prioritize early words. Example: "Floating city, emphasis on vertical structures"
3. Diverse Architectural Forms: Experiment with prompts that encourage Diffusion to generate a variety of architectural styles. Example: "Architectural fusion, blend modern and classical elements"
4. Contextual Environment: Specify the environmental context to influence the architectural setting. Example: "Urban skyscrapers, evening cityscape"
5. Material and Texture Detailing: Use prompts to highlight specific materials and textures for more detailed and realistic architectural elements. Example: "Glass facades, reflective surfaces in a futuristic city"
6. Experimentation with Modifiers: Explore modifiers like “no windows” for unique and unexpected designs. Example: "Cityscape innovation, no repeating patterns"
7. Ambient Lighting Emphasis: Experiment with prompts that highlight the importance of ambient lighting in architectural scenes. Example: "Architectural twilight, emphasis on city lights"
8. Seasonal or Time Changes: Explore prompts that incorporate seasonal or time-related details for dynamic architectural scenes. Example: "Winter resort architecture, snow-covered buildings"
9. Landscaping Integration: Combine architectural prompts with landscaping details for holistic design generation. Example: "Eco-friendly neighborhood, green roofs and gardens"
10. Personalize Your Approach: Find your unique approach with Diffusion; use prompts that reflect and push your creativity. Example: "Architectural revolution, push boundaries with form and function"

Stable Diffusion, as a generative model, uses certain special symbols and notations, such as *“+”* (Plus), “-” (Minus), “//” (Double Slash), “--” (Double Dash), “...” (Ellipsis), “#” (Hashtag) to guide the image generation process. Please note that at this stage SketchUp Diffusion does NOT support these symbols and notations. However, there are some commonly used prompt instructions that you can leverage to guide the generation of your image:

Here are some examples:

1. Element Inclusion (include):

  • Function: Directs the model to include specific elements in the generated image.
  • Example: "Abstract cityscape, include flying vehicles."

2. Abstract or Non-Traditional Elements (no clear structures):

  • Function: Encourages the generation of abstract or unconventional architectural elements.
  • Example: "Architectural abstraction, no clear structures."

3. Environmental Conditions (daytime, night):

  • Function: Specifies the desired environmental conditions for the generated scene.
  • Example: "Urban park design, daytime scene."

4. Material or Texture Emphasis (focus on):

  • Function: Guides the model to emphasize specific materials or textures in the generated image.
  • Example: "Glass tower architecture, focus on reflective surfaces."

5. Cultural or Historical References (blend with):

  • Function: Integrates cultural or historical references into the generated architectural scene.
  • Example: "Ancient temple reinterpretation, blend with modern elements."

6. Seasonal or Time-Related Details (spring, summer):

  • Function: Incorporates seasonal or time-related details into the generated scene.
  • Example: "Architectural springtime, blooming gardens."

Here are some examples of complete prompts of varying lengths that combine some of the tips above:

  • Short Prompt (5 words):
    "Abstract city, no repeating structures"

  • Medium-Short Prompt (7 words):
    "Modern skyscraper, blend with nature, glass facades"

  • Medium Prompt (15 words):
    "Cutting-edge cityscape, advanced flying vehicles, dynamic urban environment, futuristic aesthetics, sustainable design, and architectural imagery."

  • Medium-Long Prompt (20 words):
    "Visually stunning architectural image: futuristic masterplan cityscape, flying vehicles, blending historical references, vibrant, dynamic, harmonious urban environment."

  • Long Prompt (40 words):
    "Enhance conceptual massing of mixed-use development, blend with futuristic elements, incorporate green spaces seamlessly, ensure dynamic lighting effects, maintain harmony with existing structures, emphasize sustainable design principles, create a compelling, visually rich architectural narrative for an innovative urban landscape."

Once you are done with your description you can tap or click the Generate button. The image generation process typically takes a few seconds to complete, with the expected duration ranging from 3 to 20 seconds. Note that the processing time may vary depending on the resolution of the SketchUp viewport, the speed of your internet connection, and the availability of cloud computing resources. Once the images are generated, Diffusion will download the results and display them below the Preview, at the bottom of the panel. You can continue generating additional options by clicking the Generate button with or without changing the text prompt field.

Note: All of the images that you generate will remain available in the Diffusion panel, during a modeling session. However, Diffusion does not yet offer a History feature. After closing and re-opening a model, and/or quitting and relaunching the SketchUp app, you’ll find that previously generated images have been cleared from the Diffusion panel.

Prompt engineering is an ever-evolving craft. If you have some principles, or best practices that would benefit the community use this space to share.

13 Likes

Maybe this should be converted into a wizard for the creation of prompts.

Maybe the wizard should have a way of including custom steps and we could create wizard templates.

Some image formats support metadata properties. Perhaps have the generator add the prompts as a data attribute to the final output image file?

2 Likes

Happy to sign up to your AI prompting masterclas @Aristodimos

1 Like