Recommendation system deviation correction method fusing big language model world knowledge

By integrating the world knowledge of the large language model, the prompt word template and multimodal expert network module are designed, which solves the problem that the recommendation system bias correction algorithm relies on unbiased data, and achieves a more efficient and personalized recommendation effect.

CN120045792AActive Publication Date: 2025-05-27BEIJING UNIV OF POSTS & TELECOMM

Patent Information

Application Number
CN202510218762.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-26
Publication Date
2025-05-27
Estimated Expiration
2045-02-26

AI Technical Summary

Technical Problem

The existing recommendation system bias correction algorithm relies on unbiased experimental data, resulting in poor adaptability and unstable performance of the model, and the debiased algorithm that relies on unbiased data has defects such as poor adaptability and large result variance.

Method used

The recommendation system correction method is adopted that integrates world knowledge of the large language model. By obtaining open source data sets, designing preset prompt word templates, using context learning technology to guide the large language model to generate item descriptions and user preference reasoning, and the final representation of users and items is realized through the multimodal expert network module, and finally the model is optimized through the cross entropy loss function.

Benefits of technology

Without relying on unbiased data, the personalization and accuracy of the recommendation system are improved, the flexibility and transferability of the model are enhanced, and the problem of poor adaptability of traditional debiased algorithms in various biased scenarios is solved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120045792A_ABST
    Figure CN120045792A_ABST
Patent Text Reader

Abstract

The invention discloses a recommendation system deviation correction method fusing big language model world knowledge, which comprises the following steps: acquiring an open source data set of a recommendation system, and generating a training set; guiding a large language model to generate description information of an article and preference reasoning of a user through a training set in combination with a context learning technology; encoding the description information of the article and the preference reasoning of the user through a pre-trained text encoder to generate a first encoding vector, and encoding the IDs of the user and the article to generate a second encoding vector; inputting the first coding vector and the second coding vector into a multi-mode expert network module to obtain final representations of the user and the article; inputting the final representations of the user and the article into a prediction layer to obtain a prediction value, and optimizing a multi-modal expert network module through a cross entropy loss function; and performing recommendation system correction through the optimized multi-mode expert network module. The inherent deviation in the user behavior data is eliminated, the real preference of the user is captured, and recommendation system deviation correction is completed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of large language models and recommendation systems, and specifically relates to a recommendation system correction method that integrates large language model world knowledge. Background Art

[0002] In order to quickly mine valuable information from massive data, the recommendation system realizes the interaction between users and information, and has achieved great success in e-commerce, film and television platforms and other fields. However, due to the existence of various biases in the process of user behavior generation, such as popularity bias, selection bias, and exposure bias, these biases cause the data to fail to accurately reflect the user's true preferences. Therefore, blindly fitting data without considering these biases may cause a series of problems, including sub-optimization of the model and long-tail effect. By deeply analyzing the biases in the recommendation system and studying the debiased recommendation algorithm, the real preferences of users can be effectively captured, thereby improving the performance of the recommendation system.

[0003] In recent years, the study of debiasing algorithms has become an important research direction in the field of recommender systems. Early bias correction algorithms mainly focused on eliminating specific types of biases. These methods mainly eliminate the influence of specific biases through methods such as inverse propensity scores and prior knowledge. Although these methods have alleviated the impact of data bias on recommendation results to a certain extent, they still have significant limitations. First, debiasing methods for specific biases rely on experts' understanding of the generation mechanism of specific biases, so they lack universality when facing some difficult-to-define biases. Secondly, in actual recommendation scenarios, various types of data biases are often intertwined (for example, user purchasing behavior may be affected by both popularity bias and exposure bias), making debiasing algorithms for specific biases challenging in practical applications. Therefore, improving the universality of debiasing algorithms to cope with a variety of confusing biases (including known and unknown biases) in real situations has become an important issue that needs to be urgently addressed in the recommendation field.

[0004] Scholars today are committed to studying general debiasing algorithms, aiming to implement models that target multiple types of biases at the same time. These methods mainly rely on unbiased experimental data, and use knowledge distillation, meta-learning and other methods to implement debiasing algorithms for multiple biases. Although these methods have achieved certain results, they all rely on unbiased data, which is constructed through a random logging strategy, requiring high experimental and labor costs, which will harm the interests of the platform and users in the long run. In addition, due to the low coverage and small number of unbiased data, debiasing algorithms that rely on unbiased data have the defects of poor adaptability and large variance of results.

