Call suddenly ends after triggering `voicemail` to...
# support
p
This are the voicemail related settings I'm using:
Copy code
python
{
...
"tools": [
    {
        "type": "voicemail",
        "async": False,
        "messages": [
            {
                "type": "request-complete",
                "role": "assistant",
                "content": voicemail_message,
            },
        ],
    }
],
"voicemailDetection": {
    "enabled": True,
    "provider": "twilio",
    "machineDetectionSpeechThreshold": 5000,
    "voicemailDetectionTypes": [
        "machine_end_beep",
        "machine_end_silence",
    ],
},
"voicemailMessage": voicemail_message,
}
v
@progremir It looks like you've configured your voicemail settings to work with Twilio as the provider and enabled voicemail detection. You've set the
machineDetectionSpeechThreshold
to 5000 milliseconds and specified that the detection types include both
machine_end_beep
and
machine_end_silence
. Additionally, you've prepared a voicemail message to be used when the voicemail is detected. If you need to make any changes or have any questions about these settings, feel free to ask!
You can continue this conversation by mentioning me in the message.
Got it. Tagging @User for additional help.
s
call id please.
p
@Shubham Bajaj
a53fe9c7-4e21-4cbe-8460-f13d27024274
s
@progremir please remove the condiitions field from request-start message and let me know how it goes.
p
I don't have any conditions on
request-start
. I have conditions on another tool's
request-complete
.
Have same issues with this settings
Copy code
python
{
    ...,
    "voicemailDetection": {
        "enabled": True,
        "provider": "twilio",
        "machineDetectionTimeout": 30,
        "machineDetectionSpeechThreshold": 2500,
        "machineDetectionSpeechEndThreshold": 2000,
        "machineDetectionSilenceTimeout": 5000,
        "voicemailDetectionTypes": [
            "machine_end_beep",
            "machine_end_silence",
        ],
    },
    "voicemailMessage": voicemail_message,
    "tools": [
        {"type": "voicemail"},
    ],
}
s
Copy code
šŸ”µ 11:47:34:828 Tool Calls Finished. Results: [
  {
    "toolWithToolCall": {
      "type": "voicemail",
      "function": {
        "name": "voicemail",
        "description": "Use this function when you think the call has reached a user's voicemail."
      },
      "messages": [
        {
          "type": "request-start",
          "content": "Hi Emir Amanbekov. My name is Kate. I'm the patient coordinator for discharged patients at Bortz Health Care of Warren.\nJust giving you a call to see if we can get you scheduled for your follow up video visit with one of our therapists.\nWe'd just like to check in and make sure everything is going alright since being discharged from our facility.\nIf you could please give me a call back whenever you get a chance. My number is (832) 200-6080. Thank you. Bye.",
          "conditions": []
        }
      ],
      "async": false,
      "toolCall": {
        "id": "call_W6HhkzoEJAqbWAtIWvRFos7u",
        "type": "function",
        "function": {"name": "voicemail", "arguments": {}}
      }
    },
    "toolCallResult": {
      "result": "Success.",
      "name": "voicemail",
      "toolCallId": "call_W6HhkzoEJAqbWAtIWvRFos7u"
    }
  }
]
check the above empty conditions array, remove it then your message will be voiced out.
p
never added
conditions
to
voicemail
tool. the recent config doesn't even contain
messages
if u look closely. are you sure vapi doesn't set these values by default?
s
yes I am sure Vapi doesn't adds by default.
can you share the recent call id.
p
18589df5-96a2-4854-9b8b-a3b990edbbf6
hey @Shubham Bajaj! Any updates on this?
@User
s
lemme check, I am not at the desk.
p
@Shubham Bajaj any updates?
s
Hey @progremir, can you set the voicemail directly and not pass it through the voicemail tool? Because of that, things must be getting overridden and causing issues. So, delete the tool and simply use the voicemail message parameter and it will work.
p
but then it solely relies on twilio's AMD and works in 50% of the cases
s
Yeah, I get that
p
@Sahil am I right?
s
yeah, it is correct
but for only tools part don't use voicemail_message pararmeter
simply use tool with request-start message
p
i don't use anything like that
do you suggest setting voicemail message via
request-start
message?
s
yeah.
p
just noticed that docs no longer have
VoicemailTool
as an option in
tools
section. Are you guys deprecating it?
s
Nope.
not atm
2 Views