Skip to main content

//clika-runtime/io.clika.modelverse/ImageGenerationModel/generate

generate

[common]
fun generate(prompt: String, options: ImageGenerationOptions = ImageGenerationOptions(), listener: ImageGenerationListener): ImageGenerationHandle

Generate pictures for prompt under options. Returns at once; the worker runs the request and calls listener on its thread: ImageGenerationListener.onImages with the pictures and the seed the model drew, then ImageGenerationListener.onDone with the ImageGenerationReport. A knob left at its zero keeps the model's own default.