@@ -60,6 +60,28 @@ describe('Gemini Model Provider Options Type Assertions', () => {
6060 expectTypeOf < Options > ( ) . toHaveProperty ( 'responseSchema' )
6161 } )
6262
63+ it ( 'gemini-3-flash-preview should support thinking options' , ( ) => {
64+ type Model = 'gemini-3-flash-preview'
65+ type Options = GeminiChatModelProviderOptionsByName [ Model ]
66+
67+ // Should have thinking options
68+ expectTypeOf < Options > ( ) . toExtend < GeminiThinkingOptions > ( )
69+
70+ // Should have structured output options
71+ expectTypeOf < Options > ( ) . toExtend < GeminiStructuredOutputOptions > ( )
72+
73+ // Should have base options
74+ expectTypeOf < Options > ( ) . toExtend < BaseOptions > ( )
75+
76+ // Verify specific properties exist
77+ expectTypeOf < Options > ( ) . toHaveProperty ( 'generationConfig' )
78+ expectTypeOf < Options > ( ) . toHaveProperty ( 'safetySettings' )
79+ expectTypeOf < Options > ( ) . toHaveProperty ( 'toolConfig' )
80+ expectTypeOf < Options > ( ) . toHaveProperty ( 'cachedContent' )
81+ expectTypeOf < Options > ( ) . toHaveProperty ( 'responseMimeType' )
82+ expectTypeOf < Options > ( ) . toHaveProperty ( 'responseSchema' )
83+ } )
84+
6385 it ( 'gemini-2.5-pro should support thinking options' , ( ) => {
6486 type Model = 'gemini-2.5-pro'
6587 type Options = GeminiChatModelProviderOptionsByName [ Model ]
@@ -172,6 +194,7 @@ describe('Gemini Model Provider Options Type Assertions', () => {
172194 type Keys = keyof GeminiChatModelProviderOptionsByName
173195
174196 expectTypeOf < 'gemini-3-pro-preview' > ( ) . toExtend < Keys > ( )
197+ expectTypeOf < 'gemini-3-flash-preview' > ( ) . toExtend < Keys > ( )
175198 expectTypeOf < 'gemini-2.5-pro' > ( ) . toExtend < Keys > ( )
176199 expectTypeOf < 'gemini-2.5-flash' > ( ) . toExtend < Keys > ( )
177200 expectTypeOf < 'gemini-2.5-flash-preview-09-2025' > ( ) . toExtend < Keys > ( )
@@ -203,6 +226,9 @@ describe('Gemini Model Provider Options Type Assertions', () => {
203226 expectTypeOf <
204227 GeminiChatModelProviderOptionsByName [ 'gemini-3-pro-preview' ]
205228 > ( ) . toHaveProperty ( 'safetySettings' )
229+ expectTypeOf <
230+ GeminiChatModelProviderOptionsByName [ 'gemini-3-flash-preview' ]
231+ > ( ) . toHaveProperty ( 'safetySettings' )
206232 expectTypeOf <
207233 GeminiChatModelProviderOptionsByName [ 'gemini-2.5-pro' ]
208234 > ( ) . toHaveProperty ( 'safetySettings' )
@@ -230,6 +256,9 @@ describe('Gemini Model Provider Options Type Assertions', () => {
230256 expectTypeOf <
231257 GeminiChatModelProviderOptionsByName [ 'gemini-3-pro-preview' ]
232258 > ( ) . toHaveProperty ( 'toolConfig' )
259+ expectTypeOf <
260+ GeminiChatModelProviderOptionsByName [ 'gemini-3-flash-preview' ]
261+ > ( ) . toHaveProperty ( 'toolConfig' )
233262 expectTypeOf <
234263 GeminiChatModelProviderOptionsByName [ 'gemini-2.5-pro' ]
235264 > ( ) . toHaveProperty ( 'toolConfig' )
@@ -257,6 +286,9 @@ describe('Gemini Model Provider Options Type Assertions', () => {
257286 expectTypeOf <
258287 GeminiChatModelProviderOptionsByName [ 'gemini-3-pro-preview' ]
259288 > ( ) . toHaveProperty ( 'cachedContent' )
289+ expectTypeOf <
290+ GeminiChatModelProviderOptionsByName [ 'gemini-3-flash-preview' ]
291+ > ( ) . toHaveProperty ( 'cachedContent' )
260292 expectTypeOf <
261293 GeminiChatModelProviderOptionsByName [ 'gemini-2.5-pro' ]
262294 > ( ) . toHaveProperty ( 'cachedContent' )
@@ -286,6 +318,9 @@ describe('Gemini Model Provider Options Type Assertions', () => {
286318 expectTypeOf <
287319 GeminiChatModelProviderOptionsByName [ 'gemini-3-pro-preview' ]
288320 > ( ) . toExtend < GeminiThinkingOptions > ( )
321+ expectTypeOf <
322+ GeminiChatModelProviderOptionsByName [ 'gemini-3-flash-preview' ]
323+ > ( ) . toExtend < GeminiThinkingOptions > ( )
289324 expectTypeOf <
290325 GeminiChatModelProviderOptionsByName [ 'gemini-2.5-pro' ]
291326 > ( ) . toExtend < GeminiThinkingOptions > ( )
@@ -316,6 +351,9 @@ describe('Gemini Model Provider Options Type Assertions', () => {
316351 expectTypeOf <
317352 GeminiChatModelProviderOptionsByName [ 'gemini-3-pro-preview' ]
318353 > ( ) . toExtend < GeminiStructuredOutputOptions > ( )
354+ expectTypeOf <
355+ GeminiChatModelProviderOptionsByName [ 'gemini-3-flash-preview' ]
356+ > ( ) . toExtend < GeminiStructuredOutputOptions > ( )
319357 expectTypeOf <
320358 GeminiChatModelProviderOptionsByName [ 'gemini-2.5-pro' ]
321359 > ( ) . toExtend < GeminiStructuredOutputOptions > ( )
@@ -375,6 +413,19 @@ describe('Gemini Model Input Modality Type Assertions', () => {
375413 } )
376414 } )
377415
416+ describe ( 'gemini-3-flash-preview (full multimodal)' , ( ) => {
417+ type Modalities = GeminiModelInputModalitiesByName [ 'gemini-3-flash-preview' ]
418+ type Message = ConstrainedModelMessage < Modalities >
419+
420+ it ( 'should allow all content part types' , ( ) => {
421+ expectTypeOf < MessageWithContent < TextPart > > ( ) . toExtend < Message > ( )
422+ expectTypeOf < MessageWithContent < ImagePart > > ( ) . toExtend < Message > ( )
423+ expectTypeOf < MessageWithContent < AudioPart > > ( ) . toExtend < Message > ( )
424+ expectTypeOf < MessageWithContent < VideoPart > > ( ) . toExtend < Message > ( )
425+ expectTypeOf < MessageWithContent < DocumentPart > > ( ) . toExtend < Message > ( )
426+ } )
427+ } )
428+
378429 describe ( 'gemini-2.5-pro (full multimodal)' , ( ) => {
379430 type Modalities = GeminiModelInputModalitiesByName [ 'gemini-2.5-pro' ]
380431 type Message = ConstrainedModelMessage < Modalities >
0 commit comments