I have a dataset with 3 columns "item_id", "user_id", "rating". I created a coreML MLRecommender model from this dataset.
I want to use this model to get the top 10 predictions for a new user (not in the original dataset) but who has rated a subset of the items in the dataset.
I don't see any API in the Apple docs to do this. Both the recommendations APIs only accept an existing user-id and get recommendations for that user. This seems like a strange API design and hopefully I am missing something.
The WWDC tutorial talks about a prediction API to achieve this. But I dont see this in the Apple API documentation and code below from WWDC tutorial will not work since it does not give details on how to create the HikingRouteRecommenderInput class it passes into the prediction API)
let hikes : [String : Double] = ["Granite Peak" : 5, "Wildflower Meadows" : 4] let input = HikingRouteRecommenderInput(items: hikes, k: 5) // Get results as sequence of recommended items let results = try model.prediction(input: input)
Any pointers on how to get predictions for new user would be greatly appreciated
I don't see a prediction API listed in Apple documentation. Hence, I am not sure on how to proceed.