User Portrait Generation Method, Device, Electronic Device and Readable Medium

By obtaining and analyzing the user's real-time user behavior information, and expanding the tag information in combination with the co-occurrence tag library, user portraits are quickly generated, and user portraits are solved in the existing technology, and timely capture and accurate recommendations of changes in user interests are achieved.

CN114418670BActive Publication Date: 2025-06-13BEIJING 58 INFORMATION TTECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111633769.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-28
Publication Date
2025-06-13
Estimated Expiration
2041-12-28

AI Technical Summary

Technical Problem

Existing user portrait generation methods cannot be updated quickly in real time, resulting in the inability to quickly capture changes in user interests and the inability to provide accurate and personalized recommendations.

Method used

By obtaining the real-time user behavior information generated by the user when using the application, analyzing the tag information, and obtaining extended tag information from the preset co-occurrence tag library, determining the tag information of the user's portrait, and generating the user's portrait.

Benefits of technology

It realizes the rapid generation of user portraits, can timely capture changes in user interests, provide accurate and personalized recommendations, and avoids the incomplete user portraits caused by too little real-time user behavior information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114418670B_ABST
    Figure CN114418670B_ABST
Patent Text Reader

Abstract

An embodiment of the present invention provides a method for generating a user portrait, the method comprising: obtaining real-time user behavior information generated when a user uses an application; the real-time user behavior information is user behavior information corresponding to a specified window, the specified window is used to represent a specified quantity or a specified time duration; analyzing the real-time user behavior information to obtain tag information; obtaining extended tag information of the tag information from a preset co-occurrence tag library; using the tag information and the extended tag information as tag information to be determined; determining tag information as a user portrait of the user from the tag information to be determined, and generating a user portrait of the user based on the determined tag information. The embodiment of the present invention generates a user portrait after expanding the tag information based on the co-occurrence tag library, avoiding the problem of incomplete user portraits caused by too little real-time user behavior information.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present invention relate to the field of Internet technologies, and in particular, to a method for generating a user profile, a device for generating a user profile, an electronic device, and a computer-readable medium. Background Art

[0002] A user profile is a labeled user model abstracted based on information such as a user's social attributes, living habits, and consumption behaviors. Among them, the core work of constructing a user profile is to set label information for the user, and the label information is a highly refined feature identifier analyzed from user information.

[0003] In a recommendation scenario, in order to provide more accurate personalized recommendation results for users, a user profile needs to be used. For example, through the user profile, the most needed products for the user can be screened out from a large number of candidate products, thereby reducing the user's ineffective browsing and improving the user experience.

[0004] However, existing calculation schemes for user profiles often need to use historical user information within a relatively long period of time. Therefore, when the user's interests change, it takes a relatively long time to update the user profile, resulting in the inability to quickly obtain the user's interest changes based on the user profile and also unable to make accurate recommendations for the user based on the user profile. Summary of the Invention

[0005] Embodiments of the present invention provide a method, a device, an electronic device, and a computer-readable storage medium for generating a user profile to solve the problem of being unable to generate a user profile quickly in real time.

[0006] Embodiments of the present invention disclose a method for generating a user profile, including:

[0007] Obtaining real-time user behavior information generated when a user uses an application program; the real-time user behavior information is user behavior information corresponding to a specified window, and the specified window is used to represent a specified quantity or a specified time duration;

[0008] Analyzing the real-time user behavior information to obtain label information;

[0009] Obtaining extended label information of the label information from a preset co-occurrence label library;

[0010] Regarding the label information and the extended label information as to-be-determined label information;

[0011] Determining, from the to-be-determined label information, label information serving as the user profile of the user, and generating the user profile of the user according to the determined label information.

[0012] Optionally, the specified window is generated in the following manner:

[0013] Count the number of interaction behaviors of the user each time the application is used;

[0014] Take the median of the number of interaction behaviors as the specified window.

[0015] Optionally, the specified window is generated in the following way:

[0016] Calculate the average usage duration of the user each time the application is used;

[0017] Take the average usage duration as the specified window.

[0018] Optionally, the co-occurrence tag library is generated in the following way:

[0019] Obtain the historical user behavior information generated when the user has used the application historically;

[0020] Analyze the historical user behavior information to obtain historical tag information;

[0021] For any of the historical tag information, determine the co-occurrence times of each other historical tag information that co-occurs with the historical tag information within the specified window;

[0022] Determine the total co-occurrence times of the historical tag information and all the other historical tag information;

[0023] Take the ratio of the co-occurrence times to the total co-occurrence times as the co-occurrence degree of the historical tag information and the corresponding other historical tag information;

[0024] Save the co-occurrence degree of the historical tag information and the corresponding other historical tag information into the co-occurrence tag library.

[0025] Optionally, the method further includes:

[0026] Calculate the word frequency of the tag information to be determined in the real-time user behavior information;

[0027] Calculate the inverse document frequency of the word frequency of the tag information to be determined in the historical behavior data;

[0028] Multiply the word frequency and the inverse document frequency to obtain the term frequency-inverse document frequency index of the tag information to be determined;

[0029] Adjust the weight value of the tag information to be determined according to the term frequency-inverse document frequency index.

[0030] Optionally, the method further includes:

[0031] Obtain the number of occurrences of each of the to-be-determined tags in the user behavior information;

[0032] Calculate the average number of occurrences of all the to-be-determined tags in the user behavior information;

[0033] When the number of occurrences is greater than the average number of occurrences, determine the to-be-determined tag as popular tag information; adjust the weight value of the to-be-determined tag information that is adjusted to popular tag information.

[0034] Optionally, the method further includes:

[0035] For any to-be-determined tag information, count the number of co-occurrences with other to-be-determined tag information that is greater than a preset co-occurrence degree;

[0036] When the number is less than a preset number, determine the to-be-determined tag information as abnormal tag information;

[0037] Adjust the weight value of the to-be-determined tag information that is determined as abnormal tag information.

[0038] Optionally, the adjusting the weight value of the to-be-determined tag information that is determined as abnormal tag information includes:

[0039] Determine a weight adjustment ratio according to the quantity of the real-time user behavior information;

[0040] Adjust the weight value of the to-be-determined tag information that is determined as abnormal tag information according to the weight adjustment ratio.

[0041] Optionally, the determining the tag information serving as the user profile of the user from the to-be-determined tag information includes:

[0042] Sort the to-be-determined tag information according to the weight value;

[0043] Use the to-be-determined tag information ranked before a preset number of digits as the user profile of the user.

[0044] An embodiment of the present invention also discloses a user profile generation device, including:

[0045] An acquisition module, configured to acquire real-time user behavior information generated when a user uses an application program; the real-time user behavior information is user behavior information corresponding to a specified window, and the specified window is used to represent a specified quantity or a specified time duration;

[0046] An analysis module, configured to analyze the real-time user behavior information to obtain tag information;

[0047] An expansion module for obtaining extended tag information of the tag information from a preset co-occurrence tag library;

[0048] A determination module for using the tag information and the extended tag information as tag information to be determined;

[0049] A generation module for determining, from the tag information to be determined, tag information serving as a user profile of the user, and generating a user profile of the user according to the determined tag information.

[0050] Optionally, the device further includes: a first specified window generation module for counting the number of interaction behaviors of the user each time the application program is used; taking the median of the number of interaction behaviors as the specified window.

[0051] Optionally, the device further includes: a second specified window generation module for counting the average usage duration of the user each time the application program is used; taking the average usage duration as the specified window.

[0052] Optionally, the device further includes: a co-occurrence tag library generation module for obtaining historical user behavior information generated when the user historically uses the application program; analyzing the historical user behavior information to obtain historical tag information; for any of the historical tag information, determining the co-occurrence times of each other historical tag information co-occurring with the historical tag information within the specified window; determining the total co-occurrence times of the historical tag information and all the other historical tag information; taking the ratio of the co-occurrence times to the total co-occurrence times as the co-occurrence degree of the historical tag information and the corresponding other historical tag information; saving the co-occurrence degree of the historical tag information and the corresponding other historical tag information into the co-occurrence tag library.

[0053] Optionally, the device further includes: a first weight value adjustment module for calculating the word frequency of the tag information to be determined in the real-time user behavior information; calculating the inverse document frequency of the word frequency of the tag information to be determined in the historical behavior data; multiplying the word frequency and the inverse document frequency to obtain the term frequency-inverse document frequency index of the tag information to be determined; adjusting the weight value of the tag information to be determined according to the term frequency-inverse document frequency index.

[0054] Optionally, the device further includes: a second weight value adjustment module for obtaining the number of occurrences of each of the tags to be determined in the user behavior information; calculating the average number of occurrences of all the tags to be determined in the user behavior information; when the number of occurrences is greater than the average number of occurrences, determining the tag to be determined as popular tag information; adjusting the weight value of the tag information to be determined that is determined as popular tag information.

[0055] Optionally, the device further includes: a second weight value adjustment module, configured to, for any of the to-be-determined tag information, count the number of co-occurrences between the to-be-determined tag information and other to-be-determined tag information that is greater than a preset co-occurrence degree; when the number is less than a preset number, determine the to-be-determined tag information as abnormal tag information; and adjust the weight value of the to-be-determined tag information determined as abnormal tag information.

[0056] Optionally, the second weight value adjustment module is configured to determine a weight adjustment ratio according to the quantity of the real-time user behavior information; and adjust the weight value of the to-be-determined tag information determined as abnormal tag information according to the weight adjustment ratio.

[0057] Optionally, the generation module is configured to sort the to-be-determined tag information according to the weight value of the to-be-determined tag; and use the to-be-determined tag information ranked before a preset number of digits as the user profile of the user.

[0058] An embodiment of the present invention also discloses an electronic device, including a processor, a communication interface, a memory, and a communication bus, where the processor, the communication interface, and the memory communicate with each other through the communication bus;

[0059] The memory is used for storing a computer program;

[0060] When the processor executes the program stored in the memory, the method as described in the embodiment of the present invention is implemented.

[0061] An embodiment of the present invention also discloses one or more computer-readable media, on which instructions are stored, and when executed by one or more processors, cause the processors to execute the method as described in the embodiment of the present invention.

[0062] An embodiment of the present invention also discloses a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the method as described in the embodiment of the present invention.

[0063] The embodiments of the present invention have the following advantages:

[0064] In an embodiment of the present invention, a specified window is used to represent a specified quantity or a specified time duration. The real-time user behavior information of the specified window generated when the user uses the application is obtained, and then the real-time user behavior information is analyzed to obtain tag information. Since the specified window is a relatively small specified quantity or a relatively short specified time duration, the real-time user behavior information obtained is usually less. Therefore, the extended tag information of the tag information is also obtained from a preset co-occurrence tag library, and the tag information and the extended tag information are used as the to-be-determined tag information, so as to determine the tag information serving as the user portrait of the user from the to-be-determined tag information, and generate the user portrait of the user according to the determined tag information. The embodiment of the present invention quickly generates a user portrait by obtaining the real-time user behavior information of the specified window, and moreover, will generate the user portrait after expanding the tag information based on the co-occurrence tag library, avoiding the problem of incomplete user portrait caused by too little real-time user behavior information. BRIEF DESCRIPTION OF THE DRAWINGS

[0065] Figure 1 is a flowchart of the steps of a user portrait generation method provided in an embodiment of the present invention;

[0066] Figure 2 is a schematic diagram of user portrait generation provided in an embodiment of the present invention;

[0067] Figure 3 is a structural block diagram of a user portrait generation device provided in an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0068] To make the above objects, features, and advantages of the present invention more obvious and understandable, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0069] Currently, the construction of user portraits is mainly based on a tag weight algorithm with time decay. Specifically, the tag weight algorithm obtains the associated tag information and the time corresponding to the tag information according to the user behavior information of the user's historical use of the application, then assigns an initial weight to the tag message, and reduces the weight value of the tag information according to time decay. The magnitude of the weight value corresponding to each tag information reflects the degree of the user's interest preference.

[0070] It can be seen that currently, the construction of user portraits often uses the historical user behavior information within a relatively long time range. When the user's interest changes, it takes a relatively long time to update the user portrait. Therefore, the change of the user's interest cannot be quickly captured. However, if only the historical user behavior information within a short time range is used, there will be a problem of incomplete user portrait caused by too little data information.

[0071] In view of the above problems, an embodiment of the present invention provides a user portrait generation method, which obtains short-term user behavior information to quickly capture the interest changes of users and update the user portrait in a timely manner. Moreover, considering that the amount of information of short-term user behavior information is small, the tag information of the user portrait will also be extended through a tag co-occurrence library to obtain a more accurate and complete user portrait.

[0072] Referring Figure 1 , the flowchart of the steps of a user portrait generation method provided in an embodiment of the present invention is shown, which may specifically include the following steps:

[0073] Step 102, obtain real-time user behavior information generated when the user uses the application program; the real-time user behavior information is the user behavior information corresponding to a specified window, and the specified window is used to represent a specified quantity or a specified time duration.

[0074] During the process of the user using the application program (APP, Application), for example, when the user opens the application program to access a certain service, or when the user uses the application program to chat, etc., corresponding user behavior information will be generated.

[0075] Among them, the specified window is used to represent a specified quantity or a specified time duration. For example, the specified window can be 20 or 5 minutes. Specifically, the user behavior information that is the most recent and within the specified window is the real-time user behavior information. Exemplarily, assuming that the specified window is the specified quantity 20, the real-time user behavior information is the most recent 20 pieces of user behavior information. Assuming that the specified window is the specified time duration of 5 minutes, the real-time user behavior information is the user behavior information within the most recent 5 minutes.

[0076] Of course, the above-mentioned specified window is only an example. In practice, the specified window can be set according to actual needs, as long as it can obtain real-time user behavior information in a relatively short period, and this real-time user behavior information can be used to construct a user portrait.

[0077] It should be noted that other privacy information such as the user behavior information involved in the embodiments of the present invention are all information authorized by the user or authorized by all parties.

[0078] Step 104, analyze the real-time user behavior information to obtain tag information.

[0079] Among them, the tag information is a highly refined feature identifier analyzed from the user behavior information. Based on the tag information, a user portrait can be constructed, and the user's search needs and preference fields can be reflected through the user portrait, which is represented by the tag information.

[0080] Exemplarily, application programs can run on a terminal device, such as life application programs, audio application programs, game application programs, etc. Among them, the life application programs can provide functions such as vehicle and house purchase, house sale, domestic service, leisure functions, and so on. Taking the life application program as an example, the tag information obtained by analyzing the real-time user behavior information can include [Recruitment], [Used Cars], [Pets], [Second-hand Market], [Local Business], [Real Estate], [Local Services], [Rental Housing], and so on.

[0081] Step 106: Obtain the extended tag information of the tag information from a preset co-occurrence tag library.

[0082] Step 108: Use the tag information and the extended tag information as the tag information to be determined.

[0083] Specifically, the co-occurrence tag library is a database preset for the application program, and the tag information set for the application program is stored in the co-occurrence tag library. For a certain tag information, based on the co-occurrence tag library, other tag information that co-occurs with the tag information at a certain frequency can be obtained, that is, the extended tag information.

[0084] In the embodiment of the present invention, since the obtained real-time user behavior information is the user behavior information in the specified window, there may be a situation where the user behavior information is less and the user portrait is incomplete. Therefore, the extended tag information can be obtained by expanding based on the co-occurrence tag library, and the extended tag information and the tag information are used as the tag information to be determined.

[0085] Exemplarily, assuming that the tag information obtained by analyzing the real-time user behavior information is [Recruitment], then based on this tag information, the extended tag information [Rental Housing] and [Used Cars] can be obtained from the co-occurrence tag library. Then, [Recruitment], [Rental Housing], and [Used Cars] will be used as the tag information to be determined.

[0086] Step 110: Determine the tag information that serves as the user portrait of the user from the tag information to be determined, and generate the user portrait of the user according to the determined tag information.

[0087] In the embodiment of the present invention, after obtaining the tag information to be determined, the tag information that serves as the user portrait of the user can be determined from the tag information to be determined, and the user portrait of the user can be generated according to the determined tag information. Thus, based on the user portrait, accurate recommendations can be made for the user, such as recommending recruitment information, recommending commodity information, and so on.

[0088] In the above user profile generation method, a specified window is used to represent a specified quantity or a specified time duration. Real-time user behavior information of the specified window generated when the user uses the application is obtained, and then the real-time user behavior information is analyzed to obtain tag information. Since the specified window is a relatively small specified quantity or a relatively short specified time duration, the real-time user behavior information obtained is usually less. Therefore, extended tag information of the tag information is also obtained from a preset co-occurrence tag library, and the tag information and the extended tag information are used as to-be-determined tag information, so as to determine the tag information serving as the user profile of the user from the to-be-determined tag information, and generate the user profile of the user according to the determined tag information. The embodiment of the present invention quickly generates a user profile by obtaining the real-time user behavior information of the specified window, and moreover, the tag information is extended based on the co-occurrence tag library before generating the user profile, avoiding the problem of incomplete user profiles caused by too little real-time user behavior information.

