nerdexam
Amazon

MLS-C01 · Question #140

A data scientist must build a custom recommendation model in Amazon SageMaker for an online retail company. Due to the nature of the company's products, customers buy only 4-5 products every 5-10…

The correct answer is B. Identify the most recent 10% of interactions for each user. This use case involves sparse user interaction history (only 4-5 purchases over 5-10 years) and a heavy reliance on new customers. For recommendation systems, a time-based split is critical to simulate real-world deployment: the model must be trained on past interactions and…

Modeling

Question

A data scientist must build a custom recommendation model in Amazon SageMaker for an online retail company. Due to the nature of the company's products, customers buy only 4-5 products every 5-10 years. So, the company relies on a steady stream of new customers. When a new customer signs up, the company collects data on the customer's preferences. Below is a sample of the data available to the data scientist. How should the data scientist split the dataset into a training and test set for this use case?

Exhibit

MLS-C01 question #140 exhibit

Options

  • AShuffle all interaction data.
  • BIdentify the most recent 10% of interactions for each user.
  • CIdentify the 10% of users with the least interaction data.
  • DRandomly select 10% of the users.

How the community answered

(34 responses)
  • A
    6% (2)
  • B
    74% (25)
  • C
    6% (2)
  • D
    15% (5)

Explanation

This use case involves sparse user interaction history (only 4-5 purchases over 5-10 years) and a heavy reliance on new customers. For recommendation systems, a time-based split is critical to simulate real-world deployment: the model must be trained on past interactions and evaluated on future ones, preventing data leakage. Using the most recent 10% of interactions per user (option B) correctly mirrors this temporal ordering - the model sees historical behavior during training and is tested on how well it predicts what comes next. Option A (shuffling all data) destroys temporal order and causes data leakage. Option C (using users with least interaction data) evaluates cold-start performance only, not the general model. Option D (randomly selecting 10% of users) creates a user-split rather than an interaction-split and does not reflect the temporal nature of purchasing behavior.

Topics

#Data Splitting#Recommendation Systems#Training and Testing#Dataset Preparation

Community Discussion

No community discussion yet for this question.

Full MLS-C01 Practice