Stability Text to Image AI action

Stability Text to Image AI action connects automations to Amazon Bedrock Stability text-to-image AI functionality. This action enables automations to generate photorealistic images from text descriptions, unlocking a new dimension of automation possibilities.

Prerequisites

  • You must have the Bot creator role to use the Stability Text to Image AI action in a bot.
  • Ensure that you have the necessary credentials to send a request. For more information on acquiring the credentials, see Amazon Bedrock: Authenticate action.

This example shows how to send a natural language message using the Stability Text to Image AI action and get an appropriate response.

Procedure

  1. In the Automation Anywhere Control Room, navigate to the Actions pane, select Generative AI > Amazon Bedrock, drag Stability Text to Image AI and place it in the canvas.
  2. Enter or select the following fields:

    Stability Text to Image AI action

    1. Enter the Region. For information on Region, see Amazon Bedrock GA regions.
    2. Click the Model drop-down and select a model with which to communicate.
      • Stable Diffusion XL v1.0: This text-to-image model leverages diffusion-based techniques to generate photo realistic images from text descriptions.
      • Other supported version: To input other supported models.
    3. Enter a Message to use by the model to generate an image.
    4. Enter the Prompt Strength.
      By default, if you do not enter a value, it is set to 10. This parameter ranges from 0 to 30 and specifies how strict the diffusion process adheres to the prompt text (higher values keep your image closer to your prompt).
    5. Enter a Destination Folder. This refers to the folder where the output image is saved.
    6. Enter Default as the session name to limit the session to the current session.
    7. To manage the optional parameters, click Show more options and select Yes. If you select Yes, you can add other parameters such as: Generation Step and Seed. For information about these optional parameters, see text-to-image parameters.
    8. Save the entire file path including the file name in a variable. In this example, the response is saved to filePath.
  3. Click Run to start the bot.
    You can read the value of the file path including file name by printing the response in a Message box action. In this example, the image is stored in filePath