Skip to content

Commit 88b5a77

Browse files
committed
Fix lint errors and update mute video to use low resolution/2.5 flash-lite
1 parent d93c037 commit 88b5a77

File tree

4 files changed

+10
-7
lines changed

4 files changed

+10
-7
lines changed

genai/text-generation/textgen-with-local-video.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ async function generateText(
4545
{text: 'Write a short and engaging blog post based on this video.'},
4646
],
4747
config: {
48-
mediaResolution: 'MEDIA_RESOLUTION_LOW'
49-
}
48+
mediaResolution: 'MEDIA_RESOLUTION_LOW',
49+
},
5050
});
5151

5252
console.log(response.text);

genai/text-generation/textgen-with-mute-video.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ async function generateText(
3131
});
3232

3333
const response = await client.models.generateContent({
34-
model: 'gemini-2.5-flash',
34+
model: 'gemini-2.5-flash-lite',
3535
contents: [
3636
{
3737
role: 'user',
@@ -49,6 +49,9 @@ async function generateText(
4949
],
5050
},
5151
],
52+
config: {
53+
mediaResolution: 'MEDIA_RESOLUTION_LOW',
54+
},
5255
});
5356

5457
console.log(response.text);

genai/text-generation/textgen-with-video.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ async function generateContent(
4747
model: 'gemini-2.5-flash',
4848
contents: [video, prompt],
4949
config: {
50-
mediaResolution: 'MEDIA_RESOLUTION_LOW'
51-
}
50+
mediaResolution: 'MEDIA_RESOLUTION_LOW',
51+
},
5252
});
5353

5454
console.log(response.text);

genai/text-generation/textgen-with-youtube-video.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ async function generateText(
4343
model: 'gemini-2.5-flash-lite',
4444
contents: [ytVideo, prompt],
4545
config: {
46-
mediaResolution: 'MEDIA_RESOLUTION_LOW'
47-
}
46+
mediaResolution: 'MEDIA_RESOLUTION_LOW',
47+
},
4848
});
4949

5050
console.log(response.text);

0 commit comments

Comments
 (0)