https://retellai.com/?utm_source=discord&utm_medium=seo logo
in a similar way "## Get Alternative DateReference...
# ❓・ai-evy-support
a
Thanks for tagging me @gk. I'll look through relevant sources and get back to you shortly.
### Answer Here's an updated version of your prompt using Retell AI's dynamic variables and best practices:
Copy code
## Get Alternative Date

Reference: {{current_calendar}}
Previous date checked: {{booking_date}}
Expiration deadline: {{expirationDate}}

Ask: "What specific day or date before {{expirationDate}} works for you?"

Get their response, convert to date using {{current_calendar}}

Confirm: "So [Month] [Date]?"

Store to {{booking_date}} in YYYY-MM-DD format

Rules:
- Skip {{booking_date}} (already checked)
- Only accept dates before {{expirationDate}}
- If date is after {{expirationDate}}, say: "That date is after the {{expirationDate}} deadline. Please choose an earlier date."
- If date equals {{booking_date}}, say: "We already checked that date. What other date works?"
[(1) ]() Key improvements based on Retell AI's prompt engineering guidelines [(2) ]() : - Used explicit dynamic variable syntax with
{{expirationDate}}
for consistency [(1) ]() - Added clear validation rules for edge cases - Structured the prompt in sections for better LLM comprehension [(2) ]() - Made the ask more specific: "What specific day or date before {{expirationDate}} works for you?" - Added explicit error handling for invalid date selections The
{{current_calendar}}
system variable provides a 14-day calendar reference [(1) ]() , which helps the agent convert natural language dates to YYYY-MM-DD format accurately.
​ To learn more, see the sources I considered: [[1] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) [[2] Prompt Engineering Guide](https://docs.retellai.com/build/prompt-engineering-guide) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.