Vapi Agent is not following the prompt precisely.
# support
s
What are the best settings templates AI API to follow the prompt exactlly. Thank you!
v
To make your Vapi Agent follow the prompt as closely as possible, set the model's temperature to 0 for deterministic, prompt-adherent responses. Here’s a template you can use:
Copy code
json
{
  "model": {
    "provider": "openai",
    "model": "gpt-4o",
    "temperature": 0,
    "messages": [
      { "role": "system", "content": "You must follow the prompt exactly." }
    ]
  }
}
Set
"temperature": 0
to reduce randomness and increase prompt fidelity.
For best results, also make your system prompt explicit about strict adherence. [See more in the Vapi documentation.](https://docs.vapi.ai/chat/non-streaming#use-inline-assistant-configuration) Source: - [Non-streaming chat](https://docs.vapi.ai/chat/non-streaming#use-inline-assistant-configuration)
v
Message marked as helpful by @Swan! 🎉
c
Hi Swan, here are the recommended settings for strict prompt following: For OpenAI realtime models:
Copy code
{  "model": {    "provider": "openai",    "model": "gpt-realtime-2025-08-28",    "temperature": 0.2,  // Lower temperature for more deterministic outputs    "maxTokens": 250,    // Control response length    "messages": [      {        "role": "system",        "content": "FOLLOW THESE RULES EXACTLY:\n- Be precise and specific\n- Stay within defined boundaries\n- Never deviate from instructions"      }    ]  }}
Key settings for strict prompt following: - Use lower temperature (0.1-0.3) for more consistent responses - Include clear, explicit rules in system message - Use bullet points or numbered lists in prompts - Be specific about desired behavior - Use CAPS for critical instructions
6 Views