[0005] The above problems make it difficult for existing methods to achieve good results in the challenge of correcting recommendation systems. Summary of the invention

[0006] In view of the above-mentioned deficiencies in the prior art, the present invention provides a recommendation system correction method that integrates world knowledge of a large language model, which solves the problems in the prior art of poor model adaptability and unstable performance caused by reliance on unbiased experimental data.

[0007] In order to achieve the above-mentioned invention object, the technical solution adopted by the present invention is: a recommendation system correction method integrating world knowledge of a large language model, comprising the following steps:

[0008] S1. Obtain the open source dataset of the recommendation system and generate a training set;

[0009] S2, based on the preset prompt word template, guide the large language model to generate item description information and user preference inference through training set combined with context learning technology;

[0010] S3, encode the item description information and the user preference inference through the pre-trained text encoder to generate a first encoding vector, input the training set into the embedding layer, encode the user and item IDs, and generate a second encoding vector;

[0011] S4, inputting the first encoding vector and the second encoding vector into the multimodal expert network module to obtain the final representation of the user and the item;

[0012] S5. Input the final representation of the user and the item into the prediction layer to obtain the predicted value, compare the predicted value with the label in the training set, and then optimize the multimodal expert network module through the cross entropy loss function;

[0013] S6. Correct the recommendation system through the optimized multimodal expert network module.

[0014] Furthermore: in S1, the open source data set of the recommendation system includes an open source movie data set and an open source e-commerce platform data set, each piece of data in the data set contains the user's historical behavior, the name, category and characteristics of the product, and each piece of data is marked with a corresponding label.

[0015] Further: in said S2, the preset prompt word template includes a prompt word template for user preference reasoning and a prompt word template for item description information;

[0016] Among them, in the prompt word template for user preference reasoning, the instruction is a task that needs to be completed by a large language model, the example is two to three given user behavior data and their corresponding analysis results, and the request is a text description of the user behavior data currently required;

[0017] In the prompt word template for the description information of the item, the instruction is a task that needs to be completed by a large language model, the example is two to three given movie data and their corresponding supplementary description information, and the request is the movie description that needs to be requested.

[0018] Further: in S4, the multimodal expert network module includes a fusion submodule and several expert networks, and the types of expert networks include text expert networks, collaborative expert networks and hybrid expert networks.

[0019] Further: In S4, the method for obtaining the final representation of the user and the item is specifically:

[0020] The fusion submodule combines the outputs of all expert networks according to the gating network, and combines the unbiased text information provided by the large language model world knowledge and the collaborative information generated based on user behavior to generate the final representation u of users and items. final ;

[0021]

[0022] In the formula, h i is the output result of the i-th expert network, M is the number of expert networks, g i is the weight of the i-th expert network, and its specific expression is:

[0023] g i =softmax(W g h i +b g )

[0024] Where softmax(·) is the Softmax function, W g is the weight matrix of the gating network, b g is the bias vector of the gating network.

[0025] The beneficial effect of the above further scheme is that the gating network in the fusion sub-module determines which expert modules should be activated and the degree of their respective contributions by learning the characteristics of the input data. The core of the gating network to achieve probability distribution selection is that it can dynamically adjust the importance weight of each expert module according to the input, thereby ensuring that the model can make the best choice in different scenarios.

[0026] Furthermore, the structure of the text expert network is a multi-layer perceptron network, the input of the text expert network is a first encoding vector, and the output of the text expert network is an embedding vector of a custom dimension. The expression of the text expert network is as follows:

[0027]

[0028] Where t is the first encoding vector, is the vector of the text expert network input layer, is the vector of the l-1th layer of the text expert network, LeakyReLU(·) is the activation function, W t (l) is the weight matrix of the lth layer in the text expert network, is the bias vector of the lth layer in the text expert network, is the hidden vector of the lth layer in the text expert network.

[0029] The beneficial effects of the above further scheme are: the text expert network is responsible for further encoding the vector, identifying potential product attributes, consumer preferences and other factors, and then assisting in building a more accurate recommendation system. At the same time, using LeakyReLU as the activation function helps to maintain gradient flow and avoid the "dead zone" problem that may occur in traditional activation functions, thereby promoting a more efficient training process.

