mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2025-12-19 03:42:23 -06:00
refactor(chatbot): enhance EvoaiService with OpenAI integration
- Integrated OpenAI service into the EvoaiService to streamline audio message transcription. - Updated the constructor to initialize OpenaiService, allowing for direct transcription of audio messages. - Refactored audio message handling to utilize the OpenAI service for improved reliability and maintainability. - Adjusted the processing logic to handle transcription results more effectively, ensuring fallback content is provided when transcription fails. This commit focuses on enhancing the EvoaiService's capabilities by leveraging OpenAI for audio transcription, improving overall service functionality and code structure.
This commit is contained in:
@@ -45,11 +45,11 @@ export class ChannelStartupService {
|
||||
this.chatwootCache,
|
||||
);
|
||||
|
||||
public typebotService = new TypebotService(waMonitor, this.configService, this.prismaRepository);
|
||||
|
||||
public openaiService = new OpenaiService(waMonitor, this.prismaRepository, this.configService);
|
||||
|
||||
public difyService = new DifyService(waMonitor, this.configService, this.prismaRepository);
|
||||
public typebotService = new TypebotService(waMonitor, this.configService, this.prismaRepository, this.openaiService);
|
||||
|
||||
public difyService = new DifyService(waMonitor, this.configService, this.prismaRepository, this.openaiService);
|
||||
|
||||
public setInstance(instance: InstanceDto) {
|
||||
this.logger.setInstance(instance.instanceName);
|
||||
|
||||
Reference in New Issue
Block a user