[0089] Based on the above embodiment, a variant embodiment of the above embodiment is proposed. Here, it should be noted that for the sake of brief description, only the differences from the above embodiment are described in the variant embodiment.

[0090] In an exemplary embodiment, the specified window can be generated in the following manner:

[0091] Count the number of interaction behaviors of the user each time the user uses the application;

[0092] Take the median of the number of interaction behaviors as the specified window.

[0093] In a specific implementation, in order to quickly capture changes in user interests, real-time user behavior information of the specified window is obtained to generate a short-term user profile.

[0094] In an alternative example, the number of interaction behaviors of the user each time the user uses the application can be counted, and then the median of the number of interaction behaviors is taken as the specified window. Here, one use of the application can refer to the user opening the application until closing the application. Optionally, if the application is not used continuously within a specified time, it can also be regarded as closing the application, for example, not using the application for more than half an hour.

[0095] For example, it is assumed that the number of interaction behaviors of the user each time the user uses the application is counted as 10, 20, 50, 100, 60, 40 respectively. Then the median 40 can be taken as the specified window, and the real-time user behavior information obtained can be the latest 40 pieces of user behavior information.

[0096] Optionally, the number of interaction behaviors of the user each time the user uses the application can also be counted, and then the average value of the number of interaction behaviors is taken as the specified window. The embodiment of the present invention does not need to be limited thereto.

[0097] In the above exemplary embodiment, the median of the counted number of interaction behaviors of the user using the application each time is used as the specified window. Since the median is obtained through sorting and is not affected by the two extreme values of the maximum and minimum, and in the actual process of the user using the application, in some scenarios (such as recruitment and house hunting), the user uses the application frequently. Therefore, using the median of the number of interaction behaviors as the specified window can obtain a relatively appropriate amount of real-time user behavior information to construct a user portrait, which can not only capture the change of user interest quickly and timely, but also will not fail to capture the change of user interest quickly and timely due to the excessive real-time user behavior information used to construct the user portrait.

[0098] In an exemplary embodiment, the specified window can be generated in the following manner:

[0099] Calculate the average usage duration of the user using the application each time;

[0100] Use the average usage duration as the specified window.

[0101] In an alternative example, the average usage duration of the user using the application each time can be counted, and then the average usage duration is used as the specified window. For example, assuming that the average usage duration of the user using the application each time is counted as 5 minutes, then 5 minutes is used as the specified window, and the real-time user behavior information obtained can be the user behavior information within the most recent 5 minutes.

[0102] Optionally, the average usage duration can be calculated based on the usage durations of all users using the application, or can be calculated for the usage duration of a single user using the application. The embodiments of the present invention do not need to limit this.

[0103] In the above exemplary embodiment, the average usage duration of the counted user using the application each time is used as the specified window. Since the average usage duration objectively reflects the usage time of the user using the application, using the average usage duration as the specified window can obtain a relatively appropriate amount of real-time user behavior information to construct a user portrait, which can not only capture the change of user interest quickly and timely, but also will not fail to capture the change of user interest quickly and timely due to the excessive real-time user behavior information used to construct the user portrait.

[0104] In an exemplary embodiment, the co-occurrence tag library can be generated in the following manner:

[0105] Obtain the historical user behavior information generated when the user historically used the application;

[0106] Analyze the historical user behavior information to obtain historical tag information;

[0107] For any of the historical tag information, determine the co-occurrence times of each other historical tag information that co-occurs with the historical tag information within a specified window;

[0108] Determine the total co-occurrence times of the historical tag information and all the other historical tag information;

[0109] Take the ratio of the co-occurrence times to the total co-occurrence times as the co-occurrence degree of the historical tag information and the corresponding other historical tag information;

[0110] Save the co-occurrence degree of the historical tag information and the corresponding other historical tag information into the co-occurrence tag library.

[0111] Among them, the co-occurrence degree refers to the probability that when a user interacts with a tag information A, the user interacts with tag information B within a specified window in the user behavior information. Specifically, the specified window can be a specified quantity or a specified duration. For example, the specified quantity can be 10, 20, etc., and the specified duration can be 5 minutes, 10 minutes, etc.

[0112] In the embodiments of the present invention, a large amount of historical user behavior information generated when users historically use application programs is obtained, the historical user behavior information is analyzed to obtain historical tag information, and then, for any historical tag information, determine the co-occurrence times of each other historical tag information that co-occurs with the historical tag information within a specified window, and determine the total co-occurrence times of the historical tag information and all the other historical tag information, and then the ratio of the co-occurrence times to the total co-occurrence times can be taken as the co-occurrence degree of the historical tag information and the corresponding other historical tag information, and saved into the co-occurrence tag library for later use.

[0113] Optionally, the specified window can be a specified quantity. Assuming the specified quantity is 10, the co-occurrence times can be the number of times the historical tag information and other historical tag information co-occur within 10 pieces of user behavior information; the specified window can be a specified duration. Assuming the specified duration is 5 minutes, the co-occurrence times can be the number of times the historical tag information and other historical tag information co-occur within the user behavior information within 5 minutes. Of course, the specified window can also be set to other values according to actual needs, and the embodiments of the present invention do not need to limit this.

