@@ -504,9 +504,6 @@ export const groqPlugin: Plugin = {
504
504
logger . log ( 'audioBuffer' , audioBuffer ) ;
505
505
const baseURL = getCloudflareGatewayBaseURL ( runtime , 'groq' ) ;
506
506
507
- const baseURL = runtime . getSetting ( 'OPENAI_BASE_URL' ) ?? 'https://api.openai.com/v1' ;
508
- const baseURL = getCloudflareGatewayBaseURL ( runtime , 'groq' ) ;
509
-
510
507
const formData = new FormData ( ) ;
511
508
formData . append ( 'file' , new Blob ( [ audioBuffer ] , { type : 'audio/mp3' } ) ) ;
512
509
formData . append ( 'model' , 'whisper-1' ) ;
@@ -536,11 +533,6 @@ export const groqPlugin: Plugin = {
536
533
runtime . getSetting ( 'GROQ_SMALL_MODEL' ) ??
537
534
runtime . getSetting ( 'SMALL_MODEL' ) ??
538
535
'llama-3.1-8b-instangt' ;
539
- const baseURL = getCloudflareGatewayBaseURL ( runtime , 'groq' ) ;
540
- const groq = createGroq ( {
541
- apiKey : runtime . getSetting ( 'GROQ_API_KEY' ) ,
542
- baseURL,
543
- } ) ;
544
536
545
537
try {
546
538
if ( params . schema ) {
@@ -568,8 +560,6 @@ export const groqPlugin: Plugin = {
568
560
}
569
561
} ,
570
562
[ ModelType . OBJECT_LARGE ] : async ( runtime , params : ObjectGenerationParams ) => {
571
- const baseURL = getCloudflareGatewayBaseURL ( runtime , 'groq' ) ;
572
- //const baseURL = runtime.getSetting('OPENAI_BASE_URL') ?? 'https://api.openai.com/v1';
573
563
const baseURL = getCloudflareGatewayBaseURL ( runtime , 'groq' ) ;
574
564
const groq = createGroq ( {
575
565
apiKey : runtime . getSetting ( 'GROQ_API_KEY' ) ,
0 commit comments