[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN111475691B - Method and device for acquiring recommended object data and electronic equipment - Google Patents

Method and device for acquiring recommended object data and electronic equipment Download PDF

Info

Publication number
CN111475691B
CN111475691B CN202010151445.5A CN202010151445A CN111475691B CN 111475691 B CN111475691 B CN 111475691B CN 202010151445 A CN202010151445 A CN 202010151445A CN 111475691 B CN111475691 B CN 111475691B
Authority
CN
China
Prior art keywords
object data
data
target
vector
target user
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010151445.5A
Other languages
Chinese (zh)
Other versions
CN111475691A (en
Inventor
周瑜
赵彬杰
谢金锦
臧云飞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Lazas Network Technology Shanghai Co Ltd
Original Assignee
Lazas Network Technology Shanghai Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Lazas Network Technology Shanghai Co Ltd filed Critical Lazas Network Technology Shanghai Co Ltd
Priority to CN202010151445.5A priority Critical patent/CN111475691B/en
Publication of CN111475691A publication Critical patent/CN111475691A/en
Application granted granted Critical
Publication of CN111475691B publication Critical patent/CN111475691B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/903Querying
    • G06F16/9035Filtering based on additional data, e.g. user or group profiles

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiment of the application provides a method for acquiring recommended object data, which comprises the following steps: obtaining target user information and historical object data associated with the target user information; performing data expansion processing on the historical object data according to the target user information and/or the attribute information corresponding to the historical object data to obtain expanded object data; obtaining target object data according to the extended object data, and determining the correlation between the target object data and the target user information; and if the correlation meets the correlation condition, taking the target object data as the recommendation object data corresponding to the target user information. In the embodiment of the application, data expansion processing is performed on historical object data, target object data is obtained by using the expanded object data, and the correlation between the target object data and target user information is determined, so that the problem of low accuracy in recommending objects to users due to insufficient historical object data can be solved.

Description

Method and device for acquiring recommended object data and electronic equipment
Technical Field
The application relates to the technical field of computers, in particular to a method and a device for acquiring recommended object data and electronic equipment.
Background
With the rapid development of science and technology, the living material level is continuously improved, and meanwhile, more and more objects are presented for users to select. Specifically, when object recommendation is performed for a user, an object is generally selected by historical object data related to the user, and then the selected object is recommended to the user. Currently, object data related to processing behaviors such as browsing and selecting by a user is generally used as historical object data related to the user. However, if the number of object data processed by the user is small, or the number of times of processing for the object data is small for all the users, and on this basis, the object data is still used as the historical object data related to the user, the object finally recommended to the user may not be the object actually needed by the user, thereby resulting in low accuracy of inferring the object to the user.
Disclosure of Invention
The embodiment of the application provides a method for acquiring recommended object data, so that the accuracy of recommending objects to a user is improved.
In a first aspect, an embodiment of the present application provides a method for acquiring recommended object data, which is applied to a server or a client, and the method includes: obtaining target user information and historical object data associated with the target user information; performing data expansion processing on the historical object data according to the target user information and/or attribute information corresponding to the historical object data to obtain expanded object data; obtaining target object data according to the extended object data, and determining the correlation degree between the target object data and the target user information; and if the relevance meets the relevance condition, taking the target object data as recommended object data corresponding to the target user information.
Optionally, the performing data expansion processing on the historical object data according to the target user information to obtain expanded object data includes: and merging the historical object data and the target user information to obtain the extended object data.
Optionally, the obtaining target user information and historical object data associated with the target user information includes: obtaining first history object data searched by a target user corresponding to the target user information, second history object data selected by the target user and third history object data in candidate shopping objects corresponding to the target user information; the merging the historical object data and the target user information to obtain the extended object data includes: and merging the first history object data, the second history object data, the third history object data and the target user information to obtain an extended object data sequence, wherein in the extended object data sequence, an element at a position before the first history object data, an element at a position before the second history object data and an element at a position before the third history object data are all the target user information.
Optionally, the obtaining target object data according to the extended object data and determining a correlation between the target object data and the target user information includes: respectively obtaining first target object data, second target object data and third target object data according to the first historical object data, the second historical object data and the third historical object data; respectively determining a first degree of correlation between the first target object data and the target user information, a second degree of correlation between the second target object data and the target user information, and a third degree of correlation between the third target object data and the target user information.
Optionally, the obtaining target user information and historical object data associated with the target user information includes: obtaining historical object data in order information corresponding to the target user information; the merging the historical object data and the target user information to obtain the extended object data includes: and merging the historical object data in the order information with the target user information.
Optionally, the performing data expansion processing on the historical object data according to the attribute information corresponding to the historical object data to obtain expanded object data includes: and merging the plurality of attribute characteristics corresponding to the historical object data to obtain the extended object data.
Optionally, the merging the multiple attribute features corresponding to the historical object data to obtain the extended object data includes: and combining the plurality of attribute characteristics corresponding to the historical object data and the target user information to obtain the extended object data.
Optionally, the plurality of attribute features corresponding to the historical object data include category data to which the historical object data belongs and brand data to which the historical object data belongs.
Optionally, the method further includes: and taking the historical object data as input data of an attribute feature prediction model to obtain attribute features corresponding to the historical object data, wherein the attribute feature prediction model is used for obtaining the attribute features corresponding to the historical object data according to the historical object data.
Optionally, the obtaining target object data according to the extended object data and determining a correlation between the target object data and the target user information includes: obtaining a target user information vector for vector representation of the target user information, and obtaining an extended object data vector for vector representation of the extended object data according to the extended object data; obtaining a target object data vector that vector-represents the target object data based on the augmented object data vector; and determining the correlation degree between the target object data and the target user information according to the target object data vector and the target user information vector.
Optionally, the obtaining, according to the extended object data, an extended object data vector for performing vector representation on the extended object data includes: the data to be expanded is used as input data of a target data vector prediction model, and an expanded target data vector used for vector representation of the data to be expanded is obtained, wherein the target data vector prediction model is a model used for predicting a target data vector according to target data.
Optionally, the obtaining an extended object data vector for performing vector representation on the extended object data by using the extended object data as input data of an object data vector prediction model includes: obtaining a first vector corresponding to the extended object data, a first vector corresponding to first negative sample data opposite to the extended object data, and a first vector corresponding to second negative sample data opposite to the extended object data, wherein the first negative sample data is negative sample data opposite to the extended object data selected from full-size object data, and the second negative sample data satisfies the same preset condition as the extended object data and is negative sample data opposite to the extended object data; obtaining a first target value according to a first vector corresponding to the extended object data, a first vector corresponding to the first negative sample data and a first vector corresponding to the second negative sample data; if the first target value does not meet the target value condition, obtaining a second vector corresponding to the expansion object data, a second vector corresponding to the first negative sample data and a second vector corresponding to the second negative sample data; obtaining a second target value according to a second vector corresponding to the extended object data, a second vector corresponding to the first negative sample data and a second vector corresponding to the second negative sample data; and if the second target value meets a target value condition, taking a second vector corresponding to the extended object data as the extended object data vector, otherwise, obtaining a third vector corresponding to the extended object data, a third vector corresponding to the first negative sample data, a third vector corresponding to the second negative sample data, and so on until a target value meeting the target value condition is obtained.
Optionally, the obtaining a first target value according to the first vector corresponding to the expansion object data, the first vector corresponding to the first negative sample data, and the first vector corresponding to the second negative sample data includes: obtaining a first product result of a first vector corresponding to the extended object data and a first vector corresponding to positive sample data positively correlated to the extended object data, taking a negative value of the first product result as an index of a first natural exponential function, adding the first natural exponential function and a preset constant to obtain a first sum value, and taking the first sum value as a logarithm of a first logarithmic function to obtain a value of the first logarithmic function; obtaining a first product result of a first vector corresponding to the extended object data and a first vector corresponding to the first negative sample data, taking the first product result as an index of a second natural exponential function, adding the second natural exponential function and the preset constant to obtain a second sum value, and taking the second sum value as a logarithm of the second logarithmic function to obtain a value of the second logarithmic function; obtaining a second product result of the first vector corresponding to the extended object data and the first vector corresponding to the second negative sample data, taking the second product result as an index of a third natural exponential function, adding the third natural exponential function and the preset constant to obtain a third sum value, and taking the third sum value as a logarithm of a third logarithmic function to obtain a value of the third logarithmic function; and adding the value of the first logarithmic function, the value of the second logarithmic function and the value of the third logarithmic function to obtain the first target value.
Optionally, the determining a correlation between the target object data and the target user information according to the target object data vector and the target user information vector includes: calculating a distance between the target object data vector and the target user information vector; and determining the correlation degree between the target object data and the target user information according to the distance.
Optionally, the determining a correlation between the target object data and the target user information according to the target object data vector and the target user information vector includes: and taking the target object data vector and the target user information vector as input data of a vector correlation degree prediction model to obtain the correlation degree between the target object data and the target user information, wherein the vector correlation degree prediction model is used for predicting the vector correlation degree.
Optionally, the meeting of the same preset condition means meeting the same preset geographical range.
Optionally, if the method is applied to a server, the method further includes: and providing the recommendation object data corresponding to the target user information to a client.
In a second aspect, an embodiment of the present application provides an apparatus for acquiring recommended object data, which is applied to a server or a client, where the apparatus includes: a first data obtaining unit, configured to obtain target user information and history object data associated with the target user information; a second data obtaining unit, configured to perform data expansion processing on the historical object data according to the target user information and/or attribute information corresponding to the historical object data, so as to obtain expanded object data; a correlation determining unit, configured to obtain target object data according to the extended object data, and determine a correlation between the target object data and the target user information; and the recommended object data obtaining unit is used for taking the target object data as recommended object data corresponding to the target user information if the relevance meets a relevance condition.
In a third aspect, an embodiment of the present application provides an electronic device, which is applied to a server or a client, where the electronic device includes: a processor; and a memory, configured to store a computer program, where the computer program is executed by the processor, and is used to execute the method for acquiring recommendation object data according to the embodiment of the first aspect.
In a fourth aspect, an embodiment of the present application provides a computer storage medium, which is applied to a server or a client, where the computer storage medium stores a computer program, and the computer program is executed by a processor to execute the method for acquiring recommendation object data provided in the embodiment of the present application in the first aspect.
Compared with the prior art, the embodiment of the application has the following advantages:
the embodiment of the application provides a method for acquiring recommended object data, which is applied to a server side or a client side, and comprises the following steps: obtaining target user information and historical object data associated with the target user information; performing data expansion processing on the historical object data according to the target user information and/or the attribute information corresponding to the historical object data to obtain expanded object data; obtaining target object data according to the extended object data, and determining the correlation between the target object data and the target user information; and if the correlation meets the correlation condition, taking the target object data as the recommendation object data corresponding to the target user information. In the embodiment of the application, data expansion processing is performed on the historical object data associated with the target user information, that is, on the basis of the historical object data associated with the target user information, some data are expanded to serve as the object data associated with the target user information, the target object data is determined by using the expanded object data, the correlation degree between the target object data and the target user information is determined, and therefore whether the target object data is used as the recommendation object data corresponding to the target user information is determined, and therefore the problem that the accuracy of recommending the object to the user is low due to insufficient historical object data associated with the target user information can be solved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments described in the present application, and other drawings can be obtained by those skilled in the art according to the drawings.
Fig. 1 is a schematic view of an application scenario of a method for acquiring recommended object data according to a first embodiment of the present application.
Fig. 2 is a flowchart of a method for acquiring recommended object data according to a first embodiment of the present application.
Fig. 3 is a schematic diagram of an apparatus for acquiring recommended object data according to a second embodiment of the present application.
Fig. 4 is a schematic view of an electronic device for acquiring recommended object data according to a third embodiment of the present application.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present application. This application is capable of implementation in many different ways than those herein set forth and of similar import by those skilled in the art without departing from the spirit of this application and is therefore not limited to the specific implementations disclosed below.
Some embodiments provided by the application can be applied to a server or a client. Please refer to fig. 1, which is a schematic application scenario diagram of the method for acquiring recommended object data provided in the present application, and the flowchart of fig. 1 is executed at a server side for description. The scenario embodiment can be used in a scenario where an individual user (or a merchant user) searches for, clicks on, purchases, and purchases a commodity on an application providing the commodity. Since the number and types of the products searched, clicked, purchased and purchased by the user on the application are limited, and the application program providing the products can provide a variety of products, how to recommend the product data in the application program to the user becomes a problem to be solved by the embodiment of the present scenario. When recommending commodity data in an application program to a user, the recommended commodity data of each user may be different, mainly because the data of searching, clicking, buying additionally and buying commodities of the user in the application program is used as a recommendation basis in the recommending process, and because the data of searching, clicking, buying additionally and buying commodities of each user is different, the recommended commodity data obtained by each user may be different.
Taking fig. 1 as an example, first, target user search record data, target user order record data, and the target user embedding are obtained, where the target user embedding is an initial vector representation form of target user information. And then, carrying out integrated sequence data processing on target user search record data, target user order record data and the target user embedding, and inputting a Skip-gram model architecture for sample data training. When the Skip-gram model architecture is trained, a large amount of sample data is needed, however, search record data and order record data for a target user are limited, that is, the sample data for the Skip-gram model architecture training is sparse. In the embodiment of the scene, aiming at the problem of data sparseness, data expansion processing is performed on target user search record data and target user order record data. The expansion processing can be that a core word extraction model is adopted to extract the core words of the commodities of the target user search record data and the target user order record data, so that the relationship between the commodity information and the commodity name and the commodity brand is established, and one commodity information is replaced by the commodity name and the commodity brand, so that the data sequence formed by the commodity information can be directly replaced by the data sequence formed by the commodity name and the commodity brand, and the length of the data sequence can be doubled. Or, target user information may be added before each element in a data sequence formed by target user search record data and target user order record data, where the target user information refers to information of a target user corresponding to the target user search record or the target user order record. In this way, the data sequence can also be doubled in length. Through the two forms, sample data input into Skip-gram model architecture training can be expanded, so that the problem that effective embedding results cannot be output due to sparse sample data, and further commodities cannot be effectively recommended to a target user is solved.
Meanwhile, in order to more highlight the difference of commodities of different categories in the same business circle, objective function optimization is carried out when the Skip-gram model architecture is used for training. The target function of the existing Skip-gram model architecture only adopts positive sample data and randomly sampled negative sample data to carry out operation. However, the sampling form of the random sampling negative sample is a random sampling mode without any condition, that is, the negative sample is randomly sampled from the whole amount of commodities, so that when the target function operation is performed by adopting the Skip-gram model architecture of the application, and the commodity data recommendation is performed on the target user by using the output imbedding result, the difference of commodities of different categories in the same business circle cannot be highlighted. Therefore, optimization improvement is carried out on the objective function of the Skip-gram model architecture, and operations on negative samples of the same quotient circle and different from positive sample data categories are added in the objective function. For a detailed explanation of this section, see the objective function optimization related section of the first embodiment.
After the output embedding result is obtained, a user vector representing the information of the target user and an item vector representing the commodity information related to the target user are obtained respectively according to the embedding result. And determining commodity data recommended to the user according to the distance between the user vector and the item vector and the probability of the user vector and the item vector.
In the embodiment of the application, data expansion processing is performed on historical commodity data associated with target user information, that is, on the basis of the historical commodity data associated with the target user information, some data are expanded to serve as commodity data associated with the target user information, the target commodity data are determined by using the expanded commodity data, then the correlation degree between the target commodity data and the target user information is determined, and whether the target commodity data are used as recommended commodity data corresponding to the target user information is determined, so that the problem that the commodity recommending accuracy to a user is low due to insufficient historical commodity data associated with the target user information can be solved. Meanwhile, when the Skip-gram model architecture is adopted to carry out the objective function operation, the objective function is optimized. Therefore, when the method for acquiring the recommended object data is used for recommending the commodity data to the target user, the differences of commodities of different categories in the same business circle can be more highlighted. It should be noted that the application scenario is only one embodiment, and the embodiment of the application scenario is provided to facilitate understanding of the method for acquiring recommended object data of the present application, and is not used to limit the method for acquiring recommended object data of the present application.
The application provides a recommendation object data acquisition method and device, electronic equipment and a computer storage medium. The following are specific examples.
Fig. 2 is a flowchart of a method for acquiring recommended object data according to a first embodiment of the present application, where the method can be applied to a server or a client, and the method includes the following steps.
Step S201: target user information and historical object data associated with the target user information are obtained.
When obtaining recommendation object data by using the method of the present embodiment, user target information and history object data associated with the target user information are obtained first.
In practice, there are a variety of scenarios that require recommendations to the user. In order to facilitate understanding of the method of the present embodiment, the method is described by taking an application program that recommends product data to a target user as an example. Of course, the method of the embodiment is also applicable to other recommendation scenes, for example, the method may be applied to an e-market scene or an off-line shop scene for recommending commodity data or dish data to a target user, and may also be applied to a scene for recommending other item data to the target user. It is understood that the method of the present embodiment may be applied to any scene related to recommendation, and is not limited to recommending commodity data to a target user in an application program.
In this embodiment, the application program can provide a large number of products for the target user to select, where the target user may be a merchant user or an individual user who has a history of using the application program, for example, a certain merchant user has a history of purchasing products in the application program, or a certain individual user has a history of browsing products or adding products to a shopping cart in the application program.
In this application, it is assumed that there will be a large number of commodities, and a large number of up-to-date commodities will be available each day. However, the commodity data corresponding to the historical usage record of the target user in the application program is limited, or the target user cannot timely master the online information of some new commodities, so that most commodity information in the application program cannot be mastered by the target user. It is therefore necessary to recommend the commodity data of the application to the target user. When recommending commodity data to a target user, the commodity data matched with the target user information needs to be recommended to the target user, so that the association degree of the recommended commodity data and the target user is high. When recommending commodity data to a target user, the commodity data may be recommended to the target user through historical commodity data related to the target user. Therefore, it is first necessary to obtain target user information and historical object data associated with the target user information, i.e., historical commodity data associated with the target user.
As one way of obtaining the target user information and the historical object data associated with the target user information, the first historical object data searched by the target user corresponding to the target user information, the second historical object data selected by the target user and the third historical object data in the candidate shopping objects corresponding to the target user information can be obtained.
Specifically, the target user information may be information of a user to whom a product is directed when being recommended. For example, ID information of the individual user a or attribute information such as age, sex, and the like of the user a; or may be the ID information of merchant B. Of course, attribute information about the merchant such as the size of the shop of the merchant B may be used in addition to the ID information. The historical object data associated with the target user information comprises first historical object data searched by the target user, second historical object data selected by the target user and third historical object data in candidate shopping objects corresponding to the target user information. Specifically, if the current target user is user a, the first history object data searched by the target user may be search commodity data related to the commodity search of user a in the application program, the second history object data selected by the target user may be commodity data clicked by user a in the application program, and the third history object data in the candidate shopping object corresponding to the target user information may be commodity data purchased by user a in the application program. The third history object data among the candidate shopping objects corresponding to the first history object data searched by the target user, the second history object data selected by the target user and the target user information may be summarized as the history commodity data before the order placing related to the target user information.
Further, the history object data associated with the target user information may also be history object data in order information corresponding to the target user information. I.e. historical merchandise data that has been placed in association with the target user information. For example, may be merchandise data that the target user has purchased. In this embodiment, the historical commodity data before the order associated with the target user information and the historical commodity data of the order already associated with the target user information may be collectively used as the historical object data associated with the target user information.
Step S202: and performing data expansion processing on the historical object data according to the target user information and/or the attribute information corresponding to the historical object data to obtain the expanded object data.
In this embodiment, in the case where the historical object data sample associated with the target user information is sparse, the extended object data is obtained by performing data extension processing on the historical object data. And the extended object data is used as the input data of the subsequent vector prediction model, so that the result output by using the vector prediction model is ensured, and the finally obtained recommendation object data has higher correlation with the target user information.
There are various ways of performing data expansion processing on the history object data to obtain the expansion object data. As one of the modes of obtaining the data to be expanded by performing the data expansion processing on the history object data, the data to be expanded may be obtained by performing the merging processing on the history object data and the target user information.
Since the history object data associated with the target user information is obtained in step S201, it may be that the first history object data, the second history object data, or the third history object data is obtained. Therefore, after obtaining the target user information, the first history object data, the second history object data, or the third history object data, as one way to obtain the extended object data by merging the history object data and the target user information, the first history object data, the second history object data, the third history object data, and the target user information may be merged to obtain the extended object data, and here, the extended object data may refer to an extended object data sequence. In the extended object data sequence, an element at an adjacent previous position of the first history object data, an element at an adjacent previous position of the second history object data, and an element at an adjacent previous position of the third history object data are all target user information.
Specifically, the above-described method of expanding the object data sequence is exemplified as follows.
Now, a target user j enters an application program to quit the application program at a certain time to be used as a session, and the behavior data of searching for commodities, clicking commodities and additionally purchasing commodities of the target user j in a certain session are shown in the following table 1.
Generation time Behavior:
2019-09-10 10:10:01 entering an application
2019-09-10 10:12:13 Search terms: chicken meat
2019-09-10 10:13:00 Clicking: itemID: 4538928 chicken breast 3 jin pack
2019-09-10 10:13:12 Adding and purchasing: itemID: 4568473 chicken breast 10 jin
2019-09-10 10:13:30 Search terms: lute leg
2019-09-10 10:13:35 Adding and purchasing: itemID: 4568112 frozen drumstick 10 jin
2019-09-10 10:14:29 Clicking: itemID: 4583721 frozen chicken thigh
2019-09-10 10:15:00 Exiting the application
TABLE 1
The behavior data sequence of the target user j in the session can be obtained from the table as follows: chicken → chicken breast 3 jin dress → chicken breast 10 jin dress → Chinese lute leg → frozen Chinese lute leg 10 jin dress → frozen chicken thigh.
And at present, a data sequence is formed by searching commodities, clicking commodities and additionally purchasing commodities of the target user j in the session according to the action occurrence time sequence. For session data, the data sequence generated by the target user j in the session is:
sj=(lj1,lj2,…,ljn) (1)
the data sequence is called a data sequence (1), where n is the sequence length and l is the sequence lengthjnIs the historical object data associated with the information of the target user j. The data generated by the target user j in the session is referred to as positive sample data.
Because the length of the data sequence of the target user j in a session is limited, the length of the sequence is far shorter than the length of the sample data sequence required by normal training of the input Skip-gram model, namely, the data in a session is also very sparse. Here, it should be noted that, the target user j takes the process from entering the application program to exiting the application program as a session, and constructs a data sequence by using data in the session, mainly, the correlation between the commodity behavior data generated by the target user j in the process from entering the application program to exiting the application program is high.
For the case of sparse data, target user information is embedded, so that the data sequence (1) is converted into a data sequence (2), and the data sequence (2) is as follows:
sj=(uj,lj1,uj,lj2,…,uj,ljn) (2)
substituting specific commodity data in one session of the target user j into a data sequence (1), wherein the data sequence is (chicken, 3 jin of chicken breast, 10 jin of drumstick, 10 jin of frozen drumstick and frozen chicken thigh); target user information is embedded and substituted into a data sequence (2), and the data sequence becomes: (target user j, chicken, target user j, chicken breast 3 jin, target user j, chicken breast 10 jin, target user j, lute leg, target user j, frozen lute leg 10 jin, target user j, frozen chicken thigh).
The data sequence is called a data sequence (2) in which the sequence length is changed to 2n, ujFor the target user information,/jnIs the historical object data associated with the information of the target user j. Compared with the data sequence of the data sequence (1), the length of the data sequence (2) is 2 times of that of the data sequence (1), so that the data sequence (1) is correspondingly expanded, and the result of training and outputting the data sequence (2) by inputting a Skip-gram model is compared with the output result of the data sequence (1), so that the correlation degree between the obtained recommendation object data and the target user information can be improved. Therefore, the commodity data sequence is expanded through the mode, and when the Skip-gram model is used for sample data training, the problem that the correlation degree between the obtained recommendation object data and the target user information is poor due to sample data sparseness is solved.
In the above example, the way of embedding the target user information for data sequence expansion is explained in detail. In this embodiment, the history object data related to the target user information in the data series (1) is history product data related to the target user before the target user places an order, and the history object data in the target user order information may be used as the history object data related to the target user information in order to further expand the data series. In addition, the history object data in the user order information and the target user information may be separately combined. Historical object data related to target user information before ordering and historical object data in target user order information are separated, so that commodity data with different degrees of relation with the target user information are distinguished, and are recommended to target users respectively.
As another mode of obtaining the data to be expanded by performing the data expansion process on the history object data, there may be: and merging the plurality of attribute characteristics corresponding to the historical object data to obtain the extended object data. The plurality of attribute features corresponding to the historical object data comprise category data to which the historical object data belong and brand data to which the historical object data belong.
More specifically, the extended object data may be obtained by merging the plurality of attribute features corresponding to the history object data with the target user information.
The above-described method of expanding the object data is exemplified as follows.
Now, taking a certain historical object data as an example, how to combine a plurality of attribute features corresponding to the historical object data to obtain the extended object data will be described. Table 2 shows a plurality of attribute features corresponding to certain history object data, for example, a plurality of attribute features corresponding to "a brand soybean paste".
The name of the product is: soybean paste
Brand name: brand A
Specification: 100ml
TABLE 2
As can be seen from Table 2, the commodity data for "Brand A soy sauce" can be converted to a brand name and brand replacement, i.e., "soy sauce" and "Brand A". At this time, l in the data sequence (1) can be setjiUsing the name pmiAnd brand ppiInstead, the data sequence (1) is converted into:
sj=(uj,pmj1,ppj1,uj,pmj2,ppj2,…,uj,pmjn,ppjn) (3)
if the specific commodity data information in one session of the target user j is substituted into the data sequence (1), when the specific commodity data information is brand A soybean paste, brand A oyster sauce and brand B soybean paste, after the target user information is embedded, the data sequence (3) is as follows: (target user j, soy sauce, brand a, target user j, oyster sauce, brand a, target user j, thick broad-bean sauce, brand B).
I.e. injnIs replaced by pmjnAnd ppjnSuch a tuple pair. If the merchandise data does not have brand words, ppjnIt is only necessary to set it to null. In this way, the data sequence (3) is increased in length by a factor of two compared to the data sequence (1). As for the data sequence (1) which is expanded, the result of training and outputting the data sequence (3) by inputting the Skip-gram model can improve the correlation between the obtained recommendation target data and the target user information compared with the output result of the data sequence (1). Therefore, the data sequence is expanded through the method, and the problem of poor correlation between the obtained recommendation object data and the target user information caused by sample data sparseness is solved when the Skip-gram model is used for sample data training.
The data sequence (1) is a data sequence constructed by data of a target user in one session, and when data expansion is performed, a data sequence (2) and a data sequence (3) are obtained. However, the data sequence can reflect the commodity requirements of the target user in a short time, and cannot reflect the long-term commodity requirements of the target user. For a large number of commodities of the application program, the commodity data involved between different sessions of the target user has a large relevance.
Therefore, the history object data related to the information of the target user j can be extracted from the target user j for a while, and when the history object data is expanded, only the commodity data is converted into the user name and the brand, and the target user information does not need to be embedded. The data sequence obtained at this time is:
Sj=(pmj1,ppj1,pmj2,ppj2,…,pmjT,ppjT) (4)
Sjthe data sequence generated for the target user j over a period of time may reflect the long-term commodity demand of the target user j over a period of time.
The above manner of extending the data sequence relates to obtaining the attribute characteristics corresponding to the historical object data, and specifically, obtaining the attribute characteristics corresponding to the historical object data may be to obtain the attribute characteristics corresponding to the historical object data by using the historical object data as input data of an attribute characteristic prediction model, where the attribute characteristic prediction model is a model for obtaining the attribute characteristics corresponding to the historical object data according to the historical object data. For example, after obtaining historical merchandise data associated with a target user, the historical merchandise data may be input into a core word extraction model to obtain brand name information of the merchandise. Of course, other existing models or technical methods may also be used to obtain the attribute features corresponding to the historical object data.
Step S203: and obtaining target object data according to the expansion object data, and determining the correlation between the target object data and the target user information.
After the extended object data is obtained in step S202, the target object data is obtained according to the extended object data, and the correlation between the target object data and the target user information is determined.
As the target object data obtained from the extended object data, the correlation between the target object data and the target user information may be determined as follows: firstly, acquiring first target object data, second target object data and third target object data according to first history object data, second history object data and third history object data respectively; and then, respectively determining a first correlation degree between the first target object data and the target user information, a second correlation degree between the second target object data and the target user information, and a third correlation degree between the third target object data and the target user information. Since it has been elaborated that the history object data associated with the target user information may be the first history object data, the second history object data, and the third history object data in step S201, it is introduced that only the target user information is embedded as one way of data expansion processing for which the target object data is the history object data associated with the target user information, in other words, the target object data is the first target object data, the second target object data, and the third target object data, to obtain the expansion object data in step S202. Therefore, the determination of the correlation between the target object data and the target user information only needs to determine a first correlation between the first target object data and the target user information, a second correlation between the second target object data and the target user information, and a third correlation between the third target object data and the target user information, respectively.
More specifically, as the target object data obtained from the extended object data, the correlation between the target object data and the target user information is determined, which may be in the manner described below.
First, a target user information vector for vector representation of target user information is obtained, and an extended object data vector for vector representation of extended object data is obtained based on the extended object data. Then, based on the extended object data vector, a target object data vector that vector-represents the target object data is obtained. And then, determining the correlation degree between the target object data and the target user information according to the target object data vector and the target user information vector. It should be noted that, in the above scenario of recommending a product, since the extension data is a data sequence including a plurality of elements as exemplified above, each element in the extension data corresponds to a presence vector representation. For the vector of each element, the most suitable vector representation needs to be found, and then the target object data vector is obtained according to the most suitable vector representation of each element. Meanwhile, it should be noted that after the target object data vector and the target user information vector are obtained, the correlation between the target object data and the target user information is determined according to the target object data vector and the target user information vector, and determining the correlation between the target object data and the target user information may refer to calculating a distance between the target object data vector and the target user information vector, and determining the correlation between the target object data and the target user information according to the distance.
In practice, since the target user information vector and the target object data vector are obtained by training in the same vector space, the distance between the target user information vector and the target object data vector may represent the preference of the target user for the target object. And the smaller the distance between vectors, the higher the target user's preference for the target object.
Besides measuring the correlation degree by using the distance between the vectors, the correlation degree of the two vectors can be obtained by adopting the following method: and taking the target object data vector and the target user information vector as input data of a vector correlation degree prediction model to obtain the correlation degree between the target object data and the target user information, wherein the vector correlation degree prediction model is used for predicting the vector correlation degree. For example, the vector of the target user information vector and the vectors of the target recommended products may be input into the vector relevance prediction model, and the relevance between the vector of each target recommended product and the vector of the target user information vector may be obtained, and this relevance may also be understood as the probability that the user corresponding to the target user information vector performs operations such as browsing, selecting, and purchasing on the target recommended product.
Specifically, the expansion target data vector for vector representation of the expansion target data may be obtained from the expansion target data by using the expansion target data as input data of a target data vector prediction model for predicting the target data vector from the target data.
In this embodiment, an existing Skip-gram model is adopted as the object data vector prediction model. But optimization is performed on the objective function corresponding to the model, so that the output result of the model is more consistent with the scenario of the embodiment. The optimization objective function is as follows:
Figure BDA0002402573330000151
wherein,
Figure BDA0002402573330000152
representing and augmenting object dataA corresponding set of positive sample data is set,
Figure BDA0002402573330000153
representing a first set of negative sample data as opposed to the augmented object data,
Figure BDA0002402573330000154
a second set of negative sample data is represented as opposed to the augmented object data. v. oflA vector representing the correspondence of the extension object data, that is: extending the vector representation, v, of each element in the data sequencecThe term "represents a first vector corresponding to positive sample data positively correlated with the data to be expanded, and specifically may refer to v in the data to be expandedlA first vector corresponding to the positively correlated element,
Figure BDA0002402573330000156
represents a vector to which the first negative sample data corresponds,
Figure BDA0002402573330000155
and representing the vector corresponding to the second negative sample data. The first negative sample data is negative sample data corresponding to the expansion target data selected from the full-size target data, and the second negative sample data is negative sample data corresponding to the expansion target data and satisfying the same predetermined condition as the expansion target data. Satisfying the same preset condition may refer to satisfying the same preset geographical range. For example, for the commodity data, the second negative sample data may be commodity data that is not of the same category as the expanded commodity data but belongs to the same business circle as the expanded commodity data.
In a scene of recommending commodities to a user, in the embodiment, since historical behavior data of a target user for clicking, collecting, browsing and purchasing commodities in an application program for selling commodities is sparse, and meanwhile, for a certain commodity, a historical record of the certain commodity clicked, collected, browsed and purchased by the user is also sparse, when the commodity is recommended to the target user, the embodiment performs expansion based on historical commodity data associated with the target user to obtain an expanded commodity data sequence. Then, for each element in the augmented data sequence, a most appropriate vectorized representation of each element is obtained by the above-described objective function. Then, a target commodity vector is obtained based on the most appropriate vectorized representation of each element. And then, based on the target commodity vector and the target user information vector, the correlation degree between the target commodity data and the target user information can be obtained. And finally, obtaining target commodity data recommended to the user based on the correlation. For example, if user 1 previously browsed and purchased soybean paste, and chicken wings, then soybean paste, and chicken wings may be used as historical merchandise data associated with user 1, and assuming that through analysis, the soybean paste may be brand a soybean paste, the soybean paste may be brand B soybean paste, and the chicken wings may be brand C chicken wings, then the historical merchandise data may be subjected to an expansion process to obtain an expanded data sequence, that is: user 1, brand a, soybean paste; user 1, brand B, thick broad bean paste; user 1, brand C, chicken wings. Then, the most suitable vector representations of seven elements, namely user 1, brand a, brand B, brand C, soybean paste and chicken wings, can be obtained respectively based on the objective function. Specifically, various vector representations of each element may be substituted into the above-described objective function, and for each element, a vector representation at which the objective function takes a maximum value is selected as a vector representation most suitable for the element.
In the existing Skip-gram model, the objective function is only:
Figure BDA0002402573330000161
in the embodiment, the optimized objective function is added with one of the following items:
Figure BDA0002402573330000162
therefore, the result output by the optimized model can highlight the difference of commodities of different categories in a certain business circle, so that commodity data can be better recommended to the target user.
More specifically, in the present embodiment, extended object data is used as input data of the Skip-gram model, an extended object data vector for performing vector representation on the extended object data is obtained, and an optimization objective function of the Skip-gram model may be iterated as follows.
First, a first vector corresponding to the data to be extended, a first vector corresponding to first negative sample data opposed to the data to be extended, and a first vector corresponding to second negative sample data opposed to the data to be extended are obtained.
And then, obtaining a first target value according to the first vector corresponding to the expansion object data, the first vector corresponding to the first negative sample data and the first vector corresponding to the second negative sample data. And if the first target value does not meet the target value condition, obtaining a second vector corresponding to the expansion object data, a second vector corresponding to the first negative sample data and a second vector corresponding to the second negative sample data.
Then, obtaining a second target value according to a second vector corresponding to the data to be expanded, a second vector corresponding to the first negative sample data and a second vector corresponding to the second negative sample data; and if the second target value meets the target value condition, taking the second vector corresponding to the data to be expanded as the vector of the data to be expanded, otherwise, obtaining a third vector corresponding to the data to be expanded, a third vector corresponding to the first negative sample data, a third vector corresponding to the second negative sample data, and the like until the target value meeting the target value condition is obtained. In this embodiment, the condition that the target value is satisfied may mean that the iteration number reaches a preset iteration number, or that an error of output result data corresponding to the input data is within a preset error range by using a Skip-gram model. Of course, the most appropriate vector representation of each element in the extended object data sequence can be obtained by the target value condition, and thus the target object data vector is obtained. When obtaining the most suitable vector representation of each element in the expansion target data sequence, it is necessary to iterate the various vector representations of each element through the above objective function, and for each element, a vector that makes the objective function take the maximum value is selected as the most suitable vector representation of the element.
As a manner of obtaining the first target value from the first vector corresponding to the expansion target data, the first vector corresponding to the first negative sample data, and the first vector corresponding to the second negative sample data, a specific embodiment thereof is described below.
Referring to the above formula of the optimized objective function, first, a first product result of a first vector corresponding to the data to be extended and a first vector corresponding to the positive sample data positively correlated with the data to be extended is obtained, a negative value of the first product result is used as an index of a first natural exponential function, the first natural exponential function is added to a preset constant to obtain a first sum, the first sum is used as a logarithm of the first logarithmic function, and a value of the first logarithmic function is obtained
Figure BDA0002402573330000171
Meanwhile, a first product result of a first vector corresponding to the data to be expanded and a first vector corresponding to the first negative sample data is obtained, the first product result is used as an index of a second natural exponential function, the second natural exponential function is added to the preset constant to obtain a second sum value, the second sum value is used as a logarithm of the second logarithmic function, and a value of the second logarithmic function is obtained
Figure BDA0002402573330000172
Obtaining a second product result of the first vector corresponding to the data to be expanded and the first vector corresponding to the second negative sample data in a manner similar to the two manners of obtaining the value of the first logarithmic function and the value of the second logarithmic function, taking the second product result as an exponent of a third natural exponential function, adding the third natural exponential function to a preset constant to obtain a third sum value, taking the third sum value as a logarithm of the third logarithmic function, and obtaining a value of the third logarithmic function
Figure BDA0002402573330000181
Finally, the value of the first logarithmic function, the value of the second logarithmic function, and the value of the third logarithmic function are added to obtain a first target value.
And after the Skip-gram model adopts an optimization objective function to iterate, outputting an embedding result according to the input extended object data. It should be noted that the embedding result corresponds to the most appropriate vectorization representation of each element in the extended object data sequence. The output embedding result includes a target user information vector, a brand name information vector, and a brand information vector. The target user information vector can be directly used as a generated user vector, and of course, the target user information vector can also be used for selecting a target user information initial vector. And randomly selecting one brand name information vector and one brand information vector to average to serve as a generated item vector, wherein the generated item vector is a target object data vector. Of course, after generating the target object data vector, for example, after generating a target commodity vector, it may be determined in advance whether the target commodity exists in the application program, and if so, the correlation between the target commodity data and the target user information may be determined.
In the above-described manner of obtaining the target object data, all the target object data are obtained based on the history object data related to the target user. That is, the target object data is obtained based on the target user-related history object data and the target object data is obtained based on the target user-related history object data. As another embodiment of obtaining the target object data, it is also possible to obtain target object data corresponding to other user information, and use the target object data corresponding to other user information as the target object data for calculating the degree of correlation with the target user information. Of course, the elements in the extended object data sequence related to the target user information may be combined with the elements in the extended object data sequence related to other user information to obtain the target object data.
Step S204: and if the correlation meets the correlation condition, taking the target object data as the recommendation object data corresponding to the target user information.
After determining the degree of correlation between the target object data and the target user information in step S203, the target object data is used as recommended object data corresponding to the target user information according to a preset condition of the degree of correlation. The correlation degree satisfies the correlation degree condition, which may mean that a distance between vectors satisfies a preset distance threshold or a probability of the vectors satisfies a preset condition.
For example, if the correlation between the commodity vector corresponding to the "bean sauce of brand a" and the information vector of the target user j is obtained by using the extended object data vector related to the target user j and meets the correlation condition, the bean sauce of brand a can be recommended to the target user j.
If the method embodiment of recommending object data is applied to the server, after the recommending object data corresponding to the target user information is obtained, the recommending object data is provided to the client.
In the embodiment of the application, data expansion processing is performed on the historical object data associated with the target user information, that is, on the basis of the historical object data associated with the target user information, some data are expanded to serve as the object data associated with the target user information, the target object data is determined by using the expanded object data, the correlation degree between the target object data and the target user information is determined, and therefore whether the target object data is used as the recommendation object data corresponding to the target user information is determined, and therefore the problem that the accuracy of recommending the object to the user is low due to insufficient historical object data associated with the target user information can be solved. Meanwhile, as the objective function of the Skip-gram model is optimized, the difference of recommended commodities in the same business circle can be reflected better.
In the first embodiment described above, a method for acquiring recommendation target data is provided, and accordingly, the present application provides an apparatus for acquiring recommendation target data. Fig. 3 is a schematic diagram of an apparatus for acquiring recommended object data according to a second embodiment of the present application. Since the apparatus embodiments are substantially similar to the method embodiments, they are described in a relatively simple manner, and reference may be made to some of the descriptions of the method embodiments for relevant points. The device embodiments described below are merely illustrative.
A second embodiment of the present application provides an apparatus for acquiring recommended object data, which is applied to a server or a client, where the apparatus includes:
a first data obtaining unit 301, configured to obtain target user information and history object data associated with the target user information.
A second data obtaining unit 302, configured to perform data expansion processing on the historical object data according to the target user information and/or the attribute information corresponding to the historical object data, so as to obtain expanded object data.
A correlation determining unit 303, configured to obtain target object data according to the extended object data, and determine a correlation between the target object data and the target user information.
A recommended object data obtaining unit 304, configured to take the target object data as recommended object data corresponding to the target user information if the degree of correlation satisfies a degree of correlation condition.
Optionally, the second data obtaining unit is specifically configured to: and merging the historical object data and the target user information to obtain the extended object data.
Optionally, the first data obtaining unit is specifically configured to: obtaining first history object data searched by a target user corresponding to the target user information, second history object data selected by the target user and third history object data in candidate shopping objects corresponding to the target user information; the second data obtaining unit is specifically configured to: and merging the first history object data, the second history object data, the third history object data and the target user information to obtain an extended object data sequence, wherein in the extended object data sequence, an element at a position before the first history object data, an element at a position before the second history object data and an element at a position before the third history object data are all the target user information.
Optionally, the correlation determination unit is specifically configured to: respectively obtaining first target object data, second target object data and third target object data according to the first historical object data, the second historical object data and the third historical object data; respectively determining a first degree of correlation between the first target object data and the target user information, a second degree of correlation between the second target object data and the target user information, and a third degree of correlation between the third target object data and the target user information.
Optionally, the first data obtaining unit is specifically configured to: obtaining historical object data in order information corresponding to the target user information; the second data obtaining unit is specifically configured to: and merging the historical object data in the order information with the target user information.
Optionally, the second data obtaining unit is specifically configured to: and merging the plurality of attribute characteristics corresponding to the historical object data to obtain the extended object data.
Optionally, the second data obtaining unit is specifically configured to: and combining the plurality of attribute characteristics corresponding to the historical object data and the target user information to obtain the extended object data.
Optionally, the plurality of attribute features corresponding to the historical object data include category data to which the historical object data belongs and brand data to which the historical object data belongs.
Optionally, the system further comprises an attribute feature obtaining unit; and the attribute feature obtaining unit is used for obtaining the attribute features corresponding to the historical object data by taking the historical object data as input data of an attribute feature prediction model, and the attribute feature prediction model is used for obtaining the attribute features corresponding to the historical object data according to the historical object data.
Optionally, the correlation determination unit is specifically configured to: obtaining a target user information vector for vector representation of the target user information, and obtaining an extended object data vector for vector representation of the extended object data according to the extended object data; obtaining a target object data vector that vector-represents the target object data based on the augmented object data vector; and determining the correlation degree between the target object data and the target user information according to the target object data vector and the target user information vector.
Optionally, the correlation determination unit is specifically configured to: the data to be expanded is used as input data of a target data vector prediction model, and an expanded target data vector used for vector representation of the data to be expanded is obtained, wherein the target data vector prediction model is a model used for predicting a target data vector according to target data.
Optionally, the correlation determination unit is specifically configured to: obtaining a first vector corresponding to the extended object data, a first vector corresponding to first negative sample data opposite to the extended object data, and a first vector corresponding to second negative sample data opposite to the extended object data, wherein the first negative sample data is negative sample data opposite to the extended object data selected from full-size object data, and the second negative sample data satisfies the same preset condition as the extended object data and is negative sample data opposite to the extended object data; obtaining a first target value according to a first vector corresponding to the extended object data, a first vector corresponding to the first negative sample data and a first vector corresponding to the second negative sample data; if the first target value does not meet the target value condition, obtaining a second vector corresponding to the expansion object data, a second vector corresponding to the first negative sample data and a second vector corresponding to the second negative sample data; obtaining a second target value according to a second vector corresponding to the extended object data, a second vector corresponding to the first negative sample data and a second vector corresponding to the second negative sample data; and if the second target value meets a target value condition, taking a second vector corresponding to the extended object data as the extended object data vector, otherwise, obtaining a third vector corresponding to the extended object data, a third vector corresponding to the first negative sample data, a third vector corresponding to the second negative sample data, and so on until a target value meeting the target value condition is obtained.
Optionally, the correlation determination unit is specifically configured to: obtaining a first product result of a first vector corresponding to the extended object data and a first vector corresponding to positive sample data positively correlated to the extended object data, taking a negative value of the first product result as an index of a first natural exponential function, adding the first natural exponential function and a preset constant to obtain a first sum value, and taking the first sum value as a logarithm of a first logarithmic function to obtain a value of the first logarithmic function; obtaining a first product result of a first vector corresponding to the extended object data and a first vector corresponding to the first negative sample data, taking the first product result as an index of a second natural exponential function, adding the second natural exponential function and the preset constant to obtain a second sum value, and taking the second sum value as a logarithm of the second logarithmic function to obtain a value of the second logarithmic function; obtaining a second product result of the first vector corresponding to the extended object data and the first vector corresponding to the second negative sample data, taking the second product result as an index of a third natural exponential function, adding the third natural exponential function and the preset constant to obtain a third sum value, and taking the third sum value as a logarithm of a third logarithmic function to obtain a value of the third logarithmic function; and adding the value of the first logarithmic function, the value of the second logarithmic function and the value of the third logarithmic function to obtain the first target value.
Optionally, the correlation determination unit is specifically configured to: calculating a distance between the target object data vector and the target user information vector; and determining the correlation degree between the target object data and the target user information according to the distance.
Optionally, the correlation determination unit is specifically configured to: and taking the target object data vector and the target user information vector as input data of a vector correlation degree prediction model to obtain the correlation degree between the target object data and the target user information, wherein the vector correlation degree prediction model is used for predicting the vector correlation degree.
Optionally, the meeting of the same preset condition means meeting the same preset geographical range.
Optionally, if the apparatus is applied to a server, the apparatus further includes a providing unit; the providing unit is used for providing the recommendation object data corresponding to the target user information to the client.
In the embodiment of the application, data expansion processing is performed on the historical object data associated with the target user information, that is, on the basis of the historical object data associated with the target user information, some data are expanded to serve as the object data associated with the target user information, the target object data is determined by using the expanded object data, the correlation degree between the target object data and the target user information is determined, and therefore whether the target object data is used as the recommendation object data corresponding to the target user information is determined, and therefore the problem that the accuracy of recommending the object to the user is low due to insufficient historical object data associated with the target user information can be solved. Meanwhile, as the objective function of the Skip-gram model is optimized, the difference of recommended commodities in the same business circle can be reflected better.
A first embodiment of the present application provides a method for acquiring recommended object data, and a third embodiment of the present application provides an electronic device corresponding to the method of the first embodiment.
As shown in fig. 4, it shows a schematic diagram of the electronic device of the present embodiment.
The embodiment provides an electronic device, which is applied to a server or a client, and the electronic device includes: a processor 401; the memory 402 is configured to store a computer program, which is executed by the processor, and execute the method for acquiring recommended object data according to the embodiment of the first aspect.
In the embodiment of the application, data expansion processing is performed on the historical object data associated with the target user information, that is, on the basis of the historical object data associated with the target user information, some data are expanded to serve as the object data associated with the target user information, the target object data is determined by using the expanded object data, the correlation degree between the target object data and the target user information is determined, and therefore whether the target object data is used as the recommendation object data corresponding to the target user information is determined, and therefore the problem that the accuracy of recommending the object to the user is low due to insufficient historical object data associated with the target user information can be solved. Meanwhile, as the objective function of the Skip-gram model is optimized, the difference of recommended commodities in the same business circle can be reflected better.
A first embodiment of the present application provides a method for acquiring recommended object data, and a fourth embodiment of the present application provides a computer storage medium corresponding to the method of the first embodiment.
The present embodiment provides a computer storage medium, which is applied to a server or a client, where the computer storage medium stores a computer program, and the computer program is executed by a processor to execute the method for acquiring recommendation target data provided in the embodiments of the present application in the first aspect.
In the embodiment of the application, data expansion processing is performed on the historical object data associated with the target user information, that is, on the basis of the historical object data associated with the target user information, some data are expanded to serve as the object data associated with the target user information, the target object data is determined by using the expanded object data, the correlation degree between the target object data and the target user information is determined, and therefore whether the target object data is used as the recommendation object data corresponding to the target user information is determined, and therefore the problem that the accuracy of recommending the object to the user is low due to insufficient historical object data associated with the target user information can be solved. Meanwhile, as the objective function of the Skip-gram model is optimized, the difference of recommended commodities in the same business circle can be reflected better.
Although the present application has been described with reference to the preferred embodiments, it is not intended to limit the present application, and those skilled in the art can make variations and modifications without departing from the spirit and scope of the present application, therefore, the scope of the present application should be determined by the claims that follow.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory. The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
1. Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer-readable medium does not include non-transitory computer-readable storage media (non-transitory computer readable storage media), such as modulated data signals and carrier waves.
2. As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.

Claims (20)

1. A method for acquiring recommended object data is applied to a server side or a client side, and comprises the following steps:
obtaining target user information and historical object data associated with the target user information;
performing data expansion processing on the historical object data according to the target user information and/or attribute information corresponding to the historical object data to obtain expanded object data;
obtaining target object data according to the extended object data, and determining the correlation between the target object data and the target user information, including: determining the correlation degree between the target object data and the target user information according to a target user information vector for vector representation of the target user information and a target object data vector for vector representation of the target object data; wherein the target object data vector is obtained based on an extended object data vector for vector representation of the extended object data, the extended object data vector is obtained based on the extended object data and an object data vector prediction model, the object data vector prediction model is a model for predicting an object data vector from object data;
and if the relevance meets the relevance condition, taking the target object data as recommended object data corresponding to the target user information.
2. The method according to claim 1, wherein the performing data expansion processing on the historical object data according to the target user information to obtain expanded object data comprises:
and merging the historical object data and the target user information to obtain the extended object data.
3. The method of claim 2, wherein obtaining target user information and historical object data associated with the target user information comprises: obtaining first history object data searched by a target user corresponding to the target user information, second history object data selected by the target user and third history object data in candidate shopping objects corresponding to the target user information;
the merging the historical object data and the target user information to obtain the extended object data includes: and merging the first history object data, the second history object data, the third history object data and the target user information to obtain an extended object data sequence, wherein in the extended object data sequence, an element at a position before the first history object data, an element at a position before the second history object data and an element at a position before the third history object data are all the target user information.
4. The method of claim 3, wherein obtaining target object data from the augmented object data, determining a correlation between the target object data and the target user information comprises: respectively obtaining first target object data, second target object data and third target object data according to the first historical object data, the second historical object data and the third historical object data;
respectively determining a first degree of correlation between the first target object data and the target user information, a second degree of correlation between the second target object data and the target user information, and a third degree of correlation between the third target object data and the target user information.
5. The method of claim 2, wherein obtaining target user information and historical object data associated with the target user information comprises: obtaining historical object data in order information corresponding to the target user information;
the merging the historical object data and the target user information to obtain the extended object data includes: and merging the historical object data in the order information with the target user information.
6. The method according to claim 1, wherein the performing data expansion processing on the history object data according to the attribute information corresponding to the history object data to obtain expanded object data includes:
and merging the plurality of attribute characteristics corresponding to the historical object data to obtain the extended object data.
7. The method according to claim 6, wherein the merging the plurality of attribute features corresponding to the historical object data to obtain the extended object data comprises: and combining the plurality of attribute characteristics corresponding to the historical object data and the target user information to obtain the extended object data.
8. The method according to claim 6 or 7, wherein the plurality of attribute features corresponding to the historical object data comprise category data to which the historical object data belongs and brand data to which the historical object data belongs.
9. The method of claim 1, 6 or 7, further comprising: and taking the historical object data as input data of an attribute feature prediction model to obtain attribute features corresponding to the historical object data, wherein the attribute feature prediction model is used for obtaining the attribute features corresponding to the historical object data according to the historical object data.
10. The method of claim 1, wherein obtaining target object data from the augmented object data, determining a correlation between the target object data and the target user information comprises:
obtaining the target user information vector, and obtaining the extended object data vector according to the extended object data;
obtaining the target object data vector based on the augmented object data vector;
and determining the correlation degree between the target object data and the target user information according to the target object data vector and the target user information vector.
11. The method of claim 10, wherein obtaining the augmented object data vector from the augmented object data comprises: and taking the data to be expanded as input data of the target data vector prediction model to obtain the data vector to be expanded.
12. The method according to claim 11, wherein obtaining the extended object data vector using the extended object data as input data of an object data vector prediction model comprises:
obtaining a first vector corresponding to the extended object data, a first vector corresponding to first negative sample data opposite to the extended object data, and a first vector corresponding to second negative sample data opposite to the extended object data, wherein the first negative sample data is negative sample data opposite to the extended object data selected from full-size object data, and the second negative sample data satisfies the same preset condition as the extended object data and is negative sample data opposite to the extended object data;
obtaining a first target value according to a first vector corresponding to the extended object data, a first vector corresponding to the first negative sample data and a first vector corresponding to the second negative sample data;
if the first target value does not meet the target value condition, obtaining a second vector corresponding to the expansion object data, a second vector corresponding to the first negative sample data and a second vector corresponding to the second negative sample data;
obtaining a second target value according to a second vector corresponding to the extended object data, a second vector corresponding to the first negative sample data and a second vector corresponding to the second negative sample data;
and if the second target value meets a target value condition, taking a second vector corresponding to the extended object data as the extended object data vector, otherwise, obtaining a third vector corresponding to the extended object data, a third vector corresponding to the first negative sample data, a third vector corresponding to the second negative sample data, and so on until a target value meeting the target value condition is obtained.
13. The method according to claim 12, wherein obtaining the first target value according to the first vector corresponding to the expansion target data, the first vector corresponding to the first negative sample data, and the first vector corresponding to the second negative sample data comprises:
obtaining a first product result of a first vector corresponding to the extended object data and a first vector corresponding to positive sample data positively correlated to the extended object data, taking a negative value of the first product result as an index of a first natural exponential function, adding the first natural exponential function and a preset constant to obtain a first sum value, and taking the first sum value as a logarithm of a first logarithmic function to obtain a value of the first logarithmic function;
obtaining a first product result of a first vector corresponding to the extended object data and a first vector corresponding to the first negative sample data, taking the first product result as an index of a second natural exponential function, adding the second natural exponential function and the preset constant to obtain a second sum value, and taking the second sum value as a logarithm of the second logarithmic function to obtain a value of the second logarithmic function;
obtaining a second product result of the first vector corresponding to the extended object data and the first vector corresponding to the second negative sample data, taking the second product result as an index of a third natural exponential function, adding the third natural exponential function and the preset constant to obtain a third sum value, and taking the third sum value as a logarithm of a third logarithmic function to obtain a value of the third logarithmic function;
and adding the value of the first logarithmic function, the value of the second logarithmic function and the value of the third logarithmic function to obtain the first target value.
14. The method of claim 10, wherein determining the correlation between the target object data and the target user information according to the target object data vector and the target user information vector comprises:
calculating a distance between the target object data vector and the target user information vector;
and determining the correlation degree between the target object data and the target user information according to the distance.
15. The method of claim 10, wherein determining the correlation between the target object data and the target user information according to the target object data vector and the target user information vector comprises:
and taking the target object data vector and the target user information vector as input data of a vector correlation degree prediction model to obtain the correlation degree between the target object data and the target user information, wherein the vector correlation degree prediction model is used for predicting the vector correlation degree.
16. The method according to claim 12, wherein the meeting of the same preset condition is meeting the same preset geographical range.
17. The method of claim 1, wherein if the method is applied to a server, the method further comprises: and providing the recommendation object data corresponding to the target user information to a client.
18. An apparatus for acquiring data of a recommended object, which is applied to a server or a client, the apparatus comprising:
a first data obtaining unit, configured to obtain target user information and history object data associated with the target user information;
a second data obtaining unit, configured to perform data expansion processing on the historical object data according to the target user information and/or attribute information corresponding to the historical object data, so as to obtain expanded object data;
a correlation determining unit, configured to obtain target object data according to the extended object data, and determine a correlation between the target object data and the target user information; the correlation determination unit is specifically configured to: determining the correlation degree between the target object data and the target user information according to a target user information vector for vector representation of the target user information and a target object data vector for vector representation of the target object data; wherein the target object data vector is obtained based on an extended object data vector for vector representation of the extended object data, the extended object data vector is obtained based on the extended object data and an object data vector prediction model, the object data vector prediction model is a model for predicting an object data vector from object data;
and the recommended object data obtaining unit is used for taking the target object data as recommended object data corresponding to the target user information if the relevance meets a relevance condition.
19. An electronic device, applied to a server or a client, the electronic device comprising: a processor; a memory for storing a computer program for execution by the processor to perform the method of any one of claims 1 to 17.
20. A computer storage medium for a server or a client, the computer storage medium storing a computer program, the computer program being executed by a processor to perform the method of any one of claims 1 to 17.
CN202010151445.5A 2020-03-06 2020-03-06 Method and device for acquiring recommended object data and electronic equipment Active CN111475691B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010151445.5A CN111475691B (en) 2020-03-06 2020-03-06 Method and device for acquiring recommended object data and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010151445.5A CN111475691B (en) 2020-03-06 2020-03-06 Method and device for acquiring recommended object data and electronic equipment

Publications (2)

Publication Number Publication Date
CN111475691A CN111475691A (en) 2020-07-31
CN111475691B true CN111475691B (en) 2021-11-02

Family

ID=71747237

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010151445.5A Active CN111475691B (en) 2020-03-06 2020-03-06 Method and device for acquiring recommended object data and electronic equipment

Country Status (1)

Country Link
CN (1) CN111475691B (en)

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160070702A1 (en) * 2014-09-09 2016-03-10 Aivvy Inc. Method and system to enable user related content preferences intelligently on a headphone
US10664569B2 (en) * 2015-08-21 2020-05-26 Medtronic Minimed, Inc. Data analytics and generation of recommendations for controlling glycemic outcomes associated with tracked events
CN108062954B (en) * 2016-11-08 2020-12-08 科大讯飞股份有限公司 Speech recognition method and device
CN107767960A (en) * 2017-09-13 2018-03-06 温州悦康信息技术有限公司 Data processing method, device and the electronic equipment of clinical detection project
CN109241461B (en) * 2018-08-10 2020-05-22 新华三信息安全技术有限公司 User portrait construction method and device
CN109145146A (en) * 2018-09-07 2019-01-04 北京奇艺世纪科技有限公司 A kind of data object recommended method, device and electronic equipment
CN109597858B (en) * 2018-12-14 2021-09-14 拉扎斯网络科技(上海)有限公司 Merchant classification method and device and merchant recommendation method and device

Also Published As

Publication number Publication date
CN111475691A (en) 2020-07-31

Similar Documents

Publication Publication Date Title
CN107464132B (en) Similar user mining method and device and electronic equipment
US9454580B2 (en) Recommendation system with metric transformation
CN106557480B (en) Method and device for realizing query rewriting
CN110737834B (en) Recommendation method and device for business objects, storage medium and computer equipment
CN106919611B (en) Product information pushing method and device
CN110264277B (en) Data processing method and device executed by computing equipment, medium and computing equipment
CN111488385B (en) Data processing method and device based on artificial intelligence and computer equipment
CN111400507A (en) Entity matching method and device
CN108717407A (en) Entity vector determines method and device, information retrieval method and device
TW201804400A (en) Data object pushing method, device and system
CN113837842A (en) Commodity recommendation method and equipment based on user behavior data
CN110795613A (en) Commodity searching method, device and system and electronic equipment
CN111353838A (en) Method and device for automatically checking commodity category
Sharma et al. Intelligent data analysis using optimized support vector machine based data mining approach for tourism industry
CN115511546A (en) Behavior analysis method, system, equipment and readable medium for E-commerce users
CN115641179A (en) Information pushing method and device and electronic equipment
CN111475691B (en) Method and device for acquiring recommended object data and electronic equipment
CN117611232A (en) Training method of prediction model, information recommendation method, device and electronic equipment
CN113327154B (en) E-commerce user message pushing method and system based on big data
CN110874607A (en) Clustering method and device for network nodes
CN113468365B (en) Training method of image type recognition model, image retrieval method and device
CN112036176B (en) Text clustering method and device
CN115618126A (en) Search processing method, system, computer readable storage medium and computer device
CN113139127B (en) List recommendation method, system, equipment and storage medium based on zero-order learning
CN114139041B (en) Category relevance prediction network training and category relevance prediction method and device

Legal Events

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
GR01 Patent grant
GR01 Patent grant