ਜਨਰੇਟਿਵ ਡਾਟਾ ਇੰਟੈਲੀਜੈਂਸ

ਐਮਾਜ਼ਾਨ ਪਰਸਨਲਾਈਜ਼ ਵਿੱਚ ਹੱਲਾਂ ਲਈ ਆਟੋਮੈਟਿਕ ਸਿਖਲਾਈ ਪੇਸ਼ ਕਰ ਰਿਹਾ ਹੈ | ਐਮਾਜ਼ਾਨ ਵੈੱਬ ਸੇਵਾਵਾਂ

ਤਾਰੀਖ:

ਐਮਾਜ਼ਾਨ ਨਿਜੀ ਬਣਾ is excited to announce automatic training for solutions. Solution training is fundamental to maintain the effectiveness of a model and make sure recommendations align with users’ evolving behaviors and preferences. As data patterns and trends change over time, retraining the solution with the latest relevant data enables the model to learn and adapt, enhancing its predictive accuracy. Automatic training generates a new solution version, mitigating model drift and keeping recommendations relevant and tailored to end-users’ current behaviors while including the newest items. Ultimately, automatic 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 effortless to integrate personalized recommendations into existing websites, applications, email marketing systems, and more. Amazon Personalize enables developers to quickly implement a customized personalization engine, without requiring ML expertise. Amazon Personalize provisions the necessary infrastructure and manages the entire ML pipeline, including processing the data, identifying features, using the appropriate algorithms, and training, optimizing, and hosting the customized models based on your data. All your data is encrypted to be private and secure.

In this post, we guide you through the process of configuring automatic training, so your solutions and recommendations maintain their accuracy and relevance.

ਹੱਲ ਸੰਖੇਪ ਜਾਣਕਾਰੀ

A ਦਾ ਹੱਲ refers to the combination of an Amazon Personalize recipe, customized parameters, and one or more solution versions (trained models). When you create a custom solution, you specify a recipe matching your use case and configure training parameters. For this post, you configure automatic training in the training parameters.

ਪੂਰਿ-ਲੋੜਾਂ

To enable automatic training for your solutions, you first need to set up Amazon Personalize resources. Start by ਇੱਕ ਡੇਟਾਸੈਟ ਸਮੂਹ ਬਣਾਉਣਾ, ਸਕੀਮਾ, ਅਤੇ ਡੇਟਾਸੇਟ representing your items, interactions, and user data. For instructions, refer to Getting Started (console) or Getting Started (AWS CLI).

After you finish importing your data, you are ready to create a solution.

Create a solution

To set up automatic training, complete the following steps:

  1. On the Amazon Personalize console, create a new solution.
  2. Specify a name for your solution, choose the type of solution you want to create, and choose your recipe.
  3. Optionally, add any tags. For more information about tagging Amazon Personalize resources, see Tagging Amazon Personalize resources.
  4. To use automatic training, in the Automatic training ਸੈਕਸ਼ਨ, ਚੁਣੋ ਚਾਲੂ ਕਰੋ and specify your training frequency.

Automatic training is enabled by default to train one time every 7 days. You can configure the training cadence to suit your business needs, ranging from one time every 1–30 days.

  1. If your recipe generates item recommendations or user segments, optionally use the Columns for training section to choose the columns Amazon Personalize considers when training solution versions.
  2. ਵਿੱਚ Hyperparameter configuration ਅਨੁਭਾਗ, optionally configure any hyperparameter options based on your recipe and business needs.
  3. Provide any additional configurations, then choose ਅਗਲਾ.
  4. Review the solution details and confirm that your automatic training is configured as expected.
  5. ਚੁਣੋ ਹੱਲ ਬਣਾਓ.

Amazon Personalize will automatically create your first solution version. A ਹੱਲ ਵਰਜਨ refers to a trained ML model. When a solution version is created for the solution, Amazon Personalize trains the model backing the solution version based on the recipe and training configuration. It can take up to 1 hour for the solution version creation to start.

The following is sample code for creating a solution with automatic training using the AWS SDK:

import boto3 
personalize = boto3.client('personalize')

solution_config = {
    "autoTrainingConfig": {
        "schedulingExpression": "rate(3 days)"
    }
}

recipe = "arn:aws:personalize:::recipe/aws-similar-items"
name = "test_automatic_training"
response = personalize.create_solution(name=name, recipeArn=recipe_arn, datasetGroupArn=dataset_group_arn, 
                            performAutoTraining=True, solutionConfig=solution_config)

print(response['solutionArn'])
solution_arn = response['solutionArn'])

After 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 via the AWS SDK that automatic training is enabled:

response = personalize.describe_solution(solutionArn=solution_arn)
print(response)

Your response will contain the fields performAutoTraining ਅਤੇ autoTrainingConfig, displaying the values you set in the CreateSolution ਕਾਲ ਕਰੋ

On the solution details page, you will also see the solution versions that are created automatically. 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 solution versions for the given solution:

response = personalize.list_solution_versions(solutionArn=solution_arn)['solutionVersions']
print("List Solution Version responsen")
for val in response:
    print(f"SolutionVersion: {val}")
    print("n")

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 ਇੱਕ ਮੁਹਿੰਮ ਬਣਾਓ for your solution version.

