org.llm4s.imagegeneration
Members list
Packages
Type members
Classlikes
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationErrorclass Objecttrait Matchableclass AnyShow all
Represents a generated image
Represents a generated image
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- trait
- Supertypes
-
trait Sumtrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
HealthStatus.type
Configuration for the HuggingFace Inference API.
Configuration for the HuggingFace Inference API.
Value parameters
- apiKey
-
Your HuggingFace API token. This is required for authentication.
- model
-
The identifier of the model to use on the HuggingFace Hub, e.g., "runwayml/stable-diffusion-v1-5".
- timeout
-
Request timeout in milliseconds. Defaults to a higher value suitable for cloud APIs.
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationConfigclass Objecttrait Matchableclass AnyShow all
Options for image editing
Options for image editing
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- trait
- Supertypes
-
trait Sumtrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
ImageFormat.type
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
ImageGeneration.type
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
class AuthenticationErrorclass InvalidPromptErrorclass RateLimitErrorclass ServiceErrorclass UnknownErrorclass UnsupportedOperationclass ValidationErrorShow all
Options for image generation
Options for image generation
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Providers for image generation
Providers for image generation
Attributes
- Companion
- object
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
Attributes
- Companion
- trait
- Supertypes
-
trait Sumtrait Mirrorclass Objecttrait Matchableclass Any
- Self type
Registry of image generation model pricing.
Registry of image generation model pricing.
Provides per-image cost lookup for supported image generation models. Costs are in USD per image and vary by model, size, and quality.
Pricing sources:
- OpenAI: https://openai.com/api/pricing/
- Stability AI: https://platform.stability.ai/pricing
Attributes
- See also
-
org.llm4s.model.ModelPricing for LLM token-based pricing
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
ImagePricingRegistry.type
Image size enumeration
Image size enumeration
Attributes
- Companion
- object
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
object Autoclass Customobject Landscape1536x1024object Landscape768x512object Portrait1024x1536object Portrait512x768object Square1024object Square512Show all
Decorator that wraps an ImageGenerationClient with metrics collection and trace event emission.
Decorator that wraps an ImageGenerationClient with metrics collection and trace event emission.
Records:
observeImageGenerationfor every generate/edit call (success or failure)recordImageGenerationCostwhen pricing is available via ImagePricingRegistryTraceEvent.ImageGenerationCompletedfor observability
Note: Cost estimation uses the requested size, not the actual provider-billed dimensions. For models like dall-e-3 that normalize sizes (e.g., mapping non-standard requested sizes to their nearest supported size), the estimate may differ from actual billing. When size is unknown (e.g., edit operations without an explicit size), cost estimation is skipped.
Value parameters
- config
-
Image generation configuration (provides model/provider info)
- delegate
-
The underlying client to delegate actual generation to
- metrics
-
Metrics collector for Prometheus counters/histograms
- tracing
-
Tracing backend for structured event emission
Attributes
- Supertypes
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationErrorclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationErrorclass Objecttrait Matchableclass AnyShow all
Configuration for OpenAI DALL-E API.
Configuration for OpenAI DALL-E API.
Value parameters
- apiKey
-
Your OpenAI API key. This is required for authentication.
- model
-
The DALL-E model version to use (dall-e-2 or dall-e-3).
- timeout
-
Request timeout in milliseconds.
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationConfigclass Objecttrait Matchableclass AnyShow all
Provider-specific edit options; keeps shared API provider-agnostic.
Provider-specific edit options; keeps shared API provider-agnostic.
Attributes
- Companion
- object
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
class OpenAIclass StableDiffusion
Attributes
- Companion
- trait
- Supertypes
-
trait Sumtrait Mirrorclass Objecttrait Matchableclass Any
- Self type
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationErrorclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationErrorclass Objecttrait Matchableclass AnyShow all
Represents the status of the image generation service
Represents the status of the image generation service
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Configuration for Stability AI API.
Configuration for Stability AI API.
Value parameters
- apiKey
-
Your Stability AI API key. This is required for authentication.
- baseUrl
-
Base URL for Stability AI API (default: https://api.stability.ai).
- model
-
The engine/model ID to use (e.g., "stable-diffusion-xl-1024-v1-0", "stable-diffusion-v1-6").
- timeout
-
Request timeout in milliseconds.
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationConfigclass Objecttrait Matchableclass AnyShow all
Configuration for Stable Diffusion
Configuration for Stable Diffusion
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationConfigclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationErrorclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationErrorclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait ImageGenerationErrorclass Objecttrait Matchableclass AnyShow all