Practice
1. For a learning to rank system, which metric is most appropriate to evaluate the quality of the ranking?
easy
Solution
Step 1: Identify the metric that evaluates ranking quality.
NDCG is specifically designed to evaluate the quality of rankings.Step 2: Eliminate wrong options.
MSE is for regression, precision and recall are for classification, not ranking.Final Answer:
Option A -> Option AQuick Check:
NDCG = ranking quality [OK]
Hint: NDCG = ranking quality [OK]
Common Mistakes:
2. In the context of intent classification, which of the following techniques is most suitable for handling imbalanced datasets?
easy
Solution
Step 1: Identify the challenge of imbalanced datasets.
Imbalanced datasets can lead to biased models that favor the majority class.Step 2: Evaluate each option.
Use a simple logistic regression model: Logistic regression without addressing imbalance will likely be biased. Use a linear SVM without any modifications: Linear SVM also suffers from imbalance without adjustments. Ignore the imbalance and focus on feature engineering: Ignoring imbalance is not a solution. Apply SMOTE (Synthetic Minority Over-sampling Technique): SMOTE is specifically designed to handle imbalance by generating synthetic samples.Final Answer:
Option A -> Option AQuick Check:
SMOTE for imbalance handling. [OK]
Hint: SMOTE is key for imbalanced datasets. [OK]
Common Mistakes:
3. A delivery forecasting model is consistently overestimating ETAs during peak traffic hours. What is the most likely failure mode?
medium
Solution
Step 1: Identify the cause of overestimation during peak hours
Real-time traffic data is crucial for accurate ETA predictions.Step 2: Eliminate wrong options
Underfitting (A) and overfitting (D) are general issues, not specific to peak hours. Too many parameters (C) would cause overfitting, not specific time errors.Final Answer:
Option A -> Option AQuick Check:
Real-time data is key for peak accuracy. [OK]
Hint: Real-time data is key for peak accuracy. [OK]
Common Mistakes:
4. When implementing a Guardrails System for LLMs, should you prioritize precision over recall, and why?
medium
Solution
Step 1: Understand the trade-off
Prioritizing precision minimizes false positives, crucial for user experience.Step 2: Eliminate wrong options
Recall is important but can lead to over-blocking, efficiency isn't the main concern, and equal importance isn't practical in all cases.Final Answer:
Option C -> Option CQuick Check:
Prioritize precision to avoid blocking legitimate content. [OK]
Hint: Prioritize precision to avoid blocking legitimate content. [OK]
Common Mistakes:
5. As the number of queries increases tenfold, which component of a search ranking system is most likely to become a bottleneck first?
hard
Solution
Step 1: Consider the impact of scaling queries
Ranking computation is resource-intensive and scales with query volume.Step 2: Evaluate other components
Query parsing and document retrieval are less computationally intensive, and index updating is not query-dependent.Final Answer:
Option A -> Option AQuick Check:
Ranking computation scales with query volume. [OK]
Hint: Ranking computation scales with query volume. [OK]
Common Mistakes:
