I have a similar problem to this question, where I'd like to sort items, although adjust for the number of reviews. Following the link in the accepted answer leads me to this answer, which proposes an easy solution of adding a few average values to the mean and sorting on this "adjusted mean". However, it also proposes a more rigorous approach of "adding reviews with an average of to each product and tune , using cross validation to maximize some measurement of prediction accuracy. I would start with as the average rating in your whole data set, and play with values of ."
I'm having trouble understanding how to implement this rigorous approach in code. Any pointers would be helpful.