[0030] Furthermore, the structure of the collaborative expert network is a multi-layer perceptron network, the input of the collaborative expert network is a second encoding vector, and the output of the collaborative expert network is an embedding vector of a custom dimension. The specific expression of the collaborative expert network is:

[0031]

[0032] Where u is the second encoding vector, is the vector of the collaborative expert network input layer, is the vector of the l-1th layer of the collaborative expert network, LeakyReLU(·) is the activation function, is the weight matrix of the lth layer in the collaborative expert network, is the bias vector of the lth layer in the collaborative expert network, is the hidden vector of the lth layer in the collaborative expert network.

[0033] The beneficial effects of the above further scheme are: the collaborative expert network focuses on the interaction between users and items, is responsible for further encoding the vectors of users and items, and reveals the patterns and relationships hidden behind these interactions. At the same time, using LeakyReLU as the activation function helps to keep the gradient flowing and avoid the "dead zone" problem that may occur in traditional activation functions, thereby promoting a more efficient training process.

[0034] Furthermore: the hybrid expert network uses a contrastive learning method to calculate the vectors of users and items. The method is specifically as follows:

[0035] Positive and negative sample pairs are constructed in the training batch. The first encoding vector, the second encoding vector and the initialized user vector corresponding to the same user are regarded as positive examples, and the first encoding vector, the second encoding vector of the user and the initialized user vector of other users are regarded as negative examples. Based on the dot product similarity as the measurement indicator, the similarity between positive examples and the contrast between negative examples are shortened, and the fusion of multimodal information is realized in a fine-grained manner. The vectors of users and items are encoded and generated.

[0036] The beneficial effects of the above further scheme are as follows: the hybrid expert network can simultaneously coordinate text semantic information and user behavior patterns, and by bringing the text features and collaborative features of the same user closer, and pulling the text features and collaborative features of different users apart, the hybrid expert network can realize the fusion of multimodal information in a fine-grained manner. Multimodal information includes text and user behavior data, and uses unbiased text information as auxiliary information to correct deviations in collaborative information and improve the personalization and accuracy of the recommendation system.

[0037] Further: In S5, the predicted value is obtained The specific expression is:

[0038]

[0039] Where σ(·) is the Sigmoid function, is the final representation vector of the item, is the final representation vector of the user.

[0040] Further: In S5, the method for optimizing the multimodal expert network module by the cross entropy loss function is:

[0041]

[0042] L final =α*L 1 +β*L 2 +γ*L 3

[0043] In the formula, y u,i is the data label, is the predicted value, α is the first hyperparameter, β is the second hyperparameter, γ is the third hyperparameter, and u n is the user representation on the recommendation side, t n is the text representation corresponding to user n on the text side, and the similarity is measured by the dot product similarity, t k is the text representation corresponding to user k on the text side, v m is the item representation on the recommendation side, t m is the text representation corresponding to the item m on the text side, t ois the text representation corresponding to item o on the text side, N is the total number of users, M is the total number of items, and L final is the overall loss function of the method, L 1 is the estimated loss function of the fusion submodule based on the output of the text expert network and the collaborative expert network, L 2 is the contrast loss function on the user side in the hybrid expert network, L 3 is the contrast loss function on the item side in the hybrid expert network.

[0044] The beneficial effects of the present invention are as follows: the present invention provides a recommendation system correction method integrating world knowledge of a large language model, which has the following effects:

[0045] (1) Different from traditional debiasing algorithms, this paper provides a new technical route for the research of bias correction algorithms, namely, integrating external knowledge to reduce the impact of data bias on recommendation results. This paper proposes for the first time a recommendation system bias correction algorithm that integrates world knowledge of a large language model, solving the problem of completing universal bias correction for recommendation systems without relying on unbiased experimental data.

[0046] (2) When traditional large language models are applied to recommendation systems, they usually require a lot of resources for fine-tuning training to adapt to specific application scenarios, which not only increases development costs, but also limits the flexibility and portability of the model. To address this challenge, the present invention designs prompt word templates through in-context learning technology, and uses background information in the context to guide the large language model to understand the recommendation scenario, so that the large language model can automatically adjust the output content according to the provided background information without changing its original parameters. Guided by the prompt word template, whether in text generation or user preference reasoning tasks, the model can quickly understand the current recommendation scenario and generate high-quality, personalized description information, making the present invention easy to migrate to various recommendation scenarios.

