def runGetUserData(userId): return turi().getUserRatingData(userId=userId)
def runSaveUserData(userData): turi().saveUserRatingData(userData=userData) return 'finish'
def runByUser(userId, topItems): movies = turi().recommendByUser(userId=userId, topN=topItems) return movies
def runPopular(userId, topItems): movies = turi().getPopularForUser(userId=userId, topN=topItems) return movies
def runByItems(itemId, topItems): movies = turi().recommendByItems(itemId=itemId, topN=topItems) return movies