diegocp01 commited on
Commit
cd87963
·
verified ·
1 Parent(s): 83d3181

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -10
app.py CHANGED
@@ -11,21 +11,19 @@ from Gradio_UI import GradioUI
11
 
12
  # Below is the new deadline calculator tool
13
 
14
-
15
  @tool
16
  def deadline_calculator(start_date: str, days: int) -> str:
17
- """
18
- A tool that calculates the deadline date based on a given start date and duration in days.
19
-
20
  Args:
21
- start_date (str): The starting date for the calculation. It must be in the format 'YYYY-MM-DD'.
22
- days (int): The number of days to add to the start date to compute the deadline.
23
 
24
  Returns:
25
- str: A JSON-formatted string containing:
26
- - "Deadline" (str): The calculated deadline date in 'YYYY-MM-DD' format.
27
- - "Day of Week" (str): The corresponding day of the week for the deadline.
28
- - "Error" (str, optional): If an invalid date format is provided, an error message is returned.
29
 
30
  Example:
31
  >>> deadline_calculator("2025-02-18", 10)
 
11
 
12
  # Below is the new deadline calculator tool
13
 
 
14
  @tool
15
  def deadline_calculator(start_date: str, days: int) -> str:
16
+ """A tool that calculates the deadline date based on a given start date and duration in days.
17
+
 
18
  Args:
19
+ start_date: The starting date in 'YYYY-MM-DD' format.
20
+ days: The number of days until the deadline.
21
 
22
  Returns:
23
+ A JSON-formatted string containing:
24
+ - "Deadline": The calculated deadline date in 'YYYY-MM-DD' format.
25
+ - "Day of Week": The corresponding day of the week for the deadline.
26
+ - "Error": If an invalid date format is provided, an error message.
27
 
28
  Example:
29
  >>> deadline_calculator("2025-02-18", 10)