Skip to content

[JS] Doesn't work processing video #3147

Open
@jggomez

Description

@jggomez

When attempting to process videos, the system consistently returns a null response, preventing any successful video processing. This issue has been observed across multiple video files and processing attempts.

import { genkit, z } from "genkit";
import { googleAI, gemini20Flash } from "@genkit-ai/googleai";

const ai = genkit({
plugins: [googleAI()],
});

export const test = ai.defineFlow(
{
name: "test",
inputSchema: z.object({
url: z.string(),
}),
outputSchema: z.string().nullable(),
},
async ({ url }) => {
const { output } = await ai.generate({
prompt: [
{
text: "create a summary of this video",
},
{
media: {
url: url,
contentType: "video/mp4",
},
},
],
model: gemini20Flash,
output: { schema: z.string().nullable() },
});
console.log("transcription", output);
return output;
}
);

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingjs

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions