Skip to content

Commit

Permalink
changed /voice to be eleven labs
Browse files Browse the repository at this point in the history
  • Loading branch information
theofandrich committed Oct 5, 2023
1 parent a1a3fee commit fd691f6
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/modules/text-to-speech/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ import { ElevenlabsClient } from '../../elevenlabs/elevenlabsClient'
import config from '../../config'

enum SupportedCommands {
VOICE = 'voice',
V11M = 'v11m',
V11M = 'voice',
// V11M = 'v11m',
V11F = 'v11f',
}

Expand Down Expand Up @@ -48,11 +48,11 @@ export class TextToSpeechBot implements PayableBot {
}

public async onEvent (ctx: OnMessageContext): Promise<void> {
if (ctx.hasCommand(SupportedCommands.VOICE)) {
const text = this.getTextFromMessage(ctx)
await this.onTextToSpeech(ctx, { text, ssmlGender: 'MALE', languageCode: 'en-US' })
return
}
// if (ctx.hasCommand(SupportedCommands.VOICE)) {
// const text = this.getTextFromMessage(ctx)
// await this.onTextToSpeech(ctx, { text, ssmlGender: 'MALE', languageCode: 'en-US' })
// return
// }

if (ctx.hasCommand(SupportedCommands.V11M)) {
const text = this.getTextFromMessage(ctx)
Expand Down

0 comments on commit fd691f6

Please sign in to comment.