


























技术领域technical field
本申请涉及人工智能领域,尤其涉及一种推荐方法及相关装置。This application relates to the field of artificial intelligence, in particular to a recommendation method and related devices.
背景技术Background technique
人工智能(artificial intelligence,AI)是利用数字计算机或者数字计算机控制的机器模拟、延伸和扩展人的智能,感知环境、获取知识并使用知识获得最佳结果的理论、方法、技术及应用系统。换句话说,人工智能是计算机科学的一个分支,它企图了解智能的实质,并生产出一种新的能以人类智能相似的方式作出反应的智能机器。人工智能也就是研究各种智能机器的设计原理与实现方法,使机器具有感知、推理与决策的功能。Artificial intelligence (AI) is a theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is the branch of computer science that attempts to understand the nature of intelligence and produce a new class of intelligent machines that respond in ways similar to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines, so that the machines have the functions of perception, reasoning and decision-making.
选择率预测,是指预测用户在特定环境下对某个物品的选择概率。例如,应用商店、在线广告等应用的推荐系统中,选择率预测起到关键作用;通过选择率预测可以实现最大化企业的收益和提升用户满意度,推荐系统需同时考虑用户对物品的选择率和物品竞价,其中,选择率为推荐系统根据用户历史行为预测得到,而物品竞价代表该物品被选择/下载后系统的收益。例如,可以通过构建一个函数,该函数可以根据预测的用户选择率和物品竞价计算得到一个函数值,推荐系统按照该函数值对物品进行降序排列。Selection rate prediction refers to predicting the probability of a user's selection of an item in a specific environment. For example, in the recommendation system of application stores, online advertisements and other applications, the selection rate prediction plays a key role; through the selection rate prediction, the enterprise's revenue can be maximized and user satisfaction can be improved. The recommendation system needs to consider the user's selection rate of items at the same time And item bidding, where the selection rate is predicted by the recommendation system based on the user's historical behavior, and the item bidding represents the revenue of the system after the item is selected/downloaded. For example, by constructing a function, the function can calculate a function value based on the predicted user selection rate and item bidding, and the recommendation system sorts the items in descending order according to the function value.
然而,选择率预测只能表征出用户选择物品的概率,基于该信息进行的物品推荐结果并不准确。However, the selection rate prediction can only represent the probability of the user selecting an item, and the item recommendation result based on this information is not accurate.
发明内容Contents of the invention
第一方面,本申请提供了一种推荐方法,所述方法包括:In a first aspect, the present application provides a recommended method, the method comprising:
获取目标用户的第一操作信息集,所述第一操作信息集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标用户对所述多个物品进行的操作的操作类型;Obtain a first operation information set of the target user, the first operation information set includes attribute information of multiple items, multiple operation types, and correspondence between the multiple items and the multiple operation types, the correspondence The relationship is used to represent the type of operation performed by the target user on the plurality of items;
其中,目标用户的属性信息可以为与用户喜好特征相关的属性,性别、年龄、职业、收入、爱好以及受教育程度中的至少一种,其中,性别可以为男或者女,年龄可以为0-100之间的数字,职业可以为教师、程序员、厨师等等,爱好可以为篮球、网球、跑步等等,受教育程度可以为小学、初中、高中、大学等等;本申请并不限定目标用户的属性信息的具体类型;Among them, the attribute information of the target user can be attributes related to user preferences, at least one of gender, age, occupation, income, hobbies, and education level, where the gender can be male or female, and the age can be 0- Number between 100, occupation can be teacher, programmer, chef, etc., hobbies can be basketball, tennis, running, etc., education level can be elementary school, junior high school, high school, university, etc.; this application does not limit the target Specific types of user attribute information;
其中,物品可以为实体物品,或者是虚拟物品,例如可以为APP、音视频、网页以及新闻资讯等物品,物品的属性信息可以为物品名称、开发者、安装包大小、品类以及好评度中的至少一种,其中,以物品为应用程序为例,物品的品类可以为聊天类、跑酷类游戏、办公类等等,好评度可以为针对于物品的打分、评论等;本申请并不限定物品的属性信息的具体类型;Among them, the item can be a physical item or a virtual item, for example, it can be an item such as APP, audio and video, web page, and news information, and the attribute information of the item can be item name, developer, installation package size, category, and favorable rating. At least one, wherein, taking an item as an example of an application program, the category of the item can be chatting, parkour games, office, etc., and the favorable rating can be scoring, commenting, etc. for the item; this application does not limit The specific type of attribute information of the item;
其中,操作类型可以为目标用户针对于物品的行为操作类型,在网络平台和应用上,用户往往和物品有多种多样的交互形式(也就是有多种操作类型),比如图5所示用户在电商平台行为中的浏览、点击、加入购物车、购买等操作类型。这些多种多样的行为反映了用户的偏好,对于准确的刻画用户特征有很大的帮助;应理解,能够反映用户针对于物品存在喜好倾向的操作类型也可以称之为正向操作类型;Among them, the operation type can be the behavior operation type of the target user for the item. On the network platform and application, the user often has a variety of interaction forms with the item (that is, there are multiple operation types), such as the user shown in Figure 5 Operation types such as browsing, clicking, adding to shopping cart, and purchasing in e-commerce platform behaviors. These various behaviors reflect the user's preferences, which are of great help to accurately characterize the user's characteristics; it should be understood that the type of operation that can reflect the user's preference for items can also be called the positive operation type;
应理解,本申请实施例中的操作类型的数据呈现状态可以是特征向量(本申请实施例中也可以称之为操作类型特征向量),其中,操作类型特征向量可以在目标推荐模型的训练过程中被更新,并在目标推荐模型收敛(或者满足数据处理精度要求)后得到,在目标推荐模型的训练过程中,操作类型特征向量的泛化性不断增强,当目标推荐模型收敛后,操作类型特征向量可以具备很强的泛化性,其中,所谓具备很强的泛化性,是指操作类型特征向量可以适用于目标推荐模型进行新用户以及新物品之间的操作的概率预测,且概率预测的精准度很高;It should be understood that the data presentation status of the operation type in the embodiment of the present application may be a feature vector (also referred to as the operation type feature vector in the embodiment of the present application), wherein the operation type feature vector may be used in the training process of the target recommendation model is updated and obtained after the target recommendation model converges (or meets the data processing accuracy requirements). During the training process of the target recommendation model, the generalization of the operation type feature vector continues to increase. When the target recommendation model converges, the operation type The eigenvectors can have strong generalization. The so-called strong generalization means that the operation type eigenvectors can be applied to the target recommendation model to predict the probability of operations between new users and new items, and the probability The prediction accuracy is very high;
应理解,每个操作类型可以对应有一个操作类型特征向量,且在进行目标推荐模型的模型推理时,每个操作类型对应的操作类型特征向量可以是固化不变的;It should be understood that each operation type may correspond to an operation type feature vector, and when performing model reasoning of the target recommendation model, the operation type feature vector corresponding to each operation type may be fixed;
应理解,操作类型特征向量可以用于生成目标用户特征向量以及目标物品特征向量,也可以单独作为目标推荐模型的输入,目标推荐模型可以根据目标用户特征向量、目标物品特征向量以及操作类型特征向量,来计算目标用户对所述目标物品进行操作类型特征向量对应的操作类型的操作的概率。It should be understood that the operation type feature vector can be used to generate the target user feature vector and the target item feature vector, and can also be used as the input of the target recommendation model alone. The target recommendation model can be based on the target user feature vector, the target item feature vector and the operation type feature vector , to calculate the probability that the target user performs an operation of the operation type corresponding to the operation type feature vector on the target item.
根据所述第一操作信息集进行特征提取确定目标用户特征向量;performing feature extraction according to the first operation information set to determine a target user feature vector;
获取目标物品的第二操作信息集,所述第二操作信息集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;Acquire a second operation information set of the target item, the second operation information set includes attribute information of multiple users, the multiple operation types, and the correspondence between the multiple users and the multiple operation types, so The corresponding relationship is used to indicate the type of operation performed by the multiple users on the target item;
根据所述第二操作信息集进行特征提取确定目标物品特征向量;performing feature extraction according to the second operation information set to determine the feature vector of the target item;
根据所述目标用户目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,所述推荐信息用于表示所述目标用户对所述目标物品进行所述多个操作类型的操作的概率;According to the target user feature vector of the target user and the target item feature vector, based on the target recommendation model, output recommendation information, where the recommendation information is used to indicate the target user's performance of the multiple operation types on the target item. probability of operation;
当推荐信息满足预设条件,确定向所述目标用户推荐所述目标物品。When the recommendation information satisfies the preset condition, it is determined to recommend the target item to the target user.
在一种可能的实现中,在对目标用户进行信息推荐时,可以计算得到目标用户对多个物品(包括目标物品)进行多个操作类型的概率,并基于多个操作类型的概率来确定各个物品的对于该目标用户的推荐指数。In a possible implementation, when recommending information to a target user, the probability that the target user performs multiple types of operations on multiple items (including the target item) can be calculated, and each operation type is determined based on the probabilities of multiple operation types. The item's recommendation index for the target user.
在一种可能的实现中,可以选择目标用户对各个物品的多个操作类型的概率中的最大概率来表征各个物品对目标用户的推荐指数;In a possible implementation, the maximum probability among the probabilities of multiple operation types performed by the target user on each item can be selected to represent the recommendation index of each item to the target user;
在一种可能的实现中,可以计算目标用户对各个物品的多个操作类型的概率的综合值来表征各个物品对目标用户的推荐指数,综合值可以是基于加权求和的方式,具体可以对各个操作类型设置对应的权重,例如购买操作的权重大于加入购物车操作的权重,之后可以结合各个操作类型对应的权重以及各个操作类型对应的概率基于加权求和来得到各个操作类型的推荐指数;In a possible implementation, the comprehensive value of the probabilities of multiple operation types performed by the target user on each item can be calculated to represent the recommendation index of each item to the target user. The comprehensive value can be based on a weighted summation method. Specifically, Set the corresponding weight for each operation type, for example, the weight of the purchase operation is greater than the weight of the add to shopping cart operation, and then you can combine the weights corresponding to each operation type and the probability corresponding to each operation type to obtain the recommendation index of each operation type based on weighted summation;
在得到各个物品的对于该目标用户的推荐指数之后,可以对推荐指数进行排序,并向目标用户推荐推荐指数最大的M个物品(包括目标物品)。After obtaining the recommendation index of each item for the target user, the recommendation index can be sorted, and M items (including the target item) with the highest recommendation index can be recommended to the target user.
在一种可能的实现中,还可以选择可以设置一个概率阈值,当目标用户对目标物品的多种操作类型的概率中有至少一个操作类型对应的概率大于上述概率阈值,就可以向所述目标用户推荐所述目标物品。In a possible implementation, you can also choose to set a probability threshold. When the target user has a probability corresponding to at least one operation type among the multiple operation types of the target item that is greater than the above probability threshold, you can send a message to the target. The user recommends the target item.
在进行信息推荐时,可以以列表页的形式将推荐信息推荐给用户,以期望用户进行行为动作。When recommending information, the recommended information can be recommended to the user in the form of a list page, so as to expect the user to take a behavioral action.
本申请基于存在关联关系的物品和操作类型来生成表征目标用户喜好的目标用户特征向量,以及基于存在关联关系的用户和操作类型来生成表征目标物品对用户的吸引力特征的第二特征向量,来预测目标用户对目标物品的进行多个操作类型的操作的概率,可以更准确的刻画出用户针对于物品的操作概率。This application generates a target user feature vector representing the preferences of the target user based on the associated items and operation types, and generates a second feature vector representing the attractiveness of the target item to the user based on the associated users and operation types, To predict the probability of the target user performing multiple types of operations on the target item, it can more accurately describe the user's operation probability for the item.
在一种可能的实现中,所述根据所述第一操作信息集进行特征提取确定目标用户特征向量,包括:In a possible implementation, the performing feature extraction according to the first operation information set to determine the target user feature vector includes:
根据所述第一操作信息集确定多个子用户特征向量,其中,每个子用户特征向量为对存在对应关系的物品的属性信息和操作类型进行特征提取得到的;Determining a plurality of sub-user feature vectors according to the first operation information set, wherein each sub-user feature vector is obtained by feature extraction of attribute information and operation types of items with corresponding relationships;
对所述多个子用户特征向量进行融合,得到所述目标用户特征向量。The multiple sub-user feature vectors are fused to obtain the target user feature vector.
在一种可能的实现中,所述第一操作信息集包括:第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;进而可以基于第一物品的属性信息与第一操作类型来计算得到一个子用户特征向量(第一子用户特征向量)。通过上述方式,可以得到多个子用户特征向量,其中一部分子用户特征向量可以认为是目标用户的一阶特征向量(基于真实的操作信息,例如第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系),一部分子用户特征向量可以认为是目标用户的二阶特征向量(基于预测的操作信息,例如第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系),类似的,还可以得到目标用户更高阶的特征向量。In a possible implementation, the first operation information set includes: the attribute information of the first item, the first operation type, and the correspondence between the first item and the first operation type; The attribute information of an item and the first operation type are used to calculate a sub-user feature vector (first sub-user feature vector). Through the above method, multiple sub-user feature vectors can be obtained, and some of the sub-user feature vectors can be considered as the first-order feature vectors of the target user (based on real operation information, such as the attribute information of the first item, the first operation type, and all The corresponding relationship between the first item and the first operation type), a part of the sub-user feature vector can be considered as the second-order feature vector of the target user (based on the predicted operation information, such as the attribute information of the second item, the second operation type , and the correspondence between the second item and the second operation type), similarly, a higher-order feature vector of the target user can also be obtained.
在一种可能的实现中,各个子用户特征向量都可以表征目标用户的喜好特征,因此可以将多个子用户特征向量进行融合,针对于同一阶的子用户特征向量,可以采用激活函数来进行融合,针对于同一阶的子用户特征向量融合可以得到的一个特征向量结果,针对于多个阶的子用户特征向量可以得到多个特征向量结果,进而可以对多个特征向量结果进行融合(例如可以基于不同的权重进行融合,例如阶数小的特征向量由于可以更准确的刻画目标用户的特征,融合时的权重可以设置的较大),得到目标用户特征向量,其中,融合可以但不限于为加和以及拼接操作(concat)。In a possible implementation, each sub-user feature vector can represent the preferences of the target user, so multiple sub-user feature vectors can be fused, and for the sub-user feature vectors of the same order, an activation function can be used for fusion , for one eigenvector result that can be obtained from the sub-user eigenvector fusion of the same order, multiple eigenvector results can be obtained for multiple order sub-user eigenvectors, and then multiple eigenvector results can be fused (for example, you can Fusion based on different weights, for example, the feature vector with a small order can more accurately describe the characteristics of the target user, the weight of the fusion can be set to be larger), and the target user feature vector is obtained, where the fusion can be but not limited to Addition and concatenation operations (concat).
在一种可能的实现中,所述根据所述第二操作信息集进行特征提取确定目标物品特征向量,包括:In a possible implementation, the performing feature extraction according to the second operation information set to determine the feature vector of the target item includes:
根据所述第二操作信息集确定多个子物品特征向量,其中,每个子物品特征向量为对存在对应关系的用户的属性信息和操作类型进行特征提取得到的;对所述多个子物品特征向量进行融合,得到所述目标物品特征向量。Determine a plurality of sub-item feature vectors according to the second operation information set, wherein each sub-item feature vector is obtained by performing feature extraction on attribute information and operation types of users with corresponding relationships; Fusion to obtain the feature vector of the target item.
在一种可能的实现中,可以基于存在对应关系的用户的属性信息和操作类型进行特征提取得到一个子物品特征向量,其中,子物品特征向量可以表征目标物品针对于用户的吸引力特征,进而可以得到多个子物品特征向量,并对所述多个子物品特征向量进行融合,得到所述第二特征向量。In a possible implementation, a sub-item feature vector can be obtained by performing feature extraction based on the corresponding user attribute information and operation type, wherein the sub-item feature vector can represent the attractive feature of the target item for the user, and then Multiple sub-item feature vectors may be obtained, and the multiple sub-item feature vectors are fused to obtain the second feature vector.
通过上述方式,可以得到多个子物品特征向量,其中一部分子物品特征向量可以认为是目标物品的一阶特征向量(基于真实的操作信息,例如上述第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系),一部分子物品特征向量可以认为是目标物品的二阶特征向量(基于预测的操作信息,例如上述第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系),类似的,还可以得到目标物品更高阶的特征向量。Through the above method, multiple sub-item eigenvectors can be obtained, and some of the sub-item eigenvectors can be considered as the first-order eigenvectors of the target item (based on real operation information, such as the above-mentioned attribute information of the second user, the fourth forward operation type , and the corresponding relationship between the second user and the fourth positive operation type), a part of the sub-item feature vectors can be considered as the second-order feature vectors of the target item (based on the predicted operation information, such as the attribute of the third user above information, the fifth operation type, and the correspondence between the third user and the fifth operation type), similarly, a higher-order feature vector of the target item can also be obtained.
在一种可能的实现中,各个子物品特征向量都可以表征目标物品对于用户的吸引力特征,因此可以将多个子物品特征向量进行融合,针对于同一阶的子物品特征向量,可以采用激活函数来进行融合,针对于同一阶的子物品特征向量融合可以得到的一个特征向量结果,针对于多个阶的子物品特征向量可以得到多个特征向量结果,进而可以对多个特征向量结果进行融合(例如可以基于不同的权重进行融合,例如阶数小的特征向量由于可以更准确的刻画目标物品的特征,融合时的权重可以设置的较大),得到第二特征向量,其中,融合可以但不限于为加和以及拼接操作(concat)。In a possible implementation, each sub-item feature vector can represent the attractiveness of the target item to the user, so multiple sub-item feature vectors can be fused, and for the sub-item feature vectors of the same order, the activation function can be used For fusion, one eigenvector result can be obtained for the sub-item eigenvector fusion of the same order, and multiple eigenvector results can be obtained for multiple order sub-item eigenvectors, and then multiple eigenvector results can be fused (For example, it can be fused based on different weights. For example, the eigenvector with a small order can more accurately describe the characteristics of the target item, and the weight during fusion can be set larger), and the second eigenvector is obtained. Wherein, the fusion can be Not limited to addition and concatenation operations (concat).
在一种可能的实现中,所述根据所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,包括:根据所述多个操作类型的多个操作类型特征向量,所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息。In a possible implementation, the outputting recommendation information based on the target recommendation model according to the target user feature vector and the target item feature vector includes: multiple operation type feature vectors according to the multiple operation types , the target user feature vector and the target item feature vector, based on the target recommendation model, output recommendation information.
在一种可能的实现中,目标推荐模型可以计算目标用户的目标用户特征向量与目标物品特征向量之间的相似度,然后再计算目标用户特征向量、目标物品特征向量以及操作类型特征向量三者之间的相似度。In a possible implementation, the target recommendation model can calculate the similarity between the target user feature vector and the target item feature vector of the target user, and then calculate the target user feature vector, target item feature vector and operation type feature vector similarity between.
在一种可能的实现中,所述获取所述第一操作信息集包括:获取第一操作信息子集和第二操作信息子集;其中,所述第一操作信息子集中包括,第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;所述第一操作类型为所述目标用户对所述第一物品的真实操作类型;所述第二操作信息子集包括,第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;所述第二操作类型为所述目标用户对所述第二物品的预测操作类型;所述根据所述第一操作信息集确定多个子用户特征向量,包括:根据所述第一操作信息子集确定第一子用户特征向量;根据所述第二操作信息子集确定第二子用户特征向量。In a possible implementation, the acquiring the first operation information set includes: acquiring a first operation information subset and a second operation information subset; wherein, the first operation information subset includes the first item The attribute information of the first operation type, and the corresponding relationship between the first item and the first operation type; the first operation type is the actual operation type of the target user on the first item; the The second operation information subset includes the attribute information of the second item, the second operation type, and the correspondence between the second item and the second operation type; The predicted operation type of the second item; the determining a plurality of sub-user feature vectors according to the first operation information set includes: determining a first sub-user feature vector according to the first operation information subset; according to the second The subset of operation information determines the second sub-user feature vector.
也就是说,上述第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系是基于目标用户的真实操作记录中得到的。That is to say, the attribute information of the first item, the first operation type, and the correspondence between the first item and the first operation type are obtained based on the real operation records of the target user.
由于能够获取到的与用户相关的历史操作记录有限,为了提高信息推荐的精准度,可以在有限的历史操作数据中发掘更丰富的信息,进而生成更多的与用户相关的操作信息,进而可以提高历史操作记录的数据利用率。Due to the limited historical operation records that can be obtained related to users, in order to improve the accuracy of information recommendation, more abundant information can be discovered in the limited historical operation data, and then more user-related operation information can be generated, which can further improve the accuracy of information recommendation. Improve the data utilization rate of historical operation records.
在一种可能的实现中,所述对所述多个子物品特征向量进行融合,包括:根据所述第一子用户特征向量的第一权重以及所述第二子用户特征向量的第二权重,对所述第一子用户特征向量和所述第二子用户特征向量进行融合。In a possible implementation, the fusing the multiple sub-item feature vectors includes: according to the first weight of the first sub-user feature vector and the second weight of the second sub-user feature vector, The first sub-user feature vector and the second sub-user feature vector are fused.
本申请实施例可以基于不同的权重进行子用户特征向量的融合,针对于用户的真实操作数据得到的子用户特征向量(例如上述第一子用户特征向量),由于可以更准确的刻画目标用户的特征,则可以将权重设置的较大,针对于用户的预测操作数据得到的子用户特征向量(例如上述第二子用户特征向量),由于可以不一定可以准确的刻画目标用户的特征,则可以将权重设置的较小,此外,用户的预测操作数据得到的子用户特征向量,针对于预测的阶数(例如基于5个用户之间的喜好程度相似性得到的预测操作数据,相比仅基于2个用户之间的喜好程度相似性得到的预测操作数据的阶数更高)不同,也可以设置不同的权重,阶数越高,则权重越小;此外,上述阶数还可以在训练目标推荐模型时作为前馈流程的一部分来调节各个阶数的子用户特征向量在融合时的占比,且在训练时不断被更新,当目标推荐模型收敛后,可以得到针对于不同阶数的权重,该权重能够调节各个阶数的子用户特征向量在融合时的占比,以得到一个能够准确刻画用户喜好特征的目标用户特征向量。In the embodiment of the present application, the sub-user feature vectors can be fused based on different weights. The sub-user feature vectors (such as the above-mentioned first sub-user feature vectors) obtained from the user's real operation data can more accurately describe the target user. feature, the weight can be set larger, and the sub-user feature vector (such as the above-mentioned second sub-user feature vector) obtained from the user's predicted operation data may not be able to accurately describe the characteristics of the target user, then it can be Set the weight to be smaller. In addition, the sub-user feature vector obtained from the user's predicted operation data is aimed at the order of prediction (for example, the predicted operation data obtained based on the similarity of preferences between 5 users is compared with only based on The order of the predicted operation data obtained by the similarity of preferences between two users is higher), and different weights can also be set. The higher the order, the smaller the weight; in addition, the above order can also be used in the training target When recommending a model, it is used as a part of the feed-forward process to adjust the proportion of sub-user feature vectors of each order during fusion, and it is continuously updated during training. When the target recommendation model converges, weights for different orders can be obtained , the weight can adjust the proportion of the sub-user feature vectors of each order in the fusion, so as to obtain a target user feature vector that can accurately describe the characteristics of user preferences.
在一种可能的实现中,各个子用户特征向量都可以表征目标用户的喜好特征,因此可以将多个子用户特征向量进行融合,针对于同一阶的子用户特征向量,可以采用激活函数来进行融合,针对于同一阶的子用户特征向量融合可以得到的一个特征向量结果,针对于多个阶的子用户特征向量可以得到多个特征向量结果,进而可以对多个特征向量结果进行融合,得到目标用户特征向量,其中,融合可以但不限于为加和以及拼接操作(concat)。In a possible implementation, each sub-user feature vector can represent the preferences of the target user, so multiple sub-user feature vectors can be fused, and for the sub-user feature vectors of the same order, an activation function can be used for fusion , for one eigenvector result that can be obtained by merging sub-user eigenvectors of the same order, multiple eigenvector results can be obtained for sub-user eigenvectors of multiple orders, and then multiple eigenvector results can be fused to obtain the target User feature vector, where fusion can be, but not limited to, summation and concatenation operations (concat).
在一种可能的实现中,所述获取第二操作信息子集包括:获取所述第二操作类型;所述获取所述第二操作类型,具体为:获取第一用户对第二物品的第三操作类型,所述第一用户为所述目标用户的物品喜好特征满足预设条件的用户;基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型。In a possible implementation, the obtaining the second operation information subset includes: obtaining the second operation type; the obtaining the second operation type is specifically: obtaining the first user's second item on the second item Three operation types, the first user is a user whose item preference characteristics of the target user meet a preset condition; based on the third operation type of the first user for the second item, the first user is acquired Two types of operation.
在一种可能的实现中,所述预设条件可以包括所述第一用户和所述目标用户均为对所述第一物品有操作的用户。In a possible implementation, the preset condition may include that both the first user and the target user are users who operate on the first item.
当不同的用户(例如第一用户和所述目标用户)针对于同一件物品进行了操作时,可以表征出这两个用户有较大可能性具备相同或者相似的喜好,因此可以基于第一用户对于其他物品的操作信息来生成目标用户相关的操作信息,这部分生成的新的和目标用户相关的操作信息虽然不是历史操作记录中的,但是大概率可以表征出目标用户和除了第一物品的其他物品之间可能的操作关联。When different users (such as the first user and the target user) operate on the same item, it can be characterized that the two users are more likely to have the same or similar preferences, so it can be based on the first user For the operation information of other items to generate the operation information related to the target user, although the new operation information related to the target user generated by this part is not in the historical operation record, it can represent the target user and the target user except the first item with high probability. Possible operational associations between other items.
在一种可能的实现中,目标用户和第一用户可以都进行了针对于第一物品的操作,例如目标用户进行了针对于第一物品的浏览操作,而第一用户进行了针对于第一物品的购买操作,则可以认为目标用户和第一用户为具有相似喜好的用户,因此可以基于第一用户对于其他物品之间的历史操作信息,来生成更多的与目标用户有关的操作信息,特别的,基于历史操作记录中还记载有第一用户针对于第二物品的操作信息,则可以生成目标用户针对于所述第二物品的操作信息。In a possible implementation, both the target user and the first user may have performed an operation on the first item, for example, the target user has performed a browsing operation on the first item, while the first user has performed an operation on the first item. For the purchase operation of items, the target user and the first user can be considered as users with similar preferences, so more operation information related to the target user can be generated based on the historical operation information of the first user on other items, In particular, based on the operation information of the first user on the second item also recorded in the historical operation record, the operation information of the target user on the second item may be generated.
其中,为了保证生成的操作信息的准确性,可以将目标用户针对于所述第二物品的操作信息中第二用户针对于第二物品的操作类型设置为与历史操作记录中第一用户针对于第二物品的操作类型一致(也就是第二操作类型和第三操作类型相同)。Wherein, in order to ensure the accuracy of the generated operation information, the operation type of the second user for the second item in the operation information of the target user for the second item can be set to be the same as that for the first user in the historical operation records. The operation type of the second item is the same (that is, the second operation type is the same as the third operation type).
本申请实施例中,基于针对于相同物品(第一物品)进行了操作的用户(目标用户和第一用户),通过第一用户的其他操作信息,生成与目标用户有关的新的操作信息,在有限的历史操作数据中发掘了更丰富的信息,提高了历史操作记录的数据利用率。In the embodiment of the present application, based on the users (the target user and the first user) who have operated on the same item (the first item), new operation information related to the target user is generated through other operation information of the first user, Richer information is discovered in the limited historical operation data, and the data utilization rate of historical operation records is improved.
此外,在一种可能的实现中,还可以基于所述历史操作记录还包括第二用户针对于所述第二物品的操作信息、以及所述第三用户针对于第三物品的操作信息,生成所述目标用户针对于所述第三物品的操作信息,也就是说第二用户和第一用户可以都进行了针对于第二物品的操作,例如第一用户进行了针对于第二物品的浏览操作,而第二用户进行了针对于第二物品的购买操作,则可以认为第一用户和第二用户为具有相似喜好的用户,由于第一用户和第二用户为具有相似喜好的用户,则可以认为目标用户和第二用户也为具有相似喜好的用户,因此可以基于第二用户对于其他物品之间的历史操作信息,来生成更多的与目标用户有关的操作信息,特别的,基于历史操作记录中还记载有第二用户针对于第三物品的操作信息,则可以生成目标用户针对于所述第三物品的操作信息。In addition, in a possible implementation, based on the historical operation records also including the second user's operation information on the second item and the third user's operation information on the third item, generate The operation information of the target user on the third item, that is to say, both the second user and the first user may have performed operations on the second item, for example, the first user has browsed on the second item operation, and the second user has performed a purchase operation for the second item, it can be considered that the first user and the second user are users with similar preferences. Since the first user and the second user are users with similar preferences, then It can be considered that the target user and the second user are also users with similar preferences, so more operation information related to the target user can be generated based on the historical operation information of the second user on other items, in particular, based on the historical The operation record also records the operation information of the second user on the third item, so the operation information of the target user on the third item can be generated.
其中,为了保证生成的操作信息的准确性,可以将目标用户针对于所述第三物品的操作信息中目标用户针对于第三物品的操作类型设置为与历史操作记录中第二用户针对于第三物品的操作类型一致。Wherein, in order to ensure the accuracy of the generated operation information, the target user's operation type for the third item in the target user's operation information for the third item can be set to be the same as the second user's operation for the first item in the historical operation record. The operation types of the three items are the same.
本申请实施例中,基于针对于相同物品(第二物品)进行了操作的用户,通过第二用户的其他操作信息,生成与目标用户有关的新的操作信息,在有限的历史操作数据中发掘了更丰富的信息,提高了历史操作记录的数据利用率。In the embodiment of the present application, based on the user who has operated on the same item (the second item), new operation information related to the target user is generated through other operation information of the second user, and new operation information related to the target user is discovered in the limited historical operation data. It provides richer information and improves the data utilization rate of historical operation records.
在一种可能的实现中,所述预设条件可以包括所述第一用户和所述目标用户的用户属性的差异度小于阈值。In a possible implementation, the preset condition may include that the degree of difference between the user attributes of the first user and the target user is smaller than a threshold.
上述方式通过用户是否针对于同一个物品进行了操作来反应用户之间喜好的相似性,在一种可能的实现中,也可以直接通过用户之间的用户属性差异来确定用户之间喜好的相似性,其中用户属性为能反映出用户喜好的属性。The above method reflects the similarity of preferences between users by whether users have operated on the same item. In a possible implementation, the similarity of preferences between users can also be determined directly through the difference in user attributes between users. properties, where user attributes are attributes that can reflect user preferences.
在一种可能的实现中,用户属性可以为:性别、年龄、职业、收入、爱好以及受教育程度中的至少一种,其中,性别可以为男或者女,年龄可以为0-100之间的数字,职业可以为教师、程序员、厨师等等,爱好可以为篮球、网球、跑步等等,受教育程度可以为小学、初中、高中、大学等等。In a possible implementation, the user attribute can be at least one of: gender, age, occupation, income, hobbies, and education level, where the gender can be male or female, and the age can be between 0-100 Numbers, occupation can be teacher, programmer, chef, etc., hobbies can be basketball, tennis, running, etc., education level can be elementary school, junior high school, high school, university, etc.
本申请实施例中,具有相似用户属性的用户可以认为具有相似的喜好,例如相似用户属性的用户可以为年龄差异很小的用户、性别相同的用户、职业相同或相似的用户(职业相似可以理解为处于同一个行业)、爱好相同或相似的用户(例如都爱好网球的用户)、受教育程度相同或相似的用户(例如都是大学本科毕业的用户),此外,还可以通过权重值来表征用户的用户属性,权重值越相似,则可以表示用户之间的用户属性越相似,此外,还可以通过特征向量来表征用户的用户属性,特征向量之间的距离越近,则可以表示用户之间的用户属性越相似。In the embodiment of the present application, users with similar user attributes can be considered to have similar preferences. For example, users with similar user attributes can be users with little age difference, users with the same gender, users with the same or similar occupations (similar occupations can be understood) users in the same industry), users with the same or similar hobbies (for example, users who both like tennis), and users with the same or similar education level (for example, users who all graduated from college), in addition, it can also be characterized by weight values The user attributes of users, the more similar the weight value, the more similar the user attributes between users can be. In addition, the user attributes of users can also be represented by feature vectors. The closer the distance between feature vectors, the closer the distance between users can be. The more similar the user attributes between them are.
在一种可能的实现中,所述目标用户和所述第一用户之间的用户属性的差异度小于阈值,也就是说目标用户和第一用户为具有相似喜好的用户,因此可以基于第一用户对于其他物品之间的历史操作信息,来生成更多的与目标用户有关的操作信息,特别的,基于历史操作记录中还记载有第一用户针对于第二物品的操作信息,则可以生成目标用户针对于所述第二物品的操作信息。In a possible implementation, the degree of difference between the user attributes between the target user and the first user is smaller than a threshold, that is to say, the target user and the first user are users with similar preferences, and therefore, based on the first The user’s historical operation information on other items to generate more operation information related to the target user. In particular, based on the historical operation records that also record the first user’s operation information on the second item, you can generate Operation information of the target user on the second item.
其中,为了保证生成的操作信息的准确性,可以将目标用户针对于所述第二物品的操作信息中目标用户针对于第二物品的操作类型设置为与历史操作记录中第一用户针对于第二物品的操作类型一致(也就是第二操作类型和第三操作类型相同)。Wherein, in order to ensure the accuracy of the generated operation information, the target user's operation type for the second item in the target user's operation information for the second item can be set to be the same as the first user's operation for the second item in the historical operation record. The operation types of the two items are the same (that is, the second operation type is the same as the third operation type).
本申请实施例中,基于用户属性相似的用户(目标用户和第一用户),通过第一用户的其他操作信息,生成与目标用户有关的新的操作信息,在有限的历史操作数据中发掘了更丰富的信息,提高了历史操作记录的数据利用率。In the embodiment of this application, based on users with similar user attributes (the target user and the first user), new operation information related to the target user is generated through other operation information of the first user, and new operation information related to the target user is discovered in the limited historical operation data. Richer information improves the data utilization rate of historical operation records.
在一种可能的实现中,所述预设条件可以包括所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。In a possible implementation, the preset condition may include that the first user and the target user are users who operate on an item whose attribute difference is smaller than a threshold.
在一种可能的实现中,物品属性可以为:物品名称、开发者、安装包大小、品类以及好评度中的至少一种,其中,以物品为应用程序为例,物品的品类可以为聊天类、跑酷类游戏、办公类等等,好评度可以为针对于物品的打分、评论等。In a possible implementation, the item attribute may be at least one of: item name, developer, installation package size, category, and favorable rating, wherein, taking the item as an application program, the category of the item may be chat , parkour games, office games, etc., the favorable ratings can be ratings, comments, etc. for the items.
本申请实施例中,针对于具有相似物品属性的物品进行操作的用户可以认为具有相似的喜好,例如相似物品属性的物品可以为物品名称一致或相似的物品、品类相同或类似的物品、好评度相同或相似的物品,此外,还可以通过权重值来表征物品的物品属性,权重值越相似,则可以表示物品之间的物品属性越相似,此外,还可以通过特征向量来表征物品的物品属性,特征向量之间的距离越近,则可以表示物品之间的物品属性越相似。In this embodiment of the application, users who operate on items with similar item attributes can be considered to have similar preferences. For example, items with similar item attributes can be items with the same or similar item names, items with the same or similar categories, and favorable ratings. The same or similar items, in addition, the item attribute of the item can also be represented by the weight value, the more similar the weight value, the more similar the item attribute between the items can be, in addition, the item attribute of the item can also be represented by the feature vector , the closer the distance between the feature vectors, the more similar the item attributes between items can be.
在一种可能的实现中,第一用户对第一物品进行了操作,目标用户对第四物品进行了操作,可以基于所述第一物品和所述第四物品的物品属性的差异度小于阈值,认为目标用户和第一用户为具有相似喜好的用户,因此可以基于第一用户对于其他物品之间的历史操作信息,来生成更多的与目标用户有关的操作信息,特别的,基于历史操作记录中还记载有第一用户针对于第二物品的操作信息,则可以生成目标用户针对于所述第二物品的操作信息。In a possible implementation, the first user operates on the first item, and the target user operates on the fourth item, based on the fact that the difference between the item attributes of the first item and the fourth item is less than a threshold , it is considered that the target user and the first user are users with similar preferences, so more operation information related to the target user can be generated based on the historical operation information of the first user on other items, especially, based on historical operation The record also records the operation information of the first user on the second item, so the operation information of the target user on the second item can be generated.
其中,为了保证生成的操作信息的准确性,可以将目标用户针对于所述第二物品的操作信息中目标用户针对于第二物品的操作类型设置为与历史操作记录中第一用户针对于第二物品的操作类型一致(也就是第二操作类型和第三操作类型相同)。Wherein, in order to ensure the accuracy of the generated operation information, the target user's operation type for the second item in the target user's operation information for the second item can be set to be the same as the first user's operation for the second item in the historical operation record. The operation types of the two items are the same (that is, the second operation type is the same as the third operation type).
本申请实施例中,基于针对于具有相似物品属性的物品进行操作的用户(目标用户和第一用户),通过第一用户的其他操作信息,生成与目标用户有关的新的操作信息,在有限的历史操作数据中发掘了更丰富的信息,提高了历史操作记录的数据利用率。In the embodiment of the present application, based on users who operate on items with similar item attributes (the target user and the first user), new operation information related to the target user is generated through other operation information of the first user. More abundant information has been discovered in the historical operation data, which improves the data utilization rate of historical operation records.
在一种可能的实现中,所述基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型,具体为,按照所述第三操作类型获取所述第二操作类型。In a possible implementation, the acquiring the second operation type based on the third operation type of the first user on the second item is specifically, acquiring according to the third operation type The second operation type.
在一种可能的实现中,所述操作类型为正向操作类型。In a possible implementation, the operation type is a forward operation type.
在一种可能的实现中,所述获取所述第二操作信息集包括:In a possible implementation, the acquiring the second operation information set includes:
获取第三操作信息子集和第四操作信息子集;其中,Obtain the third subset of operation information and the fourth subset of operation information; wherein,
所述第三操作信息子集中包括,第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系;所述第四正向操作类型为所述第二用户对所述目标物品的真实操作类型。The third operation information subset includes attribute information of the second user, a fourth forward operation type, and a correspondence between the second user and the fourth forward operation type; the fourth forward operation The type is an actual operation type of the target item by the second user.
所述第四操作信息子集中包括,第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系;所述第五操作类型为所述第三用户对所述目标物品的预测操作类型;The fourth operation information subset includes attribute information of the third user, a fifth operation type, and a correspondence between the third user and the fifth operation type; the fifth operation type is the third user's The user's predicted operation type on the target item;
所述根据所述第二操作信息集确定多个子物品特征向量,包括:The determining a plurality of sub-item feature vectors according to the second operation information set includes:
根据所述第三操作信息子集确定第一子物品特征向量;determining a first sub-item feature vector according to the third subset of operation information;
根据所述第四操作信息子集确定第二子物品特征向量。A second sub-item feature vector is determined according to the fourth subset of operation information.
在一种可能的实现中,所述对所述多个子物品特征向量进行融合,包括:In a possible implementation, the fusing the feature vectors of the multiple sub-items includes:
根据所述第一子物品特征向量的第三权重以及所述第二子用户特征向量的第四权重,对所述第一子物品特征向量和所述第二子物品特征向量进行融合。The first sub-item feature vector and the second sub-item feature vector are fused according to the third weight of the first sub-item feature vector and the fourth weight of the second sub-user feature vector.
在一种可能的实现中,所述获取第四操作信息子集包括:In a possible implementation, the acquiring the fourth subset of operation information includes:
获取所述第五操作类型;Obtain the fifth operation type;
所述获取所述第五操作类型,具体包括:The acquiring the fifth operation type specifically includes:
获取第四用户对所述目标物品的第六操作类型,所述第四用户和所述第三用户的物品喜好特征满足预设条件的用户;Obtaining a sixth operation type of the fourth user on the target item, and users whose item preference features of the fourth user and the third user meet preset conditions;
基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型。The fifth operation type is acquired based on a sixth operation type performed by the fourth user on the target item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第四用户和所述第三用户均为对所述第一物品有操作的用户;Both the fourth user and the third user are users who operate on the first item;
所述第四用户和所述第三用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the fourth user and the third user is less than a threshold; and
所述第四用户和所述第三用户为对物品属性差异小于阈值的物品有操作的用户。The fourth user and the third user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型,具体为,按照所述第六操作类型获取所述第五操作类型。In a possible implementation, the acquiring the fifth operation type based on the sixth operation type of the fourth user on the target item is specifically, acquiring the fifth operation type according to the sixth operation type. Action type.
第二方面,本申请提供了一种推荐模型训练方法,所述方法包括:In a second aspect, the present application provides a recommended model training method, the method comprising:
获取目标样本用户的第一操作信息样本集,所述第一操作信息样本集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标样本用户对所述多个物品进行的操作的操作类型;Acquiring a first sample set of operation information of a target sample user, the first sample set of operation information includes attribute information of multiple items, multiple types of operations, and correspondence between the multiple items and the multiple types of operations, The corresponding relationship is used to represent the type of operation performed by the target sample user on the plurality of items;
根据所述第一操作信息样本集进行特征提取确定目标样本用户特征向量;performing feature extraction according to the first operation information sample set to determine a target sample user feature vector;
获取目标样本物品的第二操作信息样本集,所述第二操作信息样本集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;Obtain a second sample set of operation information of the target sample item, the second sample set of operation information includes attribute information of multiple users, the multiple operation types, and the correspondence between the multiple users and the multiple operation types relationship, the corresponding relationship is used to represent the type of operation performed by the multiple users on the target item;
根据所述第二操作信息样本集进行特征提取确定目标样本物品特征向量;performing feature extraction according to the second operation information sample set to determine the feature vector of the target sample item;
根据所述目标样本用户对所述目标物品的实际操作类型获取样本标签;Acquiring a sample label according to the actual operation type of the target sample user on the target item;
以所述目标样本用户特征向量和所述目标样本物品特征向量为输入,所述样本标签为输出,进行模型训练,获取目标推荐模型。Taking the target sample user feature vector and the target sample item feature vector as input, and the sample label as output, model training is performed to obtain a target recommendation model.
在一种可能的实现中,所述根据所述第一操作信息样本集进行特征提取确定目标样本用户特征向量,包括:In a possible implementation, the performing feature extraction according to the first operation information sample set to determine the target sample user feature vector includes:
根据所述第一操作信息样本集确定多个子样本用户特征向量,其中,每个子样本用户特征向量为对存在对应关系的物品的属性信息和操作类型进行特征提取得到的;A plurality of sub-sample user feature vectors are determined according to the first operation information sample set, wherein each sub-sample user feature vector is obtained by feature extraction of attribute information and operation types of items with corresponding relationships;
对所述多个用户子样本用户特征向量进行融合,得到所述目标样本用户特征向量。The multiple user sub-sample user feature vectors are fused to obtain the target sample user feature vector.
在一种可能的实现中,所述根据所述第二操作信息样本集进行特征提取确定目标样本物品特征向量,包括:In a possible implementation, the performing feature extraction according to the second operation information sample set to determine the feature vector of the target sample item includes:
根据所述第二操作信息样本集确定多个子样本物品特征向量,其中,每个第二子样本物品特征向量为对存在对应关系的用户的属性信息和操作类型进行特征提取得到的;A plurality of sub-sample item feature vectors are determined according to the second operation information sample set, wherein each second sub-sample item feature vector is obtained by feature extraction of user attribute information and operation types that have a corresponding relationship;
对所述多个子样本物品特征向量进行融合,得到所述目标样本物品特征向量。The multiple sub-sample item feature vectors are fused to obtain the target sample item feature vector.
在一种可能的实现中,所述获取所述第一操作信息样本集包括:In a possible implementation, the acquiring the first operation information sample set includes:
获取第一操作信息样本子集和第二操作信息样本子集;其中,Obtain the first subset of operation information samples and the second subset of operation information samples; wherein,
所述第一操作信息样本子集中包括,第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;所述第一操作类型为所述目标用户对所述第一物品的真实操作类型;The first operation information sample subset includes attribute information of a first item, a first operation type, and a correspondence between the first item and the first operation type; the first operation type is the target The actual operation type of the user on the first item;
所述第二操作信息样本子集包括,第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;所述第二操作类型为所述目标用户对所述第二物品的预测操作类型;The second operation information sample subset includes attribute information of a second item, a second operation type, and a correspondence between the second item and the second operation type; the second operation type is the target The user's predicted operation type on the second item;
所述根据所述第一操作信息样本集确定多个子样本用户特征向量,包括:The determining a plurality of sub-sample user feature vectors according to the first operation information sample set includes:
根据所述第一操作信息样本子集确定第一子样本用户特征向量;determining a first subsample user feature vector according to the first subset of operation information samples;
根据所述第二操作信息样本子集确定第二子样本用户特征向量。A second sub-sample user feature vector is determined according to the second subset of operation information samples.
在一种可能的实现中,所述对所述多个用户子样本用户特征向量进行融合,包括:In a possible implementation, the fusing the user feature vectors of the plurality of user sub-samples includes:
根据所述第一子样本用户特征向量的第一权重和所述第二子样本用户特征向量的第二权重,对所述第一子样本用户特征向量和所述第二子样本用户特征向量进行融合。According to the first weight of the first sub-sample user feature vector and the second weight of the second sub-sample user feature vector, the first sub-sample user feature vector and the second sub-sample user feature vector are performed fusion.
在一种可能的实现中,所述获取第二操作信息样本子集包括:In a possible implementation, the acquiring the second subset of operation information samples includes:
获取所述第二操作类型;obtain the second operation type;
所述获取所述第二操作类型,具体为:The acquiring the second operation type is specifically:
获取第一用户对第二物品的第三操作类型,所述第一用户为所述目标用户的物品喜好特征满足预设条件的用户;Obtaining a third operation type of a first user on a second item, the first user being a user whose item preference characteristics of the target user meet a preset condition;
基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型。The second operation type is acquired based on the third operation type of the first user on the second item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对所述第一物品有操作的用户;Both the first user and the target user are users who operate on the first item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型,具体为,按照所述第三操作类型获取所述第二操作类型。In a possible implementation, the acquiring the second operation type based on the third operation type of the first user on the second item is specifically, acquiring according to the third operation type The second operation type.
在一种可能的实现中,所述操作类型为正向操作类型。In a possible implementation, the operation type is a forward operation type.
在一种可能的实现中,所述获取所述第二操作信息样本集包括:In a possible implementation, the acquiring the second operation information sample set includes:
获取第三操作信息样本子集和第四操作信息样本子集;其中,Obtain the third subset of operation information samples and the fourth subset of operation information samples; wherein,
所述第三操作信息样本子集中包括,第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系;所述第四正向操作类型为所述第二用户对所述目标物品的真实操作类型;The third operation information sample subset includes attribute information of the second user, a fourth forward operation type, and a correspondence between the second user and the fourth forward operation type; the fourth forward operation type The operation type is the actual operation type of the second user on the target item;
所述第四操作信息样本子集中包括,第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系;所述第五操作类型为所述第三用户对所述目标物品的预测操作类型;The fourth operation information sample subset includes attribute information of the third user, a fifth operation type, and a corresponding relationship between the third user and the fifth operation type; the fifth operation type is the first 3. The user's predicted operation type on the target item;
所述根据所述第二操作信息样本集确定多个子样本物品特征向量,包括:The determining a plurality of sub-sample item feature vectors according to the second operation information sample set includes:
根据所述第三操作信息样本子集确定第一子样本物品特征向量;determining a first sub-sample item feature vector according to the third subset of operation information samples;
根据所述第四操作信息样本子集确定第二子样本物品特征向量。A second sub-sample feature vector is determined according to the fourth subset of operation information samples.
在一种可能的实现中,所述对所述多个子样本物品特征向量进行融合,包括:In a possible implementation, the fusing the multiple sub-sample item feature vectors includes:
根据所述第一子样本物品特征向量的第三权重以及所述第二子样本物品特征向量的第四权重,对所述第一子样本物品特征向量和所述第二子样本物品特征向量进行融合。According to the third weight of the first sub-sample item feature vector and the fourth weight of the second sub-sample item feature vector, the first sub-sample item feature vector and the second sub-sample item feature vector are performed fusion.
在一种可能的实现中,所述获取第四操作信息子集包括:In a possible implementation, the acquiring the fourth subset of operation information includes:
获取所述第五操作类型;Obtain the fifth operation type;
所述获取所述第五操作类型,具体包括:The acquiring the fifth operation type specifically includes:
获取第四用户对所述目标物品的第六操作类型,所述第四用户和所述第三用户的物品喜好特征满足预设条件的用户;Obtaining a sixth operation type of the fourth user on the target item, and users whose item preference features of the fourth user and the third user meet preset conditions;
基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型。The fifth operation type is acquired based on a sixth operation type performed by the fourth user on the target item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第四用户和所述第三用户均为对所述第一物品有操作的用户;Both the fourth user and the third user are users who operate on the first item;
所述第四用户和所述第三用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the fourth user and the third user is less than a threshold; and
所述第四用户和所述第三用户为对物品属性差异小于阈值的物品有操作的用户。The fourth user and the third user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型,具体为,按照所述第六操作类型获取所述第五操作类型。In a possible implementation, the acquiring the fifth operation type based on the sixth operation type of the fourth user on the target item is specifically, acquiring the fifth operation type according to the sixth operation type. Action type.
第三方面,本申请提供了一种训练样本构建方法,所述方法包括:In a third aspect, the present application provides a training sample construction method, the method comprising:
获取第一用户对第一物品的第一操作类型,所述第一用户和目标用户的物品喜好特征满足预设条件;Obtaining a first operation type of a first user on a first item, where the item preference characteristics of the first user and the target user meet a preset condition;
基于所述第一用户针对于所述第一物品的所述第一操作类型,生成所述目标用户对所述第一物品的第二操作类型;所述第二操作类型为所述目标用户针对所述第一物品的预测操作行为;Based on the first operation type of the first user on the first item, generate a second operation type of the target user on the first item; the second operation type is the target user's operation on the first item a predicted operational behavior of the first item;
根据所述目标用户的属性信息、所述第一物品的属性信息以及所述第二操作类型,构建训练样本。A training sample is constructed according to the attribute information of the target user, the attribute information of the first item, and the second operation type.
本申请可以在有限的历史操作数据中发掘更丰富的信息,进而生成更多的与用户相关的操作信息,进而可以提高历史操作记录的数据利用率,构建更多的训练样本,基于上述训练样本训练的推荐模型可以更加准确的预测用户的行为。This application can explore more abundant information in the limited historical operation data, and then generate more user-related operation information, thereby improving the data utilization rate of historical operation records and constructing more training samples. Based on the above training samples The trained recommendation model can predict user behavior more accurately.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对第二物品有操作的用户;Both the first user and the target user are users who operate on the second item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述用户属性包括如下的至少一种:In a possible implementation, the user attributes include at least one of the following:
性别,年龄,职业,收入,爱好,教育程度。Gender, age, occupation, income, hobbies, education level.
在一种可能的实现中,所述物品属性包括如下的至少一种:In a possible implementation, the item attributes include at least one of the following:
物品名称,开发者,安装包大小,品类,好评度。Item name, developer, installation package size, category, praise rating.
在一种可能的实现中,所述第一操作类型与所述第二操作类型相同。In a possible implementation, the first operation type is the same as the second operation type.
在一种可能的实现中,所述第一操作类型和所述第二操作类型包括如下的至少一种:In a possible implementation, the first operation type and the second operation type include at least one of the following:
浏览操作,加入购物车操作以及购买操作。Browse actions, add to cart actions, and buy actions.
在一种可能的实现中,所述基于所述第一用户针对于所述第一物品的所述第一操作类型,生成所述目标用户对所述第一物品的第二操作类型,包括:基于所述第一用户针对于所述第一物品的所述第一操作类型,获取第二操作类型;In a possible implementation, the generating the second operation type of the target user on the first item based on the first operation type of the first user on the first item includes: acquiring a second operation type based on the first operation type performed by the first user on the first item;
所述获取第二操作类型,具体为,按照所述第一操作类型获取所述第二操作类型。The acquiring the second operation type specifically includes acquiring the second operation type according to the first operation type.
在一种可能的实现中,上述得到的操作信息可以用于进行目标推荐模型的训练,具体的,可以获取所述目标用户的属性信息,所述第一物品的属性信息;根据所述目标用户的属性信息确定目标用户特征向量;根据所述第一物品的属性信息确定目标物品特征向量;获取所述第二操作类型的第三特征向量;并根据所述目标用户特征向量,所述目标物品特征向量以及所述第三特征向量,训练目标推荐模型,以得到训练后的目标推荐模型。关于如何根据所述目标用户的属性信息确定目标用户特征向量;根据所述第一物品的属性信息确定目标物品特征向量;获取所述第二操作类型的第三特征向量可以参照上述实施例中的描述,相似之处这里不再赘述。In a possible implementation, the operation information obtained above can be used to train the target recommendation model, specifically, the attribute information of the target user and the attribute information of the first item can be obtained; according to the target user Determine the target user feature vector according to the attribute information of the first item; determine the target item feature vector according to the attribute information of the first item; obtain the third feature vector of the second operation type; and according to the target user feature vector, the target item The feature vector and the third feature vector are used to train the target recommendation model to obtain the trained target recommendation model. Regarding how to determine the target user feature vector according to the attribute information of the target user; determine the target item feature vector according to the attribute information of the first item; and obtain the third feature vector of the second operation type can refer to the above-mentioned embodiment. Description, the similarities will not be repeated here.
在一种可能的实现中,可以根据所述目标用户特征向量,所述目标物品特征向量以及所述第三特征向量,通过目标推荐模型输出预测概率,所述预测概率用于表示所述目标用户对所述第一物品进行所述第二操作类型的操作的概率,并根据所述概率,确定损失,并根据所述损失更新所述目标推荐模型。In a possible implementation, according to the target user feature vector, the target item feature vector and the third feature vector, the target recommendation model can output a prediction probability, and the prediction probability is used to represent the target user The probability of performing the operation of the second operation type on the first item, and according to the probability, determine a loss, and update the target recommendation model according to the loss.
第四方面,本申请提供了一种信息推荐装置,其特征在于,所述装置包括:In a fourth aspect, the present application provides an information recommendation device, characterized in that the device includes:
获取模块,用于获取目标用户的第一操作信息集,所述第一操作信息集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标用户对所述多个物品进行的操作的操作类型;以及获取目标物品的第二操作信息集,所述第二操作信息集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;An acquisition module, configured to acquire a first operation information set of a target user, where the first operation information set includes attribute information of a plurality of items, a plurality of operation types, and correspondence between the plurality of items and the plurality of operation types relationship, the corresponding relationship is used to indicate the type of operation performed by the target user on the multiple items; and acquiring a second operation information set of the target item, the second operation information set includes attributes of multiple users information, the multiple operation types, and the correspondence between the multiple users and the multiple operation types, the correspondence being used to represent the operation types of the operations performed by the multiple users on the target item;
特征向量生成模块,用于根据所述第一操作信息集进行特征提取确定目标用户特征向量;以及根据所述第二操作信息集进行特征提取确定目标物品特征向量;A feature vector generating module, configured to perform feature extraction according to the first operation information set to determine the target user feature vector; and perform feature extraction according to the second operation information set to determine the target item feature vector;
信息推荐模块,用于根据所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,所述推荐信息用于表示所述目标用户对所述目标物品进行所述多个操作类型的操作的概率;当推荐信息满足预设条件,确定向所述目标用户推荐所述目标物品。An information recommendation module, configured to output recommendation information based on a target recommendation model according to the target user feature vector and the target item feature vector, and the recommendation information is used to indicate that the target user has performed the multiple actions on the target item. The probability of an operation of an operation type; when the recommendation information satisfies the preset condition, it is determined to recommend the target item to the target user.
在一种可能的实现中,所述特征向量生成模块,具体用于:In a possible implementation, the feature vector generating module is specifically used for:
根据所述第一操作信息集确定多个子用户特征向量,其中,每个子用户特征向量为对存在对应关系的物品的属性信息和操作类型进行特征提取得到的;Determining a plurality of sub-user feature vectors according to the first operation information set, wherein each sub-user feature vector is obtained by feature extraction of attribute information and operation types of items with corresponding relationships;
对所述多个子用户特征向量进行融合,得到所述目标用户特征向量。The multiple sub-user feature vectors are fused to obtain the target user feature vector.
在一种可能的实现中,所述特征向量生成模块,具体用于:In a possible implementation, the feature vector generating module is specifically used for:
根据所述第二操作信息集确定多个子物品特征向量,其中,每个子物品特征向量为对存在对应关系的用户的属性信息和操作类型进行特征提取得到的;Determining a plurality of sub-item feature vectors according to the second operation information set, wherein each sub-item feature vector is obtained by performing feature extraction on attribute information and operation types of users with corresponding relationships;
对所述多个子物品特征向量进行融合,得到所述目标物品特征向量。The multiple sub-item feature vectors are fused to obtain the target item feature vector.
在一种可能的实现中,所述信息推荐模块,具体用于:In a possible implementation, the information recommendation module is specifically used for:
根据所述多个操作类型的多个操作类型特征向量,所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息。Outputting recommendation information based on a target recommendation model according to multiple operation type feature vectors of the multiple operation types, the target user feature vector and the target item feature vector.
在一种可能的实现中,所述获取模块,具体用于:In a possible implementation, the acquiring module is specifically used for:
获取第一操作信息子集和第二操作信息子集;其中,Obtain the first subset of operation information and the second subset of operation information; wherein,
所述第一操作信息子集中包括,第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;所述第一操作类型为所述目标用户对所述第一物品的真实操作类型;The first operation information subset includes attribute information of the first item, a first operation type, and a correspondence between the first item and the first operation type; the first operation type is the target user the actual type of operation on the first item;
所述第二操作信息子集包括,第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;所述第二操作类型为所述目标用户对所述第二物品的预测操作类型;The second operation information subset includes attribute information of the second item, a second operation type, and a correspondence between the second item and the second operation type; the second operation type is the target user a type of predicted operation on said second item;
所述特征向量生成模块,具体用于:The feature vector generating module is specifically used for:
根据所述第一操作信息子集确定第一子用户特征向量;determining a first sub-user feature vector according to the first subset of operation information;
根据所述第二操作信息子集确定第二子用户特征向量。A second sub-user feature vector is determined according to the second subset of operation information.
在一种可能的实现中,所述特征向量生成模块,具体用于:In a possible implementation, the feature vector generating module is specifically used for:
根据所述第一子用户特征向量的第一权重以及所述第二子用户特征向量的第二权重,对所述第一子用户特征向量和所述第二子用户特征向量进行融合。The first sub-user feature vector and the second sub-user feature vector are fused according to the first weight of the first sub-user feature vector and the second weight of the second sub-user feature vector.
在一种可能的实现中,所述获取模块,还用于:In a possible implementation, the acquisition module is also used to:
获取所述第二操作类型;obtain the second operation type;
所述获取所述第二操作类型,具体为:The acquiring the second operation type is specifically:
获取第一用户对第二物品的第三操作类型,所述第一用户为所述目标用户的物品喜好特征满足预设条件的用户;Obtaining a third operation type of a first user on a second item, the first user being a user whose item preference characteristics of the target user meet a preset condition;
基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型。The second operation type is acquired based on the third operation type of the first user on the second item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对所述第一物品有操作的用户;Both the first user and the target user are users who operate on the first item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型,具体为,按照所述第三操作类型获取所述第二操作类型。In a possible implementation, the acquiring the second operation type based on the third operation type of the first user on the second item is specifically, acquiring according to the third operation type The second operation type.
在一种可能的实现中,所述操作类型为正向操作类型。In a possible implementation, the operation type is a forward operation type.
在一种可能的实现中,所述获取模块,具体用于:In a possible implementation, the acquiring module is specifically used for:
获取第三操作信息子集和第四操作信息子集;其中,Obtain the third subset of operation information and the fourth subset of operation information; wherein,
所述第三操作信息子集中包括,第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系;所述第四正向操作类型为所述第二用户对所述目标物品的真实操作类型。The third operation information subset includes attribute information of the second user, a fourth forward operation type, and a correspondence between the second user and the fourth forward operation type; the fourth forward operation The type is an actual operation type of the target item by the second user.
所述第四操作信息子集中包括,第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系;所述第五操作类型为所述第三用户对所述目标物品的预测操作类型;The fourth operation information subset includes attribute information of the third user, a fifth operation type, and a correspondence between the third user and the fifth operation type; the fifth operation type is the third user's The user's predicted operation type on the target item;
所述特征向量生成模块,具体用于:The feature vector generating module is specifically used for:
根据所述第三操作信息子集确定第一子物品特征向量;determining a first sub-item feature vector according to the third subset of operation information;
根据所述第四操作信息子集确定第二子物品特征向量。A second sub-item feature vector is determined according to the fourth subset of operation information.
在一种可能的实现中,所述特征向量生成模块,具体用于:In a possible implementation, the feature vector generating module is specifically used for:
根据所述第一子物品特征向量的第三权重以及所述第二子用户特征向量的第四权重,对所述第一子物品特征向量和所述第二子物品特征向量进行融合。The first sub-item feature vector and the second sub-item feature vector are fused according to the third weight of the first sub-item feature vector and the fourth weight of the second sub-user feature vector.
在一种可能的实现中,所述获取模块,具体用于:In a possible implementation, the acquiring module is specifically used for:
获取所述第五操作类型;Obtain the fifth operation type;
所述获取所述第五操作类型,具体包括:The acquiring the fifth operation type specifically includes:
获取第四用户对所述目标物品的第六操作类型,所述第四用户和所述第三用户的物品喜好特征满足预设条件的用户;Obtaining a sixth operation type of the fourth user on the target item, and users whose item preference features of the fourth user and the third user meet preset conditions;
基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型。The fifth operation type is acquired based on a sixth operation type performed by the fourth user on the target item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第四用户和所述第三用户均为对所述第一物品有操作的用户;Both the fourth user and the third user are users who operate on the first item;
所述第四用户和所述第三用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the fourth user and the third user is less than a threshold; and
所述第四用户和所述第三用户为对物品属性差异小于阈值的物品有操作的用户。The fourth user and the third user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型,具体为,按照所述第六操作类型获取所述第五操作类型。In a possible implementation, the acquiring the fifth operation type based on the sixth operation type of the fourth user on the target item is specifically, acquiring the fifth operation type according to the sixth operation type. Action type.
本申请提供了一种信息推荐装置,所述装置包括:获取模块,用于获取目标用户的第一操作信息集,所述第一操作信息集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标用户对所述多个物品进行的操作的操作类型;以及获取目标物品的第二操作信息集,所述第二操作信息集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;特征向量生成模块,用于根据所述第一操作信息集进行特征提取确定目标用户特征向量;以及根据所述第二操作信息集进行特征提取确定目标物品特征向量;信息推荐模块,用于根据所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,所述推荐信息用于表示所述目标用户对所述目标物品进行所述多个操作类型的操作的概率;当推荐信息满足预设条件,确定向所述目标用户推荐所述目标物品。本申请基于存在关联关系的物品和操作类型来生成表征目标用户喜好的目标用户特征向量,以及基于存在关联关系的用户和操作类型来生成表征目标物品对用户的吸引力特征的第二特征向量,来预测目标用户对目标物品的进行多个操作类型的操作的概率,可以更准确的刻画出用户针对于物品的操作概率。The present application provides an information recommendation device, the device includes: an acquisition module, configured to acquire a first operation information set of a target user, the first operation information set includes attribute information of a plurality of items, a plurality of operation types, and the corresponding relationship between the multiple items and the multiple operation types, the corresponding relationship is used to represent the operation type of the operation performed by the target user on the multiple items; and acquiring the second operation information of the target item set, the second operation information set includes the attribute information of multiple users, the multiple operation types, and the correspondence between the multiple users and the multiple operation types, and the correspondence is used to represent the The operation type of the operation performed by multiple users on the target item; the feature vector generation module is used to perform feature extraction and determine the target user feature vector according to the first operation information set; and perform feature extraction and determination according to the second operation information set A target item feature vector; an information recommendation module, configured to output recommendation information based on the target recommendation model based on the target user feature vector and the target item feature vector, the recommendation information being used to indicate that the target user has an opinion on the target Probability of the item performing operations of the multiple operation types; when the recommendation information satisfies a preset condition, it is determined to recommend the target item to the target user. This application generates a target user feature vector representing the preferences of the target user based on the associated items and operation types, and generates a second feature vector representing the attractiveness of the target item to the user based on the associated users and operation types, To predict the probability of the target user performing multiple types of operations on the target item, it can more accurately describe the user's operation probability for the item.
第五方面,本申请提供了一种推荐模型训练装置,所述装置包括:In a fifth aspect, the present application provides a recommended model training device, the device comprising:
获取模块,用于获取目标样本用户的第一操作信息样本集,所述第一操作信息样本集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标样本用户对所述多个物品进行的操作的操作类型;获取目标样本物品的第二操作信息样本集,所述第二操作信息样本集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;An acquisition module, configured to acquire a first operation information sample set of a target sample user, where the first operation information sample set includes attribute information of multiple items, multiple operation types, and the multiple items and the multiple operations Type correspondence, the correspondence is used to represent the operation type of the operation performed by the target sample user on the plurality of items; obtain the second operation information sample set of the target sample item, and the second operation information sample set Including the attribute information of multiple users, the multiple operation types, and the correspondence between the multiple users and the multiple operation types, the correspondence is used to represent the operations performed by the multiple users on the target item type of operation;
特征向量生成模块,用于根据所述第一操作信息样本集进行特征提取确定目标样本用户特征向量;根据所述第二操作信息样本集进行特征提取确定目标样本物品特征向量;The feature vector generation module is used to perform feature extraction according to the first operation information sample set to determine the target sample user feature vector; perform feature extraction according to the second operation information sample set to determine the target sample item feature vector;
所述获取模块,还用于根据所述目标样本用户对所述目标物品的实际操作类型获取样本标签;The obtaining module is also used to obtain sample tags according to the actual operation type of the target sample user on the target item;
模型训练模块,用于以所述目标样本用户特征向量和所述目标样本物品特征向量为输入,所述样本标签为输出,进行模型训练,获取目标推荐模型。A model training module, configured to use the target sample user feature vector and the target sample item feature vector as input, and the sample label as output, to perform model training and obtain a target recommendation model.
在一种可能的实现中,所述特征向量生成模块,具体用于:In a possible implementation, the feature vector generating module is specifically used for:
根据所述第一操作信息样本集确定多个子样本用户特征向量,其中,每个子样本用户特征向量为对存在对应关系的物品的属性信息和操作类型进行特征提取得到的;A plurality of sub-sample user feature vectors are determined according to the first operation information sample set, wherein each sub-sample user feature vector is obtained by feature extraction of attribute information and operation types of items with corresponding relationships;
对所述多个用户子样本用户特征向量进行融合,得到所述目标样本用户特征向量。The multiple user sub-sample user feature vectors are fused to obtain the target sample user feature vector.
在一种可能的实现中,所述特征向量生成模块,具体用于:In a possible implementation, the feature vector generating module is specifically used for:
根据所述第二操作信息样本集确定多个子样本物品特征向量,其中,每个第二子样本物品特征向量为对存在对应关系的用户的属性信息和操作类型进行特征提取得到的;A plurality of sub-sample item feature vectors are determined according to the second operation information sample set, wherein each second sub-sample item feature vector is obtained by feature extraction of user attribute information and operation types that have a corresponding relationship;
对所述多个子样本物品特征向量进行融合,得到所述目标样本物品特征向量。The multiple sub-sample item feature vectors are fused to obtain the target sample item feature vector.
在一种可能的实现中,所述获取模块,具体用于:In a possible implementation, the acquiring module is specifically used for:
获取第一操作信息样本子集和第二操作信息样本子集;其中,Obtain the first subset of operation information samples and the second subset of operation information samples; wherein,
所述第一操作信息样本子集中包括,第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;所述第一操作类型为所述目标用户对所述第一物品的真实操作类型;The first operation information sample subset includes attribute information of a first item, a first operation type, and a correspondence between the first item and the first operation type; the first operation type is the target The actual operation type of the user on the first item;
所述第二操作信息样本子集包括,第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;所述第二操作类型为所述目标用户对所述第二物品的预测操作类型;The second operation information sample subset includes attribute information of a second item, a second operation type, and a correspondence between the second item and the second operation type; the second operation type is the target The user's predicted operation type on the second item;
所述特征向量生成模块,具体用于:The feature vector generating module is specifically used for:
根据所述第一操作信息样本子集确定第一子样本用户特征向量;determining a first subsample user feature vector according to the first subset of operation information samples;
根据所述第二操作信息样本子集确定第二子样本用户特征向量。A second sub-sample user feature vector is determined according to the second subset of operation information samples.
在一种可能的实现中,所述特征向量生成模块,具体用于:In a possible implementation, the feature vector generating module is specifically used for:
根据所述第一子样本用户特征向量的第一权重和所述第二子样本用户特征向量的第二权重,对所述第一子样本用户特征向量和所述第二子样本用户特征向量进行融合。According to the first weight of the first sub-sample user feature vector and the second weight of the second sub-sample user feature vector, the first sub-sample user feature vector and the second sub-sample user feature vector are performed fusion.
在一种可能的实现中,所述获取模块,具体用于:In a possible implementation, the acquiring module is specifically used for:
获取所述第二操作类型;obtain the second operation type;
所述获取所述第二操作类型,具体为:The acquiring the second operation type is specifically:
获取第一用户对第二物品的第三操作类型,所述第一用户为所述目标用户的物品喜好特征满足预设条件的用户;Obtaining a third operation type of a first user on a second item, the first user being a user whose item preference characteristics of the target user meet a preset condition;
基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型。The second operation type is acquired based on the third operation type of the first user on the second item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对所述第一物品有操作的用户;Both the first user and the target user are users who operate on the first item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型,具体为,按照所述第三操作类型获取所述第二操作类型。In a possible implementation, the acquiring the second operation type based on the third operation type of the first user on the second item is specifically, acquiring according to the third operation type The second operation type.
在一种可能的实现中,所述操作类型为正向操作类型。In a possible implementation, the operation type is a forward operation type.
在一种可能的实现中,所述获取模块,具体用于:In a possible implementation, the acquiring module is specifically used for:
获取第三操作信息样本子集和第四操作信息样本子集;其中,Obtain the third subset of operation information samples and the fourth subset of operation information samples; wherein,
所述第三操作信息样本子集中包括,第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系;所述第四正向操作类型为所述第二用户对所述目标物品的真实操作类型;The third operation information sample subset includes attribute information of the second user, a fourth forward operation type, and a correspondence between the second user and the fourth forward operation type; the fourth forward operation type The operation type is the actual operation type of the second user on the target item;
所述第四操作信息样本子集中包括,第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系;所述第五操作类型为所述第三用户对所述目标物品的预测操作类型;The fourth operation information sample subset includes attribute information of the third user, a fifth operation type, and a corresponding relationship between the third user and the fifth operation type; the fifth operation type is the first 3. The user's predicted operation type on the target item;
所述特征向量生成模块,具体用于:The feature vector generating module is specifically used for:
根据所述第三操作信息样本子集确定第一子样本物品特征向量;determining a first sub-sample item feature vector according to the third subset of operation information samples;
根据所述第四操作信息样本子集确定第二子样本物品特征向量。A second sub-sample feature vector is determined according to the fourth subset of operation information samples.
在一种可能的实现中,所述特征向量生成模块,具体用于:In a possible implementation, the feature vector generating module is specifically used for:
根据所述第一子样本物品特征向量的第三权重以及所述第二子样本物品特征向量的第四权重,对所述第一子样本物品特征向量和所述第二子样本物品特征向量进行融合。According to the third weight of the first sub-sample item feature vector and the fourth weight of the second sub-sample item feature vector, the first sub-sample item feature vector and the second sub-sample item feature vector are performed fusion.
在一种可能的实现中,所述获取模块,具体用于:In a possible implementation, the acquiring module is specifically used for:
获取所述第五操作类型;Obtain the fifth operation type;
所述获取所述第五操作类型,具体包括:The acquiring the fifth operation type specifically includes:
获取第四用户对所述目标物品的第六操作类型,所述第四用户和所述第三用户的物品喜好特征满足预设条件的用户;Obtaining a sixth operation type of the fourth user on the target item, and users whose item preference features of the fourth user and the third user meet preset conditions;
基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型。The fifth operation type is acquired based on a sixth operation type performed by the fourth user on the target item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第四用户和所述第三用户均为对所述第一物品有操作的用户;Both the fourth user and the third user are users who operate on the first item;
所述第四用户和所述第三用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the fourth user and the third user is less than a threshold; and
所述第四用户和所述第三用户为对物品属性差异小于阈值的物品有操作的用户。The fourth user and the third user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型,具体为,按照所述第六操作类型获取所述第五操作类型。In a possible implementation, the acquiring the fifth operation type based on the sixth operation type of the fourth user on the target item is specifically, acquiring the fifth operation type according to the sixth operation type. Action type.
第六方面,本申请提供了一种训练样本构建装置,所述装置包括:In a sixth aspect, the present application provides a training sample construction device, the device comprising:
获取模块,用于获取第一用户对第一物品的第一操作类型,所述第一用户和目标用户的物品喜好特征满足预设条件;An acquisition module, configured to acquire a first operation type of a first user on a first item, and the item preference characteristics of the first user and the target user satisfy a preset condition;
操作信息生成模块,用于基于所述第一用户针对于所述第一物品的所述第一操作类型,生成所述目标用户对所述第一物品的第二操作类型;所述第二操作类型为所述目标用户针对所述第一物品的预测操作行为;An operation information generation module, configured to generate a second operation type of the target user on the first item based on the first operation type of the first user on the first item; the second operation The type is the predicted operation behavior of the target user on the first item;
样本构建模块,用于根据所述目标用户的属性信息、所述第一物品的属性信息以及所述第二操作类型,构建训练样本。A sample construction module, configured to construct a training sample according to the attribute information of the target user, the attribute information of the first item, and the second operation type.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对第二物品有操作的用户;Both the first user and the target user are users who operate on the second item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述用户属性包括如下的至少一种:In a possible implementation, the user attributes include at least one of the following:
性别,年龄,职业,收入,爱好,教育程度。Gender, age, occupation, income, hobbies, education level.
在一种可能的实现中,所述物品属性包括如下的至少一种:In a possible implementation, the item attributes include at least one of the following:
物品名称,开发者,安装包大小,品类,好评度。Item name, developer, installation package size, category, praise rating.
在一种可能的实现中,所述操作信息生成模块,具体用于:In a possible implementation, the operation information generation module is specifically configured to:
基于所述第一用户针对于所述第一物品的所述第一操作类型,获取第二操作类型;acquiring a second operation type based on the first operation type performed by the first user on the first item;
所述获取第二操作类型,具体为,按照所述第一操作类型获取所述第二操作类型。The acquiring the second operation type specifically includes acquiring the second operation type according to the first operation type.
在一种可能的实现中,所述第一操作类型和所述第二操作类型包括如下的至少一种:In a possible implementation, the first operation type and the second operation type include at least one of the following:
浏览操作,加入购物车操作以及购买操作。Browse actions, add to cart actions, and buy actions.
本申请实施例提供了一种用户操作行为预测装置,所述装置包括:获取模块,用于获取第一用户对第一物品的第一操作类型,所述第一用户和目标用户的物品喜好特征满足预设条件;操作信息生成模块,用于基于所述第一用户针对于所述第一物品的所述第一操作类型,生成所述目标用户对所述第一物品的第二操作类型;所述第二操作类型为所述目标用户针对所述第一物品的预测操作行为。本申请可以在有限的历史操作数据中发掘更丰富的信息,进而生成更多的与用户相关的操作信息,进而可以提高历史操作记录的数据利用率,基于上述信息训练的推荐模型可以更加准确的预测用户的行为。An embodiment of the present application provides a device for predicting user operation behavior, the device including: an acquisition module, configured to acquire the first operation type of the first user on the first item, the item preference characteristics of the first user and the target user Satisfying preset conditions; an operation information generating module, configured to generate a second operation type of the target user on the first item based on the first operation type of the first user on the first item; The second operation type is a predicted operation behavior of the target user on the first item. This application can explore more abundant information in the limited historical operation data, and then generate more user-related operation information, thereby improving the data utilization rate of historical operation records, and the recommendation model trained based on the above information can be more accurate. Predict user behavior.
第七方面,本申请实施例提供了一种推荐装置,可以包括存储器、处理器以及总线系统,其中,存储器用于存储程序,处理器用于执行存储器中的程序,以执行如上述第一方面任一可选的方法。In the seventh aspect, the embodiment of the present application provides a recommendation device, which may include a memory, a processor, and a bus system, wherein the memory is used to store programs, and the processor is used to execute the programs in the memory to perform any of the above-mentioned first aspects. an optional method.
第八方面,本申请实施例提供了一种训练装置,可以包括存储器、处理器以及总线系统,其中,存储器用于存储程序,处理器用于执行存储器中的程序,以执行如上述第二方面任一可选的方法。In the eighth aspect, the embodiment of the present application provides a training device, which may include a memory, a processor, and a bus system, wherein the memory is used to store programs, and the processor is used to execute the programs in the memory to perform any of the above-mentioned second aspects. an optional method.
第九方面,本申请实施例提供了一种用户操作行为预测装置,可以包括存储器、处理器以及总线系统,其中,存储器用于存储程序,处理器用于执行存储器中的程序,以执行如上述第三方面任一可选的方法。In the ninth aspect, the embodiment of the present application provides a device for predicting user operation behavior, which may include a memory, a processor, and a bus system, wherein the memory is used to store programs, and the processor is used to execute the programs in the memory to perform the above-mentioned first Any of the three options.
第十方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机程序,当其在计算机上运行时,使得计算机执行上述第一方面及任一可选的方法,上述第二方面及任一可选的方法、以及上述第三方面及任一可选的方法。In a tenth aspect, an embodiment of the present application provides a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when it is run on a computer, the computer executes the above-mentioned first aspect and any possible program. The selected method, the above-mentioned second aspect and any optional method, and the above-mentioned third aspect and any optional method.
第十一方面,本申请实施例提供了一种计算机程序产品,包括代码,当代码被执行时,用于实现上述第一方面及任一可选的方法,上述第二方面及任一可选的方法、以及上述第三方面及任一可选的方法。In the eleventh aspect, the embodiment of the present application provides a computer program product, including codes, which, when the codes are executed, are used to implement the above-mentioned first aspect and any optional method, the above-mentioned second aspect and any optional method method, as well as the above-mentioned third aspect and any optional method.
第十二方面,本申请提供了一种芯片系统,该芯片系统包括处理器,用于支持执行设备或训练设备实现上述方面中所涉及的功能,例如,发送或处理上述方法中所涉及的数据;或,信息。在一种可能的设计中,所述芯片系统还包括存储器,所述存储器,用于保存执行设备或训练设备必要的程序指令和数据。该芯片系统,可以由芯片构成,也可以包括芯片和其他分立器件。In a twelfth aspect, the present application provides a chip system, the chip system includes a processor, used to support the execution device or the training device to realize the functions involved in the above aspect, for example, send or process the data involved in the above method ; or, information. In a possible design, the chip system further includes a memory, and the memory is used for storing necessary program instructions and data of the execution device or the training device. The system-on-a-chip may consist of chips, or may include chips and other discrete devices.
本申请实施例提供了一种推荐方法,所述方法包括:获取目标用户的第一操作信息集,所述第一操作信息集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标用户对所述多个物品进行的操作的操作类型;根据所述第一操作信息集进行特征提取确定目标用户特征向量;获取目标物品的第二操作信息集,所述第二操作信息集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;根据所述第二操作信息集进行特征提取确定目标物品特征向量;根据所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,所述推荐信息用于表示所述目标用户对所述目标物品进行所述多个操作类型的操作的概率;当推荐信息满足预设条件,确定向所述目标用户推荐所述目标物品。通过上述方式,基于存在关联关系的物品和操作类型来生成表征目标用户喜好的目标用户特征向量,以及基于存在关联关系的用户和操作类型来生成表征目标物品对用户的吸引力特征的目标物品特征向量,来预测目标用户对目标物品的进行多个操作类型的操作的概率,可以更准确的刻画出用户针对于物品的操作概率。An embodiment of the present application provides a recommendation method, the method includes: acquiring a first operation information set of a target user, the first operation information set includes attribute information of multiple items, multiple operation types, and the multiple The corresponding relationship between an item and the multiple operation types, the corresponding relationship is used to represent the operation type of the operation performed by the target user on the multiple items; perform feature extraction according to the first operation information set to determine the target User feature vector; acquire the second operation information set of the target item, the second operation information set includes attribute information of multiple users, the multiple operation types, and the multiple users and the multiple operation types A corresponding relationship, the corresponding relationship is used to represent the operation type of the operation performed by the multiple users on the target item; perform feature extraction according to the second operation information set to determine the target item feature vector; according to the target user feature vector and The target item feature vector outputs recommendation information based on the target recommendation model, and the recommendation information is used to represent the probability that the target user performs operations of the multiple operation types on the target item; when the recommendation information satisfies the preset condition, determine to recommend the target item to the target user. Through the above method, the target user feature vector representing the preferences of the target user is generated based on the associated items and the operation type, and the target item feature representing the attractiveness of the target item to the user is generated based on the associated user and the operation type Vector, to predict the probability of the target user performing multiple types of operations on the target item, which can more accurately describe the user's operation probability for the item.
附图说明Description of drawings
图1为人工智能主体框架的一种结构示意图;Fig. 1 is a kind of structural schematic diagram of main frame of artificial intelligence;
图2为本申请实施例提供的一种系统架构的示意图;FIG. 2 is a schematic diagram of a system architecture provided by an embodiment of the present application;
图3为本申请实施例提供的一种信息推荐流程的示意图;FIG. 3 is a schematic diagram of an information recommendation process provided by an embodiment of the present application;
图4为本申请实施例提供的一种信息推荐方法的流程示意图;FIG. 4 is a schematic flowchart of an information recommendation method provided in an embodiment of the present application;
图5为本申请实施例提供的一种操作信息的示意图;Fig. 5 is a schematic diagram of a kind of operation information provided by the embodiment of the present application;
图6为本申请实施例提供的一种信息推荐方法的示意图;FIG. 6 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图7为本申请实施例提供的一种信息推荐方法的示意图;FIG. 7 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图8为本申请实施例提供的一种信息推荐方法的示意图;FIG. 8 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图9为本申请实施例提供的一种信息推荐方法的示意图;FIG. 9 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图10为本申请实施例提供的一种信息推荐方法的示意图;FIG. 10 is a schematic diagram of an information recommendation method provided in an embodiment of the present application;
图11为本申请实施例提供的一种信息推荐方法的示意图;FIG. 11 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图12为本申请实施例提供的一种信息推荐方法的示意图;FIG. 12 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图13为本申请实施例提供的一种信息推荐方法的示意图;FIG. 13 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图14为本申请实施例提供的一种信息推荐方法的示意图;FIG. 14 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图15为本申请实施例提供的一种信息推荐方法的示意图;FIG. 15 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图16为本申请实施例提供的一种信息推荐方法的示意图;FIG. 16 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图17为本申请实施例提供的一种信息推荐方法的示意图;FIG. 17 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图18为本申请实施例提供的一种信息推荐方法的示意图;FIG. 18 is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图19a为本申请实施例提供的一种信息推荐方法的示意图;Fig. 19a is a schematic diagram of an information recommendation method provided by an embodiment of the present application;
图19b为本申请实施例提供的一种用户行为预测方法的示意图;Fig. 19b is a schematic diagram of a user behavior prediction method provided by an embodiment of the present application;
图20为本申请实施例提供的一种推荐模型训练方法的示意图;FIG. 20 is a schematic diagram of a recommended model training method provided in an embodiment of the present application;
图21为本申请实施例提供的一种信息推荐装置的示意图;FIG. 21 is a schematic diagram of an information recommendation device provided by an embodiment of the present application;
图22为本申请实施例提供的一种用户行为预测装置的示意图;FIG. 22 is a schematic diagram of a user behavior prediction device provided by an embodiment of the present application;
图23为本申请实施例提供的一种推荐模型训练装置的示意图;FIG. 23 is a schematic diagram of a recommended model training device provided in an embodiment of the present application;
图24为本申请实施例提供的一种执行设备的示意图;Fig. 24 is a schematic diagram of an execution device provided by an embodiment of the present application;
图25为本申请实施例提供的一种训练设备的示意图;FIG. 25 is a schematic diagram of a training device provided by an embodiment of the present application;
图26为本申请实施例提供的一种芯片的示意图。FIG. 26 is a schematic diagram of a chip provided by an embodiment of the present application.
具体实施方式detailed description
下面结合本发明实施例中的附图对本发明实施例进行描述。本发明的实施方式部分使用的术语仅用于对本发明的具体实施例进行解释,而非旨在限定本发明。Embodiments of the present invention will be described below with reference to the drawings in the embodiments of the present invention. The terms used in the embodiments of the present invention are only used to explain specific examples of the present invention, and are not intended to limit the present invention.
下面结合附图,对本申请的实施例进行描述。本领域普通技术人员可知,随着技术的发展和新场景的出现,本申请实施例提供的技术方案对于类似的技术问题,同样适用。Embodiments of the present application are described below in conjunction with the accompanying drawings. Those of ordinary skill in the art know that, with the development of technology and the emergence of new scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.
本申请的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的术语在适当情况下可以互换,这仅仅是描述本申请的实施例中对相同属性的对象在描述时所采用的区分方式。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,以便包含一系列单元的过程、方法、系统、产品或设备不必限于那些单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它单元。The terms "first", "second" and the like in the specification and claims of the present application and the above drawings are used to distinguish similar objects, and are not necessarily used to describe a specific sequence or sequence. It should be understood that the terms used in this way can be interchanged under appropriate circumstances, and this is merely a description of the manner in which objects with the same attribute are described in the embodiments of the present application. Furthermore, the terms "comprising" and "having", as well as any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, product, or apparatus comprising a series of elements is not necessarily limited to those elements, but may include elements not expressly included. Other elements listed explicitly or inherent to the process, method, product, or apparatus.
首先对人工智能系统总体工作流程进行描述,请参见图1,图1示出的为人工智能主体框架的一种结构示意图,下面从“智能信息链”(水平轴)和“IT价值链”(垂直轴)两个维度对上述人工智能主题框架进行阐述。其中,“智能信息链”反映从数据的获取到处理的一列过程。举例来说,可以是智能信息感知、智能信息表示与形成、智能推理、智能决策、智能执行与输出的一般过程。在这个过程中,数据经历了“数据—信息—知识—智慧”的凝练过程。“IT价值链”从人智能的底层基础设施、信息(提供和处理技术实现)到系统的产业生态过程,反映人工智能为信息技术产业带来的价值。First, describe the overall workflow of the artificial intelligence system. Please refer to Figure 1. Figure 1 shows a schematic structural diagram of the main framework of artificial intelligence. The following is from the "intelligent information chain" (horizontal axis) and "IT value chain" ( Vertical axis) to illustrate the above artificial intelligence theme framework in two dimensions. Among them, the "intelligent information chain" reflects a series of processes from data acquisition to processing. For example, it can be the general process of intelligent information perception, intelligent information representation and formation, intelligent reasoning, intelligent decision-making, intelligent execution and output. In this process, the data has undergone a condensed process of "data-information-knowledge-wisdom". "IT value chain" reflects the value brought by artificial intelligence to the information technology industry from the underlying infrastructure of artificial intelligence, information (provided and processed by technology) to the systematic industrial ecological process.
(1)基础设施(1) Infrastructure
基础设施为人工智能系统提供计算能力支持,实现与外部世界的沟通,并通过基础平台实现支撑。通过传感器与外部沟通;计算能力由智能芯片(CPU、NPU、GPU、ASIC、FPGA等硬件加速芯片)提供;基础平台包括分布式计算框架及网络等相关的平台保障和支持,可以包括云存储和计算、互联互通网络等。举例来说,传感器和外部沟通获取数据,这些数据提供给基础平台提供的分布式计算系统中的智能芯片进行计算。The infrastructure provides computing power support for the artificial intelligence system, realizes communication with the outside world, and realizes support through the basic platform. Communicate with the outside through sensors; computing power is provided by smart chips (CPU, NPU, GPU, ASIC, FPGA and other hardware acceleration chips); the basic platform includes distributed computing framework and network and other related platform guarantees and supports, which can include cloud storage and Computing, interconnection network, etc. For example, sensors communicate with the outside to obtain data, and these data are provided to the smart chips in the distributed computing system provided by the basic platform for calculation.
(2)数据(2) data
基础设施的上一层的数据用于表示人工智能领域的数据来源。数据涉及到图形、图像、语音、文本,还涉及到传统设备的物联网数据,包括已有系统的业务数据以及力、位移、液位、温度、湿度等感知数据。Data from the upper layer of the infrastructure is used to represent data sources in the field of artificial intelligence. The data involves graphics, images, voice, text, and IoT data of traditional equipment, including business data of existing systems and sensory data such as force, displacement, liquid level, temperature, and humidity.
(3)数据处理(3) Data processing
数据处理通常包括数据训练,机器学习,深度学习,搜索,推理,决策等方式。Data processing usually includes data training, machine learning, deep learning, search, reasoning, decision-making, etc.
其中,机器学习和深度学习可以对数据进行符号化和形式化的智能信息建模、抽取、预处理、训练等。Among them, machine learning and deep learning can symbolize and formalize intelligent information modeling, extraction, preprocessing, training, etc. of data.
推理是指在计算机或智能系统中,模拟人类的智能推理方式,依据推理控制策略,利用形式化的信息进行机器思维和求解问题的过程,典型的功能是搜索与匹配。Reasoning refers to the process of simulating human intelligent reasoning in a computer or intelligent system, and using formalized information to carry out machine thinking and solve problems according to reasoning control strategies. The typical functions are search and matching.
决策是指智能信息经过推理后进行决策的过程,通常提供分类、排序、预测等功能。Decision-making refers to the process of decision-making after intelligent information is reasoned, and usually provides functions such as classification, sorting, and prediction.
(4)通用能力(4) General ability
对数据经过上面提到的数据处理后,进一步基于数据处理的结果可以形成一些通用的能力,比如可以是算法或者一个通用系统,例如,翻译,文本的分析,计算机视觉的处理,语音识别,图像的识别等等。After the above-mentioned data processing is performed on the data, some general capabilities can be formed based on the results of data processing, such as algorithms or a general system, such as translation, text analysis, computer vision processing, speech recognition, image processing identification, etc.
(5)智能产品及行业应用(5) Smart products and industry applications
智能产品及行业应用指人工智能系统在各领域的产品和应用,是对人工智能整体解决方案的封装,将智能信息决策产品化、实现落地应用,其应用领域主要包括:智能终端、智能交通、智能医疗、自动驾驶、智慧城市等。Intelligent products and industry applications refer to the products and applications of artificial intelligence systems in various fields. It is the packaging of the overall solution of artificial intelligence, which commercializes intelligent information decision-making and realizes landing applications. Its application fields mainly include: intelligent terminals, intelligent transportation, Smart healthcare, autonomous driving, smart cities, etc.
本申请实施例可以应用于信息推荐领域,具体的,可以应用于应用市场、音乐播放推荐、视频播放推荐、阅读类推荐、新闻资讯推荐以及网页中的信息推荐等。本申请可以应用于推荐系统,推荐系统可以基于本申请提供的推荐方法来确定推荐对象,推荐对象例如可以但不限于是应用程序(application,APP)、音视频、网页以及新闻资讯等物品。The embodiments of the present application can be applied to the field of information recommendation, specifically, application markets, music playback recommendations, video playback recommendations, reading recommendations, news information recommendations, and information recommendations in web pages. This application can be applied to a recommendation system. The recommendation system can determine recommendation objects based on the recommendation method provided by this application. The recommendation objects can be, for example but not limited to, items such as applications (APP), audio and video, web pages, and news information.
在推荐系统中,信息推荐可以包括预测和推荐等过程。其中,预测所需要解决的是预测用户对每个物品的喜好程度,可以通过用户选择该物品的概率来反映上述喜好程度。推荐可以是根据预测的结果将推荐对象进行排序,例如根据预测的喜好程度,按照喜好程度高到低的顺序进行排序,并基于排序的结果对用户进行信息推荐。In recommender systems, information recommendation can include processes such as prediction and recommendation. Among them, what needs to be solved in the prediction is to predict the user's preference for each item, which can be reflected by the probability of the user selecting the item. The recommendation can be to sort the recommended objects according to the predicted results, for example, according to the predicted liking degree, sorting in descending order of liking degree, and recommending information to the user based on the sorting result.
例如,在应用市场的场景中,推荐系统可以基于排序的结果对用户进行应用程序的推荐,在音乐推荐的场景中,推荐系统可以基于排序的结果对用户进行音乐的推荐,在视频推荐的场景中,推荐系统可以基于排序的结果对用户进行视频的推荐。For example, in the application market scenario, the recommendation system can recommend applications to users based on the ranking results. In the music recommendation scenario, the recommendation system can recommend music to users based on the ranking results. In the video recommendation scenario In , the recommendation system can recommend videos to users based on the ranking results.
接下来介绍本申请实施例的应用架构。Next, the application architecture of the embodiment of the present application is introduced.
下面结合图2对本申请实施例提供的系统架构进行详细的介绍。图2为本申请一实施例提供的系统架构示意图。如图2所示,系统架构500包括执行设备510、训练设备520、数据库530、客户设备540、数据存储系统550以及数据采集系统560。The system architecture provided by the embodiment of the present application will be described in detail below with reference to FIG. 2 . FIG. 2 is a schematic diagram of a system architecture provided by an embodiment of the present application. As shown in FIG. 2 , the
执行设备510包括计算模块511、I/O接口512、预处理模块513和预处理模块514。计算模块511中可以包括目标模型/规则501,预处理模块513和预处理模块514是可选的。The
数据采集设备560用于采集训练样本。在本申请实施例中,训练样本可以为用户的历史操作记录,该历史操作记录可以为用户的行为日志(logs),该历史操作记录可以包括用户针对于物品的操作信息,其中,操作信息可以包括操作类型、用户的标识、物品的标识,在物品为电商产品时,操作类型可以包括但不限于点击、购买、退货、加入购物车等等,在物品为应用程序时,操作类型可以但不限于为点击、下载等等,训练样本为对初始化的推荐模型进行训练时所采用的数据。在采集到训练样本之后,数据采集设备560将这些训练样本存入数据库530。The
应理解,本申请实施例中数据采集设备560可以对采集到的历史操作记录进行挖掘,得到更多的用户针对于物品的操作信息(例如本申请实施例中的第一用户对第一物品的第一操作类型等);It should be understood that in the embodiment of the present application, the
训练设备520可以基于数据库530中维护的训练样本对初始化的推荐模型进行训练,以得到目标模型/规则501。本申请实施例中,目标模型/规则501可以为推荐模型,推荐模型可以基于用户针对于物品的操作信息来预测用户针对于物品进行操作类型对应的操作的概率,该概率可以用于进行信息推荐。The
需要说明的是,在实际应用中,数据库530中维护的训练样本不一定都来自于数据采集设备560的采集,也有可能是从其他设备接收得到的,或者是基于数据采集设备560采集的数据进行数据扩展得到的(例如本申请实施例中的目标用户对所述第一物品的第二操作类型)。另外需要说明的是,训练设备520也不一定完全基于数据库530维护的训练样本进行目标模型/规则501的训练,也有可能从云端或其他地方获取训练样本进行模型训练,上述描述不应该作为对本申请实施例的限定。It should be noted that, in practical applications, the training samples maintained in the
根据训练设备520训练得到的目标模型/规则501可以应用于不同的系统或设备中,如应用于图2所示的执行设备510,所述执行设备510可以是终端,如手机终端,平板电脑,笔记本电脑,增强现实(augmented reality,AR)/虚拟现实(virtual reality,VR)设备,车载终端等,还可以是服务器或者云端等。The target model/
在图2中,执行设备510配置输入/输出(input/output,I/O)接口512,用于与外部设备进行数据交互,用户可以通过客户设备540向I/O接口512输入数据(例如本申请实施例中的操作信息,例如第二用户针对于第一物品的操作信息、第二用户针对于第二物品的操作信息、第一用户针对于第一物品的操作信息等)。In FIG. 2, the
预处理模块513和预处理模块514用于根据I/O接口512接收到的输入数据进行预处理。应理解,可以没有预处理模块513和预处理模块514或者只有的一个预处理模块。当不存在预处理模块513和预处理模块514时,可以直接采用计算模块511对输入数据进行处理。The
在执行设备510对输入数据进行预处理,或者在执行设备510的计算模块511执行计算等相关的处理过程中,执行设备510可以调用数据存储系统550中的数据、代码等以用于相应的处理,也可以将相应处理得到的数据、指令等存入数据存储系统550中。When the
最后,I/O接口512将处理结果呈现给客户设备540,从而提供给用户。Finally, the I/
本申请实施例中,上述执行设备510可以获取到数据存储系统550中存储的代码来实现本申请实施例中的推荐方法。In the embodiment of the present application, the
本申请实施例中,执行设备510可以包括硬件电路(如专用集成电路(applicationspecific integrated circuit,ASIC)、现场可编程门阵列(field-programmable gatearray,FPGA)、通用处理器、数字信号处理器(digital signal processing,DSP)、微处理器或微控制器等等)、或这些硬件电路的组合,例如,执行设备510可以为具有执行指令功能的硬件系统,如CPU、DSP等,或者为不具有执行指令功能的硬件系统,如ASIC、FPGA等,或者为上述不具有执行指令功能的硬件系统以及具有执行指令功能的硬件系统的组合。In the embodiment of the present application, the
具体的,执行设备510可以为具有执行指令功能的硬件系统,本申请实施例提供的信息推荐方法可以为存储在数据存储系统550中的软件代码,执行设备510可以从数据存储系统550中获取到软件代码,并执行获取到的软件代码来实现本申请实施例提供的推荐方法。Specifically, the
应理解,执行设备510可以为不具有执行指令功能的硬件系统以及具有执行指令功能的硬件系统的组合,本申请实施例提供的推荐方法的部分步骤还可以通过执行设备510中不具有执行指令功能的硬件系统来实现,这里并不限定。It should be understood that the
在图2所示情况下,用户可以手动给定输入数据,该“手动给定输入数据”可以通过I/O接口512提供的界面进行操作。另一种情况下,客户设备540可以自动地向I/O接口512发送输入数据,如果要求客户设备540自动发送输入数据需要获得用户的授权,则用户可以在客户设备540中设置相应权限。用户可以在客户设备540查看执行设备510输出的结果,具体的呈现形式可以是显示、声音、动作等具体方式。客户设备540也可以作为数据采集端,采集如图所示输入I/O接口512的输入数据及输出I/O接口512的输出结果作为新的样本数据,并存入数据库530。当然,也可以不经过客户设备540进行采集,而是由I/O接口512直接将如图所示输入I/O接口512的输入数据及输出I/O接口512的输出结果,作为新的样本数据存入数据库530。In the situation shown in FIG. 2 , the user can manually specify input data, and the “manually specify input data” can be operated through the interface provided by the I/
值得注意的是,图2仅是本申请实施例提供的一种系统架构的示意图,图中所示设备、器件、模块等之间的位置关系不构成任何限制,例如,在图2中,数据存储系统550相对执行设备510是外部存储器,在其它情况下,也可以将数据存储系统550置于执行设备510中。应理解,上述执行设备510可以部署于客户设备540中。It should be noted that FIG. 2 is only a schematic diagram of a system architecture provided by the embodiment of the present application, and the positional relationship between devices, devices, modules, etc. shown in the figure does not constitute any limitation. For example, in FIG. 2, the data The storage system 550 is an external memory relative to the
由于本申请实施例涉及大量神经网络的应用,为了便于理解,下面先对本申请实施例涉及的相关术语及神经网络等相关概念进行介绍。Since the embodiment of the present application involves the application of a large number of neural networks, for ease of understanding, the following first introduces related terms and neural network related concepts involved in the embodiment of the present application.
1、点击概率(click-throughrate,CTR)1. Click probability (click-through rate, CTR)
点击概率又可以称为点击率,是指网站或者应用程序上推荐信息(例如,推荐物品)被点击次数和曝光次数之比,点击率通常是推荐系统中衡量推荐系统的重要指标。The click probability can also be called the click rate, which refers to the ratio of the number of times recommended information (for example, recommended items) on a website or application is clicked to the number of times it is exposed. The click rate is usually an important indicator for measuring the recommendation system in the recommendation system.
2、个性化推荐系统2. Personalized recommendation system
个性化推荐系统是指根据用户的历史数据(例如本申请实施例中的操作信息),利用机器学习算法进行分析,并以此对新请求进行预测,给出个性化的推荐结果的系统。A personalized recommendation system refers to a system that uses machine learning algorithms to analyze the user's historical data (such as the operation information in the embodiment of this application), predicts new requests, and gives personalized recommendation results.
3、离线训练(offlinetraining)3. Offline training
离线训练是指在个性化推荐系统中,根据用户的历史数据(例如本申请实施例中的操作信息),对推荐模型参数按照器学习的算法进行迭代更新直至达到设定要求的模块。Offline training refers to a module in which in the personalized recommendation system, according to the user's historical data (such as the operation information in the embodiment of this application), the recommended model parameters are iteratively updated according to the machine learning algorithm until the set requirements are met.
4、在线预测(onlineinference)4. Online prediction (onlineinference)
在线预测是指基于离线训练好的模型,根据用户、物品和上下文的特征预测该用户在当前上下文环境下对推荐物品的喜好程度,预测用户选择推荐物品的概率。Online prediction refers to predicting the user's preference for recommended items in the current context based on the offline trained model based on the characteristics of the user, item and context, and predicting the probability of the user choosing the recommended item.
例如,图3是本申请实施例提供的推荐系统的示意图。如图3所示,当一个用户进入统,会触发一个推荐的请求,推荐系统会将该请求及其相关信息(例如本申请实施例中的操作信息)输入到推荐模型,然后预测用户对系统内的物品的选择率。进一步,根据预测的选择率或基于该选择率的某个函数将物品降序排列,即推荐系统可以按顺序将物品展示在不同的位置作为对用户的推荐结果。用户浏览不同的处于位置的物品并发生用户行为,如浏览、选择以及下载等。同时,用户的实际行为会存入日志中作为训练数据,通过离线训练模块不断更新推荐模型的参数,提高模型的预测效果。For example, FIG. 3 is a schematic diagram of a recommendation system provided by an embodiment of the present application. As shown in Figure 3, when a user enters the system, a recommendation request will be triggered, and the recommendation system will input the request and related information (such as the operation information in the embodiment of this application) into the recommendation model, and then predict the user's preference for the system. The selection rate of the items in . Further, according to the predicted selection rate or a certain function based on the selection rate, the items are arranged in descending order, that is, the recommendation system can display the items in different positions in order as the recommendation result for the user. The user browses items in different locations and performs user actions, such as browsing, selecting, and downloading. At the same time, the user's actual behavior will be stored in the log as training data, and the parameters of the recommendation model will be continuously updated through the offline training module to improve the prediction effect of the model.
例如,用户打开智能终端(例如,手机)中的应用市场即可触发应用市场中的推荐系统。应用市场的推荐系统会根据用户的历史行为日志,例如,用户的历史下载记录、用户选择记录,应用市场的自身特征,比如时间、地点等环境特征信息,预测用户下载推荐的各个候选APP的概率。根据计算的结果,应用市场的推荐系统可以按照预测的概率值大小降序展示候选APP,从而提高候选APP的下载概率。For example, when a user opens an application market in a smart terminal (for example, a mobile phone), the recommendation system in the application market can be triggered. The recommendation system of the application market will predict the probability of the user downloading each recommended candidate APP based on the user's historical behavior logs, such as the user's historical download records, user selection records, and the application market's own characteristics, such as time, location and other environmental characteristics. . According to the calculation results, the recommendation system of the application market can display candidate APPs in descending order according to the predicted probability value, thereby increasing the download probability of candidate APPs.
示例性地,可以将预测的用户选择率较高的APP展示在靠前的推荐位置,将预测的用户选择率较低的APP展示在靠后的推荐位置。For example, APPs with a higher predicted user selection rate may be displayed in a higher recommended position, and APPs with a lower predicted user selection rate may be displayed in a lower recommended position.
上述推荐模型可以是神经网络模型,下面对本申请实施例可能涉及的神经网络的相关术语和概念进行介绍。The foregoing recommendation model may be a neural network model, and the following will introduce related terms and concepts of neural networks that may be involved in the embodiments of the present application.
(1)神经网络(1) neural network
神经网络可以是由神经单元组成的,神经单元可以是指以xs(即输入数据)和截距1为输入的运算单元,该运算单元的输出可以为:The neural network can be composed of neural units, and the neural unit can refer to an operation unit that takes xs (ie input data) and
其中,s=1、2、……n,n为大于1的自然数,Ws为xs的权重,b为神经单元的偏置。f为神经单元的激活函数(activation functions),用于将非线性特性引入神经网络中,来将神经单元中的输入信号转换为输出信号。该激活函数的输出信号可以作为下一层卷积层的输入,激活函数可以是sigmoid函数。神经网络是将多个上述单一的神经单元联结在一起形成的网络,即一个神经单元的输出可以是另一个神经单元的输入。每个神经单元的输入可以与前一层的局部接受域相连,来提取局部接受域的特征,局部接受域可以是由若干个神经单元组成的区域。Wherein, s=1, 2, ... n, n is a natural number greater than 1, Ws is the weight of xs, and b is the bias of the neural unit. f is the activation function of the neural unit, which is used to introduce nonlinear characteristics into the neural network to convert the input signal in the neural unit into an output signal. The output signal of the activation function can be used as the input of the next convolutional layer, and the activation function can be a sigmoid function. A neural network is a network formed by connecting multiple above-mentioned single neural units, that is, the output of one neural unit can be the input of another neural unit. The input of each neural unit can be connected with the local receptive field of the previous layer to extract the features of the local receptive field. The local receptive field can be an area composed of several neural units.
(2)深度神经网络(2) Deep Neural Network
深度神经网络(Deep Neural Network,DNN),也称多层神经网络,可以理解为具有很多层隐含层的神经网络,这里的“很多”并没有特别的度量标准。从DNN按不同层的位置划分,DNN内部的神经网络可以分为三类:输入层,隐含层,输出层。一般来说第一层是输入层,最后一层是输出层,中间的层数都是隐含层。层与层之间是全连接的,也就是说,第i层的任意一个神经元一定与第i+1层的任意一个神经元相连。虽然DNN看起来很复杂,但是就每一层的工作来说,其实并不复杂,简单来说就是如下线性关系表达式:其中,是输入向量,是输出向量,是偏移向量,W是权重矩阵(也称系数),α()是激活函数。每一层仅仅是对输入向量经过如此简单的操作得到输出向量由于DNN层数多,则系数W和偏移向量的数量也就很多了。这些参数在DNN中的定义如下所述:以系数W为例:假设在一个三层的DNN中,第二层的第4个神经元到第三层的第2个神经元的线性系数定义为上标3代表系数W所在的层数,而下标对应的是输出的第三层索引2和输入的第二层索引4。总结就是:第L-1层的第k个神经元到第L层的第j个神经元的系数定义为需要注意的是,输入层是没有W参数的。在深度神经网络中,更多的隐含层让网络更能够刻画现实世界中的复杂情形。理论上而言,参数越多的模型复杂度越高,“容量”也就越大,也就意味着它能完成更复杂的学习任务。训练深度神经网络的也就是学习权重矩阵的过程,其最终目的是得到训练好的深度神经网络的所有层的权重矩阵(由很多层的向量W形成的权重矩阵)。Deep Neural Network (DNN), also known as multi-layer neural network, can be understood as a neural network with many hidden layers, and there is no special metric for "many" here. According to the position of different layers of DNN, the neural network inside DNN can be divided into three categories: input layer, hidden layer, and output layer. Generally speaking, the first layer is the input layer, the last layer is the output layer, and the layers in the middle are all hidden layers. The layers are fully connected, that is, any neuron in the i-th layer must be connected to any neuron in the i+1-th layer. Although DNN looks complicated, it is actually not complicated in terms of the work of each layer. In simple terms, it is the following linear relationship expression: in, is the input vector, is the output vector, Is the offset vector, W is the weight matrix (also called coefficient), and α() is the activation function. Each layer is just the input vector After such a simple operation to get the output vector Due to the large number of DNN layers, the coefficient W and the offset vector The number is also a lot. The definition of these parameters in DNN is as follows: Take the coefficient W as an example: Assume that in a three-layer DNN, the linear coefficient from the fourth neuron of the second layer to the second neuron of the third layer is defined as The superscript 3 represents the layer number of the coefficient W, and the subscript corresponds to the output
(3)损失函数(3) Loss function
在训练深度神经网络的过程中,因为希望深度神经网络的输出尽可能的接近真正想要预测的值,所以可以通过比较当前网络的预测值和真正想要的目标值,再根据两者之间的差异情况来更新每一层神经网络的权重向量(当然,在第一次更新之前通常会有初始化的过程,即为深度神经网络中的各层预先配置参数),比如,如果网络的预测值高了,就调整权重向量让它预测低一些,不断的调整,直到深度神经网络能够预测出真正想要的目标值或与真正想要的目标值非常接近的值。因此,就需要预先定义“如何比较预测值和目标值之间的差异”,这便是损失函数(loss function)或目标函数(objective function),它们是用于衡量预测值和目标值的差异的重要方程。其中,以损失函数举例,损失函数的输出值(loss)越高表示差异越大,那么深度神经网络的训练就变成了尽可能缩小这个loss的过程。In the process of training the deep neural network, because it is hoped that the output of the deep neural network is as close as possible to the value you really want to predict, you can compare the predicted value of the current network with the target value you really want, and then according to the difference between the two to update the weight vector of each layer of the neural network (of course, there is usually an initialization process before the first update, that is, to pre-configure parameters for each layer in the deep neural network), for example, if the predicted value of the network If it is high, adjust the weight vector to make it predict lower, and keep adjusting until the deep neural network can predict the real desired target value or a value very close to the real desired target value. Therefore, it is necessary to pre-define "how to compare the difference between the predicted value and the target value", which is the loss function (loss function) or objective function (objective function), which are used to measure the difference between the predicted value and the target value important equation. Among them, taking the loss function as an example, the higher the output value (loss) of the loss function, the greater the difference. Then the training of the deep neural network becomes a process of reducing the loss as much as possible.
(4)反向传播算法(4) Back propagation algorithm
可以采用误差反向传播(back propagation,BP)算法在训练过程中修正初始模型中参数的大小,使得模型的误差损失越来越小。具体地,前向传递输入信号直至输出会产生误差损失,通过反向传播误差损失信息来更新初始模型中的参数,从而使误差损失收敛。反向传播算法是以误差损失为主导的反向传播运动,旨在得到最优的模型参数,例如权重矩阵。The error backpropagation (back propagation, BP) algorithm can be used to correct the size of the parameters in the initial model during the training process, so that the error loss of the model becomes smaller and smaller. Specifically, passing the input signal forward until the output produces an error loss, and updating the parameters in the initial model by backpropagating the error loss information, so that the error loss converges. The backpropagation algorithm is a backpropagation movement dominated by error loss, aiming to obtain the optimal model parameters, such as the weight matrix.
接下来以模型推理阶段为例对本申请实施例提供的信息推荐方法进行说明。Next, the information recommendation method provided by the embodiment of the present application will be described by taking the model reasoning stage as an example.
参照图4,图4为本申请实施例提供的一种推荐方法的实施例示意,如图4示出的那样,本申请实施例提供的一种推荐方法包括:Referring to FIG. 4, FIG. 4 is a schematic diagram of an embodiment of a recommendation method provided by the embodiment of the present application. As shown in FIG. 4, a recommendation method provided by the embodiment of the present application includes:
401、获取目标用户的第一操作信息集,所述第一操作信息集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标用户对所述多个物品进行的操作的操作类型。401. Acquire a first operation information set of a target user, where the first operation information set includes attribute information of multiple items, multiple operation types, and correspondence between the multiple items and the multiple operation types, so The corresponding relationship is used to represent the type of operation performed by the target user on the plurality of items.
本申请实施例中,步骤401的执行主体可以为终端设备,终端设备可以为便携式移动设备,例如但不限于移动或便携式计算设备(如智能手机)、个人计算机、服务器计算机、手持式设备(例如平板)或膝上型设备、多处理器系统、游戏控制台或控制器、基于微处理器的系统、机顶盒、可编程消费电子产品、移动电话、具有可穿戴或配件形状因子(例如,手表、眼镜、头戴式耳机或耳塞)的移动计算和/或通信设备、网络PC、小型计算机、大型计算机、包括上面的系统或设备中的任何一种的分布式计算环境等等。In the embodiment of the present application, the execution body of
本申请实施例中,步骤401的执行主体可以为云侧的服务器,服务器可以接收来自终端设备发送的目标用户的第一操作信息集,进而服务器可以获取到目标用户的第一操作信息集。In the embodiment of the present application,
为了方便描述,以下不对执行主体的形态进行区分,都描述为执行设备。本申请实施例中,执行设备可以获取到目标用户的第一操作信息集,其中,目标用户的第一操作信息集可以基于目标用户与物品之间的交互记录(例如用户的行为日志)得到,该第一操作信息集中的信息可以包括目标用户对各个物品的真实操作记录,第一操作信息集可以包括目标用户的属性信息、各个物品的属性信息信息以及所述目标用户对所述多个物品进行的操作的操作类型。For the convenience of description, the form of the execution subject will not be distinguished below, and they will all be described as execution devices. In the embodiment of the present application, the execution device may obtain the first operation information set of the target user, wherein the first operation information set of the target user may be obtained based on the interaction record (such as the user's behavior log) between the target user and the item, The information in the first operation information set may include the target user’s actual operation records on each item, and the first operation information set may include the target user’s attribute information, each item’s attribute information, and the target user’s operation of the multiple items. The operation type of the operation being performed.
其中,目标用户的属性信息可以为与用户喜好特征相关的属性,性别、年龄、职业、收入、爱好以及受教育程度中的至少一种,其中,性别可以为男或者女,年龄可以为0-100之间的数字,职业可以为教师、程序员、厨师等等,爱好可以为篮球、网球、跑步等等,受教育程度可以为小学、初中、高中、大学等等;本申请并不限定目标用户的属性信息的具体类型。Among them, the attribute information of the target user can be attributes related to user preferences, at least one of gender, age, occupation, income, hobbies, and education level, where the gender can be male or female, and the age can be 0- Number between 100, occupation can be teacher, programmer, chef, etc., hobbies can be basketball, tennis, running, etc., education level can be elementary school, junior high school, high school, university, etc.; this application does not limit the target The specific type of user attribute information.
其中,物品可以为实体物品,或者是虚拟物品,例如可以为APP、音视频、网页以及新闻资讯等物品,物品的属性信息可以为物品名称、开发者、安装包大小、品类以及好评度中的至少一种,其中,以物品为应用程序为例,物品的品类可以为聊天类、跑酷类游戏、办公类等等,好评度可以为针对于物品的打分、评论等;本申请并不限定物品的属性信息的具体类型。Among them, the item can be a physical item or a virtual item, for example, it can be an item such as APP, audio and video, web page, and news information, and the attribute information of the item can be item name, developer, installation package size, category, and favorable rating. At least one, wherein, taking an item as an example of an application program, the category of the item can be chatting, parkour games, office, etc., and the favorable rating can be scoring, commenting, etc. for the item; this application does not limit The specific type of attribute information of the item.
其中,操作类型可以为目标用户针对于物品的行为操作类型,在网络平台和应用上,用户往往和物品有多种多样的交互形式(也就是有多种操作类型),比如图5所示用户在电商平台行为中的浏览、点击、加入购物车、购买等操作类型。这些多种多样的行为反映了用户的偏好,对于准确的刻画用户特征有很大的帮助。Among them, the operation type can be the behavior operation type of the target user for the item. On the network platform and application, the user often has a variety of interaction forms with the item (that is, there are multiple operation types), such as the user shown in Figure 5 Operation types such as browsing, clicking, adding to shopping cart, and purchasing in e-commerce platform behaviors. These various behaviors reflect user preferences and are of great help in accurately characterizing users.
在一种可能的实现中,第一操作信息集可以包括第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;其中,所述第一操作类型为所述目标用户对所述第一物品的真实操作行为。也就是说,上述第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系是基于目标用户的真实操作记录中得到的。In a possible implementation, the first operation information set may include the attribute information of the first item, the first operation type, and the correspondence between the first item and the first operation type; wherein, the first The operation type is the actual operation behavior of the target user on the first item. That is to say, the attribute information of the first item, the first operation type, and the correspondence between the first item and the first operation type are obtained based on the real operation records of the target user.
示例性的,图5中的操作信息可以包括:用户1针对于物品1的浏览操作、用户1针对于物品1的购买操作、用户1针对于物品1的加入购物车操作、用户2针对于物品1的浏览操作、用户2针对于物品1的购买操作。Exemplarily, the operation information in FIG. 5 may include:
本申请实施例中,可以将上述操作信息表达为三元组信息格式,三元组的形式可以为<用户,关系,物品>,其中,三元组中的用户可以为用户的信息,物品为可以为物品的信息,关系可以为操作类型,例如用户1针对于物品2的购买操作可以表达为:<用户1,购买操作,物品2>。In the embodiment of the present application, the above operation information can be expressed as a triplet information format, and the format of the triplet can be <user, relationship, item>, where the user in the triplet can be user information, and the item can be It can be item information, and the relationship can be an operation type. For example,
在一种可能的实现中,所述第一操作信息集包括:第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;其中,所述第二操作类型为所述目标用户对所述第二物品的预测操作行为。In a possible implementation, the first operation information set includes: attribute information of a second item, a second operation type, and a correspondence between the second item and the second operation type; wherein, the The second operation type is a predicted operation behavior of the target user on the second item.
本申请实施例中,由于能够获取到的与用户相关的历史操作记录有限,为了提高信息推荐的精准度,可以在有限的历史操作数据中发掘更丰富的信息,进而生成更多的与用户相关的操作信息,进而可以提高历史操作记录的数据利用率。In the embodiment of this application, due to the limited historical operation records that can be obtained related to the user, in order to improve the accuracy of information recommendation, more abundant information can be discovered in the limited historical operation data, and then more user-related information can be generated. operation information, which in turn can improve the data utilization rate of historical operation records.
接下来描述,如何生成所述目标用户对所述第二物品的预测操作行为:Next, how to generate the predicted operation behavior of the target user on the second item is described:
在一种可能的实现中,可以获取第一用户对第二物品的第三操作类型,并基于所述第一用户针对于所述第二物品的所述第三操作类型,且所述第一用户和所述目标用户的物品喜好特征满足预设条件,在所述第一操作信息集中生成所述第二物品与第二操作类型的对应关系。In a possible implementation, the third operation type of the first user on the second item may be obtained, and based on the third operation type of the first user on the second item, and the first The item preference features of the user and the target user satisfy a preset condition, and a correspondence between the second item and a second operation type is generated in the first operation information set.
在一种可能的实现中,所述预设条件可以包括所述第一用户和所述目标用户均为对所述第一物品有操作的用户。In a possible implementation, the preset condition may include that both the first user and the target user are users who operate on the first item.
当不同的用户(例如第一用户和所述目标用户)针对于同一件物品进行了操作时,可以表征出这两个用户有较大可能性具备相同或者相似的喜好,因此可以基于第一用户对于其他物品的操作信息来生成目标用户相关的操作信息,这部分生成的新的和目标用户相关的操作信息虽然不是历史操作记录中的,但是大概率可以表征出目标用户和除了第一物品的其他物品之间可能的操作关联。When different users (such as the first user and the target user) operate on the same item, it can be characterized that the two users are more likely to have the same or similar preferences, so it can be based on the first user For the operation information of other items to generate the operation information related to the target user, although the new operation information related to the target user generated by this part is not in the historical operation record, it can represent the target user and the target user except the first item with high probability. Possible operational associations between other items.
在一种可能的实现中,目标用户和第一用户可以都进行了针对于第一物品的操作,例如目标用户进行了针对于第一物品的浏览操作,而第一用户进行了针对于第一物品的购买操作,则可以认为目标用户和第一用户为具有相似喜好的用户,因此可以基于第一用户对于其他物品之间的历史操作信息,来生成更多的与目标用户有关的操作信息,特别的,基于历史操作记录中还记载有第一用户针对于第二物品的操作信息,则可以生成目标用户针对于所述第二物品的操作信息。In a possible implementation, both the target user and the first user may have performed an operation on the first item, for example, the target user has performed a browsing operation on the first item, while the first user has performed an operation on the first item. For the purchase operation of items, the target user and the first user can be considered as users with similar preferences, so more operation information related to the target user can be generated based on the historical operation information of the first user on other items, In particular, based on the operation information of the first user on the second item also recorded in the historical operation record, the operation information of the target user on the second item may be generated.
其中,为了保证生成的操作信息的准确性,可以将目标用户针对于所述第二物品的操作信息中第二用户针对于第二物品的操作类型设置为与历史操作记录中第一用户针对于第二物品的操作类型一致(也就是第二操作类型和第三操作类型相同)。Wherein, in order to ensure the accuracy of the generated operation information, the operation type of the second user for the second item in the operation information of the target user for the second item can be set to be the same as that for the first user in the historical operation records. The operation type of the second item is the same (that is, the second operation type is the same as the third operation type).
参照图6,所述第一用户和目标用户都对第一物品进行了操作,且第一用户进行了针对于第一物品的操作,且操作类型为第二操作类型,进而生成的所述目标用户针对于所述第二物品的操作,且操作类型为第三操作类型。Referring to FIG. 6 , both the first user and the target user have operated on the first item, and the first user has performed an operation on the first item, and the operation type is the second operation type, and the generated target The user operates on the second item, and the operation type is the third operation type.
示例性的,可以基于操作信息:<目标用户,收藏操作,第一物品>、<第一用户,收藏操作,第一物品>以及<第一用户,购买操作,第二物品>,则可以生成<目标用户,购买操作,第二物品>的操作信息。Exemplarily, based on the operation information: <target user, collection operation, first item>, <first user, collection operation, first item> and <first user, purchase operation, second item>, it can generate Operation information of <target user, purchase operation, second item>.
本申请实施例中,基于针对于相同物品(第一物品)进行了操作的用户(目标用户和第一用户),通过第一用户的其他操作信息,生成与目标用户有关的新的操作信息,在有限的历史操作数据中发掘了更丰富的信息,提高了历史操作记录的数据利用率。In the embodiment of the present application, based on the users (the target user and the first user) who have operated on the same item (the first item), new operation information related to the target user is generated through other operation information of the first user, Richer information is discovered in the limited historical operation data, and the data utilization rate of historical operation records is improved.
此外,在一种可能的实现中,还可以基于所述历史操作记录还包括第二用户针对于所述第二物品的操作信息、以及所述第三用户针对于第三物品的操作信息,生成所述目标用户针对于所述第三物品的操作信息,也就是说第二用户和第一用户可以都进行了针对于第二物品的操作,例如第一用户进行了针对于第二物品的浏览操作,而第二用户进行了针对于第二物品的购买操作,则可以认为第一用户和第二用户为具有相似喜好的用户,由于第一用户和第二用户为具有相似喜好的用户,则可以认为目标用户和第二用户也为具有相似喜好的用户,因此可以基于第二用户对于其他物品之间的历史操作信息,来生成更多的与目标用户有关的操作信息,特别的,基于历史操作记录中还记载有第二用户针对于第三物品的操作信息,则可以生成目标用户针对于所述第三物品的操作信息。In addition, in a possible implementation, based on the historical operation records also including the second user's operation information on the second item and the third user's operation information on the third item, generate The operation information of the target user on the third item, that is to say, both the second user and the first user may have performed operations on the second item, for example, the first user has browsed on the second item operation, and the second user has performed a purchase operation for the second item, it can be considered that the first user and the second user are users with similar preferences. Since the first user and the second user are users with similar preferences, then It can be considered that the target user and the second user are also users with similar preferences, so more operation information related to the target user can be generated based on the historical operation information of the second user on other items, in particular, based on the historical The operation record also records the operation information of the second user on the third item, so the operation information of the target user on the third item can be generated.
其中,为了保证生成的操作信息的准确性,可以将目标用户针对于所述第三物品的操作信息中目标用户针对于第三物品的操作类型设置为与历史操作记录中第二用户针对于第三物品的操作类型一致。Wherein, in order to ensure the accuracy of the generated operation information, the target user's operation type for the third item in the target user's operation information for the third item can be set to be the same as the second user's operation for the first item in the historical operation record. The operation types of the three items are the same.
参照图7,第二用户和第一用户都对第二物品进行了操作,且第二用户还针对于第三物品进行了操作,进而可以生成目标用户针对于所述第三物品的操作信息。Referring to FIG. 7 , both the second user and the first user have performed operations on the second item, and the second user has also performed operations on the third item, so that operation information of the target user on the third item may be generated.
示例性的,例如历史操作信息包括<目标用户,收藏操作,第一物品>、<第一用户,收藏操作,第一物品>、<第一用户,购买操作,第二物品>、<第二用户,浏览操作,第二物品>以及<第二用户,购买操作,第三物品>,则可以生成<目标用户,购买操作,第三物品>的操作信息。Exemplarily, for example, historical operation information includes <target user, collection operation, first item>, <first user, collection operation, first item>, <first user, purchase operation, second item>, <second user, browsing operation, second item> and <second user, purchase operation, third item>, the operation information of <target user, purchase operation, third item> can be generated.
本申请实施例中,基于针对于相同物品(第二物品)进行了操作的用户,通过第二用户的其他操作信息,生成与目标用户有关的新的操作信息,在有限的历史操作数据中发掘了更丰富的信息,提高了历史操作记录的数据利用率。In the embodiment of the present application, based on the user who has operated on the same item (the second item), new operation information related to the target user is generated through other operation information of the second user, and new operation information related to the target user is discovered in the limited historical operation data. It provides richer information and improves the data utilization rate of historical operation records.
在一种可能的实现中,所述预设条件可以包括所述第一用户和所述目标用户的用户属性的差异度小于阈值。In a possible implementation, the preset condition may include that the degree of difference between the user attributes of the first user and the target user is smaller than a threshold.
上述方式通过用户是否针对于同一个物品进行了操作来反应用户之间喜好的相似性,在一种可能的实现中,也可以直接通过用户之间的用户属性差异来确定用户之间喜好的相似性,其中用户属性为能反映出用户喜好的属性。The above method reflects the similarity of preferences between users by whether users have operated on the same item. In a possible implementation, the similarity of preferences between users can also be determined directly through the difference in user attributes between users. properties, where user attributes are attributes that can reflect user preferences.
在一种可能的实现中,用户属性可以为:性别、年龄、职业、收入、爱好以及受教育程度中的至少一种,其中,性别可以为男或者女,年龄可以为0-100之间的数字,职业可以为教师、程序员、厨师等等,爱好可以为篮球、网球、跑步等等,受教育程度可以为小学、初中、高中、大学等等。In a possible implementation, the user attribute can be at least one of: gender, age, occupation, income, hobbies, and education level, where the gender can be male or female, and the age can be between 0-100 Numbers, occupation can be teacher, programmer, chef, etc., hobbies can be basketball, tennis, running, etc., education level can be elementary school, junior high school, high school, university, etc.
本申请实施例中,具有相似用户属性的用户可以认为具有相似的喜好,例如相似用户属性的用户可以为年龄差异很小的用户、性别相同的用户、职业相同或相似的用户(职业相似可以理解为处于同一个行业)、爱好相同或相似的用户(例如都爱好网球的用户)、受教育程度相同或相似的用户(例如都是大学本科毕业的用户),此外,还可以通过权重值来表征用户的用户属性,权重值越相似,则可以表示用户之间的用户属性越相似,此外,还可以通过特征向量来表征用户的用户属性,特征向量之间的距离越近,则可以表示用户之间的用户属性越相似。In the embodiment of the present application, users with similar user attributes can be considered to have similar preferences. For example, users with similar user attributes can be users with little age difference, users with the same gender, users with the same or similar occupations (similar occupations can be understood) users in the same industry), users with the same or similar hobbies (for example, users who both like tennis), and users with the same or similar education level (for example, users who all graduated from college), in addition, it can also be characterized by weight values The user attributes of users, the more similar the weight value, the more similar the user attributes between users can be. In addition, the user attributes of users can also be represented by feature vectors. The closer the distance between feature vectors, the closer the distance between users can be. The more similar the user attributes between them are.
在一种可能的实现中,所述目标用户和所述第一用户之间的用户属性的差异度小于阈值,也就是说目标用户和第一用户为具有相似喜好的用户,因此可以基于第一用户对于其他物品之间的历史操作信息,来生成更多的与目标用户有关的操作信息,特别的,基于历史操作记录中还记载有第一用户针对于第二物品的操作信息,则可以生成目标用户针对于所述第二物品的操作信息。In a possible implementation, the degree of difference between the user attributes between the target user and the first user is smaller than a threshold, that is to say, the target user and the first user are users with similar preferences, and therefore, based on the first The user’s historical operation information on other items to generate more operation information related to the target user. In particular, based on the historical operation records that also record the first user’s operation information on the second item, you can generate Operation information of the target user on the second item.
其中,为了保证生成的操作信息的准确性,可以将目标用户针对于所述第二物品的操作信息中目标用户针对于第二物品的操作类型设置为与历史操作记录中第一用户针对于第二物品的操作类型一致(也就是第二操作类型和第三操作类型相同)。Wherein, in order to ensure the accuracy of the generated operation information, the target user's operation type for the second item in the target user's operation information for the second item can be set to be the same as the first user's operation for the second item in the historical operation record. The operation types of the two items are the same (that is, the second operation type is the same as the third operation type).
示例性的,例如操作信息可以包括<目标用户,收藏操作,第一物品>、<第一用户,购买操作,第二物品>,则基于目标用户和第一用户之间的用户属性差异小于阈值,可以生成<目标用户,购买操作,第二物品>的操作信息。Exemplarily, for example, the operation information may include <target user, collection operation, first item>, <first user, purchase operation, second item>, then based on the user attribute difference between the target user and the first user being less than a threshold , the operation information of <target user, purchase operation, second item> can be generated.
本申请实施例中,基于用户属性相似的用户(目标用户和第一用户),通过第一用户的其他操作信息,生成与目标用户有关的新的操作信息,在有限的历史操作数据中发掘了更丰富的信息,提高了历史操作记录的数据利用率。In the embodiment of this application, based on users with similar user attributes (the target user and the first user), new operation information related to the target user is generated through other operation information of the first user, and new operation information related to the target user is discovered in the limited historical operation data. Richer information improves the data utilization rate of historical operation records.
上述方式通过用户之间的用户属性差异来确定用户之间喜好的相似性,在一种可能的实现中,也可以通过用户是否针对于具有相似物品属性的物品进行了操作来确定用户之间的喜好相似性。The above method determines the similarity of preferences between users through the difference in user attributes between users. In a possible implementation, the similarity between users can also be determined based on whether users have operated on items with similar item attributes. Like similarity.
在一种可能的实现中,所述预设条件可以包括所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。In a possible implementation, the preset condition may include that the first user and the target user are users who operate on an item whose attribute difference is smaller than a threshold.
在一种可能的实现中,物品属性可以为:物品名称、开发者、安装包大小、品类以及好评度中的至少一种,其中,以物品为应用程序为例,物品的品类可以为聊天类、跑酷类游戏、办公类等等,好评度可以为针对于物品的打分、评论等。In a possible implementation, the item attribute may be at least one of: item name, developer, installation package size, category, and favorable rating, wherein, taking the item as an application program, the category of the item may be chat , parkour games, office games, etc., the favorable ratings can be ratings, comments, etc. for the items.
本申请实施例中,针对于具有相似物品属性的物品进行操作的用户可以认为具有相似的喜好,例如相似物品属性的物品可以为物品名称一致或相似的物品、品类相同或类似的物品、好评度相同或相似的物品,此外,还可以通过权重值来表征物品的物品属性,权重值越相似,则可以表示物品之间的物品属性越相似,此外,还可以通过特征向量来表征物品的物品属性,特征向量之间的距离越近,则可以表示物品之间的物品属性越相似。In this embodiment of the application, users who operate on items with similar item attributes can be considered to have similar preferences. For example, items with similar item attributes can be items with the same or similar item names, items with the same or similar categories, and favorable ratings. The same or similar items, in addition, the item attribute of the item can also be represented by the weight value, the more similar the weight value, the more similar the item attribute between the items can be, in addition, the item attribute of the item can also be represented by the feature vector , the closer the distance between the feature vectors, the more similar the item attributes between items can be.
在一种可能的实现中,第一用户对第一物品进行了操作,目标用户对第四物品进行了操作,可以基于所述第一物品和所述第四物品的物品属性的差异度小于阈值,认为目标用户和第一用户为具有相似喜好的用户,因此可以基于第一用户对于其他物品之间的历史操作信息,来生成更多的与目标用户有关的操作信息,特别的,基于历史操作记录中还记载有第一用户针对于第二物品的操作信息,则可以生成目标用户针对于所述第二物品的操作信息。In a possible implementation, the first user operates on the first item, and the target user operates on the fourth item, based on the fact that the difference between the item attributes of the first item and the fourth item is less than a threshold , it is considered that the target user and the first user are users with similar preferences, so more operation information related to the target user can be generated based on the historical operation information of the first user on other items, especially, based on historical operation The record also records the operation information of the first user on the second item, so the operation information of the target user on the second item can be generated.
其中,为了保证生成的操作信息的准确性,可以将目标用户针对于所述第二物品的操作信息中目标用户针对于第二物品的操作类型设置为与历史操作记录中第一用户针对于第二物品的操作类型一致(也就是第二操作类型和第三操作类型相同)。Wherein, in order to ensure the accuracy of the generated operation information, the target user's operation type for the second item in the target user's operation information for the second item can be set to be the same as the first user's operation for the second item in the historical operation record. The operation types of the two items are the same (that is, the second operation type is the same as the third operation type).
示例性的,例如操作信息包括<目标用户,收藏操作,第一物品>、<第一用户,浏览操作,第四物品>、<第一用户,购买操作,第二物品>,则基于第一物品和第四物品之间的物品属性差异小于阈值,可以生成<目标用户,购买操作,第二物品>的操作信息。Exemplarily, for example, if the operation information includes <target user, collection operation, first item>, <first user, browsing operation, fourth item>, <first user, purchase operation, second item>, then based on the first The item attribute difference between the item and the fourth item is smaller than the threshold, and the operation information of <target user, purchase operation, second item> can be generated.
本申请实施例中,基于针对于具有相似物品属性的物品进行操作的用户(目标用户和第一用户),通过第一用户的其他操作信息,生成与目标用户有关的新的操作信息,在有限的历史操作数据中发掘了更丰富的信息,提高了历史操作记录的数据利用率。In the embodiment of the present application, based on users who operate on items with similar item attributes (the target user and the first user), new operation information related to the target user is generated through other operation information of the first user. More abundant information has been discovered in the historical operation data, which improves the data utilization rate of historical operation records.
通过上述方式,对历史操作记录中的高阶节点关系进行了挖掘,生成了更多的操作信息,且上述数据挖掘方式可以同时使用,以实现对数据的最大化程度的挖掘,接下来结合一个示例描述上述过程:Through the above methods, the high-order node relationships in the historical operation records are mined, and more operation information is generated, and the above data mining methods can be used at the same time to achieve the maximum degree of data mining. Next, combine a An example describing the above process:
可以获取到如下历史操作记录:以<用户,操作类型,物品>三元组表示多行为三元异质图网络,则上述历史操作记录可以简化表示为:<用户1,购买,物品1>、<用户1,收藏,物品2>、<用户1,收藏,物品3>、<用户2,收藏,物品2>、<用户2,点击,物品3>、<用户3,点击,物品3>。The following historical operation records can be obtained: Using <user, operation type, item> triplet to represent a multi-behavior triplet heterogeneous graph network, the above historical operation records can be simplified as: <
由于物品2被用户2收藏,且被用户1收藏,进而可以生成针对于用户2的新的操作信息:<用户2,购买,物品1>,以此类推可获得操作信息:<用户3,购买,物品1>。Since
此外,用户的用户属性信息可以为:结合上述用户的操作信息,通过图网络协同过滤推断可以获得以下多阶三元数据:以<用户4,购买,物品1>表示,以此类推可获得<用户5,购买,物品1>数据。此外,物品的物品属性可以为:物品名字、品类、标签、打分、评论等,如相同处理也可得到以<用户1,购买,物品4>表示。In addition, the user attribute information of the user can be: Combined with the above user's operation information, the following multi-order ternary data can be obtained through graph network collaborative filtering inference: It is represented by <user 4, purchase,
通过以上数据挖掘过程,将原本仅包含6个三元的操作信息拓展为10个。Through the above data mining process, the operating information that originally only contained 6 triples was expanded to 10.
402、根据所述第一操作信息集进行特征提取确定目标用户特征向量。402. Perform feature extraction according to the first operation information set to determine a target user feature vector.
在得到上述目标用户的第一操作信息集之后,可以根据所述第一操作信息集进行特征提取确定目标用户特征向量。After obtaining the above-mentioned first operation information set of the target user, feature extraction may be performed according to the first operation information set to determine the target user feature vector.
接下来描述如何根据所述第一操作信息集进行特征提取确定目标用户特征向量:Next, describe how to perform feature extraction according to the first operation information set to determine the target user feature vector:
在一种可能的实现中,第一操作信息集可以包括多组存在对应关系的物品和操作类型,可以对每组存在对应关系的物品和操作类型计算得到一个子用户特征向量,之后将计算得到的多个子用户特征向量进行融合得到目标用户特征向量。其中,每个子用户特征向量为对存在对应关系的物品的属性信息和操作类型进行特征提取得到的。In a possible implementation, the first operation information set may include multiple sets of corresponding items and operation types, and a sub-user feature vector may be calculated for each set of corresponding items and operation types, and then calculated to obtain Multiple sub-user feature vectors are fused to obtain the target user feature vector. Wherein, each sub-user feature vector is obtained by feature extraction of the attribute information and operation type of the corresponding items.
在一种可能的实现中,所述第一操作信息集包括:第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;进而可以基于第一物品的属性信息与第一操作类型来计算得到一个子用户特征向量。In a possible implementation, the first operation information set includes: the attribute information of the first item, the first operation type, and the correspondence between the first item and the first operation type; The attribute information of an item and the first operation type are used to calculate a sub-user feature vector.
其中,第一物品的属性信息可以表示为嵌入向量embedding(例如以表示物品的属性信息,l可以等于1),第一操作类型可以表示为嵌入向量(例如以表示操作类型),子用户特征向量可以通过第一物品的属性信息与第一操作类型之间的相似度来表示。Among them, the attribute information of the first item can be expressed as an embedding vector embedding (for example, with Represents the attribute information of the item, l can be equal to 1), the first operation type can be expressed as an embedding vector (for example, with represents the operation type), and the sub-user feature vector can be represented by the similarity between the attribute information of the first item and the first operation type.
参照图8和图9,例如可以通过如下方式计算子用户特征向量:Referring to Fig. 8 and Fig. 9, for example, the sub-user feature vector can be calculated in the following manner:
其中,σ(x)为激活函数,例如激活函数可以为sigmoid函数。指的是与目标用户存在关联关系的操作类型和物品的集合。W(l)是第l层的神经元权重,定义为两个向量之间元素按位点乘操作。Wherein, σ(x) is an activation function, for example, the activation function may be a sigmoid function. Refers to a collection of operation types and items that are associated with the target user. W(l) is the neuron weight of layer l, Defined as an element-wise point multiplication operation between two vectors.
在一种可能的实现中,所述第一操作信息集包括:第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;进而可以基于第二物品的属性信息与第二操作类型来计算得到一个子用户特征向量。In a possible implementation, the first operation information set includes: the attribute information of the second item, the second operation type, and the correspondence between the second item and the second operation type; The attribute information of the second item and the second operation type are used to calculate a sub-user feature vector.
其中,第二物品的信息可以表示为嵌入向量(例如以表示第二物品的信息,l可以等于2),第二操作类型可以表示为嵌入向量(例如以表示第二操作类型),第二特征向量可以通过第二物品的信息与第二操作类型之间的相似度来表示,参照图10,例如可以通过如下方式计算第二用户的第二特征向量:Among them, the information of the second item can be expressed as an embedding vector (for example, with Represents the information of the second item, l can be equal to 2), the second operation type can be expressed as an embedding vector (for example, with Represents the second operation type), the second feature vector can be represented by the similarity between the information of the second item and the second operation type, referring to Figure 10, for example, the second feature vector of the second user can be calculated as follows:
其中,σ(x)为激活函数,例如激活函数可以为sigmoid函数。指的是与目标用户存在关联关系的操作类型和物品的集合。W(l)是第l层的神经元权重,定义为两个向量之间元素按位点乘操作。Wherein, σ(x) is an activation function, for example, the activation function may be a sigmoid function. Refers to a collection of operation types and items that are associated with the target user. W(l) is the neuron weight of layer l, Defined as an element-wise point multiplication operation between two vectors.
通过上述方式,可以得到多个子用户特征向量,其中一部分子用户特征向量可以认为是目标用户的一阶特征向量(基于真实的操作信息,例如第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系),一部分子用户特征向量可以认为是目标用户的二阶特征向量(基于预测的操作信息,例如第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系),类似的,还可以得到目标用户更高阶的特征向量。Through the above method, multiple sub-user feature vectors can be obtained, and some of the sub-user feature vectors can be considered as the first-order feature vectors of the target user (based on real operation information, such as the attribute information of the first item, the first operation type, and all The corresponding relationship between the first item and the first operation type), a part of the sub-user feature vector can be considered as the second-order feature vector of the target user (based on the predicted operation information, such as the attribute information of the second item, the second operation type , and the correspondence between the second item and the second operation type), similarly, a higher-order feature vector of the target user can also be obtained.
在一种可能的实现中,各个子用户特征向量都可以表征目标用户的喜好特征,因此可以将多个子用户特征向量进行融合,针对于同一阶的子用户特征向量,可以采用激活函数来进行融合,例如上述公式中的σ(x),针对于同一阶的子用户特征向量融合可以得到的一个特征向量结果,针对于多个阶的子用户特征向量可以得到多个特征向量结果,进而可以对多个特征向量结果进行融合,得到目标用户特征向量,其中,融合可以但不限于为加和以及拼接操作(concat)。In a possible implementation, each sub-user feature vector can represent the preferences of the target user, so multiple sub-user feature vectors can be fused, and for the sub-user feature vectors of the same order, an activation function can be used for fusion , such as σ(x) in the above formula, one eigenvector result can be obtained for the sub-user eigenvector fusion of the same order, and multiple eigenvector results can be obtained for sub-user eigenvectors of multiple orders, and then can be used for Multiple feature vector results are fused to obtain the target user feature vector, where the fusion can be but not limited to summation and splicing operations (concat).
在一种可能的实现中,参照图11,由于目标用户针对于第一物品的操作信息为历史操作记录中的数据,也就是真实的数据,是百分百准确的,而目标用户针对于第二物品的操作信息是基于历史操作记录中的其他数据推测出来的,不是百分百准确的,因此,在进行融合时,可以将所述目标用户针对于第一物品的操作信息所占的权重设置为大于所述目标用户针对于所述第二物品的操作信息所占的权重,进而融合后的操作信息所表征的目标用户的喜好特征会更加的准确。In a possible implementation, referring to Figure 11, since the operation information of the target user for the first item is the data in the historical operation record, that is, the real data, it is 100% accurate, and the target user for the first item The operation information of the second item is estimated based on other data in the historical operation records, which is not 100% accurate. Therefore, when performing fusion, the weight of the target user’s operation information on the first item can be used It is set to be greater than the weight of the target user's operation information on the second item, so that the target user's preferences represented by the fused operation information will be more accurate.
在一种可能的实现中,参照图12,可以将多个子用户特征向量进行融合,示例性的,可以参照如下公式进行特征向量的融合:In a possible implementation, referring to FIG. 12 , multiple sub-user feature vectors can be fused. For example, the feature vectors can be fused with reference to the following formula:
其中,L表示特征向量的阶数。Among them, L represents the order of the feature vector.
在一种可能的实现中,参照图13,还可以将目标用户的初始化嵌入向量作为融合操作的对象。In a possible implementation, referring to FIG. 13 , the initialization embedding vector of the target user may also be used as the object of the fusion operation.
在一种可能的实现中,还可以将目标用户的更高阶(大于2阶)的特征向量作为融合操作的对象。In a possible implementation, a higher-order (greater than 2-order) feature vector of the target user may also be used as an object of the fusion operation.
在一种可能的实现中,可以获取第一操作信息子集和第二操作信息子集;其中,所述第一操作信息子集中包括,第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;所述第一操作类型为所述目标用户对所述第一物品的真实操作类型;所述第二操作信息子集包括,第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;所述第二操作类型为所述目标用户对所述第二物品的预测操作类型;所述根据所述第一操作信息集确定多个子用户特征向量,包括:根据所述第一操作信息子集确定第一子用户特征向量;根据所述第二操作信息子集确定第二子用户特征向量。In a possible implementation, the first operation information subset and the second operation information subset may be acquired; wherein, the first operation information subset includes attribute information of the first item, the first operation type, and the The corresponding relationship between the first item and the first operation type; the first operation type is the actual operation type of the target user on the first item; the second operation information subset includes the second item The attribute information of the second operation type, and the corresponding relationship between the second item and the second operation type; the second operation type is the predicted operation type of the target user on the second item; the Determining a plurality of sub-user feature vectors according to the first operation information set includes: determining a first sub-user feature vector according to the first operation information subset; determining a second sub-user feature vector according to the second operation information subset .
也就是说,上述第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系是基于目标用户的真实操作记录中得到的。That is to say, the attribute information of the first item, the first operation type, and the correspondence between the first item and the first operation type are obtained based on the real operation records of the target user.
由于能够获取到的与用户相关的历史操作记录有限,为了提高信息推荐的精准度,可以在有限的历史操作数据中发掘更丰富的信息,进而生成更多的与用户相关的操作信息,进而可以提高历史操作记录的数据利用率。Due to the limited historical operation records that can be obtained related to users, in order to improve the accuracy of information recommendation, more abundant information can be discovered in the limited historical operation data, and then more user-related operation information can be generated, which can further improve the accuracy of information recommendation. Improve the data utilization rate of historical operation records.
在一种可能的实现中,可以根据所述第一子用户特征向量的第一权重以及所述第二子用户特征向量的第二权重,对所述第一子用户特征向量和所述第二子用户特征向量进行融合。In a possible implementation, according to the first weight of the first sub-user feature vector and the second weight of the second sub-user feature vector, the first sub-user feature vector and the second Sub-user feature vectors are fused.
本申请实施例可以基于不同的权重进行子用户特征向量的融合,针对于用户的真实操作数据得到的子用户特征向量(例如上述第一子用户特征向量),由于可以更准确的刻画目标用户的特征,则可以将权重设置的较大,针对于用户的预测操作数据得到的子用户特征向量(例如上述第二子用户特征向量),由于可以不一定可以准确的刻画目标用户的特征,则可以将权重设置的较小,此外,用户的预测操作数据得到的子用户特征向量,针对于预测的阶数(例如基于5个用户之间的喜好程度相似性得到的预测操作数据,相比仅基于2个用户之间的喜好程度相似性得到的预测操作数据的阶数更高)不同,也可以设置不同的权重,阶数越高,则权重越小;此外,上述阶数还可以在训练目标推荐模型时作为前馈流程的一部分来调节各个阶数的子用户特征向量在融合时的占比,且在训练时不断被更新,当目标推荐模型收敛后,可以得到针对于不同阶数的权重,该权重能够调节各个阶数的子用户特征向量在融合时的占比,以得到一个能够准确刻画用户喜好特征的目标用户特征向量。In the embodiment of the present application, the sub-user feature vectors can be fused based on different weights. The sub-user feature vectors (such as the above-mentioned first sub-user feature vectors) obtained from the user's real operation data can more accurately describe the target user. feature, the weight can be set larger, and the sub-user feature vector (such as the above-mentioned second sub-user feature vector) obtained from the user's predicted operation data may not be able to accurately describe the characteristics of the target user, then it can be Set the weight to be smaller. In addition, the sub-user feature vector obtained from the user's predicted operation data is aimed at the order of prediction (for example, the predicted operation data obtained based on the similarity of preferences between 5 users is compared with only based on The order of the predicted operation data obtained by the similarity of preferences between two users is higher), and different weights can also be set. The higher the order, the smaller the weight; in addition, the above order can also be used in the training target When recommending a model, it is used as a part of the feed-forward process to adjust the proportion of sub-user feature vectors of each order during fusion, and it is continuously updated during training. When the target recommendation model converges, weights for different orders can be obtained , the weight can adjust the proportion of the sub-user feature vectors of each order in the fusion, so as to obtain a target user feature vector that can accurately describe the characteristics of user preferences.
403、获取目标物品的第二操作信息集,所述第二操作信息集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型。403. Acquire a second operation information set of the target item, where the second operation information set includes attribute information of multiple users, the multiple operation types, and the correspondence between the multiple users and the multiple operation types , the corresponding relationship is used to represent the operation types of the operations performed by the multiple users on the target item.
和第一操作信息集不同的是,第二操作信息集中包括的是与目标物品有关的存在对应关系的所述多个用户和所述多个操作类型。Different from the first operation information set, the second operation information set includes the multiple users and the multiple operation types that have a corresponding relationship with the target item.
在一种可能的实现中,第二操作信息集可以包括四操作信息子集,所述第四操作信息子集中可以包括,第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系;其中,所述第五操作类型为所述第三用户对所述目标物品的预测操作类型。In a possible implementation, the second operation information set may include four operation information subsets, and the fourth operation information subset may include the third user's attribute information, the fifth operation type, and the third user's Corresponding relationship with the fifth operation type; wherein, the fifth operation type is a predicted operation type of the third user on the target item.
在一种可能的实现中,可以获取第四用户对所述目标物品的第六操作类型,所述第四用户和所述第三用户的物品喜好特征满足预设条件的用户;基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型。In a possible implementation, the fourth user's sixth operation type on the target item may be obtained, and the item preference characteristics of the fourth user and the third user satisfy a preset condition; based on the first 4. Obtain the fifth operation type according to the sixth operation type of the target item by the user.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第四用户和所述第三用户均为对所述第一物品有操作的用户;Both the fourth user and the third user are users who operate on the first item;
所述第四用户和所述第三用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the fourth user and the third user is less than a threshold; and
所述第四用户和所述第三用户为对物品属性差异小于阈值的物品有操作的用户。The fourth user and the third user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型,具体为,按照所述第六操作类型获取所述第五操作类型,例如所述第五操作类型与所述第六操作类型相同。In a possible implementation, the acquiring the fifth operation type based on the sixth operation type of the fourth user on the target item is specifically, acquiring the fifth operation type according to the sixth operation type. An operation type, for example, the fifth operation type is the same as the sixth operation type.
关于操作信息的扩展策略可以参照上述实施例中步骤401的描述,相似之处不再赘述。Regarding the expansion strategy of the operation information, reference may be made to the description of
404、根据所述第二操作信息集进行特征提取确定目标物品特征向量。404. Perform feature extraction according to the second operation information set to determine a target item feature vector.
在一种可能的实现中,可以基于存在对应关系的用户的属性信息和操作类型进行特征提取得到一个子物品特征向量,其中,子物品特征向量可以表征目标物品针对于用户的吸引力特征,进而可以得到多个子物品特征向量,并对所述多个子物品特征向量进行融合,得到所述目标物品特征向量。In a possible implementation, a sub-item feature vector can be obtained by performing feature extraction based on the corresponding user attribute information and operation type, wherein the sub-item feature vector can represent the attractive feature of the target item for the user, and then Multiple sub-item feature vectors may be obtained, and the multiple sub-item feature vectors are fused to obtain the target item feature vector.
在一种可能的实现中,所述第二操作信息集包括:第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系,则可以根据第二用户的属性信息以及第四正向操作类型得到目标物品的子物品特征向量,其中,第二用户的属性信息可以表示为嵌入向量(例如以表示第二用户的属性信息,l可以等于1),第一操作类型可以表示为嵌入向量(例如以表示第一操作类型),第四特征向量可以通过第二用户的信息与第四操作类型之间的相似度来表示,参照图14,例如可以通过如下方式计算目标物品的子物品特征向量:In a possible implementation, the second operation information set includes: attribute information of the second user, a fourth forward operation type, and a correspondence between the second user and the fourth forward operation type, Then the sub-item feature vector of the target item can be obtained according to the attribute information of the second user and the fourth forward operation type, wherein the attribute information of the second user can be expressed as an embedding vector (for example, in the form of Represents the attribute information of the second user, l can be equal to 1), the first operation type can be expressed as an embedding vector (for example, with Represents the first operation type), the fourth feature vector can be represented by the similarity between the second user's information and the fourth operation type, referring to Figure 14, for example, the sub-item feature vector of the target item can be calculated as follows:
其中,σ(x)为激活函数,例如激活函数可以为sigmoid函数。指的是与目标物品存在关联关系的操作类型和用户的集合。W(l)是第l层的神经元权重,定义为两个向量之间元素按位点乘操作。Wherein, σ(x) is an activation function, for example, the activation function may be a sigmoid function. Refers to the collection of operation types and users that are associated with the target item. W(l) is the neuron weight of layer l, Defined as an element-wise point multiplication operation between two vectors.
在一种可能的实现中,可以基于第二用户针对于第二物品的操作信息来确定目标物品的一个子物品特征向量,其中,子物品特征向量可以用于表征目标物品针对于第二用户的吸引力特征。In a possible implementation, a sub-item feature vector of the target item can be determined based on the operation information of the second user for the second item, wherein the sub-item feature vector can be used to represent the attractive features.
在一种可能的实现中,所述第二操作信息集包括:第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系;其中,所述第五操作类型为所述第三用户对所述目标物品的预测操作行为,可以根据第三用户的属性信息以及第五操作类型得到目标用户的一个子物品特征向量,其中,第一用户的信息可以表示为嵌入向量embedding(例如以表示第一用户的信息,l可以等于2),第五操作类型可以表示为嵌入向量(例如以表示第二操作类型),子物品特征向量可以通过第三用户的信息与第五操作类型之间的相似度来表示,参照图15,例如可以通过如下方式计算目标物品的子物品特征向量:In a possible implementation, the second operation information set includes: attribute information of a third user, a fifth operation type, and a correspondence between the third user and the fifth operation type; wherein, the The fifth operation type is the predicted operation behavior of the third user on the target item, and a sub-item feature vector of the target user can be obtained according to the attribute information of the third user and the fifth operation type, wherein the information of the first user Can be expressed as an embedding vector embedding (for example, with Represent the information of the first user, l can be equal to 2), the fifth operation type can be expressed as an embedding vector (for example with represents the second operation type), the sub-item feature vector can be represented by the similarity between the information of the third user and the fifth operation type, referring to Fig. 15, for example, the sub-item feature vector of the target item can be calculated as follows:
其中,σ(x)为激活函数,例如激活函数可以为sigmoid函数。指的是与目标物品存在关联关系的操作类型和用户的集合。W(l)是第l层的神经元权重,定义为两个向量之间元素按位点乘操作。Wherein, σ(x) is an activation function, for example, the activation function may be a sigmoid function. Refers to the collection of operation types and users that are associated with the target item. W(l) is the neuron weight of layer l, Defined as an element-wise point multiplication operation between two vectors.
参照图16,通过上述方式,可以得到多个子物品特征向量,其中一部分子物品特征向量可以认为是目标物品的一阶特征向量(基于真实的操作信息,例如上述第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系),一部分子物品特征向量可以认为是目标用户的二阶特征向量(基于预测的操作信息,例如上述第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系),类似的,还可以得到目标物品更高阶的特征向量。Referring to Fig. 16, through the above method, a plurality of sub-item feature vectors can be obtained, and some of the sub-item feature vectors can be considered as the first-order feature vectors of the target item (based on real operation information, such as the above-mentioned attribute information of the second user, the fourth Forward operation type, and the corresponding relationship between the second user and the fourth forward operation type), a part of the sub-item feature vectors can be considered as the second-order feature vector of the target user (based on the predicted operation information, such as the above-mentioned first attribute information of the third user, the fifth operation type, and the correspondence between the third user and the fifth operation type), similarly, a higher-order feature vector of the target item can also be obtained.
在一种可能的实现中,各个子物品特征向量都可以表征目标物品对于用户的吸引力特征,因此可以将多个子物品特征向量进行融合,针对于同一阶的子物品特征向量,可以采用激活函数来进行融合,例如上述公式中的σ(x),针对于同一阶的子物品特征向量融合可以得到的一个特征向量结果,针对于多个阶的子物品特征向量可以得到多个特征向量结果,进而可以对多个特征向量结果进行融合,得到目标物品特征向量,其中,融合可以但不限于为加和以及拼接操作(concat)。In a possible implementation, each sub-item feature vector can represent the attractiveness of the target item to the user, so multiple sub-item feature vectors can be fused, and for the sub-item feature vectors of the same order, the activation function can be used For fusion, for example, σ(x) in the above formula, one eigenvector result can be obtained for the sub-item eigenvector fusion of the same order, and multiple eigenvector results can be obtained for the sub-item eigenvectors of multiple orders, Furthermore, multiple feature vector results can be fused to obtain the feature vector of the target item, wherein the fusion can be, but not limited to, addition and splicing operations (concat).
在一种可能的实现中,由于第二用户针对于目标物品的操作信息为历史操作记录中的数据,也就是真实的数据,是百分百准确的,而第三用户针对于目标物品的操作信息是基于历史操作记录中的其他数据推测出来的,不是百分百准确地,因此,在所述融合后的操作信息中,可以将所述第二用户针对于目标物品的操作信息所占的权重设置为大于所述第二用户针对于所述目标物品的操作信息所占的权重,进而融合后的操作信息所表征的目标物品针对于的用户的吸引力特征会更加的准确。In a possible implementation, since the second user's operation information on the target item is the data in the historical operation record, that is, the real data, it is 100% accurate, and the third user's operation on the target item The information is inferred based on other data in the historical operation records, and it is not 100% accurate. Therefore, in the fused operation information, the operation information of the second user on the target item can be accounted for The weight is set to be greater than the weight of the second user's operation information on the target item, so that the attractive features of the target item for the user represented by the fused operation information will be more accurate.
在一种可能的实现中,参照图17,可以将多个子物品特征向量进行融合,示例性的,可以参照如下公式进行特征向量的融合:In a possible implementation, referring to FIG. 17 , multiple sub-item feature vectors can be fused. For example, the following formula can be used to fuse the feature vectors:
其中,L表示特征向量的阶数。Among them, L represents the order of the feature vector.
在一种可能的实现中,参照图18,还可以将目标物品的初始化嵌入向量作为融合操作的对象。In a possible implementation, referring to FIG. 18 , the initialization embedding vector of the target item may also be used as the object of the fusion operation.
在一种可能的实现中,还可以将目标物品的更高阶(大于2阶)的特征向量作为融合操作的对象。In a possible implementation, a higher-order (greater than 2-order) feature vector of the target item may also be used as an object of the fusion operation.
在一种可能的实现中,可以获取所述多个操作类型中每个操作类型的操作类型特征向量;其中每个操作类型特征向量可以在训练目标推荐模型时得到。In a possible implementation, an operation type feature vector of each operation type among the plurality of operation types may be obtained; wherein each operation type feature vector may be obtained when training a target recommendation model.
在一种实现中,不同阶的操作信息中操作类型都可以得到一个对应的操作类型子特征向量,可以将多个操作类型子特征向量进行融合来得到多个操作类型中每个操作类型的操作类型特征向量。In one implementation, a corresponding operation type sub-feature vector can be obtained for the operation types in the operation information of different orders, and multiple operation type sub-feature vectors can be fused to obtain the operation of each operation type in the multiple operation types type character vector.
例如可以通过全连接网络处理前一阶操作信息中的操作类型的操作类型特征向量,以得到相邻后一阶操作信息中的操作类型的操作类型特征向量,例如可以通过以下公式进行计算:For example, the operation type feature vector of the operation type in the previous order operation information can be processed through the fully connected network to obtain the operation type feature vector of the operation type in the adjacent subsequent order operation information, for example, it can be calculated by the following formula:
其中,是神经元权重,为前一阶操作信息中的操作类型的操作类型特征向量,为相邻后一阶操作信息中的操作类型的操作类型特征向量。in, is the neuron weight, is the operation type feature vector of the operation type in the previous operation information, is the operation type feature vector of the operation type in the adjacent next-order operation information.
在一种可能的实现中,可以将与进行融合,以得到操作类型特征向量。In one possible implementation, the and Fusion is performed to obtain the operation type feature vector.
示例性的,可以参照如下公式进行特征向量的融合:Exemplarily, the fusion of feature vectors can be performed with reference to the following formula:
其中,L表示特征向量的阶数。Among them, L represents the order of the feature vector.
405、根据所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,所述推荐信息用于表示所述目标用户对所述目标物品进行所述多个操作类型的操作的概率。405. Output recommendation information based on the target recommendation model according to the target user feature vector and the target item feature vector, where the recommendation information is used to indicate the multiple operation types performed by the target user on the target item Probability of action.
通过上述方式,可以得到目标用户的目标用户目标用户特征向量、目标物品的目标物品特征向量以及多个操作类型的多个操作类型特征向量,进而可以根据所述多个操作类型的多个操作类型特征向量,所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,具体的,可以基于所述目标用户特征向量、所述目标物品特征向量以及多个操作类型特征向量中每个操作类型特征向量三者之间的相似度,来确定目标用户对目标物品进行各个操作类型的操作的概率。Through the above method, the target user target user feature vector of the target user, the target item feature vector of the target item, and multiple operation type feature vectors of multiple operation types can be obtained, and then according to the multiple operation types of the multiple operation types The feature vector, the target user feature vector and the target item feature vector, output recommendation information based on the target recommendation model, specifically, it can be based on the target user feature vector, the target item feature vector and multiple operation type features The similarity among the three characteristic vectors of each operation type in the vector is used to determine the probability that the target user performs operations of each operation type on the target item.
示例性的,用户u对物品v进行操作类型k的操作的预测概率可以基于如下方式计算:Exemplarily, the predicted probability of user u performing operation type k on item v can be calculated based on the following method:
其中,d为模型参数,是隐向量的长度,例如可以为128。Among them, d is a model parameter, which is the length of the hidden vector, for example, it can be 128.
示例性的,参照图19a,图19a示出了一种信息推荐方法的流程示意,在一种可能的实现中,可以首先计算目标用户的目标用户特征向量与目标物品的特征向量之间的相似度,然后再计算第二用户的特征向量、目标物品的目标物品特征向量以及操作类型的操作类型特征向量三者之间的相似度。Exemplarily, referring to FIG. 19a, FIG. 19a shows a schematic flowchart of an information recommendation method. In a possible implementation, the similarity between the target user feature vector of the target user and the feature vector of the target item can be calculated first. degree, and then calculate the similarity between the feature vector of the second user, the target item feature vector of the target item, and the operation type feature vector of the operation type.
406、当推荐信息满足预设条件,确定向所述目标用户推荐所述目标物品。406. When the recommendation information satisfies the preset condition, determine to recommend the target item to the target user.
通过上述方式,可以得到目标用户进行针对于目标物品的多个操作类型对应的操作的概率,并基于上述概率进行信息推荐,具体的,当推荐信息满足预设条件,可以确定向所述目标用户推荐所述目标物品。Through the above method, the probability that the target user performs operations corresponding to multiple operation types for the target item can be obtained, and information recommendation can be performed based on the above probability. The target item is recommended.
接下来描述预设条件:The preconditions are described next:
在一种可能的实现中,在对目标用户进行信息推荐时,可以计算得到目标用户对多个物品(包括目标物品)进行多个操作类型的概率,并基于多个操作类型的概率来确定各个物品的对于该目标用户的推荐指数。In a possible implementation, when recommending information to a target user, the probability that the target user performs multiple types of operations on multiple items (including the target item) can be calculated, and each operation type is determined based on the probabilities of multiple operation types. The item's recommendation index for the target user.
在一种可能的实现中,可以选择目标用户对各个物品的多个操作类型的概率中的最大概率来表征各个物品对目标用户的推荐指数;In a possible implementation, the maximum probability among the probabilities of multiple operation types performed by the target user on each item can be selected to represent the recommendation index of each item to the target user;
在一种可能的实现中,可以计算目标用户对各个物品的多个操作类型的概率的综合值来表征各个物品对目标用户的推荐指数,综合值可以是基于加权求和的方式,具体可以对各个操作类型设置对应的权重,例如购买操作的权重大于加入购物车操作的权重,之后可以结合各个操作类型对应的权重以及各个操作类型对应的概率基于加权求和来得到各个操作类型的推荐指数;In a possible implementation, the comprehensive value of the probabilities of multiple operation types performed by the target user on each item can be calculated to represent the recommendation index of each item to the target user. The comprehensive value can be based on a weighted summation method. Specifically, Set the corresponding weight for each operation type, for example, the weight of the purchase operation is greater than the weight of the add to shopping cart operation, and then you can combine the weights corresponding to each operation type and the probability corresponding to each operation type to obtain the recommendation index of each operation type based on weighted summation;
在得到各个物品的对于该目标用户的推荐指数之后,可以对推荐指数进行排序,并向目标用户推荐推荐指数最大的M个物品(包括目标物品)。After obtaining the recommendation index of each item for the target user, the recommendation index can be sorted, and M items (including the target item) with the highest recommendation index can be recommended to the target user.
在一种可能的实现中,还可以选择可以设置一个概率阈值,当目标用户对目标物品的多种操作类型的概率中有至少一个操作类型对应的概率大于上述概率阈值,就可以向所述目标用户推荐所述目标物品。In a possible implementation, you can also choose to set a probability threshold. When the target user has a probability corresponding to at least one operation type among the multiple operation types of the target item that is greater than the above probability threshold, you can send a message to the target. The user recommends the target item.
在进行信息推荐时,可以以列表页的形式将推荐信息推荐给用户,以期望用户进行行为动作。When recommending information, the recommended information can be recommended to the user in the form of a list page, so as to expect the user to take a behavioral action.
接下来结合试验描述本申请实施例的有益效果,本申请实施例提供的信息推荐方法与现有的几种业内成熟的技术(BPR,NCF,LightGCN,CMF,MC-BPR,NMTR和EHCF)的对比如下。通过使用一个公开的电商数据集,该数据集的统计数据如下:用户数:48749;物品数:39493;浏览行为数:1548126;加入购物车数:193747;购买数:259747。将用户的最后一个购买记录作为测试样例除外,其他数据作为训练集训练该方法。本发明通过选取业界公认的HR(hit rate)和NDCG作为评价指标进行对比试验。Next, describe the beneficial effects of the embodiments of the present application in conjunction with experiments. The information recommendation method provided by the embodiments of the present application is compatible with several existing mature technologies in the industry (BPR, NCF, LightGCN, CMF, MC-BPR, NMTR and EHCF) The comparison is as follows. By using a public e-commerce data set, the statistical data of the data set are as follows: number of users: 48749; number of items: 39493; number of browsing behaviors: 1548126; number of added shopping carts: 193747; number of purchases: 259747. Except for the user's last purchase record as a test sample, other data are used as a training set to train the method. The present invention selects industry-recognized HR (hit rate) and NDCG as evaluation indexes to carry out comparative experiments.
表1:与现有推荐模型在公开数据集的对比效果Table 1: Comparison with existing recommendation models in public datasets
根据表1结果所示,可以得到以下几个结论:首先,考虑用户的多种操作类型比只使用一种操作类型的结果更好,且考虑节点之间的高阶关系可以提升推荐算法的准确性。According to the results shown in Table 1, the following conclusions can be drawn: First, considering multiple types of user operations is better than using only one type of operation, and considering the high-order relationship between nodes can improve the accuracy of the recommendation algorithm sex.
本申请实施例提供了一种推荐方法,所述方法包括:获取目标用户的第一操作信息集,所述第一操作信息集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标用户对所述多个物品进行的操作的操作类型;根据所述第一操作信息集进行特征提取确定目标用户特征向量;获取目标物品的第二操作信息集,所述第二操作信息集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;根据所述第二操作信息集进行特征提取确定目标物品特征向量;根据所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,所述推荐信息用于表示所述目标用户对所述目标物品进行所述多个操作类型的操作的概率;当推荐信息满足预设条件,确定向所述目标用户推荐所述目标物品。通过上述方式,基于存在关联关系的物品和操作类型来生成表征目标用户喜好的目标用户特征向量,以及基于存在关联关系的用户和操作类型来生成表征目标物品对用户的吸引力特征的目标物品特征向量,来预测目标用户对目标物品的进行多个操作类型的操作的概率,可以更准确的刻画出用户针对于物品的操作概率。An embodiment of the present application provides a recommendation method, the method includes: acquiring a first operation information set of a target user, the first operation information set includes attribute information of multiple items, multiple operation types, and the multiple The corresponding relationship between an item and the multiple operation types, the corresponding relationship is used to represent the operation type of the operation performed by the target user on the multiple items; perform feature extraction according to the first operation information set to determine the target User feature vector; acquire the second operation information set of the target item, the second operation information set includes attribute information of multiple users, the multiple operation types, and the multiple users and the multiple operation types A corresponding relationship, the corresponding relationship is used to represent the operation type of the operation performed by the multiple users on the target item; perform feature extraction according to the second operation information set to determine the target item feature vector; according to the target user feature vector and The target item feature vector outputs recommendation information based on the target recommendation model, and the recommendation information is used to represent the probability that the target user performs operations of the multiple operation types on the target item; when the recommendation information satisfies the preset condition, determine to recommend the target item to the target user. Through the above method, the target user feature vector representing the preferences of the target user is generated based on the associated items and the operation type, and the target item feature representing the attractiveness of the target item to the user is generated based on the associated user and the operation type Vector, to predict the probability of the target user performing multiple types of operations on the target item, which can more accurately describe the user's operation probability for the item.
参照图19b,图有19b为本申请实施例提供的一种训练样本构建测方法的示意,其中,所述方法包括:Referring to Fig. 19b, Fig. 19b is a schematic diagram of a training sample construction test method provided by the embodiment of the present application, wherein the method includes:
1901:获取第一用户对第一物品的第一操作类型,且所述第一用户和目标用户的物品喜好特征满足预设条件。1901: Obtain a first operation type of a first user on a first item, and the item preference characteristics of the first user and the target user meet a preset condition.
其中,第一用户对第一物品的第一操作类型可以为第一用户对第一物品的真实操作类型。Wherein, the first operation type of the first user on the first item may be an actual operation type of the first user on the first item.
通过上述方式,对历史操作记录中的高阶节点关系进行了挖掘,生成了更多的操作信息,且上述数据挖掘方式可以同时使用,以实现对数据的最大化程度的挖掘,接下来结合一个示例描述上述过程:Through the above methods, the high-order node relationships in the historical operation records are mined, and more operation information is generated, and the above data mining methods can be used at the same time to achieve the maximum degree of data mining. Next, combine a An example describing the above process:
可以获取到如下历史操作记录:以<用户,操作类型,物品>三元组表示多行为三元异质图网络,则上述历史操作记录可以简化表示为:<用户1,购买,物品1>、<用户1,收藏,物品2>、<用户1,收藏,物品3>、<用户2,收藏,物品2>、<用户2,点击,物品3>、<用户3,点击,物品3>。The following historical operation records can be obtained: Using <user, operation type, item> triplet to represent a multi-behavior triplet heterogeneous graph network, the above historical operation records can be simplified as: <
由于物品2被用户2收藏,且被用户1收藏,进而可以生成针对于用户2的新的操作信息:<用户2,购买,物品1>,以此类推可获得操作信息:<用户3,购买,物品1>。Since
此外,用户的用户属性信息可以为:结合上述用户的操作信息,通过图网络协同过滤推断可以获得以下多阶三元数据:以<用户4,购买,物品1>表示,以此类推可获得<用户5,购买,物品1>数据。此外,物品的物品属性可以为:物品名字、品类、标签、打分、评论等,如相同处理也可得到以<用户1,购买,物品4>表示。In addition, the user attribute information of the user can be: Combined with the above user's operation information, the following multi-order ternary data can be obtained through graph network collaborative filtering inference: It is represented by <user 4, purchase,
通过以上数据挖掘过程,将原本仅包含6个三元的操作信息拓展为10个。Through the above data mining process, the operating information that originally only contained 6 triples was expanded to 10.
更多关于步骤1901的描述,可以参照上述实施例中关于数据扩展策略的描述,这里不再赘述。For more description of
1902、基于所述第一用户针对于所述第一物品的所述第一操作类型,生成所述目标用户对所述第一物品的第二操作类型;所述第二操作类型为所述目标用户针对所述第一物品的预测操作行为。1902. Based on the first operation type of the first user on the first item, generate a second operation type of the target user on the first item; the second operation type is the target A predicted operation behavior of the user on the first item.
更对关于步骤1902的描述,可以参照上述实施例中关于数据扩展策略的描述,这里不再赘述。For the description of
1903、根据所述目标用户的属性信息、所述第一物品的属性信息以及所述第二操作类型,构建训练样本。1903. Construct a training sample according to the attribute information of the target user, the attribute information of the first item, and the second operation type.
本申请可以在有限的历史操作数据中发掘更丰富的信息,进而生成更多的与用户相关的操作信息,进而可以提高历史操作记录的数据利用率,构建更多的训练样本,基于上述训练样本训练的推荐模型可以更加准确的预测用户的行为。This application can explore more abundant information in the limited historical operation data, and then generate more user-related operation information, thereby improving the data utilization rate of historical operation records and constructing more training samples. Based on the above training samples The trained recommendation model can predict user behavior more accurately.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对第二物品有操作的用户;Both the first user and the target user are users who operate on the second item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述用户属性包括如下的至少一种:In a possible implementation, the user attributes include at least one of the following:
性别,年龄,职业,收入,爱好,教育程度。Gender, age, occupation, income, hobbies, education level.
在一种可能的实现中,所述物品属性包括如下的至少一种:In a possible implementation, the item attributes include at least one of the following:
物品名称,开发者,安装包大小,品类,好评度。Item name, developer, installation package size, category, praise rating.
在一种可能的实现中,所述第一操作类型与所述第二操作类型相同。In a possible implementation, the first operation type is the same as the second operation type.
在一种可能的实现中,所述第一操作类型和所述第二操作类型包括如下的至少一种:In a possible implementation, the first operation type and the second operation type include at least one of the following:
浏览操作,加入购物车操作以及购买操作。Browse actions, add to cart actions, and buy actions.
在一种可能的实现中,上述得到的操作信息可以用于进行目标推荐模型的训练,具体的,可以获取所述目标用户的属性信息,所述第一物品的属性信息;根据所述目标用户的属性信息确定目标用户特征向量;根据所述第一物品的属性信息确定目标物品特征向量;获取所述第二操作类型的第三特征向量;并根据所述目标用户特征向量,所述目标物品特征向量以及所述第三特征向量,训练目标推荐模型,以得到训练后的目标推荐模型。关于如何根据所述目标用户的属性信息确定目标用户特征向量;根据所述第一物品的属性信息确定目标物品特征向量;获取所述第二操作类型的第三特征向量可以参照上述实施例中的描述,相似之处这里不再赘述。In a possible implementation, the operation information obtained above can be used to train the target recommendation model, specifically, the attribute information of the target user and the attribute information of the first item can be obtained; according to the target user Determine the target user feature vector according to the attribute information of the first item; determine the target item feature vector according to the attribute information of the first item; obtain the third feature vector of the second operation type; and according to the target user feature vector, the target item The feature vector and the third feature vector are used to train the target recommendation model to obtain the trained target recommendation model. Regarding how to determine the target user feature vector according to the attribute information of the target user; determine the target item feature vector according to the attribute information of the first item; and obtain the third feature vector of the second operation type can refer to the above-mentioned embodiment. Description, the similarities will not be repeated here.
在一种可能的实现中,可以根据所述目标用户特征向量,所述目标物品特征向量以及所述第三特征向量,通过目标推荐模型输出预测概率,所述预测概率用于表示所述目标用户对所述第一物品进行所述第二操作类型的操作的概率,并根据所述概率,确定损失,并根据所述损失更新所述目标推荐模型。In a possible implementation, according to the target user feature vector, the target item feature vector and the third feature vector, the target recommendation model can output a prediction probability, and the prediction probability is used to represent the target user The probability of performing the operation of the second operation type on the first item, and according to the probability, determine a loss, and update the target recommendation model according to the loss.
本申请实施例提供了一种用户操作行为预测方法,所述方法包括:获取第一用户对第一物品的第一操作类型,所述第一用户和目标用户的物品喜好特征满足预设条件;基于所述第一用户针对于所述第一物品的所述第一操作类型,生成所述目标用户对所述第一物品的第二操作类型;所述第二操作类型为所述目标用户针对所述第一物品的预测操作行为。可以在有限的历史操作数据中发掘更丰富的信息,进而生成更多的与用户相关的操作信息,进而可以提高历史操作记录的数据利用率,基于上述信息训练的推荐模型可以更加准确的预测用户的行为。An embodiment of the present application provides a method for predicting user operation behavior, the method comprising: obtaining a first type of operation of a first user on a first item, and the item preference characteristics of the first user and the target user satisfy a preset condition; Based on the first operation type of the first user on the first item, generate a second operation type of the target user on the first item; the second operation type is the target user's operation on the first item A predicted operational behavior of the first item. Richer information can be discovered in the limited historical operation data, and then more user-related operation information can be generated, which can improve the data utilization rate of historical operation records. The recommendation model trained based on the above information can predict users more accurately the behavior of.
参照图20,图20为本申请实施例提供的一种推荐模型训练方法的流程示意,所述方法包括:Referring to FIG. 20, FIG. 20 is a schematic flowchart of a method for training a recommendation model provided by an embodiment of the present application. The method includes:
2001、获取目标样本用户的第一操作信息样本集,所述第一操作信息样本集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标样本用户对所述多个物品进行的操作的操作类型;2001. Obtain a first sample set of operation information of a target sample user, the first sample set of operation information includes attribute information of multiple items, multiple types of operations, and the correspondence between the multiple items and the multiple types of operations relationship, the corresponding relationship is used to represent the type of operation performed by the target sample user on the plurality of items;
关于步骤2001的描述可以参照上述实施例中步骤401的描述,这里不再赘述,For the description of
2002、根据所述第一操作信息样本集进行特征提取确定目标样本用户特征向量;2002. Perform feature extraction according to the first operation information sample set to determine a target sample user feature vector;
关于步骤2002的描述可以参照上述实施例中步骤402的描述,这里不再赘述,For the description of
2003、获取目标样本物品的第二操作信息样本集,所述第二操作信息样本集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;2003. Obtain a second sample set of operation information of the target sample item, the second sample set of operation information includes attribute information of multiple users, the multiple operation types, and the multiple users and the multiple operation types A corresponding relationship, the corresponding relationship is used to represent the type of operation performed by the multiple users on the target item;
关于步骤2003的描述可以参照上述实施例中步骤403的描述,这里不再赘述,For the description of
2004、根据所述第二操作信息样本集进行特征提取确定目标样本物品特征向量;2004. Perform feature extraction according to the second operation information sample set to determine the feature vector of the target sample item;
关于步骤2004的描述可以参照上述实施例中步骤404的描述,这里不再赘述。For the description of
2005、根据所述目标样本用户对所述目标物品的实际操作类型获取样本标签;2005. Obtain a sample label according to the actual operation type of the target sample user on the target item;
2006、以所述目标样本用户特征向量和所述目标样本物品特征向量为输入,所述样本标签为输出,进行模型训练,获取目标推荐模型。2006. Using the target sample user feature vector and the target sample item feature vector as input, and the sample label as output, perform model training to obtain a target recommendation model.
在一种可能的实现中,所述根据所述第一操作信息样本集进行特征提取确定目标样本用户特征向量,包括:In a possible implementation, the performing feature extraction according to the first operation information sample set to determine the target sample user feature vector includes:
根据所述第一操作信息样本集确定多个子样本用户特征向量,其中,每个子样本用户特征向量为对存在对应关系的物品的属性信息和操作类型进行特征提取得到的;A plurality of sub-sample user feature vectors are determined according to the first operation information sample set, wherein each sub-sample user feature vector is obtained by feature extraction of attribute information and operation types of items with corresponding relationships;
对所述多个用户子样本用户特征向量进行融合,得到所述目标样本用户特征向量。The multiple user sub-sample user feature vectors are fused to obtain the target sample user feature vector.
在一种可能的实现中,所述根据所述第二操作信息样本集进行特征提取确定目标样本物品特征向量,包括:In a possible implementation, the performing feature extraction according to the second operation information sample set to determine the feature vector of the target sample item includes:
根据所述第二操作信息样本集确定多个子样本物品特征向量,其中,每个第二子样本物品特征向量为对存在对应关系的用户的属性信息和操作类型进行特征提取得到的;A plurality of sub-sample item feature vectors are determined according to the second operation information sample set, wherein each second sub-sample item feature vector is obtained by feature extraction of user attribute information and operation types that have a corresponding relationship;
对所述多个子样本物品特征向量进行融合,得到所述目标样本物品特征向量。The multiple sub-sample item feature vectors are fused to obtain the target sample item feature vector.
在一种可能的实现中,所述获取所述第一操作信息样本集包括:In a possible implementation, the acquiring the first operation information sample set includes:
获取第一操作信息样本子集和第二操作信息样本子集;其中,Obtain the first subset of operation information samples and the second subset of operation information samples; wherein,
所述第一操作信息样本子集中包括,第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;所述第一操作类型为所述目标用户对所述第一物品的真实操作类型;The first operation information sample subset includes attribute information of a first item, a first operation type, and a correspondence between the first item and the first operation type; the first operation type is the target The actual operation type of the user on the first item;
所述第二操作信息样本子集包括,第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;所述第二操作类型为所述目标用户对所述第二物品的预测操作类型;The second operation information sample subset includes attribute information of a second item, a second operation type, and a correspondence between the second item and the second operation type; the second operation type is the target The user's predicted operation type on the second item;
所述根据所述第一操作信息样本集确定多个子样本用户特征向量,包括:The determining a plurality of sub-sample user feature vectors according to the first operation information sample set includes:
根据所述第一操作信息样本子集确定第一子样本用户特征向量;determining a first subsample user feature vector according to the first subset of operation information samples;
根据所述第二操作信息样本子集确定第二子样本用户特征向量。A second sub-sample user feature vector is determined according to the second subset of operation information samples.
在一种可能的实现中,所述对所述多个用户子样本用户特征向量进行融合,包括:In a possible implementation, the fusing the user feature vectors of the plurality of user sub-samples includes:
根据所述第一子样本用户特征向量的第一权重和所述第二子样本用户特征向量的第二权重,对所述第一子样本用户特征向量和所述第二子样本用户特征向量进行融合。According to the first weight of the first sub-sample user feature vector and the second weight of the second sub-sample user feature vector, the first sub-sample user feature vector and the second sub-sample user feature vector are performed fusion.
在一种可能的实现中,所述获取第二操作信息样本子集包括:In a possible implementation, the acquiring the second subset of operation information samples includes:
获取所述第二操作类型;obtain the second operation type;
所述获取所述第二操作类型,具体为:The acquiring the second operation type is specifically:
获取第一用户对第二物品的第三操作类型,所述第一用户为所述目标用户的物品喜好特征满足预设条件的用户;Obtaining a third operation type of a first user on a second item, the first user being a user whose item preference characteristics of the target user meet a preset condition;
基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型。The second operation type is acquired based on the third operation type of the first user on the second item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对所述第一物品有操作的用户;Both the first user and the target user are users who operate on the first item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型,具体为,按照所述第三操作类型获取所述第二操作类型。In a possible implementation, the acquiring the second operation type based on the third operation type of the first user on the second item is specifically, acquiring according to the third operation type The second operation type.
在一种可能的实现中,所述操作类型为正向操作类型。In a possible implementation, the operation type is a forward operation type.
在一种可能的实现中,所述获取所述第二操作信息样本集包括:In a possible implementation, the acquiring the second operation information sample set includes:
获取第三操作信息样本子集和第四操作信息样本子集;其中,Obtain the third subset of operation information samples and the fourth subset of operation information samples; wherein,
所述第三操作信息样本子集中包括,第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系;所述第四正向操作类型为所述第二用户对所述目标物品的真实操作类型;The third operation information sample subset includes attribute information of the second user, a fourth forward operation type, and a correspondence between the second user and the fourth forward operation type; the fourth forward operation type The operation type is the actual operation type of the second user on the target item;
所述第四操作信息样本子集中包括,第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系;所述第五操作类型为所述第三用户对所述目标物品的预测操作类型;The fourth operation information sample subset includes attribute information of the third user, a fifth operation type, and a corresponding relationship between the third user and the fifth operation type; the fifth operation type is the first 3. The user's predicted operation type on the target item;
所述根据所述第二操作信息样本集确定多个子样本物品特征向量,包括:The determining a plurality of sub-sample item feature vectors according to the second operation information sample set includes:
根据所述第三操作信息样本子集确定第一子样本物品特征向量;determining a first sub-sample item feature vector according to the third subset of operation information samples;
根据所述第四操作信息样本子集确定第二子样本物品特征向量。A second sub-sample feature vector is determined according to the fourth subset of operation information samples.
在一种可能的实现中,所述对所述多个子样本物品特征向量进行融合,包括:In a possible implementation, the fusing the multiple sub-sample item feature vectors includes:
根据所述第一子样本物品特征向量的第三权重以及所述第二子样本物品特征向量的第四权重,对所述第一子样本物品特征向量和所述第二子样本物品特征向量进行融合。According to the third weight of the first sub-sample item feature vector and the fourth weight of the second sub-sample item feature vector, the first sub-sample item feature vector and the second sub-sample item feature vector are performed fusion.
在一种可能的实现中,所述获取第四操作信息子集包括:In a possible implementation, the acquiring the fourth subset of operation information includes:
获取所述第五操作类型;Obtain the fifth operation type;
所述获取所述第五操作类型,具体包括:The acquiring the fifth operation type specifically includes:
获取第四用户对所述目标物品的第六操作类型,所述第四用户和所述第三用户的物品喜好特征满足预设条件的用户;Obtaining a sixth operation type of the fourth user on the target item, and users whose item preference features of the fourth user and the third user meet preset conditions;
基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型。The fifth operation type is acquired based on a sixth operation type performed by the fourth user on the target item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第四用户和所述第三用户均为对所述第一物品有操作的用户;Both the fourth user and the third user are users who operate on the first item;
所述第四用户和所述第三用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the fourth user and the third user is less than a threshold; and
所述第四用户和所述第三用户为对物品属性差异小于阈值的物品有操作的用户。The fourth user and the third user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型,具体为,按照所述第六操作类型获取所述第五操作类型。In a possible implementation, the acquiring the fifth operation type based on the sixth operation type of the fourth user on the target item is specifically, acquiring the fifth operation type according to the sixth operation type. Action type.
本申请实施例提供了一种推荐模型训练方法,所述方法包括:获取目标样本用户的第一操作信息样本集,所述第一操作信息样本集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标样本用户对所述多个物品进行的操作的操作类型;根据所述第一操作信息样本集进行特征提取确定目标样本用户特征向量;获取目标样本物品的第二操作信息样本集,所述第二操作信息样本集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;根据所述第二操作信息样本集进行特征提取确定目标样本物品特征向量;根据所述目标样本用户对所述目标物品的实际操作类型获取样本标签;以所述目标样本用户特征向量和所述目标样本物品特征向量为输入,所述样本标签为输出,进行模型训练,获取目标推荐模型。通过上述方式,基于存在关联关系的物品和操作类型来生成表征目标用户喜好的目标用户特征向量,以及基于存在关联关系的用户和操作类型来生成表征目标物品对用户的吸引力特征的目标物品特征向量,来预测目标用户对目标物品的进行多个操作类型的操作的概率,可以更准确的刻画出用户针对于物品的操作概率。An embodiment of the present application provides a recommendation model training method, the method includes: acquiring a first sample set of operation information of a target sample user, the first sample set of operation information includes attribute information of a plurality of items, and a plurality of operation types , and the corresponding relationship between the multiple items and the multiple operation types, the corresponding relationship is used to represent the operation type of the operation performed by the target sample user on the multiple items; according to the first operation information The sample set performs feature extraction to determine the target sample user feature vector; obtain the second operation information sample set of the target sample item, and the second operation information sample set includes attribute information of multiple users, the multiple operation types, and the The corresponding relationship between multiple users and the multiple operation types, the corresponding relationship is used to represent the operation type of the operation performed by the multiple users on the target item; perform feature extraction according to the second operation information sample set to determine the target Sample item feature vector; obtain sample label according to the actual operation type of the target sample user on the target item; take the target sample user feature vector and the target sample item feature vector as input, and the sample label is output, Perform model training to obtain the target recommendation model. Through the above method, the target user feature vector representing the preferences of the target user is generated based on the associated items and the operation type, and the target item feature representing the attractiveness of the target item to the user is generated based on the associated user and the operation type Vector, to predict the probability of the target user performing multiple types of operations on the target item, which can more accurately describe the user's operation probability for the item.
参照图21,图21为本申请实施例提供的一种推荐装置2100,所述装置包括:Referring to FIG. 21 , FIG. 21 is a
获取模块2101,用于获取目标用户的第一操作信息集,所述第一操作信息集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标用户对所述多个物品进行的操作的操作类型;以及获取目标物品的第二操作信息集,所述第二操作信息集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;An
关于获取模块2101的具体描述可以参照步骤401以及步骤403的描述,这里不再赘述。For a specific description of the obtaining
特征向量生成模块2102,用于根据所述第一操作信息集进行特征提取确定目标用户特征向量;以及根据所述第二操作信息集进行特征提取确定目标物品特征向量;A feature
关于特征向量生成模块2102的具体描述可以参照步骤402以及步骤404的描述,这里不再赘述。For a specific description of the feature
信息推荐模块2103,用于根据所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,所述推荐信息用于表示所述目标用户对所述目标物品进行所述多个操作类型的操作的概率;当推荐信息满足预设条件,确定向所述目标用户推荐所述目标物品。The
关于信息推荐模块2103的具体描述可以参照步骤406的描述,这里不再赘述。For a specific description of the
在一种可能的实现中,所述特征向量生成模块2102,具体用于:In a possible implementation, the feature
根据所述第一操作信息集确定多个子用户特征向量,其中,每个子用户特征向量为对存在对应关系的物品的属性信息和操作类型进行特征提取得到的;Determining a plurality of sub-user feature vectors according to the first operation information set, wherein each sub-user feature vector is obtained by feature extraction of attribute information and operation types of items with corresponding relationships;
对所述多个子用户特征向量进行融合,得到所述目标用户特征向量。The multiple sub-user feature vectors are fused to obtain the target user feature vector.
在一种可能的实现中,所述特征向量生成模块2102,具体用于:In a possible implementation, the feature
根据所述第二操作信息集确定多个子物品特征向量,其中,每个子物品特征向量为对存在对应关系的用户的属性信息和操作类型进行特征提取得到的;Determining a plurality of sub-item feature vectors according to the second operation information set, wherein each sub-item feature vector is obtained by performing feature extraction on attribute information and operation types of users with corresponding relationships;
对所述多个子物品特征向量进行融合,得到所述目标物品特征向量。The multiple sub-item feature vectors are fused to obtain the target item feature vector.
在一种可能的实现中,所述信息推荐模块2103,具体用于:In a possible implementation, the
根据所述多个操作类型的多个操作类型特征向量,所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息。Outputting recommendation information based on a target recommendation model according to multiple operation type feature vectors of the multiple operation types, the target user feature vector and the target item feature vector.
在一种可能的实现中,所述获取模块2101,具体用于:In a possible implementation, the obtaining
获取第一操作信息子集和第二操作信息子集;其中,Obtain the first subset of operation information and the second subset of operation information; wherein,
所述第一操作信息子集中包括,第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;所述第一操作类型为所述目标用户对所述第一物品的真实操作类型;The first operation information subset includes attribute information of the first item, a first operation type, and a correspondence between the first item and the first operation type; the first operation type is the target user the actual type of operation on the first item;
所述第二操作信息子集包括,第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;所述第二操作类型为所述目标用户对所述第二物品的预测操作类型;The second operation information subset includes attribute information of the second item, a second operation type, and a correspondence between the second item and the second operation type; the second operation type is the target user a type of predicted operation on said second item;
所述特征向量生成模块2102,具体用于:The feature
根据所述第一操作信息子集确定第一子用户特征向量;determining a first sub-user feature vector according to the first subset of operation information;
根据所述第二操作信息子集确定第二子用户特征向量。A second sub-user feature vector is determined according to the second subset of operation information.
在一种可能的实现中,所述特征向量生成模块2102,具体用于:In a possible implementation, the feature
根据所述第一子用户特征向量的第一权重以及所述第二子用户特征向量的第二权重,对所述第一子用户特征向量和所述第二子用户特征向量进行融合。The first sub-user feature vector and the second sub-user feature vector are fused according to the first weight of the first sub-user feature vector and the second weight of the second sub-user feature vector.
所述获取模块2101,还用于:The obtaining
获取所述第二操作类型;obtain the second operation type;
所述获取所述第二操作类型,具体为:The acquiring the second operation type is specifically:
获取第一用户对第二物品的第三操作类型,所述第一用户为所述目标用户的物品喜好特征满足预设条件的用户;Obtaining a third operation type of a first user on a second item, the first user being a user whose item preference characteristics of the target user meet a preset condition;
基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型。The second operation type is acquired based on the third operation type of the first user on the second item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对所述第一物品有操作的用户;Both the first user and the target user are users who operate on the first item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型,具体为,按照所述第三操作类型获取所述第二操作类型。In a possible implementation, the acquiring the second operation type based on the third operation type of the first user on the second item is specifically, acquiring according to the third operation type The second operation type.
在一种可能的实现中,所述操作类型为正向操作类型。In a possible implementation, the operation type is a forward operation type.
在一种可能的实现中,所述获取模块2101,具体用于:In a possible implementation, the obtaining
获取第三操作信息子集和第四操作信息子集;其中,Obtain the third subset of operation information and the fourth subset of operation information; wherein,
所述第三操作信息子集中包括,第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系;所述第四正向操作类型为所述第二用户对所述目标物品的真实操作类型。The third operation information subset includes attribute information of the second user, a fourth forward operation type, and a correspondence between the second user and the fourth forward operation type; the fourth forward operation The type is an actual operation type of the target item by the second user.
所述第四操作信息子集中包括,第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系;所述第五操作类型为所述第三用户对所述目标物品的预测操作类型;The fourth operation information subset includes attribute information of the third user, a fifth operation type, and a correspondence between the third user and the fifth operation type; the fifth operation type is the third user's The user's predicted operation type on the target item;
所述特征向量生成模块2102,具体用于:The feature
根据所述第三操作信息子集确定第一子物品特征向量;determining a first sub-item feature vector according to the third subset of operation information;
根据所述第四操作信息子集确定第二子物品特征向量。A second sub-item feature vector is determined according to the fourth subset of operation information.
在一种可能的实现中,所述特征向量生成模块2102,具体用于:In a possible implementation, the feature
根据所述第一子物品特征向量的第三权重以及所述第二子用户特征向量的第四权重,对所述第一子物品特征向量和所述第二子物品特征向量进行融合。The first sub-item feature vector and the second sub-item feature vector are fused according to the third weight of the first sub-item feature vector and the fourth weight of the second sub-user feature vector.
在一种可能的实现中,所述获取模块2101,具体用于:In a possible implementation, the obtaining
获取所述第五操作类型;Obtain the fifth operation type;
所述获取所述第五操作类型,具体包括:The acquiring the fifth operation type specifically includes:
获取第四用户对所述目标物品的第六操作类型,所述第四用户和所述第三用户的物品喜好特征满足预设条件的用户;Obtaining a sixth operation type of the fourth user on the target item, and users whose item preference features of the fourth user and the third user meet preset conditions;
基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型。The fifth operation type is acquired based on a sixth operation type performed by the fourth user on the target item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第四用户和所述第三用户均为对所述第一物品有操作的用户;Both the fourth user and the third user are users who operate on the first item;
所述第四用户和所述第三用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the fourth user and the third user is less than a threshold; and
所述第四用户和所述第三用户为对物品属性差异小于阈值的物品有操作的用户。The fourth user and the third user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型,具体为,按照所述第六操作类型获取所述第五操作类型。In a possible implementation, the acquiring the fifth operation type based on the sixth operation type of the fourth user on the target item is specifically, acquiring the fifth operation type according to the sixth operation type. Action type.
本申请提供了一种信息推荐装置,所述装置包括:获取模块,用于获取目标用户的第一操作信息集,所述第一操作信息集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标用户对所述多个物品进行的操作的操作类型;以及获取目标物品的第二操作信息集,所述第二操作信息集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;特征向量生成模块,用于根据所述第一操作信息集进行特征提取确定目标用户特征向量;以及根据所述第二操作信息集进行特征提取确定目标物品特征向量;信息推荐模块,用于根据所述目标用户特征向量和所述目标物品特征向量,基于目标推荐模型,输出推荐信息,所述推荐信息用于表示所述目标用户对所述目标物品进行所述多个操作类型的操作的概率;当推荐信息满足预设条件,确定向所述目标用户推荐所述目标物品。本申请基于存在关联关系的物品和操作类型来生成表征目标用户喜好的目标用户特征向量,以及基于存在关联关系的用户和操作类型来生成表征目标物品对用户的吸引力特征的第二特征向量,来预测目标用户对目标物品的进行多个操作类型的操作的概率,可以更准确的刻画出用户针对于物品的操作概率。The present application provides an information recommendation device, the device includes: an acquisition module, configured to acquire a first operation information set of a target user, the first operation information set includes attribute information of a plurality of items, a plurality of operation types, and the corresponding relationship between the multiple items and the multiple operation types, the corresponding relationship is used to represent the operation type of the operation performed by the target user on the multiple items; and acquiring the second operation information of the target item set, the second operation information set includes the attribute information of multiple users, the multiple operation types, and the correspondence between the multiple users and the multiple operation types, and the correspondence is used to represent the The operation type of the operation performed by multiple users on the target item; the feature vector generation module is used to perform feature extraction and determine the target user feature vector according to the first operation information set; and perform feature extraction and determination according to the second operation information set Target item feature vector; an information recommendation module, configured to output recommendation information based on the target recommendation model based on the target user feature vector and the target item feature vector, and the recommendation information is used to indicate that the target user has a high opinion of the target Probability of the item performing operations of the multiple operation types; when the recommendation information satisfies a preset condition, it is determined to recommend the target item to the target user. This application generates a target user feature vector representing the preferences of the target user based on the associated items and operation types, and generates a second feature vector representing the attractiveness of the target item to the user based on the associated users and operation types, To predict the probability of the target user performing multiple types of operations on the target item, it can more accurately describe the user's operation probability for the item.
参照图22,图22为本申请实施例提供的一种训练样本构建装置的结构示意,所述装置2200包括:Referring to FIG. 22, FIG. 22 is a schematic structural diagram of a training sample construction device provided in the embodiment of the present application. The
获取模块2201,用于获取第一用户对第一物品的第一操作类型,所述第一用户和目标用户的物品喜好特征满足预设条件;An
关于获取模块2201的具体描述可以参照步骤1901的描述,这里不再赘述。For a specific description of the obtaining
操作信息生成模块2202,用于基于所述第一用户针对于所述第一物品的所述第一操作类型,生成所述目标用户对所述第一物品的第二操作类型;所述第二操作类型为所述目标用户针对所述第一物品的预测操作行为。An operation
关于操作信息生成模块2202的具体描述可以参照步骤1902的描述,这里不再赘述。For a specific description of the operation
样本构建模块2203,用于根据所述目标用户的属性信息、所述第一物品的属性信息以及所述第二操作类型,构建训练样本。A
关于样本构建模块2203的具体描述可以参照步骤1903的描述,这里不再赘述。For the specific description of the
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对第二物品有操作的用户;Both the first user and the target user are users who operate on the second item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述用户属性包括如下的至少一种:In a possible implementation, the user attributes include at least one of the following:
性别,年龄,职业,收入,爱好,教育程度。Gender, age, occupation, income, hobbies, education level.
在一种可能的实现中,所述物品属性包括如下的至少一种:In a possible implementation, the item attributes include at least one of the following:
物品名称,开发者,安装包大小,品类,好评度。Item name, developer, installation package size, category, praise rating.
在一种可能的实现中,所述第一操作类型与所述第二操作类型相同。In a possible implementation, the first operation type is the same as the second operation type.
在一种可能的实现中,所述第一操作类型和所述第二操作类型包括如下的至少一种:In a possible implementation, the first operation type and the second operation type include at least one of the following:
浏览操作,加入购物车操作以及购买操作。Browse actions, add to cart actions, and buy actions.
在一种可能的实现中,所述操作信息生成模块2202,具体用于:In a possible implementation, the operation
基于所述第一用户针对于所述第一物品的所述第一操作类型,获取第二操作类型;acquiring a second operation type based on the first operation type performed by the first user on the first item;
所述获取第二操作类型,具体为,按照所述第一操作类型获取所述第二操作类型。The acquiring the second operation type specifically includes acquiring the second operation type according to the first operation type.
本申请实施例提供了一种用户操作行为预测装置,所述装置包括:获取模块,用于获取第一用户对第一物品的第一操作类型,所述第一用户和目标用户的物品喜好特征满足预设条件;操作信息生成模块,用于基于所述第一用户针对于所述第一物品的所述第一操作类型,生成所述目标用户对所述第一物品的第二操作类型;所述第二操作类型为所述目标用户针对所述第一物品的预测操作行为。本申请可以在有限的历史操作数据中发掘更丰富的信息,进而生成更多的与用户相关的操作信息,进而可以提高历史操作记录的数据利用率,基于上述信息训练的推荐模型可以更加准确的预测用户的行为。An embodiment of the present application provides a device for predicting user operation behavior, the device including: an acquisition module, configured to acquire the first operation type of the first user on the first item, the item preference characteristics of the first user and the target user Satisfying preset conditions; an operation information generating module, configured to generate a second operation type of the target user on the first item based on the first operation type of the first user on the first item; The second operation type is a predicted operation behavior of the target user on the first item. This application can explore more abundant information in the limited historical operation data, and then generate more user-related operation information, thereby improving the data utilization rate of historical operation records, and the recommendation model trained based on the above information can be more accurate. Predict user behavior.
参照图23,图23为本申请实施例提供的一种推荐模型训练装置的结构示意,所述装置2300可以包括:Referring to FIG. 23 , FIG. 23 is a schematic structural diagram of a recommended model training device provided in an embodiment of the present application. The
获取模块2301,用于获取目标样本用户的第一操作信息样本集,所述第一操作信息样本集包括多个物品的属性信息,多个操作类型,以及所述多个物品和所述多个操作类型的对应关系,所述对应关系用于表示所述目标样本用户对所述多个物品进行的操作的操作类型;获取目标样本物品的第二操作信息样本集,所述第二操作信息样本集包括多个用户的属性信息,所述多个操作类型,以及所述多个用户和所述多个操作类型的对应关系,所述对应关系用于表示所述多个用户对目标物品进行的操作的操作类型;Obtaining
关于获取模块2301的具体描述可以参照步骤2001以及步骤2003的描述,这里不再赘述。For the specific description of the obtaining
特征向量生成模块2302,用于根据所述第一操作信息样本集进行特征提取确定目标样本用户特征向量;根据所述第二操作信息样本集进行特征提取确定目标样本物品特征向量;The feature
关于特征向量生成模块2302的具体描述可以参照步骤2002以及步骤2004的描述,这里不再赘述。For the specific description of the feature
所述获取模块2301,还用于根据所述目标样本用户对所述目标物品的实际操作类型获取样本标签;The acquiring
关于获取模块2301的具体描述可以参照步骤2005的描述,这里不再赘述。For a specific description of the obtaining
模型训练模块2303,用于以所述目标样本用户特征向量和所述目标样本物品特征向量为输入,所述样本标签为输出,进行模型训练,获取目标推荐模型。The
关于模型训练模块2303的具体描述可以参照步骤2006的描述,这里不再赘述。For the specific description of the
在一种可能的实现中,所述特征向量生成模块2302,具体用于:In a possible implementation, the feature
根据所述第一操作信息样本集确定多个子样本用户特征向量,其中,每个子样本用户特征向量为对存在对应关系的物品的属性信息和操作类型进行特征提取得到的;A plurality of sub-sample user feature vectors are determined according to the first operation information sample set, wherein each sub-sample user feature vector is obtained by feature extraction of attribute information and operation types of items with corresponding relationships;
对所述多个用户子样本用户特征向量进行融合,得到所述目标样本用户特征向量。The multiple user sub-sample user feature vectors are fused to obtain the target sample user feature vector.
在一种可能的实现中,所述特征向量生成模块2302,具体用于:In a possible implementation, the feature
根据所述第二操作信息样本集确定多个子样本物品特征向量,其中,每个第二子样本物品特征向量为对存在对应关系的用户的属性信息和操作类型进行特征提取得到的;A plurality of sub-sample item feature vectors are determined according to the second operation information sample set, wherein each second sub-sample item feature vector is obtained by feature extraction of user attribute information and operation types that have a corresponding relationship;
对所述多个子样本物品特征向量进行融合,得到所述目标样本物品特征向量。The multiple sub-sample item feature vectors are fused to obtain the target sample item feature vector.
在一种可能的实现中,所述以所述目标样本用户特征向量和所述目标样本物品特征向量为输入,包括:In a possible implementation, the inputting the target sample user feature vector and the target sample item feature vector includes:
以所述多个操作类型的多个操作类型特征向量,所述目标样本用户特征向量和所述目标样本物品特征向量为输入。Taking multiple operation type feature vectors of the multiple operation types, the target sample user feature vector and the target sample item feature vector as input.
在一种可能的实现中,所述获取模块2301,具体用于:In a possible implementation, the acquiring
获取第一操作信息样本子集和第二操作信息样本子集;其中,Obtain the first subset of operation information samples and the second subset of operation information samples; wherein,
所述第一操作信息样本子集中包括,第一物品的属性信息,第一操作类型,以及所述第一物品和所述第一操作类型的对应关系;所述第一操作类型为所述目标用户对所述第一物品的真实操作类型;The first operation information sample subset includes attribute information of a first item, a first operation type, and a correspondence between the first item and the first operation type; the first operation type is the target The actual operation type of the user on the first item;
所述第二操作信息样本子集包括,第二物品的属性信息,第二操作类型,以及所述第二物品和所述第二操作类型的对应关系;所述第二操作类型为所述目标用户对所述第二物品的预测操作类型;The second operation information sample subset includes attribute information of a second item, a second operation type, and a correspondence between the second item and the second operation type; the second operation type is the target The user's predicted operation type on the second item;
所述特征向量生成模块2302,具体用于:The feature
根据所述第一操作信息样本子集确定第一子样本用户特征向量;determining a first subsample user feature vector according to the first subset of operation information samples;
根据所述第二操作信息样本子集确定第二子样本用户特征向量。A second sub-sample user feature vector is determined according to the second subset of operation information samples.
在一种可能的实现中,所述特征向量生成模块2302,具体用于:In a possible implementation, the feature
根据所述第一子样本用户特征向量的第一权重和所述第二子样本用户特征向量的第二权重,对所述第一子样本用户特征向量和所述第二子样本用户特征向量进行融合。According to the first weight of the first sub-sample user feature vector and the second weight of the second sub-sample user feature vector, the first sub-sample user feature vector and the second sub-sample user feature vector are performed fusion.
在一种可能的实现中,所述获取模块2301,具体用于:In a possible implementation, the acquiring
获取所述第二操作类型;obtain the second operation type;
所述获取所述第二操作类型,具体为:The acquiring the second operation type is specifically:
获取第一用户对第二物品的第三操作类型,所述第一用户为所述目标用户的物品喜好特征满足预设条件的用户;Obtaining a third operation type of a first user on a second item, the first user being a user whose item preference characteristics of the target user meet a preset condition;
基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型。The second operation type is acquired based on the third operation type of the first user on the second item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第一用户和所述目标用户均为对所述第一物品有操作的用户;Both the first user and the target user are users who operate on the first item;
所述第一用户和所述目标用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the first user and the target user is less than a threshold; and
所述第一用户和所述目标用户为对物品属性差异小于阈值的物品有操作的用户。The first user and the target user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第一用户针对于所述第二物品的所述第三操作类型,获取所述第二操作类型,具体为,按照所述第三操作类型获取所述第二操作类型。In a possible implementation, the acquiring the second operation type based on the third operation type of the first user on the second item is specifically, acquiring according to the third operation type The second operation type.
在一种可能的实现中,所述操作类型为正向操作类型。In a possible implementation, the operation type is a forward operation type.
在一种可能的实现中,所述获取模块2301,具体用于:In a possible implementation, the acquiring
获取第三操作信息样本子集和第四操作信息样本子集;其中,Obtain the third subset of operation information samples and the fourth subset of operation information samples; wherein,
所述第三操作信息样本子集中包括,第二用户的属性信息,第四正向操作类型,以及所述第二用户和所述第四正向操作类型的对应关系;所述第四正向操作类型为所述第二用户对所述目标物品的真实操作类型;The third operation information sample subset includes attribute information of the second user, a fourth forward operation type, and a correspondence between the second user and the fourth forward operation type; the fourth forward operation type The operation type is the actual operation type of the second user on the target item;
所述第四操作信息样本子集中包括,第三用户的属性信息,第五操作类型,以及所述第三用户和所述第五操作类型的对应关系;所述第五操作类型为所述第三用户对所述目标物品的预测操作类型;The fourth operation information sample subset includes attribute information of the third user, a fifth operation type, and a corresponding relationship between the third user and the fifth operation type; the fifth operation type is the first 3. The user's predicted operation type on the target item;
所述特征向量生成模块2302,具体用于:The feature
根据所述第三操作信息样本子集确定第一子样本物品特征向量;determining a first sub-sample item feature vector according to the third subset of operation information samples;
根据所述第四操作信息样本子集确定第二子样本物品特征向量。A second sub-sample feature vector is determined according to the fourth subset of operation information samples.
在一种可能的实现中,所述特征向量生成模块2302,具体用于:In a possible implementation, the feature
根据所述第一子样本物品特征向量的第三权重以及所述第二子样本物品特征向量的第四权重,对所述第一子样本物品特征向量和所述第二子样本物品特征向量进行融合。在一种可能的实现中,所述获取模块2301,具体用于:According to the third weight of the first sub-sample item feature vector and the fourth weight of the second sub-sample item feature vector, the first sub-sample item feature vector and the second sub-sample item feature vector are performed fusion. In a possible implementation, the acquiring
获取所述第五操作类型;Obtain the fifth operation type;
所述获取所述第五操作类型,具体包括:The acquiring the fifth operation type specifically includes:
获取第四用户对所述目标物品的第六操作类型,所述第四用户和所述第三用户的物品喜好特征满足预设条件的用户;Obtaining a sixth operation type of the fourth user on the target item, and users whose item preference features of the fourth user and the third user meet preset conditions;
基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型。The fifth operation type is acquired based on a sixth operation type performed by the fourth user on the target item.
在一种可能的实现中,所述预设条件包括如下的至少一种:In a possible implementation, the preset conditions include at least one of the following:
所述第四用户和所述第三用户均为对所述第一物品有操作的用户;Both the fourth user and the third user are users who operate on the first item;
所述第四用户和所述第三用户的用户属性的差异度小于阈值;以及The degree of difference between the user attributes of the fourth user and the third user is less than a threshold; and
所述第四用户和所述第三用户为对物品属性差异小于阈值的物品有操作的用户。The fourth user and the third user are users who operate on items whose attribute difference is smaller than a threshold.
在一种可能的实现中,所述基于所述第四用户对所述目标物品的第六操作类型,获取所述第五操作类型,具体为,按照所述第六操作类型获取所述第五操作类型。In a possible implementation, the acquiring the fifth operation type based on the sixth operation type of the fourth user on the target item is specifically, acquiring the fifth operation type according to the sixth operation type. Action type.
接下来介绍本申请实施例提供的一种执行设备,请参阅图24,图24为本申请实施例提供的执行设备的一种结构示意图,执行设备2400具体可以表现为手机、平板、笔记本电脑、智能穿戴设备、服务器等,此处不做限定。其中,执行设备2400上可以部署有图10对应实施例中所描述的数据处理装置,用于实现图10对应实施例中数据处理的功能。具体的,执行设备2400包括:接收器2401、发射器2402、处理器2403和存储器2404(其中执行设备2400中的处理器2403的数量可以一个或多个),其中,处理器2403可以包括应用处理器24031和通信处理器24032。在本申请的一些实施例中,接收器2401、发射器2402、处理器2403和存储器2404可通过总线或其它方式连接。Next, an execution device provided by the embodiment of the present application is introduced. Please refer to FIG. 24. FIG. 24 is a schematic structural diagram of the execution device provided by the embodiment of the present application. Smart wearable devices, servers, etc. are not limited here. Wherein, the data processing apparatus described in the embodiment corresponding to FIG. 10 may be deployed on the
存储器2404可以包括只读存储器和随机存取存储器,并向处理器2403提供指令和数据。存储器2404的一部分还可以包括非易失性随机存取存储器(non-volatile randomaccess memory,NVRAM)。存储器2404存储有处理器和操作指令、可执行模块或者数据结构,或者它们的子集,或者它们的扩展集,其中,操作指令可包括各种操作指令,用于实现各种操作。The memory 2404 may include read-only memory and random-access memory, and provides instructions and data to the processor 2403 . A part of the memory 2404 may also include a non-volatile random access memory (non-volatile random access memory, NVRAM). The memory 2404 stores processors and operating instructions, executable modules or data structures, or their subsets, or their extended sets, wherein the operating instructions may include various operating instructions for implementing various operations.
处理器2403控制执行设备的操作。具体的应用中,执行设备的各个组件通过总线系统耦合在一起,其中总线系统除包括数据总线之外,还可以包括电源总线、控制总线和状态信号总线等。但是为了清楚说明起见,在图中将各种总线都称为总线系统。The processor 2403 controls the operations of the execution device. In a specific application, various components of the execution device are coupled together through a bus system, where the bus system may include not only a data bus, but also a power bus, a control bus, and a status signal bus. However, for the sake of clarity, the various buses are referred to as bus systems in the figures.
上述本申请实施例揭示的方法可以应用于处理器2403中,或者由处理器2403实现。处理器2403可以是一种集成电路芯片,具有信号的处理能力。在实现过程中,上述方法的各步骤可以通过处理器2403中的硬件的集成逻辑电路或者软件形式的指令完成。上述的处理器2403可以是通用处理器、数字信号处理器(digital signal processing,DSP)、微处理器或微控制器、以及视觉处理器(vision processing unit,VPU)、张量处理器(tensorprocessing unit,TPU)等适用于AI运算的处理器,还可进一步包括专用集成电路(application specific integrated circuit,ASIC)、现场可编程门阵列(field-programmable gate array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。该处理器2403可以实现或者执行本申请实施例中的公开的各方法、步骤及逻辑框图。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。结合本申请实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成,或者用译码处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器,闪存、只读存储器,可编程只读存储器或者电可擦写可编程存储器、寄存器等本领域成熟的存储介质中。该存储介质位于存储器2404,处理器2403读取存储器2404中的信息,结合其硬件完成上述实施例中步骤401至步骤406的步骤,以及步骤1901和步骤1902的步骤。The methods disclosed in the foregoing embodiments of the present application may be applied to the processor 2403 or implemented by the processor 2403 . The processor 2403 may be an integrated circuit chip, which has a signal processing capability. In the implementation process, each step of the above-mentioned method may be completed by an integrated logic circuit of hardware in the processor 2403 or instructions in the form of software. The above-mentioned processor 2403 may be a general-purpose processor, a digital signal processor (digital signal processing, DSP), a microprocessor or a microcontroller, a vision processing unit (vision processing unit, VPU), a tensor processing unit (tensorprocessing unit) , TPU) and other processors suitable for AI computing, and can further include application specific integrated circuits (application specific integrated circuits, ASICs), field-programmable gate arrays (field-programmable gate arrays, FPGAs) or other programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components. The processor 2403 may implement or execute various methods, steps, and logic block diagrams disclosed in the embodiments of the present application. A general-purpose processor may be a microprocessor, or the processor may be any conventional processor, or the like. The steps of the method disclosed in connection with the embodiments of the present application may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module can be located in a mature storage medium in the field such as random access memory, flash memory, read-only memory, programmable read-only memory or electrically erasable programmable memory, register. The storage medium is located in the memory 2404, and the processor 2403 reads the information in the memory 2404, and combines its hardware to complete steps from
接收器2401可用于接收输入的数字或字符信息,以及产生与执行设备的相关设置以及功能控制有关的信号输入。发射器2402可用于通过第一接口输出数字或字符信息;发射器2402还可用于通过第一接口向磁盘组发送指令,以修改磁盘组中的数据;发射器2402还可以包括显示屏等显示设备。The receiver 2401 can be used to receive input digital or character information, and generate signal input related to performing device related settings and function control. The transmitter 2402 can be used to output digital or character information through the first interface; the transmitter 2402 can also be used to send instructions to the disk group through the first interface to modify the data in the disk group; the transmitter 2402 can also include display devices such as a display screen .
本申请实施例还提供了一种训练设备,请参阅图25,图25是本申请实施例提供的训练设备一种结构示意图,具体的,训练设备2500由一个或多个服务器实现,训练设备2500可因配置或性能不同而产生比较大的差异,可以包括一个或一个以上中央处理器(centralprocessing units,CPU)2525(例如,一个或一个以上处理器)和存储器2532,一个或一个以上存储应用程序2542或数据2544的存储介质2530(例如一个或一个以上海量存储设备)。其中,存储器2532和存储介质2530可以是短暂存储或持久存储。存储在存储介质2530的程序可以包括一个或一个以上模块(图示没标出),每个模块可以包括对训练设备中的一系列指令操作。更进一步地,中央处理器2525可以设置为与存储介质2530通信,在训练设备2500上执行存储介质2530中的一系列指令操作。The embodiment of the present application also provides a training device. Please refer to FIG. 25. FIG. 25 is a schematic structural diagram of the training device provided in the embodiment of the present application. Specifically, the
训练设备2500还可以包括一个或一个以上电源2526,一个或一个以上有线或无线网络接口2550,一个或一个以上输入输出接口2558;或,一个或一个以上操作系统2541,例如Windows ServerTM,Mac OS XTM,UnixTM,LinuxTM,FreeBSDTM等等。The
具体的,训练设备可以进行上述实施例中步骤2001至步骤2006的步骤。Specifically, the training device may perform steps from
本申请实施例中还提供一种包括计算机程序产品,当其在计算机上运行时,使得计算机执行如前述执行设备所执行的步骤,或者,使得计算机执行如前述训练设备所执行的步骤。The embodiment of the present application also provides a computer program product, which, when running on a computer, causes the computer to perform the steps performed by the aforementioned execution device, or enables the computer to perform the steps performed by the aforementioned training device.
本申请实施例中还提供一种计算机可读存储介质,该计算机可读存储介质中存储有用于进行信号处理的程序,当其在计算机上运行时,使得计算机执行如前述执行设备所执行的步骤,或者,使得计算机执行如前述训练设备所执行的步骤。An embodiment of the present application also provides a computer-readable storage medium, the computer-readable storage medium stores a program for signal processing, and when it is run on a computer, the computer executes the steps performed by the aforementioned executing device , or, causing the computer to perform the steps performed by the aforementioned training device.
本申请实施例提供的执行设备、训练设备或终端设备具体可以为芯片,芯片包括:处理单元和通信单元,所述处理单元例如可以是处理器,所述通信单元例如可以是输入/输出接口、管脚或电路等。该处理单元可执行存储单元存储的计算机执行指令,以使执行设备内的芯片执行上述实施例描述的数据处理方法,或者,以使训练设备内的芯片执行上述实施例描述的数据处理方法。可选地,所述存储单元为所述芯片内的存储单元,如寄存器、缓存等,所述存储单元还可以是所述无线接入设备端内的位于所述芯片外部的存储单元,如只读存储器(read-only memory,ROM)或可存储静态信息和指令的其他类型的静态存储设备,随机存取存储器(random access memory,RAM)等。The execution device, training device or terminal device provided in the embodiment of the present application may specifically be a chip. The chip includes: a processing unit and a communication unit. The processing unit may be, for example, a processor, and the communication unit may be, for example, an input/output interface, pins or circuits etc. The processing unit can execute the computer-executed instructions stored in the storage unit, so that the chips in the execution device execute the data processing methods described in the above embodiments, or make the chips in the training device execute the data processing methods described in the above embodiments. Optionally, the storage unit is a storage unit in the chip, such as a register, a cache, etc., and the storage unit may also be a storage unit located outside the chip in the wireless access device, such as only Read-only memory (ROM) or other types of static storage devices that can store static information and instructions, random access memory (random access memory, RAM), etc.
具体的,请参阅图26,图26为本申请实施例提供的芯片的一种结构示意图,所述芯片可以表现为神经网络处理器NPU2600,NPU 2600作为协处理器挂载到主CPU(Host CPU)上,由Host CPU分配任务。NPU的核心部分为运算电路2603,通过控制器2604控制运算电路2603提取存储器中的矩阵数据并进行乘法运算。Specifically, please refer to FIG. 26. FIG. 26 is a schematic structural diagram of a chip provided by the embodiment of the present application. The chip can be represented as a neural network processor NPU2600, and the NPU 2600 is mounted on the main CPU (Host CPU) as a coprocessor. ), the tasks are assigned by the Host CPU. The core part of the NPU is the operation circuit 2603, and the controller 2604 controls the operation circuit 2603 to extract matrix data in the memory and perform multiplication operations.
NPU 2600可以通过内部的各个器件之间的相互配合,来实现图4所描述的实施例中提供的信息推荐方法以及图19b所描述的实施例中提供的训练样本构建方法,以及图20所描述的实施例中提供的推荐模型训练方法。The NPU 2600 can realize the information recommendation method provided in the embodiment described in FIG. 4 and the training sample construction method provided in the embodiment described in FIG. The recommended model training method provided in the examples.
更具体的,在一些实现中,NPU 2600中的运算电路2603内部包括多个处理单元(Process Engine,PE)。在一些实现中,运算电路2603是二维脉动阵列。运算电路2603还可以是一维脉动阵列或者能够执行例如乘法和加法这样的数学运算的其它电子线路。在一些实现中,运算电路2603是通用的矩阵处理器。More specifically, in some implementations, the computing circuit 2603 in the NPU 2600 includes multiple processing units (Process Engine, PE). In some implementations, arithmetic circuit 2603 is a two-dimensional systolic array. The arithmetic circuit 2603 may also be a one-dimensional systolic array or other electronic circuits capable of performing mathematical operations such as multiplication and addition. In some implementations, arithmetic circuit 2603 is a general-purpose matrix processor.
举例来说,假设有输入矩阵A,权重矩阵B,输出矩阵C。运算电路从权重存储器2602中取矩阵B相应的数据,并缓存在运算电路中每一个PE上。运算电路从输入存储器2601中取矩阵A数据与矩阵B进行矩阵运算,得到的矩阵的部分结果或最终结果,保存在累加器(accumulator)2608中。For example, suppose there is an input matrix A, a weight matrix B, and an output matrix C. The operation circuit fetches the data corresponding to the matrix B from the weight memory 2602, and caches it in each PE in the operation circuit. The operation circuit takes the data of matrix A from the input memory 2601 and performs matrix operation with matrix B, and the obtained partial or final results of the matrix are stored in the accumulator (accumulator) 2608 .
统一存储器2606用于存放输入数据以及输出数据。权重数据直接通过存储单元访问控制器(Direct Memory Access Controller,DMAC)2605,DMAC被搬运到权重存储器2602中。输入数据也通过DMAC被搬运到统一存储器2606中。The unified memory 2606 is used to store input data and output data. The weight data directly accesses the controller (Direct Memory Access Controller, DMAC) 2605 through the storage unit, and the DMAC is transferred to the weight storage 2602 . The input data is also transferred to the unified memory 2606 through the DMAC.
BIU为Bus Interface Unit即,总线接口单元2610,用于AXI总线与DMAC和取指存储器(Instruction Fetch Buffer,IFB)2609的交互。The BIU is a Bus Interface Unit, that is, the bus interface unit 2610 , which is used for the interaction between the AXI bus and the DMAC and the instruction fetch buffer (Instruction Fetch Buffer, IFB) 2609 .
总线接口单元2610(Bus Interface Unit,简称BIU),用于取指存储器2609从外部存储器获取指令,还用于存储单元访问控制器2605从外部存储器获取输入矩阵A或者权重矩阵B的原数据。The bus interface unit 2610 (Bus Interface Unit, BIU for short) is used for the instruction fetch memory 2609 to obtain instructions from the external memory, and for the storage unit access controller 2605 to obtain the original data of the input matrix A or the weight matrix B from the external memory.
DMAC主要用于将外部存储器DDR中的输入数据搬运到统一存储器2606或将权重数据搬运到权重存储器2602中或将输入数据数据搬运到输入存储器2601中。The DMAC is mainly used to move the input data in the external memory DDR to the unified memory 2606 , to move the weight data to the weight memory 2602 , or to move the input data to the input memory 2601 .
向量计算单元2607包括多个运算处理单元,在需要的情况下,对运算电路2603的输出做进一步处理,如向量乘,向量加,指数运算,对数运算,大小比较等等。主要用于神经网络中非卷积/全连接层网络计算,如Batch Normalization(批归一化),像素级求和,对特征平面进行上采样等。The vector calculation unit 2607 includes a plurality of calculation processing units, and further processes the output of the calculation circuit 2603, such as vector multiplication, vector addition, exponential operation, logarithmic operation, size comparison, etc., if necessary. It is mainly used for non-convolutional/fully connected layer network calculations in neural networks, such as Batch Normalization (batch normalization), pixel-level summation, and upsampling of feature planes.
在一些实现中,向量计算单元2607能将经处理的输出的向量存储到统一存储器2606。例如,向量计算单元2607可以将线性函数;或,非线性函数应用到运算电路2603的输出,例如对卷积层提取的特征平面进行线性插值,再例如累加值的向量,用以生成激活值。在一些实现中,向量计算单元2607生成归一化的值、像素级求和的值,或二者均有。在一些实现中,处理过的输出的向量能够用作到运算电路2603的激活输入,例如用于在神经网络中的后续层中的使用。In some implementations, vector computation unit 2607 can store the vector of the processed output to unified memory 2606 . For example, the vector calculation unit 2607 can apply a linear function; or, a nonlinear function to the output of the operation circuit 2603, such as performing linear interpolation on the feature plane extracted by the convolution layer, and then such as a vector of accumulated values to generate an activation value. In some implementations, the vector computation unit 2607 generates normalized values, pixel-level summed values, or both. In some implementations, the vector of processed outputs can be used as an activation input to arithmetic circuitry 2603, eg, for use in subsequent layers in a neural network.
控制器2604连接的取指存储器(instruction fetch buffer)2609,用于存储控制器2604使用的指令;An instruction fetch buffer (instruction fetch buffer) 2609 connected to the controller 2604 is used to store instructions used by the controller 2604;
统一存储器2606,输入存储器2601,权重存储器2602以及取指存储器2609均为On-Chip存储器。外部存储器私有于该NPU硬件架构。The unified memory 2606, the input memory 2601, the weight memory 2602 and the fetch memory 2609 are all On-Chip memories. External memory is private to the NPU hardware architecture.
其中,上述任一处提到的处理器,可以是一个通用中央处理器,微处理器,ASIC,或一个或多个用于控制上述程序执行的集成电路。Wherein, the processor mentioned above can be a general-purpose central processing unit, microprocessor, ASIC, or one or more integrated circuits for controlling the execution of the above-mentioned programs.
另外需说明的是,以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。另外,本申请提供的装置实施例附图中,模块之间的连接关系表示它们之间具有通信连接,具体可以实现为一条或多条通信总线或信号线。In addition, it should be noted that the device embodiments described above are only illustrative, and the units described as separate components may or may not be physically separated, and the components shown as units may or may not be A physical unit can be located in one place, or it can be distributed to multiple network units. Part or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. In addition, in the drawings of the device embodiments provided in the present application, the connection relationship between the modules indicates that they have communication connections, which can be specifically implemented as one or more communication buses or signal lines.
通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到本申请可借助软件加必需的通用硬件的方式来实现,当然也可以通过专用硬件包括专用集成电路、专用CPU、专用存储器、专用元器件等来实现。一般情况下,凡由计算机程序完成的功能都可以很容易地用相应的硬件来实现,而且,用来实现同一功能的具体硬件结构也可以是多种多样的,例如模拟电路、数字电路或专用电路等。但是,对本申请而言更多情况下软件程序实现是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在可读取的存储介质中,如计算机的软盘、U盘、移动硬盘、ROM、RAM、磁碟或者光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,训练设备,或者网络设备等)执行本申请各个实施例所述的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the present application can be implemented by means of software plus necessary general-purpose hardware, and of course it can also be realized by special hardware including application-specific integrated circuits, dedicated CPUs, dedicated memories, Special components, etc. to achieve. In general, all functions completed by computer programs can be easily realized by corresponding hardware, and the specific hardware structure used to realize the same function can also be varied, such as analog circuits, digital circuits or special-purpose circuit etc. However, for this application, software program implementation is a better implementation mode in most cases. Based on this understanding, the essence of the technical solution of this application or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product is stored in a readable storage medium, such as a floppy disk of a computer , U disk, mobile hard disk, ROM, RAM, magnetic disk or optical disk, etc., including several instructions to make a computer device (which can be a personal computer, training device, or network device, etc.) execute the instructions described in various embodiments of the present application method.
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。In the above embodiments, all or part of them may be implemented by software, hardware, firmware or any combination thereof. When implemented using software, it may be implemented in whole or in part in the form of a computer program product.
所述计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行所述计算机程序指令时,全部或部分地产生按照本申请实施例所述的流程或功能。所述计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。所述计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一计算机可读存储介质传输,例如,所述计算机指令可以从一个网站站点、计算机、训练设备或数据中心通过有线(例如同轴电缆、光纤、数字用户线(DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、训练设备或数据中心进行传输。所述计算机可读存储介质可以是计算机能够存储的任何可用介质或者是包含一个或多个可用介质集成的训练设备、数据中心等数据存储设备。所述可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者半导体介质(例如固态硬盘(Solid State Disk,SSD))等。The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on the computer, the processes or functions according to the embodiments of the present application will be generated in whole or in part. The computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable devices. The computer instructions may be stored in or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transferred from a website, computer, training device, or data The center transmits to another website site, computer, training device or data center via wired (eg, coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (eg, infrared, wireless, microwave, etc.). The computer-readable storage medium may be any available medium that can be stored by a computer, or a data storage device such as a training device or a data center integrated with one or more available media. The available medium may be a magnetic medium (for example, a floppy disk, a hard disk, or a magnetic tape), an optical medium (for example, DVD), or a semiconductor medium (for example, a solid state disk (Solid State Disk, SSD)).
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202110742728.1ACN115545738A (en) | 2021-06-30 | 2021-06-30 | A kind of recommended method and related device |
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202110742728.1ACN115545738A (en) | 2021-06-30 | 2021-06-30 | A kind of recommended method and related device |
| Publication Number | Publication Date |
|---|---|
| CN115545738Atrue CN115545738A (en) | 2022-12-30 |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202110742728.1APendingCN115545738A (en) | 2021-06-30 | 2021-06-30 | A kind of recommended method and related device |
| Country | Link |
|---|---|
| CN (1) | CN115545738A (en) |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN116383521A (en)* | 2023-05-19 | 2023-07-04 | 苏州浪潮智能科技有限公司 | Keyword mining method and device, computer equipment and storage medium |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN108711075A (en)* | 2018-05-22 | 2018-10-26 | 阿里巴巴集团控股有限公司 | A kind of Products Show method and apparatus |
| CN108985830A (en)* | 2018-07-05 | 2018-12-11 | 北京邮电大学 | Recommendation scoring method and device based on heterogeneous information network |
| CN111090756A (en)* | 2020-03-24 | 2020-05-01 | 腾讯科技(深圳)有限公司 | Artificial intelligence-based multi-target recommendation model training method and device |
| CN111400613A (en)* | 2020-03-17 | 2020-07-10 | 苏宁金融科技(南京)有限公司 | Article recommendation method, device, medium and computer equipment |
| CN112365283A (en)* | 2020-11-05 | 2021-02-12 | 广州视琨电子科技有限公司 | Coupon issuing method, device, terminal equipment and storage medium |
| CN112950321A (en)* | 2021-03-10 | 2021-06-11 | 北京汇钧科技有限公司 | Article recommendation method and device |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN108711075A (en)* | 2018-05-22 | 2018-10-26 | 阿里巴巴集团控股有限公司 | A kind of Products Show method and apparatus |
| CN108985830A (en)* | 2018-07-05 | 2018-12-11 | 北京邮电大学 | Recommendation scoring method and device based on heterogeneous information network |
| CN111400613A (en)* | 2020-03-17 | 2020-07-10 | 苏宁金融科技(南京)有限公司 | Article recommendation method, device, medium and computer equipment |
| CN111090756A (en)* | 2020-03-24 | 2020-05-01 | 腾讯科技(深圳)有限公司 | Artificial intelligence-based multi-target recommendation model training method and device |
| CN112365283A (en)* | 2020-11-05 | 2021-02-12 | 广州视琨电子科技有限公司 | Coupon issuing method, device, terminal equipment and storage medium |
| CN112950321A (en)* | 2021-03-10 | 2021-06-11 | 北京汇钧科技有限公司 | Article recommendation method and device |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN116383521A (en)* | 2023-05-19 | 2023-07-04 | 苏州浪潮智能科技有限公司 | Keyword mining method and device, computer equipment and storage medium |
| CN116383521B (en)* | 2023-05-19 | 2023-08-29 | 苏州浪潮智能科技有限公司 | Subject word mining method and device, computer equipment and storage medium |
| Publication | Publication Date | Title |
|---|---|---|
| US12210577B2 (en) | Method and apparatus for training search recommendation model, and method and apparatus for sorting search results | |
| WO2023050143A1 (en) | Recommendation model training method and apparatus | |
| EP4538894A1 (en) | Operation prediction method and related apparatus | |
| WO2025002350A1 (en) | Data processing method and related apparatus | |
| CN115048560B (en) | Data processing method and related device | |
| US20250225398A1 (en) | Data processing method and related apparatus | |
| CN117009650A (en) | Recommendation method and device | |
| EP4398128A1 (en) | Recommendation method and related device | |
| WO2024041483A1 (en) | Recommendation method and related device | |
| CN117217284A (en) | Data processing method and device | |
| CN116204709A (en) | Data processing method and related device | |
| CN115630297A (en) | Model training method and related equipment | |
| WO2024255779A1 (en) | Data processing method and related apparatus | |
| CN117194766A (en) | Data processing method and related device | |
| WO2024230757A1 (en) | Data processing method and related apparatus | |
| WO2024012360A1 (en) | Data processing method and related apparatus | |
| CN116308640A (en) | Recommendation method and related device | |
| CN115618950A (en) | A data processing method and related device | |
| CN115545738A (en) | A kind of recommended method and related device | |
| CN116843022A (en) | A data processing method and related devices | |
| CN115630680A (en) | Data processing method and related device | |
| CN117556917A (en) | Data processing method and device | |
| CN116523587A (en) | Data processing method and related device | |
| CN116910358A (en) | A data processing method and related devices | |
| CN116340616A (en) | A data processing method and related device |
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination |