Click4Ai

551.

Hard

Design an A/B testing infrastructure that can manage multiple experiments and provide efficient access to experiment results. **Example:** Consider a scenario where you have three experiments: a linear regression experiment, a decision tree experiment, and a random forest experiment. You want to store experiment metadata such as experiment name, experiment type, and experiment results in your A/B testing infrastructure. **Constraints:** The A/B testing infrastructure should be able to handle thousands of experiments and provide results in a format suitable for model deployment.

Test Cases

Test Case 1
Input: [{"name": "linear_regression", "type": "linear_regression", "data": "customer_database"}, {"name": "decision_tree", "type": "decision_tree", "data": "transaction_log"}, {"name": "random_forest", "type": "random_forest", "data": "customer_database"}]
Expected: {"linear_regression": {'experiment_type': 'linear_regression', 'results': 'customer_database'}, 'decision_tree': {'experiment_type': 'decision_tree', 'results': 'transaction_log'}, 'random_forest': {'experiment_type': 'random_forest', 'results': 'customer_database'}}
Test Case 2
Input: [{"name": "linear_regression", "type": "linear_regression", "data": "customer_database"}, {"name": "decision_tree", "type": "decision_tree", "data": "transaction_log"}, {"name": "random_forest", "type": "random_forest", "data": "customer_database"}]
Expected: {"linear_regression": {'experiment_type': 'linear_regression', 'results': 'customer_database'}, 'decision_tree': {'experiment_type': 'decision_tree', 'results': 'transaction_log'}, 'random_forest': {'experiment_type': 'random_forest', 'results': 'customer_database'}}
+ 3 hidden test cases