11import { createAnthropic } from '@ai-sdk/anthropic'
22import { AnthropicMessagesModelId } from '@ai-sdk/anthropic/internal'
3+ import { createGoogleGenerativeAI } from '@ai-sdk/google'
4+ import { GoogleGenerativeAILanguageModel } from '@ai-sdk/google/internal'
35import { createOpenAI } from '@ai-sdk/openai'
46import { OpenAIChatModelId } from '@ai-sdk/openai/internal'
57import { createAiGateway } from 'ai-gateway-provider'
6- import { createGoogleGenerativeAI } from '@ai-sdk/google'
78import { env } from 'cloudflare:test'
89import { describe } from 'vitest'
910import { createWorkersAI } from 'workers-ai-provider'
10- import { GoogleGenerativeAILanguageModel } from '@ai-sdk/google/internal'
1111
1212export const factualityModel = getOpenAiModel ( 'gpt-4o' )
1313
@@ -41,13 +41,13 @@ function getAnthropicModel(modelName: AnthropicMessagesModelId) {
4141 accountId : env . CLOUDFLARE_ACCOUNT_ID ,
4242 gateway : env . AI_GATEWAY_ID ,
4343 apiKey : env . AI_GATEWAY_TOKEN ,
44- } ) ;
45-
44+ } )
45+
4646 const ai = createAnthropic ( {
4747 apiKey : '' ,
4848 } )
4949
50- const model = aigateway ( [ ai ( modelName ) ] ) ;
50+ const model = aigateway ( [ ai ( modelName ) ] )
5151
5252 return { modelName, model, ai }
5353}
@@ -61,9 +61,9 @@ function getGeminiModel(modelName: GoogleGenerativeAILanguageModel['modelId']) {
6161 accountId : env . CLOUDFLARE_ACCOUNT_ID ,
6262 gateway : env . AI_GATEWAY_ID ,
6363 apiKey : env . AI_GATEWAY_TOKEN ,
64- } ) ;
64+ } )
6565
66- const ai = createGoogleGenerativeAI ( { apiKey : '' } )
66+ const ai = createGoogleGenerativeAI ( { apiKey : '' } )
6767
6868 const model = aigateway ( [ ai ( modelName ) ] )
6969
@@ -85,7 +85,7 @@ export const eachModel = describe.each([
8585 getOpenAiModel ( 'gpt-4o' ) ,
8686 getOpenAiModel ( 'gpt-4o-mini' ) ,
8787 // getAnthropicModel('claude-3-5-sonnet-20241022'), TODO: The evals pass with anthropic, but our rate limit is so low with AI wholesaling that we can't use it in CI because it's impossible to get a complete run with the current limits
88- getGeminiModel ( 'gemini-2.0-flash' )
88+ getGeminiModel ( 'gemini-2.0-flash' ) ,
8989 // llama 3 is somewhat inconsistent
9090 //getWorkersAiModel("@cf/meta/llama-3.3-70b-instruct-fp8-fast")
9191 // Currently llama 4 is having issues with tool calling
0 commit comments