DEV Community

particular
particular

Posted on

How to create an Embedding Model for Recipe Dataset Using Deep Metric Learning

Hello everyone! I want to create an embedding model for my own dataset of recipes. The goal is to create a neural network that takes each recipe, represented by a list of its ingredients, a list of recipe tags, and its title, as input.
The network should use deep metric learning to create an embedding model that represents recipes in a way that distinguishes them well. I have considered using a triplet network with the triplet loss function, trained on a dataset of triplets. Each triplet would consist of an anchor (the recipe itself), a positive sample (a similar recipe), and a negative sample (a very different recipe).
The objective would be to minimize the distances between the anchor and positive samples while maximizing the distances between the anchor and negative samples. Since I'm relatively new to neural networks and natural language processing, I would greatly appreciate your thoughts and insights on this approach.
Do you think this method is suitable for my task? Are there any potential pitfalls or challenges that I should be aware of? Additionally, I would be grateful if you could provide me with a guideline on how I can successfully execute this project.

Thank you.

Top comments (0)