Giter VIP home page Giter VIP logo

Comments (11)

ZiyaoGeng avatar ZiyaoGeng commented on August 15, 2024 2

你好,我将attRec进行了更改,采用与SASRec中相同的做法进行评估。要是想要再所有的item list做测试,可以自己定义一个predict,输入为用户序列、所有的物品列表(或者自己给出一个范围),然后再进行预测计算(因为embedding信息已经训练得到,存储在模型中)。

from reclearn.

R7788380 avatar R7788380 commented on August 15, 2024 2

嘗試了將模型的 item_embedding 拿出來做 Item-based collaboration filters,top5 的效果看起來是挺不錯的,與第一部電影 GoldenEye 最像的 top5 如下圖 row2 ~ row6:
截圖 2020-12-05 上午9 36 28

您好,可不可以跟您要一下predict部分您自己写的代码,刚学习这些内容,还不太上手。如果可以的话,这是我的邮箱:[email protected]。非常感谢您!!!

已寄信,有其他任何問題歡迎回信。

from reclearn.

R7788380 avatar R7788380 commented on August 15, 2024 1

嘗試了將模型的 item_embedding 拿出來做 Item-based collaboration filters,top5 的效果看起來是挺不錯的,與第一部電影 GoldenEye 最像的 top5 如下圖 row2 ~ row6:

截圖 2020-12-05 上午9 36 28

from reclearn.

ZiyaoGeng avatar ZiyaoGeng commented on August 15, 2024

你好,之前我也有类似的问题,这感觉像是学术与工业的trade-off。在真正预测的时候,工业上并不是直接调用预测的模型,而是通过训练模型得到所需的item embedding,以及通过序列模型抽象得到的user embedding,两者作交互,来得到预测分数。不知道你是否看过MIND或者YouTube DNN,你看过他们的模型就明白,真正serving的时候,用的是nearest neighbor index(FaceBook有个库叫做faiss)

from reclearn.

R7788380 avatar R7788380 commented on August 15, 2024

謝謝作者回答。

Youtube DNN 我有閱讀過,Youtube 那篇主要是透過特徵工程來強調時間序列的關係,而 AttRec 這篇則是在模型中強調時間序列的關係 (Positional embedding)。

我心中想像的情境是,假設今天某位 User 稱作 U1,曾經看過三部電影 Item {I3, I2, I6},則我想要推薦給他下一部電影,我的想法是將 U1 的 user embedding 與所有的 Item embedding 計算相似度 (使用 faiss 來加速計算),得到最相似的影片例如為 I7,那麼就推薦 I7 這部電影給他。

但是想到這邊我就有兩個疑問

  1. user embedding 與 Item embedding 計算相似度的過程似乎跟過去看過的電影沒什麼關係 ? 有可能造成今天不管看過 {I3, I2, I6} 還是 {I9, I1, I8},我都會推薦 I7 給他。

  2. 假設 User 看過 {I3, I2, I6},那接下來推薦的電影是不是先過濾這三部電影,才不會重複 ?

from reclearn.

ZiyaoGeng avatar ZiyaoGeng commented on August 15, 2024

Youtube DNN,我觉得最重要的是其中工业召回的流程,模型倒是其次的。
1、关于你提到的第一个问题,我有点没大理解。user embedding的抽象表示,不是通过seq embedding而得到的么?在AttRec中特别强调了那种短周期的用户偏好,当前推荐的肯定是与短期偏好相似的内容。
2、我赞同你的观点,确实应该要过滤之前已经发生过交互的物品,但工业上是如何做的,不得而知。

from reclearn.

R7788380 avatar R7788380 commented on August 15, 2024

是我想錯了,AttRec 強調的就是用戶時間序列上的偏好。

工業上可能會離線地定期更新 user embedding 以及 item embedding,以便於隨時掌握 user 的偏好。

謝謝你的回答,我收穫很多。

from reclearn.

RodJohn avatar RodJohn commented on August 15, 2024

你好,之前我也有类似的问题,这感觉像是学术与工业的trade-off。在真正预测的时候,工业上并不是直接调用预测的模型,而是通过训练模型得到所需的item embedding,以及通过序列模型抽象得到的user embedding,两者作交互,来得到预测分数。不知道你是否看过MIND或者YouTube DNN,你看过他们的模型就明白,真正serving的时候,用的是nearest neighbor index(FaceBook有个库叫做faiss)

在样本上,
使用user、item、label的形式是一种pointwise的做法
使用user、item_positive、item_negative的形式是一种pairwise的做法
对于双塔模型
使用user、item、label样本建立的模型可以用塔最后一层的输出作为embedding
使用user、item_positive、item_negative的样本 工业实现有点难

from reclearn.

mushroomhe avatar mushroomhe commented on August 15, 2024

嘗試了將模型的 item_embedding 拿出來做 Item-based collaboration filters,top5 的效果看起來是挺不錯的,與第一部電影 GoldenEye 最像的 top5 如下圖 row2 ~ row6:

截圖 2020-12-05 上午9 36 28

您好,可不可以跟您要一下predict部分您自己写的代码,刚学习这些内容,还不太上手。如果可以的话,这是我的邮箱:[email protected]。非常感谢您!!!

from reclearn.

mushroomhe avatar mushroomhe commented on August 15, 2024

嘗試了將模型的 item_embedding 拿出來做 Item-based collaboration filters,top5 的效果看起來是挺不錯的,與第一部電影 GoldenEye 最像的 top5 如下圖 row2 ~ row6:
截圖 2020-12-05 上午9 36 28

您好,可不可以跟您要一下predict部分您自己写的代码,刚学习这些内容,还不太上手。如果可以的话,这是我的邮箱:[email protected]。非常感谢您!!!

已寄信,有其他任何問題歡迎回信。

非常感谢您!!!

from reclearn.

nmnhut0208 avatar nmnhut0208 commented on August 15, 2024

I tried to take out the item_embedding of the model to make Item-based collaboration filters. The effect of top5 seems to be quite good. The top5 which is most similar to the first movie GoldenEye is shown in the following figure row2 ~ row6:
Screenshot 2020-12-05 9 36 28 AM

Hello, can I ask you about the code that you wrote yourself in the predict part. I just learned this content and I haven't gotten to it yet. If possible, this is my email: [email protected] . Thank you very much! ! !

The letter has been sent, please reply if you have any other questions.

I tried to take out the item_embedding of the model to make Item-based collaboration filters. The effect of top5 seems to be quite good. The top5 which is most similar to the first movie GoldenEye is shown in the following figure row2 ~ row6:

Screenshot 2020-12-05 9 36 28 AM

Hello, can I ask you about the code that you wrote yourself in the predict part. I just learned this content and I haven't gotten to it yet. If possible, this is my email: [email protected] . Thank you very much! ! !

I tried to take out the item_embedding of the model to make Item-based collaboration filters. The effect of top5 seems to be quite good. The top5 which is most similar to the first movie GoldenEye is shown in the following figure row2 ~ row6:
Screenshot 2020-12-05 9 36 28 AM

Hello, can I ask you about the code that you wrote yourself in the predict part. I just learned this content and I haven't gotten to it yet. If possible, this is my email: [email protected] . Thank you very much! ! !

The letter has been sent, please reply if you have any other questions.

Hi, Can you give me the predict code for reference? If possible, this is my email: [email protected] . Thank you very much! ! !

from reclearn.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.