File tree 2 files changed +6
-5
lines changed
2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -113,7 +113,8 @@ export async function generateText({
113
113
114
114
case ModelProvider . GROK : {
115
115
prettyConsole . log ( "Initializing Grok model." ) ;
116
- const grok = createGroq ( { apiKey } ) ;
116
+ const serverUrl = models [ provider ] . endpoint ;
117
+ const grok = createOpenAI ( { apiKey, baseURL : serverUrl } ) ;
117
118
118
119
const { text : grokResponse } = await aiGenerateText ( {
119
120
model : grok . languageModel ( model , {
Original file line number Diff line number Diff line change @@ -74,10 +74,10 @@ const models: Models = {
74
74
} ,
75
75
endpoint : "https://api.x.ai/v1" ,
76
76
model : {
77
- [ ModelClass . SMALL ] : "grok-2- beta" ,
78
- [ ModelClass . MEDIUM ] : "grok-2- beta" ,
79
- [ ModelClass . LARGE ] : "grok-2- beta" ,
80
- [ ModelClass . EMBEDDING ] : "grok-2- beta" , // not sure about this one
77
+ [ ModelClass . SMALL ] : "grok-beta" ,
78
+ [ ModelClass . MEDIUM ] : "grok-beta" ,
79
+ [ ModelClass . LARGE ] : "grok-beta" ,
80
+ [ ModelClass . EMBEDDING ] : "grok-beta" , // not sure about this one
81
81
} ,
82
82
} ,
83
83
[ ModelProvider . GROQ ] : {
You can’t perform that action at this time.
0 commit comments