Class GoogleGenAiImageModel
java.lang.Object
dev.langchain4j.model.google.genai.GoogleGenAiImageModel
- All Implemented Interfaces:
ImageModel
Represents a Google GenAI model for image generation and editing using the official com.google.genai SDK.
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Given an existing image, edit this image following the given prompt and apply the changes only to the part of the image specified by the given mask.Given an existing image, edit this image following the given prompt.Given a prompt, generate an image.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ImageModel
generate
-
Method Details
-
builder
-
generate
Description copied from interface:ImageModelGiven a prompt, generate an image.- Specified by:
generatein interfaceImageModel- Parameters:
prompt- The prompt to generate an image from.- Returns:
- The generated image Response.
-
edit
Description copied from interface:ImageModelGiven an existing image, edit this image following the given prompt.- Specified by:
editin interfaceImageModel- Parameters:
image- The image to be edited.prompt- The prompt to edit the image.- Returns:
- The generated image Response.
-
edit
Description copied from interface:ImageModelGiven an existing image, edit this image following the given prompt and apply the changes only to the part of the image specified by the given mask.- Specified by:
editin interfaceImageModel- Parameters:
image- The image to be edited.mask- The image mask to apply to delimit the area to edit.prompt- The prompt to edit the image.- Returns:
- The generated image Response.
-