[0047] (3) The present invention realizes the mining and alignment of the world knowledge of the large language model and the user behavior data through the multimodal expert network module, eliminates the inherent bias in the user behavior data, thereby capturing the user's true preferences and completing the recommendation system correction.

[0048] (4) The present invention can be applied to various recommendations without relying on unbiased data, and has broad application prospects. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 This is a flow chart of a recommendation system correction method that integrates world knowledge of a large language model according to the present invention.

[0050] Figure 2Schematic diagram of the cue word template for inferring user preferences.

[0051] Figure 3 A schematic diagram of a prompt word template for item description information. DETAILED DESCRIPTION

[0052] The specific implementation modes of the present invention are described below to facilitate those skilled in the art to understand the present invention. However, it should be clear that the present invention is not limited to the scope of the specific implementation modes. For those of ordinary skill in the art, as long as various changes are within the spirit and scope of the present invention as defined and determined by the attached claims, these changes are obvious, and all inventions and creations utilizing the concept of the present invention are protected.

[0053] like Figure 1 As shown, in one embodiment of the present invention, a recommendation system correction method integrating world knowledge of a large language model includes the following steps:

[0054] S1. Obtain the open source dataset of the recommendation system and generate a training set;

[0055] S2, based on the preset prompt word template, guide the large language model to generate item description information and user preference inference through training set combined with context learning technology;

[0056] S3, encode the item description information and the user preference inference through the pre-trained text encoder to generate a first encoding vector, input the training set into the embedding layer, encode the user and item IDs, and generate a second encoding vector;

[0057] S4, inputting the first encoding vector and the second encoding vector into the multimodal expert network module to obtain the final representation of the user and the item;

[0058] S5. Input the final representation of the user and the item into the prediction layer to obtain the predicted value, compare the predicted value with the label in the training set, and then optimize the multimodal expert network module through the cross entropy loss function;

[0059] S6. Correct the recommendation system through the optimized multimodal expert network module.

[0060] The present invention aims to break the information cocoon of the recommendation system by utilizing the general world knowledge and reasoning ability of the large language model, realize the correction of the recommendation system, and improve the estimation accuracy and fairness of the recommendation system.

[0061] In S1, the open source datasets of the recommendation system include an open source movie dataset and an open source e-commerce platform dataset. Each piece of data in the dataset contains the user's historical behavior, the name, category and features of the product, and each piece of data is marked with a corresponding label.

[0062] In this embodiment, the present invention divides the data set into a training set and a verification set, and uses whether the user has rated or clicked on a certain product as a label, so as to complete the training and verification of the multimodal expert network module.

[0063] In S2, the preset prompt word templates include prompt word templates for user preference reasoning and prompt word templates for item description information;

[0064] Among them, in the prompt word template for user preference reasoning, the instruction is a task that needs to be completed by a large language model, the example is two to three given user behavior data and their corresponding analysis results, and the request is a text description of the user behavior data currently required;

[0065] like Figure 2 As shown, in this embodiment, for the prompt word template for user preference inference, the instruction describes the task that needs to be completed by the large language model, for example: "Given a user is {{user description}}, the user's movie viewing history over a period of time is, listed below: {{user history record}}. Analyze user preferences (consider factors such as movie categories, release periods, {{scene-specific factors}}, etc.). Please provide a clear explanation and other relevant factors based on the detailed information of the user's browsing history." The example is two to three given user behavior data and their corresponding manual analysis results, for example: "Example A: The user is {{user description}}, and the user's movie viewing history over a period of time is, listed below: {{user history record}}. Reply A: After analysis, the user's preference is {{user preference}}, and the reasoning reasons are as follows: {{user preference}}". The request is a text description of the user behavior data that needs to be requested, for example: "The user is {{user description}}, and the user's movie viewing history over a period of time is, listed below: {{user history record}}, please analyze the user's preference."

[0066] In the prompt word template for the description information of the item, the instruction is a task that needs to be completed by a large language model, the example is two to three given movie data and their corresponding supplementary description information, and the request is the movie description that needs to be requested.

