Sales

Provide Sales data in Alviss AI as core dataset for outcomes like revenue volume with units sold price per unit optional profit.

Sales data is the core and most critical dataset in Alviss AI, as it represents actual business outcomes like revenue and volume. This file is the only required data source for modeling and must include units sold and price per unit; profit per unit is optional but recommended for advanced ROI analysis. It captures transactional details, enabling Alviss AI to model demand drivers, price elasticity, and performance trends.

Examples include daily/weekly sales volumes and average prices for products like insurance policies or consumer goods. Sourced from CRM systems, ERP software, point-of-sale records, or e-commerce platforms, this data forms the foundation for attributions (e.g., linking marketing to sales), simulations (e.g., "what if" price changes), predictions (e.g., forecasting demand), and optimizations (e.g., pricing strategies). Without accurate sales data, models cannot quantify impacts on KPIs, making it essential for all projects.

Data Requirements

The Sales Data file must include the following columns (headers). All columns are required unless marked as optional:

  • Country (string, required): A three-letter country code per ISO 3166 standard (e.g., "SWE" for Sweden), indicating where the sales occurred.
  • Region (string, required): The region within the country (e.g., "all" for nationwide or a specific ISO 3166-2 code like "SE-AB" for Stockholm County in Sweden).
  • Grouping (string, optional): For additional segmentation, such as sales channels, customer types, or product variants (e.g., "all" if not applicable).
  • Date (date, required): The start date of the sales period in ISO 8601 format (YYYY-MM-DD).
  • Product (string, required): The name or identifier of the product/service sold (e.g., "Health", "Life", "Pc").
  • UnitsSold (integer or float, required): The number of units sold (e.g., 292). Can be fractional for weighted or averaged data; use integers for whole counts.
  • PricePerUnit (float, required): The average price per unit in local currency (e.g., 362.97). Use a period (.) as the decimal separator.
  • ProfitPerUnit (float, optional): The average profit per unit in local currency (e.g., 120.0). Include for margin-based analysis; omit if unavailable.

Only the following characters are allowed when enter text values: 0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZåäöüøæÆÄÅÖÜߨ()_+-

Supported Formats

Data can be uploaded in long (tidy) or wide (pivoted) format. Choose based on your data pipeline:

  • Long Format (Recommended for flexibility): Each row represents a single observation (one product per date, etc.).
CountryRegionGroupingDateProductUnitsSoldPricePerUnitProfitPerUnit
SWEallall2018-01-07Health292.00362.9658120.0
SWEallall2018-01-07Life1489.001990.8113550.0
SWEallall2018-01-07Pc30212.33546.3061220.0
SWEallall2018-01-14Health275.00391.5818120.0
SWEallall2018-01-14Life1359.005241.0199550.0
SWEallall2018-01-14Pc27306.00478.0982220.0
  • Wide Format (Useful for spreadsheets): Columns represent combinations of Product and Metric (UnitsSold, PricePerUnit, etc.), with rows as dates. The first few rows define fixed attributes (e.g., Country, Region). Note: ProfitPerUnit can be added as additional columns if included.
CountrySWESWESWESWESWESWE
Regionallallallallallall
ProductHealthLifePcHealthLifePc
Groupingallallallallallall
MetricUnitsSoldUnitsSoldUnitsSoldPricePerUnitPricePerUnitPricePerUnit
2018-01-08292148930212.33333362.96575341990.811283546.3061282
2018-01-15275135927306391.58181825241.019868478.0982202
2018-01-22359143125467285.74651812303.684836417.5839321
2018-01-29411148122027306.71776164008.871708345.5292141
2018-02-05533238250881361.66791742419.802687348.0693776

Best Practices

  • Consistency: Ensure dates align with your project's periodicity (e.g., weekly sales if the project is set to weekly granularity). Mismatched granularity will cause upload errors. Use average prices for aggregated periods to reflect true economics.
  • Data Quality: Verify for outliers (e.g., negative units), missing values, or inconsistencies before upload. Include ProfitPerUnit when possible for margin-focused insights. Use the Activities dashboard to visualize and validate post-upload.
  • Granularity Alignment: All data in a project must match the chosen periodicity (set during project creation). For details, see Projects.
  • Product and Grouping: Use consistent naming for Product and Grouping to enable segmentation. If sales span multiple products, allocate appropriately or use "all".

Common Issues and Troubleshooting

  • Fractional Units: Acceptable for averaged data, but ensure they make sense for your business (e.g., partial policies); round if whole counts are required.
  • Optional Fields: Omitting ProfitPerUnit is fine, but including it enhances model depth—add it later via dataset updates if needed.

For uploading instructions, see Upload Data. If you encounter issues, contact support or refer to the API for programmatic uploads.