Date
The rules for how dates needs to be formated when uploaded in to the Alviss AI platform.
Overview
The Date field in all data files must follow the ISO 8601 standard, an international format for representing dates and times. This ensures consistency, compatibility, and accurate temporal alignment across datasets in Alviss AI.
ISO 8601 supports dates alone or combined with times and time zones, providing flexibility for different granularities. Always use this format to avoid upload errors or model inaccuracies.
Format Requirements
- Basic Date: Expressed as
YYYY-MM-DD, where:YYYYis the four-digit year.MMis the two-digit month (01-12, with leading zero).DDis the two-digit day (01-31, with leading zero).
- With Time: Append
Tfollowed byHH:MM:SS, where:HHis the 24-hour format hour (00-23).MMis the minute (00-59).SSis the second (00-59).
- With Time Zone: Append
±HH:MMafter the time, where:±indicates offset from UTC (plus for ahead, minus for behind).HH:MMis the offset in hours and minutes (e.g., +00 for UTC).
Use the start of the period for aggregated data (e.g., Monday for weekly). For details, see Periodicity.
Examples
Valid ISO 8601 formats include:
2023-04-02(date without time)2023-04-02T15:30:00(date with time)2023-04-02T15:30:00-05:00(date with time and time zone offset)2023-04-02T15:30:00+02:00(date with time and time zone offset)
Best Practices
- Consistency: Use the same level of detail (e.g., date-only or with time) across all files in a project. Align with the project's Periodicity to ensure dates match interval starts.
- Time Zones: Include offsets if data spans regions; default to UTC if unknown to avoid assumptions.
- Data Preparation: Convert non-ISO formats (e.g., MM/DD/YYYY) externally before upload. Tools like Python's
datetimemodule can help. - Edge Cases: For periods like quarters or years, use the first day (e.g.,
2023-01-01for Q1). Handle leap years and invalid dates (e.g., no February 30) to prevent errors. - Validation: After upload, check dates in the Activities dashboard for alignment and completeness.
See the Periodicity page for details on which dates to use depending on the project's periodicity.
Short summary of rules: Dates must be the first day of the period—e.g., Monday for weekly, 1st for monthly, 1st of starting month for quarterly (January 1 for Q1), January 1 for yearly. Always follow ISO 8601 for weeks (starting Monday).
Common Issues and Troubleshooting
- Invalid Formats: Non-ISO dates (e.g.,
04-02-2023) will cause upload failures—reformat toYYYY-MM-DD. - Missing Leading Zeros: Use
2023-01-01, not2023-1-1. - Time Zone Mismatches: Inconsistent offsets can skew time-series; standardize to one zone.
- Period Mismatch: Dates not on period starts (e.g., weekly on Friday) violate Periodicity—adjust accordingly.
For related topics, see Periodicity or Upload Data. If issues arise, contact support.