Create something like below. I think there is a lot of confusion around if googleAi has a model called gemini-2.5-flash-image and if it can be used in genkit.
// A simple example of image generation with Gemini.
ai.defineFlow('imagen-image-generation', async (_) => {
const { media } = await ai.generate({
model: googleAI.model('imagen-3.0-generate-002'),
prompt: `generate an image of a banana riding a bicycle`,
});
return media;
});
Create something like below. I think there is a lot of confusion around if
googleAihas a model calledgemini-2.5-flash-imageand if it can be used in genkit.