← 返回 instacart 的题目列表Instacart Search Ranking System Design and Scalability
类型:online_judge
instacart
Design an Instacart search ranking system. The system should consider user search queries and return the best product ranking based on various factors. Please describe the system architecture, the algorithms or models used, and consider the scalability and flexibility of the system.
Example
Input
{ 'user_profile': {'preferences': ['organic', 'gluten-free']}, 'search_query': 'cereal', 'product_list': [{'id': 1, 'name': 'Organic Oats', 'tags': ['organic', 'fiber']}, {'id': 2, 'name': 'Whole Wheat Cereal', 'tags': ['fiber', 'wheat']}, {'id': 3, 'name': 'Gluten-Free Cereal', 'tags': ['gluten-free']}]}
Output
3, 1, 2