How to Connect Voiceflow to a Custom AI Model and System Prompt
Use Voiceflow's AI Response block to call a specific model with your own system prompt and temperature, then feed it variables from the conversation.
Beyond answering from a knowledge base, Voiceflow can generate free-form replies with an AI Response block. You choose the model, write a system prompt, set temperature, and inject conversation variables into the prompt. This guide shows how to wire a controlled, on-brand generative reply.
What you need
- A Voiceflow agent project open on the canvas
- A clear idea of the persona and rules the bot should follow
- At least one captured variable to personalize replies (optional)
Step 1: Capture a variable first
Drag a Capture block onto the canvas to store the user's reply into a variable, for example {user_name}. You will reference this inside the AI prompt so the generated answer feels personal.
Step 2: Add an AI Response block
Drop in a Response block and switch its mode to AI (Generative). In its settings, choose the model, set the system prompt, and pick a temperature. Lower temperature means more predictable, on-brand answers; higher means more creative and more risk of drift.
Step 3: Inject variables into the prompt
Reference captured variables with curly braces directly in the system or user prompt. Voiceflow substitutes the stored value at run time before sending the prompt to the model.
System:
You are Acme's concierge. The customer's name is {user_name}.
Their current plan is {plan_tier}. Recommend only upgrades
above their tier. Decline off-topic questions politely.
User:
{last_utterance}Step 4: Test with the variables set
Run the tester and walk through the flow so the capture step fills the variables before the AI block runs. The tester's variable panel lets you confirm the values were stored.
Result
Your bot now produces personalized, rule-bound replies driven by a model you chose and variables you captured. Use a low temperature in production and only raise it once you trust the guardrails in your prompt.
Watch related tutorials
19:40
23:00
16:20
5:42
24:16
33:42