Recommended method and device, electronic device, storage medium and program product
Patent Information
- Application Number
- CN202510571277.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-30
- Publication Date
- 2026-10-30
AI Technical Summary
然而,目前的重排环节中所用到的模型普遍运行在云端,无法对用户的实时行为做出响应,导致推荐效果差
[0068]本公开实施例提供的一种推荐方法,应用于终端,可以通过向服务端发送推荐请求,并接收服务端返回的包括多个待推荐物料的响应结果,再对多个待推荐物料进行排序处理,得到目标顺序,以按目标顺序显示多个待推荐物料。如此,可以通过在终端上对多个待推荐物料进行排序处理,以按排序后的目标顺序显示多个待推荐物料,从而能够实时感知到终端侧的行为和/或状态,并做出实时反馈,有效提升推荐物料的效果。
Smart Images

Figure CN123012251A_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of Internet technology, and in particular to a recommended method and apparatus, electronic device, storage medium and program product. Background Technology
[0002] In recent years, the internet advertising industry has developed rapidly, especially in terms of personalized recommendations and precision marketing for advertising.
[0003] Currently, to optimize the display order of ad recommendations, a re-ranking stage is typically added after the recall, re-ranking, and fine-ranking stages of traditional recommendations to correct the order in the fine-ranking stage. However, the models used in the current re-ranking stage generally run in the cloud and cannot respond to users' real-time behavior, resulting in poor recommendation performance. Summary of the Invention
[0004] To overcome the problems existing in related technologies, this disclosure provides a recommendation method and apparatus, electronic device, storage medium and program product, which can sense the behavior and / or status of the terminal side in real time and make real-time feedback, effectively improving the effect of recommended materials.
[0005] According to a first aspect of the present disclosure, a recommended method is provided, comprising at least:
[0006] Send a recommendation request to the server;
[0007] Receive the response result returned by the server based on the recommendation request; wherein the response result includes multiple materials to be recommended;
[0008] The multiple materials to be recommended are sorted to obtain the target order;
[0009] The multiple recommended materials are displayed in the order of the target.
[0010] In some possible implementations, the sorting process of the plurality of materials to be recommended to obtain a target order includes:
[0011] Obtain reference information associated with the user and / or the terminal; wherein the reference information includes the user's operation behavior on the terminal and / or the terminal's operating status;
[0012] Based on the reference information, the multiple materials to be recommended are sorted to obtain the target order.
[0013] In some possible implementations, the process of sorting the plurality of materials to be recommended based on the reference information to obtain the target order includes:
[0014] Feature extraction is performed on the reference information to obtain the reference features corresponding to the reference information;
[0015] Based on the reference features, the multiple materials to be recommended are sorted using the trained sorting model to obtain the target order; wherein, the trained sorting model is trained by the server and sent to the terminal.
[0016] In some possible implementations, the trained ranking model includes a re-ranking model; the step of ranking the plurality of materials to be recommended using the trained ranking model based on the reference features to obtain the target order includes:
[0017] Based on the reference features, the attention calculation is performed on each material to be recommended using the re-ranking model to obtain the attention score of each material to be recommended.
[0018] Based on the attention score of each material to be recommended, the multiple materials to be recommended are sorted to obtain the target order.
[0019] In some possible implementations, the step of calculating attention for each item to be recommended using the re-ranking model based on the reference features to obtain an attention score for each item to be recommended includes:
[0020] Extract the material features corresponding to each material to be recommended;
[0021] The reference features are concatenated with the material features corresponding to each material to be recommended and then input into the re-ranking model to obtain the feature vector of each material to be recommended.
[0022] Based on the feature vector of each material to be recommended, an attention mechanism is used to construct the correlation between each material to be recommended, and the attention weight corresponding to each material to be recommended is calculated based on the correlation between each material to be recommended, so as to obtain the attention score of each material to be recommended.
[0023] In some possible implementations, extracting the material features corresponding to each material to be recommended includes:
[0024] Feature extraction is performed on each of the materials to be recommended to obtain the content features of each material to be recommended.
[0025] For each material to be recommended, the content features of the material to be recommended and the features of the sorting position of the material to be recommended among the multiple materials to be recommended are concatenated to obtain the material features corresponding to each material to be recommended.
[0026] In some possible implementations, the trained ranking model includes an evaluation model; the step of ranking the plurality of materials to be recommended based on the reference features using the trained ranking model to obtain the target order includes:
[0027] Extract the content features of each material to be recommended;
[0028] For each material to be recommended, the reference features are concatenated with the content features of the material to be recommended and then input into the evaluation model to evaluate the material to be recommended and obtain the recommendation score of the material to be recommended.
[0029] Based on the recommendation score of each material to be recommended, the multiple materials to be recommended are sorted to obtain the target order.
[0030] According to a second aspect of the present disclosure, a recommended method is provided, comprising at least:
[0031] Receive recommendation requests sent by the terminal;
[0032] In response to the recommendation request, determine multiple materials to be recommended corresponding to the recommendation request;
[0033] The system returns a response result to the terminal; wherein the response result includes the plurality of materials to be recommended, and the response result is used by the terminal to sort the plurality of materials to be recommended in order to obtain a target order before displaying them.
[0034] In some possible implementations, the method further includes:
[0035] Obtain a sample dataset; wherein the sample dataset includes multiple sample reference information and multiple sample materials associated with the multiple sample reference information;
[0036] Based on the sample dataset, a preset neural network model is trained to obtain a trained ranking model;
[0037] The trained ranking model is sent to the terminal; wherein the trained ranking model is used by the terminal to rank the received plurality of materials to be recommended.
[0038] In some possible implementations, the method further includes:
[0039] The terminal sends multiple sample reference information; wherein, the multiple sample reference information includes sample operation behaviors of multiple sample users on the terminal and / or the sample operation behaviors associated with the terminal's sample running status.
[0040] According to a third aspect of the present disclosure, a recommended apparatus is provided, comprising at least:
[0041] The first sending module is configured to send recommendation requests to the server;
[0042] The first receiving module is configured to receive the response result returned by the server based on the recommendation request; wherein the response result includes multiple materials to be recommended;
[0043] The processing module is configured to sort the multiple materials to be recommended to obtain a target order;
[0044] The recommendation module is configured to display the multiple materials to be recommended in the order of the target.
[0045] In some possible implementations, the processing module is specifically configured as follows:
[0046] Obtain reference information associated with the user and / or the terminal; wherein the reference information includes the user's operation behavior on the terminal and / or the terminal's operating status;
[0047] Based on the reference information, the multiple materials to be recommended are sorted to obtain the target order.
[0048] In some possible implementations, the processing module is further configured to:
[0049] Feature extraction is performed on the reference information to obtain the reference features corresponding to the reference information;
[0050] Based on the reference features, the multiple materials to be recommended are sorted using the trained sorting model to obtain the target order; wherein, the trained sorting model is trained by the server and sent to the terminal.
[0051] According to a fourth aspect of the present disclosure, a recommended apparatus is provided, comprising at least:
[0052] The second receiving module is configured to receive recommendation requests sent by the terminal;
[0053] The determination module is configured to determine, in response to the recommendation request, multiple materials to be recommended corresponding to the recommendation request;
[0054] The second sending module is configured to return a response result to the terminal; wherein the response result includes the plurality of materials to be recommended, and the response result is used by the terminal to sort the plurality of materials to be recommended in order to obtain a target order before displaying them.
[0055] In some possible implementations, the second transmitting module is further configured to:
[0056] Obtain a sample dataset; wherein the sample dataset includes multiple sample reference information and multiple sample materials associated with the multiple sample reference information;
[0057] Based on the sample dataset, a preset neural network model is trained to obtain a trained ranking model;
[0058] The trained ranking model is sent to the terminal; wherein the trained ranking model is used by the terminal to rank the received plurality of materials to be recommended.
[0059] In some possible implementations, the second receiving module is further configured to:
[0060] The terminal sends multiple sample reference information; wherein, the multiple sample reference information includes sample operation behaviors of multiple sample users on the terminal and / or the sample operation behaviors associated with the terminal's sample running status.
[0061] According to a fifth aspect of the present disclosure, an electronic device is provided, comprising at least:
[0062] processor;
[0063] Memory used to store computer programs or instructions;
[0064] The processor executes the computer program or instructions to implement the steps of the recommended method described in the first or second aspect.
[0065] According to a sixth aspect of the present disclosure, a non-transitory computer-readable storage medium is provided, the storage medium storing a computer program or instructions that, when executed by a processor, implement the steps of the recommended method described in the first or second aspect.
[0066] According to a seventh aspect of the present disclosure, a computer program product is provided, including a computer program or instructions that, when executed by a processor, implement the steps of the recommended method described in the first or second aspect.
[0067] The technical solutions provided by the embodiments of this disclosure may include the following beneficial effects:
[0068] This disclosure provides a recommendation method applied to a terminal. It involves sending a recommendation request to a server, receiving a response from the server including multiple items to be recommended, sorting these items to obtain a target order, and then displaying the items in that target order. This allows for real-time monitoring of the terminal's behavior and / or status, providing real-time feedback and effectively improving the recommendation results.
[0069] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description
[0070] The accompanying drawings, which are incorporated in and form a part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure.
[0071] Figure 1 This is a flowchart illustrating a recommendation method according to an exemplary embodiment. Figure 1 .
[0072] Figure 2 This is a flowchart illustrating a recommendation method according to an exemplary embodiment. Figure 2 .
[0073] Figure 3 This is a flowchart illustrating a recommendation method according to an exemplary embodiment.
[0074] Figure 4 This is a structural block diagram of a recommended device according to an exemplary embodiment. Figure 1 .
[0075] Figure 5 This is a structural block diagram of a recommended device according to an exemplary embodiment. Figure 2 .
[0076] Figure 6 This is a schematic diagram of the structure of a terminal according to an exemplary embodiment.
[0077] Figure 7 This is a schematic diagram of a server structure according to an exemplary embodiment. Detailed Implementation
[0078] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this disclosure. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this disclosure as detailed in the appended claims.
[0079] The technical solutions provided by the embodiments of this disclosure are described in detail below with reference to the accompanying drawings.
[0080] Figure 1 This is a flowchart illustrating a recommendation method according to an exemplary embodiment. Figure 1 ,like Figure 1 As shown, the recommended method provided in this disclosure embodiment can be applied to a terminal and includes at least the following steps:
[0081] S110, Send a recommendation request to the server;
[0082] S120. Receive the response result returned by the server based on the recommendation request; wherein, the response result includes multiple materials to be recommended;
[0083] S130. Sort multiple materials to be recommended to obtain the target order;
[0084] S140: Display multiple materials to be recommended in target order.
[0085] In this embodiment of the disclosure, the recommended method described above can be applied to a terminal. Here, the terminal may include a mobile terminal or a fixed terminal. A mobile terminal may include devices such as mobile phones, tablets, laptops, and wearable electronic devices; a fixed terminal may include desktop computers, smart TVs, and in-vehicle devices, etc., and this embodiment of the disclosure does not impose any limitations.
[0086] In steps S110-S120, the terminal can send a recommendation request to the server with which it has established a communication connection and receive a response from the server that includes multiple materials to be recommended, so that the multiple materials to be recommended can be sorted in subsequent processes.
[0087] Here, a recommendation request can be a material recommendation request sent by a user on the terminal to the server by refreshing the recommendation page or clicking the recommendation button on the terminal; the response result can be the result output by the server after performing recall, coarse ranking and fine ranking based on the recommendation request.
[0088] It is understandable that the multiple materials to be recommended can be materials obtained by the server after recalling, coarse ranking, and fine ranking based on the recommendation request. The terminal can perform the rearrangement process, while the traditional recalling, coarse ranking, and fine ranking processes are still performed by the server, in order to reduce the terminal's computational load and power consumption.
[0089] In this embodiment of the disclosure, the response result returned by the server to the terminal includes multiple recommended materials.
[0090] It should be noted that the response returned by the server to the terminal may directly contain multiple materials to be recommended; or the response may also contain a list of materials to be recommended, which contains multiple materials to be recommended. This embodiment of the disclosure does not impose any restrictions.
[0091] In steps S130-S140, the terminal can sort multiple materials to be recommended to obtain a target order, and then display the multiple materials to be recommended in the target order.
[0092] Here, the target order can be the order in which the terminal displays multiple recommended materials to the user. In other words, the terminal can display multiple recommended materials in the target order to recommend materials that the user is interested in.
[0093] It should be noted that the target order of multiple recommended materials can represent the degree of relevance between the recommended materials and the user. That is, the recommended material ranked first in the target order is the material with the highest relevance to the user among all recommended materials, while the recommended material ranked last in the target order is the material with the lowest relevance to the user among all recommended materials.
[0094] In this embodiment, the terminal can sort multiple recommended materials based on user actions and / or the terminal's operating status, as well as a sorting model trained by the server, to display the materials in descending order of their relevance to the user. The trained sorting model can be a different type of neural network model, such as a reordering model incorporating an attention mechanism or a generator evaluator model.
[0095] It is understandable that sorting multiple materials to be recommended to obtain a target order can include, but is not limited to: sorting multiple materials to be recommended by calculating the attention score of each material to obtain a target order; or, calculating the recommendation score of each material to be recommended by an evaluation model that includes a generator and an evaluator to sort multiple materials to obtain a target order.
[0096] It should be noted that in order to enable the trained ranking model to run on the terminal, the number of computational parameters can be reduced by sampling the shared embedding on the terminal. That is, the same embedding vector is reused in the trained ranking model, i.e., shared embedding, in order to reduce the number of parameters and improve the generalization ability of the model.
[0097] The recommendation method provided in this disclosure, applied to a terminal, can send a recommendation request to a server, receive a response from the server including multiple items to be recommended, and then sort the multiple items to obtain a target order, displaying the multiple items to be recommended in that target order. In this way, by sorting multiple items to be recommended on the terminal and displaying them in the sorted target order, the behavior and / or status of the terminal can be perceived in real time, and real-time feedback can be provided, effectively improving the effectiveness of the recommended items.
[0098] In some embodiments, step S130 may include:
[0099] Obtain reference information associated with users and / or terminals; wherein, the reference information includes user actions on the terminal and / or the terminal's operating status;
[0100] Based on the reference information, multiple materials to be recommended are sorted to obtain the target order.
[0101] In this way, by acquiring reference information including user actions on the terminal and / or the terminal's operating status, and sorting multiple materials to be recommended based on this reference information to obtain a target order, it is possible to prepare for the subsequent display of multiple materials to be recommended in the target order. This allows for real-time perception of user actions on the terminal and / or the terminal's operating status, and real-time feedback, further improving the effectiveness of recommending materials to users.
[0102] In this embodiment of the disclosure, the terminal can obtain the user's operation behavior on the terminal by detecting the user's operation on the terminal, and / or obtain the terminal's running status, so as to sort multiple materials to be recommended according to the operation behavior and / or running status, and then display multiple materials to be recommended in the target order in the subsequent process.
[0103] Here, the user can be the object using the terminal, i.e., the object to be recommended materials. User actions on the terminal can include, but are not limited to, clicking, downloading, searching, or voice commands. The terminal's operating state can include, but is not limited to, landscape or portrait mode, Bluetooth or Wi-Fi.
[0104] It should be noted that the terminal may acquire the user's operation behavior and / or the terminal's operating status before sending a recommendation request to the server or after receiving the response result returned by the server; this embodiment of the disclosure does not impose any restrictions. For example, the terminal may acquire the user's operation behavior and / or the terminal's operating status at the current moment, or it may acquire the user's operation behavior and / or the terminal's operating status within a preset time period (e.g., 1 minute or 5 minutes).
[0105] In some embodiments, the above-described sorting process based on reference information to obtain a target order includes:
[0106] Feature extraction is performed on the reference information to obtain the reference features corresponding to the reference information;
[0107] Based on reference features, the trained ranking model is used to sort multiple materials to be recommended to obtain the target order; the trained ranking model is trained on the server and sent to the terminal.
[0108] In this way, we can first extract features from the reference information to obtain the reference features corresponding to the reference information. Then, using the reference features, we can use the trained ranking model sent by the server to sort multiple materials to be recommended to obtain the target order. This can prepare for the subsequent display of multiple materials to be recommended in the target order, so as to better perceive the user's operation behavior on the terminal and / or the terminal's operating status in real time, and make real-time feedback, effectively improving the effect of recommending materials to users.
[0109] In this embodiment of the disclosure, the terminal can first extract features from the reference information to obtain the reference features corresponding to the reference information, and then use the trained sorting model to sort multiple materials to be recommended through the reference features to obtain the target order, so that multiple materials to be recommended can be displayed in the target order in the subsequent process.
[0110] Here, the reference information may include the user's operation behavior on the terminal and / or the terminal's operating status. The terminal may preprocess the reference information such as the user's operation behavior on the terminal and / or the terminal's operating status to obtain reference information such as operation behavior and / or operating status with uniform format and no abnormalities. Then, the preprocessed reference information such as operation behavior and / or operating status is subjected to dimensionality reduction processing through a hash algorithm to convert the reference information such as operation behavior and / or operating status into a fixed-length hash value. Then, the dimensionality-reduced reference information such as operation behavior and / or operating status is discretized to simplify the data and facilitate the extraction of reference features from the simplified reference information such as operation behavior and / or operating status.
[0111] The trained ranking model can be trained by the server using a sample dataset and then sent to the terminal. The terminal can use this trained ranking model to sort multiple materials to be recommended.
[0112] Understandably, the terminal can input the extracted reference features into the trained ranking model, utilize the attention mechanism in the trained ranking model to calculate the attention score of each item to be recommended, and then rank the multiple items to be recommended based on the attention score to obtain the target order; alternatively, the terminal can also input the extracted reference features into the trained ranking model, utilize the evaluation mechanism in the trained ranking model to calculate the recommendation score of each item to be recommended, and then rank the multiple items to be recommended based on the recommendation score to obtain the target order, etc.
[0113] It should be noted that the terminal can also send the user's operation behavior and / or the terminal's running status to the server in real time. The server can store multiple sample reference information including multiple operation behaviors and / or running statuses to construct a sample dataset including multiple sample reference information, so as to use the sample dataset to train the trained ranking model; or, the server can also train the trained ranking model based on the user's historical browsing content or historical operation behavior and other related data, etc., which are not limited in the embodiments disclosed herein.
[0114] In some embodiments, the trained ranking model includes a re-ranking model; the above-mentioned ranking process based on reference features, using the trained ranking model to rank multiple materials to be recommended to obtain a target order, includes:
[0115] Based on reference features, an attention calculation is performed on each item to be recommended using a re-ranking model to obtain an attention score for each item to be recommended.
[0116] Based on the attention score of each material to be recommended, the materials to be recommended are sorted to obtain the target order.
[0117] In this way, attention calculations can be performed on each recommended material using a reordering model based on reference features to obtain an attention score for each recommended material. Then, based on the attention scores of each recommended material, multiple recommended materials can be sorted to obtain a target order. This prepares for displaying multiple recommended materials in the target order, enabling better real-time perception of user actions on the terminal and / or the terminal's operating status, and providing real-time feedback to further improve the effectiveness of recommending materials to users.
[0118] In this embodiment of the disclosure, the terminal can perform attention calculation on each recommended material based on reference features using a reordering model to obtain an attention score for each recommended material. The terminal can then sort multiple recommended materials according to the attention scores of each recommended material to obtain a target order, so that multiple recommended materials can be displayed in the target order in subsequent processes.
[0119] Here, the re-ranking model can be a trained neural network model incorporating an attention mechanism. The attention score for each item to be recommended can be calculated by determining the attention weights for each item using the attention mechanism in the re-ranking model.
[0120] Understandably, the terminal can input the reference features extracted from the reference information into the re-ranking model for encoding processing, and use the attention mechanism in the re-ranking model to determine the attention weight corresponding to each material to be recommended, so as to calculate the attention score of each material to be recommended. In this way, multiple materials to be recommended can be sorted according to the attention score to obtain the target order.
[0121] It should be noted that the specific type of attention mechanism in the reordering model can be selected according to the actual application scenario, and this disclosure does not impose any restrictions. For example, the attention mechanism can be a self-attention mechanism or a multi-head attention mechanism, etc.
[0122] In some embodiments, the above-mentioned attention calculation for each item to be recommended based on reference features using a re-ranking model to obtain an attention score for each item to be recommended includes:
[0123] Extract the material characteristics corresponding to each material to be recommended;
[0124] The reference features are concatenated with the material features corresponding to each material to be recommended and then input into the re-ranking model to obtain the feature vector of each material to be recommended.
[0125] Based on the feature vector of each material to be recommended, the correlation between each material to be recommended is constructed using an attention mechanism, and the attention weight corresponding to each material to be recommended is calculated based on the correlation between each material to be recommended, so as to obtain the attention score of each material to be recommended.
[0126] In this way, by extracting the material features corresponding to each material to be recommended, and concatenating the reference features with the material features corresponding to each material to be recommended, and then inputting the concatenation into the re-ranking model, the feature vector of each material to be recommended can be obtained. Then, based on the feature vector of each material to be recommended, the correlation between each material to be recommended can be constructed using an attention mechanism, and the attention weight corresponding to each material to be recommended can be calculated based on the correlation between each material to be recommended, so as to obtain the attention score of each material to be recommended. This prepares for subsequent ranking of multiple materials to be recommended based on the attention score of each material to be recommended, so as to recommend materials with higher relevance to users based on real-time user behavior and / or real-time terminal operating status, thereby improving the effect of recommending materials to users.
[0127] In this embodiment of the disclosure, the terminal can first pre-determine the material features corresponding to each material to be recommended, then concatenate the reference features with the material features corresponding to each material to be recommended and input them into the reordering model to obtain the feature vector of each material to be recommended. Then, based on the feature vector of each material to be recommended, the attention mechanism in the reordering model is used to construct the correlation between each material to be recommended, and the attention weight corresponding to each material to be recommended is calculated based on the correlation between each material to be recommended to obtain the attention score of each material to be recommended, so that multiple materials to be recommended can be displayed in the target order in the subsequent process.
[0128] Here, the material features corresponding to each material to be recommended can be obtained based on the content features of each material to be recommended and its ranking position among multiple materials to be recommended. The feature vector of each material to be recommended can be obtained by encoding the features obtained by concatenating the reference features and the material features corresponding to each material to be recommended. The correlation between the materials to be recommended can be the degree of dependence between any one material to be recommended and the other materials to be recommended.
[0129] It is understandable that the terminal utilizes the attention mechanism in the re-ranking model to construct the correlation between each recommended item based on the feature vector of each item. This attention mechanism can be a self-attention mechanism or a multi-head attention mechanism. The multi-head attention mechanism is an improvement on the traditional attention mechanism. It processes the input features (usually queries, keys, and values) through multiple independent, parallel-running attention modules (or "heads"). Each head independently calculates an attention score and generates an attention-weighted output. These outputs are then merged (usually by concatenation or averaging) to form a final, more complex representation, i.e., the first feature vector, second feature vector, and third feature vector obtained in this embodiment of the disclosure. The following formula (1) is a function of the multi-head attention mechanism:
[0130]
[0131] Where Q, K, and V represent the query vector, key vector, and value vector, respectively, and d represents the vector dimension.
[0132] In this embodiment of the disclosure, based on the feature vector of each material to be recommended, an attention mechanism is used to construct the correlation between the materials to be recommended, and the attention weight corresponding to each material to be recommended is calculated based on the correlation between the materials to be recommended, so as to obtain the attention score of each material to be recommended. This may include, but is not limited to: performing feature transformation on the feature vector of each material to be recommended to obtain a first feature vector, a second feature vector, and a third feature vector corresponding to each material to be recommended; determining the weight coefficient corresponding to each material to be recommended based on the similarity between the first feature vector of each material to be recommended and the second feature vectors of all materials to be recommended; and performing a weighted summation of the third feature vectors of all materials to be recommended based on the weight coefficient of each material to be recommended to obtain the attention score of each material to be recommended.
[0133] Here, the first feature vector can represent the information that any recommended material at the current ranking position wants to focus on or query among multiple recommended materials, and can be used to calculate the similarity between it and the second feature vector of recommended materials at other ranking positions among multiple recommended materials.
[0134] Understandably, the first feature vector can be obtained by converting any recommended item at the current ranking position into a word embedding vector, and then performing a linear transformation on that word embedding vector, i.e., multiplying it by a weight matrix. For example, this first feature vector can be a query vector.
[0135] The second feature vector can be used to calculate similarity with the first feature vector to determine the degree of dependence among multiple items to be recommended. By comparing the similarity between the first and second feature vectors, the attention weights of items to be recommended at corresponding ranking positions can be adaptively adjusted.
[0136] It should be noted that the second feature vector can also be obtained by converting the recommended material at the corresponding ranking position into a word embedding vector, and then performing a linear transformation on that word embedding vector, i.e., multiplying it by a weight matrix. This transformation allows the second feature vector to capture the key information needed for comparison with the first feature vector. For example, this second feature vector can be a key vector.
[0137] It is understood that this disclosure can determine the similarity between each recommended material and other recommended materials by performing dot product calculation or other metric (such as cosine similarity) on the first feature vector of each recommended material and the second feature vector of all recommended materials respectively.
[0138] The dot product, also known as the scalar product or dot product, is used to calculate the similarity between the query vector and the key vector, or the angle between them. Similarity can be a measure of how similar two objects, such as any item to be recommended, are to other items to be recommended.
[0139] In this embodiment of the disclosure, the weight coefficient corresponding to each recommended material can be used to represent the proportionality of the importance of other recommended materials relative to each recommended material. The value of the weight coefficient can range from 0 to 1.
[0140] Understandably, the Softmax function can be used to normalize the similarity between each recommended item and other recommended items, thus obtaining the weight coefficients of other recommended items relative to each recommended item. The Softmax function is a commonly used classification function that standardizes an n-dimensional vector input to the function into an n-dimensional probability distribution. In this n-dimensional probability distribution, each element has a value between 0 and 1, and the sum of all elements is 1.
[0141] Here, the correlation between the recommended materials can be determined by weighting and summing the weight coefficient of each material and the third feature vector of all materials. Alternatively, the correlation between the recommended materials can be obtained by weighting the weight coefficient and the third feature vector of all materials, and then weighting and summing the weighted third feature vectors according to preset coefficients. The third feature vector can be a value vector.
[0142] It should be noted that, after calculating the correlation degree corresponding to each material to be recommended in the embodiments of this disclosure, the materials to be recommended can be corrected based on the correlation degree, so as to improve the effect of recommending each material to the user.
[0143] In some embodiments, the material features corresponding to each material to be recommended are extracted, including:
[0144] For each material to be recommended, feature extraction is performed to obtain the content features of each material to be recommended.
[0145] For each material to be recommended, the content features of the material to be recommended and the features of the ranking position of the material to be recommended among multiple materials to be recommended are concatenated to obtain the material features corresponding to each material to be recommended.
[0146] In this way, by extracting the content features of each material to be recommended, and concatenating the content features of the material to be recommended with the features of its ranking position among multiple materials to be recommended, we can obtain the material features corresponding to each material to be recommended. This can prepare for the subsequent calculation of the attention score of each material to be recommended, thereby strengthening the dependence between the materials to be recommended and effectively improving the effect of recommending materials to users.
[0147] In this embodiment of the disclosure, the terminal can extract features from each material to be recommended to obtain the content features of each material to be recommended. For each material to be recommended, the content features of the material to be recommended and the features of the ranking position of the material to be recommended among multiple materials to be recommended are concatenated to obtain the material features corresponding to each material to be recommended. In the subsequent process, the attention score of each material to be recommended can be calculated based on the material features corresponding to each material to be recommended.
[0148] Here, the content features of each recommended material can be features used for semantic content understanding of the recommended material; for example, the content features of the recommended material can include, but are not limited to, keywords, semantic vectors, or image features. The ranking position of the recommended material among multiple recommended materials can refer to the position of any one of the multiple recommended materials in the response result, that is, the position of the multiple recommended materials in the ranking obtained before the server sends the response result to the terminal.
[0149] Understandably, the terminal can concatenate the content features of each recommended material with the features of its ranking position among multiple recommended materials to obtain the material features corresponding to each recommended material. In the future, the material features can be input into the re-ranking model to calculate the attention score of each recommended material, thereby sorting the multiple recommended materials and recommending the sorted materials to the user.
[0150] It should be noted that the terminal can use the principle of feature splicing to splice the content features of the material to be recommended and the features of the ranking position of the material to be recommended among multiple materials to be recommended. The specific splicing method can be set according to the actual application scenario, and this disclosed embodiment does not impose any restrictions.
[0151] In some embodiments, the trained ranking model includes an evaluation model; based on reference features, the trained ranking model is used to rank multiple items to be recommended to obtain a target order, including:
[0152] Extract the content features of each material to be recommended;
[0153] For each material to be recommended, the reference features are concatenated with the content features of the material to be recommended and then input into the evaluation model to evaluate the material to be recommended and obtain the recommendation score of the material to be recommended.
[0154] Based on the recommendation score of each material to be recommended, the materials to be recommended are sorted to obtain the target order.
[0155] In this way, by extracting the content features of each material to be recommended, and then concatenating the reference features with the content features of the material to be recommended for each material, and inputting the concatenation into the evaluation model, the material to be recommended is evaluated to obtain a recommendation score. Based on the recommendation score of each material to be recommended, multiple materials to be recommended are sorted to obtain a target order. This prepares for displaying multiple materials to be recommended in the target order, thereby increasing the diversity of sorting multiple materials to be recommended and improving the effectiveness of recommending materials to users.
[0156] In this embodiment of the disclosure, the terminal can first extract the content features of each material to be recommended, then for each material to be recommended, the reference features and the content features of the material to be recommended are concatenated, and the concatenated features are input into the evaluation model to evaluate the material to be recommended, thereby obtaining the recommendation score of the material to be recommended. Then, based on the recommendation score of each material to be recommended, the multiple materials to be recommended are sorted to obtain the target order, so that multiple materials to be recommended can be displayed in the target order in subsequent processes.
[0157] Here, the evaluation model can be a trained generator-evaluator model. The recommendation score for each item to be recommended can be the score determined by the screening and evaluation mechanism in the evaluation model, indicating that each item can be recommended to the user.
[0158] It's understandable that the Generator-Evaluator is a collaborative generation framework that achieves more efficient and higher-quality text generation by separating the generator and evaluator modules. In the Generator-Evaluator model, the generator is responsible for generating multiple candidates from multiple materials to be recommended, and the evaluator scores the generator's results according to preset criteria, outputting a recommendation score for each material.
[0159] It should be noted that, in the embodiments of this disclosure, a generator evaluator model can be used on the terminal to evaluate each material to be recommended in order to sort multiple materials to be recommended; and using the generator evaluator model does not require inputting the sorting position of each material to be recommended among multiple materials to be recommended, but the degree of contextual dependency between each material to be recommended can be obtained through the processing within the generator evaluator model.
[0160] Figure 2 This is a flowchart illustrating a recommendation method according to an exemplary embodiment. Figure 2 ,like Figure 2 As shown, the recommended method provided in this disclosure embodiment can be applied to the server side and includes at least the following steps:
[0161] S210, Receive recommendation request sent by terminal;
[0162] S220. In response to the recommendation request, determine the multiple materials to be recommended corresponding to the recommendation request;
[0163] S230. Return the response result to the terminal; wherein, the response result includes multiple materials to be recommended, and the response result is used by the terminal to sort the multiple materials to be recommended in order to obtain the target order before displaying them.
[0164] In steps S210-S220, the server can receive recommendation requests sent by terminals that have established communication connections with the server, and determine multiple recommended materials associated with the user based on the recommendation requests.
[0165] Here, a recommendation request can be a material recommendation request sent by a user to the server by refreshing the recommendation page or clicking the recommendation button on the terminal. Multiple materials to be recommended can be materials obtained by the server after performing recall, coarse ranking, and fine ranking processes based on the recommendation request.
[0166] Understandably, after receiving a recommendation request, the server can use historical user characteristics and other data stored on the server to identify multiple materials to be recommended from a large number of candidate materials using recall, coarse ranking, and fine ranking models.
[0167] Among them, historical user characteristics can be historical data associated with the user sent from the terminal and stored on the server; for example, historical user characteristics may include the user's historical browsing content or the user's historical operation behavior on the terminal.
[0168] It should be noted that the historical data associated with a user may include: the user's identification information, historical query information, etc. The user's identification information may include: the user's Identity Document (ID) and geographical location, etc.; the user's historical query information may include: the user's historical browsing content, browsing time, and transaction information, etc., which are not limited in this embodiment.
[0169] In step S230, the server can return a response result including multiple materials to be recommended to the terminal, so that the terminal can sort the multiple materials to be recommended according to the response result to obtain the target order and then display it.
[0170] Here, the response result can be the result of the server performing recall, coarse ranking, and fine ranking based on the recommendation request.
[0171] It should be noted that the response returned by the server to the terminal may contain multiple materials to be recommended; or, the response may also contain a list of materials to be recommended, which contains multiple materials to be recommended. This embodiment of the disclosure does not impose any restrictions.
[0172] The recommendation method provided in this embodiment is applied to the server. It can receive recommendation requests sent by the terminal and determine multiple materials to be recommended based on the recommendation requests. It then returns a response result including multiple materials to be recommended to the terminal, enabling the terminal to sort the multiple materials to be recommended in a target order and display them. This allows the terminal to perceive the behavior and / or status of the terminal side in real time and display multiple materials to be recommended in the target order for real-time feedback, effectively improving the effect of recommending materials.
[0173] In some embodiments, the above-recommended method further includes:
[0174] Obtain a sample dataset; wherein the sample dataset includes multiple sample reference information and multiple sample materials associated with the multiple sample reference information;
[0175] Based on the sample dataset, a pre-defined neural network model is trained to obtain a trained ranking model.
[0176] The trained ranking model is sent to the terminal; the trained ranking model is used by the terminal to rank multiple materials to be recommended.
[0177] In this way, a preset neural network model can be trained using a sample dataset that includes multiple sample reference information and multiple sample materials associated with the multiple sample reference information, to obtain a trained ranking model. The trained ranking model is then sent to the terminal, which facilitates the terminal in sorting the multiple materials to be recommended, thereby improving the effect of recommending materials to users.
[0178] In this embodiment of the disclosure, the server can obtain a sample dataset including multiple sample reference information and multiple sample materials associated with the multiple sample reference information, and train a preset neural network model based on the sample dataset to obtain a trained ranking model, and send the trained ranking model to the terminal so that the subsequent terminal can sort the received multiple materials to be recommended based on the trained ranking model.
[0179] Here, each sample data in the sample dataset can be historical data pre-stored on the server or newly acquired sample data, etc.; for example, the sample dataset may include, but is not limited to: multiple sample reference information such as sample operation behaviors of multiple sample users on the terminal and / or sample status of the terminal associated with the sample operation behaviors, multiple sample materials associated with multiple sample users, and associated data of multiple sample materials, etc.
[0180] The aforementioned preset neural network model can be the initial neural network model before the ranking model is trained on the server. The trained ranking model can be obtained by the server through a sample dataset and sent to the terminal by the server to rank the multiple recommended materials received by the terminal.
[0181] Understandably, the server can iteratively train the preset neural network model based on the sample data in the sample dataset until the neural network model converges, obtain the trained ranking model, and send the trained ranking model to the terminal so that the terminal can sort the multiple materials to be recommended.
[0182] Here, after the server trains the ranking model, it can export the trained ranking model as a ranking model package that can be run on the terminal, and send the ranking model package to the terminal so that the terminal can sort the multiple materials to be recommended.
[0183] It should be noted that the trained ranking model can be a re-ranking model that includes an attention mechanism, or it can be an evaluation model such as a generator evaluator model. This disclosure does not impose any limitations on the embodiments.
[0184] In some embodiments, the above-recommended method further includes:
[0185] The receiver sends multiple sample reference information from the terminal; wherein, the multiple sample reference information includes multiple sample user operations on the terminal and / or the sample operation status of the terminal associated with the sample operation operations.
[0186] In this way, by receiving multiple sample reference information sent by the terminal, including sample user operation behavior on the terminal and / or sample operation behavior associated with the terminal's sample running status, it is possible to prepare for the subsequent construction of sample datasets and training of the trained ranking model. This enables better end-to-end cloud collaboration between the terminal and the server to improve the real-time performance of recommending materials to users and effectively enhance the effect of recommending materials to users.
[0187] In this embodiment of the disclosure, the terminal can send the reference information to the server each time it obtains reference information, that is, when it obtains the user's operation behavior on the terminal and / or the terminal's running status. The server can store multiple sample reference information including multiple operation behaviors and / or running statuses to construct a sample dataset including multiple sample reference information. The server can then use the sample dataset to train a preset neural network model to obtain a trained ranking model. The trained ranking model can then be sent to the terminal so that the terminal can sort the multiple materials to be recommended.
[0188] In some embodiments, the trained ranking model includes a re-ranking model; based on a sample dataset, a pre-defined neural network model is trained to obtain the trained ranking model, including:
[0189] Feature extraction is performed on sample operation behavior and / or sample running status to obtain the first sample feature corresponding to the sample operation behavior and / or the second sample feature corresponding to the sample running status, and material features corresponding to multiple sample materials are extracted.
[0190] For each sample material, the first sample feature and / or the second sample feature are concatenated with the material feature corresponding to the sample material and then input into the neural network model to obtain the feature vector of the sample material.
[0191] Based on the feature vector of each sample material, the correlation between each sample material is determined by an attention mechanism, and the neural network model is iteratively trained based on the correlation between each sample material until the neural network model converges, thus obtaining the re-ranking model.
[0192] In this way, feature extraction can be performed on sample operation behavior and / or sample running state to obtain the first sample feature corresponding to the sample operation behavior and / or the second sample feature corresponding to the sample running state. Material features corresponding to multiple sample materials can also be extracted. For each sample material, the first sample feature and / or the second sample feature are concatenated with the material feature corresponding to the sample material and then input into the neural network model to obtain the feature vector of the sample material. Then, based on the feature vector of each sample material, the correlation between each sample material is determined using an attention mechanism. The neural network model is iteratively trained based on the correlation between each sample material until the neural network model converges, resulting in a trained re-ranking model. This prepares the re-ranking model for subsequent sending to the terminal, so that the terminal can sort the multiple materials to be recommended, effectively improving the effect of recommending materials to users.
[0193] In this embodiment, the server can extract features from sample operation behavior and / or sample running state to obtain first sample features corresponding to sample operation behavior and / or second sample features corresponding to sample running state. It can also extract material features corresponding to multiple sample materials. For each sample material, the first sample features and / or second sample features are concatenated with the material features corresponding to the sample material and then input into the neural network model to obtain the feature vector of the sample material. Based on the feature vector of each sample material, the correlation between each sample material is determined using an attention mechanism. The neural network model is iteratively trained based on the correlation between each sample material until the neural network model converges, resulting in a trained re-ranking model. This re-ranking model can then be sent to the terminal in subsequent processes, facilitating the terminal to sort the multiple materials to be recommended.
[0194] Here, the sample operation behavior can be the user's historical operation behavior on the terminal, and the first sample feature can be the feature extracted from the sample operation behavior. The sample running state can be the historical running state of the terminal associated with the sample operation behavior, i.e., the historical operation behavior, and the second sample feature can be the feature extracted from the sample running state of the terminal.
[0195] Understandably, this disclosure can determine the correlation between each sample material based on its feature vector using the attention mechanism in a neural network model. Then, based on this correlation, the loss value of the neural network model is determined. The neural network model is then iteratively trained based on this loss value until it converges, resulting in a trained re-ranking model. In other words, the loss value is recursively pushed from the output layer of the neural network model to its input layer to determine the gradient values corresponding to the model parameters. The gradient values characterize the relationship between the loss value and the model parameters. Based on these gradient values, the model parameters are updated until the model convergence condition is met, resulting in a trained re-ranking model.
[0196] It should be noted that the model convergence conditions may include: the loss value reaching a preset value, or the number of iterations reaching a set number, etc., and this public embodiment does not impose any restrictions.
[0197] Here, the gradient value can be the partial derivative of the loss function with respect to the model parameters of the neural network model, corresponding to the loss value. This gradient value can represent the rate of change and direction of the loss value in the parameter space. The gradient value can include positive and negative gradient values; a positive gradient value indicates that increasing the corresponding model parameter value will lead to an increase in the loss value, while a negative gradient value indicates that increasing the corresponding model parameter value will lead to a decrease in the loss value.
[0198] In this embodiment of the disclosure, the server can determine how to adjust the model parameters of the neural network model to reduce the loss value by determining the sign and magnitude of the gradient value. When the loss value is reduced to a preset value or the number of iterations reaches a set number, the iterative training of the neural network model can be stopped to improve the accuracy of the trained re-ranking model in re-ranking the recommended materials for the user.
[0199] In some embodiments, the trained reordering model includes an evaluation model; and training a pre-defined neural network model based on a sample dataset to obtain a trained ranking model, including:
[0200] Feature extraction is performed on sample operation behavior and / or sample running status to obtain the first sample feature corresponding to the sample operation behavior and / or the second sample feature corresponding to the sample running status, and the content features of multiple sample materials are extracted.
[0201] For each sample material, the first sample features and / or the second sample features are concatenated with the content features of the sample material and then input into the neural network model to obtain the weight parameters corresponding to the sample material.
[0202] Based on the weight parameters corresponding to each sample material, the correlation between each sample material is determined, and the neural network model is iteratively trained based on the correlation between each sample material until the neural network model converges, thus obtaining the evaluation model.
[0203] In this way, feature extraction can be performed on sample operation behavior and / or terminal sample state to obtain the first sample feature corresponding to the sample operation behavior and / or the second sample feature corresponding to the terminal sample state. Content features of multiple sample materials can also be extracted. For each sample material, the first and / or second sample features are concatenated with the sample material's content features and input into a neural network model to obtain the corresponding weight parameters. Then, based on the weight parameters of each sample material, the correlation between each sample material is determined. The neural network model is iteratively trained based on the correlation between the sample materials until the neural network model converges, resulting in a trained evaluation model. This prepares the model for subsequent delivery to the terminal, enabling the terminal to sort the received multiple materials to be recommended, effectively improving the material recommendation effect to the user.
[0204] In this embodiment, the server can extract features from sample operation behavior and / or sample running status to obtain first sample features corresponding to sample operation behavior and / or second sample features corresponding to sample running status. It can also extract content features of multiple sample materials. For each sample material, the first sample features and / or second sample features are concatenated with the content features of the sample material and then input into a neural network model to obtain the weight parameters corresponding to the sample material. Based on the weight parameters corresponding to each sample material, the correlation between each sample material is determined. The neural network model is iteratively trained based on the correlation between each sample material until the neural network model converges to obtain a trained evaluation model. This evaluation model can be sent to the terminal in subsequent processes, facilitating the terminal to rearrange the multiple materials to be recommended.
[0205] Understandably, this disclosure allows the concatenation of the first sample features and / or the second sample features with the content features of the sample materials to be input into a neural network model for processing. This yields weight parameters for each sample material, and the correlation between each sample material is determined based on these weight parameters. The loss value of the neural network model is then determined based on this correlation, and the model is iteratively trained using this loss value until convergence, resulting in a trained evaluation model. In other words, the loss value is recursively pushed from the output layer of the neural network model to the input layer to determine the gradient values corresponding to the model parameters. The gradient values characterize the relationship between the loss value and the model parameters. Based on the gradient values, the model parameters are updated until the model convergence condition is met, resulting in a trained evaluation model.
[0206] It should be noted that by determining the sign and magnitude of the gradient values, the server can determine how to adjust the model parameters of the neural network model to reduce the loss value. When the loss value decreases to a preset value or the number of iterations reaches a set number, the iterative training of the neural network model can be stopped to improve the accuracy of the trained evaluation model in sorting the recommended materials for users.
[0207] Figure 3 This is an interactive schematic diagram illustrating a recommendation method according to an exemplary embodiment. For example... Figure 3 As shown, the recommended methods provided in the embodiments of this disclosure are merely examples and not limitations, and are intended to help those skilled in the art better understand the technical solutions of this disclosure. See also Figure 3 The recommended method provided in this disclosure can be applied to electronic devices, which may include terminals and servers, and specifically may include the following steps:
[0208] S301, The terminal sends a recommendation request to the server.
[0209] S302. The server responds to the recommendation request and determines the multiple materials to be recommended corresponding to the recommendation request.
[0210] Here, after receiving a recommendation request, the server can use historical user characteristics and other data stored on the server to determine multiple materials to be recommended from a large number of candidate materials using recall, coarse ranking, and fine ranking models.
[0211] S303. The server returns a response result to the terminal, which includes multiple materials to be recommended.
[0212] Here, the above response results can be used by the terminal to sort multiple materials to be recommended to obtain the target order and then display them.
[0213] S304. The terminal obtains reference information associated with the user and / or the terminal.
[0214] Here, the reference information may include, but is not limited to: the user's operation behavior on the terminal and / or the terminal's operating status.
[0215] S305. The terminal extracts features from the reference information to obtain the reference features corresponding to the reference information.
[0216] S306. The terminal extracts the material features corresponding to each material to be recommended, and then concatenates the reference features with the material features corresponding to each material to be recommended and inputs them into the re-sorting model to obtain the feature vector of each material to be recommended.
[0217] S307. The terminal constructs the correlation between each recommended material based on the feature vector of each recommended material using an attention mechanism, and calculates the attention weight corresponding to each recommended material based on the correlation between each recommended material to obtain the attention score of each recommended material.
[0218] Here, the terminal performs feature transformation on the feature vector of each material to be recommended, obtaining the first feature vector, the second feature vector, and the third feature vector corresponding to each material to be recommended; based on the similarity between the first feature vector of each material to be recommended and the second feature vectors of all materials to be recommended, the weight coefficient corresponding to each material to be recommended is determined, and the third feature vectors of all materials to be recommended are weighted and summed based on the weight coefficient of each material to be recommended, to obtain the attention score of each material to be recommended.
[0219] S308. The terminal sorts multiple recommended materials based on the attention score of each recommended material to obtain the target order.
[0220] S309. The terminal extracts the content features of each material to be recommended, and for each material to be recommended, it concatenates the reference features with the content features of the material to be recommended and inputs them into the evaluation model to evaluate the material to be recommended and obtain the recommendation score of the material to be recommended.
[0221] Here, the terminal can use an evaluation model, such as a generator evaluator model, to evaluate each item to be recommended in order to rearrange multiple items to be recommended. Moreover, using a generator evaluator model does not require inputting the ranking position of each item to be recommended among multiple items to be recommended. Instead, the degree of contextual dependency between each item to be recommended can be obtained through the processing within the generator evaluator model.
[0222] S310: The terminal sorts multiple recommended materials based on the recommendation score of each recommended material to obtain the target order.
[0223] S311. The terminal displays multiple materials to be recommended in the order of the target.
[0224] Among related technologies, the internet advertising field has developed rapidly in recent years, especially in personalized recommendations and precision marketing for advertising.
[0225] Personalized recommendation: With the continuous development of big data and machine learning technologies, personalized recommendation algorithms have become one of the core technologies of internet advertising systems. By analyzing user behavior data, the system can more accurately predict users' interests and needs, thereby providing more personalized advertising content.
[0226] Real-time performance: Modern advertising systems need to complete complex calculations and decisions within milliseconds to achieve real-time ad display. Advances in edge computing technology have enabled some calculations to be performed on user devices, reducing network latency and improving system response speed and user experience.
[0227] Privacy Protection: As users become more aware of privacy, protecting user privacy while providing personalized services has become a crucial issue. Technologies such as differential privacy and federated learning are widely used to ensure the security and privacy of user data.
[0228] Multimodal data processing: Modern advertising systems not only process text data, but also data in multiple modalities such as images and videos. The development of multimodal data processing technology enables advertising systems to more comprehensively understand user needs and provide richer and more diverse advertising content.
[0229] Currently, to optimize the display order of ad recommendations, a re-ranking stage is typically added after the recall, re-ranking, and fine-ranking stages of traditional recommendations to correct the ranking in the fine-ranking stage. The models used in this re-ranking stage can include, but are not limited to, Personalized re-ranking for recommendation (PRM) models or EdgeRec models.
[0230] Here, the PRM model takes the list output by the fine-ranking model as input, incorporating the positional information of each item in the list. It then uses an attention mechanism to model the relationships between different items in the list and finally reorders the items based on their attention scores. However, this type of PRM model typically runs in the cloud and cannot respond to real-time user behavior, resulting in poor recommendation performance.
[0231] The EdgeRec model can divide the recommender system into cloud services and mobile services. First, the cloud service performs feature engineering on user behavior and candidates, generating an initial recommendation list based on a neural network model. Then, the mobile service models the result list generated by the cloud service using a Gated Recurrent Unit (GRU), considering real-time user behavior, and reorders the result list to generate new recommendations. However, the GRU in this EdgeRec model focuses on the dependencies between current and historical items, but its ability to model the contextual information of the result list is weak, making it prone to losing relevant information in the result list.
[0232] The recommendation method provided in this embodiment allows a terminal to send a recommendation request to a server and receive a response from the server containing multiple items to be recommended. The terminal then uses reference information, including user actions on the terminal and / or the terminal's state, to sort the multiple items to be recommended, obtaining a target order. The multiple items are then displayed in this target order, enabling the terminal to recommend them to the user. This allows the terminal to provide real-time feedback based on real-time perception of user actions on the terminal and / or the terminal's state, and strengthens the contextual relationships between the multiple items to be recommended, effectively improving the recommendation process.
[0233] Figure 4 This is a structural block diagram of a recommended device according to an exemplary embodiment. Figure 1 See also Figure 4 The recommendation device 400 provided in this embodiment of the present disclosure is applied to a terminal and may include: a first sending module 410, a first receiving module 420, a processing module 430 and a recommendation module 440.
[0234] The first sending module 410 is configured to send a recommendation request to the server.
[0235] The first receiving module 420 is configured to receive the response result returned by the server based on the recommendation request; wherein the response result includes multiple materials to be recommended;
[0236] Processing module 430 is configured to sort multiple materials to be recommended to obtain a target order;
[0237] The recommendation module 440 is configured to display multiple materials to be recommended in target order.
[0238] The recommendation device provided in this embodiment, applied to a terminal, can send a recommendation request to a server, receive a response from the server including multiple items to be recommended, and then sort the multiple items to be recommended to obtain a target order, so as to display the multiple items to be recommended in the target order. In this way, by sorting multiple items to be recommended on the terminal and displaying them in the target order, the device can perceive the behavior and / or status of the terminal side in real time and provide real-time feedback, effectively improving the effectiveness of recommending items.
[0239] for Figure 4 In some possible implementations of the technical solution shown, the processing module 430 is specifically configured to: obtain reference information associated with the user and / or the terminal; wherein the reference information includes the user's operation behavior on the terminal and / or the terminal's operating status; and sort multiple materials to be recommended based on the reference information to obtain a target order.
[0240] for Figure 4 In some possible implementations of the technical solution shown, the processing module 430 is further configured to: extract features from the reference information to obtain reference features corresponding to the reference information; based on the reference features, sort multiple materials to be recommended using a trained sorting model to obtain the target order; wherein the trained sorting model is trained by the server and sent to the terminal.
[0241] for Figure 4 In some possible implementations of the technical solution shown, the trained ranking model includes a re-ranking model; the processing module 430 is further configured to: perform attention calculation on each material to be recommended based on reference features using the re-ranking model to obtain an attention score for each material to be recommended; and perform ranking processing on multiple materials to be recommended based on the attention score of each material to be recommended to obtain a target order.
[0242] for Figure 4 In some possible implementations of the technical solution shown, the processing module 430 is further configured to: extract the material features corresponding to each material to be recommended; concatenate the reference features with the material features corresponding to each material to be recommended and input them into the reordering model to obtain the feature vector of each material to be recommended; based on the feature vector of each material to be recommended, use an attention mechanism to construct the correlation degree between each material to be recommended, and calculate the attention weight corresponding to each material to be recommended based on the correlation degree between each material to be recommended, so as to obtain the attention score of each material to be recommended.
[0243] for Figure 4In some possible implementations of the technical solution shown, the processing module 430 is further configured to: extract features from each material to be recommended to obtain the content features of each material to be recommended; and for each material to be recommended, concatenate the content features of the material to be recommended and the features of the sorting position of the material to be recommended among multiple materials to obtain the material features corresponding to each material to be recommended.
[0244] for Figure 4 In some possible implementations of the technical solution shown, the trained ranking model includes an evaluation model; the processing module 430 is specifically configured to: extract the content features of each material to be recommended; for each material to be recommended, concatenate the reference features with the content features of the material to be recommended and input them into the evaluation model to evaluate the material to be recommended and obtain the recommendation score of the material to be recommended; based on the recommendation score of each material to be recommended, sort the multiple materials to be recommended to obtain the target order.
[0245] It should be noted that the recommendation device for terminals provided in this disclosure corresponds to the recommendation method for terminals mentioned above. Related details can be found in the description of the recommendation method for terminals above, and will not be repeated here.
[0246] Figure 5 This is a structural block diagram of a recommended device according to an exemplary embodiment. Figure 2 See also Figure 5 The recommended device 500 provided in this embodiment of the present disclosure is applied to a server and may include: a second receiving module 510, a determining module 520, and a second sending module 530.
[0247] The second receiving module 510 is configured to receive recommendation requests sent by the terminal.
[0248] Module 520 is configured to respond to a recommendation request and determine multiple materials to be recommended corresponding to the recommendation request.
[0249] The second sending module 530 is configured to return a response result to the terminal; wherein, the response result includes multiple materials to be recommended, and the response result is used by the terminal to sort the multiple materials to be recommended in order to obtain the target order before displaying it.
[0250] The recommendation device provided in this embodiment is applied to a server. It can receive recommendation requests sent by a terminal and determine multiple materials to be recommended based on the recommendation requests. It then returns a response result including multiple materials to be recommended to the terminal, enabling the terminal to sort the multiple materials to be recommended in a target order and display them. This allows the terminal to perceive the behavior and / or status of the terminal side in real time and display multiple materials to be recommended in the target order for real-time feedback, effectively improving the effect of recommending materials.
[0251] for Figure 5 In some possible implementations of the technical solution shown, the second sending module 530 is further configured to: acquire a sample dataset; wherein the sample dataset includes multiple sample reference information and multiple sample materials associated with the multiple sample reference information; train a preset neural network model based on the sample dataset to obtain a trained ranking model; and send the trained ranking model to the terminal; wherein the trained ranking model is used by the terminal to sort the multiple materials to be recommended.
[0252] for Figure 5 In some possible implementations of the technical solution shown, the second receiving module 510 is further configured to receive multiple sample reference information sent by the terminal; wherein the multiple sample reference information includes multiple sample user sample operation behaviors on the terminal and / or the sample operation behaviors associated with the terminal sample operation status.
[0253] It should be noted that the recommendation device applied to the server provided in this embodiment corresponds to the recommendation method applied to the server mentioned above. Related content can be found in the description of the recommendation method applied to the server above, and will not be repeated here.
[0254] Figure 6 This is a schematic diagram illustrating the structure of a terminal according to an exemplary embodiment. For example, terminal 600 may be a mobile phone, computer, digital broadcasting terminal, messaging device, game console, tablet device, medical device, fitness equipment, personal digital assistant, etc.
[0255] Reference Figure 6 The terminal 600 may include one or more of the following components: processing component 602, memory 604, power supply component 606, multimedia component 608, audio component 610, input / output (I / O) interface 612, sensor component 614, and communication component 616.
[0256] Processing component 602 typically controls the overall operation of terminal 600, such as operations associated with at least one of display, telephone call, data communication, camera operation, and recording operation. Processing component 602 may include one or more processors 620 to execute instructions to perform all or part of the steps of the methods described above. Furthermore, processing component 602 may include one or more modules to facilitate interaction between processing component 602 and other components. For example, processing component 602 may include a multimedia module to facilitate interaction between multimedia component 608 and processing component 602.
[0257] Memory 604 is configured to store various types of data to support operation on terminal 600. Examples of such data include at least one of the following: instructions for any application or method operating on terminal 600, contact data, phonebook data, messages, pictures, and videos. Memory 604 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read Only Memory (EEPROM), Erasable Programmable Read-Only Memory (EPROM), Programmable Read Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0258] Power supply component 606 provides power to various components of terminal 600. Power supply component 606 may include at least one of the following: a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to terminal 600.
[0259] Multimedia component 608 includes a screen that provides an output interface between terminal 600 and the user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a Touch Panel, the screen may be implemented as a touchscreen to receive input signals from the user. The Touch Panel includes one or more touch sensors to sense touches, swipes, and gestures on the Touch Panel. The touch sensors may sense not only the boundaries of touch or swipe actions but also the duration and pressure associated with the touch or swipe operation. In some embodiments, multimedia component 608 includes a front-facing camera and / or a rear-facing camera. When terminal 600 is in an operating mode, such as a shooting mode or a video mode, the front-facing camera and / or rear-facing camera may receive external multimedia data. Each front-facing camera and rear-facing camera may be a fixed optical lens system or have focal length and optical zoom capabilities.
[0260] Audio component 610 is configured to output and / or input audio signals. For example, audio component 610 includes a microphone (MIC) configured to receive external audio signals when terminal 600 is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals may be further stored in memory 604 or transmitted via communication component 616. In some embodiments, audio component 610 also includes a speaker for outputting audio signals.
[0261] I / O interface 612 provides an interface between processing component 602 and peripheral interface modules, such as keyboards, click wheels, and buttons. These buttons may include, but are not limited to, home buttons, volume buttons, power buttons, and lock buttons.
[0262] Sensor assembly 614 includes one or more sensors for providing state assessments of various aspects of terminal 600. For example, sensor assembly 614 may detect the on / off state of terminal 600, the relative positioning of components such as the display and keypad of terminal 600, changes in position of terminal 600 or one of its components, the presence or absence of user contact with terminal 600, orientation or acceleration / deceleration of terminal 600, and temperature changes of terminal 600. Sensor assembly 614 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. Sensor assembly 614 may also include an optical sensor, such as a complementary metal-oxide-semiconductor (CMOS) or charge-coupled device (CCD) image sensor, for use in imaging applications. In some embodiments, sensor assembly 614 may also include, but is not limited to, at least one of the following: an accelerometer, a gyroscope, a magnetometer, a pressure sensor, and a temperature sensor.
[0263] Communication component 616 is configured to facilitate wired or wireless communication between terminal 600 and other devices. Terminal 600 can access wireless networks based on communication standards, such as Wi-Fi, 4G, 5G, or combinations thereof. In one exemplary embodiment, communication component 616 receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, communication component 616 also includes a Near Field Communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID), Infrared Data Association (IrDA), Ultra Wide Band (UWB), Bluetooth (BT), and other technologies.
[0264] In an exemplary embodiment, terminal 600 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components.
[0265] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory including executable instructions or a computer program that can be executed by a terminal's processor to perform the recommended method. For example, the non-transitory computer-readable storage medium may be a ROM, random access memory (RAM), a compact disc read-only memory (CD-ROM), magnetic tape, floppy disk, and optical data storage device, etc.
[0266] A non-transitory computer-readable storage medium, when the instructions in the storage medium are executed by the processor of a terminal, enables the terminal to execute any of the recommendation methods described in the above embodiments. For example, the recommendation method includes: sending a recommendation request to a server; receiving a response result returned by the server based on the recommendation request; wherein the response result includes multiple items to be recommended; sorting the multiple items to be recommended to obtain a target order; and displaying the multiple items to be recommended in the target order.
[0267] Figure 7 This is a schematic diagram illustrating the structure of a server according to an exemplary embodiment. For example, server 700 can be provided as a cloud server. (Refer to...) Figure 7 The server 700 includes a processing component 722, which further includes one or more processors, and memory resources represented by memory 732 for storing instructions executable by the processing component 722, such as application programs. The application programs stored in memory 732 may include one or more modules, each corresponding to a set of instructions. Furthermore, the processing component 722 is configured to execute instructions to perform any of the aforementioned recommendation methods. For example, the recommendation method includes: receiving a recommendation request sent by a terminal; in response to the recommendation request, determining multiple items to be recommended corresponding to the recommendation request; returning a response result to the terminal; wherein the response result includes multiple items to be recommended, and the response result is used by the terminal to sort the multiple items to be recommended to obtain a target order before displaying them.
[0268] The server 700 may also include a power supply component 726 configured to perform power management for the server 700, a wired or wireless network interface 750 configured to connect the server 700 to a network, and an input / output (I / O) interface 758. The server 700 can operate an operating system stored in memory 732, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, or similar.
[0269] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory including executable instructions or a computer program that can be executed by a server processor to perform the recommended method. For example, the non-transitory computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a compact disc read-only memory (CD-ROM), magnetic tape, floppy disk, and optical data storage device, etc.
[0270] A non-transitory computer-readable storage medium, when the instructions in the storage medium are executed by the processor of a server, enables the server to execute any of the recommendation methods described in the above embodiments. For example, the recommendation method includes: receiving a recommendation request sent by a terminal; in response to the recommendation request, determining multiple items to be recommended corresponding to the recommendation request; and returning a response result to the terminal; wherein the response result includes multiple items to be recommended, and the response result is used by the terminal to sort the multiple items to be recommended to obtain a target order before displaying them.
[0271] This disclosure provides a computer program product comprising a computer program or executable instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer program or executable instructions from the computer-readable storage medium and executes the computer program or executable instructions, causing the computer device to perform any of the recommended methods for the terminal or server described in the above embodiments.
[0272] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this disclosure are indicated by the claims.
[0273] It should be understood that this disclosure is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this disclosure is limited only by the appended claims.
Claims
1. A recommendation method characterized by comprising: include: Send a recommendation request to the server; Receive the response result returned by the server based on the recommendation request; wherein the response result includes multiple materials to be recommended; The multiple materials to be recommended are sorted to obtain the target order; The multiple recommended materials are displayed in the order of the target.
2. The method of claim 1, wherein, The process of sorting the multiple materials to be recommended to obtain the target order includes: Obtain reference information associated with the user and / or the terminal; wherein the reference information includes the user's operation behavior on the terminal and / or the terminal's operating status; Based on the reference information, the multiple materials to be recommended are sorted to obtain the target order.
3. The method of claim 2, wherein, The process of sorting the plurality of materials to be recommended based on the reference information to obtain the target order includes: Feature extraction is performed on the reference information to obtain the reference features corresponding to the reference information; Based on the reference features, the multiple materials to be recommended are sorted using the trained sorting model to obtain the target order; wherein, the trained sorting model is trained by the server and sent to the terminal.
4. The method of claim 3, wherein, The trained ranking model includes a re-ranking model; the step of ranking the multiple materials to be recommended based on the reference features using the trained ranking model to obtain the target order includes: Based on the reference features, the attention calculation is performed on each material to be recommended using the re-ranking model to obtain the attention score of each material to be recommended. Based on the attention score of each material to be recommended, the multiple materials to be recommended are sorted to obtain the target order.
5. The method of claim 4, wherein, The step of calculating the attention score for each recommended material based on the reference features using the re-ranking model to obtain an attention score for each recommended material includes: Extract the material features corresponding to each material to be recommended; The reference features are concatenated with the material features corresponding to each material to be recommended and then input into the re-ranking model to obtain the feature vector of each material to be recommended. Based on the feature vector of each material to be recommended, an attention mechanism is used to construct the correlation between each material to be recommended, and the attention weight corresponding to each material to be recommended is calculated based on the correlation between each material to be recommended, so as to obtain the attention score of each material to be recommended.
6. The method of claim 5, wherein, The extraction of material features corresponding to each material to be recommended includes: Feature extraction is performed on each of the materials to be recommended to obtain the content features of each material to be recommended. For each material to be recommended, the content features of the material to be recommended and the features of the sorting position of the material to be recommended among the multiple materials to be recommended are concatenated to obtain the material features corresponding to each material to be recommended.
7. The method of claim 3, wherein, The trained ranking model includes an evaluation model; the process of ranking the multiple materials to be recommended based on the reference features using the trained ranking model to obtain the target order includes: Extract the content features of each material to be recommended; For each material to be recommended, the reference features are concatenated with the content features of the material to be recommended and then input into the evaluation model to evaluate the material to be recommended and obtain the recommendation score of the material to be recommended. Based on the recommendation score of each material to be recommended, the multiple materials to be recommended are sorted to obtain the target order.
8. A recommendation method characterized by comprising: include: Receive recommendation requests sent by the terminal; In response to the recommendation request, determine multiple materials to be recommended corresponding to the recommendation request; The system returns a response result to the terminal; wherein the response result includes the plurality of materials to be recommended, and the response result is used by the terminal to sort the plurality of materials to be recommended in order to obtain a target order before displaying them.
9. The method according to claim 8, characterized in that, The method further includes: Obtain a sample dataset; wherein the sample dataset includes multiple sample reference information and multiple sample materials associated with the multiple sample reference information; Based on the sample dataset, a preset neural network model is trained to obtain a trained ranking model; The trained ranking model is sent to the terminal; wherein the trained ranking model is used by the terminal to rank the received plurality of materials to be recommended.
10. The method according to claim 9, characterized in that, The method further includes: The terminal sends multiple sample reference information; wherein, the multiple sample reference information includes sample operation behaviors of multiple sample users on the terminal and / or the sample operation behaviors associated with the terminal's sample running status.
11. A recommendation device, characterized in that, include: The first sending module is configured to send recommendation requests to the server; The first receiving module is configured to receive the response result returned by the server based on the recommendation request; wherein the response result includes multiple materials to be recommended; The processing module is configured to sort the multiple materials to be recommended to obtain a target order; The recommendation module is configured to display the multiple materials to be recommended in the order of the target.
12. The apparatus according to claim 11, characterized in that, The processing module is specifically configured as follows: Obtain reference information associated with the user and / or the terminal; wherein the reference information includes the user's operation behavior on the terminal and / or the terminal's operating status; Based on the reference information, the multiple materials to be recommended are sorted to obtain the target order.
13. The apparatus according to claim 12, characterized in that, The processing module is further configured to: Feature extraction is performed on the reference information to obtain the reference features corresponding to the reference information; Based on the reference features, the multiple materials to be recommended are sorted using the trained sorting model to obtain the target order; wherein, the trained sorting model is trained by the server and sent to the terminal.
14. A recommendation device, characterized in that, include: The second receiving module is configured to receive recommendation requests sent by the terminal; The determination module is configured to determine, in response to the recommendation request, multiple materials to be recommended corresponding to the recommendation request; The second sending module is configured to return a response result to the terminal; wherein the response result includes the plurality of materials to be recommended, and the response result is used by the terminal to sort the plurality of materials to be recommended in order to obtain a target order before displaying them.
15. The apparatus according to claim 14, characterized in that, The second sending module is also configured as follows: Obtain a sample dataset; wherein the sample dataset includes multiple sample reference information and multiple sample materials associated with the multiple sample reference information; Based on the sample dataset, a preset neural network model is trained to obtain a trained ranking model; The trained ranking model is sent to the terminal; wherein the trained ranking model is used by the terminal to rank the received plurality of materials to be recommended.
16. The apparatus according to claim 14, characterized in that, The second receiving module is also configured as follows: The terminal sends multiple sample reference information; wherein, the multiple sample reference information includes sample operation behaviors of multiple sample users on the terminal and / or the sample operation behaviors associated with the terminal's sample running status.
17. An electronic device, characterized in that, include: processor; Memory used to store computer programs or instructions; The processor executes the computer program or instructions to implement the steps of the method according to any one of claims 1 to 7 or any one of claims 8 to 10.
18. A non-transitory computer-readable storage medium storing a computer program or instructions, characterized in that, When the computer program or instructions in the storage medium are executed by a processor, the steps of the method of any one of claims 1 to 7 or any one of claims 8 to 10 are implemented.
19. A computer program product comprising a computer program or instructions, characterized in that, When the computer program or instructions are executed by a processor, they implement the steps of the method according to any one of claims 1 to 7 or any one of claims 8 to 10.
