Age-based content recommendation method, electronic device, medium and program product
By using a pre-trained age-labeled large model and a weighted calculation filtering method, the problems of low accuracy and high cost in existing content recommendation strategies are solved, achieving efficient and accurate age-based content recommendation, which is suitable for multimedia content filtering and recommendation.
Patent Information
- Application Number
- CN202411167096.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-23
- Publication Date
- 2026-03-03
AI Technical Summary
Existing content recommendation strategies based on age suffer from low accuracy and high cost. In particular, when dealing with underage users, traditional methods such as blocking specified keywords and manual review are inefficient, leading to false positives or incomplete screening.
A pre-trained age-labeling model is used to label media information. By combining the target user's age tag and other tag information, suitable recommended content is selected through weighted calculation or matching judgment. The efficiency and accuracy of the large model in classification tasks are used to perform age labeling and recommendation of multimedia content.
It improves the accuracy of content recommendations, reduces the workload and cost of manual review, ensures the accuracy and efficiency of the content platform, and adapts to the parent mode needs of various content platforms.
Smart Images

Figure CN121597850A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of large model technology, and in particular to an age-based content recommendation method, electronic device, computer-readable storage medium, and computer program product. Background Technology
[0002] With the rapid development of content sharing platforms and the continuous increase in user scale, the age range of users has become more diverse, with a large number of minors and even children (e.g., under 14 years old) emerging on these platforms. Therefore, some content recommendations have age restrictions, necessitating content filtering and segmentation for users of different age groups.
[0003] Currently, some short video platforms, long video platforms, and online learning platforms with parental controls typically regulate content based on the channels / tags submitted by content creators. Other solutions combine manual review and keyword analysis to determine the appropriate age range for content. However, these methods have drawbacks: blocking specific keywords or channels can result in false positives or incomplete blocking, affecting the accuracy of content recommendations; while relying on manual review to age-label media information is inefficient, requires excessive workload, and incurs high human and material costs.
[0004] The above content is only used to help understand the technical solution of this application and does not represent an admission that the above content is prior art. Summary of the Invention
[0005] The main objective of this application is to provide an age-based content recommendation method, electronic device, computer-readable storage medium, and computer program product, aiming to solve the technical problems of low accuracy and high cost in current age-based content recommendation strategies.
[0006] To achieve the above objectives, this application proposes an age-based content recommendation method, which includes:
[0007] Media information is input into a pre-trained age tagging model, and the age tagging model outputs the age label corresponding to the media information. The age tagging model is trained by training the media information and the corresponding age label.
[0008] Based on the age tags corresponding to multiple media information and the age tags of the target user, the media information is filtered to obtain the first recommended content corresponding to the target user, and content is recommended to the target user based on the first recommended content.
[0009] In one embodiment, the step of filtering each piece of media information based on age tags corresponding to multiple pieces of media information and the age tag of the target user to obtain first recommended content corresponding to the target user, and recommending content to the target user based on the first recommended content, includes:
[0010] Sequentially determine whether the age tag of each piece of media information matches the age tag of the target user;
[0011] Media information that matches the age tag of the target user is identified as the first recommended content;
[0012] Based on the target user's other tag information and the first recommended content's recommendation tags, the first recommended content is filtered to obtain the second recommended content corresponding to the target user. The other tag information includes at least one of preference information, interest circle information, and content preference information, and the recommendation tags include at least one of preference tags, interest circle tags, and content tags.
[0013] The second recommended content is pushed to the user account corresponding to the target user.
[0014] In one embodiment, the step of filtering each piece of media information based on age tags corresponding to multiple pieces of media information and the age tag of the target user to obtain the first recommended content corresponding to the target user includes:
[0015] Based on the matching between the age tags of the media information and the age tags of the target users, the corresponding age weight is determined;
[0016] The recommendation weight of the media information is calculated based on the target user's other tag information and the media information's recommendation tag. The other tag information includes at least one of the following: preference information, interest circle information, and content preference information. The recommendation tag includes at least one of the following: preference tag, interest circle tag, and content tag.
[0017] If the sum of the age weight and the recommendation weight is greater than a preset recommendation threshold, then the media information is determined as the first recommended content; or,
[0018] The media information is sorted based on the sum of the age weight and the recommendation weight to obtain the corresponding first recommended content.
[0019] In one embodiment, the step of determining the corresponding age weight based on the matching of the age tag of the media information and the age tag of the target user includes:
[0020] Determine whether the age tag of the media information matches the age tag of the target user;
[0021] If a match is found, the age tag matching value is determined to be the first preset value;
[0022] If there is no match, the age tag matching value is determined to be the second preset value, where the first preset value is greater than the second preset value;
[0023] The age weight is obtained by calculating the product of the age tag matching value and the preset age weight.
[0024] In one embodiment, the steps of the age-based content recommendation method further include:
[0025] Obtain original media information;
[0026] Remove emoticons and text formatting from the original media information, and normalize the image clarity in the original media information to obtain training media information;
[0027] Based on the training media information and the corresponding age tags, the preset initial large model is fine-tuned and trained to obtain an age-labeled large model;
[0028] During the fine-tuning training process, the initial large model updates the model parameters of the model layer adjacent to the output layer based on a preset learning rate. The preset learning rate is lower than the learning rate corresponding to the initial large model during the basic training process.
[0029] Alternatively, the initial large model updates all model parameters based on the preset learning rate during the fine-tuning training process.
[0030] In one embodiment, the training media information includes at least one of training text information, training image information, and mixed text and image information; the initial large model includes at least one of an initial text large model, an initial image large model, and an initial multimodal large model; and the age tag large model includes at least one of a target text large model, a target image large model, and a target multimodal large model.
[0031] The step of fine-tuning the preset initial large model based on the training media information and the corresponding age tags to obtain the age-labeled large model includes:
[0032] Based on the training text information and corresponding age tags, the preset initial large text model is fine-tuned to obtain the target large text model; and / or,
[0033] Based on the training image information and corresponding age tags, a preset initial image model is fine-tuned to obtain a target image model; and / or,
[0034] Based on the image and text mixed information and the corresponding age tags, the preset initial multimodal large model is fine-tuned and trained to obtain the target multimodal large model.
[0035] In one embodiment, before the step of fine-tuning the preset initial large model based on the training media information and the corresponding age tags, the method further includes:
[0036] Obtain the age label corresponding to the training media information, wherein the age label is a binary classification label, an age segmentation label, or a preset age segment label, and the preset age segment label is determined by other label information of the training media information.
[0037] In addition, to achieve the above objectives, this application also proposes an electronic device, the device comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, the computer program being configured to implement the steps of the age-based content recommendation method as described above.
[0038] In addition, to achieve the above objectives, this application also proposes a storage medium, which is a computer-readable storage medium, on which a computer program is stored, and which, when executed by a processor, implements the steps of the age-based content recommendation method described above.
[0039] In addition, to achieve the above objectives, this application also provides a computer program product, which includes a computer program that, when executed by a processor, implements the steps of the age-based content recommendation method described above.
[0040] This application proposes an age-based content recommendation method. First, media information is input into a pre-trained age-labeling model. The age-labeling model outputs the age tags corresponding to the media information. The age-labeling model is trained using the media information and corresponding age tags. Therefore, this application leverages the superior performance of continuously evolving age-labeling models in classification tasks, enabling accurate age labeling of multimedia content (such as text, images, and videos). Then, based on the age tags corresponding to multiple media pieces and the target user's age tag, each media piece is filtered to obtain the first recommended content for the target user. Content recommendations are then made to the target user based on this first recommended content. Furthermore, this application combines the target user's own age tag to filter media content suitable for the target user, improving the accuracy of age-based content recommendation. This overcomes the shortcomings of traditional content recommendation schemes, such as unclear age stratification, low accuracy, and low efficiency of manual review. It effectively reduces the workload of content platform staff, lowers classification costs, and balances the accuracy and efficiency of age classification. Moreover, it is better adapted to the parental control modes of various content platforms. Attached Figure Description
[0041] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0042] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0043] Figure 1 This is a flowchart illustrating an embodiment of the age-based content recommendation method of this application.
[0044] Figure 2 This is a schematic diagram illustrating the classification of newly uploaded multimedia files using a fine-tuned model in an embodiment of the age-based content recommendation method of this application;
[0045] Figure 3 This is a schematic diagram illustrating the process of first filtering labeled data by age and then making recommendations in an embodiment of the age-based content recommendation method of this application;
[0046] Figure 4 This is a schematic diagram illustrating the process of simultaneously filtering and recommending labeled data based on age in an embodiment of the age-based content recommendation method of this application;
[0047] Figure 5 This is a schematic diagram illustrating the fine-tuning of the base model in an embodiment of the age-based content recommendation method of this application;
[0048] Figure 6 This is a schematic diagram illustrating the updating of an old model in an embodiment of the age-based content recommendation method of this application;
[0049] Figure 7 This is a schematic diagram of the device structure of the hardware operating environment involved in the age-based content recommendation method in this application embodiment.
[0050] The purpose, features, and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0051] It should be understood that the specific embodiments described herein are merely illustrative of the technical solutions of this application and are not intended to limit this application.
[0052] To better understand the technical solution of this application, a detailed description will be provided below in conjunction with the accompanying drawings and specific implementation methods.
[0053] The executing entity in this embodiment can be a computing service device with data processing, network communication, and program execution functions, such as a tablet computer, personal computer, mobile phone, server, etc., or an electronic device or control device capable of performing the above functions. The following description uses a server as the executing entity to illustrate this embodiment and the subsequent embodiments.
[0054] This application provides an age-based content recommendation method, referring to... Figure 1 , Figure 1 This is a flowchart illustrating the first embodiment of the age-based content recommendation method of this application. The age-based content recommendation method includes:
[0055] Step S10: Input the media information into the pre-trained age tagging model, and output the age tag corresponding to the media information through the age tagging model. The age tagging model is obtained by training the large model with the media information and the corresponding age tag.
[0056] It should be noted that the age-based content recommendation method in this application can be applied to the pre-screening process of media information uploaded by content creators, or to the process of filtering a certain amount of media information using conventional recommendation methods and then further filtering it based on age tags. It can also be combined with existing conventional recommendation methods to screen and recommend media uploaded by content creators. The age tag is used to characterize the appropriate age range for the media information, and can use broad intervals such as teenagers, young adults, middle-aged, and elderly, or can be further segmented according to actual needs.
[0057] It should be noted that before age tagging, the data corresponding to the media information should be cleaned and preprocessed, such as removing special expressions (or encoding and converting emojis), deleting text indentation, and unifying image clarity, to facilitate the recognition and understanding of the large age tagging model.
[0058] The media information is multimedia information, which can be one of the following: text information, image information, mixed text and image information, and video information. The pre-trained age tagging model also includes models with multiple dimensions, which are used to process text information, image information, mixed text and image information, and video information to obtain the age tag corresponding to the media information. Specifically, the age tag is used to represent which age groups of users are suitable to watch the media information, and there can be overlap between different age groups, such as under 10 years old, 14 years old and above, 18 years old and above, etc. This classification method can not only filter media information that is not suitable for younger children, but also filter media information that children tend to prefer. For example, early childhood education videos, popular science knowledge, or children's education content suitable for children under 10 years old will not be pushed to users over 14 years old and over 18 years old, thereby achieving matching recommendation of media information with user age groups.
[0059] The age labeling big model in this application embodiment is obtained by fine-tuning and training based on existing big models. Currently, existing big models usually have content understanding capabilities and a certain natural language processing capabilities. The trained age labeling big model in this application embodiment is fine-tuned and trained on the basis of these big models to further enable it to have age labeling function and to effectively label and classify media information by age.
[0060] For example, refer to Figure 2 The trained age labeling model is a fine-tuning model. When a newly uploaded multimedia file is detected, the multimedia file is classified (labeled) by the fine-tuning model, resulting in multiple multimedia files with completed age labeling, from category 1 to category n.
[0061] Step S20: Based on the age tags corresponding to multiple media information and the age tag of the target user, filter each of the media information to obtain the first recommended content corresponding to the target user, and recommend content to the target user based on the first recommended content.
[0062] In this embodiment, when filtering media information by age tags of media information and age tags of target users, media information with mismatched age tags can be deleted, and media information matching the age tags of target users can be used as the first recommended content. Alternatively, age tags can be combined with other tags of target users to evaluate the degree of matching between the media information and the user using a weighted calculation method. Finally, the degree of matching is used to determine whether the media information is used as the first recommended content. Specifically, it can be preset that when the degree of matching is greater than a certain preset threshold, it can be determined as the first recommended content for the target user.
[0063] It should be noted that if media information has been pre-screened using other recommendation methods, or if the first recommended content is obtained by combining age tags with other tag information, then the first recommended content is the content to be recommended to the user. Alternatively, the first recommended content can also be the recommended content after initial screening of media information, or it can be further screened using other recommendation methods before being recommended to the user.
[0064] In the technical solution of this application embodiment, media information is first input into a pre-trained age tagging model, and the age tag corresponding to the media information is output through the age tagging model. The age tagging model is obtained by training the model with training media information and corresponding age tags. Thus, the technical solution of this application utilizes the characteristic of continuously evolving large models performing well in classification tasks, which can easily and accurately tag multimedia content (such as text, images, videos, etc.) by age. Then, based on the age tags corresponding to multiple media information and the age tag of the target user, each media information is filtered to obtain the first recommended content corresponding to the target user. The technical solution of this application also combines the target user's own age tag to filter media content suitable for the target user to watch, making up for the shortcomings of traditional content recommendation schemes such as unclear age classification, low accuracy, and low efficiency of manual review. It effectively reduces the workload of content platform staff, balances the accuracy and efficiency of age classification, and can better adapt to the parent mode of various content platforms.
[0065] Furthermore, in one feasible implementation, the step of filtering each piece of media information based on the age tags corresponding to multiple pieces of media information and the age tag of the target user to obtain the first recommended content corresponding to the target user includes:
[0066] Step S21: Sequentially determine whether the age tag of each piece of media information matches the age tag of the target user;
[0067] Step S22: The media information that matches the age tag of the target user is determined as the first recommended content;
[0068] In this embodiment, only media information matching the target user's age tag is selected as the first recommended content. For example, if a target user's age tag is 14 years or older, and the media information's age tag is 18 years or older, the two do not match, and the media information cannot be used as the first recommended content. If the media information's age tag is 14 years or older, the two match, and the media information is determined as the first recommended content. In particular, if the media information's age tag is 8 years or older, it can be selected whether to determine the media information as the first recommended content based on preset conditions. If the preset condition is met for recommendation, it can be understood that 14 years or older is also within the range of 8 years or older, and the media information can be determined as the first recommended content. If the preset precise recommendation is set, considering that content for users aged 8 or older may not be of interest to users aged 14 or older, the media information can be discarded and not recommended to the target user.
[0069] In addition, considering that the elderly have a poor ability to discern media information and are easily influenced by false information, if a user's age tag is 60 years or older, and the age tag of the media information is 18 years or older and includes other tags with marketing or false attributes, then the media information will not be recommended as the first content, so as to avoid the elderly being affected by marketing or false information.
[0070] It should be noted that, in another feasible embodiment, the method of filtering media information disclosed in this application embodiment can be applied before or after adopting the existing conventional content recommendation process (i.e., steps S23 to S24 below) to pre-screen or further screen the media information by age.
[0071] Step S23: Based on the other tag information of the target user and the recommendation tags of the first recommended content, filter the first recommended content to obtain the second recommended content corresponding to the target user. The other tag information includes at least one of the following: preference information other than age tag, interest circle information, and content preference information. The recommendation tags include at least one of the following: preference tags, interest circle tags, and content tags.
[0072] Step S24: Push the second recommended content to the user account corresponding to the target user.
[0073] This application discloses a process for recommending content based on interests, circles, and content preferences after age screening of media information. The recommendation method based on preference and interest circle information is a collaborative filtering method, which uses media information with similar preferences and belonging to the same circle as the target user as secondary recommended content. The recommendation method based on content preference information is a content-based recommendation method, which mainly uses relevant information about the media content (such as uploader descriptions, comments from other users, etc.) to filter secondary recommended content corresponding to the target user's own content preferences. Preference tags are used to characterize the user's preferences, interest circle information is used to represent the target user's preferred interest circles, and content tags are used to characterize other information related to the media content.
[0074] In this embodiment, the first recommended content that matches all other tag information of the target user can be determined as the second recommended content. If some other tag information of the target user is missing, such other tag information is ignored, and the first recommended content that matches other tag information is determined as the second recommended content.
[0075] Taking the application of age filtering before the content recommendation process as an example, refer to Figure 3 First, the labeled data (i.e., media information with age tags) is filtered by age. After filtering, it enters the recommendation process and finally obtains the recommended data to be recommended to users (equivalent to the second recommended content).
[0076] This application discloses a method for content recommendation that combines other tag information from multiple dimensions. This method is performed after age screening, which further improves the accuracy of content push and provides a more suitable content viewing experience for target users. It allows users to browse media information that matches their age group and interests, ensuring a healthy and safe internet environment.
[0077] In another feasible embodiment, the step of filtering each piece of media information based on the age tags corresponding to multiple pieces of media information and the age tag of the target user to obtain the first recommended content corresponding to the target user includes:
[0078] Step S25: Determine the corresponding age weight based on the matching between the age tag of the media information and the age tag of the target user;
[0079] Step S26: Calculate the recommendation weight of the media information based on the target user's other tag information and the media information's recommendation tag. The other tag information includes at least one of preference information, interest circle information, and content preference information. The recommendation tag includes at least one of preference tag, interest circle tag, and content tag.
[0080] Step S27: If the sum of the age weight and the recommendation weight is greater than a preset recommendation threshold, then the media information is determined as the first recommended content; or,
[0081] Step S28: Sort each piece of media information based on the sum of the age weight and the recommendation weight to obtain the corresponding first recommended content.
[0082] It should be noted that in this embodiment, steps S25 to S28 are parallel to steps S21 to S24. You can choose to obtain the first recommended content by using steps S21 to S24 in the previous embodiment, and then determine the corresponding second recommended content to push to the target user. Alternatively, you can choose to obtain the first recommended content by using steps S25 to S28 in this embodiment, and then recommend the first recommended content to the target user.
[0083] Unlike steps S21 to S24, this embodiment uses a weighted calculation method to filter the corresponding first recommended content from the media information. Compared to the tag matching determination method in the previous embodiment, this embodiment comprehensively considers the tag situation in various dimensions, resulting in a higher degree of refinement. Steps S27 and S28 are parallel solutions. Step S27 is a filtering method based on age weight, recommendation weight, and a preset recommendation threshold, while step S28 is a sorting method based on age weight and recommendation weight.
[0084] Specifically, the matching between the age tag of the media information and the age tag of the target user refers to the difference between the age range corresponding to the age tag of the media information and the age range corresponding to the age tag of the target user. It can be understood that if the age ranges of the two completely match, the matching is optimal, and the corresponding age weight is the largest. The greater the age range difference between the two, the worse the matching is, and the smaller the corresponding age weight. Furthermore, the recommendation weight of the media information includes the sum of other tag information from various dimensions (such as preference information, interest circle information, and content preference information). When calculating this recommendation weight, the weight corresponding to each other tag information is first calculated. For example, if the target user's preference information matches the media information's preference information, it is assigned a value of 1. Then, the product of 1 and a preset preference information weight (such as 0.2) is calculated to obtain the interest weight. This process is repeated until the weights of each other tag information are obtained, and then the sums are used to obtain the recommendation weight.
[0085] Among them, the age weight and recommendation weight can be regarded as the total weight of the media information. The higher the total weight, the higher the degree of matching with the user, and the higher the recommendation priority. The media information can be filtered or sorted according to the value of the total weight.
[0086] In step S27, the first recommended content can be selected by setting a preset recommendation threshold. This threshold can be a fixed value or a percentage (e.g., the top 50%). This prevents the first recommended content from having too little media information due to a low overall weight. Furthermore, in step S28, the first recommended content is determined by sorting the various media information. This means all media information can be considered components of the first recommended content, specifically sorted based on the total weight composed of age and recommendation weights. For example, when a user browses information on a short video platform, videos with higher total weights are listed first, and those with lower total weights are listed later. This prioritizes multimedia content that better matches the user's various tags (including age tags, preferences, interest groups, and content preferences), effectively targeting content to the user's age group. Finally, the first recommended content is pushed to the target user's corresponding account. For example, when a user logs into their account on the short video platform, the first recommended content is pushed to the recommendation interface.
[0087] For example, refer to Figure 4 For tagged data (equivalent to media information with age tags), a recommendation process and age filtering are performed simultaneously to obtain the corresponding recommended data (equivalent to the first recommended content).
[0088] Furthermore, in a feasible embodiment, the step of determining the corresponding age weight based on the matching of the age tag of the media information and the age tag of the target user includes:
[0089] Step S251: Determine whether the age tag of the media information matches the age tag of the target user;
[0090] Step S252: If a match is found, the age tag matching value is determined to be the first preset value;
[0091] Step S253: If there is no match, determine that the age tag matching value is the second preset value, and the first preset value is greater than the second preset value;
[0092] Step S254: Calculate the product of the age tag matching value and the preset age weight to obtain the age weight value.
[0093] This application provides a method for determining age weights, primarily based on the matching between the age tags of media information and the age tags of target users. Matching the age tags of the media information and the target user means they are completely identical. For example, if both the age tag of the media information and the target user is 18 years or older, they are a perfect match, and the age tag matching value can be set as a first preset value (e.g., 1). If the age tag of the target user is 12 years or older, the age tag matching value is set as a second preset value (e.g., 0). The age tag matching value characterizes the degree of matching between the age tags of the media information and the target user; a higher age tag matching value indicates a higher degree of matching. Additionally, a preset age weight (ranging from 0 to 1) represents the proportion of age factors in content recommendation. Finally, the product of the age tag matching value and the preset age weight is calculated to obtain the age weight.
[0094] On the other hand, in some cases, age tags may partially match. For example, if the age tag of the media information is 14 years and older, and the age tag of the target user is 18 years and older, although there is no complete match, 18 years and older is within the range of 14 years and older. The age tag matching value can be assigned a third preset value (e.g., 0.5), where the third preset value is greater than the second preset value and less than the first preset value.
[0095] In another feasible embodiment, before applying the age-labeling big model in this application embodiment for age labeling, the steps of the age-based content recommendation method in this application embodiment further include:
[0096] Step A10: Obtain the original media information;
[0097] Step A20: Delete emoticons and text formatting from the original media information, and normalize the image clarity in the original media information to obtain training media information;
[0098] Step A30: Based on the training media information and the corresponding age tags, fine-tune the preset initial large model to obtain the age-labeled large model;
[0099] During the fine-tuning training process, the initial large model updates the model parameters of the model layer adjacent to the output layer based on a preset learning rate. The preset learning rate is lower than the learning rate corresponding to the initial large model during the basic training process.
[0100] Alternatively, the initial large model updates all model parameters based on the preset learning rate during the fine-tuning training process.
[0101] This application provides a method for training a large-scale age tagging model. The original media information includes text, images, graphic-text, and video information commonly found on various content platforms. The original media information is manually tagged with corresponding age labels, which are based on the specific content of the media information. For example, high school students and university students may have similar interests, but their psychological development and ability to discern content differ. For instance, even within the same beauty and skincare category, advertisements recommending sunscreen and those designing medical aesthetic treatments require significantly different levels of discernment from the viewer. Therefore, advertisements that are marketing-oriented, carry higher risks, or involve higher spending levels should be recommended to groups with a certain income, such as those over 22 years old. For older adults, who have insufficient ability to distinguish between marketing information and misinformation, such information can be tagged with an age group under 60.
[0102] It should be noted that before age labeling, the data corresponding to the original media information is cleaned and preprocessed, such as removing special expressions (or converting emoticons into text encoding for easier model recognition and understanding), deleting text indentation, and normalizing image clarity (i.e., unifying image clarity), to obtain training media information. All of the above processes are to make the media information easier for large models to recognize and understand.
[0103] Furthermore, because the training objective of the large model is more refined (age-labeling the input media information), the initial large model used can be a currently publicly available basic large model or a private domain large model, and then fine-tuned using age-labeled media data. Specifically, during the fine-tuning training process, the internal model parameters can be updated using gradient descent, as shown in the following expression:
[0104]
[0105] Where, θ i+1 For the updated model parameters, θ i These are the model parameters before the update, and η is the learning rate. For gradient.
[0106] In addition, when fine-tuning training a large model, the model parameters that need to be iterated can be selected in one of the following two ways.
[0107] One approach is to freeze a portion of the base model in the large model (usually the upper half of the model that processes the input data) and iterate over it. This means keeping most of the parameters in the upper layers of the model unchanged during fine-tuning, and only updating the parameters of a few model layers that are closer to the final output layer. This results in a relatively small amount of training and allows for a faster acquisition of a large model with age labels that meets the requirements.
[0108] Secondly, updating all nodes of the base model is an option, but this method requires a larger amount of training and a longer training time.
[0109] It should be noted that during fine-tuning, a learning rate relatively small compared to that used when training the base model is typically chosen: η fine-tune <η pre-train , where η fine-tune To fine-tune the learning rate during training, η pre-train The learning rate used for training the base model is the learning rate used in the regular deep learning model training process. Using a smaller learning rate can preserve pre-trained knowledge, avoid overfitting, maintain the stability of large models, and thus efficiently and stably transfer and improve the performance of large models on age labeling tasks.
[0110] The selection of the large model structure and data in the embodiments of this application can depend on various factors such as computing power, platform content style, and data format. For example, in order to select an age label in the data labeling method that differs from the output label of the basic model, adaptation can be achieved by modifying the last output layer or adding a separate layer of neural network structure.
[0111] For example, refer to Figure 5 The base model (i.e., the initial large model) is fine-tuned by labeling multimedia files (i.e., training media information with age labels), and finally the fine-tuned model (i.e., the trained age-labeled large model) is obtained.
[0112] Furthermore, in a feasible embodiment, the training media information includes at least one of training text information, training image information, and mixed text and image information; the initial large model includes at least one of an initial text large model, an initial image large model, and an initial multimodal large model; and the age tag large model includes at least one of a target text large model, a target image large model, and a target multimodal large model.
[0113] The step of fine-tuning the preset initial large model based on the training media information and the corresponding age tags to obtain the age-labeled large model includes:
[0114] Step A31: Based on the training text information and corresponding age tags, fine-tune the preset initial large text model to obtain the target large text model; and / or,
[0115] Step A32: Based on the training image information and corresponding age labels, fine-tune the preset initial image model to obtain the target image model; and / or,
[0116] Step A33: Based on the image-text hybrid information and the corresponding age tags, fine-tune the preset initial multimodal large model to obtain the target multimodal large model.
[0117] The age tagging big model in this application embodiment can be applied to accurately tag the age of files in various formats such as text, pictures, graphic text and video in multimedia information. The corresponding age tagging big model also includes a target text big model, a target image big model and a target multimodal big model that are processed in a targeted manner for the above-mentioned file formats.
[0118] It should be noted that when processing media information in video format, the video can first be divided into multiple video frame images, then the target image large model can be used for age labeling, and finally the age label of the video can be determined by comprehensively considering the age label of each video frame image.
[0119] Specifically, video frame images can be extracted according to a preset extraction ratio. For example, one frame can be extracted from every 10 frames and input into the age labeling model for age tagging to obtain the age label for that frame. When the age labels of multiple video frames corresponding to a video file are inconsistent, the age label with the largest age range among all video frames is selected as the age label for the entire video. This is because when recommending the video to a user, it is necessary to consider whether all the content of the video is suitable for that user. If there is a segment that is not suitable for the user, then the entire video is not suitable for that user. Therefore, the age label with the largest age range is used as the age label for the entire video.
[0120] In this embodiment, three models are trained using text information, image information (including video information), and graphic information included in the training media information, until the target text large model, target image large model, and target multimodal large model are obtained with the expected age tag marking accuracy.
[0121] Furthermore, in a feasible embodiment, before the step of fine-tuning the preset initial large model based on the training media information and the corresponding age label, the method further includes:
[0122] Step A21: Obtain the age label corresponding to the training media information, wherein the age label is a binary classification label, an age segmentation label, or a preset age segment label, and the preset age segment label is determined by other label information of the training media information.
[0123] In this embodiment, the specific details of age labeling for training information can be defined according to the usage scenario. For example, binary classification labels are suitable for scenarios where content recommendation platforms use a parental control mode, and can include both "no parental accompaniment required" and "parental accompaniment required" age labels. For this type of age label, the optimization objective during fine-tuning training is suitable for using metrics such as accuracy and hit rate to evaluate the performance of the large model. Age segmentation labels can be divided into age levels such as under 10, under 14, under 18, and over 18. For this type of age label, the optimization objective during fine-tuning training is suitable for using metrics such as accuracy and classification hit rate to evaluate the performance of the large model. Preset age segment labels mark content segments in text and multimedia files that are suitable for display to specific age groups. For this type of age label, the optimization objective during training is also suitable for using metrics such as accuracy and hit rate.
[0124] It should be noted that the preset age group label is determined by other label information of the training media information. For example, in content recommendation, some label information is suitable for users of certain age groups and needs to be specially marked. For example, other label information of a certain training media information includes "health and wellness" and "dieting and weight loss". "Health and wellness" is suitable for users of all ages, but "dieting and weight loss" is not suitable for minors who are in the growth and development period. Therefore, the training media information needs to be labeled with the age label "18 years and above" to avoid pushing media information with the "dieting and weight loss" label to users "under 18 years old", so as to avoid affecting minors with poor information discrimination ability and protect their physical health.
[0125] In another feasible embodiment, after obtaining the trained age-labeled large model, it can be updated at a preset frequency, or updated when a significant deviation is detected in the age-labeled large model for a certain type of media information. This situation typically arises because the model has poor recognition and understanding capabilities for this type of media information. When a model update is required, refer to... Figure 6 The old model (i.e., the age-labeled large model that needs to be updated) is fine-tuned and trained using new multimedia files (i.e., manually labeled media information) to obtain a new model (i.e., the updated age-labeled large model). It should be noted that during the fine-tuning training process, the structure of the original age-labeled large model can be left unchanged. The model can be fine-tuned again by mixing the new data with the old data.
[0126] This application employs a large-scale model to train the age labeling model. Currently evolving large-scale models perform well in summarizing and generalizing tasks, achieving higher accuracy than traditional classification models across various classification tasks. They can also easily summarize and classify multimedia content, such as text + images or videos, offering significant advantages in efficiency and accuracy compared to traditional models. Compared to the need for initial word segmentation and training, using an existing general-purpose large-scale model, with only minor adjustments to its age classification capabilities, is less time-consuming, less labor-intensive, and less costly. The age labeling large-scale model can also directly provide appropriate feedback on new terms in media information. Even if the large-scale model misunderstands new terms in the data, its understanding can be updated through manual prompts or relatively low-cost fine-tuning. Although fine-tuning a single model function currently carries the risk of losing its general capabilities, since the large-scale model is only used for age labeling throughout the process, the loss of general capabilities has little impact on the intended use (age labeling) of the technical solution in this application.
[0127] It should be noted that the above examples are only for understanding this application and do not constitute a limitation on the age-based content recommendation method of this application. Any simple modifications based on this technical concept are within the protection scope of this application.
[0128] This application provides an electronic device, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the age-based content recommendation method in Embodiment 1 above.
[0129] The following is for reference. Figure 7 The diagram illustrates a structural schematic of an electronic device suitable for implementing embodiments of this application. The electronic devices in these embodiments may include, but are not limited to, mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Descriptions), PMPs (Portable Media Players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital TVs and desktop computers. Figure 7 The electronic device shown is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments of this application.
[0130] like Figure 7As shown, the electronic device may include a processing unit 1001 (e.g., a central processing unit, a graphics processing unit, etc.) that can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1002 or a program loaded from a storage device 1003 into a random access memory (RAM) 1004. The RAM 1004 also stores various programs and data required for the operation of the device. The processing unit 1001, ROM 1002, and RAM 1004 are interconnected via a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Typically, the following systems can be connected to the I / O interface 1006: input devices 1007 including, for example, touchscreens, touchpads, keyboards, mice, image sensors, microphones, accelerometers, gyroscopes, etc.; output devices 1008 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 1003 including, for example, magnetic tapes, hard disks, etc.; and communication devices 1009. Communication device 1009 allows electronic devices to communicate wirelessly or wiredly with other devices to exchange data. While electronic devices with various systems are shown in the figures, it should be understood that implementation or possession of all the systems shown is not required. More or fewer systems may be implemented alternatively.
[0131] Specifically, according to the embodiments disclosed in this application, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments disclosed in this application include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device, or installed from storage device 1003, or installed from ROM 1002. When the computer program is executed by processing device 1001, it performs the functions defined in the methods of the embodiments disclosed in this application.
[0132] The electronic device provided in this application employs the age-based content recommendation method described in the above embodiments, which solves the technical problems of low accuracy and high cost in current age-based content recommendation strategies. Compared with the prior art, the beneficial effects of the electronic device provided in this application are the same as those of the age-based content recommendation method provided in the above embodiments, and other technical features of this electronic device are the same as those disclosed in the previous embodiment method, and will not be repeated here.
[0133] It should be understood that the various parts disclosed in this application can be implemented using hardware, software, firmware, or a combination thereof. In the description of the above embodiments, specific features, structures, materials, or characteristics can be combined in any suitable manner in one or more embodiments or examples.
[0134] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
[0135] This application provides a computer-readable storage medium having computer-readable program instructions (i.e., a computer program) stored thereon, the computer-readable program instructions being used to execute the age-based content recommendation method in the above embodiments.
[0136] The computer-readable storage medium provided in this application may be, for example, a USB flash drive, but is not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to: electrical connections having one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, system, or device. The program code contained on the computer-readable storage medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination thereof.
[0137] The aforementioned computer-readable storage medium may be included in an electronic device or may exist independently without being assembled into an electronic device.
[0138] The aforementioned computer-readable storage medium carries one or more programs that, when executed by an electronic device, cause the electronic device to perform the following: inputting media information into a pre-trained age tagging model, outputting an age tag corresponding to the media information through the age tagging model, wherein the age tagging model is trained by training the media information and the corresponding age tags; filtering each piece of media information based on the age tags corresponding to multiple pieces of media information and the age tag of the target user, obtaining first recommended content corresponding to the target user, and recommending content to the target user based on the first recommended content.
[0139] Computer program code for performing the operations of this application can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, and conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a Local Area Network (LAN) or a Wide Area Network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0140] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0141] The modules described in the embodiments of this application can be implemented in software or hardware. The names of the modules do not necessarily limit the functionality of the unit itself.
[0142] The readable storage medium provided in this application is a computer-readable storage medium that stores computer-readable program instructions (i.e., a computer program) for executing the age-based content recommendation method described above. This addresses the technical problems of low accuracy and high cost in current age-based content recommendation strategies. Compared to the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as those of the age-based content recommendation method provided in the above embodiments, and will not be elaborated upon here.
[0143] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the age-based content recommendation method described above.
[0144] The computer program product provided in this application can solve the technical problems of low accuracy and high cost in current age-based content recommendation strategies. Compared with the prior art, the beneficial effects of the computer program product provided in this application are the same as those of the age-based content recommendation method provided in the above embodiments, and will not be repeated here.
[0145] The above description is only a part of the embodiments of this application and does not limit the patent scope of this application. All equivalent structural transformations made under the technical concept of this application and using the contents of the specification and drawings of this application, or direct / indirect applications in other related technical fields, are included in the patent protection scope of this application.
Claims
1. An age-based content recommendation method, characterized in that, The age-based content recommendation method includes: Media information is input into a pre-trained age tagging model, and the age tagging model outputs the age label corresponding to the media information. The age tagging model is trained by training the media information and the corresponding age label. Based on the age tags corresponding to multiple media information and the age tags of the target user, the media information is filtered to obtain the first recommended content corresponding to the target user, and content is recommended to the target user based on the first recommended content.
2. The age-based content recommendation method as described in claim 1, characterized in that, The step of filtering the media information based on age tags corresponding to multiple media information and the target user's age tag to obtain first recommended content for the target user, and recommending content to the target user based on the first recommended content, includes: Sequentially determine whether the age tag of each piece of media information matches the age tag of the target user; Media information that matches the age tag of the target user is identified as the first recommended content; Based on the target user's other tag information and the first recommended content's recommendation tags, the first recommended content is filtered to obtain the second recommended content corresponding to the target user. The other tag information includes at least one of preference information, interest circle information, and content preference information, and the recommendation tags include at least one of preference tags, interest circle tags, and content tags. The second recommended content is pushed to the user account corresponding to the target user.
3. The age-based content recommendation method as described in claim 1, characterized in that, The step of filtering the media information based on the age tags corresponding to multiple media information and the age tag of the target user to obtain the first recommended content corresponding to the target user includes: Based on the matching between the age tags of the media information and the age tags of the target users, the corresponding age weight is determined; The recommendation weight of the media information is calculated based on the target user's other tag information and the media information's recommendation tags; If the sum of the age weight and the recommendation weight is greater than a preset recommendation threshold, then the media information is determined as the first recommended content; or, The media information is sorted based on the sum of the age weight and the recommendation weight to obtain the corresponding first recommended content.
4. The age-based content recommendation method as described in claim 3, characterized in that, The step of determining the corresponding age weight based on the matching of the age tags of the media information and the age tags of the target user includes: Determine whether the age tag of the media information matches the age tag of the target user; If a match is found, the age tag matching value is determined to be the first preset value; If there is no match, the age tag matching value is determined to be the second preset value, where the first preset value is greater than the second preset value; The age weight is obtained by calculating the product of the age tag matching value and the preset age weight.
5. The age-based content recommendation method as described in claim 1, characterized in that, The steps of the age-based content recommendation method also include: Obtain original media information; Remove emoticons and text formatting from the original media information, and normalize the image clarity in the original media information to obtain training media information; Based on the training media information and the corresponding age tags, the preset initial large model is fine-tuned and trained to obtain an age-labeled large model; During the fine-tuning training process, the initial large model updates the model parameters of the model layer adjacent to the output layer based on a preset learning rate. The preset learning rate is lower than the learning rate corresponding to the initial large model during the basic training process. Alternatively, the initial large model updates all model parameters based on the preset learning rate during the fine-tuning training process.
6. The age-based content recommendation method as described in claim 5, characterized in that, The training media information includes at least one of training text information, training image information, and mixed text and image information; the initial large model includes at least one of initial text large model, initial image large model, and initial multimodal large model; and the age tag large model includes at least one of target text large model, target image large model, and target multimodal large model. The step of fine-tuning the preset initial large model based on the training media information and the corresponding age tags to obtain the age-labeled large model includes: Based on the training text information and corresponding age tags, the preset initial large text model is fine-tuned to obtain the target large text model; and / or, Based on the training image information and corresponding age tags, a preset initial image model is fine-tuned to obtain a target image model; and / or, Based on the image and text mixed information and the corresponding age tags, the preset initial multimodal large model is fine-tuned and trained to obtain the target multimodal large model.
7. The age-based content recommendation method as described in claim 6, characterized in that, Before the step of fine-tuning the preset initial large model based on the training media information and the corresponding age labels, the method further includes: Obtain the age label corresponding to the training media information, wherein the age label is a binary classification label, an age segmentation label, or a preset age segment label, and the preset age segment label is determined by other label information of the training media information.
8. An electronic device, characterized in that, The device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, the computer program being configured to implement the steps of the age-based content recommendation method as described in any one of claims 1 to 7.
9. A storage medium, characterized in that, The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, it implements the steps of the age-based content recommendation method as described in any one of claims 1 to 7.
10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the method described in any one of claims 1 to 7.