Docs
MAC AWS Bedrock
Supported Operations
Image Generation

[Image] Generate

The Image generate operation generates an image based on a prompt sent to the AWS Bedrock.

Image Generate

Input Fields

Module Configuration

This refers to the MAC AWS Bedrock Configuration set up in the Getting Started section.

General Operation Fields

  • TextToImage: Contains the instructions for the image generation.
  • AvoidInImage: Instructions on what to avoid in the image generation.
  • FullPathOutput: Once generated where should the file be saved. i.e. mule.home ++ "/apps/" ++ app.name ++ "/Image.png"

Additional Properties

  • ModelName: The name of the LLM. You can select any model from the supported LLM Providers.
  • Region: The aws region.
  • NumOfImages: The number of images to be generated.
  • Height: Default is 512.
  • Width: Default is 512.
  • CfgScale: Default is 8.0
  • Seed: Default is 0

XML Configuration

Below is the XML configuration for this operation:

<mac-bedrock:
  image-generate 
  doc:name="Image generate" 
  doc:id="8304d49f-5e96-4514-ac4c-7abf48fcd8f3" 
  config-ref="AWS" 
  TextToImage="#[payload.prompt]" 
  fullPathOutput='#[mule.home ++ "/apps/" ++ app.name ++ "/Image.png"]' 
  AvoidInImage="#[payload.avoid]" 
  modelName="amazon.titan-image-generator-v1"
/>

Output Field

This operation responds with a json payload with the path of the generated image.