[0114] In the embodiment of the present invention, a designated window is determined, and each other historical tag information that appears in the designated window after a certain historical tag information appears is regarded as a matching pair. For example, after tag information A appears, tag information B appears in the designated window, then tag information A and tag information B are a matching pair (A, B). The number of occurrences of the matching pair (A, B) in the designated window and the total number of occurrences of tag information A and all other tag information b in the designated window are counted. The calculation formula of the co-occurrence R (A, B) is as follows:

[0115]

[0116] Based on the above calculation formula, the co-occurrence degree of all historical tag information is calculated and stored in a storage medium as a tag co-occurrence library, so that the tag information can be expanded based on the tag co-occurrence library.

[0117] In the above exemplary embodiment, a co-occurrence tag library is constructed through massive historical user behavior information, so that when calculating the user portrait, after the current tag information is determined based on the real-time user behavior information, the extended tag information associated with the tag information can be further expanded from the tag co-occurrence library, thereby solving the problem of incomplete user portraits caused by too little user behavior information.

[0118] In an exemplary embodiment, the method may further include the following steps:

[0119] Calculate the word frequency of the tag information to be determined in the real-time user behavior information;

[0120] Calculate the inverse text word frequency of the word frequency of the tag information to be determined in the historical behavior data;

[0121] Multiplying the word frequency and the inverse text word frequency to obtain a word frequency-inverse text frequency index of the tag information to be determined;

[0122] The weight value of the tag information to be determined is adjusted according to the word frequency-inverse text frequency index.

[0123] Among them, the term frequency (TF) refers to the number of times a given word appears in a document. For example, the number of times the label information in the embodiments of this application appears in the real-time user behavior information; the Term Frequency-Inverse Document Frequency (TF-IDF) is a weighting technique used in information retrieval and text mining, which can be used to evaluate the importance of a word for a document in a document set or corpus. For example, the importance of the label information in the embodiments of this application for the user behavior information. The importance of a word increases in direct proportion to the number of times it appears in the document, but at the same time decreases in inverse proportion to the frequency of its appearance in the corpus. If a certain word is relatively rare, but it appears many times in this article, then it is very likely to reflect the characteristics of this article.

[0124] Among them, the weight value is used to characterize the importance of the label information for constructing the user portrait. In the embodiments of the present invention, for the label information to be determined, based on the term frequency of the label information to be determined in the real-time user behavior information of the specified window, and based on the historical user behavior information, the inverse document frequency of the label information to be determined is calculated. Multiplying the term frequency and the inverse document frequency can obtain the term frequency-inverse document frequency index of the label information to be determined, so that the weight value of the label to be determined can be adjusted according to the term frequency-inverse document frequency index.

[0125] Exemplarily, the term frequency-inverse document frequency indexes of the label messages to be determined can be sorted in descending order of magnitude, and the weight value of the label information to be determined corresponding to the term frequency-inverse document frequency index ranked ahead can be increased, or the weight value of the label information to be determined corresponding to the term frequency-inverse document frequency index ranked behind can be decreased.

[0126] In the above exemplary embodiment, by calculating the term frequency-inverse document frequency index of the label information to be determined to adjust the weight value of the label information to be determined, the user portrait constructed based on the label information to be determined can be made more accurate.

[0127] In an exemplary embodiment, the method may further include the following steps:

[0128] Obtain the number of occurrences of each of the labels to be determined in the user behavior information;

[0129] Calculate the average number of occurrences of all the labels to be determined in the user behavior information;

[0130] When the number of occurrences is greater than the average number of occurrences, determine the label to be determined as popular label information;

[0131] Adjust the weight value of the label information to be determined that is determined as popular label information.

[0132] In the specific implementation, after the tag information is expanded according to the co-occurrence tag library, some popular tag information will appear at the front in large quantities. If the user portrait is constructed based on the popular tag information, the user portrait is not accurate enough, so the weight value of the tag information determined as popular tag information to be determined needs to be adjusted.

[0133] Exemplarily, the number of occurrences c of each tag information to be determined in the real-time user behavior information is calculated, and the average number of occurrences avg_c of all tag information to be determined in the real-time user behavior information is calculated, wherein when c>avg_c, the tag to be determined is linearly downgraded.

[0134] In the above exemplary embodiment, adjusting the weight value of the tag information to be determined that is determined to be hot tag information can make the user portrait constructed based on the tag information to be determined more accurate.

[0135] In an exemplary embodiment, the method may further include the following steps:

[0136] For any of the to-be-determined tag information, counting the number of co-occurrences between the to-be-determined tag information and other to-be-determined tag information that are greater than a preset co-occurrence;

[0137] When the number is less than a preset number, determining the to-be-determined label information as abnormal label information;

[0138] The weight value of the to-be-determined label information determined to be abnormal label information is adjusted.

[0139] In a specific implementation, users may make mistakes when using an application. For example, a user actually wants to visit the [Recruitment] section of the application but accidentally clicks on [Used Cars]. The label information constructed based on the real-time user behavior information generated by these mistakes is abnormal label information. If a user portrait is constructed based on the abnormal label information, the user portrait is not accurate enough. Therefore, the weight value of the label information to be determined that is abnormal label information needs to be adjusted.

