Generate Images Using Leonardo Phoenix Model

πŸ“˜

Leonardo Phoenix is currently in preview.

For questions and feedback, please reach out via the support button on the lower right of the web app.

Follow this recipe to generate images using the Leonardo Phoenix model.


The guide will recreate the following functionality in the Web UI via API.

Sample Request

curl --request POST \
     --url https://cloud.leonardo.ai/api/rest/v1/generations \
     --header 'accept: application/json' \
     --header 'authorization: Bearer <YOUR_API_KEY>' \
     --header 'content-type: application/json' \
     --data '
{
  "modelId": "6b645e3a-d64f-4341-a6d8-7a3690fbf042",
  "contrast": 3.5,
  "prompt": "an orange cat standing on a blue basketball with the text PAWS",
  "num_images": 4,
  "width": 1472,
  "height": 832,
  "alchemy": true,
  "styleUUID": "111dc692-d470-4eec-b791-3475abac4c46",
  "enhancePrompt": false
}
'

Sample Output

Leonardo Phoenix with the prompt "an orange cat standing on a blue basketball with the text PAWS"

Leonardo Phoenix with the prompt "an orange cat standing on a blue basketball with the text PAWS"

Required Parameters

  • modelId - Should be set to 6b645e3a-d64f-4341-a6d8-7a3690fbf042 for Leonardo Phoenix.
  • prompt - Text prompt to use for generation.

Supported Parameters

  • alchemy (Generation Mode)

    Generation ModeValue
    Fastalchemy:false
    Qualityalchemy:true

    Generation Mode uses the alchemy pipeline.

  • contrast

    ContrastValue
    Low3
    Medium3.5
    High4

    Accepts [1.0, 1.3, 1.8, 2.5, 3, 3.5, 4, 4.5]. If alchemy is true, contrast needs to be 2.5 or higher.

  • enhancePrompt (Prompt Enhance)

    • Set to false for OFF.
    • Set to true for ON and specify enhancePromptInstruction: "INSTRUCTION_AS_STRING".
  • height - Height input resolution.

  • num_images - Number of images.

  • styleUUID (Preset Style)

    Preset StyleUUID
    3D Renderdebdf72a-91a4-467b-bf61-cc02bdeb69c6
    Bokeh9fdc5e8c-4d13-49b4-9ce6-5a74cbb19177
    Cinematica5632c7c-ddbb-4e2f-ba34-8456ab3ac436
    Cinematic Concept33abbb99-03b9-4dd7-9761-ee98650b2c88
    Creative6fedbf1f-4a17-45ec-84fb-92fe524a29ef
    Dynamic111dc692-d470-4eec-b791-3475abac4c46
    Fashion594c4a08-a522-4e0e-b7ff-e4dac4b6b622
    Graphic Design Pop Art2e74ec31-f3a4-4825-b08b-2894f6d13941
    Graphic Design Vector1fbb6a68-9319-44d2-8d56-2957ca0ece6a
    HDR97c20e5c-1af6-4d42-b227-54d03d8f0727
    Illustration645e4195-f63d-4715-a3f2-3fb1e6eb8c70
    Macro30c1d34f-e3a9-479a-b56f-c018bbc9c02a
    Minimalistcadc8cd6-7838-4c99-b645-df76be8ba8d8
    Moody621e1c9a-6319-4bee-a12d-ae40659162fa
    None556c1ee5-ec38-42e8-955a-1e82dad0ffa1
    Portrait8e2bc543-6ee2-45f9-bcd9-594b6ce84dcd
    Ray Tracedb504f83c-3326-4947-82e1-7fe9e839ec0f
    Sketch (B&W)be8c6b58-739c-4d44-b9c1-b032ed308b61
    Sketch (Color)093accc3-7633-4ffd-82da-d34000dfc0d6
    Stock Photo5bdc3f2a-1be6-4d1c-8e77-992a30824a2c
    Vibrantdee282d3-891f-4f73-ba02-7f8131e5541b
  • width - Width input resolution.

Pricing

Please refer to the apiCreditCost parameter in the API response. We will update the Pricing Calculator and Pricing Calculator API soon.