shayanrmt
03/05/2025, 6:41 PMVapi Support Bot
03/05/2025, 6:42 PMtopic
variable is defined and has a value before you use it in your systemPrompt
and initialMessage
. If topic
is undefined or empty, it could lead to issues.
2. **Correct JSON Structure**: Ensure that your JSON structure is correctly formatted. The assistantOverrides
and config
should be properly nested within the main configuration object.
3. **API Request**: When sending this configuration to the VAPI API, ensure that you are using the correct endpoint and that your request is properly formatted. If the API request fails, the assistant may revert to a default prompt.
4. **Check for Errors**: Look for any error messages in your console or logs that might indicate what went wrong during the setup.
5. **Testing with Static Values**: As a troubleshooting step, try replacing topic
with a static string to see if the prompt works without the variable. This can help you determine if the issue is with the variable itself.
If you follow these steps and still encounter issues, feel free to share any error messages or additional details, and I'll be happy to help further! 😊
Sources:
- [Vapi Dynamic Variables](https://docs.vapi.ai/assistants/dynamic-variables)
- [Vapi Quickstart Dashboard](https://docs.vapi.ai/quickstart/dashboard)
- [Vapi & Discord Documentation Discussion](https://discord.com/channels/1211482211119796234/1211483291191083018/threads/1333350360932421682)shayanrmt
03/05/2025, 6:57 PMPraveen
03/07/2025, 11:39 AM"assistantOverrides": {
"model": {
"provider": "openai",
"messages": [
{
"role": "system",
"content": "insert-your-system-prompt-here"
}
]
},
"firstMessage": "insert-first-message-here"
}
The key difference is that systemPrompt needs to be nested within the model object in the assistantOverrides. The system analyzes the model configuration and applies the system prompt from there rather than from the root level.Shubham Bajaj
03/07/2025, 11:39 AM