[0140] Exemplarily, calculate the co-occurrence degree between each piece of tag information to be determined and other pieces of tag information to be determined, and count the number of co-occurrence degrees greater than a preset co-occurrence degree. The preset co-occurrence degree can be a numerically pre-set value. If the co-occurrence degree of a certain piece of tag information to be determined is greater than the preset co-occurrence degree, it indicates that the probability of this piece of tag information to be determined co-occurring with other pieces of tag information to be determined is high. Among them, if the number of co-occurrence degrees of this piece of tag information to be determined that are greater than the preset co-occurrence degree is less than a preset number, it is very likely that this piece of tag information to be determined only accidentally has a co-occurrence degree greater than the preset co-occurrence degree with other pieces of tag information to be determined, that is, the situation where this piece of tag information to be determined co-occurs with other pieces of tag information to be determined only accidentally has a high probability, indicating that this piece of tag information to be determined may be an abnormal tag information generated from real-time user behavior information due to user misoperation. Then, de-weight this piece of tag information to be determined. Exemplarily, assume the preset number is 2. If the number of co-occurrence degrees of this piece of tag information to be determined that are greater than the preset co-occurrence degree is 1, then this piece of tag information to be determined can be determined as abnormal tag information.

[0141] In the above exemplary embodiment, adjusting the weight value of the tag information to be determined that is determined as abnormal tag information can make the user portrait constructed based on the tag information to be determined more accurate.

[0142] In an exemplary embodiment, the adjusting the weight value of the tag information to be determined that is determined as abnormal tag information may include the following steps:

[0143] Determine a weight adjustment ratio according to the quantity of the real-time user behavior information;

[0144] Adjust the weight value of the tag information to be determined that is determined as abnormal tag information according to the weight adjustment ratio.

[0145] In the embodiment of the present invention, for the tag information to be determined that is abnormal tag information, a weight adjustment ratio can be determined according to the quantity of the real-time user behavior information. For example, assume the quantity of user behavior information is N, then the weight adjustment ratio can be 1 / N. Then, the weight value of the tag information to be determined that is an abnormal tag can be adjusted according to the weight adjustment ratio.

[0146] In the above exemplary embodiment, determining the weight adjustment ratio according to the quantity of the real-time user behavior information, and thus adjusting the weight value of the tag to be determined that is abnormal tag information according to the weight adjustment ratio, can make the user portrait constructed based on the tag information to be determined more accurate.

[0147] In an exemplary embodiment, step 108, determining the tag information that serves as the user portrait of the user from the tag information to be determined, may include the following steps:

[0148] Determine the weight value of the to-be-determined tag information, and sort the to-be-determined tag information accordingly;

[0149] Use the to-be-determined tag information ranked before the preset number of digits as the user portrait of the user.

[0150] In the embodiment of the present invention, after the weight value of the to-be-determined tag information is cumulatively adjusted multiple times, sort the to-be-determined tag information according to the finally obtained weight value, and use the to-be-determined tag information ranked before the preset number of digits as the user portrait of the user and output it.

[0151] Exemplarily, assume that the weight values corresponding to the to-be-determined tag information [Recruitment], [Rental], and [Used Cars] are 50, 20, and 100 respectively. Assume that only the first two to-be-determined tag information are taken, then [Recruitment] and [Used Cars] can be output as the user portrait.

[0152] In the above exemplary embodiment, determining the tag information that serves as the user portrait of the user from the to-be-determined tag information according to the cumulatively adjusted weight value can avoid the influence of popular or abnormal tag information on the output of the user portrait, ensuring the accuracy of the user portrait.

[0153] To enable those skilled in the art to better understand the embodiments of the present invention, the following uses a specific example for illustration. Refer to Figure 2 The process of generating the user portrait in the embodiment of the present invention is described as follows: 1. Obtain user behavior information; 2. Real-time user behavior information of the specified window; 3. Obtain the tag information of the real-time user behavior information; 4. Expand the tag information based on the tag co-occurrence library; 5. Perform TF-IDF weighting on the tag information; 6. Demote the popular tags of the tag information; 7. Demote the abnormal tags of the tag information; 8. Output the user portrait.

[0154] Applying the embodiment of the present invention can solve the problem of the long time period for generating traditional user portraits. Generate tag information through the real-time user behavior information of the specified window, and then generate a user portrait based on the tag information to achieve rapid capture of changes in user interests. At the same time, considering that the real-time user behavior information of the short-term specified window is relatively small, the tag information will be further expanded through the tag co-occurrence library, having the ability to expand user interests and predict changes, and being able to capture the portrait information of users more accurately.

[0155] It should be noted that, for the method embodiments, for the sake of simple description, they are all expressed as a series of action combinations. However, those skilled in the art should know that the embodiments of the present invention are not limited by the described action sequence, because according to the embodiments of the present invention, certain steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily essential for the embodiments of the present invention.

[0156] Referring to Figure 3 , a structural block diagram of a user portrait generation device provided in an embodiment of the present invention is shown, which may specifically include the following modules:

[0157] An acquisition module 302, configured to acquire real-time user behavior information generated when a user uses an application program; the real-time user behavior information is user behavior information corresponding to a specified window, and the specified window is used to represent a specified quantity or a specified time duration;

[0158] An analysis module 304, configured to analyze the real-time user behavior information to obtain tag information;

[0159] An extension module 306, configured to obtain extended tag information of the tag information from a preset co-occurrence tag library;

[0160] A determination module 308, configured to use the tag information and the extended tag information as to-be-determined tag information;

[0161] A generation module 310, configured to determine, from the to-be-determined tag information, tag information that serves as the user portrait of the user, and generate the user portrait of the user according to the determined tag information.

[0162] In an exemplary embodiment, the device further includes: a first specified window generation module, configured to count the number of interaction behaviors of the user each time the application program is used; and take the median of the number of interaction behaviors as the specified window.

[0163] In an exemplary embodiment, the device may further include: a second specified window generation module, configured to calculate the average usage duration of the user each time the application program is used; and use the average usage duration as the specified window.

