Recommendation apparatus and recommendation method
The recommendation device enhances item suggestions by encoding user and item history into a latent space, training the model to reconstruct and predict items that align with user preferences and provide unexpected surprises.
Patent Information
- Application Number
- JP2024035945
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2024-03-08
- Publication Date
- 2025-09-19
- Estimated Expiration
- 2044-03-08
Smart Images

Figure 2025136990000001_ABST
Abstract
Description
[Technical Field]
[0001] The present disclosure relates to a recommendation device and a recommendation method. [Background technology]
[0002] Recommendation is a technology that uses personal history and attributes to predict each user's preferences and behavior, and then recommends information and items that match those.In order to improve the accuracy of predictions and the quality of recommendations, not only actions such as access and purchases and personal attributes are used, but also the time and location of each action.
[0003] Known recommendation models incorporating time information are described in Non-Patent Documents 1-4. [Prior art documents] [Non-patent literature]
[0004] [Non-Patent Document 1] Jiaxi Tang and Ke Wangy, “Personalized Top-N Sequential Recommendation via Convolutional Sequence Embedding,” In WSDM, 2018, pp. 565-573 [Non-patent document 2] Lu Yu, Chuxu Zhang, Shangsong Liang, and Xiangliang Zhang, “Multi-Order Attentive Ranking Model for Sequential Recommendation,” In AAAI, 2019, pp. 5709-5716. [Non-patent document 3] Jiacheng Li, Yujie Wang, and Julian J. McAuley, “Time Interval Aware Self-Attention for Sequential Recommendation,” In WSDM, 2020, pp. 322-330. [Non-patent document 4] Liwei Wu, Shuqing Li, Cho-Jui Hsieh, and James Sharpnack, “SSE-PT: Sequential Recommendation Via Personalized Transformer,” In RecSys, 2020, pp. 328-337 Summary of the Invention [Problem to be solved by the invention]
[0005] However, simply using history to suggest items poses a problem: it lacks new discoveries and unexpected surprises.
[0006] The present disclosure has been made in consideration of the above, and aims to not only appropriately recommend items that suit a user, but also to recommend items in a way that allows the user to experience serendipity. [Means for solving the problem]
[0007] A recommendation device according to one aspect of the present disclosure includes a learning unit that inputs a user and an item history and inputs the user and partially missing item history into a model, encodes the user and partially missing item history into a latent space, trains the model so that the original item history can be reconstructed from the user and partially missing item history encoded in the latent space, and trains the model so that recommended items can be predicted from the user and partially missing item history encoded in the latent space, and trains the model to minimize an objective function that represents the rarity of the recommended item from the perspective of all users and the unexpectedness of the recommended item from the perspective of the user and item history, and an input / output unit that inputs the user and item history into the trained model and outputs recommended items to be recommended to the user. [Effects of the Invention]
[0008] According to the present disclosure, not only can items that suit a user be appropriately recommended, but items can also be recommended in a way that allows the user to experience serendipity. [Brief explanation of the drawings]
[0009] [Figure 1] FIG. 1 is a diagram illustrating an example of the configuration of a recommendation system. [Figure 2] FIG. 2 is a diagram for explaining learning and prediction of user and item history. [Figure 3] FIG. 3 is a diagram illustrating an example of the proposed model. [Figure 4] FIG. 4 is a diagram illustrating an example of the implementation of the proposed model. [Figure 5] FIG. 5 is a flowchart showing an example of the flow of the learning process. [Figure 6] FIG. 6 is a flowchart showing an example of a process for recommending an item. DETAILED DESCRIPTION OF THE INVENTION
[0010] [System Configuration] Hereinafter, embodiments of the present disclosure will be described with reference to the drawings.
[0011] FIG. 1 is a diagram showing an example of the configuration of a recommendation system according to this embodiment. The recommendation system 1 learns a user's item history, receives a user identifier from a user terminal 5, inputs the user identifier into a trained deep learning model, and returns recommended items to the user. Examples of items include products purchased by the user, content used by the user (books, music, videos, etc.), and services used by the user. The item history is a history of items purchased or used by the user, and includes time information such as the time of purchase, the time of use, or the order of purchase.
[0012] The recommendation system 1 shown in Fig. 1 includes a learning unit 10, an input / output unit 20, a data storage unit 30, and a calculation result storage unit 40. Each unit included in the recommendation system 1 may be configured with at least one computer equipped with an arithmetic processing unit, a storage device, etc., and the processing of each unit may be executed by a program. This program is stored in a storage device included in the recommendation system 1, and can also be recorded on a computer-readable non-transitory recording medium such as a magnetic disk, optical disk, or semiconductor memory, or provided via a network.
[0013] The learning unit 10 embeds different data, such as users and items, in the same space and learns dynamic user preferences and item trends by focusing on the similarities between recommendations and natural language processing. Natural language processing predicts the next word to appear based on words that have appeared so far. Similarly, recommendations can predict the next item a user is likely to purchase or use based on items the user has previously purchased or used.
[0014] The learning unit 10 includes a pre-processing unit 11 and a calculation processing unit 12 .
[0015] The pre-processing unit 11 sets various parameters for the model, acquires learning data from the data storage unit 30, extracts user identifiers and item histories (including, for example, item identifiers and time information), and generates a dataset consisting of item histories for each user.
[0016] The calculation processing unit 12 inputs the user identifier and item history into the model and learns the model parameters so as to minimize the objective function. The calculation processing unit 12 masks some items in the item history and learns the model parameters so that the masked items can be correctly inferred, thereby making it possible to predict more appropriate recommended items.
[0017] The calculation processing unit 12 maximizes serendipity by training a model to increase the novelty of recommended items for all users and the unexpectedness of recommended items based on the user's past item history. Serendipity refers to encountering something by chance or discovering something unexpected.
[0018] The input / output unit 20 inputs a user identifier and an item history from the user terminal 5, inputs them into the deep learning model, and returns recommended items. The input / output unit 20 may accept a user identifier from the user terminal 5 and obtain an item history corresponding to the user identifier from the data storage unit 30.
[0019] The data storage unit 30 stores data for learning, which includes, for example, information about the user, items purchased or used by the user, and time information.
[0020] The calculation result storage unit 40 stores the parameters of the model learned by the learning unit 10.
[0021] [Proposed model] An overview of model learning in this embodiment will be described.
[0022] FIG. 2 shows an overview of learning and prediction of user and item history. In this embodiment, item history i u,1:t-1 In addition to the user u (user identifier), we use the user's unique influence to predict the recommended item i t To do this, we introduce a latent space z that maps the features of users and items to a common representation. u,1:t-1 Item history i with a random item removed from u,1:t-1 (~tilde over i) to get the original full item history i u,1:t-1 The latent space z is trained so that it can correctly predict the recommended item i. t By predicting this, it is believed that more appropriate items can be recommended.
[0023] As shown in the following equation, recommendations are decomposed into learning and prediction of user preferences (item history).
[0024]
number
[0025] where L FPM (ζ) is the objective function for maximizing serendipity. FPM Details of (ζ) will be given later.
[0026] The configuration of the model of this embodiment is shown in Figure 3. In this embodiment, a variational autoencoder (VAE) configuration is used, and a model including an encoder, a latent space z, a reconstruction decoder, and a prediction decoder is used.
[0027] The above equation can be transformed using the calculus of variations to give the following equation:
[0028]
number
[0029] The encoder generates a user u and a randomly selected item history i. u,1:t-1 (~tilde above i) is encoded into the latent space z, and the item history i with user u and a random item removed is u,1:t-1 (~tilde over i) to the original full item history i u,1:t-1 The likelihood logP(i u,1:t-1 We train the model to maximize |z;ξ). We also train the model to maximize the item history i for user u and a randomly selected item. u,1:t-1 (~tilde above i) to select the recommended item i t The likelihood logP(i tThe model is trained to maximize |z;ψ).
[0030] The objective function L for maximizing serendipity is given in the following equation: FPM An example of (ζ) is shown below.
[0031]
number
[0032] where U is the set of users, e i is the embedding representation of the item.
[0033] novelty(i) calculates the novelty (unusualness) of item i. It is calculated based on the number of users who have recommended item i. Items with high novelty are considered to be more likely to provide a fresh and interesting experience. unexp(u,i) calculates the unexpectedness between user u and item i. The item history i excluding item i for user u u,\i Calculate the distance between item i and item history i. u,\i An item that is highly unexpected is likely to provide a new experience that the user has never experienced before.
[0034] [Model implementation example] Next, an example of model implementation will be described with reference to Fig. 4. In this example, as shown in Fig. 4, a VAE and a Transformer are linked together, a latent factor layer is added to the Transformer decoder, and a model for the above task is trained.
[0035] In addition, a mask called AAM (shown on the right side of the figure) was introduced into the Transformer's attention mechanism, integrating the reconstruction decoder and predictive decoder into a single Transformer decoder. Specifically, when training the reconstruction decoder, an AAM (the bottom mask in the figure) that can refer to all tokens in the user and item history is used, and when training the predictive decoder, an AAM (the top mask in the figure) that can only refer to tokens in past item history among the user and item history is used. In other words, the top mask controls access to tokens of other items based on the context of the item history.
[0036] The latent factor layer is expressed by the following equation:
[0037]
number
[0038] where h L,t is the t-th output of the L-th layer encoder. The function F is a function that reflects the latent space z in the output of the Transformer. Any of the transformation formulas can be arbitrarily selected. W IZ , and h L is a parameter that is updated during model training. g z ,W z , and b z are weights in the latent space and are parameters that are updated during model training.
[0039] During training, the proposed model is fed with the user and the item history with randomly selected items removed, and the objective function L MUM ,L MIM The parameters are learned to minimize
[0040]
number
[0041] where B is the batch and e a ,e p ,en are the embedding representations of the masked ID, the inferred ID, and the distinct ID, respectively. p is at least ε e n than e a Learn to get closer to
[0042] The proposed model is input with user and item history, and the parameters are trained to correctly predict recommended items.
[0043] In addition, the objective function L for maximizing the aforementioned serendipity is FPM The parameters are learned to minimize (ζ).
[0044] Putting the above tasks together, model training is performed by minimizing the following objective function L:
[0045]
number
[0046] where e is the Napier's number, t (bar above) is the time elapsed until the present, and λ is the decay constant. TDCE is the discounted sum of rewards.
[0047] During inference, the user and item history are input to the proposed model to obtain the inference items that follow the item history.
[0048] [Operation] Next, an example of the flow of the learning process will be described with reference to the flowchart of FIG.
[0049] In step S11, the learning unit 10 reads out the user and item history for learning from the data storage unit 30, randomly missing a portion of the item history, and inputs it into the model.
[0050] In step S12, the learning unit 10 updates the parameters of the model so as to minimize the objective function shown above, and stores the updated parameters in the calculation result storage unit 40.
[0051] Next, an example of processing for recommending an item will be described with reference to the flowchart of FIG.
[0052] In step S21, the input / output unit 20 inputs a user identifier from the user terminal 5, and acquires an item history corresponding to the user identifier from the data storage unit 30. The input / output unit 20 may input the item history from the user terminal 5.
[0053] In step S22, the input / output unit 20 inputs the user identifier and the item history into the model, obtains recommended items from the model, and returns the recommended items to the user terminal 5.
[0054] As described above, the recommendation system 1 of this embodiment includes a learning unit 10 and an input / output unit 20. The learning unit 10 inputs a user and item history, inputs the user and partially missing item history into a model, encodes the user and partially missing item history into a latent space, and trains the model so that the original item history can be reconstructed from the user and partially missing item history encoded in the latent space. The model also trains the model so that recommended items can be predicted from the user and partially missing item history encoded in the latent space. The model trains the model to minimize an objective function that represents the rarity of the recommended item from the user as a whole and the unexpectedness of the recommended item from the user and item history. The input / output unit 20 inputs the user and item history into the trained model and outputs recommended items to be recommended to the user. According to this embodiment, by learning the latent space so that the original item history can be reconstructed from the partially missing item history, recommended items can be predicted more accurately. Furthermore, by training the model to minimize an objective function that represents the rarity of the recommended item from the perspective of all users and the unexpectedness of the recommended item from the perspective of the user and item history, it is possible to recommend items that allow users to experience serendipity. [Explanation of symbols]
[0055] 1. Recommendation Systems 10 Learning Department 11 Pre-processing section 12. Computational Processing Unit 20 Input / output section 30 Data storage section 40 Calculation result storage section 5. User terminal
Claims
1. a learning unit that inputs users and item histories, inputs the users and partially missing item histories into a model, encodes the users and partially missing item histories into a latent space, trains the model so that the original item history can be reconstructed from the users and partially missing item histories encoded in the latent space, trains the model so that recommended items can be predicted from the users and partially missing item histories encoded in the latent space, and trains the model so that an objective function that represents the rarity of the recommended items from the perspective of all users and the unexpectedness of the recommended items from the perspective of the users and item histories is minimized; An input / output unit inputs user and item history into the trained model and outputs recommended items to be recommended to the user. Recommendation device.
2. The recommendation device according to claim 1 , The model comprises an encoder, a reconstruction decoder, and a prediction decoder, wherein the encoder encodes user and item histories into a latent space, the reconstruction decoder reconstructs original items from the user and partially missing item histories encoded in the latent space, and the prediction decoder predicts recommended items from the user and partially missing item histories encoded in the latent space; The learning unit learns the latent space so that the reconstruction decoder can reconstruct the original item history from the user and partially missing item history encoded in the latent space, and learns the latent space so that the prediction decoder can predict recommended items from the user and partially missing item history encoded in the latent space. Recommendation device.
3. The recommendation device according to claim 1 or 2, The model is a Transformer with a latent factor layer added, The Transformer is fed with the user and missing item history tokens, and trained to reconstruct the original item history and predict recommended items. When learning to reconstruct item history, all input tokens are referenced, and when learning to predict recommended items, access to other tokens is controlled based on the context of the item history. Recommendation device.
4. Input the user and item history, input the user and partially missing item history into the model, encode the user and partially missing item history into a latent space, training the model so that the original item history can be reconstructed from the user and partially missing item history encoded in the latent space, and training the model so that the recommended items can be predicted from the user and partially missing item history encoded in the latent space; The model is trained to minimize an objective function that represents the rarity of the recommended item from the perspective of all users and the unexpectedness of the recommended item from the perspective of the users and item histories; Input the user and item history into the trained model and output recommended items to be recommended to the user. How to recommend.
5. Recommendation method according to claim 4, The model comprises an encoder, a reconstruction decoder, and a prediction decoder, wherein the encoder encodes user and item histories into a latent space, the reconstruction decoder reconstructs original items from the user and partially missing item histories encoded in the latent space, and the prediction decoder predicts recommended items from the user and partially missing item histories encoded in the latent space; The latent space is learned so that the reconstruction decoder can reconstruct the original item history from the user and partially missing item history encoded in the latent space, and the predictive decoder can predict recommended items from the user and partially missing item history encoded in the latent space. How to recommend.