Technical User Reference (Optimization - Shelf Price)

This section details the Model Class and the logics that the Optimization - Shelf Price Accelerator deploys. For each step, its aim, its outputs, and the main reasons to modify the logics are explained. If there is a need to modify the logics, refer to the process in Optimization Accelerator Customization and to documentation in , , and .

In this section:

Shelf Price Model Class

The Shelf Price Model Class organizes a list of logics to create the model architecture. It is transformed into an UI in the Pricefx platform that is organized in 4 steps:

  1. Definition − Maps the sources of data and filters out invalid values.

  2. Scope − Sets the scope of the optimization.

  3. Configuration − Sets the parameters of the optimization.

  4. Results − Looks at the outputs of the optimization.

There are two types of logics: calculation, which writes tables in the model, and evaluation, whose purpose is only to display some results. The standard Model Class definition is documented in .

All the logics of the Optimization - Shelf Price Accelerator follow a standard naming convention: first “SP_” prefix, then the first letters of the step name, then “Calc” or “Eval”, depending on the formula nature, then the name of the tab. In the end, there is a library logic named SP_Lib.

Library

The logic is SP_Lib.

This logic contains some functions needed specifically for this Accelerator, such as reading its configuration from the application settings, applying the user filters in each part of the model, providing the problem description for the OE, preprocessing the data for the charts, and many small helpers for the charts rendering.

  • The elements ParametersUtils, LabelsUtils, and TablesUtils contain the names of many elements and fields of the models.

  • The elements DefinitionUtils, ScopeUtils, ConfigurationUtils, and ResultUtils contain functions specific to the corresponding step.

  • The ProblemDescriptionDefinition element returns the problem description in a map. The content of the problem description is detailed in . The specific Shelf Price Optimization problem is described as a chart in the logics repository of the accelerator. The element ProblemDescriptionUtils contains the names and field definitions for the problem description field.

This lib is the place where to change the names inside the model, to reflect the user business vocabulary. Here you can also write a function to be used in different places of the model class.

Any modification of the problem modeling and type of constraints to apply or objectives to reach implies a modification of the Problem Description, thus ProblemDescriptionDefinition.groovy should change accordingly.

If the problem description changes, do not forget to check if it is necessary to change or create some Problem tables.

Definition Step

There is no calculation logic run in this step. The tabs are Sales, Stock, and Competition, and their related logics are SP_Def_Eval_Sales, SP_Def_Eval_Sales_Configurator, SP_Def_Eval_Stock, SP_Def_Eval_Stock_Configurator, SP_Def_Eval_Competition and SP_Def_Eval_Competition_Configurator.

Sales Tab

The logics are SP_Def_Eval_Sales and SP_Def_Eval_Sales_Configurator.

These logics define the Data Source and the mapping of the entries for the transactions, in the configurator. The main logic calls the configurator and the code for the dashboard portlets.

Two portlets show the data that will be materialized in the model (table sales) and the filtered-out rows.

The mapping could be changed if a field is removed or added.

Stock Tab

The logics are SP_Def_Eval_Stock and SP_Def_Eval_Stock_Configurator.

Competition Tab

The logics are SP_Def_Eval_Competition and SP_Def_Eval_Competition_Configurator.

Scope Step

The calculation logic is SP_Sco_Calc_Dataprep and there is one tab called Scope.

Calculation: Data Preparation

The logic is SP_Sco_Calc_Dataprep.

Scope Tab

The logics are SP_Sco_Eval_Scope and SP_Sco_Eval_Scope_Configurator.

Configuration Step

The calculation logic is SP_Conf_Calc_Aggregation and there are five tabs: General, Price, Competition, Stock, and Channels.

Aggregation Calculation

The name of the logic is SP_Conf_Calc_Aggregation.

Configuration Tabs Logics

The logics are SP_Conf_Eval_General_Configurator, SP_Conf_Eval_Boundaries_Configurator, SP_Conf_Eval_Competition_Configurator, SP_Conf_Eval_StockCoverage_Configurator, SP_Conf_Eval_Channels_Configurator.

Results Step

The calculation logics are SP_Res_Calc_Run_Initialization, SP_Res_Calc_Run_Optimization, and SP_Res_Cal_PrepareResults. There are four tabs: Impact, Details, Glassbox, and Evaluation.

Calculation: Run Initialization

The logic is SP_Res_Calc_Run_Initialization.

Calculation: Run Optimization

The logic is SP_Res_Calc_Run_Optimization.

Calculation: Prepare Results

The logic is SP_Res_Calc_PrepareResults.

Impact Tab

The logic is SP_Res_Eval_Impact.

Details Tab

The logic is SP_Res_Eval_Details.

Glassbox and Drivers Tabs

The logics are SP_Res_Eval_Glassbox and SP_Res_Eval_Drivers.

Evaluation Tab

The logic is SP_Res_Eval_Evaluation.