[0164] In an exemplary embodiment, the device may further include: a co-occurrence tag library generation module, configured to obtain historical user behavior information generated when the user historically uses an application; analyze the historical user behavior information to obtain historical tag information; for any of the historical tag information, determine the co-occurrence times of each other historical tag information that co-occurs with the historical tag information within a specified window; determine the total co-occurrence times of the historical tag information and all the other historical tag information; use the ratio of the co-occurrence times to the total co-occurrence times as the co-occurrence degree of the historical tag information and the corresponding other historical tag information; and save the co-occurrence degree of the historical tag information and the corresponding other historical tag information into the co-occurrence tag library.

[0165] In an exemplary embodiment, the device may further include: a first weight value adjustment module, configured to calculate the word frequency of the tag information to be determined in the real-time user behavior information; calculate the inverse document frequency of the word frequency of the tag information to be determined in the historical behavior data; multiply the word frequency and the inverse document frequency to obtain the term frequency-inverse document frequency index of the tag information to be determined; and adjust the weight value of the tag information to be determined according to the term frequency-inverse document frequency index.

[0166] In an exemplary embodiment, the device may further include: a second weight value adjustment module, configured to obtain the occurrence times of each tag information to be determined in the user behavior information; calculate the average occurrence times of all the tag information to be determined in the user behavior information; when the occurrence times are greater than the average occurrence times, determine the tag information to be determined as popular tag information; and adjust the weight value of the tag information to be determined that is determined as popular tag information.

[0167] In an exemplary embodiment, the device may further include: a second weight value adjustment module, configured to, for any tag information to be determined, count the number of co-occurrence degrees greater than a preset co-occurrence degree between the tag information to be determined and other tag information to be determined; when the number is less than a preset number, determine the tag information to be determined as abnormal tag information; and adjust the weight value of the tag information to be determined that is determined as abnormal tag information.

[0168] In an exemplary embodiment, the second weight value adjustment module is configured to determine a weight adjustment ratio according to the quantity of the real-time user behavior information; and adjust the weight value of the tag information to be determined that is determined as abnormal tag information according to the weight adjustment ratio.

[0169] In an exemplary embodiment, the generation module 310 is configured to sort the tag information to be determined according to the weight value of the tag to be determined; and use the tag information to be determined ranked before a preset number of digits as the user portrait of the user.

[0170] In summary, in the embodiments of the present invention, the specified window is used to represent a specified quantity or a specified time duration. The real-time user behavior information of the specified window generated when the user uses the application program is obtained, and then the real-time user behavior information is analyzed to obtain tag information. Since the specified window is a relatively small specified quantity or a relatively short specified time duration, the real-time user behavior information obtained is usually less. Therefore, the extended tag information of the tag information is also obtained from the preset co-occurrence tag library, and the tag information and the extended tag information are used as the to-be-determined tag information to determine the tag information of the user portrait of the user from the to-be-determined tag information, and the user portrait of the user is generated according to the determined tag information. The embodiments of the present invention quickly generate a user portrait by obtaining the real-time user behavior information of the specified window, and moreover, the tag information is extended based on the co-occurrence tag library before generating the user portrait, avoiding the problem of incomplete user portrait caused by too little real-time user behavior information.

[0171] For the device embodiments, since they are basically similar to the method embodiments, the description is relatively simple. For the relevant parts, refer to the partial description of the method embodiments.

[0172] Preferably, the embodiments of the present invention further provide an electronic device, including: a processor, a memory, and a computer program stored on the memory and executable on the processor. When the computer program is executed by the processor, it implements each process of the above-mentioned user portrait generation method embodiment and can achieve the same technical effect. To avoid repetition, it will not be elaborated here.

[0173] The embodiments of the present invention further provide a computer-readable storage medium. A computer program is stored on the computer-readable storage medium. When the computer program is executed by the processor, it implements each process of the above-mentioned user portrait generation method embodiment and can achieve the same technical effect. To avoid repetition, it will not be elaborated here. Among them, the computer-readable storage medium is, for example, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disc, etc.

[0174] The embodiments of the present invention provide a computer program product. The program product is stored in a storage medium. The program product is executed by at least one processor to implement each process of the above-mentioned user portrait generation method embodiment and can achieve the same technical effect. To avoid repetition, it will not be elaborated here.

[0175] It should be noted that in this text, the term "including", "comprising" or any other variant thereof is intended to cover non-exclusive inclusion, such that a process, method, article or device comprising a series of elements not only includes those elements but also includes other elements not expressly listed, or further includes elements inherent to such process, method, article or device. Without further limitation, an element defined by the phrase "comprising a..." does not exclude the presence of additional identical elements in the process, method, article or device comprising such element.

[0176] From the description of the above embodiments, those skilled in the art can clearly understand that the above-described method of the embodiments can be implemented by means of software plus a necessary general hardware platform. Of course, it can also be implemented by hardware, but in many cases the former is a better implementation. Based on such an understanding, the technical solution of the present invention, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions for causing a terminal (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of the present invention.

[0177] The embodiments of the present invention have been described above in conjunction with the accompanying drawings. However, the present invention is not limited to the above specific embodiments. The above specific embodiments are merely illustrative and not restrictive. Under the inspiration of the present invention, those of ordinary skill in the art can also make many forms without departing from the spirit and scope protected by the claims of the present invention, and all of them fall within the protection scope of the present invention.

[0178] Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in connection with the embodiments disclosed in the embodiments of the present invention can be implemented by electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods for each specific application to implement the described functions, but such implementation should not be considered to exceed the scope of the present invention.

[0179] Those skilled in the art can clearly understand that for the convenience and brevity of description, the specific working processes of the above-described systems, devices and units can refer to the corresponding processes in the foregoing method embodiments and will not be elaborated herein.

[0180] In the embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections to each other can be through some interfaces. The indirect couplings or communication connections of the devices or units can be in electrical, mechanical or other forms.

[0181] The units described as separate components may or may not be physically separated. The components displayed as units may or may not be physical units, that is, they can be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0182] In addition, in each embodiment of the present invention, the functional units can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit.

