Class OllamaImageModel
java.lang.Object
dev.langchain4j.model.ollama.OllamaImageModel
- All Implemented Interfaces:
dev.langchain4j.model.image.ImageModel
@Experimental
public class OllamaImageModel
extends Object
implements dev.langchain4j.model.image.ImageModel
Experimental Ollama image generation model.
Supports text-to-image generation through Ollama's /api/generate endpoint. Generated images
are returned as PNG Base64 data. Image editing and multi-image generation are not supported.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classException thrown when Ollama does not return an image.static class -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface dev.langchain4j.model.image.ImageModel
edit, edit, generate
-
Constructor Details
-
OllamaImageModel
-
-
Method Details
-
builder
-
modelName
-
generate
public dev.langchain4j.model.output.Response<dev.langchain4j.data.image.Image> generate(String prompt) - Specified by:
generatein interfacedev.langchain4j.model.image.ImageModel
-