Skip to main content

ImageConfig

Defined in the agents module.
Rust AI Agent SDK Configuration for image generation settings.

Fields

NameTypeDescription
styleStringStyle of the generated image
response_formatStringResponse format (url or b64_json)
timeoutu32Timeout in seconds
sizeOption<String>Image size (e.g., “1024x1024”, “1792x1024”)
qualityOption<String>Image quality (standard or hd)
api_baseOption<String>API base URL
api_keyOption<String>API key

Methods

new

fn new() -> Self
Create a new ImageConfig

style

fn style(mut self, style: impl Into<String>) -> Self
Set the style Parameters:
NameType
styleimpl Into&lt;String&gt;

size

fn size(mut self, size: impl Into<String>) -> Self
Set the size Parameters:
NameType
sizeimpl Into&lt;String&gt;

quality

fn quality(mut self, quality: impl Into<String>) -> Self
Set the quality Parameters:
NameType
qualityimpl Into&lt;String&gt;

Source

View on GitHub

praisonai/src/agents/mod.rs at line 230