Practice
1. You are dealing with a dataset where both covariate and concept drift are suspected. Which approach is more suitable for handling this scenario?
medium
Solution
Step 1: Identify the best approach for handling drift.
Periodic model retraining helps adapt to both covariate and concept drift.Step 2: Eliminate wrong options.
Static models (Use a static model trained on historical data.) and single validation sets (Use a single validation set for model evaluation.) don't adapt to drift. Feature scaling (Rely on feature scaling to handle the drift.) doesn't address drift.Final Answer:
Option B -> Option BQuick Check:
Retrain models to adapt to drift [OK]
Hint: Retrain models to adapt to drift [OK]
Common Mistakes:
2. When choosing between polynomial features and interaction terms for a linear model, which is more appropriate when the dataset is small and why?
medium
Solution
Step 1: Consider dataset size and model complexity.
Small datasets are prone to overfitting with complex models.Step 2: Evaluate the impact of each option.
Polynomial features (A, C) increase complexity significantly, leading to overfitting. Interaction terms (B, D) add complexity but less than polynomial features, making them more suitable for small datasets.Final Answer:
Option D -> Option DQuick Check:
Small data: prefer interaction terms to avoid overfitting. [OK]
Hint: Small data: prefer interaction terms to avoid overfitting. [OK]
Common Mistakes:
3. A search engine's NDCG score is unexpectedly low. What is a likely cause?
medium
Solution
Step 1: Identify NDCG sensitivity
NDCG is sensitive to the position of relevant results; irrelevant results at the top lower the score.Step 2: Eliminate wrong options
Normalization affects comparability, not score; incorrect ideal DCG or log base would affect all results, not just NDCG.Final Answer:
Option D -> Option DQuick Check:
Top irrelevant results lower NDCG. [OK]
Hint: Top irrelevant results lower NDCG. [OK]
Common Mistakes:
4. In a fraud detection system, you need to balance precision and recall. Which metric would you choose and why?
hard
Solution
Step 1: Understand the need for balance.
Fraud detection requires a balance between catching frauds and minimizing false alarms.Step 2: Choose the metric that balances precision and recall.
F1 Score is the harmonic mean of precision and recall, providing a balance.Final Answer:
Option A -> Option AQuick Check:
F1 Score balances precision and recall. [OK]
Hint: F1 Score balances precision and recall. [OK]
Common Mistakes:
5. You are tasked with designing a system to handle label drift in a real-time recommendation engine. Which approach would be most effective?
hard
Solution
Step 1: Identify the best approach for handling label drift.
A feedback loop allows the model to adapt to changes in label distribution by learning from recent interactions.Step 2: Eliminate wrong options.
Static mappings (Use a static label mapping based on historical data.) and increasing dataset size (Increase the size of the training dataset.) don't adapt to real-time changes. Feature selection (Apply feature selection to reduce dimensionality.) doesn't address label drift.Final Answer:
Option A -> Option AQuick Check:
Feedback loop adapts to label drift [OK]
Hint: Feedback loop adapts to label drift [OK]
Common Mistakes:
