https://retellai.com/?utm_source=discord&utm_medium=seo logo
retell in the environment it is gettting the curre...
# ❓・ai-evy-support
g
@AI Evy retell in the environment it is gettting the current date correctly and It is not getting the specific day of the week given a specific date and also I ant able to parse upcoming Monday to Exact day It is getting one earlier or later
a
Thanks for tagging me @gk. I'll look through relevant sources and get back to you shortly.
### Answer Based on the available sources, Retell AI provides system default dynamic variables for date and time information [(1) ]() . The
{{current_time}}
variable gives you the current time in
America/Los_Angeles
timezone in the format "Thursday, March 28, 2024 at 11:46:04 PM PST" . You can also use
{{current_time_[timezone]}}
for specific timezones, such as
{{current_time_Australia/Sydney}}
. For calendar information, Retell AI offers
{{current_calendar}}
which provides a 14-day calendar in
America/Los_Angeles
timezone . The format is:
Copy code
Thursday, March 28, 2024 PST (Today)
Friday, March 29, 2024 PST
…
Wednesday, April 10, 2024 PST
You can also use timezone-specific calendar variables like
{{current_calendar_[timezone]}}
. To improve date parsing accuracy in your prompts: 1. Use the system variables directly in your agent's prompt to provide context 2. Instruct your agent explicitly about date calculation logic in your general prompt or state prompts [(2) ]() [(3) ]() 3. Consider using custom functions to handle complex date parsing if the LLM struggles with relative dates like "upcoming Monday" The sources don't provide specific troubleshooting for day-of-week parsing errors. If you're experiencing consistent off-by-one errors with relative dates, you may need to add explicit instructions in your prompt about how to calculate relative dates from the
{{current_time}}
or
{{current_calendar}}
variables.
​ To learn more, see the sources I considered: [[1] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) [[2] Create Retell LLM](https://docs.retellai.com/api-references/create-retell-llm) [[3] Update Retell LLM](https://docs.retellai.com/api-references/update-retell-llm) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.