https://retellai.com/?utm_source=discord&utm_medium=seo logo
How we can fix repeated question in conversational...
# ❓・ai-evy-support
a
@AI Evy How we can fix repeated question in conversational flow if the question is already answered by the user before asked but its in flow how to fix so that the agent don't ask again
a
Thanks for tagging me @akshat_9728. I'll look through relevant sources and get back to you shortly.
### Answer To prevent your Conversation Flow agent from repeating questions that users have already answered, you can use dynamic variables combined with transition conditions [(1) ]() . Here's the approach: 1. Set a dynamic variable after the user answers a question to track that the information was collected [(2) ]() [(3) ]() 2. Use equation-based transition conditions to skip nodes when the variable indicates the answer was already provided [(1) ]() For example, if you're collecting a user's name, you can: - Set a variable like
{{name_collected}}
to
true
after the user provides their name - Before the node that asks for the name, add an equation transition condition:
{{name_collected}} == true
- If true, transition directly to the next node, bypassing the question You can also use the exists operator in equation conditions to check if a variable has been set:
{{name}} exists
Important notes: - Equation conditions are evaluated from top to bottom, and the flow travels on the first condition that evaluates to true - You can only use variables that are passed in as dynamic variables for equation conditions - Make sure variables are treated as dynamic variables so they're accessible across branches [(4) ]() If the agent still repeats questions despite these conditions, you may need to adjust your node instructions to be more flexible or add transition finetune examples to help the model better understand when to skip already-answered questions [(5) ](
on-flow/debug-guide) [(1) ]() . **
​ To learn more, see the sources I considered: [[1] Step 3: Add transition conditions](https://docs.retellai.com/build/conversation-flow/transition-condition) [[2] Create Conversation Flow](https://docs.retellai.com/api-references/create-conversation-flow) [[3] Update Conversation Flow](https://docs.retellai.com/api-references/update-conversation-flow) [[4] How to set up the flow to avoid repeating what was mentioned already](https://discord.com/channels/1186424376300679209/1390655241170456617) [[5] Debug guide](https://docs.retellai.com/build/conversation-flow/debug-guide) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
a
@AI Evy how to set condition so it doesn't repeat if there are too many questions
a
Thanks for the follow-up, @akshat_9728. I'll get back to you soon.
2. Set up bypass transitions For each question node, add an equation transition that checks if the variable already has a value : - If
{{variable_name}} exists
evaluates to true, transition directly to the next node, skipping the question - If
{{variable_name}} does not exist
, proceed to ask the question 3. Order your conditions correctly Equation conditions are evaluated from top to bottom, and the flow follows the first condition that evaluates to true . Place your "exists" checks at the top of your transition conditions. 4. Use Logic Split Nodes for complex branching If you need to check multiple variables at once, consider using a Logic Split Node to create conditional branches based on which variables are already populated [(3) ]() . Important note: Transitions typically happen after the user speaks [(1) ]() . If you're using equation conditions with dynamic variables and need automatic transitions without user input, you may need to enable "skip response" on conversation nodes and add a Logic Split Node after it [(4) ]() .
### Answer To prevent repeating questions when you have multiple questions in your flow, you can use equation-based transition conditions with dynamic variables to check if information already exists [(1) ]() [(2) ]() . Here's the strategy for multiple questions: 1. Check if variables exist before asking Use the
exists
operator in equation conditions to skip questions when data is already available [(1) ]() :
Copy code
{{user_email}} exists
{{user_phone}} exists
{{preferred_language}} exists
​ To learn more, see the sources I considered: [[1] Step 3: Add transition conditions](https://docs.retellai.com/build/conversation-flow/transition-condition) [[2] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) [[3] Node Overview](https://docs.retellai.com/build/conversation-flow/node) [[4] Issues with transitions - getting stuck on Conversation and Logic Split Nodes using dynamic variable](https://discord.com/channels/1186424376300679209/1437030319541719172) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.