End call not working with gpt-4o
# support
t
I have clear instructions in my prompt to use endCall function to end the call, but this almost never happens. I'm using gpt-4o and have end call feature enabled, of course.
v
Hi @tgaro, I'm an AI assistant for Vapi. I'll analyze available sources and get back to you shortly.
----------------------------- **While I generate an answer, here are some sources that might be helpful**: * [Function Calling]() * [Call Forwarding]() * [Outbound Sales Example]() * [Inbound Calling]() -----------------------------
### Answer It seems like there might be an issue with how the endCall function is being triggered in your setup. Since you mentioned using clear instructions in your prompt and having the end call feature enabled, it's important to ensure that the model is interpreting and executing these instructions as expected. If the endCall function is not being triggered as it should, you may want to review the specific conditions or contexts under which your assistant is instructed to end the call. The model's behavior can be influenced by how the instructions are framed in the system prompt or the assistant's configuration. Additionally, double-check that the
endCallFunctionEnabled
is properly configured in your assistant. If the issue persists, it could be helpful to examine the logs or debugging information to identify any patterns or errors related to the function call behavior [(1)]() . For further troubleshooting, you might also consider reaching out to Vapi's support or checking the documentation for any updates or common issues related to function calls with GPT-4 models. : [Function Calling]()
Got it. Tagging @User for additional help.
s
Did you enable endCallFunction and added prompt related to when to trigger the endCallFunction?
t
Yes I did and over the past couple months, using a variety of prompts, it's been a very low percentage of calls that end call properly
s
provide me your latest call_id
t
@Sahil 9c959faa-8108-452e-b577-d4fbbd751502 thanks
s
Dude your prompt 🤡
Your prompt size is 10k it will not work.
Please reduce the prompt size.
16 Views