最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

node.js - ConversationRelay Twilio Not allow user input when the agent is speaking - Stack Overflow

programmeradmin0浏览0评论

When the agent is speaking and the user interupts them the agent starts to gather the input even when they are speaking. How do I prevent this?

Here is my init of the Conversation Relay.

const response = new twilio.twiml.VoiceResponse();
            const connect = response.connect();
            const conversationRelay = connect.conversationRelay({
                url: `wss://${serverBaseUrl}/conversation-relay`,
                welcomeGreeting: "Hi! This is reservations. I see you are wanting to reserve a room at The Venetian Resort In Las Vegas. Can I begin by getting your name please?",
                transcriptionProvider: "deepgram",
                //voice: "en-AU-Journey-D",
                //ttsProvider: "Elevenlabs",
                //voice: "Jessica-flash_v2_5",
                //voice: "Charlie-flash_v2_5",
                //speechModel: "nova2-general",
                ttsProvider: "google",
                voice: "en-GB-Journey-F",
                dtmfDetection: "true",
                interruptByDtmf: "true",
                debug: "true",
                //interruptible: false,
                //welcomeGreetingInterruptible: false
            });

When the agent is speaking and the user interupts them the agent starts to gather the input even when they are speaking. How do I prevent this?

Here is my init of the Conversation Relay.

const response = new twilio.twiml.VoiceResponse();
            const connect = response.connect();
            const conversationRelay = connect.conversationRelay({
                url: `wss://${serverBaseUrl}/conversation-relay`,
                welcomeGreeting: "Hi! This is reservations. I see you are wanting to reserve a room at The Venetian Resort In Las Vegas. Can I begin by getting your name please?",
                transcriptionProvider: "deepgram",
                //voice: "en-AU-Journey-D",
                //ttsProvider: "Elevenlabs",
                //voice: "Jessica-flash_v2_5",
                //voice: "Charlie-flash_v2_5",
                //speechModel: "nova2-general",
                ttsProvider: "google",
                voice: "en-GB-Journey-F",
                dtmfDetection: "true",
                interruptByDtmf: "true",
                debug: "true",
                //interruptible: false,
                //welcomeGreetingInterruptible: false
            });
Share asked Mar 4 at 4:29 Max YoungMax Young 1
Add a comment  | 

1 Answer 1

Reset to default 1

I see in your code snippet you have interruptible commented out. By default this is set to true - meaning the agent IS interruptible.

You can accomplish what you're after by setting interruptible to false. Meaning the agent will continue to speak, even when the user attempt to talk over it.

More details on these parameters is located at https://www.twilio/docs/voice/twiml/connect/conversationrelay

发布评论

评论列表(0)

  1. 暂无评论