amazon Personalize is excited to announce automated training for solutions. Solutions training is critical to maintaining the effectiveness of a model and ensuring that recommendations align with changing user behaviors and preferences. As data patterns and trends change over time, retraining the solution with the most recent relevant data allows the model to learn and adapt, improving its predictive accuracy. Automated training generates a new version of the solution, mitigating model drift and keeping recommendations relevant and tailored to current end-user behaviors while including the newest elements. Ultimately, automated training provides a more personalized and engaging experience that adapts to changing preferences.
amazon Personalize accelerates your digital transformation with machine learning (ML), making it easy to integrate personalized recommendations into existing websites, apps, email marketing systems, and more. amazon Personalize allows developers to quickly deploy a custom personalization engine, without requiring machine learning experience. amazon Personalize provides the necessary infrastructure and manages the entire machine learning process, including processing data, identifying features, using appropriate algorithms, and training, optimizing, and hosting custom models based on your data. All your data is encrypted to keep it private and secure.
In this post, we guide you through the process of setting up automated training, so your solutions and recommendations remain accurate and relevant.
Solution Overview
TO solution refers to the combination of an amazon Personalize recipe, custom parameters, and one or more solution versions (trained models). When you create a custom solution, you specify a recipe that matches your use case and configure training parameters. For this post, set up automatic training in the training parameters.
Previous requirements
To enable automatic training for your solutions, you must first configure amazon Personalize resources. Start by creating a group of data sets, schemas, and data sets that represent your items, interactions, and user data. For instructions, see Getting started (console) or Getting started (AWS CLI).
Once you finish importing your data, you are ready to create a solution.
Create a solution
To set up automatic training, complete the following steps:
- In the amazon Personalize console, create a new solution.
- Specify a name for your solution, choose the type of solution you want to create, and choose your recipe.
- Optionally add any tags. For more information about tagging amazon Personalize resources, see Tagging amazon Personalize Resources.
- To use automatic training, in the Automatic training section, select Light and specify your training frequency.
Auto training is enabled by default to train once every 7 days. You can set the training cadence to suit your business needs, from once every 1 to 30 days.
- If your recipe generates recommendations from items or user segments, optionally use the Columns for training section to choose the columns that amazon Personalize considers when training solution versions.
- In it Hyperparameter settings sectionOptionally configure any hyperparameter options based on your recipe and business needs.
- Provide any additional settings, then choose Next.
- Review the solution details and confirm that your automatic training is configured as expected.
- Choose Create solution.
amazon Personalize will automatically create your first version of the solution. TO solution version refers to a trained ML model. When you create a solution version, amazon Personalize trains the model that supports the solution version based on the training recipe and configuration. The solution build may take up to 1 hour to begin.
The following is sample code to create a self-trained solution using the AWS SDK:
Once a solution is created, you can confirm whether automatic training is enabled on the solution details page.
You can also use the following sample code to confirm using the AWS SDK that automatic training is enabled:
Your response will contain the fields performAutoTraining
and autoTrainingConfig
displaying the values you set in the CreateSolution
call.
On the solution details page, you will also see the solution versions that are created automatically. He Training Type The column specifies whether the solution version was created manually or automatically.
You can also use the following sample code to return a list of versions of the given solution:
Your response will contain the field trainingType
which specifies whether the solution version was created manually or automatically.
When your solution version is ready, you can create a campaign for your solution version.
Create a campaign
TO Campaign deploys a version of the solution (trained model) to generate recommendations in real time. With amazon Personalize, you can streamline your workflow and automate the deployment of the latest version of the solution to campaigns through automatic synchronization. To set up automatic sync, complete the following steps:
- In the amazon Personalize console, create a new campaign.
- Specify a name for your campaign.
- Choose the solution you just created.
- Select Automatically use the latest version of the solution.
- Set the minimum transactions provisioned per second.
- Create your campaign.
The campaign will be ready when its status is ACTIVE
.
The following is sample code to create a campaign with syncWithLatestSolutionVersion
adjusted to true
using the AWS SDK. You must also add the suffix $LATEST
toward solutionArn
in solutionVersionArn
when you set syncWithLatestSolutionVersion
to true
.
On the campaign details page, you can see if the selected campaign has automatic sync enabled. When enabled, your campaign will automatically update to use the latest version of the solution, whether it was created automatically or manually.
Use the following sample code to confirm through the AWS SDK that syncWithLatestSolutionVersion
is enabled:
Your response will contain the field syncWithLatestSolutionVersion
low campaignConfig
displaying the value you set in the CreateCampaign
call.
You can enable or disable the option to automatically use the latest version of the solution in the amazon Personalize console after you create a campaign by updating your campaign. Similarly, you can enable or disable syncWithLatestSolutionVersion
with UpdateCampaign
using the AWS SDK.
Conclusion
With automated training, you can mitigate model drift and keep recommendations relevant by streamlining your workflow and automating the deployment of the latest version of your solution to amazon Personalize.
To learn more about optimizing your user experience with amazon Personalize, see the amazon Personalize Developer Guide.
About the authors
Not Carrie Johnson is a Senior Technical Product Manager working with AWS ai/ML on the amazon Personalize team. With a background in IT and strategy, he is passionate about product innovation. In his spare time, he enjoys traveling and exploring the outdoors.
Ajay Venkatakrishnan is a software development engineer on the amazon Personalize team. In his free time he likes to write and play soccer.
Pranesh Anubhav is a Senior Software Engineer at amazon Personalize. He is passionate about designing machine learning systems to serve customers at scale. Outside of his job, he loves to play soccer and is an avid supporter of Real Madrid.