https://retellai.com/?utm_source=discord&utm_medium=seo logo
How to create responses based on the variable valu...
# ❓・ai-evy-support
a
@AI Evy How to create responses based on the variable value in the finetuning conversation node ?
a
Thanks for tagging me @afrah_85175. I'll look through relevant sources and get back to you shortly.
### Answer Based on the available sources, I can explain how to work with finetune examples in conversation nodes, though the documentation doesn't specifically detail creating responses based on variable values within finetune examples. For conversation nodes, you can add finetune examples to improve agent responses [(1) ]() . When configuring finetune examples, you provide a transcript as context and can select
user
,
agent
, or
function
as the role of the transcript [(2) ]() . When selecting
function
as the role, you can fill out both the invocation and result of the function . For finetune examples in conversation nodes, supplying a transcript as the context is everything you need to do . It's not necessary to provide the entire call transcript - you can simply provide the relevant part . At least one
agent
response is required, as this is finetuning the agent's response . The documentation mentions that default dynamic variables can be referenced throughout the conversation flow [(3) ]() , and these variables can be used in transition conditions using equation syntax like
{{variable_name}}
[(4) ]() . However, the specific process for incorporating variable values into finetune conversation examples isn't detailed in the available sources. For more specific guidance on using variables within finetune examples, you might want to check out these potentially helpful resources: - [Finetune Examples]() - [Create Conversation Flow]() - [Debug guide](
ocs.retellai.com/build/conversation-flow/debug-guide) Would you like me to provide a general approach based on my knowledge instead?
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
a
a
Thanks for the follow-up, @afrah_85175. I'll get back to you soon.
riables You can set default values for dynamic variables at the agent level [(1) ]() . Default variables serve as a fallback and will only be used when specific variables aren't included in the call request . ## Best Practices - Set defaults at agent level: Configure fallback values in agent settings - Use defensive prompting: Design prompts that work with or without variables - Test thoroughly: Always test with both set and unset variables - Document requirements: Clearly indicate which variables are required vs optional If you continue experiencing issues with default dynamic variables not saving or displaying, this appears to be a known platform issue that has been addressed, but you may need to republish your agent or contact support if the problem persists.
### Answer Based on the documentation and community discussions, there are several reasons why your default dynamic variables might not be displaying their values in the transcript: ## Default Behavior When Variables Are Missing When a dynamic variable has no assigned value, it remains in its raw form with the curly braces intact [(1) ]() . For example, if you have a prompt with
"Hello {{user_name}}, how can I help you today?"
and
user_name
is not provided, it will display as
"Hello {{user_name}}, how can I help you today?"
. ## Common Issues and Solutions ### 1. Agent Version Mismatch Check that your phone number is associated with the current version of your agent [(2) ]() . Make sure it's the version you're looking at in the dashboard, as commonly people phone an older version of their agent . ### 2. Default Variables Not Saving There have been reported issues with default dynamic variables not saving properly [(3) ]() . Users have experienced situations where they enter values for default dynamic variables, click save, but when they return to the flow, the variables show the previous values . This issue has been reported as fixed . ### 3. Agent Publishing Ensure you have published your agent after making changes to the default dynamic variables [(4) ]() . ### 4. Prompting Specificity Be more explicit in your prompting, especially if you're using a weaker model [(2) ]() . For example, use "The user's name is: {{name}}" rather than just referencing the variable indirectly . ## Setting Default Va
​ To learn more, see the sources I considered: [[1] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) [[2] Discord message from @nitss21 on 2025-08-25](https://discord.com/channels/1186424376300679209/1186462578310910112/1409651256460574952) [[3] Default Dynamic Variables not saving](https://discord.com/channels/1186424376300679209/1350197993688535061) [[4] Default Dynamic Variables not saving](https://discord.com/channels/1186424376300679209/1403152516513927258) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
a
@AI Evy I want to know the variables values when testing each node ?
a
Thanks for the follow-up, @afrah_85175. I'll get back to you soon.
### Answer Based on the available sources, I can provide information about dynamic variables in conversation flow nodes, though the specific process for viewing variable values during individual node testing isn't detailed in the documentation. ## Dynamic Variables in Conversation Flow You can use dynamic variables throughout your conversation flow using the
{{variable_name}}
syntax [(1) ]() . These variables can be used in several places including prompts, begin messages, tool configurations, and call handling . ## Extract Dynamic Variable Node To capture and store information as dynamic variables during conversation flow, you can use the Extract Dynamic Variable Node [(2) ]() . This node allows you to: - Extract information from conversations and store them as dynamic variables - Create variables of different types: Text, Number, Enum, or Boolean - Define variable names and descriptions for what the value should be ## Checking Variable Values in Transition Conditions You can check if dynamic variables exist or have specific values using equation conditions in transition conditions [(3) ]() :
Copy code
{{variable_name}} exists
{{variable_name}} does not exists
{{user_age}} > 18
{{user_location}} == "New York"
## Default System Variables Retell automatically provides system variables that you can reference [(1) ]() : -
{{current_agent_state}}
- Current state name for multi-state agents -
{{previous_agent_state}}
- Previous state name for multi-state agents -
{{current_time}}
- Current time in America/Los_Angeles -
{{call_type}}
- Call type, web_call or phone_call ## Community Insights Based on community discussions, you can set static values in Extract Variables nodes instead of dynamic ones based on conversation, which can help track which node the flow came from [(4) ]() . For example, setting a state variable to "BUY" for a house buying node and "RENT" for a house renting node . The documentation doesn't specifically detail how to view variable values during individual node testing. For more specific guidance on debugging and viewing variable values during node testing, you might want to: Check out these potentially useful sources: - [Dynamic Variables]() - [Extract Dynamic Variable Node]() - [Step 3: Add transition conditions]() Would you like me to provide a general approach based on my knowledge instead?
​ To learn more, see the sources I considered: [[1] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) [[2] Extract Dynamic Variable Node](https://docs.retellai.com/build/conversation-flow/extract-dv-node) [[3] Step 3: Add transition conditions](https://docs.retellai.com/build/conversation-flow/transition-condition) [[4] Discord message from @rkrausse on 2025-08-20](https://discord.com/channels/1186424376300679209/1186462578310910112/1407859048426115163) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
a
@AI Evy How to access default dynamic variables ?
a
Thanks for the follow-up, @afrah_85175. I'll get back to you soon.
### Answer Based on the documentation, here's how to access default dynamic variables in Retell AI: ## Setting Default Dynamic Variables You can configure agent-level default dynamic variables that serve as fallback values [(1) ]() . Default variables will only be used when specific variables aren't included in the call request . ### For Retell LLM Response Engine When creating or updating a Retell LLM, you can set default dynamic variables using the
default_dynamic_variables
field [(2) ]() [(3) ]() :
Copy code
javascript
const llmResponse = await client.llm.update('16b980523634a6dc504898cda492e939', {
 begin_message: 'Hey I am a virtual assistant calling from Retell Hospital.',
}) ;
[(2) ]() The response includes the default dynamic variables structure [(2) ]() [(3) ]() :
Copy code
json
{
 "default_dynamic_variables": {
 "customer_name": "John Doe"
 }
}
[(2) ]() , [(3) ]() ### For Conversation Flow When creating a conversation flow, you can also set default dynamic variables [(4) ]() :
Copy code
json
{
 "default_dynamic_variables": {
 "company_name": "Retell Inc",
 "support_hours": "9 AM - 5 PM"
 }
}
## Using Dynamic Variables Once configured, you access these variables using the
{{variable_name}}
syntax in [(1) ]() : - **Prompts**: Agent instructions and personality - **Begin message**: Opening greeting - **Tool configurations**: Custom function URLs, tool descriptions, property descriptions - **Call handling**: Voicemail prompts and messages, transfer call phone numbers, warm transfer instructions ## Important Notes All values in
retell_llm_dynamic_variables
must be strings . Numbers, booleans, or other data types are not supported . Based on community feedback, make sure dynamic variables are sent as strings and match the exact names in your prompt (case-sensitive) [(5) ]() . If the prompt doesn't explicitly use them or the tool isn't set up correctly, they may just show in the Data tab but aren't used .
​ To learn more, see the sources I considered: [[1] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) [[2] Update Retell LLM](https://docs.retellai.com/api-references/update-retell-llm) [[3] Create Retell LLM](https://docs.retellai.com/api-references/create-retell-llm) [[4] Create Conversation Flow](https://docs.retellai.com/api-references/create-conversation-flow) [[5] dynamic variables are not being used even though in data tab it was captured](https://discord.com/channels/1186424376300679209/1380529470468919320) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
a
@AI Evy How to send retell_llm_dynamic_variables in conversation flow agent ?
a
Thanks for the follow-up, @afrah_85175. I'll get back to you soon.
### Answer ### Answer Based on the documentation, here's how to send
retell_llm_dynamic_variables
for conversation flow agents: ## For Outbound Calls When using the Create Phone Call API, set your variables in the
retell_llm_dynamic_variables
field [(1) ]() . All values must be strings:
Copy code
json
{
 "user_name": "John Smith",
 "product_name": "Premium Plan",
 "account_status": "active"
}
## For Inbound Calls You can supply dynamic variables in the Inbound Call Webhook . The documentation notes that more details are available at the linked documentation. ## JSON Format Requirements Based on community discussions, ensure your JSON is properly formatted as an object, not a string [(2) ]() . The correct format is:
Copy code
json
"retell_llm_dynamic_variables": {
  "first_name": "Fred2",
  "business_type": "Chiropractor"
}
Avoid this incorrect format:
Copy code
json
"retell_llm_dynamic_variables": "{ 'first_name' : 'Fred2',  'business_type' : 'Chiropractor' }"
## Important Notes - All values in
retell_llm_dynamic_variables
must be strings [(1) ]() . Numbers, booleans, or other data types are not supported. - The variables work in general prompts and begin messages [(3) ]() . - You can also use the
{{}}
format in dashboard prompts . ## Default Dynamic Variables You can also configure default dynamic variables at the agent level using the
default_dynamic_variables
field [(1) ]() , [(4) ]() . These serve as fallback values when specific variables aren't included in the call request.
​ To learn more, see the sources I considered: [[1] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) [[2] Discord message from @fredg9582 on 2025-01-13](https://discord.com/channels/1186424376300679209/1186462578310910112/1328256759110045722) [[3] Issue using retell_llm_dynamic_variables](https://discord.com/channels/1186424376300679209/1223405124882534470) [[4] Create Retell LLM](https://docs.retellai.com/api-references/create-retell-llm) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
a
@AI Evy Can i access default dynamic variables through out the conversation flow without sending from retell_llm_dynamic_variables ?
a
Thanks for the follow-up, @afrah_85175. I'll get back to you soon.
​ To learn more, see the sources I considered: [[1] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) [[2] Create Conversation Flow](https://docs.retellai.com/api-references/create-conversation-flow) ​
### Answer Yes, you can access default dynamic variables throughout the conversation flow without sending them via
retell_llm_dynamic_variables
[(1) ]() . ## How Default Dynamic Variables Work Default dynamic variables serve as fallback values and will only be used when specific variables aren't included in the call request . You can set default values for dynamic variables at the agent level . ## For Conversation Flow Agents When creating a conversation flow, you can configure default dynamic variables using the
default_dynamic_variables
field [(2) ]() :
Copy code
json
{
  "default_dynamic_variables": {
    "company_name": "Retell Inc",
    "support_hours": "9 AM - 5 PM"
  }
}
## Where You Can Use Default Dynamic Variables Once configured, these default dynamic variables can be referenced throughout the conversation flow using the
{{variable_name}}
syntax in [(1) ]() : - **Prompts**: Agent instructions and personality - **Begin message**: Opening greeting - **Tool configurations**: Custom function URLs, tool descriptions, property descriptions - **Call handling**: Voicemail prompts and messages, transfer call phone numbers, warm transfer instructions ## Default System Variables Retell also automatically provides system variables that require no configuration : -
{{current_agent_state}}
- Current state name (for multi-state agents) -
{{previous_agent_state}}
- Previous state name (for multi-state agents) -
{{current_time}}
- Current time in America/Los_Angeles -
{{call_type}}
- Call type, web_call or phone_call The key point is that default dynamic variables act as fallbacks - they're automatically available throughout your conversation flow without needing to be sent in each individual call request .
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.