[0067] like Figure 3As shown, in this embodiment, for the prompt word template of the description information of the item, the instruction describes the task that needs to be completed by the large language model, for example: "Please introduce the movie {{movie name}} and accurately describe its attributes (including but not limited to movie category, release period, {{scene specific factors}} and other factors)". The example is two to three given movie data and their corresponding supplementary description information, for example: "Example A: The movie that needs to be supplemented is {{movie name}}. Reply A: After analysis, its supplementary information is {{movie category}, {release period}, {scene specific factors}}". The request is the description of the movie that needs to be requested at the moment, for example: "The movie that needs to be supplemented is {{movie name}}".

[0068] In this embodiment, through the prompt word template designed by the present invention and the in-context learning technology, the background information in the context is used to guide the large language model to generate description information for the item and infer the user's preference. In order to improve the online service efficiency of the recommendation system, this process is completed offline, and the generated content can be stored locally for multiple use.

[0069] In S3, the pre-trained text encoder can select different parameter sizes and language models of different languages ​​according to the scenario. The text encoder is used to encode the original text into a vector of fixed length. The pre-trained encoder can capture the complex semantic relationships, contextual dependencies, and long-distance dependencies in the text through a multi-layer neural network structure. These pre-trained weights can be used as a starting point to help the model adapt to new tasks more quickly without the need to start training from scratch. In addition, the hot-pluggable pre-trained text encoder can better adapt to different recommendation scenarios. For example, in the Chinese recommendation scenario, the Chinese language model is selected as the text encoder, and in the English recommendation scenario, the English language model is selected; in the recommendation scenario that requires real-time, a text encoder with a small parameter amount is selected for encoding to reduce the dimension of the vector, while reducing storage overhead and speeding up the response speed of the model, and in the recommendation scenario that requires accuracy, a text encoder with a large parameter amount is selected for encoding to ensure that more in-depth text information is encoded into the vector.

[0070] In this embodiment, the embedding layer is a single-layer perceptron, the input dimension is the number of items and users, and the output is a custom hidden layer dimension. By mapping discrete user IDs and item IDs to embedding vectors, the embedding layer greatly reduces the parameter scale of the model compared to the one-hot encoding method, especially when dealing with large-scale categories or vocabulary. This not only improves training efficiency, but also reduces the risk of overfitting. In addition, the introduction of the embedding layer also makes the model easier to expand. With the addition of new IDs, it is only necessary to simply expand the embedding matrix without redesigning the entire model structure.

[0071] In S4, the multimodal expert network module includes a fusion submodule and several expert networks, and the types of expert networks include text expert networks, collaborative expert networks and hybrid expert networks. The fusion submodule combines the outputs of multiple experts through a gating network, combines the unbiased text information provided by the world knowledge of the large language model and the collaborative information generated based on user behavior, and generates the final item representation and user representation.

[0072] In S4, the method for obtaining the final representation of the user and the item is specifically as follows:

[0073] The fusion submodule combines the outputs of all expert networks according to the gating network, and combines the unbiased text information provided by the large language model world knowledge and the collaborative information generated based on user behavior to generate the final representation u of users and items. final ;

[0074]

[0075] In the formula, h i is the output result of the i-th expert network, M is the number of expert networks, g i is the weight of the i-th expert network, and its specific expression is:

[0076] g i =softmax(W g h i +b g )

[0077] Where softmax(·) is the Softmax function, W g is the weight matrix of the gating network, b g is the bias vector of the gating network.

[0078] In this embodiment, the gating network in the fusion submodule decides which expert modules should be activated and the extent of their respective contributions by learning the characteristics of the input data. The core of the gating network to achieve probability distribution selection is that it can dynamically adjust the importance weight of each expert module according to the input, thereby ensuring that the model can make the best choice in different scenarios.

[0079] The structure of the text expert network is a multi-layer perceptron network. The input of the text expert network is the first encoding vector, and the output of the text expert network is an embedding vector of a custom dimension. The expression of the text expert network is as follows:

[0080]

[0081]

[0082] Where t is the first encoding vector, is the vector of the text expert network input layer, is the vector of the l-1th layer of the text expert network, LeakyReLU(·) is the activation function, W t (l) is the weight matrix of the lth layer in the text expert network, is the bias vector of the lth layer in the text expert network, is the hidden vector of the lth layer in the text expert network.

[0083] In this embodiment, the text expert network is designed specifically for processing text data. It is responsible for further encoding the vectors, identifying potential product attributes, consumer preferences and other factors, and then assisting in building a more accurate recommendation system. At the same time, using LeakyReLU as the activation function helps to maintain gradient flow and avoid the "dead zone" problem that may occur in traditional activation functions, thereby promoting a more efficient training process. The expression of the LeakyReLU function is as follows:

