Home  >  Article  >  Backend Development  >  How to design database using cosine similarity algorithm

How to design database using cosine similarity algorithm

WBOY
WBOYOriginal
2016-10-10 11:56:081245browse

There are many articles in the website database, all of which are tagged with relevant tags. When the user registers, the user will be asked to choose the tag he likes, and then use the cosine similarity algorithm to calculate and recommend it to him on the homepage, but this way every time he visits It will be recalculated once. How to design the database to save recommendations to users?

Reply content:

There are many articles in the website database, all of which are tagged with relevant tags. When the user registers, the user will be asked to choose the tag he likes, and then use the cosine similarity algorithm to calculate and recommend it to him on the homepage, but this way every time he visits It will be recalculated once. How to design the database to save recommendations to users?

Separate tags with commas, merge them into strings, and save them~

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn