Training BERT for basic recommendation

Hi, I’m new to using BERT and I could use some guidance on training the bert-base-uncased model for building a basic recommender system. Here’s a detailed description of what I’m trying to achieve:

I have a dataset with movie histories for each user, where each movie is labeled as either 0 (not liked) or 1 (liked). This data is stored in a Pandas DataFrame named train_df, which has columns: {"user_id", "movie_title", "label", "timestamp"}.

For training, I’ve split the data into train and test sets as follows: for each positively labeled movie in the training set, I’ve included two negatively labeled movies. In the test set, I’ve chosen the most recent positively labeled movie for each user.

My goal is to train the BERT model to create sentence embeddings. Given a movie history with liked movies, the model should create a sentence embedding vector. Then, when I input a movie title string that is similar to the movie history, the model should output a high similarity score.

I’d appreciate any guidance on how to approach this training process with bert-base-uncased. Thanks in advance for your help!