Can I send images to the Leiolai API?

Yes. The Leiolai API accepts base64 image inputs through Chat Completions, Responses, and Messages. Send the image data in the format for your endpoint and include a text question explaining what you want Leiolai to examine. Remote image URLs are not accepted as image inputs.

Which API formats accept images?

Use Leiolai Chat Completions, Responses, or Anthropic Messages for text and base64 images. Text Completions accepts a text prompt.

Can I pass a link to an image on the web?

No. Send image data to Leiolai as base64 in your endpoint’s supported content block. Remote image URLs are not accepted.

What question should accompany an image?

Tell Leiolai what to examine in the image: a chart’s axis labels, a diagram’s arrows, a difference between layouts, or a particular visible detail. Send that question in the text content alongside the image.

Can I use images in both Research and Private?

Supported image inputs are available in both modes. Choose Private for confidential material and Research for non-sensitive material. The Leiolai API key’s restriction still applies to the request.

Choose handling for the input

How does Messages represent an image?

Use a Messages image block with type: image and a base64 source containing media_type and data. Include a text block with your question.

Use the Messages content format

Can I update an image during continuous generation?

Yes. Add an image field with a base64 data URI to a Leiolai continuous-generation injection request. A new image replaces the prior image. The documented limit is 8 MiB decoded and 12 MiB for the request body.

Update context during generation

Is an inline text file the same kind of input as an image?

They use different content representations. Leiolai Chat Completions and Responses also accept supported inline UTF-8 text and code files, up to 2 MiB per file. A binary PDF or a file ID is not a supported inline text-file input.

Text-file and document inputs

What should I check if an image request fails?

Check the image content-block shape, media type, base64 data, request size, and the Leiolai error code. Correct malformed input before retrying. vision_unavailable indicates temporary unavailability rather than a malformed image.

Troubleshoot the reported API error