[0084]

[0085] Where x is the input data.

[0086] The structure of the collaborative expert network is a multi-layer perceptron network, the input of the collaborative expert network is the second encoding vector, and the output of the collaborative expert network is an embedding vector of a custom dimension The specific expression of the collaborative expert network is:

[0087]

[0088] Where u is the second encoding vector, is the vector of the collaborative expert network input layer, is the vector of the l-1th layer of the collaborative expert network, LeakyReLU(·) is the activation function, is the weight matrix of the lth layer in the collaborative expert network, is the bias vector of the lth layer in the collaborative expert network, is the hidden vector of the lth layer in the collaborative expert network.

[0089] In this embodiment, the collaborative expert network focuses on the interaction between users and items, and is responsible for further encoding the vectors of users and items, revealing the patterns and relationships hidden behind these interactions. At the same time, using LeakyReLU as the activation function helps to maintain gradient flow and avoid the "dead zone" problem that may occur in traditional activation functions, thereby promoting a more efficient training process.

[0090] The hybrid expert network uses a contrastive learning method to calculate the vectors of users and items. The specific method is:

[0091] Positive and negative sample pairs are constructed in the training batch. The first encoding vector, the second encoding vector and the initialized user vector corresponding to the same user are regarded as positive examples, and the first encoding vector, the second encoding vector of the user and the initialized user vector of other users are regarded as negative examples. Based on the point product similarity as a measurement indicator, the similarity between positive examples and the contrast between negative examples are shortened, and the fusion of multimodal information is realized in a fine-grained manner. The vectors of users and items are encoded and generated. The working principle of the hybrid expert network is as follows:

[0092] First, within the same batch, taking the user side as an example, for each user i, we replace the vector t of the same user i i And the user vector u in the recommendation space i Considered as a positive example (t i ,u i ); For each user i, the vector t of the same user i i and other user vectors u in the recommendation space j Considered as negative example pairs (t i ,u j ).

[0093] Next, we use point product similarity as a measurement indicator to minimize the distance between the distributions of positive examples and maximize the distance between the distributions of negative examples to achieve multimodal information fusion of text space and collaborative space. The loss function is modeled as follows:

[0094]

[0095] Among them, u i is the user representation on the recommendation side, t i is the text representation corresponding to user i on the text side, and the similarity is measured by the dot product similarity, t k is the text representation corresponding to item k on the text side, and N is the total number of users.

[0096] The hybrid expert network can coordinate text semantic information and user behavior patterns at the same time. By bringing the text features and collaborative features of the same user closer and pulling the text features and collaborative features of different users farther apart, the hybrid expert network can achieve fine-grained fusion of multimodal information. Multimodal information includes text and user behavior data. Unbiased text information is used as auxiliary information to correct deviations in collaborative information and improve the personalization and accuracy of the recommendation system.

[0097] In S5, the predicted value is obtained. The specific expression is:

[0098]

[0099] Where σ(·) is the Sigmoid function, is the final representation vector of the item, is the final representation vector of the user.

[0100] In this embodiment, the present invention compares the predicted value with the label in the data set, optimizes the model through the cross entropy loss function and the contrast loss function of hybrid expert modeling, and completes the correction and training of the model.

[0101] In S5, the method for optimizing the multimodal expert network module by using the cross entropy loss function is:

[0102]

[0103] L final =α*L 1 +β*L 2 +γ*L 3

[0104] In the formula, y u,i is the data label, is the predicted value, α is the first hyperparameter, β is the second hyperparameter, γ is the third hyperparameter, and u n is the user representation on the recommendation side, t n is the text representation corresponding to user n on the text side, and the similarity is measured by the dot product similarity, t k is the text representation corresponding to user k on the text side, v m is the item representation on the recommendation side, t m is the text representation corresponding to the item m on the text side, t o is the text representation corresponding to item o on the text side, N is the total number of users, M is the total number of items, and L final is the overall loss function of the method, L 1 is the estimated loss function of the fusion submodule based on the output of the text expert network and the collaborative expert network, L 2 is the contrast loss function on the user side in the hybrid expert network, L 3 is the contrast loss function on the item side in the hybrid expert network.

