prithivMLmods commited on
Commit
d00c866
·
verified ·
1 Parent(s): faf9a0e
Files changed (1) hide show
  1. Home.tsx +2 -4
Home.tsx CHANGED
@@ -3,7 +3,7 @@
3
  * SPDX-License-Identifier: Apache-2.0
4
  */
5
  /* tslint:disable */
6
- import {Content, GoogleGenAI, Modality} from '@google/genai';
7
  import {
8
  ChevronDown,
9
  Library,
@@ -364,11 +364,9 @@ export default function Home() {
364
 
365
  parts.push({text: prompt});
366
 
367
- const contents: Content[] = [{role: 'USER', parts}];
368
-
369
  const response = await ai.models.generateContent({
370
  model: 'gemini-2.5-flash-image-preview',
371
- contents,
372
  config: {
373
  responseModalities: [Modality.TEXT, Modality.IMAGE],
374
  },
 
3
  * SPDX-License-Identifier: Apache-2.0
4
  */
5
  /* tslint:disable */
6
+ import {GoogleGenAI, Modality} from '@google/genai';
7
  import {
8
  ChevronDown,
9
  Library,
 
364
 
365
  parts.push({text: prompt});
366
 
 
 
367
  const response = await ai.models.generateContent({
368
  model: 'gemini-2.5-flash-image-preview',
369
+ contents: { parts },
370
  config: {
371
  responseModalities: [Modality.TEXT, Modality.IMAGE],
372
  },