[0183] If the functions are implemented in the form of software function units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or part of this technical solution can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in each embodiment of the present invention. The foregoing storage medium includes: various media such as USB flash drives, mobile hard disks, ROM, RAM, magnetic disks, or optical discs that can store program codes.

[0184] The above is only the specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art within the technical scope disclosed by the present invention can easily think of changes or substitutions, which should all be covered by the protection scope of the present invention. Therefore, the protection scope of the present invention should be subject to the protection scope of the claims.

Claims

1. A method for generating a user profile, characterized in that, it includes: Obtain real-time user behavior information generated when the user uses the application; The real-time user behavior information is the user behavior information corresponding to a specified window, and the specified window is used to represent a specified quantity or a specified time duration; Analyze the real-time user behavior information to obtain tag information; Obtain extended tag information of the tag information from a preset co-occurrence tag library; Use the tag information and the extended tag information as tag information to be determined; Determine the tag information that serves as the user profile of the user from the tag information to be determined, and generate the user profile of the user according to the determined tag information; The co-occurrence tag library is generated in the following manner: Obtain historical user behavior information generated when the user historically used the application; Analyze the historical user behavior information to obtain historical tag information; For any one of the historical tag information, determine the co-occurrence times of each other historical tag information that co-occurs with the historical tag information within the specified window; Determine the total co-occurrence times of the historical tag information and all the other historical tag information; Use the ratio of the co-occurrence times to the total co-occurrence times as the co-occurrence degree of the historical tag information and the corresponding other historical tag information; Save the co-occurrence degree of the historical tag information and the corresponding other historical tag information into the co-occurrence tag library.

2. The method according to claim 1, characterized in that, The specified window is generated in the following manner: Count the number of interaction behaviors of the user each time the user uses the application; Take the median of the number of interaction behaviors as the specified window.

3. The method according to claim 1, characterized in that, The specified window is generated in the following manner: Calculate the average usage duration of the user each time the user uses the application; Use the average usage duration as the specified window.

4. The method according to claim 1, characterized in that, The method further includes: Calculate the word frequency of the tag information to be determined in the real-time user behavior information; Calculate the inverse document frequency of the word frequency of the tag information to be determined in the historical behavior data; Multiply the word frequency and the inverse document frequency to obtain the term frequency-inverse document frequency index of the tag information to be determined; Adjust the weight value of the tag information to be determined according to the term frequency-inverse document frequency index.

5. The method according to claim 1, characterized in that, The method further includes: Obtain the number of occurrences of each tag to be determined in the user behavior information; Calculate the average number of occurrences of all the tags to be determined in the user behavior information; When the number of occurrences is greater than the average number of occurrences, determine the tag to be determined as popular tag information; Adjust the weight value of the tag information to be determined that is determined as popular tag information.

6. The method according to claim 1, characterized in that, The method further includes: For any one of the tag information to be determined, count the number of other tag information to be determined whose co-occurrence degree with the tag information to be determined is greater than a preset co-occurrence degree; When the quantity is less than a preset quantity, determine the to-be-determined tag information as abnormal tag information; Adjust the weight value of the to-be-determined tag information determined as abnormal tag information.

7. The method according to claim 6, wherein, the adjusting the weight value of the to-be-determined tag information determined as abnormal tag information includes: determine a weight adjustment ratio according to the quantity of the real-time user behavior information; adjust the weight value of the to-be-determined tag information determined as abnormal tag information according to the weight adjustment ratio.

8. The method according to any one of claims 1 to 7, wherein, the determining the tag information serving as the user profile of the user from the to-be-determined tag information includes: sort the to-be-determined tag information according to the weight value of the to-be-determined tag; take the to-be-determined tag information sorted before a preset number of digits as the tag information of the user profile of the user.

9. A user profile generation device, wherein, comprising: a co-occurrence tag library generation module, configured to obtain historical user behavior information generated when the user historically uses an application program; analyze the historical user behavior information to obtain historical tag information; for any one of the historical tag information, determine the co-occurrence times of each other historical tag information co-occurring with the historical tag information within a specified window; determine the total co-occurrence times of the historical tag information and all the other historical tag information; take the ratio of the co-occurrence times to the total co-occurrence times as the co-occurrence degree of the historical tag information and the corresponding other historical tag information; save the co-occurrence degree of the historical tag information and the corresponding other historical tag information into the co-occurrence tag library; an acquisition module, configured to acquire real-time user behavior information generated when the user uses an application program; the real-time user behavior information is user behavior information corresponding to a specified window, and the specified window is used to represent a specified quantity or a specified time duration; an analysis module, configured to analyze the real-time user behavior information to obtain tag information; an extension module, configured to obtain extended tag information of the tag information from a preset co-occurrence tag library; a determination module, configured to use the tag information and the extended tag information as to-be-determined tag information; a generation module, configured to determine the tag information serving as the user profile of the user from the to-be-determined tag information, and generate the user profile of the user according to the determined tag information.

10. An electronic device, wherein, comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; the memory is used for storing a computer program; when the processor executes the program stored on the memory, the method according to any one of claims 1-8 is implemented.

11. One or more computer-readable media, on which instructions are stored, which when executed by one or more processors, cause the processors to execute the method according to any one of claims 1-8.

Citation Information

Patent Citations

  • Big-data-based method and system for establishing and analyzing e-commerce user portrait of mobile terminal

    CN108021929A

  • Method and device for portraying user portrait, medium and calculating equipment

    CN108154401A