Recommend item from set based on features

Forgive what might be a basic question. I'm just experimenting with ML / AL and I have a small problem set and I'd like to see if it can be solved with ML / AI. Basically, given a set of objects with multiple features, I'd like to create a process for recommending one automatically to a user.

I'm thinking that some sort of clustering algorithm may be the best approach. However, one main challenge I'm trying to wrap my head around is that I don't know in advance how many distinct clusters will evolve... There may be scenarios where we Feature X is really important, but other scenarios where a user will say Feature Y is important.

Secondly, what is my input set? For each training sample, I will have 1 selected object, and N-1 unselected objects. But I don't want to "train" that the unselected objects are "bad" because they could be selected in a future training example.

Finally, I don't have a large training set already, so I would like to use feedback (user input, "This was a bad choice" or "Use this object instead.") from the process to further refine the algorithm. Is this feasible?

Are there any established patterns for this sort of process? Thanks in advance.

This problem is usually approached with "Singular Value Decomposition".

Search also for the "Netflix Challenge".

• Could you expand on SVD and describe on a high level how it is used? This is so that the answers on the stack can be self-contained. – Jaden Travnik Jan 22 '18 at 18:14

One approach for this is collaborative filtering.

This does however need you to have data about some user preferences on some products. Given that you have stated you are willing to mine user preferences this approach may be feasible.

The idea is that with this data you can train a model to predict how a user might rate a product. This is accomplished by learning the "preference signature" of a user and a feature vector for each product.

General Idea

for your i-th user, the algorithm will learn said preferences as a vector $$\theta^{(i)}$$

Additionally, for your j-th product it will learn a feature vector $$x^{(j)}$$

You can then predict how the i-th user will rate the j-th item by computing the dot product (or some equivalent). That is, compute the predicted rating as: $$\hat R(i,j)=\theta^{(i)}\cdot x^{(j)}$$

You can then use this rating to decide whether or not a a product is a good match for a user.

The A. Ng Machine Learning Coursera MOOC has a very nice module on collaborative filtering.

Implementation Note

When asking your users for feedback, try to ask for quantitative measures. For example, the classic 1-5 scale rating.

• Please put some information on your answer instead of a single link. Maybe, you can give some reasons why OP should use Collaborative filtering. – malioboro Sep 1 '19 at 5:56
• @malioboro I am currently writing an in depth answer with full mathematical formalism. I hastily submitted this as a temporary post - perhaps an oversight. – respectful Sep 1 '19 at 6:02
• I see, it is good answer now! – malioboro Sep 2 '19 at 2:38
• @malioboro thanks! I'm having fun writing answers. I don't believe in "shady" answers. I'll just have to make sure I finish them from now on before I post. – respectful Sep 2 '19 at 2:40