Enhance OpenAI TTS: add gpt-4o-mini-tts support with instructions parameter
This commit is contained in:
@@ -41,8 +41,9 @@ export class OpenAITTSProvider implements TTSProvider {
|
||||
|
||||
const mp3 = await this.openai.audio.speech.create({
|
||||
model: model,
|
||||
voice: voice as any, // Type casting to any to avoid type issues
|
||||
input: text
|
||||
voice: voice as any,
|
||||
input: text,
|
||||
...(options.instructions ? { instructions: options.instructions } : {})
|
||||
});
|
||||
|
||||
// Cost calculation is based on character count
|
||||
|
||||
Reference in New Issue
Block a user