Models
A model is the core component provided by LS Recommend. A model can be viewed as a container for the input data, parameter settings, and the underlying mathematical model which makes up the recommendation engine.
Activate a recommendation model
Retrieve model data from Azure
All models created by LS Recommend are listed in the Models list. The Models list shows which model is in use and the status of each model. Only one model can be in use at each time in LS Recommend. A typical user of LS Recommend is expected to have one, or possibly two models, but each model can have multiple versions which are referred to as builds.
This section explains how to:
- select model parameters
- create and build a model for product recommendation
- activate a recommendation model
- delete a recommendation model
- retrieve model data from Azure.
Model parameters
When you create a new model by clicking the New action, the following parameters are set to keep track of existing models in the Models list page. Some parameters are updated automatically by LS Recommend, but you must take care to select a descriptive name for each model.
Field | Description |
---|---|
Description | Select a descriptive name for the recommendation model. |
Date Created | Indicates the date and time when a new model is created. |
Model Status | This field shows the current status of the recommendation model. The recommendation model can have the following statuses:
|
In Use | Indicates whether a model is in use or not. That is, a model that is In Use is the model that provides the recommendations. |
The remaining fields on the Model card get their values from the Model Template, which contains parameter default settings for a model and its corresponding builds. These parameters are described in subsections of Model Template and can be adjusted without overwriting the default settings, except for the fields Last Upload Data Date and Active Build No. which are set by LS Recommend.
Field | Description |
---|---|
Last Upload Data Date | Indicates the date of the newest usage data, which corresponds to the day previous to the day that the usage data is loaded to a model. After initial load of usage data, this date corresponds to the last day of the time interval that is covered by the usage data and is updated when new usage data is loaded to a model. |
Active Build No. | Represents an identification code of the build that a model uses to give recommendation. If there is no recommendation build available for a model to give recommendation, then the Active Build No. is -1. The status of active build can be viewed via the action View Active Build. |
Note: The parameter fields on the Model card can be adjusted after a model has been created and built with default settings. The parameter fields grouped in the Recommendation section take effect immediately, but in the case of updating Filter With Regard to Stock the server must be restarted for the change to take effect. The parameter fields grouped in the Data section only take effect following the action Step 2: Load Model Data (click Actions - Model Procedure).
Create a recommendation model
Creating and building a recommendation model is carried out in three steps:
This procedure is assumed to be carried out manually when LS Recommend is set up for the first time. To see how this procedure can be automated, go to Scheduler Jobs.
For convenience, this procedure can be carried out by a single click, but the three steps can also be carried out step-by-step.
Create and build a model with a single click
- Click the
icon, enter Models, and select the relevant link.
- Click the New action to open the Model card.
- Enter a name for the new model, and click Active - Create & Build Model with Data to create and build a recommendation model.
This action automatically carries out the three steps in consecutive order. A status bar appears showing which step is being executed at each time. This process may take a few moments depending on the amount of data in the model.
Once a model is created in Azure and the building procedure is completed, the next step is to enable the new model for recommendation. See how to activate a model here.
Create and build a model in three steps
As an alternative to Create & Build Model with Data, you can click Actions - Model Procedure to execute the three steps manually step-by-step.
The three steps are carried out by clicking these actions under Model Procedure:
- Step 1: Create Model. Creates a model container with current settings in the Microsoft Azure cloud.
- Step 2: Load Model Data. Uploads a catalog and usage data into the model container.
- Step 3: Default Build. Builds a recommendation model, with the current setting and the uploaded data.
A status bar appears indicating the status of every step. Once a model is created in Azure and the data is successfully uploaded, LS Recommend needs to build the recommendation model. Building the model might take a few moments, depending on the model size.
Once a model is created in Azure and the building procedure is completed, the next step is to activate the new model for recommendation, see details below in Activate a recommendation model.
Load model data step-by-step
The remaining actions on the Actions menu let you observe the model data after executing Step 1: Create Model.
- Load Catalog. Loads a catalog to the model container in Azure.
- Load Usage History. Loads usage history into the model container in Azure. Note: Before using this action, you must run Load Catalog.
- Catalog. View the catalog of items that is uploaded into the Azure cloud.
- Usage Files. View the usage files that are uploaded into the Azure cloud.
Activate a recommendation model
After creating and building a model following the procedure described above, the build status must be completed before you can activate the model.
- Click the
icon, enter Models, and select the relevant link.
- Click the Builds action.
- Click Get All builds. When the Build Status is Completed, the build is active.
Once a model has an active build, the Model Status is Ready for Recommendation and the model can be activated to give recommendation on POS or in Commerce. That means that only one model, and one corresponding model build, is allowed to make recommendations at a time.
- Go to the Models list, select the model intended to be used to give recommendations from the model list, and click Active - Enable. The flag In Use is set to true.
A model can be deactivated by clicking Disable.
Delete a recommendation model
- Go to the Models list, and click Delete to delete a recommendation model.
Retrieve model data from Azure
The Azure Data - Get All Models on the Models page retrieves model data from Azure. The action does not update user settings on display or usage data.