Information recommendation method and device, electronic equipment and computer readable storage medium
By encoding and processing the recommended information and generating intelligent prompts based on user information, the problem of difficult to meet the diverse interests and intentions of users in the prior art is solved, and efficient information recommendation results are achieved.
Patent Information
- Application Number
- CN202311433543.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-10-30
- Publication Date
- 2025-05-02
AI Technical Summary
The prior art is difficult to meet the user's diverse interests and intentions in information recommendation. The pre-trained language model has small parameters, lack of background knowledge, and cannot fully understand the user's potential intentions, resulting in poor recommendation results.
By encoding the item description information of the recommended information, intelligent prompt information is generated based on the object information of the object to be recommended and the interactive information of various item categories, and reasoning is performed on these intelligent prompt information to obtain the interest description characteristics of the object to be recommended, thereby diversified recommendations.
It realizes diversified interest mining of recommended objects, improves the effect and user experience of information recommendations, and provides diversified recommendation results while personalizing recommendations.
Smart Images

Figure CN119917726A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence, and in particular to an information recommendation method, device, electronic device and computer-readable storage medium. Background Art
[0002] Artificial Intelligence (AI) technology is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can respond in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines so that machines have the functions of perception, reasoning and decision-making.
[0003] In some information recommendation scenarios, a pre-trained language model is usually used to build a recommendation framework in the hope of making recommendations based on the user's interest intentions. In related technologies, pre-trained language models are limited to small-scale language models with relatively small model parameters and a lack of background dependency knowledge. This makes the prediction ability of the language model limited, and the recommended information cannot meet the user's interest intentions. Although the method based on the large language model can learn background dependency knowledge from the text corpus and then predict the user's interest intentions based on user interaction behavior, it generally considers the user's interaction behavior as a whole and cannot fully understand the user's potential intentions. In the recall stage of information recommendation, it is likely that only information similar to the user's past interaction behavior will be recommended, resulting in poor final information recommendation effect. Summary of the invention
[0004] The embodiments of the present application provide an information recommendation method, device, electronic device, and computer-readable storage medium, which can perform diversified recommendations for objects to be recommended and improve the effect of information recommendation.
[0005] The technical solution of the embodiment of the present application is implemented as follows:
[0006] The present application provides an information recommendation method, the method comprising:
[0007] Encoding the item description information of at least one item of information to be recommended to obtain the item description feature of the at least one item of information to be recommended;
[0008] Based on the object information of the object to be recommended and the interaction information of the multiple item categories, generating intelligent prompt information of the multiple item categories;
[0009] Performing inference processing on the intelligent prompt information of the multiple item categories to obtain interest description features of the to-be-recommended object for the multiple item categories;
[0010] Based on the similarity between the item description feature and the interest description feature, a recommendation operation of the at least one information to be recommended is performed on the object to be recommended.
[0011] The present application provides an information recommendation device, including:
[0012] An encoding module, used for encoding the item description information of at least one item of information to be recommended to obtain the item description feature of the at least one item of information to be recommended;
[0013] A generation module, configured to generate intelligent prompt information of the multiple item categories based on the object information of the object to be recommended and the interaction information of the multiple item categories;
[0014] An inference module, configured to perform inference processing on the intelligent prompt information of the multiple item categories to obtain interest description features of the recommended object for the multiple item categories;
[0015] The recommendation module is used to recommend the at least one information to be recommended to the object to be recommended based on the similarity between the item description feature and the interest description feature.
[0016] An embodiment of the present application provides an electronic device, including:
[0017] Memory for storing computer executable instructions or computer programs;
[0018] The processor is used to implement the information recommendation method provided in the embodiment of the present application when executing the computer executable instructions or computer programs stored in the memory.
[0019] An embodiment of the present application provides a computer-readable storage medium storing computer-executable instructions or a computer program for implementing the information recommendation method provided in the embodiment of the present application when executed by a processor.
[0020] An embodiment of the present application provides a computer program product, including computer executable instructions or a computer program. When the computer executable instructions or the computer program are executed by a processor, the information recommendation method provided by the embodiment of the present application is implemented.
[0021] The embodiments of the present application have the following beneficial effects:
[0022] In the recommendation process, on the one hand, the description information of the items to be recommended is encoded to obtain the description features of the items to be recommended. On the other hand, the object information of the recommended object and the interaction information of multiple item categories are used to generate intelligent prompt information of multiple item categories, that is, multiple intelligent prompt information is generated through the interaction information of multiple item categories, and then the intelligent prompt information of multiple item categories is inferred to obtain the interest description features of the recommended object for multiple item categories, thereby mining the diversified interests of the recommended object, and finally, by determining the similarity between the item description features and the interest description features, the recommended object is recommended. In this way, the recommended information corresponding to multiple item categories can be recommended according to the diversified interests of the mined recommended object, so as to achieve personalized recommendation while achieving diversified recommendation and improve the information recommendation effect. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] Figure 1 It is a structural diagram of the information recommendation system architecture provided by the embodiment of the present application;
[0024] Figure 2 It is a schematic diagram of the structure of the server provided in the embodiment of the present application;
[0025] 3A to 3H It is a flowchart of the information recommendation method provided in the embodiment of the present application. DETAILED DESCRIPTION
[0026] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. The described embodiments should not be regarded as limiting the present application. All other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of this application.
[0027] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0028] In the following description, the terms "first\second\third" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second\third" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present application described here can be implemented in an order other than that illustrated or described here.
[0029] Unless otherwise defined, all technical and scientific terms used in the embodiments of the present application have the same meanings as those commonly understood by those skilled in the art. The terms used in the embodiments of the present application are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application.
[0030] Before further describing the embodiments of the present application in detail, the nouns and terms involved in the embodiments of the present application are explained. The nouns and terms involved in the embodiments of the present application are subject to the following interpretations.
[0031] 1) Large Language Models (LLM), also known as language models for short, are machine learning models that can process and generate natural language, such as Generate Pre-Training Model (GPT). The prediction tasks of language models can include text classification, cloze test, and intelligent question answering.
[0032] 2) Recall, which refers to selecting a portion of the recommended information that matches the interest category of the recommended object from the recommended information of multiple categories of items. The recall stage is a key step in the recommendation system, which aims to cover the user's interest areas as much as possible and ensure that the most relevant recommended information is recommended to the user.
[0033] 3) Item category, which refers to the category to which the recommended information belongs, that is, the classification to which the recommended information belongs. This category can generally be the same as the user's interest category. For example, the item category of the recommended information can be sports, entertainment, or literature, and the user's interest category can also be sports, entertainment, or literature. In this way, the recommended information of the corresponding item category can be recommended according to the user's interest category.
[0034] The embodiments of the present application provide an information recommendation method, apparatus, device, computer-readable storage medium, and computer program product, which can perform diversified recommendations for objects to be recommended and improve the effect of information recommendation.
[0035] The following describes exemplary applications of the electronic device provided in the embodiments of the present application. The device provided in the embodiments of the present application can be implemented as various types of user terminals such as laptop computers, tablet computers, desktop computers, set-top boxes, mobile devices (for example, mobile phones, portable music players, personal digital assistants, dedicated messaging devices, portable gaming devices), smart phones, smart speakers, smart watches, smart televisions, and vehicle-mounted terminals, and can also be implemented as servers.
[0036] Taking the server provided in the embodiment of the present application as an example, for example, a server cluster can be deployed in the cloud, thereby opening up artificial intelligence cloud services (AI as a Service, AIaaS) to users or developers. The AIaaS platform will split several common AI services and provide independent or packaged services in the cloud. This service model is similar to opening an AI theme mall, and all users or developers can access one or more artificial intelligence services provided by the AIaaS platform through an application programming interface.
[0037] For example, the server in the cloud is encapsulated with the program of the information recommendation method provided in the embodiment of the present application. The user calls the information recommendation service in the cloud service through the terminal (the terminal runs an APP, such as an instant messaging APP, a reading APP, etc.), so that the server deployed in the cloud calls the program of the encapsulated information recommendation method. When the user initiates an information recommendation request at the terminal, the information to be recommended is obtained in response to the information recommendation request initiated by the terminal, and the item description information of the information to be recommended is encoded and processed to obtain the item description features of the information to be recommended, and based on the object information of the object to be recommended and the interactive information of the multiple item categories, the intelligent prompt information of the multiple item categories is generated. Next, the intelligent prompt information of the multiple item categories is inferred and processed to obtain the interest description features of the object to be recommended for the multiple item categories. Finally, based on the similarity between the item description features and the interest description features, the recommended information to be recommended is recommended for the object to be recommended, and the information recommendation result is generated and returned to the terminal, and the user can preview the information recommendation result returned by the server in the terminal.
[0038] See also Figure 1 , Figure 1 It is a schematic diagram of the architecture of the information recommendation system 100 provided in an embodiment of the present application, including a terminal 500, a network 300 and a server 200. The terminal 500 is connected to the server 200 via the network 300. The network 300 can be a wide area network or a local area network, or a combination of the two.
[0039] In some embodiments, the information recommendation method provided in the embodiments of the present application can be implemented in the terminal 500. When a user initiates an information recommendation request through an application running in the terminal, the terminal can respond to the user's information recommendation request and directly display the information recommendation result in the application of the terminal for the user to preview. For example, when the object to be recommended (for example, a user or other artificial intelligence program) initiates an information recommendation request in the terminal 500, the terminal 500 can directly obtain the information to be recommended, encode the item description information of the information to be recommended, obtain the item description features of the information to be recommended, and generate intelligent prompt information of multiple item categories based on the object information of the object to be recommended and the interactive information of multiple item categories. Next, the intelligent prompt information of multiple item categories is inferred and processed to obtain the interest description features of the object to be recommended for multiple item categories. Finally, based on the similarity between the item description features and the interest description features, the recommended information is recommended for the object to be recommended, and the information recommendation results are generated and displayed directly in the terminal 500 for the object to be recommended to preview.
[0040] In some embodiments, the information recommendation method provided in the embodiments of the present application can be implemented by the terminal 500 and the server 200. For example, various application scenarios are running in the terminal 500, such as instant messaging APP, reading APP, video APP, game APP, or other software programs. When the object to be recommended (for example, a user or other artificial intelligence program) initiates an information recommendation request at the terminal 500 and sends it to the server 200 through the network 300, the server 200 responds to the information recommendation request initiated by the object to be recommended at the terminal 500, and obtains the information to be recommended, encodes the item description information of the information to be recommended, obtains the item description features of the information to be recommended, and generates intelligent prompt information of multiple item categories based on the object information of the object to be recommended and the interactive information of multiple item categories. Next, the intelligent prompt information of various item categories is inferred and processed to obtain the interest description features of the recommended object for various item categories. Finally, based on the similarity between the item description features and the interest description features, the recommended information is recommended to the recommended object. After the information recommendation result is generated, it is returned to the terminal 500 through the network 300. The recommended object (for example, a user or other artificial intelligence program) can receive the information recommendation result returned by the server 200 in the terminal 500.
[0041] In some embodiments, Figure 1The server 200 shown in can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms. The terminal 500 can be an electronic device such as a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, a car terminal, etc., but is not limited to this. The terminal and the server can be directly or indirectly connected by wired or wireless communication, which is not limited in the embodiments of the present application.
[0042] See also Figure 2 , Figure 2 is a schematic diagram of the structure of an electronic device 400 provided in an embodiment of the present application. The electronic device may be Figure 1 The server 200 shown, Figure 2 The electronic device 400 shown includes: at least one processor 410, a memory 450, and at least one network interface 420. The various components in the server 200 are coupled together via a bus system 440. It is understood that the bus system 440 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 440 also includes a power bus, a control bus, and a status signal bus. However, for the sake of clarity, the bus system 440 is not described in detail. Figure 2 Various buses are labeled as bus system 440 .
[0043] The processor 410 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc., where the general-purpose processor can be a microprocessor or any conventional processor, etc.
[0044] The memory 450 may be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state memory, hard disk drives, optical disk drives, etc. The memory 450 may optionally include one or more storage devices that are physically remote from the processor 410.
[0045] The memory 450 includes a volatile memory or a non-volatile memory, and may also include both volatile and non-volatile memories. The non-volatile memory may be a read-only memory (ROM), and the volatile memory may be a random access memory (RAM). The memory 450 described in the embodiments of the present application is intended to include any suitable type of memory.
[0046] In some embodiments, memory 450 can store data to support various operations, examples of which include programs, modules, and data structures, or a subset or superset thereof, as exemplarily described below.
[0047] Operating system 451, including system programs for processing various basic system services and performing hardware-related tasks, such as a framework layer, a core library layer, a driver layer, etc., for implementing various basic services and processing hardware-based tasks;
[0048] A network communication module 452, used to reach other electronic devices via one or more (wired or wireless) network interfaces 420, exemplary network interfaces 420 include: Bluetooth, Wireless Compatibility Certification (WiFi), and Universal Serial Bus (USB), etc.;
[0049] In some embodiments, the device provided in the embodiments of the present application can be implemented in software. Figure 2 The information recommendation device 453 stored in the memory 450 is shown, which can be software in the form of a program and a plug-in, etc., including the following software modules: an encoding module 4531, a generation module 4532, an inference module 4533, and a recommendation module 4534. These modules are logical, and therefore can be arbitrarily combined or further split according to the functions implemented. The functions of each module will be described below.
[0050] In some embodiments, the terminal or server can implement the information recommendation method provided in the embodiment of the present application by running various computer executable instructions or computer programs. For example, computer executable instructions can be microprogram-level commands, machine instructions or software instructions. The computer program can be a native program or software module in the operating system; it can be a local (Native) application (Application, APP), that is, a program that needs to be installed in the operating system to run, such as a live broadcast APP or an instant messaging APP; it can also be a small program that can be embedded in any APP, that is, a program that can be run only by downloading it to a browser environment. In short, the above-mentioned computer executable instructions can be instructions in any form, and the above-mentioned computer program can be an application, module or plug-in in any form.
[0051] The information recommendation method provided in the embodiment of the present application will be explained in combination with the exemplary application and implementation of the server provided in the embodiment of the present application.
[0052] See also Figure 3A , Figure 3A is a flow chart of the information recommendation method provided in the embodiment of the present application, Figure 1 The server 200 shown in FIG. 1 is the execution subject, which will be combined with Figure 3A The steps shown are explained.
[0053] In step 101, encoding processing is performed on at least one item description information of the information to be recommended to obtain at least one item description feature of the information to be recommended.
[0054] In some information recommendation scenarios, when the object to be recommended (for example, a user or other artificial intelligence program) initiates an information recommendation request on the terminal, in response to the information recommendation request initiated by the terminal, at least one information to be recommended will be obtained. The information to be recommended belongs to multiple different item categories, where the item category is the category to which the information to be recommended belongs. For example, if the item category is sports category or entertainment category, then the information to be recommended can be news in the sports category or videos in the entertainment category, etc.
[0055] After obtaining the information to be recommended, the item description information of at least one of the information to be recommended is encoded to obtain at least one item description feature of the information to be recommended. Because it is necessary to recommend the information to be recommended of the corresponding item category according to the interest category of the object to be recommended, it is necessary to extract the features of each information to be recommended. In the embodiment of the present application, the item description information of each information to be recommended is collected, and then the item description information of the information to be recommended is encoded to obtain the item description feature of the information to be recommended.
[0056] In some embodiments, to obtain the item description features of the information to be recommended, the item description information of each information to be recommended may be first subjected to sequence embedding processing to obtain an embedded feature vector of the item description information, and then the embedded feature vector may be subjected to sequence encoding processing to obtain the item description features of each information to be recommended. Specifically, the sequence encoding processing may be implemented by calling a sequence encoding model, and the item description information of each information to be recommended may be first collected, wherein the item description information includes the information title, specific description text, and item category of the information to be recommended, and then the information title, specific description text, and item category in the item description information may be merged into a text sequence. Because the sequence encoding model cannot directly encode the text, it is necessary to perform sequence embedding processing on the text sequence of the item description information to obtain an embedded feature vector of the item description information, wherein the embedding processing may be implemented by calling a word vector model, and the embedded feature vector may be a word vector.
[0057] After obtaining the embedded feature vector of the item description information, the sequence encoder can be called for encoding to obtain the item description features of each information to be recommended. The sequence encoder can be a transformer encoder (Transformer) or a bidirectional encoder representation from transformers (BERT) model based on transformers, and the item description features can be semantic feature vectors. In this way, each information to be recommended can be encoded to obtain the corresponding item description features.
[0058] In addition, in addition to the information title, specific description text and item category of the information to be recommended included in the item description information, the embodiment of the present application also considers other specific item information (i.e., context information) included in the item description information of the information to be recommended, such as the duration of the video, the like rate and the release time of the video of the object to be recommended in the video recommendation scenario. These specific item information can help to give priority to the recommendation of high-quality videos that have just been released. Therefore, when encoding the item description information, in some recommendation scenarios, the specific item information included in the item description information can also be feature constructed. Specifically, these feature item information are discretely encoded, and the specific encoding method depends on the item description features in the scene. For example, a bucketing method can be used to set the time interval of the bucketing to construct a specific description feature for the residence time, such as the interval of the bucketing time is set within 0-2 seconds or 3-30 seconds, and the specific description feature of the item is constructed within each bucketing time. Therefore, the item description features obtained by encoding the information to be recommended can include specific description features, and the specific description features can be used for the training of the information recommendation model, which will be specifically introduced below.
[0059] In step 102, based on the object information of the object to be recommended and the interaction information of the multiple item categories, intelligent prompt information of the multiple item categories is generated.
[0060] In some embodiments, in order to make diversified recommendations for the recommended objects, it is necessary to explore multiple interest categories of the recommended objects. Here, based on the object information of the recommended objects and the interaction information of multiple item categories, intelligent prompt information of multiple item categories can be generated, wherein the object information of the recommended objects is generally the attribute information of the recommended objects, such as basic user information, etc., and the interaction information of multiple item categories is the transaction record or browsing record of the recommended objects in each item category in the previous time period. The intelligent prompt information can be used to input into certain large language models, and the generalization ability and reasoning ability of the large language model are used to generate corresponding interest description texts, and then extract the interest description features of the recommended objects.
[0061] In some embodiments, see Figure 3B , Figure 3A The illustrated step 102 may be implemented by following the steps 1021 to 1022, which are described in detail below.
[0062] In step 1021, system prompt information and the active intention of the object to be recommended with respect to the item category are obtained.
[0063] In some embodiments, after determining the object information of the object to be recommended and the interaction information of multiple item categories, intelligent prompt information for the item category can be generated in combination with the interaction information of each item category. Since the intelligent prompt information is used by the large language model to mine the interest description features of the object to be recommended, the system prompt information and the active intention of the object to be recommended for the item category are also needed when constructing the intelligent prompt information, but these data can be obtained in advance. Therefore, the following processing is performed for each item category to obtain the system prompt information and the active intention of the object to be recommended for the item category, among which the system prompt information is for the large language model to take the role of "recommender" and is used to instruct the large language model to generate or predict. The acquisition method can be automatically generated by the recommendation system or manually constructed.
[0064] For example, a system prompt message may be: "You are a personalized recommendation system. I will tell you the attributes of the recommended object, a list of items in the item category that the recommended object has interacted with before, and some terms that the recommended object has actively searched for. You need to mine his interest preferences from this information and generate a personalized interest description text. This interest description text must be highly consistent with the information I give you."
[0065] The active intention of the recommended object for the item category can be obtained through some active operations of the recommended object in the information recommendation scenario, such as the search record of the recommended object for recommended information of certain item categories in the information recommendation scenario, or the comment score and scoring record of the recommended object for certain item categories. Because the search record and comment score generally reflect some active intentions of the recommended object, it is conducive to exploring the interests of the recommended object. For example, the active intention of a certain recommended object can be: "The current search record of the recommended object is as follows: basketball tactical analysis".
[0066] In step 1022, the system prompt information, the object information of the object to be recommended, the interaction information of the item category, and the active intention are combined to obtain the intelligent prompt information of the item category.
[0067] Following the above embodiment, for each item category, after obtaining the system prompt information and the active intention of the object to be recommended for the item category, it is also necessary to combine the object information of the object to be recommended and the interactive information of the item category to generate the intelligent prompt information corresponding to the item category. Among them, the object information of the object to be recommended is the basic attribute information of the object to be recommended, such as: age, gender, interests and hobbies, and geographical location. The interactive information of the item category is the transaction record or browsing record of the object to be recommended on the item category within a certain period of time. For example, the interactive information of a certain item category is: the interactive record of the object to be recommended under the sports category is as follows: "Finals: Lakers win the championship", "Consecutive goals, Barcelona wins", "Table Tennis World Cup, China wins the championship", etc.
[0068] Next, for each item category, we will generate the intelligent prompt information of the corresponding item category, that is, we will combine the system prompt information, the object information of the object to be recommended, the interactive information of the item category, and the active intention to obtain the intelligent prompt information of the item category. The combination here can be to splice the system prompt information, the object information of the object to be recommended, the interactive information of the item category, and the active intention in a set logical order to obtain the intelligent prompt information of the item category, wherein the set logical order is used to indicate the splicing order of the four texts of the system prompt information, the object information of the object to be recommended, the interactive information of the item category, and the active intention. For example, the set logical order can be the order in which the system prompt information is before the three texts of the object information of the object to be recommended, the interactive information of the item category, and the active intention, and the splicing order of the three texts of the object information of the object to be recommended, the interactive information of the item category, and the active intention can be unlimited. For example, the system prompt information is first used as the text beginning of the intelligent prompt information, and then the three texts of the object information of the object to be recommended, the interactive information of the item category, and the active intention are spliced after the system prompt information, and the intelligent prompt information of the item category can be obtained; the set logical order can also be the order in which the system prompt information is after the three texts of the object information of the object to be recommended, the interactive information of the item category, and the active intention, and the splicing order of the three texts of the object information of the object to be recommended, the interactive information of the item category, and the active intention can be unlimited. In this way, each item category can obtain the intelligent prompt information of the corresponding item category.
[0069] For example, taking the system prompt information before the three texts of the object information of the recommended object, the interaction information of the item category, and the active intention, the intelligent prompt information of a sports category can be: You are a personalized recommendation system, I will tell you the attributes of the recommended object, the list of items of a single category that the recommended object has interacted with before, and some terms that the recommended object has actively searched. You need to mine his interest preferences from this information and generate a personalized user interest description text. This interest description text must be highly consistent with the information I give you, and the label must be very short. The object information of the recommended object is as follows: age group: 20, gender: male, overall interest preference: games, geographical location: Shenzhen. The interaction records of the recommended object in the sports category are as follows: "NBA Finals: Lakers win the championship", "Continuous goals, Barcelona wins", "Table Tennis World Cup: China wins the championship". The search record at the moment when the Chinese team won the championship is as follows: "Basketball tactical analysis".
[0070] Continue to see Figure 3A In step 103, the intelligent prompt information of multiple item categories is inferred and processed to obtain the interest description features of the recommended object for the multiple item categories.
[0071] In some embodiments, see Figure 3C , Figure 3A The illustrated step 103 may be implemented by following steps 1031 to 1033, which are described in detail below.
[0072] In step 1031, based on the intelligent prompt information of the item category, an interest description text of the item category is generated.
[0073] In the following embodiment, after constructing the intelligent prompt information of each item category, the following processing is performed for the intelligent prompt information of each item category: based on the intelligent prompt information of the item category, an interest description text of the item category is generated. Through the intelligent prompt information, the generalization ability and reasoning ability of the language model can be utilized to fully mine the interest category of the object to be recommended, thereby generating the corresponding interest description text. The language model here can be a large language model, because the large language model is generally trained in a large-scale corpus, has rich background knowledge, and can complete the corresponding text task by understanding the semantics of the input text. Therefore, in the embodiment of the present application, the intelligent prompt information can be input as input text into the large language model, so that the large language model understands the semantics of the intelligent prompt information, mines the interest category of the object to be recommended, and generates the corresponding interest description text.
[0074] In some embodiments, see Figure 3D , Figure 3CThe illustrated step 1031 may be implemented by following steps 10311A to 10312A, which are described in detail below.
[0075] In step 10311A, text encoding is performed on the smart prompt information of the item category to obtain a contextual semantic feature vector of the smart prompt information.
[0076] The large language model can specifically be a language model of the Generative Pre-Trained Transformer (GPT) series, which is generally based on multiple transformer encoders (Transformer). In the implementation of this application, the intelligent prompt information of each item category can be input into the large language model, and the encoding part in the large language model can perform text encoding processing on the intelligent prompt information of the item category to obtain the contextual semantic feature vector of the intelligent prompt information. These contextual semantic feature vectors can be recognized by the large language model, so as to understand the semantics of the intelligent prompt information. Among them, the encoding process can be implemented using the encoding part of the transformer encoder in the large language model.
[0077] In step 10312A, text decoding is performed on the context semantic feature vector to obtain the interest description text of the item category.
[0078] After the large language model understands the semantics of the intelligent prompt information and generates the corresponding contextual semantic feature vector, the contextual semantic feature vector is subjected to text decoding processing to obtain the interest description text of the item category. Considering that the task of the large language model is to generate the interest description text corresponding to the intelligent prompt information, that is, to understand the interest category of the object to be recommended, the large language model can use the semantics of the intelligent prompt information to guess the interest category of the recommended object based on its own background knowledge and reasoning ability. Specifically, the contextual semantic feature vector is subjected to text decoding processing through the decoding part of the transformer encoder in the large language model, so as to identify the interest category of the object to be recommended and generate the interest description text of the item category. Here, the interest description text of the item category also represents the interest category of the object to be recommended. Therefore, through the intelligent prompt information of each item category, the large language model can be used to generate the corresponding interest description text, thereby also mining multiple interest categories of the object to be recommended.
[0079] For example, the smart prompt information for a sports category is: You are a personalized recommendation system. I will tell you the attributes of the recommended object, the list of items in a single category that the recommended object has interacted with before, and some terms that the recommended object has actively searched. You need to mine his interest preferences from this information and generate a personalized interest description text for the recommended object. This interest description text must be highly consistent with the information I give you, and the label must be very short. The object information of the recommended object is as follows: age group: 20, gender: male, overall interest preference: games, geographical location: Shenzhen. The interaction records of the recommended object under the sports category are as follows: "NBA Finals: Lakers win the championship", "Continuous goals, Barcelona wins", "Table Tennis World Cup: China wins the championship". The current search record of the recommended object is as follows: "Basketball tactical analysis". After the smart prompt information of this sports category is input into the large language model, the large language model finally generates the corresponding interest description text as "sports games and tactical analysis", that is, the mined interest category of the recommended object is the sports category, indicating that the recommended object is interested in the recommended information in the sports category.
[0080] In some embodiments, see Figure 3E , Figure 3C The illustrated step 1031 may also be implemented by following steps 10311B to 10314B, which are described in detail below.
[0081] In step 10311B, the intelligent prompt information of the item category is segmented to obtain multiple words.
[0082] In some embodiments, considering that the intelligent prompt information of some recommended objects is simple, that is, there are few interaction records of the recommended objects, such as intelligent prompt information of only one item category, indicating that the number of interest categories of the recommended objects is also small, there is no need to use the generalization and reasoning capabilities of the large language model to fully explore multiple interest categories of the recommended objects. Since the item category is single, at this time, for the intelligent prompt information of a single item category, the interest description text can be directly extracted from the intelligent prompt information by extracting text keywords or extracting text summaries.
[0083] The language model used in the method of extracting text keywords or extracting text summaries generally does not require rich background knowledge and strong reasoning ability, so it can be implemented using a simple language model, such as a transformer encoder. First, the intelligent prompt information can be preprocessed, that is, the intelligent prompt information of the item category is segmented to obtain multiple words. In this way, the language model can understand the semantics of each word to determine which words can be used as text keywords or text summaries. The word segmentation process can be implemented using certain word segmentation tools, word segmentation algorithms, or word segmentation libraries.
[0084] In step 10312B, feature extraction is performed on each word to obtain a text feature vector of the word.
[0085] Following the above embodiment, after obtaining multiple words of the intelligent prompt information, the language model can be called to perform feature extraction processing on each word to obtain the text feature vector of the word. Specifically, each word segment is embedded to obtain the word vector of each word, and then the word vector of each word is input into the language model for encoding processing to obtain the text feature vector of each word, wherein the text feature vector can be a semantic feature vector (representing the semantics of the word), a word frequency feature vector (representing the frequency of the word), or a weighted word vector (representing the importance of the word). These text feature vectors can be used to determine whether a word can be used as a keyword or abstract.
[0086] In step 10313B, the text feature vector is mapped to obtain the distribution probability of the word.
[0087] Following the above embodiment, after extracting the text feature vector of each word, the fully connected layer of the language model is called, and the text feature vector is mapped using the activation function of the fully connected layer to obtain the distribution probability of the word. The distribution probability of a word is the probability of the word being a keyword or abstract.
[0088] In step 10314B, multiple words whose distribution probabilities are greater than the probability threshold are combined to obtain the interest description text of the item category.
[0089] After determining the distribution probability of each word, a probability threshold can be preset to filter out the most suitable words as keywords or text summaries from multiple words. The screening criterion is that when the distribution probability of a word is greater than the probability threshold, it means that the word is most suitable as a keyword or text summary. Thus, multiple words suitable as keywords or text summaries can be determined, and finally multiple words with distribution probabilities greater than the probability threshold are combined to obtain the interest description text, that is, multiple words with distribution probabilities greater than the probability threshold are combined to obtain the interest description text.
[0090] For example, the smart prompt information for a sports category can be: You are a personalized recommendation system. I will tell you the attributes of the recommended object, the list of single-category items that the recommended object has interacted with before, and some terms that the recommended object has actively searched. You need to mine his interest preferences from this information and generate a personalized interest description text for the recommended object. This interest description text must be highly consistent with the information I give you, and the label must be very short. The object information of the recommended object is as follows: age group: 20, gender: male, overall interest preference: games, geographical location: Shenzhen. The interaction records of the recommended object under the sports category are as follows: "NBA Finals: Lakers win the championship", "Continuous goals, Barcelona wins", "Table Tennis World Cup: China wins the championship". The current search record of the recommended object is as follows: "Basketball tactical analysis". By segmenting this smart prompt information to obtain multiple words, each word is subjected to feature extraction processing to obtain the text feature vector of the word, and then the text feature vector of each word is mapped to obtain the distribution probability of the word. A probability threshold can be preset, such as 0.9. Finally, the words with a distribution probability greater than 0.9 are selected as "sports, tactical analysis", so "sports tactical analysis" can be used as the interest description text corresponding to the intelligent prompt information.
[0091] Continue to see Figure 3C , in step 1032, text embedding processing is performed on the interest description text of the item category to obtain an embedded feature vector of the interest description text.
[0092] After generating the corresponding interest description text according to the intelligent prompt information, the interest description features of the object to be recommended can be extracted from the interest description text. Since this interest description feature is used to characterize the interest category of the object to be recommended, the semantic features of the interest description text can be directly extracted as the interest description feature. However, the transformer encoder cannot process the text directly, so it is necessary to perform text embedding processing on the interest description text of the item category to obtain the embedded feature vector of the interest description text. Among them, the text embedding processing can be implemented by calling the word vector model, such as the word2vec word vector model, which converts the text characters into the corresponding word vectors, and then performs encoding processing to extract the interest description features.
[0093] In step 1033, the embedded feature vector of the interest description text is encoded to obtain the interest description feature of the object to be recommended for the item category.
[0094] In some embodiments, the encoding process of extracting the semantic features of the interest description text is implemented by an encoder, which can be a transformer encoder (Transformer), which includes multiple hidden layers, each hidden layer is a small encoder, and each editor includes an attention mechanism layer and a feedforward network layer, which are used to encode the input embedded feature vector, and then input the output feature vector into the next encoder for encoding, until the output of the encoder of the last hidden layer is the final feature vector, and this final feature vector can be used as the interest description feature. The specific processing process of one of the small encoders is described in detail below.
[0095] In some embodiments, see Figure 3F , Figure 3C The illustrated step 1033 may be implemented by following the steps 10331 to 10334, which are described in detail below.
[0096] In step 10331, the position feature vector of the embedded feature vector of the interest description text is determined, and the position feature is merged with the embedded feature vector to obtain a first fused feature vector.
[0097] In some embodiments, since each word in the interest description text has a sequence relationship, this sequence relationship may affect the semantics of the word, so it is necessary to integrate the corresponding position feature vector into the embedded feature vector of the interest description text. In the embodiment of the present application, the position feature vector of the embedded feature vector of the interest description text is determined, and the position feature is merged with the embedded feature vector to obtain a first fused feature vector, that is, the position feature vector corresponding to the embedded feature vector of each word in the interest description text is determined, and then the embedded feature vector of each word is merged with the position feature vector, wherein the merging process can be to add the vector values at the same position or to physically splice the vectors directly, so as to obtain the fused feature vector of the interest description text.
[0098] In step 10332, the first fused feature is processed by the attention mechanism layer to obtain the attention tensor of the first fused feature vector.
[0099] Following the above embodiment, after obtaining the first fused feature vector of the interest description text, the first fused feature vector can be input into the encoder attention mechanism layer, and the first fused feature is processed by the attention mechanism layer to obtain the attention tensor of the first fused feature vector. Among them, the attention mechanism processing can be to input the first fused feature vector of each word, and map it through three weight matrices respectively, so that each word can obtain three vectors, namely, key vector (Keys), value vector (Values) and query vector (Queries). Then, the attention calculation is performed through the key vector, value vector and query vector, and finally the attention tensor of each word is obtained and merged to obtain the attention tensor of the first fused feature vector.
[0100] In some embodiments, a multi-head attention mechanism can be used in the attention mechanism layer, that is, the first fusion vector is processed with the attention mechanism multiple times, and each word can obtain multiple sets of key vectors, value vectors and query vectors. Finally, multiple attention tensors are calculated, and then the multiple attention tensors are spliced to obtain the attention tensor of each word, thereby also obtaining the attention tensor of the first fusion feature vector.
[0101] In step 10333, the first fused feature vector is merged with the attention tensor to obtain a second fused feature vector.
[0102] After the first fused feature vector of the interest description text is processed by the attention mechanism, the corresponding attention tensor is obtained, and then the attention tensor is input into the residual module for residual processing. The residual processing process is to merge the first fused feature vector with the attention tensor to obtain the second fused feature vector. That is, the first fused feature vector and the attention tensor processed by the attention mechanism are merged to obtain the second fused feature vector.
[0103] In step 10334, the second fused feature vector is mapped through a feed-forward network layer to obtain interest description features of the object to be recommended for the item category.
[0104] After the first fused feature vector is subjected to residual processing to obtain the second fused feature vector, the second fused feature vector can be input into the feedforward network layer of the encoder, and the second fused feature vector is mapped through the feedforward network layer to obtain the interest description features of the recommended object for the item category. Considering that the fitting degree of the attention mechanism layer is not enough, the second fused feature vector is mapped through the two-layer linear fully connected neural network layer of the feedforward network layer, and the second fused feature vector is preliminarily fitted through the weight matrix of the first fully connected neural network layer, and then the second fused feature vector is further fitted using the activation function and input into the second fully connected neural network layer, and the final fitting is performed through the corresponding weight matrix to obtain the fitted feature vector.
[0105] The feature vector output by the feedforward network is then input into the residual module for residual processing, that is, the output feature vector is merged with the second fused feature vector to obtain the feature vector finally output by the encoder, and input into the next small encoder to continue similar encoding processing until the last small encoder outputs the corresponding feature vector, which is the interest description feature of the interest description text.
[0106] Through the embodiments of the present application, the object information of the object to be recommended and the interaction information of multiple item categories are used to generate intelligent prompt information of multiple item categories. That is, multiple intelligent prompt information can be generated through the interaction information of multiple item categories, and then the intelligent prompt information of multiple item categories is inferred and processed to obtain the interest description features of the object to be recommended for multiple item categories, so as to mine multiple interest categories of the object to be recommended, and provide a basis for the candidate to make diversified recommendations of multiple item categories for multiple interest categories.
[0107] Continue to see Figure 3A In step 104, based on the similarity between the item description feature and the interest description feature, a recommendation operation of at least one information to be recommended is performed on the recommended object.
[0108] In some embodiments, after determining the interest description features corresponding to the interest description text of each item category, the recommendation operation can be performed for the recommended object according to the interest description features of each item category. First, the recommended information to be recommended is determined according to the interest description features, and the similarity between the interest description features and the item description features of the recommended information is calculated to determine the recommended information to be recommended, which is used to perform the recommendation operation on the recommended object, as described in detail below.
[0109] In some embodiments, see Figure 3G , Figure 3A The illustrated step 104 may be implemented by following steps 1041A to 1043A, which are described in detail below.
[0110] In step 1041A, a first similarity between the interest description feature of the item category and the item description feature of each information to be recommended is determined.
[0111] Because there are interest description features of multiple item categories, and these item categories are all interest categories that the recommended objects are interested in, it is also necessary to recommend information to be recommended of multiple item categories. Therefore, in the embodiment of the present application, the following processing is performed for each item category: determine the first similarity between the interest description features of the item category and the item description features of each information to be recommended. Specifically, for each item category, the first similarity between the interest description features of the current item category and the item description features of all the information to be recommended in the current category is calculated respectively, that is, a first similarity can be calculated for each information to be recommended. The higher the first similarity, the more consistent the information to be recommended is with the interests of the recommended object. The first similarity with the item description features of all the information to be recommended in the current category is calculated here to adapt the item category of the information to be recommended to the interest category corresponding to the recommended object, so as to make targeted recommendations.
[0112] For example, if a certain object to be recommended has two interest description features of sports and entertainment categories, then the first similarities between the interest description features of the sports category and the item description features of 10,000 items to be recommended in the sports category are calculated, thereby obtaining 10,000 first similarities. Similarly, the first similarities between the interest description features of the entertainment category and the item description features of 10,000 items to be recommended in the entertainment category are calculated, thereby obtaining 10,000 first similarities. Finally, based on the sports category and the entertainment category, 20,000 first similarities can be calculated.
[0113] In step 1042A, based on the first similarity, a portion of the information to be recommended is filtered out from at least one piece of information to be recommended.
[0114] After determining the first similarity between the interest description feature and the information to be recommended, part of the information to be recommended can be filtered out from at least one information to be recommended according to the first similarity. Specifically, for each item category, at least one information to be recommended is sorted in descending order according to the first similarity between each information to be recommended and the interest description feature of the corresponding item category to obtain a sequence of information to be recommended, that is, the information to be recommended with a high first similarity is arranged at the front of the sequence of information to be recommended, and the information to be recommended with a low first similarity is arranged at the back of the sequence of information to be recommended. In the embodiment of the present application, a recommendation quantity can be preset, that is, the number of information to be recommended recommended for the recommended object, for example, K, and K information to be recommended are selected from the head of the sequence of information to be recommended as part of the information to be recommended. In this way, part of the information to be recommended can be filtered out corresponding to each item category.
[0115] In some embodiments, the embodiments of the present application can set a preset similarity threshold for each item category, or uniformly set a similarity threshold for all item categories, and after determining the first similarity between the interest description feature and the information to be recommended, then for each item category, directly filter out the information to be recommended whose first similarity is greater than the similarity threshold of the corresponding item category from at least one information to be recommended, and obtain part of the information to be recommended. In this way, each item category can also filter out part of the information to be recommended.
[0116] In step 1043A, target information to be recommended is screened out from the partial information to be recommended corresponding to the multiple item categories, and a recommendation operation is performed on the recommended object based on the target information to be recommended.
[0117] After filtering out part of the information to be recommended for each item category, the target information to be recommended is filtered out from the partial information to be recommended corresponding to the multiple item categories, and the recommendation operation is performed on the recommended object based on the target information to be recommended. Because the amount of information to be recommended is limited, and it is necessary to ensure that the information to be recommended to the recommended object has multiple item categories, a certain amount of target information to be recommended can be filtered out from the partial information to be recommended corresponding to the multiple item categories, that is, a certain amount of target information to be recommended can be filtered out from the partial information to be recommended for each item category. Finally, the target information to be recommended of all item categories is combined, and the recommendation operation is performed on the recommended object.
[0118] For example, according to the first similarity of 10,000 pieces of information to be recommended in the sports category, 500 pieces of information to be recommended are selected, and according to the first similarity of 10,000 pieces of information to be recommended in the entertainment category, 500 pieces of information to be recommended are also selected. At this time, the total number of recommended information to be recommended for the recommended object is 100, so 50 target information to be recommended is selected from the 500 pieces of information to be recommended in the sports category, and at the same time, 50 target information to be recommended is selected from the 500 pieces of information to be recommended in the entertainment category, and 100 target information to be recommended is obtained in combination for information recommendation to the recommended object.
[0119] In some embodiments, see Figure 3H , Figure 3A The illustrated step 104 may also be implemented by the following steps 1041B to 1043B, which are described in detail below.
[0120] In step 1041B, the average value of the first similarity between the interest description feature of each item category and the item description feature of each information to be recommended is determined.
[0121] In some embodiments, considering that the interest categories of the recommended objects have different focuses, it is necessary to make diversified recommendations while making targeted recommendations. Therefore, in the embodiments of the present application, the number of item categories of the recommended information can also be adjusted, that is, the item categories that are more in line with the interests of the recommended objects will be recommended. More information of this item category will be recommended. Specifically, the average value of the first similarity between the interest description feature of each item category and the item description feature of each information to be recommended is determined, that is, for each item category, the first similarity between the interest description feature of the item category and the item description feature of each information to be recommended is first determined, and then the average value of the first similarity is calculated, so that an average value of the first similarity can be calculated for each item category.
[0122] For example, if a certain object to be recommended has two interest description features of sports and entertainment, then the first similarities between the interest description features of the sports category and the item description features of 10,000 items to be recommended in the sports category are calculated, thereby obtaining 10,000 first similarities, and then the average value of these 10,000 first similarities is calculated as the first similarity average value of the sports category. Similarly, the first similarities between the interest description features of the entertainment category and the item description features of 10,000 items to be recommended in the entertainment category are calculated, thereby obtaining 10,000 first similarities, and the average value of these 10,000 first similarities is also calculated as the first similarity average value of the entertainment category.
[0123] In step 1042B, based on the average value, the proportion of the number of to-be-recommended information corresponding to each item category to the total number of recommendations is determined.
[0124] Following the above embodiment, the average value of the first similarity between the interest description feature of each item category and the item description feature of each information to be recommended, that is, the average value of the first similarity of each item category, is determined. Based on the average value, the proportion of the number of information to be recommended corresponding to each item category to the total number of recommendations is determined. The total number of recommendations represents the number of information to be recommended recommended to the recommended object, and the proportion is positively correlated with the average value.
[0125] For example, the average first similarity of 10,000 pieces of sports category information to be recommended is 0.8, and the average first similarity of 10,000 pieces of entertainment category information to be recommended is 0.9. Based on these two averages, it is determined that the proportion of the number of sports category information to be recommended is 0.6, and the proportion of the number of entertainment category information to be recommended is 0.4. The average value and the proportion are positively correlated. The higher the average value, the more consistent the item category is with the interests of the recommended object, and a larger proportion of the corresponding information to be recommended is allocated when performing the recommendation operation. For example, when performing the recommendation operation, 60% of the information to be recommended is allocated to the sports category, while 40% of the information to be recommended is allocated to the entertainment category.
[0126] In step 1043B, based on the ratio and the first similarity, target information to be recommended is screened out from at least one piece of information to be recommended, and a recommendation operation is performed on the object to be recommended based on the target information to be recommended.
[0127] After determining the ratio of the number of recommended information corresponding to each item category to the total number of recommendations, the target recommended information can be screened out from at least one piece of recommended information based on the ratio and the first similarity, and the recommended object can be recommended based on the target recommended information. Specifically, first, based on the first similarity, a portion of the recommended information is screened out from at least one piece of recommended information, and then the target recommended information is screened out from the portion of the recommended information corresponding to the multiple item categories. The screening process is the same as Figure 3G Step 1042A is similar to step 1043A and will not be described again. Next, according to the ratio of the number of recommended information corresponding to each item category to the total number of recommendations, the number of target recommended information for each item category is adjusted to reasonably distribute the information.
[0128] For example, during the recommendation operation, the sports category is allocated 60% of the information to be recommended, while the entertainment category is allocated 40% of the information to be recommended. Then, based on the first similarity of the 10,000 information to be recommended in the sports category, 500 pieces of partial information to be recommended are screened out, and based on the first similarity of the 10,000 information to be recommended in the entertainment category, 500 pieces of partial information to be recommended are screened out. At this time, the total number of recommended information to be recommended for the recommended objects is 100. It is expected that 50 target information to be recommended will be screened out from the 500 sports category information to be recommended, and at the same time, 50 target information to be recommended will be screened out from the 500 entertainment category information to be recommended. However, at this time, the number of target information to be recommended for each item category needs to be adjusted according to the allocation ratio to ensure reasonable allocation. Therefore, 60 target information to be recommended are screened out from the 500 sports category information to be recommended, and 40 target information to be recommended are screened out from the 500 entertainment category information to be recommended. A total of 100 target information to be recommended are obtained and used for information recommendation operations on the recommended objects.
[0129] It should be noted that Figure 3A The execution order of step 101 and step 102 shown is not in particular order, and can be executed serially or in parallel. The specific order or sequence can be interchanged where permitted, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein. For the convenience of explanation, the embodiments of the present application arrange the corresponding steps for different processing, but this should not be regarded as a limitation on the execution order.
[0130] Through the embodiments of the present application, the recommendation operation is performed on the recommended object by determining the similarity between the item description features and the interest description features. In this way, it is possible to recommend information corresponding to multiple item categories for the multiple interest categories of the mined recommended object, while performing personalized recommendations on the recommended object, and achieving diversified recommendations to improve the information recommendation effect. In addition, the recommendation ratio of each item category is determined according to the similarity to adjust the amount of recommended information for each item category, while achieving diversified recommendations, and better meeting the interest needs of the recommended object, further improving the information recommendation effect.
[0131] In some embodiments, Figure 3AThe recommendation operation in step 104 shown can be implemented by calling an information recommendation model. This information recommendation model can be pre-trained and can be used to directly perform information recommendation operations on the recommended object. The training method of the information recommendation model is introduced below. Before training the information recommendation model, it is necessary to obtain the information sample to be recommended and the interest description text of multiple item categories; forward propagate the information sample to be recommended in the information recommendation model to obtain the item description features of the information sample to be recommended, and forward propagate the interest description text in the information recommendation model to obtain the interest description features of multiple item categories; determine the loss value of the information recommendation model based on the item description features, the interest description features of multiple item categories, and the recommended labels of the information sample to be recommended; and back propagate in the information recommendation model through the loss value to update the parameters of the information recommendation model.
[0132] Specifically, first obtain samples of information to be recommended. These samples are information to be recommended of multiple categories of items, and the number of samples in each category is balanced. In addition, these samples carry recommendation tags, which are used to characterize whether the samples are suitable for recommendation for the item category. For the interest description texts of multiple item categories, we can first collect the interaction information of each item category of the recommended object and the active intention of each item category, and then combine the system prompt information and the object information of the recommended object to obtain intelligent prompt information of multiple item categories, and then input it into the large language model to generate interest description texts of multiple item categories.
[0133] Next, the information sample to be recommended is forward propagated in the information recommendation model, that is, the information sample to be recommended is encoded through the information recommendation model to obtain the item description features of the information sample to be recommended. The interest description texts of multiple item categories are forward propagated in the information recommendation model, that is, the interest description texts of multiple item categories are encoded to obtain the interest description features of multiple item categories. Finally, the loss value of the information recommendation model is constructed through the item description features, the interest description features of multiple item categories, and the recommended labels of the information sample to be recommended, and the loss value is back-propagated in the information recommendation model to update the parameters of the information recommendation model. When the loss value of the information recommendation model no longer decreases or reaches the specified number of iterations, the training stops.
[0134] In some embodiments, the process of determining the loss value of an information recommendation model based on item description features, interest description features of multiple item categories, and recommended tags of information samples to be recommended may be: determining the feature similarity between the interest description features of any item category and the item description features; constructing a first loss value of the information recommendation model based on the feature similarity and the recommended tags of the information samples to be recommended; constructing a second loss value of the information recommendation model based on the interest description features of multiple item categories; and determining the loss value of the information recommendation model based on the first loss value and the second loss value, as described in detail below.
[0135] Because the information recommendation model not only needs to make personalized recommendations for the objects to be recommended, that is, recommend the information to be recommended that the objects to be recommended are interested in, but also needs to make diversified recommendations for the objects to be recommended to meet the different interest needs of the objects to be recommended. Therefore, for personalized recommendations, it is necessary to determine the feature similarity (i.e., the similarity in the above text) between the interest description features and the item description features of any item category. Next, the first loss value of the information recommendation model is constructed based on the feature similarity and the recommended label of the information sample to be recommended. Considering that the information samples to be recommended of certain item categories may also include specific descriptive features (such as residence time, denoted as t), a weight feature can be preset to weight the specific descriptive features, and the weighted specific descriptive features and feature similarity are added to obtain the recommendation score of the information sample to be recommended. If the information samples to be recommended of certain item categories do not have specific descriptive features, the feature similarity is directly used as the recommendation score of the information sample to be recommended. After determining the recommendation score of the information sample to be recommended, a cross entropy loss function can be constructed based on the recommendation score as the first loss value of the information recommendation model. The specific formula is as follows:
[0136]
[0137] In the above formula (1), is a cross entropy loss function, r i,t The table represents the recommendation score of the i-th recommended information sample at the residence time t, y i,t represents the recommended label corresponding to the i-th information sample to be recommended at the residence time t, I represents the total number of information samples to be recommended, when the i-th information sample to be recommended is a positive sample, that is, when the information sample to be recommended is suitable for recommendation for this item category, y i,t is 1 if the value is true, otherwise it is 0.
[0138] For diversified recommendation, the second loss value of the information recommendation model can be constructed through the interest description features of all item categories. Because diversified recommendation needs to satisfy the different interest categories of the recommended objects, the second loss value of the information recommendation model is constructed through the interest description features of all item categories in the embodiment of the present application, so that the information recommendation model can learn the interest description features of different item categories and can recommend multiple item categories to the recommended objects. The specific formula for constructing the second loss value is as follows:
[0139]
[0140] In the above formula (2), P f With P q They represent the interest description features of item category f and item category q respectively, and C represents the set of all item categories.
[0141] After determining the first loss value of the model to be recommended for personalized recommendation and the second loss value for diversified recommendation, the first loss value and the second loss value can be directly added to obtain the loss value of the information recommendation model. Corresponding weights can be assigned to the first loss value and the second loss value according to the focus of the recommendation operation. For example, if this recommendation operation focuses on personalized recommendation, a high weight, such as 0.6, is assigned to the first loss value, and a low weight, such as 0.4, is assigned to the second loss value. If this recommendation operation focuses on diversified recommendation, a low weight, such as 0.3, is assigned to the first loss value, and a high weight, such as 0.7, is assigned to the second loss value. The first loss value and the second loss value are weighted by the corresponding weights, and the weighted results of the two are summed to obtain the loss value of the information recommendation model.
[0142] Through the embodiments of the present application, samples of information to be recommended and interest description texts of multiple item categories are obtained to train the information recommendation model, a first loss value is constructed by the feature similarity between the interest description features of any item category and the item description features, and a second loss value is constructed by the interest description features of multiple item categories, and a final loss value of the information recommendation model is constructed by the first loss value and the second loss value, so that the information recommendation model can make personalized recommendations for the objects to be recommended and diversified recommendations for the objects to be recommended, thereby improving the diversity of information recommendation and enriching the information recommendation results.
[0143] The following is an explanation of an exemplary application of an embodiment of the present application in a practical application scenario.
[0144] In some information recommendation scenarios, such as item recommendation, a pre-trained language model is generally used to build a recommendation system to make personalized recommendations based on user interests. However, in most scenarios, the number of materials usually reaches millions, so improving the diversity of recommendations is crucial to mining user interests. In related technologies, pre-trained language models are limited to small-scale language models, such as the Bidirectional Encoder Represe ntation from Transformers (BERT) model based on transformers. Compared with the large language models of the Generative Pre-Trai ned Transformer (GPT) series, the parameters of pre-trained language models are relatively small and the background dependency knowledge is relatively lacking, which makes their reasoning ability limited and unable to mine the user's interest intentions. Although the methods based on large language models aim to predict user preferences or transfer rich background dependency knowledge from text corpora, they have certain deficiencies in the diversity of the recall stage. On the one hand, the recommendation method based on large language models considers the user interaction behavior sequence as a whole, and cannot fully decouple the user's multiple interest intentions. This means that in the recall phase, it is likely that only items similar to the user's past behavior will be recommended, while ignoring other potential interests that the user may have. On the other hand, all recommendation methods based on large language models need to be fine-tuned based on the pre-trained large model, but some large language models do not support fine-tuning or the fine-tuning process requires a lot of time cost.
[0145] Based on the above scenario, the embodiment of the present application provides an item recommendation method (implemented by an information recommendation method), which can better capture the user's interest preferences in different item categories by processing items (i.e., information to be recommended) in batches according to categories. Secondly, the model used can use only the parameter amount of the traditional recommendation model (various features on the item side and parameters on the encoder side) in the training phase, and can also use the powerful reasoning and generalization capabilities of the large language model, so as to generate diverse user interests in the recall phase, improve the user's interactive experience, and can be deployed in general recommendation scenarios at a lower cost.
[0146] In the item recommendation method of the embodiment of the present application, the first step is to construct the item information. First, a language model is selected, such as the Bidirectional Encoder Representation from Transformers (BERT) model, as the basic model of the recommendation system. Then the description information of all items in the scene is encoded, including the title, description, category, etc. of the item. By using the language model, the semantic representation vector corresponding to the item information (equivalent to the item description feature above) can be extracted as a high-dimensional space vector describing the item information itself. The semantic representation vector of each item is e i ∈R 1×d (Where d represents the dimension of the semantic representation vector, and i represents the i-th item.) Next, the semantic representation vectors of all items are stored in a search library, such as a similarity vector retrieval library (Facebook AI Similarity Search, Faiss), and corresponding indexes are created for use in subsequent vector retrieval. In this way, these indexes can be used in the recommendation framework to retrieve items in the recall phase.
[0147] The embodiments of the present application also consider other important specific item information included in the item description information, such as the user's dwell time on the video, the like rate, and the release time of the video in the video recommendation scenario. This information is very critical in the recall stage because it can help prioritize the recommendation of high-quality videos that have just been released. Therefore, in addition to encoding the item description information, features of these important specific item information are also constructed. Specifically, this information is discretely encoded, and the specific encoding method depends on the characteristics of the items in the scene. For example, a bucketing method can be used to set the time interval of the buckets to construct item features for the dwell time. For example, the interval of the bucket time is set to 0-2 seconds or 3-30 seconds. A specific feature vector of the item is constructed within each bucket time, and e is used. i,v ∈R 1×d To represent the specific feature vector of the item.
[0148] Through the above-mentioned item-side information construction, we can make full use of the large language model to extract the semantic representation vector of the item description information, and combine it with other important item information for recommendation in the recall stage.
[0149] Since it is necessary to mine the user's intention when recommending items, in the embodiment of the present application, prompt words (equivalent to the intelligent prompt information above) are constructed based on object attribute information and user interaction behavior records under a single item category, so as to utilize the generalization ability of the large semantic model to generate user diversified interest description texts based on prompt words. In a general scenario, in addition to constructing prompt words based on user interaction data, in order to generate a more fine-grained personalized interest description of the user, the characteristics of the object attribute information and some active intentions (such as an active search operation) are also considered. Then, the rich semantic knowledge and reasoning generalization ability of the large language model are utilized to directly generate the user's current interest description text. Among them, the construction of prompt words is crucial, because its quality directly affects the generation ability of the model. In the embodiment of the present application, the prompt word construction is realized by system prompts, object attributes, user single category interaction records and user's active intentions, which are described in detail below.
[0150] Regarding the system prompts, the system prompts are used to construct prompt words in the embodiment of the present application in order to allow the large language model to take on the role of "recommender", tell the large language model the precise task description, and output the results in the prescribed format.
[0151] For example, a system prompt can be described as: "You are a personalized recommendation system. I will tell you the user's attributes, a list of single-category items that the user has interacted with before, and some terms that the user has actively searched for. You need to mine his interest preferences from this information and generate a personalized user interest description text. This interest description text must be highly consistent with the information I give you."
[0152] For object attributes, it specifically includes user attribute information, such as gender, age, geographic location, etc. These attribute information can be used as part of the prompt words to help the model generate diversified interest description texts related to object attributes. Because even if the interaction records of two users are the same, due to the introduction of user configuration information, the generated user interest descriptions will be different. Using the user's attribute information can accurately generate interest description texts related to object attributes. The following is a prompt word structure for an object attribute: "The user's attributes are as follows: age group: [], gender [], overall interest preference [], geographic location []".
[0153] For user single-category interaction records, the user's interaction records in a specific item category are used as prompt words so that the model can better generate interest description text related to the category. User single-category interaction records reflect the user's current interest preferences in a certain item category. Prompt words are used according to item categories to generate diverse interest descriptions to ensure that user interests are not coupled. The following is a user's prompt word construction in a single category: "The user's interaction records in the sports category are as follows: "Finals: Lakers win the championship", "Continuous goals, Barcelona wins", "Table Tennis World Cup wins", "Manchester United reverses and wins, enters the Champions League final", "Tennis Grand Slam: Nadal wins".
[0154] For the user's active intention, the user's interaction record provides implicit feedback, reflecting the user's current preference, but the user's active rating or search often reflects the user's strong current intention. Consider the user's active dialogue or active search operation, and use the user's intention as part of the prompt word. In this way, the large language model can better understand the user's current interests and needs, so it is also integrated into the construction of the prompt word. The following is a prompt word construction of a user's active intention: "The user's current search record is as follows: basketball tactical analysis".
[0155] After completing the construction of the prompt word, in the embodiment of the present application, the complete prompt word is used as input, and the generalization and reasoning capabilities of the large language model are used to generate the user's personalized preference description text under the current category (equivalent to the interest description text above). The sports category and the new entertainment category are used as examples for illustration.
[0156] The prompt word description constructed under the sports category is: You are a personalized recommendation system. I will tell you the user's attributes, the list of single-category items that the user has interacted with before, and some terms that the user has actively searched. You need to mine his interest preferences from this information and generate a personalized user interest description text. This interest description text must be highly consistent with the information I give you, and the label must be very short. The user's attributes are as follows: age group: 20, gender: male, overall interest preference: games, geographical location: Shenzhen. The user's interaction records under the sports category are as follows: "NBA Finals: Lakers win the championship", "Continuous goals, Barcelona wins", "Table Tennis World Cup: China wins the championship", "Manchester United reverses and wins, enters the Champions League final", "Tennis Grand Slam: Nadal wins the championship". The user's current search record is as follows: "Basketball tactical analysis". Then this prompt word is input into the large language model. The large language model outputs the user's interest description text under the sports category according to the prompt word: "Sports games and tactical analysis". It can be seen that the generated interest description text is also consistent with the user's interests and hobbies.
[0157] The prompt word description constructed under the entertainment category is: You are a personalized recommendation system. I will tell you the user's attributes, the list of single-category items that the user has interacted with before, and some terms that the user has actively searched for. You need to mine his interest preferences from this information and generate a personalized user interest description. This interest description must be highly consistent with the information I give you, and the label must be very brief. The user's attributes are as follows: age group: 20, gender: male, overall interest preference: games, geographic location: Shenzhen. The user's interaction records under the sports category are as follows: "Marvel's new movie: Black Widow", "Game of Thrones Final Season: Who will sit on the Iron Throne", "Pop Music Charts: Top 10 this week", "Variety show Idol Producer Season 2 starts", "The movie Fast and Furious 9 is released and breaks the global box office record". The user's current search record is as follows: "Introduction to the players of Idol Producer Season 2". Then this prompt word is input into the large language model. The large language model outputs the user's interest description text under the entertainment category based on the prompt word: "Multiple entertainment selections", from which it can be seen that the generated interest description text is also consistent with the user's interests and hobbies.
[0158] In all categories, the large language model can generate the user's interest description text in the category based on the constructed prompt words, so that the user's diverse interest description text can be obtained. Then the vector representation of these interest description texts can be extracted and searched in the similar vector retrieval library (Faiss) to recall items related to the user's interest description text.
[0159] After the large language model generates the diversified user interest description text, it is then encoded using a text encoder (such as BER T or Transformer), and the last hidden state is used as the vector representation of the user interest description text. Finally, Faiss is used to calculate the similarity to recommend the corresponding items. Specifically, the user interest description text generated by the large language model is encoded using a text encoder to obtain the corresponding user interest description text feature vector p f , and then calculate the user interest description text feature vector p f The semantic feature vector corresponding to the item information (ie, ei∈R 1×d ), denoted as The items that match the user's interests are determined by similarity. The similarity here can be calculated by the cosine distance of two feature vectors, which is used to represent the user's recommendation score for the item. The higher the similarity, the more the item matches the user's interest description, and the higher the recommendation score.
[0160] In addition to considering the user's interest description, the embodiment of the present application also considers other important item information in the item description information, such as the like rate, the stay time, and the creation time. For example, if a piece of news has a high like rate and is not created for a long time, then the recommendation rate of this news should be higher than other news. In order to correct the consistency of item recommendations, the embodiment of the present application introduces attribute feature deviation in the similarity, and the recommendation score obtained is shown in formula (3):
[0161]
[0162] In the above formula (3), p f represents the vector representation of user interest description generated by the large language model, t represents the residence time, f represents the item category, and e represents the user interest description generated by the large language model. i Represents the semantic feature vector corresponding to the i-th candidate item information, Indicates the similarity between the two, e i,v Represents the specific feature vector (like rate, etc.) of the i-th candidate item, Represents a trainable vector. It is worth noting that even if the user does not have many interactive behavior records and only has one category of interest description text, the knowledge and semantic understanding capabilities of the large language model can still be used to enrich the recommendation results. This helps improve the accuracy of recall and user satisfaction, while presenting users with more diverse choices.
[0163] After determining the recommendation scores of related items, it is necessary to optimize the corresponding model parameters during model training, such as the parameters of the text encoder (BERT or Transformer) and the parameters of the semantic feature vector corresponding to the item information. The loss function of the model training is based on the recommendation score r. i,t To construct, as shown in the following formula (4):
[0164]
[0165] In the above formula (4), is a cross entropy loss function, r i,t The table represents the recommendation score of the i-th candidate item at the residence time t, I represents the total number of candidate items, y i,t represents the recommended label corresponding to the i-th candidate item at the residence time t. When the i-th candidate item information is a positive sample, y i,t is 1 if the value is true, otherwise it is 0.
[0166] In order to make the large language model generate user interest description text in a diversified trend, the embodiment of the present application also constructs The loss function is shown in the following formula (5):
[0167]
[0168] In the above formula (5), P f With P q represents the vector representation of user interest description texts under different categories, and C represents the collection of interest description texts under all categories generated by the large language model for the current user.
[0169] The loss function of the final model is and The sum of That is, we need to recommend items that match the user's interests based on the interest description text, and make the large language model generate user interest description texts in a diversified trend of item categories. The loss function of the model is As shown in the following formula (6):
[0170]
[0171] When the model is predicted, that is, in the recall stage of item recommendation, the recommendation score r of an item in a certain category can be directly used. i,t Sort each candidate item in the candidate item sequence under the category, or map the recommendation score to a recommendation probability, and then sort each candidate item in the candidate item sequence according to the recommendation probability. The higher the recommendation score, the higher the mapped recommendation probability, which means that the candidate item is more in line with the user's interests and needs, and the higher it is ranked in the candidate item sequence, making it easier for users to find items that meet their interests and needs.
[0172] Through the embodiment of the present application, the rich semantic knowledge of the large language model can be used to infer the user's potential interests from limited user interaction data, extract the user's interest description text under a specific category, and thus better understand the user's interest preferences. This makes it possible to provide users with a wider range of and more diverse recommendation results, and for cold-start users, it is also possible to provide personalized recommendations for cold-start users, thereby improving the effect of the recommendation system and user experience. The large language model framework is introduced into the recall stage in a general scenario, which effectively solves the user's multi-interest coupling problem, improves the diversity of user recommendations, and is conducive to mining more potential user interests. In addition, the item information is processed in batches according to categories, which can better capture the user's interest preferences under different categories. The model can use only the parameter amount of the traditional recommendation model (i.e., various semantic features on the item side and parameters on the text encoder side) in the training stage, and can also use the powerful reasoning and generalization capabilities of the large language model to generate diverse user interests in the recall stage, without fine-tuning the large language model, and can be deployed in general scenarios at a lower cost.
[0173] The following is a description of an exemplary structure of the information recommendation device 453 provided in the embodiment of the present application implemented as a software module. In some embodiments, Figure 2 As shown, the software modules stored in the information recommendation device 453 of the memory 450 may include: an encoding module 4531, used to encode the item description information of at least one to-be-recommended information to obtain the item description feature of at least one to-be-recommended information; a generating module 4532, used to generate intelligent prompt information of multiple item categories based on the object information of the to-be-recommended object and the interaction information of multiple item categories; an inference module 4533, used to infer the intelligent prompt information of multiple item categories to obtain the interest description features of the to-be-recommended object for multiple item categories;
[0174] The recommendation module 4534 is used to perform a recommendation operation on at least one piece of information to be recommended on the recommended object based on the similarity between the item description feature and the interest description feature.
[0175] In some embodiments, the encoding module 4531 is further used to perform sequence embedding processing on the item description information of each information to be recommended to obtain an embedded feature vector of the item description information; and perform sequence encoding processing on the embedded feature vector to obtain the item description feature of each information to be recommended.
[0176] In some embodiments, the generating module 4532 is further configured to perform the following processing for each item category:
[0177] Obtain system prompt information and the active intention of the object to be recommended for the item category; combine the system prompt information, the object information of the object to be recommended, the interactive information of the item category and the active intention to obtain intelligent prompt information of the item category.
[0178] In some embodiments, the reasoning module 4533 is also used to perform the following processing on the intelligent prompt information of each item category: generate an interest description text for the item category based on the intelligent prompt information of the item category; perform text embedding processing on the interest description text of the item category to obtain an embedded feature vector of the interest description text; perform encoding processing on the embedded feature vector of the interest description text to obtain the interest description feature of the item category of the object to be recommended.
[0179] In some embodiments, the reasoning module 4533 is also used to perform text encoding processing on the intelligent prompt information of the item category to obtain the contextual semantic feature vector of the intelligent prompt information; and perform text decoding processing on the contextual semantic feature vector to obtain the interest description text of the item category.
[0180] In some embodiments, the reasoning module 4533 is also used to perform word segmentation processing on the intelligent prompt information of the item category to obtain multiple words; perform feature extraction processing on each word to obtain a text feature vector of the word; map the text feature vector to obtain the distribution probability of the word; combine multiple words whose distribution probability is greater than the probability threshold to obtain the interest description text of the item category.
[0181] In some embodiments, the reasoning module 4533 is also used to determine the position feature vector of the embedded feature vector of the interest description text, and merge the position feature with the embedded feature vector to obtain a first fused feature vector; perform attention mechanism processing on the first fused feature through the attention mechanism layer to obtain the attention tensor of the first fused feature vector; merge the first fused feature vector with the attention tensor to obtain a second fused feature vector; map the second fused feature vector through the feedforward network layer to obtain the interest description feature of the object to be recommended for the item category.
[0182] In some embodiments, the recommendation module 4534 is further configured to perform the following processing for each item category:
[0183] Determine a first similarity between an interest description feature of an item category and an item description feature of each information to be recommended; based on the first similarity, filter out a portion of information to be recommended from at least one information to be recommended; filter out target information to be recommended from the portion of information to be recommended corresponding to a plurality of item categories, and perform a recommendation operation on the object to be recommended based on the target information to be recommended.
[0184] In some embodiments, the recommendation module 4534 is also used to determine the average value of the first similarity between the interest description feature of each item category and the item description feature of each information to be recommended; based on the average value, determine the proportion of the number of information to be recommended corresponding to each item category to the total number of recommendations, wherein the total number of recommendations represents the number of information to be recommended recommended to the object to be recommended, and the proportion is positively correlated with the average value; based on the proportion and the first similarity, filter out target information to be recommended from at least one information to be recommended, and perform a recommendation operation on the object to be recommended based on the target information to be recommended.
[0185] In some embodiments, the recommendation module 4534 is also used to obtain information samples to be recommended and interest description texts of multiple item categories; forward propagates the information samples to be recommended in the information recommendation model to obtain item description features of the information samples to be recommended, and forward propagates the interest description text in the information recommendation model to obtain interest description features of multiple item categories; determines the loss value of the information recommendation model based on the item description features, interest description features of multiple item categories, and recommended tags of the information samples to be recommended; and backpropagates in the information recommendation model through the loss value to update the parameters of the information recommendation model.
[0186] In some embodiments, the recommendation module 4534 is further used to determine the feature similarity between the interest description feature and the item description feature of any item category; construct a first loss value of the information recommendation model based on the feature similarity and the recommended label of the information sample to be recommended; construct a second loss value of the information recommendation model based on the interest description features of multiple item categories;
[0187] Based on the first loss value and the second loss value, a loss value of the information recommendation model is determined.
[0188] The embodiment of the present application provides a computer program product, which includes a computer program or a computer executable instruction, and the computer program or the computer executable instruction is stored in a computer-readable storage medium. The processor of the electronic device reads the computer executable instruction from the computer-readable storage medium, and the processor executes the computer executable instruction, so that the electronic device performs the information recommendation method described in the embodiment of the present application.
[0189] The present application embodiment provides a computer-readable storage medium storing computer-executable instructions, wherein the computer-executable instructions or computer programs are stored. When the computer-executable instructions or computer programs are executed by a processor, the processor will be caused to execute the information recommendation method provided by the present application embodiment, for example, 3A to 3H The information recommendation method is shown.
[0190] In some embodiments, the computer-readable storage medium may be a memory such as RAM, ROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or may be various devices including one or any combination of the above memories.
[0191] In some embodiments, computer executable instructions may be in the form of a program, software, software module, script or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a stand-alone program or as a module, component, subroutine or other unit suitable for use in a computing environment.
[0192] As an example, computer-executable instructions may, but need not, correspond to a file in a file system, may be stored as part of a file that stores other programs or data, such as in one or more scripts in a HyperText Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple coordinated files (e.g., files storing one or more modules, subroutines, or code portions).
[0193] As an example, computer executable instructions may be deployed to be executed on one electronic device, or on multiple electronic devices located at one site, or on multiple electronic devices distributed at multiple sites and interconnected by a communication network.
[0194] In summary, through the embodiments of the present application, in the recommendation process, on the one hand, the description information of the items to be recommended is encoded to obtain the description features of the items to be recommended, and on the other hand, the object information of the recommended object and the interaction information of multiple item categories are used to generate intelligent prompt information of multiple item categories, that is, multiple intelligent prompt information can be generated through the interaction information of multiple item categories, and then the intelligent prompt information of multiple item categories is inferred to obtain the interest description features of the recommended object for multiple item categories, so that multiple interest categories of the recommended object can be mined, and finally, the recommendation operation is performed on the recommended object by determining the similarity between the item description features and the interest description features. In this way, the recommended information corresponding to multiple item categories can be recommended for multiple interest categories of the mined recommended object, and while personalized recommendations are made to the recommended object, diversified recommendations are achieved, thereby improving the information recommendation effect and user experience. When training the information recommendation model, the first loss value is constructed by the feature similarity between the interest description feature of any item category and the item description feature, and the second loss value is constructed by the interest description features of multiple item categories. The final loss value of the information recommendation model is constructed by the first loss value and the second loss value, so that the information recommendation model can make personalized recommendations for the recommended objects and diversified recommendations for the recommended objects when making recommendations, thereby improving the diversity of information recommendations and enriching the information recommendation results.
[0195] The above is only an embodiment of the present application and is not intended to limit the protection scope of the present application. Any modifications, equivalent substitutions and improvements made within the spirit and scope of the present application are included in the protection scope of the present application.
Claims
1. An information recommendation method, characterized in that: The method comprises: Encoding the item description information of at least one item of information to be recommended to obtain the item description feature of the at least one item of information to be recommended; Based on the object information of the object to be recommended and the interaction information of the multiple item categories, generating intelligent prompt information of the multiple item categories; Performing inference processing on the intelligent prompt information of the multiple categories of items to obtain interest description features of the recommended object for the multiple categories of items; Based on the similarity between the item description feature and the interest description feature, a recommendation operation of the at least one information to be recommended is performed on the object to be recommended.
2. The method according to claim 1, characterized in that The encoding process of the item description information of at least one item of information to be recommended to obtain the item description feature of the at least one item of information to be recommended includes: Performing sequence embedding processing on the item description information of each of the to-be-recommended information to obtain an embedded feature vector of the item description information; The embedded feature vector is subjected to sequence encoding processing to obtain the item description feature of each of the information to be recommended.
3. The method according to claim 1, characterized in that The generating of intelligent prompt information of the multiple item categories based on the object information of the object to be recommended and the interaction information of the multiple item categories includes: For each item category, the following processing is performed: Obtaining system prompt information and the active intention of the object to be recommended for the item category; The system prompt information, the object information of the object to be recommended, the interaction information of the item category and the active intention are combined to obtain intelligent prompt information of the item category.
4. The method according to claim 1, characterized in that The inference processing of the intelligent prompt information of the multiple item categories to obtain the interest description features of the recommended object for the multiple item categories includes: The following processing is performed for the intelligent prompt information of each item category: Based on the intelligent prompt information of the item category, generate an interest description text of the item category; Performing text embedding processing on the interest description text of the item category to obtain an embedding feature vector of the interest description text; The embedded feature vector of the interest description text is encoded to obtain the interest description feature of the object to be recommended for the item category.
5. The method according to claim 4, characterized in that The step of generating an interest description text for the item category based on the intelligent prompt information for the item category includes: Performing text encoding processing on the intelligent prompt information of the item category to obtain a contextual semantic feature vector of the intelligent prompt information; The context semantic feature vector is subjected to text decoding processing to obtain an interest description text of the item category.
6. The method according to claim 4, characterized in that The step of generating an interest description text for the item category based on the intelligent prompt information for the item category includes: Performing word segmentation processing on the intelligent prompt information of the item category to obtain multiple words; Performing feature extraction processing on each of the words to obtain a text feature vector of the word; Mapping the text feature vector to obtain the distribution probability of the word; The multiple words whose distribution probabilities are greater than a probability threshold are combined to obtain an interest description text of the item category.
7. The method according to claim 4, characterized in that The encoding process is implemented by an encoder, and the encoder includes an attention mechanism layer and a feedforward network layer; the encoding process is performed on the embedded feature vector of the interest description text to obtain the interest description feature of the object to be recommended for the item category, including: Determine a position feature vector of the embedded feature vector of the interest description text, and merge the position feature with the embedded feature vector to obtain a first fused feature vector; Performing attention mechanism processing on the first fused feature through the attention mechanism layer to obtain an attention tensor of the first fused feature vector; Merging the first fused feature vector with the attention tensor to obtain a second fused feature vector; The second fused feature vector is mapped through the feedforward network layer to obtain interest description features of the object to be recommended for the item category.
8. The method according to claim 1, characterized in that Based on the similarity between the item description feature and the interest description feature, performing a recommendation operation of the at least one to-be-recommended information on the to-be-recommended object includes: The following processing is performed for each of the described item categories: Determine a first similarity between the interest description feature of the item category and the item description feature of each of the information to be recommended; Based on the first similarity, filter out part of the information to be recommended from the at least one information to be recommended; Target information to be recommended is screened out from the partial information to be recommended corresponding to the multiple categories of items, and a recommendation operation is performed on the object to be recommended based on the target information to be recommended.
9. The method according to claim 1, characterized in that: The recommending operation of performing the at least one to-be-recommended information on the to-be-recommended object based on the similarity between the item description feature and the interest description feature includes: Determine an average value of the first similarity between the interest description feature of each item category and the item description feature of each item of the information to be recommended; Based on the average value, determine the ratio of the number of to-be-recommended information corresponding to each of the item categories to the total number of recommendations, wherein the total number of recommendations represents the number of to-be-recommended information recommended to the to-be-recommended object, and the ratio is positively correlated with the average value; Based on the ratio and the first similarity, target information to be recommended is screened out from the at least one information to be recommended, and a recommendation operation is performed on the object to be recommended based on the target information to be recommended.
10. The method according to claim 1, characterized in that The recommendation operation is implemented by calling an information recommendation model, and the training method of the information recommendation model includes: Obtain samples of information to be recommended and interest description texts of multiple item categories; Forward propagation of the information sample to be recommended in the information recommendation model to obtain item description features of the information sample to be recommended, and forward propagation of the interest description text in the information recommendation model to obtain interest description features of the multiple item categories; Determining a loss value of the information recommendation model based on the item description features, the interest description features of the multiple item categories, and the recommendation tags of the to-be-recommended information samples; The loss value is used to perform back propagation in the information recommendation model to update the parameters of the information recommendation model.
11. The method according to claim 10, characterized in that The determining the loss value of the information recommendation model based on the item description feature, the interest description features of the multiple item categories, and the recommendation label of the to-be-recommended information sample includes: Determine the feature similarity between the interest description feature of any item category and the item description feature; Constructing a first loss value of the information recommendation model based on the feature similarity and the recommendation label of the information sample to be recommended; Constructing a second loss value of the information recommendation model based on the interest description features of the multiple item categories; Based on the first loss value and the second loss value, a loss value of the information recommendation model is determined.
12. An information recommendation device, characterized in that: The device comprises: An encoding module, used for encoding the item description information of at least one item of information to be recommended to obtain the item description feature of the at least one item of information to be recommended; A generation module, configured to generate intelligent prompt information of the multiple item categories based on the object information of the object to be recommended and the interaction information of the multiple item categories; An inference module, configured to perform inference processing on the intelligent prompt information of the multiple item categories to obtain interest description features of the recommended object for the multiple item categories; The recommendation module is used to recommend the at least one information to be recommended to the object to be recommended based on the similarity between the item description feature and the interest description feature.
13. An electronic device, characterized in that: The electronic device comprises: Memory for storing computer executable instructions or computer programs; A processor, configured to implement the information recommendation method according to any one of claims 1 to 11 when executing the computer executable instructions or computer programs stored in the memory.
14. A computer-readable storage medium storing computer-executable instructions or a computer program, characterized in that: When the computer executable instructions or computer program are executed by a processor, the information recommendation method according to any one of claims 1 to 11 is implemented.
15. A computer program product comprising computer executable instructions or a computer program, characterized in that When the computer executable instructions or computer program are executed by a processor, the information recommendation method according to any one of claims 1 to 11 is implemented.