Date difference
ti_date_differenceCalculate the exact span between two dates in days or as Jalali years, months, and days—ideal for age calculations. Omit the end date to measure up to today.
Instructions
Count the days between two dates and give the span as Jalali years, months and days (age calculator).
Omit to_date for today. Both dates use calendar. If to_date is earlier, direction is "before".
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"from_date": "<from_date>"
},
"name": "ti_date_difference"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to_date | No | YYYY-MM-DD in `calendar`, e.g. 1405-08-10. Omit for today. | |
| calendar | No | Calendar of the date(s). | jalali |
| from_date | Yes | Start date YYYY-MM-DD, e.g. birth date 1380-05-17. |