[0105] The beneficial effects of the present invention are as follows: the present invention provides a recommendation system correction method integrating world knowledge of a large language model, which has the following effects:

[0106] (1) Different from traditional debiasing algorithms, this paper provides a new technical route for the research of bias correction algorithms, namely, integrating external knowledge to reduce the impact of data bias on recommendation results. This paper proposes for the first time a recommendation system bias correction algorithm that integrates world knowledge of a large language model, solving the problem of completing universal bias correction for recommendation systems without relying on unbiased experimental data.

[0107] (2) When traditional large language models are applied to recommendation systems, they usually require a lot of resources for fine-tuning training to adapt to specific application scenarios, which not only increases development costs, but also limits the flexibility and portability of the model. In response to this challenge, the present invention designs prompt word templates through contextual learning technology, and uses the background information in the context to guide the large language model to understand the recommendation scenario, so that the large language model can automatically adjust the output content according to the provided background information without changing its original parameters. Guided by the prompt word template, whether in text generation or user preference reasoning tasks, the model can quickly understand the current recommendation scenario and generate high-quality, personalized description information, making the present invention easy to migrate to various recommendation scenarios.

[0108] (3) The present invention realizes the mining and alignment of the world knowledge of the large language model and the user behavior data through the multimodal expert network module, eliminates the inherent bias in the user behavior data, thereby capturing the user's true preferences and completing the recommendation system correction.

[0109] (4) The present invention can be applied to various recommendations without relying on unbiased data, and has broad application prospects.

[0110] In the description of the present invention, it is necessary to understand that the orientation or positional relationship indicated by the terms "center", "thickness", "upper", "lower", "horizontal", "top", "bottom", "inner", "outer", "radial", etc. is based on the orientation or positional relationship shown in the drawings, and is only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present invention. In addition, the terms "first", "second", and "third" are used only for descriptive purposes, and cannot be understood as indicating or implying the relative importance or the number of implicitly specified technical features. Therefore, the features defined by "first", "second", and "third" may explicitly or implicitly include one or more of the features.

Claims

1. A recommendation system correction method integrating world knowledge of a large language model, characterized in that: The following steps are involved: S1. Obtain the open source dataset of the recommendation system and generate a training set; S2, based on the preset prompt word template, guide the large language model to generate item description information and user preference inference through training set combined with context learning technology; S3, encode the item description information and the user preference inference through the pre-trained text encoder to generate a first encoding vector, input the training set into the embedding layer, encode the user and item IDs, and generate a second encoding vector; S4, inputting the first encoding vector and the second encoding vector into the multimodal expert network module to obtain the final representation of the user and the item; S5. Input the final representation of the user and the item into the prediction layer to obtain the predicted value, compare the predicted value with the label in the training set, and then optimize the multimodal expert network module through the cross entropy loss function; S6. Correct the recommendation system through the optimized multimodal expert network module.

2. The recommendation system correction method integrating large language model world knowledge according to claim 1 is characterized in that: In S1, the open source datasets of the recommendation system include an open source movie dataset and an open source e-commerce platform dataset. Each piece of data in the dataset contains the user's historical behavior, the name, category and features of the product, and each piece of data is marked with a corresponding label.

3. The recommendation system correction method integrating large language model world knowledge according to claim 1 is characterized in that: In S2, the preset prompt word templates include prompt word templates for user preference reasoning and prompt word templates for item description information; Among them, in the prompt word template for user preference reasoning, the instruction is a task that needs to be completed by a large language model, the example is two to three given user behavior data and their corresponding analysis results, and the request is a text description of the user behavior data currently required; In the prompt word template for the description information of the item, the instruction is a task that needs to be completed by a large language model, the example is two to three given movie data and their corresponding supplementary description information, and the request is the movie description that needs to be requested.

4. The recommendation system correction method integrating large language model world knowledge according to claim 1 is characterized in that: In S4, the multimodal expert network module includes a fusion submodule and several expert networks, and the types of expert networks include text expert networks, collaborative expert networks and hybrid expert networks.