ਇੱਕ ਮੁਹਿੰਮ ਬਣਾਓ

A ਮੁਹਿੰਮ ਦੀ deploys a solution version (trained model) to generate real-time recommendations. With Amazon Personalize, you can streamline your workflow and automate the deployment of the latest solution version to campaigns via automatic syncing. To set up auto sync, complete the following steps:

  1. On the Amazon Personalize console, create a new campaign.
  2. Specify a name for your campaign.
  3. Choose the solution you just created.
  4. ਦੀ ਚੋਣ ਕਰੋ Automatically use the latest solution version.
  5. ਸੈੱਟ ਕਰੋ minimum provisioned transactions per second.
  6. Create your campaign.

The campaign is ready when its status is ACTIVE.

The following is sample code for creating a campaign with syncWithLatestSolutionVersion ਕਰਨ ਲਈ ਸੈੱਟ ਕੀਤਾ true using the AWS SDK. You must also append the suffix $LATEST ਨੂੰ solutionArn in solutionVersionArn when you set syncWithLatestSolutionVersion ਨੂੰ true.

campaign_config = {
    "syncWithLatestSolutionVersion": True
}
resource_name = "test_campaign_sync"
solution_version_arn = "arn:aws:personalize:<region>:<accountId>:solution/<solution_name>/$LATEST"
response = personalize.create_campaign(name=resource_name, solutionVersionArn=solution_version_arn, campaignConfig=campaign_config)
campaign_arn = response['campaignArn']
print(campaign_arn)

On the campaign details page, you can see whether the campaign selected has auto sync enabled. When enabled, your campaign will automatically update to use the most recent solution version, whether it was automatically or manually created.

Use the following sample code to confirm via the AWS SDK that syncWithLatestSolutionVersion ਯੋਗ ਕੀਤਾ ਗਿਆ ਹੈ:

response = personalize.describe_campaign(campaignArn=campaign_arn)
Print(response)

Your response will contain the field syncWithLatestSolutionVersion ਅਧੀਨ campaignConfig, displaying the value you set in the CreateCampaign ਕਾਲ ਕਰੋ

You can enable or disable the option to automatically use the latest solution version on the Amazon Personalize console after a campaign is created by updating your campaign. Similarly, you can enable or disable syncWithLatestSolutionVersion ਨਾਲ UpdateCampaign using the AWS SDK.

ਸਿੱਟਾ

With automatic training, you can mitigate model drift and maintain recommendation relevance by streamlining your workflow and automating the deployment of the latest solution version in Amazon Personalize.

For more information about optimizing your user experience with Amazon Personalize, see the ਐਮਾਜ਼ਾਨ ਪਰਸਨਲਾਈਜ਼ ਡਿਵੈਲਪਰ ਗਾਈਡ.


ਲੇਖਕਾਂ ਬਾਰੇ

ਬਾ'ਕੈਰੀ ਜੌਨਸਨ Amazon Personalize ਟੀਮ 'ਤੇ AWS AI/ML ਨਾਲ ਕੰਮ ਕਰਨ ਵਾਲਾ ਇੱਕ ਸੀਨੀਅਰ ਤਕਨੀਕੀ ਉਤਪਾਦ ਪ੍ਰਬੰਧਕ ਹੈ। ਕੰਪਿਊਟਰ ਵਿਗਿਆਨ ਅਤੇ ਰਣਨੀਤੀ ਵਿੱਚ ਇੱਕ ਪਿਛੋਕੜ ਦੇ ਨਾਲ, ਉਹ ਉਤਪਾਦ ਨਵੀਨਤਾ ਬਾਰੇ ਭਾਵੁਕ ਹੈ। ਆਪਣੇ ਖਾਲੀ ਸਮੇਂ ਵਿੱਚ, ਉਹ ਸਫ਼ਰ ਕਰਨ ਅਤੇ ਸ਼ਾਨਦਾਰ ਬਾਹਰੀ ਥਾਵਾਂ ਦੀ ਪੜਚੋਲ ਕਰਨ ਦਾ ਅਨੰਦ ਲੈਂਦੀ ਹੈ।

Ajay Venkatakrishnan is a Software Development Engineer on the Amazon Personalize team. In his spare time, he enjoys writing and playing soccer.

Pranesh Anubhav is a Senior Software Engineer for Amazon Personalize. He is passionate about designing machine learning systems to serve customers at scale. Outside of his work, he loves playing soccer and is an avid follower of Real Madrid.

ਸਪਾਟ_ਮਿਗ

ਨਵੀਨਤਮ ਖੁਫੀਆ ਜਾਣਕਾਰੀ

ਸਪਾਟ_ਮਿਗ

ਸਾਡੇ ਨਾਲ ਚੈਟ ਕਰੋ

ਸਤ ਸ੍ਰੀ ਅਕਾਲ! ਮੈਂ ਕਿਵੇਂ ਮਦਦ ਕਰ ਸਕਦਾ ਹਾਂ?