Method and apparatus for generating user tags
By acquiring popular content from the data platform, extracting contextual information from existing user tags, and performing data analysis, high-quality new user tags are generated. This solves the problem of poor scalability of manually operated user tags and achieves efficient mining and quality improvement of user tags.
Patent Information
- Application Number
- CN202210101598.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-01-27
- Publication Date
- 2026-02-10
- Estimated Expiration
- 2042-01-27
AI Technical Summary
In existing technologies, the construction of user tags mainly relies on manual operation, making it difficult to discover tag content outside the knowledge system, resulting in poor scalability of user tags.
By acquiring multiple target contents with popularity values greater than a threshold from the data platform, the contextual information of the created user tags is extracted, new user tags are generated using data analysis, and high-quality new user tags are selected by combining the frequency and popularity values of candidate user tags.
It improves the efficiency and quality of user tag mining, enabling the discovery of new online terms and their conversion into new user tags, thus expanding the coverage of user tags.
Smart Images

Figure CN114443734B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of big data technology, and in particular to a method and device for generating user tags. Background Technology
[0002] User profiles are tagged user models abstracted from information such as user attributes, preferences, lifestyle habits, and behaviors. User tags are the core elements of user profiles. Taking a data sharing platform as an example, by comprehensively analyzing a user's behavioral data such as likes and favorites generated within the platform, user tags with distinctive characteristics can be identified.
[0003] Currently, in most business scenarios, user tags are mainly constructed manually. This method is limited by human experience, making it difficult to discover tag content outside the knowledge system, and the scalability of user tags is poor.
[0004] With the advent of the big data era, how to mine user tags from massive amounts of data in order to improve the accuracy of user tag mining is a problem that major data platforms urgently need to solve. Summary of the Invention
[0005] This application provides a method and apparatus for generating user tags, improving the efficiency and quality of user tag mining.
[0006] The first aspect of this application provides a method for generating user tags, including:
[0007] Retrieve multiple target contents with a popularity value greater than a threshold within a preset time period;
[0008] Determine the created user tags from the plurality of target contents, and obtain the context information of the created user tags in the plurality of target contents;
[0009] New user tags are generated by analyzing the contextual information of the created user tags within the multiple target contents.
[0010] In an optional embodiment of the first aspect of this application, obtaining multiple target contents with a popularity value greater than a threshold within a preset time period includes:
[0011] Obtain interaction statistics for the first content within the preset time period, wherein the first content is any content posted by the user;
[0012] The popularity value of the first content within the preset time period is determined based on the interaction statistics of the first content. If the popularity value of the first content is greater than the threshold, the first content is determined to be the target content.
[0013] In an optional embodiment of the first aspect of this application, the interaction statistics of the first content include at least one of the following: number of views, number of likes, number of favorites, number of reposts, and number of comments;
[0014] Determining the popularity value of the first content within the preset time period based on the interaction statistics of the first content includes:
[0015] Based on the various interaction statistics of the first content and the preset weight values of various interaction statistics, the popularity value of the first content within the preset time period is determined.
[0016] In an optional embodiment of the first aspect of this application, the plurality of target contents includes text content; the step of determining the created user tag from the plurality of target contents and obtaining the context information of the created user tag in the plurality of target contents includes:
[0017] Multiple keywords are extracted from the text content based on a text keyword detection algorithm;
[0018] If the plurality of keywords contains a target keyword that matches the created user tag, obtain the contextual information of the target keyword in the text content.
[0019] In an optional embodiment of the first aspect of this application, the plurality of target contents includes video content; the step of determining the created user tags from the plurality of target contents and obtaining the context information of the created user tags in the plurality of target contents includes:
[0020] Extract audio data from the video content, convert the audio data into first text data based on a speech recognition algorithm, and extract multiple keywords from the first text data;
[0021] If the plurality of keywords contains a target keyword that matches the created user tag, obtain the context information of the target keyword in the first text data.
[0022] In an optional embodiment of the first aspect of this application, the plurality of target contents includes image content; the step of determining the created user tag from the plurality of target contents and obtaining the context information of the created user tag in the plurality of target contents includes:
[0023] The second text data of the image content is extracted based on the text recognition algorithm. The second text data is used to indicate the text in the image.
[0024] If the second text data contains a target keyword that matches the created user tag, obtain the context information of the target keyword in the second text data.
[0025] In an optional embodiment of the first aspect of this application, the method further includes:
[0026] The semantic information of the image content is extracted based on the image recognition algorithm, and the semantic information is used to indicate the category and attributes of the target object in the image;
[0027] New user tags are generated based on the semantic information.
[0028] In an optional embodiment of the first aspect of this application, the plurality of target contents includes shareable links; the step of determining created user tags from the plurality of target contents and obtaining contextual information of the created user tags in the plurality of target contents includes:
[0029] Obtain the page content of the shared link, wherein the page content includes at least third-party text data;
[0030] If the third text data contains a target keyword that matches the created user tag, obtain the context information of the target keyword in the third text data.
[0031] In an optional embodiment of the first aspect of this application, the step of generating new user tags by performing data analysis on the contextual information of the multiple target contents of the already created user tags includes:
[0032] Obtain and parse the context information of the first user tag in the multiple target contents to generate a first candidate user tag set, wherein the first user tag is any one of the created user tags and the first candidate user tag set includes multiple candidate user tags;
[0033] Based on at least one of the frequency of occurrence of the candidate user tag in the plurality of target contents in the first candidate user tag set and the highest popularity value of the target content corresponding to the candidate user tag, a new user tag corresponding to the first user tag is determined from the first candidate user tag set.
[0034] In an optional embodiment of the first aspect of this application, determining a new user tag corresponding to the first user tag from the first candidate user tag set based on the frequency of occurrence of the candidate user tag in the plurality of target contents includes:
[0035] Select a candidate user tag from the first candidate user tag set whose frequency of occurrence is greater than a preset frequency as the new user tag corresponding to the first user tag; or
[0036] The top N most frequent candidate user tags are selected from the first set of candidate user tags as the new user tags corresponding to the first user tag, where N is a positive integer.
[0037] In an optional embodiment of the first aspect of this application, determining a new user tag corresponding to the first user tag from the first candidate user tag set based on the highest popularity value of the target content corresponding to the candidate user tag in the first candidate user tag set includes:
[0038] The top M candidate user tags with higher popularity values are selected from the first candidate user tag set as the new user tags corresponding to the first user tag, where M is a positive integer.
[0039] A second aspect of this application provides a user tag generation apparatus, comprising:
[0040] The acquisition module is used to acquire multiple target contents whose popularity value is greater than a threshold within a preset time period;
[0041] The processing module is used to determine the created user tags from the plurality of target contents and obtain the context information of the created user tags in the plurality of target contents;
[0042] New user tags are generated by analyzing the contextual information of the created user tags within the multiple target contents.
[0043] A third aspect of this application provides an electronic device, including: a memory, a processor, and a computer program; the computer program is stored in the memory and configured to be executed by the processor to implement the method as described in any one of the first aspects.
[0044] A fourth aspect of this application provides a computer-readable storage medium having a computer program stored thereon, the computer program being executed by a processor to implement the method as described in any one of the first aspects.
[0045] A fifth aspect of this application provides a computer program product, including a computer program that, when executed by a processor, implements the method described in any one of the first aspects.
[0046] This application provides a method and apparatus for generating user tags. The method includes: acquiring multiple target content items with a popularity value greater than a threshold within a preset time period; determining existing user tags from the multiple target content items; acquiring contextual information of the existing user tags within the multiple target content items; and performing data analysis on the contextual information of the existing user tags within the multiple target content items to obtain new user tags corresponding to each existing user tag. This approach mines new user tags from current trending content on a data platform based on existing user tags, learns new online terms, and converts them into new user tags, thereby improving the efficiency and quality of user tag mining. Attached Figure Description
[0047] Figure 1 A schematic diagram illustrating a scenario for the user tag generation method provided in this application embodiment;
[0048] Figure 2 A flowchart illustrating the user tag generation method provided in this application embodiment;
[0049] Figure 3 This is a schematic diagram illustrating the principle of new user tag generation provided in the embodiments of this application;
[0050] Figure 4 A flowchart illustrating the information extraction process provided in this application embodiment. Figure 1 ;
[0051] Figure 5 A flowchart illustrating the information extraction process provided in this application embodiment. Figure 2 ;
[0052] Figure 6 A flowchart illustrating the information extraction process provided in this application embodiment. Figure 3 ;
[0053] Figure 7 A flowchart illustrating the information extraction process provided in this application embodiment. Figure 4 ;
[0054] Figure 8 A schematic diagram of the structure of the user tag generation device provided in the embodiments of this application;
[0055] Figure 9 This is a hardware structure diagram of the electronic device provided in the embodiments of this application. Detailed Implementation
[0056] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0057] The terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in a sequence other than that illustrated or described herein.
[0058] It should be understood that the terms “comprising” and “having” as used herein, and any variations thereof, are intended to cover non-exclusive inclusion, for example, a process, method, system, product, or apparatus that includes a series of steps or units is not necessarily limited to those steps or units that are expressly listed, but may include other steps or units that are not expressly listed or that are inherent to such process, method, product, or apparatus.
[0059] In the description of the embodiments of this application, the term "correspondence" may indicate that there is a direct or indirect correspondence between two things, or that there is an association between two things, or that there is a relationship of instruction and being instructed, configuration and being configured, etc.
[0060] With the continuous development of the information age, network data platforms (hereinafter referred to as data platforms) are providing more and more business scenarios. Based on different business scenarios, the classification of user tags is usually different. At present, the user tag library in the data platform pre-stores some user tags that are common in some business scenarios. These user tags are usually constructed by manual operation and have certain limitations. It is difficult to discover knowledge systems in a timely manner, such as the knowledge system of e-commerce business scenarios, as well as tag content other than new online terms. The scalability of user tags is poor.
[0061] To address the aforementioned issues, this application provides a method for generating user tags. The main inventive idea is as follows: Considering that content posted by influencers or livestreamers on data platforms often enjoys a certain level of popularity and typically includes recommendations tailored to different user groups, the inventors have designed a method for expanding new user tags based on existing user tags. This involves acquiring content posted by users with a certain level of popularity on the data platform, first extracting text from the content that matches the already created user tags, obtaining the contextual information of this text, and then extracting candidate user tags from the contextual information. Each created user tag can generate a corresponding set of candidate user tags through the above content extraction process. Subsequently, by performing statistical analysis on multiple candidate user tags in the candidate user tag set, high-quality new user tags can be selected from the candidate user tag set, thereby achieving the expansion of user tags.
[0062] To facilitate understanding of the technical solution of this application, the application scenarios of the user tag generation method will be briefly introduced below.
[0063] Figure 1 This is a schematic diagram illustrating a scenario for the user tag generation method provided in an embodiment of this application. For example... Figure 1 As shown, the scenario includes a terminal device 11, a data platform (or content publishing platform) 12, and a user tag generation device 13, wherein the terminal device 11 is communicatively connected to the data platform 12, and the data platform 12 is communicatively connected to the user tag generation device 13.
[0064] Optionally, data platform 12 includes one or more databases, such as Figure 1 Two databases are shown, labeled Database 14 and Database 15. Database 14 stores content posted by users on Data Platform 12, such as shared items, recommended content, and popular science content related to relevant knowledge. Database 15 stores created user tags, which are generally manually defined by operations personnel based on various business scenarios on Data Platform 12. Database 15 is also known as the user tag library.
[0065] As an example, a user accesses the data platform 12 through terminal device 11, for instance, by uploading and sharing content, or by querying or downloading content shared by other users. Users in this example include ordinary users, verified experts, or livestreamers. For example, shopping experts recommend products through data platform 12, fashion experts share fashion outfits through data platform 12, and knowledge experts distribute knowledge lists in their professional fields through data platform 12.
[0066] As an example, the user tag generation device 13 can obtain the created user tags from the database 15 of the data platform 12 and store them in the local storage space for the mining of new user tags.
[0067] As an example, the user tag generation device 13 retrieves shared content posted by users on the data platform 12, especially trending shared content, from the database 14 of the data platform 12. Based on the created user tags, the user tag generation device 13 extracts the context information of the created user tags from the shared content and mines new user tags from the context information.
[0068] As an example, the data platform 12 can update the user tag library 15 in real time or periodically based on the update messages from the user tag generation device 13.
[0069] Optionally, the data platform 12 also includes a data processing device 16, which is used to determine the sharing content of the data platform 12 that has a certain popularity within a preset time period.
[0070] It should be noted that the data platform 12 in the above scenario can be any data platform that can provide information sharing services, such as social platforms, short video platforms, e-commerce platforms, etc., and this application embodiment does not specifically limit it.
[0071] Optionally, in some embodiments, the user tag generation device 13 can be integrated into the data platform 12 and regarded as a functional module of the data platform 12.
[0072] It should be noted that the user tags in this embodiment can also be described as crowd tags, which refer to a group of people with similar behaviors or interests, such as wood product enthusiasts, snack lovers, office workers, etc.
[0073] Based on the above scenario, the technical solutions provided by the embodiments of this application will be described in detail below through specific examples. It should be noted that the technical solutions provided by the embodiments of this application may include some or all of the following content. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.
[0074] Figure 2 This is a flowchart illustrating a method for generating user tags according to an embodiment of this application. The method provided in this embodiment is applicable to... Figure 1 The user tag generation device shown is, for example Figure 2 As shown, the user tag generation method in this embodiment includes:
[0075] Step 201: Obtain multiple target contents whose popularity value is greater than the threshold within a preset time period.
[0076] In one optional embodiment of this invention, the user tag generation device obtains content with a certain level of popularity posted by users within a preset time period from the data platform, and uses this content as the target content. The preset time period can be reasonably set according to actual needs, such as the past month or the past week; this embodiment does not impose any restrictions on this.
[0077] It's important to note that the target content can be shared content (or recommended content, learning content, etc.) posted by ordinary users on the data platform, or it can be shared content posted by popular streamers or influencers on the data platform (e.g., high number of followers, high interaction frequency). Understandably, a single share from an ordinary user may also have high popularity within a certain period. Target content can be among the most popular recently posted content, or it can be shared content posted at any time, such as content posted six months ago that has consistently maintained high popularity. In other words, as long as the shared content has a certain level of popularity within the preset time period, such as a popularity value exceeding a threshold, it can be identified as target content.
[0078] The following explains how to calculate the popularity value of user-posted content on the data platform.
[0079] It should be noted that the entity performing the heat value calculation process can be... Figure 1 The data processing device 16 of the data platform 12 shown. For ease of understanding, the following explanation uses the first content as an example, where the first content is any content published on the data platform.
[0080] Specifically, the data processing device of the data platform first obtains the interaction statistics of the first content within a preset time period, determines the popularity value of the first content within the preset time period based on the interaction statistics of the first content, and if the popularity value of the first content is greater than the threshold, then the first content is taken as the target content, that is, the first content is determined as the target content.
[0081] Optionally, the interaction statistics for the first content may include at least one of the following: number of views, number of likes, number of favorites, number of shares, and number of comments.
[0082] In one optional implementation, if the interaction statistics of the first content include the number of views, the data processing device of the data platform can determine its popularity value based on the number of views of the first content within a preset time period. For example, the number of views of the first content within the preset time period can be used as its popularity value. If the number of views of the first content within the preset time period is greater than the preset number of views, the first content can be used as the target content.
[0083] In one optional implementation, if the interaction statistics of the first content include the number of likes, the data processing device of the data platform can determine its popularity value based on the number of likes for the first content within a preset time period. For example, the number of likes for the first content within the preset time period can be used as its popularity value. If the number of likes for the first content within the preset time period is greater than a preset number of likes, the first content can be used as the target content.
[0084] In one optional implementation, if the interaction statistics of the first content include the number of favorites, the data processing device of the data platform can determine its popularity value based on the number of favorites of the first content within a preset time period. For example, the number of favorites of the first content within the preset time period can be used as its popularity value. If the number of favorites of the first content within the preset time period is greater than the preset number of favorites, the first content can be used as the target content.
[0085] In one optional implementation, if the interaction statistics of the first content include the number of reposts, the data processing device of the data platform can determine its popularity value based on the number of reposts of the first content within a preset time period. For example, the number of reposts of the first content within the preset time period can be used as its popularity value. If the number of reposts of the first content within the preset time period is greater than the preset number of reposts, the first content can be used as the target content.
[0086] In one optional implementation, if the interaction statistics of the first content include the number of comments, the data processing device of the data platform can determine its popularity value based on the number of comments on the first content within a preset time period. For example, the number of comments on the first content within the preset time period can be used as its popularity value. If the number of comments on the first content within the preset time period is greater than a preset number of comments, the first content can be used as the target content.
[0087] In one optional implementation, if the interaction statistics of the first content include the aforementioned types of interaction statistics, namely, the number of views, likes, favorites, shares, and comments, the data processing device of the data platform can determine the popularity value of the first content within a preset time period based on the various interaction statistics of the first content and preset weight values of the various interaction statistics.
[0088] For example, suppose the number of views, likes, favorites, shares, and comments for the first piece of content within a preset time period are a, b, c, d, and e, respectively, where a, b, c, d, and e are all positive integers. Suppose the preset weights for the number of views, likes, favorites, shares, and comments are p1, p2, p3, p4, and p5, respectively, where p1 + p2 + p3 + p4 + p5 = 1. The popularity value r of the first piece of content within the preset time period can be expressed as r = a × p1 + b × p2 + c × p3 + d × p4 + e × p5.
[0089] It should be noted that the above calculation of the popularity value of the first content is only an example. The popularity value can also be determined by any combination of the interaction statistics of the first content, such as the combination of the number of views and the number of likes, the combination of the number of favorites and the number of reposts, etc. This application embodiment does not limit this in any way.
[0090] Optionally, in some embodiments, the data processing device of the data platform may only acquire content published by users on the data platform within a preset time period, calculate the popularity value of all published content during that time period, and thus determine the target content with a high popularity value. It is evident that the target content with a high statistical popularity value is recently published content on the data platform. This embodiment reduces the computational load on the data processing device of the data platform. Because it only performs popularity value statistics on recently published content, it can obtain the latest content published by users, which is more conducive to the mining of user tags.
[0091] Step 202: Identify the created user tags from multiple target contents and obtain the context information of the created user tags in multiple target contents.
[0092] In this embodiment, the target content includes at least one of the following: text content, video content, audio content, image content, and shareable links. Regardless of the type of content, target data matching existing user tags can typically be extracted from its content. Based on the position of this target data within the target content, contextual information of the target data is further extracted from the target content. This contextual information may contain exploitable user tags. The contextual information includes information preceding and following the target data. It should be noted that target data matching existing user tags can be understood as target data whose similarity to existing user tags is greater than a preset similarity threshold; the target data can be considered as existing user tags.
[0093] Multiple target contents may contain the same or different created user tags, or contain the same or different data similar to created user tags.
[0094] For example, multiple target contents include target contents 1, 2, and 3. Target content 1 contains user tag a and user tag b, target content 2 contains user tag b and user tag c, and target content 3 contains user tag a and user tag d. It can be seen that target content 1 and target content 3 both contain user tag a, target content 1 and target content 2 both contain user tag b, and target content 2 and target content 3 contain different user tags.
[0095] Step 203: Generate new user tags by performing data analysis on the contextual information of the created user tags in multiple target contents.
[0096] Since the context information is obtained from multiple target contents based on the created user tags, and the created user tags contained in different target contents are different, when performing data analysis on the context information of multiple target contents, it is necessary to obtain the context information of the created user tag in all target contents based on the same created user tag, and then mine the new user tags corresponding to the created user tag based on the context information of the created user tag in all target contents.
[0097] For example, based on the example in step 202, four types of created user tags are obtained from multiple target contents: user tags a, b, c, and d. Taking user tag a as an example, the context information of user tag a in target content 1 and target content 3 is obtained. Based on the context information of user tag a in target content 1 and target content 3, new user tags corresponding to user tag a are mined. Similarly, new user tags corresponding to user tags b, c, and d can be mined.
[0098] The generation principle of new user tags will be explained below with reference to the accompanying diagram. Figure 3 This is a schematic diagram illustrating the principle of new user tag generation provided in an embodiment of this application. Figure 3 As shown, the trending content shared by users A, B, and C all contains the created user tag "office worker" or similar descriptions such as "salary worker" or "salary-earning youth." We extract the preceding context information (preA) and following context information (suffixA) for "office worker" in user A's trending content, the preceding context information (preB) and following context information (suffixB) for "salary-earning youth" in user B's trending content, and the preceding context information (preC) and following context information (suffixC) for "salary-earning youth" in user C's trending content. New user tags are then mined based on the context information {preA, preB, preC, suffixA, suffixB, suffixC}. In this example, the new user tags are mined from the context of the created user tag "office worker" in the trending content.
[0099] The user tag generation method shown in this embodiment obtains multiple target content items with a popularity value greater than a threshold within a preset time period, identifies existing user tags from these target content items, acquires the contextual information of the existing user tags within the multiple target content items, and performs data analysis on the contextual information of the existing user tags within the multiple target content items to obtain new user tags corresponding to each existing user tag. The above scheme mines new user tags from current trending content on a data platform based on existing user tags, learns new online terms, and converts them into new user tags, thereby improving the efficiency and quality of user tag mining.
[0100] Based on the above embodiments, the following will illustrate the information extraction process for different types of target content through several specific embodiments.
[0101] Figure 4 A flowchart illustrating the information extraction process provided in this application embodiment. Figure 1 In this embodiment, the target content includes text content, that is, the plain text content on the sharing page. For example... Figure 4 As shown, the information extraction process in this embodiment includes:
[0102] Step 401: Extract multiple keywords from the text content based on the text keyword detection algorithm.
[0103] This embodiment can use any existing text keyword detection algorithm for text keyword extraction, such as the TF-IDF algorithm, TextRank algorithm, etc., and this application embodiment does not impose any restrictions on it.
[0104] Step 402: Determine if there are any target keywords among the multiple keywords that match the user tags that have been created.
[0105] Specifically, based on the user tag library, it is determined whether there are target keywords among multiple keywords that match the user tags that have been created.
[0106] In one optional implementation, the similarity between a keyword and an existing user tag can be calculated to determine whether a keyword matches an existing user tag. If the similarity between a keyword and an existing user tag is greater than or equal to a preset similarity threshold, then the keyword is determined to match the existing user tag, and the keyword can be considered as an existing user tag. If the similarity between a keyword and an existing user tag is less than the preset similarity threshold, then the keyword is determined not to match the existing user tag.
[0107] Step 403: If multiple keywords contain target keywords that match the created user tags, obtain the contextual information of the target keywords in the text content.
[0108] Step 404: Obtain candidate user tags from the context information of the target keywords in the text content.
[0109] The number of target keywords identified from the text content that match the created user tags may be 0 or greater than or equal to 1.
[0110] If there is only one target keyword, other keywords are obtained from the context of that target keyword in the text content as candidate user tags. If there are multiple target keywords, other keywords corresponding to each target keyword are obtained from the context of each target keyword in the text content as candidate user tags.
[0111] Figure 5 A flowchart illustrating the information extraction process provided in this application embodiment. Figure 2 In this embodiment, the target content includes video content. For example... Figure 5 As shown, the information extraction process in this embodiment includes:
[0112] Step 501: Extract audio data from the video content.
[0113] Step 502: Convert the audio data into first text data based on the speech recognition algorithm.
[0114] This embodiment can use any existing speech recognition algorithm to obtain the first text data corresponding to the audio data, such as the Dynamic Time Warping algorithm, the Hidden Markov Model (HMM) algorithm based on the parametric model, the Vector Quantization (VQ) algorithm based on the nonparametric model, etc. This application embodiment does not impose any restrictions on this.
[0115] Step 503: Extract multiple keywords from the first text data.
[0116] Step 504: Determine if there are any target keywords among the multiple keywords that match the user tags that have been created.
[0117] Step 505: If multiple keywords contain target keywords that match the created user tags, obtain the context information of the target keywords in the first text data.
[0118] Step 506: Obtain candidate user tags from the context information of the target keywords in the first text data.
[0119] Steps 503 to 506 in this embodiment are similar to steps 401 to 404 in the previous embodiment. Please refer to the above for details, which will not be repeated here.
[0120] Optionally, in some embodiments, the target content includes audio content, and the information extraction process can refer to steps 502 to 506.
[0121] Figure 6 A flowchart illustrating the information extraction process provided in this application embodiment. Figure 3 In this embodiment, the target content includes image content, and text information may be overlaid on the image. For example... Figure 6As shown, the information extraction process in this embodiment includes:
[0122] Step 601: Extract semantic information and second text data from the image content.
[0123] The second text data is used to indicate the text in the image. Semantic information is used to indicate the category and attributes of the target object in the image, where the target object includes items and / or people. For example, an influencer shares an article about fashion, and the sharing page includes an image showing a woman wearing a loose-fitting short-sleeved shirt, along with overlaid text descriptions such as "suitable for obese people, pregnant women, plus-size people, and people who exercise in the morning."
[0124] In one optional implementation, semantic information of the image content is extracted based on an image recognition algorithm. This embodiment can employ any existing image recognition algorithm, such as image semantic segmentation algorithms, to obtain the category and attributes of the target object in the image. For example, based on the above example, the image recognition algorithm can obtain the category (shirt) and attributes (such as color, presence or absence of a collar, collar shape, etc.) of the short-sleeved shirt in the image, as well as the attributes of the person (such as female, age group, hairstyle, weight, etc.).
[0125] In one optional implementation, second text data of the image content is extracted based on a text recognition algorithm. This embodiment may employ an OCR image text recognition algorithm to extract the second text data of the image content. For example, based on the above example, the following information can be extracted from the image's text description: "obese people," "pregnant women," "plus-size people," and "people exercising in the morning."
[0126] Step 602: If the second text data contains target keywords that match the created user tags, obtain the context information of the target keywords in the second text data.
[0127] Referring to the above embodiment, step 602 specifically includes: extracting multiple keywords from the second text data based on a text keyword detection algorithm; if the multiple keywords contain a target keyword that matches the created user tag, then obtaining the context information of the target keyword from the second text data.
[0128] Step 603: Obtain candidate user tags from the context information of the target keywords in the second text data.
[0129] In one optional implementation, candidate user tags are obtained from the second text data of the image content, and these candidate user tags are directly used as new user tags. For example, based on the example in step 601, assuming the user tag library includes existing user tags such as "obese people" and "plus-size people," information near these existing tags, such as "pregnant women" and "morning exercisers," can be used as new user tags.
[0130] In one optional implementation, candidate user tags are obtained from the second text data of the image content, and the candidate user tags are added to the candidate user tag set of the corresponding created user tags, so as to filter new user tags based on the candidate user tag set of the created user tags (the user tag filtering can be combined with the text content information extraction results in the sharing page). The specific filtering process is described later.
[0131] Step 604: Generate candidate user tags based on semantic information.
[0132] In this embodiment, the candidate user tags generated based on semantic information can be directly used as new user tags, or new user tags can be screened in conjunction with step 603.
[0133] It should be noted that steps 602 to 603 and step 604 are two independent processing procedures, which can be executed sequentially or synchronously in parallel. This embodiment does not make specific limitations on this.
[0134] Figure 7 A flowchart illustrating the information extraction process provided in this application embodiment. Figure 4 In this embodiment, the target content includes a shareable link. For example... Figure 7 As shown, the information extraction process in this embodiment includes:
[0135] Step 701: Obtain the page content of the share link. The page content must include at least third-party text data.
[0136] Step 702: If the third text data contains target keywords that match the created user tags, obtain the contextual information of the target keywords in the third text data. The information extraction from the third text data in this embodiment can be referred to... Figure 4 The embodiments shown are not described in detail here.
[0137] Step 703: Obtain candidate user tags from the context information of the target keywords in the third text data.
[0138] Optionally, in some embodiments, if the content of the shared link page also includes content such as videos, audio, and images, information extraction can be performed with reference to the above embodiments, which will not be repeated in this embodiment.
[0139] Based on the above embodiments, the following describes the process of mining new user tags from contextual information through several specific embodiments.
[0140] To facilitate understanding, the following explanation uses the first user tag as an example to illustrate how to generate a new user tag based on the contextual information of the first user tag within the target content (i.e., trending content). The first user tag can be any one of the previously created user tags.
[0141] In an optional embodiment, the context information of the first user tag in multiple target contents is obtained and parsed to generate a first candidate user tag set, which includes multiple candidate user tags. Based on the frequency of occurrence of the candidate user tags in the first candidate user tag set within the multiple target contents, a new user tag corresponding to the first user tag is determined from the first candidate user tag set. In this embodiment, the frequency of occurrence of the candidate user tags is determined by counting the number of times the candidate user tags appear in the context information of the first user tag (i.e., appear near the first user tag) in the multiple target contents. It can be understood that candidate user tags are user tags that have not yet been created.
[0142] As an example, candidate user tags that appear more frequently than a preset frequency are selected from the first set of candidate user tags as new user tags corresponding to the first user tag. The preset frequency can be reasonably set according to actual needs, and this embodiment does not impose any restrictions on it.
[0143] For example, by mining the contextual information of a created user tag 'a' from multiple target content sources, a candidate user tag set is generated. This set might include user tags 'b', 'c', and 'd', where user tags 'b', 'c', and 'd' appear near user tag 'a' 10, 1, and 8 times respectively across multiple target content sources. Assuming a preset frequency of 5, user tags 'b' and 'd' can be used as new user tags.
[0144] As an example, the top N most frequent candidate user tags are selected from the first set of candidate user tags as the new user tags corresponding to the first user tag, where N is a positive integer.
[0145] In one optional embodiment, the context information of the first user tag in multiple target contents is obtained and parsed to generate a first candidate user tag set, which includes multiple candidate user tags; based on the highest popularity value of the target content corresponding to the candidate user tag in the first candidate user tag set, a new user tag corresponding to the first user tag is determined from the first candidate user tag set.
[0146] As an example, the top M candidate user tags with higher popularity values are selected from the first candidate user tag set as the new user tags corresponding to the first user tag. Here, M is a positive integer, and M can be set reasonably according to actual needs; this embodiment does not impose any restrictions on it.
[0147] For example, suppose the target content containing the created user tag 'a' includes target content 1, 2, and 3. By extracting the context information of user tag 'a' from target content 1, candidate user tag 'b' is obtained; by extracting the context information of user tag 'a' from target content 2, candidate user tags 'd' and 'b' are obtained; and by extracting the context information of user tag 'a' from target content 3, candidate user tags 'c' and 'd' are obtained. The candidate user tag set includes user tags 'b', 'c', and 'd'. The user tags in the candidate user tag set can be sorted by user tag popularity value; for example, the top two user tags can be taken as new user tags.
[0148] The following explains how the popularity values of candidate user tags are determined: Based on the example above, for user tag b, which corresponds to two target contents, the higher of the popularity values of target contents 1 and 2 can be used as the popularity value of user tag b. Similarly, the higher of the popularity values of target contents 2 and 3 can be used as the popularity value of user tag d. The popularity value of user tag c is the popularity value of target content 3, and the popularity value of user tag d is the popularity value of target content 2. Assuming that the popularity values of the target contents from high to low are: target content 1, target content 2, target content 3, the popularity values of candidate user tags from high to low can be determined as: user tag b, user tag d, user tag c. If M is 2, then user tags b and d can be used as new user tags.
[0149] In one optional embodiment, the context information of the first user tag in multiple target contents is obtained and parsed to generate a first candidate user tag set, which includes multiple candidate user tags; based on at least one of the frequency of occurrence of the candidate user tag in the multiple target contents and the highest popularity value of the target content corresponding to the candidate user tag, a new user tag corresponding to the first user tag is determined from the first candidate user tag set.
[0150] This embodiment combines the new user tag selection principles of the two embodiments described above, which can further improve the accuracy of new user tag mining. This embodiment can solve the following two scenarios of candidate user tag selection: one is to select one from two candidate user tags that appear with the same frequency, and the other is to select one from candidate user tags that have the same popularity value.
[0151] The method for generating user tags provided in the embodiments of this application has been described above. The apparatus for generating user tags provided in the embodiments of this application will be described below.
[0152] This application embodiment can divide the user tag generation device into functional modules according to the above method embodiment. For example, each function can be divided into a separate functional module, or two or more functions can be integrated into one processing module. The integrated module can be implemented in hardware or as a software functional module.
[0153] It should be noted that the module division in this embodiment is illustrative and represents only one logical functional division. In actual implementation, other division methods may be used. The following explanation uses the division of functional modules according to their respective functions as an example.
[0154] Figure 8 This is a schematic diagram of the user tag generation apparatus provided in an embodiment of this application. Figure 8 As shown, the user tag generation device 800 provided in this embodiment includes: an acquisition module 801 and a processing module 802.
[0155] The acquisition module 801 is used to acquire multiple target contents whose popularity value is greater than a threshold within a preset time period;
[0156] Processing module 802 is used to determine the created user tags from the plurality of target contents and obtain the context information of the created user tags in the plurality of target contents;
[0157] New user tags are generated by analyzing the contextual information of the created user tags within the multiple target contents.
[0158] In an optional embodiment of this embodiment, the acquisition module 801 is used to acquire interaction statistics of the first content within the preset time period, wherein the first content is any content published by the user.
[0159] The processing module 802 is used to determine the popularity value of the first content within the preset time period based on the interaction statistics of the first content, and if the popularity value of the first content is greater than the threshold, the first content is determined to be the target content.
[0160] In one optional embodiment of this example, the interaction statistics of the first content include at least one of the following: number of views, number of likes, number of favorites, number of reposts, and number of comments.
[0161] The processing module 802 is used to determine the popularity value of the first content within the preset time period based on the various interaction statistics of the first content and the preset weight values of the various interaction statistics.
[0162] Optionally, the plurality of target contents includes text content;
[0163] In an optional embodiment of this example, the processing module 802 is used to extract multiple keywords from the text content based on a text keyword detection algorithm;
[0164] If the plurality of keywords include a target keyword that matches the created user tag, the acquisition module 801 is used to acquire the context information of the target keyword in the text content.
[0165] Optionally, the plurality of target contents includes video content;
[0166] In an optional embodiment of this example, the processing module 802 is used to extract audio data from the video content, convert the audio data into first text data based on a speech recognition algorithm, and extract multiple keywords from the first text data;
[0167] If the plurality of keywords include a target keyword that matches the created user tag, the acquisition module 801 is used to acquire the context information of the target keyword in the first text data.
[0168] Optionally, the plurality of target contents includes image content;
[0169] In an optional embodiment of this embodiment, the processing module 802 is used to extract second text data of the image content based on a text recognition algorithm, wherein the second text data is used to indicate the text in the image;
[0170] If the second text data contains a target keyword that matches the created user tag, the acquisition module 801 is used to acquire the context information of the target keyword in the second text data.
[0171] In an optional embodiment of this example, the processing module 802 is configured to:
[0172] The semantic information of the image content is extracted based on the image recognition algorithm, and the semantic information is used to indicate the category and attributes of the target object in the image;
[0173] New user tags are generated based on the semantic information.
[0174] Optionally, the plurality of target content includes share links;
[0175] In an optional embodiment of this example, the acquisition module 801 is used for:
[0176] Obtain the page content of the shared link, wherein the page content includes at least third-party text data;
[0177] If the third text data contains a target keyword that matches the created user tag, obtain the context information of the target keyword in the third text data.
[0178] In an optional embodiment of this example, the processing module 802 is configured to:
[0179] Obtain and parse the context information of the first user tag in the multiple target contents to generate a first candidate user tag set, wherein the first user tag is any one of the created user tags and the first candidate user tag set includes multiple candidate user tags;
[0180] Based on at least one of the frequency of occurrence of the candidate user tag in the plurality of target contents in the first candidate user tag set and the highest popularity value of the target content corresponding to the candidate user tag, a new user tag corresponding to the first user tag is determined from the first candidate user tag set.
[0181] In an optional embodiment of this example, the processing module 802 is configured to:
[0182] Select a candidate user tag from the first candidate user tag set whose frequency of occurrence is greater than a preset frequency as the new user tag corresponding to the first user tag; or
[0183] The top N most frequent candidate user tags are selected from the first set of candidate user tags as the new user tags corresponding to the first user tag, where N is a positive integer.
[0184] In an optional embodiment of this example, the processing module 802 is configured to:
[0185] The top M candidate user tags with higher popularity values are selected from the first candidate user tag set as the new user tags corresponding to the first user tag, where M is a positive integer.
[0186] The user tag generation device provided in this embodiment can execute the technical solutions of any of the above method embodiments, and its implementation principle and technical effect are similar, so they will not be described again here.
[0187] Figure 9 This is a hardware structure diagram of the electronic device provided in an embodiment of this application. For example... Figure 9 As shown, the electronic device 900 provided in this embodiment includes: a memory 901, a processor 902, and a computer program; the computer program is stored in the memory 901 and configured to be executed by the processor 902 to implement the technical solution of any of the above method embodiments. The implementation principle and technical effect are similar, and will not be described again here.
[0188] Optionally, the memory 901 can be either standalone or integrated with the processor 902. When the memory 901 is a device independent of the processor 902, the electronic device 900 also includes a bus 903 for connecting the memory 901 and the processor 902.
[0189] This application also provides a computer-readable storage medium storing a computer program thereon, which is executed by a processor 902 to implement the technical solutions of any of the foregoing method embodiments.
[0190] This application provides a computer program product, including a computer program, which, when executed by a processor, implements the technical solutions of any of the foregoing method embodiments.
[0191] This application also provides a chip, including: a processing module and a communication interface, wherein the processing module is capable of executing the technical solutions of any of the foregoing method embodiments.
[0192] Optionally, the chip may also include a storage module (such as a memory), which is used to store instructions, and the processing module is used to execute the instructions stored in the storage module. The execution of the instructions stored in the storage module causes the processing module to execute the technical solution of any of the foregoing method embodiments.
[0193] It should be understood that the aforementioned processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. A general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in this invention can be directly manifested as being executed by a hardware processor, or executed by a combination of hardware and software modules within the processor.
[0194] The memory may include high-speed RAM, and may also include non-volatile storage (NVM), such as at least one disk storage device, and may also be a USB flash drive, external hard drive, read-only memory, disk or optical disc, etc.
[0195] The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc. For ease of illustration, the buses shown in the accompanying drawings are not limited to a single bus or a single type of bus.
[0196] The aforementioned storage medium can be implemented from any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The storage medium can be any available medium accessible to general-purpose or special-purpose computers.
[0197] An exemplary storage medium is coupled to a processor, enabling the processor to read information from and write information to the storage medium. Alternatively, the storage medium can be an integral part of the processor. Both the processor and the storage medium can reside in an application-specific integrated circuit (ASIC). Alternatively, the processor and storage medium can exist as discrete components in an electronic device.
[0198] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
Claims
1. A method for generating user tags, characterized in that, include: Acquire multiple target content items whose popularity value exceeds a threshold within a preset time period, wherein the target content items are shared content published by users on the data platform; Determine the created user tags from the plurality of target contents, and obtain the context information of the created user tags in the plurality of target contents; Obtain and parse the context information of the first user tag in the multiple target contents to generate a first candidate user tag set, wherein the first user tag is any one of the created user tags and the first candidate user tag set includes multiple candidate user tags; Based on at least one of the frequency of occurrence of candidate user tags in the plurality of target contents in the first candidate user tag set and the highest popularity value of the target content corresponding to the candidate user tag, a new user tag corresponding to the first user tag is determined from the first candidate user tag set; The acquisition of multiple target contents with a popularity value greater than a threshold within a preset time period includes: Obtain interaction statistics for the first content within the preset time period, wherein the first content is any content posted by the user; The popularity value of the first content within the preset time period is determined based on the interaction statistics of the first content. If the popularity value of the first content is greater than the threshold, the first content is determined to be the target content.
2. The method according to claim 1, characterized in that, The interaction statistics of the first content include at least one of the following: number of views, number of likes, number of favorites, number of shares, and number of comments; Determining the popularity value of the first content within the preset time period based on the interaction statistics of the first content includes: Based on the various interaction statistics of the first content and the preset weight values of various interaction statistics, the popularity value of the first content within the preset time period is determined.
3. The method according to claim 1 or 2, characterized in that, The plurality of target contents includes text content; the step of determining the created user tags from the plurality of target contents and obtaining the context information of the created user tags in the plurality of target contents includes: Multiple keywords are extracted from the text content based on a text keyword detection algorithm; If the plurality of keywords contains a target keyword that matches the created user tag, obtain the contextual information of the target keyword in the text content.
4. The method according to claim 1 or 2, characterized in that, The plurality of target content includes video content; the step of determining created user tags from the plurality of target content and obtaining contextual information of the created user tags in the plurality of target content includes: Extract audio data from the video content, convert the audio data into first text data based on a speech recognition algorithm, and extract multiple keywords from the first text data; If the plurality of keywords contains a target keyword that matches the created user tag, obtain the context information of the target keyword in the first text data.
5. The method according to claim 1 or 2, characterized in that, The plurality of target content includes image content; the step of determining created user tags from the plurality of target content and obtaining contextual information of the created user tags in the plurality of target content includes: The second text data of the image content is extracted based on the text recognition algorithm. The second text data is used to indicate the text in the image. If the second text data contains a target keyword that matches the created user tag, obtain the context information of the target keyword in the second text data.
6. The method according to claim 5, characterized in that, The method further includes: The semantic information of the image content is extracted based on the image recognition algorithm. The semantic information is used to indicate the category and attributes of the target object in the image. New user tags are generated based on the semantic information.
7. The method according to claim 1 or 2, characterized in that, The plurality of target content includes shareable links; the step of determining created user tags from the plurality of target content and obtaining contextual information of the created user tags in the plurality of target content includes: Obtain the page content of the shared link, wherein the page content includes at least third-party text data; If the third text data contains a target keyword that matches the created user tag, obtain the context information of the target keyword in the third text data.
8. The method according to claim 1, characterized in that, Based on the frequency of occurrence of candidate user tags in the first candidate user tag set within the plurality of target contents, a new user tag corresponding to the first user tag is determined from the first candidate user tag set, including: Select a candidate user tag from the first candidate user tag set whose frequency of occurrence is greater than a preset frequency as the new user tag corresponding to the first user tag; or The top N most frequent candidate user tags are selected from the first set of candidate user tags as the new user tags corresponding to the first user tag, where N is a positive integer.
9. The method according to claim 1, characterized in that, Based on the highest popularity value of the target content corresponding to the candidate user tags in the first candidate user tag set, determine the new user tag corresponding to the first user tag from the first candidate user tag set, including: The top M candidate user tags with higher popularity values are selected from the first candidate user tag set as the new user tags corresponding to the first user tag, where M is a positive integer.
10. An electronic device, characterized in that, include: A memory, a processor, and a computer program; the computer program is stored in the memory and configured to be executed by the processor to implement the method as described in any one of claims 1-9.
Citation Information
Patent Citations
Information-processing device, control method, and program
CN106462622A
Content pushing method and device
CN106815364A
E-commerce user message pushing method and system based on big data
CN113327154A
Word vector-based similar customer group mining method
CN113704411A