5. The recommendation system correction method integrating large language model world knowledge according to claim 4 is characterized in that: In S4, the method for obtaining the final representation of the user and the item is specifically as follows: The fusion submodule combines the outputs of all expert networks according to the gating network, and combines the unbiased text information provided by the large language model world knowledge and the collaborative information generated based on user behavior to generate the final representation u of users and items. final : In the formula, h i is the output result of the i-th expert network, M is the number of expert networks, g i is the weight of the i-th expert network, and its specific expression is: g i =softmax(W g h i +b g ) In the formula, softmax(·) is the Softmax function, W g is the weight matrix of the gating network, b g is the bias vector of the gating network.

6. The recommendation system correction method integrating large language model world knowledge according to claim 5 is characterized in that: The structure of the text expert network is a multi-layer perceptron network. The input of the text expert network is the first encoding vector, and the output of the text expert network is an embedding vector of a custom dimension. The expression of the text expert network is as follows: Where t is the first encoding vector, is the vector of the text expert network input layer, is the vector of the l-1th layer of the text expert network, LeakyReLU(·) is the activation function, is the weight matrix of the lth layer in the text expert network, is the bias vector of the lth layer in the text expert network, is the hidden vector of the lth layer in the text expert network.

7. The recommendation system correction method integrating large language model world knowledge according to claim 5 is characterized in that: The structure of the collaborative expert network is a multi-layer perceptron network, the input of the collaborative expert network is the second encoding vector, and the output of the collaborative expert network is an embedding vector of a custom dimension The specific expression of the collaborative expert network is: Where u is the second encoding vector, is the vector of the collaborative expert network input layer, is the vector of the l-1th layer of the collaborative expert network, LeakyReLU(·) is the activation function, is the weight matrix of the lth layer in the collaborative expert network, is the bias vector of the lth layer in the collaborative expert network, is the hidden vector of the lth layer in the collaborative expert network.

8. The recommendation system correction method integrating large language model world knowledge according to claim 5 is characterized in that: The hybrid expert network uses a contrastive learning method to calculate the vectors of users and items. The specific method is: Positive and negative sample pairs are constructed in the training batch. The first encoding vector, the second encoding vector and the initialized user vector corresponding to the same user are regarded as positive examples, and the first encoding vector, the second encoding vector of the user and the initialized user vector of other users are regarded as negative examples. Based on the dot product similarity as the measurement indicator, the similarity between positive examples and the contrast between negative examples are shortened, and the fusion of multimodal information is realized in a fine-grained manner. The vectors of users and items are encoded and generated.

9. The recommendation system correction method integrating large language model world knowledge according to claim 8 is characterized in that: In S5, the predicted value is obtained. The specific expression is: Where σ(·) is the Sigmoid function, is the final representation vector of the item, is the final representation vector of the user.

10. The recommendation system correction method integrating large language model world knowledge according to claim 1 is characterized in that: In S5, the method for optimizing the multimodal expert network module by using the cross entropy loss function is: L final =α*L1+β*L2+γ*L3 In the formula, y u,i is the data label, is the predicted value, α is the first hyperparameter, β is the second hyperparameter, γ is the third hyperparameter, and u n is the user representation on the recommendation side, t n is the text representation corresponding to user n on the text side, and the similarity is measured by the dot product similarity, t k is the text representation corresponding to user k on the text side, v m is the item representation on the recommendation side, t m is the text representation corresponding to the item m on the text side, t o is the text representation corresponding to item o on the text side, N is the total number of users, M is the total number of items, and L final is the overall loss function of the method, L1 is the estimated loss function of the fusion submodule based on the output of the text expert network and the collaborative expert network, L2 is the contrast loss function on the user side in the hybrid expert network, and L3 is the contrast loss function on the item side in the hybrid expert network.

Citation Information

Patent Citations

  • Knowledge base question generation method based on hybrid expert model and joint learning

    CN113127623A

  • Recommendation method and system based on multi-level comparative learning and multi-modal knowledge graph

    CN116091152A

  • Product recommendation method based on double-channel preference enhancement

    CN117251624A

  • Recommendation system click prediction method based on feature selection depolarization

    CN117272130A

  • Scientific and technical literature recommendation method based on large language model

    CN118839067A

Cited By

  • Anti-data migration recommendation method based on hybrid expert and dynamic graph neural network

    CN120910364A

  • Anti-data drift recommendation method based on hybrid expert and dynamic graph neural network

    CN120910364B

  • Multi-scene user controllable personalized recommendation method and system based on super network adaptation

    CN121481678A

  • Individualized language recommendation depolarization method based on adversarial learning

    CN122412666A