Recommended label distribution method and device, equipment and medium
By using a pre-configured large language model for recommended tag allocation and selecting an appropriate model for semantic feature extraction and similarity matching based on text description information, the flexibility and accuracy issues of existing methods are resolved, and accurate tag matching and recommendation for various types of products are achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-19
- Publication Date
- 2026-03-24
AI Technical Summary
Existing recommendation tag assignment methods are inflexible and inaccurate, making it difficult to adapt to changes in user interests. In particular, the accuracy of tag assignment for new users or new products is insufficient. Machine learning-based methods require a large amount of labeled data, and the accuracy of the labeled data affects model performance.
Multiple pre-configured large language models are used. The corresponding tag assignment model is selected based on the text type of the product's text description information. Semantic feature extraction and similarity matching are performed through the large language models. Recommended tags are determined from the tag library and combined with user demand information to make product recommendations.
It achieves accurate classification and tag matching for various types of products, improves the accuracy and flexibility of recommendation tags, requires no large amount of labeled data, has strong generalization ability, and improves the accuracy and efficiency of the recommendation system.
Smart Images

Figure CN121722958A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of big data technology, specifically to a method, apparatus, device, and medium for assigning recommendation tags. Background Technology
[0002] With the development of the internet and digital media, recommendation tags play a crucial role in the product recommendation process. They help the system better understand users' interests and preferences, thereby improving the accuracy of product recommendations.
[0003] In related technologies, common recommendation tag assignment methods mainly include rule-based assignment, collaborative filtering-based assignment, and machine learning-based assignment. Rule-based assignment lacks flexibility and struggles to adapt to changes in user interests; collaborative filtering-based assignment struggles to accurately assign tags to new users or new products due to insufficient data; and machine learning-based assignment requires a large amount of labeled data to train the model, and the accuracy of the labeled data significantly impacts the model's performance. Summary of the Invention
[0004] This application provides a method, apparatus, device, and medium for allocating recommendation tags, which addresses the problems of low flexibility and inaccurate allocation results in related technologies.
[0005] Firstly, this application provides a method for assigning recommendation tags, the method comprising: In response to an instruction to assign recommendation tags to the target product, obtain text description information corresponding to the target product. Determine the text type corresponding to the above text description information, and based on the above text type, match the tag assignment model corresponding to the above target product from multiple pre-configured large language models; The above text description information is input into the above label allocation model. The above label allocation model extracts semantic features from the above text description information and determines the similarity between the extracted target feature vector and the feature vectors of each reference label in the label library. Based on the similarity described above, the above-mentioned label allocation model determines the recommended label corresponding to the target product from the reference labels, and determines the confidence level of each recommended label.
[0006] In one possible embodiment, the above-mentioned input of the text description information into the label assignment model, and the extraction of semantic features from the text description information through the label assignment model, includes: Obtain the tag constraints and pre-configured prompt word templates corresponding to the target products mentioned above; the tag constraints are used to identify the selection range of recommended tags corresponding to the target products mentioned above; the prompt word templates include flags corresponding to the text description information and the tag constraints mentioned above respectively; Fill the corresponding flags in the prompt word template with the above text description information and the above tag constraints to construct the tag assignment prompt words; The aforementioned label assignment prompts are input into the aforementioned label assignment model, and the semantic features of the aforementioned text description information are extracted through the aforementioned label assignment model.
[0007] In one possible embodiment, before determining the similarity between the extracted feature vector and the feature vectors of each reference tag in the tag library, the method further includes: The above-mentioned tag constraints are extracted from the above-mentioned tag allocation prompts using the above-mentioned tag allocation model; Based on the above label constraints, a reference label corresponding to the target product is determined from the labels included in the above label library.
[0008] In one possible embodiment, the process of determining recommended tags corresponding to the target product from the reference tags based on the similarity using the tag allocation model, and determining the confidence level for each recommended tag, includes: The above label assignment model is used to select candidate labels from each reference label that have a similarity to the target feature vector that is higher than a preset threshold. If the number of candidate assigned tags is greater than the preset number, the candidate tags are sorted in descending order of similarity, and the first preset number of candidate assigned tags after sorting are determined as the recommended tags corresponding to the target product. Based on the similarity of each recommended tag, the confidence level of each recommended tag is determined.
[0009] In one possible embodiment, after selecting a recommended label corresponding to the target product from the reference labels and determining the confidence level corresponding to each recommended label, the method further includes: Receive a product recommendation request from a user, which includes the user's needs information; the needs information is used to indicate the conditions that the recommended product must meet. Based on the above requirements, a product recommendation model corresponding to the above product recommendation request is matched from multiple pre-configured large language models. Input the above demand information into the above product recommendation model, and use the above product recommendation model to match candidate recommendation tags corresponding to the above recommended products from the tag library; If the aforementioned candidate recommendation tags correspond to multiple candidate products, the evaluation index value corresponding to each candidate product is determined through the aforementioned product recommendation model, and the aforementioned product to be recommended is determined from each candidate product based on the aforementioned evaluation index value, and feedback is given to the aforementioned user.
[0010] In one possible embodiment, the evaluation metrics corresponding to the above-mentioned candidate products include at least one of relevance metrics, user preference metrics, timeliness metrics, and priority metrics; for any candidate product, the evaluation metric value corresponding to the above-mentioned candidate product is determined based on at least one of the following methods: Based on the overlap between the multiple recommendation tags corresponding to the above candidate products and the candidate recommendation tags corresponding to the above recommended products, the indicator values corresponding to the above relevance indicators for the above candidate products are determined. Determine the user profile of the above users, predict the user's preference for the above candidate products based on the above user profile, and obtain the index value corresponding to the above candidate products and the above user preference index. Based on the matching degree between the usage time corresponding to the above candidate products and the time information included in the above demand information, the indicator values corresponding to the above candidate products and the above timeliness indicators are determined. Based on the pre-configured priorities of each product, the indicator values corresponding to the above candidate products and the above priority indicators are determined.
[0011] In one possible embodiment, if there are multiple evaluation indicators corresponding to the candidate products, then determining the product to be recommended from the candidate products based on the evaluation indicator values includes: For any candidate product, the comprehensive evaluation value of the candidate product is determined based on the weights corresponding to each evaluation index value and the evaluation index values corresponding to the candidate product. Based on the comprehensive evaluation value of each candidate product, at least one product to be recommended is selected from the above candidate products.
[0012] Secondly, this application provides a recommendation label allocation device, the device comprising: The information acquisition module is used to acquire text description information corresponding to the target product in response to the instruction to assign recommendation tags to the target product; The assignment model matching module is used to determine the text type corresponding to the above text description information, and based on the above text type, to match the tag assignment model corresponding to the above target product from multiple pre-configured large language models. The similarity determination module is used to input the above text description information into the above label allocation model, extract semantic features from the above text description information through the above label allocation model, and determine the similarity between the extracted target feature vector and the feature vectors of each reference label in the label library. The tag determination module is used to determine the recommended tags corresponding to the target product from the reference tags based on the similarity using the tag allocation model, and to determine the confidence level of each recommended tag.
[0013] In one possible embodiment, the similarity determination module described above is specifically used for: Obtain the tag constraints and pre-configured prompt word templates corresponding to the target products mentioned above; the tag constraints are used to identify the selection range of recommended tags corresponding to the target products mentioned above; the prompt word templates include flags corresponding to the text description information and the tag constraints mentioned above respectively; Fill the corresponding flags in the prompt word template with the above text description information and the above tag constraints to construct the tag assignment prompt words; The aforementioned label assignment prompts are input into the aforementioned label assignment model, and the semantic features of the aforementioned text description information are extracted through the aforementioned label assignment model.
[0014] In one possible embodiment, the similarity determination module described above is further configured to: The above-mentioned tag constraints are extracted from the above-mentioned tag allocation prompts using the above-mentioned tag allocation model; Based on the above label constraints, a reference label corresponding to the target product is determined from the labels included in the above label library.
[0015] In one possible embodiment, the above-described label determination module is specifically used for: The above label assignment model is used to select candidate labels from each reference label that have a similarity to the target feature vector that is higher than a preset threshold. If the number of candidate assigned tags is greater than the preset number, the candidate tags are sorted in descending order of similarity, and the first preset number of candidate assigned tags after sorting are determined as the recommended tags corresponding to the target product. Based on the similarity of each recommended tag, the confidence level of each recommended tag is determined.
[0016] In one possible embodiment, the above-described apparatus further includes: The request receiving module is used to receive product recommendation requests from users, which include the user's demand information. The demand information is used to indicate the conditions that the recommended product must meet. The recommendation model matching module is used to match the product recommendation model corresponding to the above product recommendation request from multiple pre-configured large language models based on the above requirement information. The tag matching module is used to input the above-mentioned demand information into the above-mentioned product recommendation model, and to match the candidate recommendation tags corresponding to the above-mentioned product to be recommended from the tag library through the above-mentioned product recommendation model; The product determination module is used to determine the evaluation index value corresponding to each candidate product through the product recommendation model if the above candidate recommendation tag corresponds to multiple candidate products, and to determine the product to be recommended from each candidate product based on the above evaluation index value, and to provide feedback to the above user.
[0017] In one possible embodiment, the above-described recommendation model matching module is specifically used for: Based on the above requirements, the text description information of the related products of the products to be recommended is retrieved from the product information database; Based on the retrieved text description information, a product recommendation model corresponding to the above product recommendation request is matched from multiple pre-configured large language models. The aforementioned tag matching module is specifically used for: Input the retrieved text description information and the aforementioned requirement information into the product recommendation model.
[0018] In one possible embodiment, the evaluation metrics corresponding to the candidate products include at least one of relevance metrics, user preference metrics, timeliness metrics, and priority metrics; for any candidate product, the evaluation metric value corresponding to the candidate product is determined based on at least one of the following methods: Based on the overlap between the multiple recommendation tags corresponding to the above candidate products and the candidate recommendation tags corresponding to the above recommended products, the indicator values corresponding to the above relevance indicators for the above candidate products are determined. Determine the user profile of the above users, predict the user's preference for the above candidate products based on the above user profile, and obtain the index value corresponding to the above candidate products and the above user preference index. Based on the matching degree between the usage time corresponding to the above candidate products and the time information included in the above demand information, the indicator values corresponding to the above candidate products and the above timeliness indicators are determined. Based on the pre-configured priorities of each product, the indicator values corresponding to the above candidate products and the above priority indicators are determined.
[0019] In one possible embodiment, if there are multiple evaluation indicators corresponding to the candidate products, then the product determination module is specifically used for: For any candidate product, the comprehensive evaluation value of the candidate product is determined based on the weights corresponding to each evaluation index value and the evaluation index values corresponding to the candidate product. Based on the comprehensive evaluation value of each candidate product, at least one product to be recommended is selected from the above candidate products.
[0020] Thirdly, this application provides an electronic device, comprising: Memory, used to store program instructions; A processor is configured to invoke program instructions stored in the memory and execute the steps of the method described in any one of the first aspects according to the obtained program instructions.
[0021] Fourthly, this application provides a computer-readable storage medium storing a computer program, the computer program including program instructions, which, when executed by a computer, cause the computer to perform the method described in any one of the first aspects.
[0022] Fifthly, this application provides a computer program product comprising: computer program code, which, when run on a computer, causes the computer to perform the method described in any one of the first aspects.
[0023] Through the technical solutions in one or more of the above embodiments of this application, this application has at least the following technical effects: The above method, by pre-configuring multiple large language models, selects the corresponding tag assignment model from the large language models when matching recommendation tags for products, based on the text type of the product's text description information. This supports dynamic matching of models and ensures the accuracy of model selection. Based on this tag assignment model, corresponding recommendation tags are matched from the tag library based on the text description information. Through large language models, semantic understanding and pattern recognition can be performed on large amounts of text data, thereby achieving accurate classification and tag matching of text description information. Furthermore, large language models have strong generalization capabilities and can handle text data from various domains and topics, thus achieving tag matching for various types of products without the need to acquire a large amount of labeled data.
[0024] Other features and advantages of this application will be set forth in the description which follows, and will be apparent in part from the description, or may be learned by practicing the application. The objectives and other advantages of this application may be realized and obtained by means of the structures particularly pointed out in the written description, claims, and drawings. Attached Figure Description
[0025] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0026] Figure 1A flowchart illustrating a method for assigning recommendation tags, as provided in this application embodiment; Figure 2 A schematic diagram of an MCP architecture provided in an embodiment of this application; Figure 3 A schematic diagram illustrating a recommendation tag allocation process provided in an embodiment of this application; Figure 4 A structural diagram of a recommendation label distribution device provided in an embodiment of this application; Figure 5 This is a structural diagram of an electronic device provided in an embodiment of this application. Detailed Implementation
[0027] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. 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. Unless otherwise specified, the embodiments and features in the embodiments of this application can be arbitrarily combined with each other. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than that shown here.
[0028] The terms "first" and "second" in the specification, claims, and accompanying drawings of this application are used to distinguish different objects, not to describe a specific order. Furthermore, the term "comprising" and any variations thereof are intended to cover non-exclusive protection. For example, a process, method, system, product, or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to these processes, methods, products, or devices. The term "multiple" in this application can mean at least two, for example, two, three, or more, and the embodiments of this application do not impose limitations.
[0029] The following description, in conjunction with the accompanying drawings, illustrates exemplary embodiments of this application, including various details to aid understanding. These embodiments should be considered merely exemplary. Therefore, those skilled in the art should recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope of this application. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description. It should be noted that in the embodiments of this application, certain existing industry solutions such as software, components, and models may be mentioned. These should be considered exemplary, intended only to illustrate the feasibility of implementing the technical solutions of this application, and do not imply that the applicant has already used or necessarily used such solutions.
[0030] The acquisition, transmission, storage, and use of data in this application all comply with the requirements of relevant national laws and regulations.
[0031] Before introducing the recommendation tag allocation method provided in the embodiments of this application, for ease of understanding, the technical background of the embodiments of this application will be described in detail below.
[0032] With the development of the internet and digital media, the number of products has surged. To assist users in making product selections, various product recommendation systems have gradually emerged. Recommendation tags play a crucial role in the product recommendation process, helping the system better understand users' interests and preferences, thereby improving the accuracy of product recommendations.
[0033] Among related technologies, common recommendation tag allocation methods mainly include rule-based allocation methods, collaborative filtering-based allocation methods, and machine learning-based allocation methods.
[0034] The rule-based assignment methods described above rely primarily on predefined rules to assign tags, such as based on a user's browsing history or consumption records. While simple and intuitive, this approach lacks flexibility and struggles to adapt to changes in user interests. Over time, user interests typically evolve, but this method fails to capture these changes promptly, leading to lower recommendation accuracy.
[0035] The collaborative filtering-based assignment methods described above primarily assign tags by analyzing the similarity between users or products. For example, if two users like similar items, they might be assigned similar tags. While this method can uncover potential connections between users, it may suffer from the cold start problem, meaning that for new users or new products, accurate tag assignment is difficult due to a lack of sufficient data. Furthermore, this method can be affected by data sparsity; when there is limited interaction data between users and products, accurate recommendations become challenging.
[0036] The aforementioned machine learning-based assignment methods automatically learn the relationship between labels and user behavior by training a model. For example, a supervised learning algorithm can be used to train a classifier to predict possible labels based on user behavior data. While this method can automatically learn and adapt to changes in user interests, it requires a large amount of labeled data to train the model. In practical applications, it is often difficult to obtain large amounts of labeled data, and the accuracy of the labeled data can also affect the model's performance.
[0037] In recent years, the application of Large Language Models (LLMs) in recommender systems has received widespread attention. LLMs possess powerful text understanding and generation capabilities, capturing complex patterns in user behavior and preferences. Applied to recommender systems, they can understand text data such as user comments, feedback, and search queries. Combining LLMs with recommender systems can more accurately capture user interests and preferences, leading to more precise recommendations. Furthermore, LLMs can be combined with other recommender techniques, such as collaborative filtering and content recommendation, to improve the accuracy and diversity of recommendations. For example, LLMs can be used to generate more accurate labels, which can then be combined with collaborative filtering methods for recommendations.
[0038] Based on this, this application proposes a method for assigning recommendation tags. Multiple large language models are pre-configured. When matching recommendation tags for products, a corresponding tag assignment model is selected from the large language models based on the text type of the product's text description information. This tag assignment model then matches the corresponding recommendation tags from a tag library based on the text description information. Through the large language models, semantic understanding and pattern recognition can be performed on large amounts of text data, thereby achieving accurate classification and tag matching of text description information. Actual data verification shows that in a study on online product descriptions, this method achieves 90% accuracy in assigning recommendation tags. Furthermore, the large language models possess strong generalization capabilities, capable of handling text data from various domains and topics; therefore, tag matching for various product types can be achieved without acquiring a large amount of labeled data.
[0039] Figure 1 This is a flowchart illustrating a recommendation tag allocation method provided in an embodiment of this application; as shown below. Figure 1 As shown in the figure, this application provides a method for assigning recommendation tags, including: Step S101: In response to the instruction to assign recommendation tags to the target product, obtain the text description information corresponding to the target product; In some embodiments, this application provides a display interface that allows users to input information. Business personnel can input text description information corresponding to a target product through this display interface to trigger the instruction to assign recommendation tags to the target product. The specific text description information can be set according to requirements. In other embodiments, a product information database can be pre-configured to store text description information corresponding to each product. Business personnel can input the identifier of a target product in the display interface to trigger the instruction to assign recommendation tags to the target product. The system then retrieves the text description information corresponding to the target product from the database based on the identifier.
[0040] In some embodiments, the product information database described above can store relevant information (i.e., text description information) about various promotional activities corresponding to each product, including but not limited to the promotion name, discount level, and scope of application. This product information database has a reasonable structure, enabling rapid retrieval and updating of promotional information, and providing accurate data support for tag assignment.
[0041] For example, business personnel can fill in the basic information of the promotional activities corresponding to the target product (i.e., the text description information mentioned above) on the display interface (such as the administrator platform). The basic information may include the activity name, activity format, description of the activity rules, applicable target audience, applicable scenarios, and applicable time, etc., and upload the information by clicking the save button. This triggers the instruction to assign recommendation tags to the target product. After receiving the instruction, the system stores the uploaded information in a specified database (which can be selected and configured based on needs) for persistent storage, so that it can be called later.
[0042] In some embodiments, when a user selects a target product, multiple classification criteria are typically provided for the user to filter. However, due to different classification dimensions, the same target product usually corresponds to multiple types. For example, it can be classified into different levels such as level one and level two according to its grade; into various scenarios such as catering and clothing according to its applicable scenarios; and into various objects such as students and teachers according to their applicable objects. When assigning recommendation tags, a target product may be associated with multiple promotional activities, and each promotional activity may belong to different recommendation tags. Therefore, a target product usually has multiple recommendation tags, and each recommendation tag corresponds to multiple promotional activities. Consequently, in the subsequent product recommendation process for users, multiple promotional activities are usually matched based on the user's needs, and then multiple products are associated with these multiple promotional activities.
[0043] Step S102: Determine the text type corresponding to the text description information, and based on the text type, match the tag assignment model corresponding to the target product from multiple pre-configured large language models; In some embodiments, this application establishes a context specification based on the Model Context Protocol (MCP) framework, which enables plug-and-play functionality for LLM components. This means that multiple LLM adapters are configured to support dynamic matching of models based on task requirements (such as text length, degree of structuring, required generalization ability, etc.).
[0044] Specifically, the task requires a text type that can be represented as textual description information. The method for obtaining this text type can be set based on requirements, such as carrying the text type in the instruction or classifying the textual description information to obtain its corresponding text type. Furthermore, the specific configuration of this text type is not limited in this embodiment of the application, and can be set based on requirements in implementation. For example, it can be set as a first text type corresponding to normalized short text, a second text type corresponding to unstructured long text, and a third text type including specific words. These specific words can also be preset as needed, for example, they may include personally identifiable information (PII).
[0045] Compared to related technologies that configure independent code branches for each LLM model and set different prompt word templates and data preprocessing code for each LLM, the method described in this application only requires dynamically loading the configuration information of different adapters to achieve dynamic switching of LLMs. Furthermore, when multiple LLMs are connected, only the corresponding adapter files need to be added, greatly reducing the cost of model integration. Moreover, while related technologies require simultaneous modification of the model's adaptation code during model version upgrades, this application demonstrates automatic version conversion at the protocol layer with backward compatibility, improving the efficiency of version upgrades.
[0046] In some embodiments, this application may also set up a centralized word filter for specific words to filter specific words and ensure data security. Compared with the method of filtering specific words in each prompt word template in related technologies, this method can simplify the configuration of prompt word templates and achieve effective filtering of specific words.
[0047] like Figure 2 As shown, in this embodiment of the application, multiple LLM adapters are configured under the MCP framework, such as... Figure 2The diagram shows the LLM-1 and LLM-2 adapters; different adapters correspond to different text types. After receiving an instruction to assign recommendation tags to a target product (hereinafter referred to as the assignment instruction for ease of explanation), the MCP routing layer determines the corresponding target adapter based on the text type of the text description information corresponding to the target product, and reads the current model configuration (such as the LLM-1 adapter). If it is determined that the current model configuration is different from the target adapter, a configuration switching process is performed (such as switching to the LLM-2 adapter), and subsequent unified context construction, recommendation tag matching, and standardized output are performed based on the target adapter.
[0048] In specific implementation, each adapter can correspond to at least one LLM. In this embodiment, there are no restrictions on the settings of the adapters and the LLM models corresponding to each adapter. For example, the adapters can be set to include LLM-1, LLM-2 and LLM-3.
[0049] Among them, LLM-1 is used for precise information extraction. Its corresponding LLM needs to have the characteristics of efficient execution of structured instructions, low latency and relatively controllable cost, focusing on information extraction and format compliance; and its corresponding text type can be set to the first text type mentioned above, such as the activity name, description information of activity rules and applicable object set entered by business personnel, etc., and information of specified type elements (such as date) needs to be extracted from the worm.
[0050] LLM-2 is used for text semantic understanding. Its corresponding LLM needs to have strong context understanding and generalization capabilities, be able to handle ambiguity and complex language structures, and focus on deep semantic analysis. Furthermore, its corresponding text type can be set to the second text type mentioned above, such as long event description texts written by operators, story-based promotional texts, and other promotional texts that require intent understanding.
[0051] LLM-3 is used for security isolation or processing of multimodal data such as images and audio. Its corresponding LLM needs to have the ability to recognize specific words or process multimodal data; and its corresponding text type can be set to the aforementioned third text type.
[0052] In some embodiments, when model matching is performed based on text type, the LLM adapter corresponding to the text type includes multiple LLMs. In this case, any model can be selected as the above-mentioned label allocation model. The model selection is based on other pre-configured rules, such as the pre-configured set of optional models corresponding to each target product, the priority of multiple LLMs in the same LLM adapter, etc.
[0053] In some embodiments, to ensure model performance, this application employs the latest pre-trained LLM model. To further improve the accuracy and recall of recommendation label allocation, this application can further optimize the pre-trained LLM model. Specifically, it can be optimized through the following methods: fine-tuning or transfer learning the pre-trained model for the recommendation label allocation task to improve its performance on specific tasks; that is, using model quantization techniques to reduce the computational complexity and storage space of the model and improve inference speed; utilizing the parallel computing capabilities of graphics processing units (GPUs) to accelerate the training and inference process of the model; increasing the amount of training data and using more complex model structures to improve the generalization ability of the model.
[0054] Step S103: Input the text description information into the label assignment model, extract semantic features from the text description information through the label assignment model, and determine the similarity between the extracted target feature vector and the feature vectors of each reference label in the label library. In some embodiments, this application pre-configures a tag library including various tags, wherein the tags can be set according to needs, such as limited-time discounts, discounts for purchases over a certain amount, new product recommendations, etc.; each tag is configured with a clear definition and classification, which facilitates accurate matching and allocation by the subsequent model.
[0055] In one optional implementation, the above-mentioned text description information is input into the above-mentioned tag assignment model, and semantic feature extraction of the above-mentioned text description information is performed through the above-mentioned tag assignment model, including: Obtain the tag constraints and pre-configured prompt word templates corresponding to the target products mentioned above; the tag constraints are used to identify the selection range of recommended tags corresponding to the target products mentioned above; the prompt word templates include flags corresponding to the text description information and the tag constraints mentioned above respectively; Fill the corresponding flags in the prompt word template with the above text description information and the above tag constraints to construct the tag assignment prompt words; The aforementioned label assignment prompts are input into the aforementioned label assignment model, and the semantic features of the aforementioned text description information are extracted through the aforementioned label assignment model.
[0056] In some embodiments, before inputting the text description information into the label assignment model, this application also needs to construct corresponding label assignment prompts based on the text description information. Specifically, in this embodiment, a prompt template corresponding to the recommended labels can be configured. The specific content of the prompt template can be configured according to requirements, including the flag bits corresponding to the aforementioned text description information and label constraints, and may also include the configuration of the structure of the model's output content, such as setting it to output a structured list of recommended labels, which may include the identifiers of each recommended label and can be in JSON or other formats. When configuring the prompt template, since the goal is information extraction and classification, it is necessary to emphasize extraction and structured output in the prompt template.
[0057] In some embodiments, this application may provide a prompt word template management module through the MCP framework, which can automatically call and fill in customized prompt words for corresponding scenarios according to business processes, ensuring efficiency and accuracy.
[0058] In an optional implementation, before determining the similarity between the extracted feature vector and the feature vectors of each reference tag in the tag library, the method further includes: The above-mentioned tag constraints are extracted from the above-mentioned tag allocation prompts using the above-mentioned tag allocation model; Based on the above label constraints, a reference label corresponding to the target product is determined from the labels included in the above label library.
[0059] In some embodiments, to ensure that the generated matching labels are strictly based on a preset label library and that no illusions are generated, i.e. to ensure that the recommended labels output by the model are the labels in the label library, a label library locking mechanism is implemented, which forcibly binds the label library as the sole source of knowledge.
[0060] The aforementioned tag constraints can be configured based on requirements and carried through allocation instructions. Specifically, these tag constraints can be the list of tags to which the recommended tags for the target product belong, or the conditions that the recommended tags need to meet. This ensures that only authorized structured corpora can be used when generating recommended tags, meaning that recommended tags can only be determined from the reference tags corresponding to the tag constraints.
[0061] In some embodiments, this application may also bind the tag library as a unique data source by using blockchain fingerprint technology to solidify the version, such as hash verification of the InterPlanetary File System (IPFS).
[0062] In some embodiments, this application also provides a semantic vector isolation mechanism, that is, when the model generates unknown concepts, such as recommended tags that are not in the tag library, a blocking strategy is triggered to stop the process of recommending tags matching.
[0063] Step S104: Based on similarity, determine the recommended tags corresponding to the target product from each reference tag using the tag assignment model, and determine the confidence level of each recommended tag.
[0064] like Figure 3 As shown in the embodiments of this application, before inputting the above-mentioned text description information into the label allocation model, text preprocessing is required, which may include operations such as removing irrelevant characters, word segmentation, and removing stop words, in order to improve the accuracy and efficiency of subsequent processing.
[0065] After text preprocessing, semantic analysis and tag matching are performed using a tag assignment model. Specifically, the preprocessed text is semantically analyzed using the tag assignment model to extract the text's theme and identify key information (i.e., feature extraction). For example, when the text description information is basic information about a promotional activity, the semantic analysis process for the preprocessed text can be as follows: extract the corresponding theme of the promotional activity from the text description information, and identify its corresponding key information, including the target product's consumption type as "dining" and "online consumption," the discount form as "instant reduction," and the applicable scenarios as "holiday activities" and "exclusive for new users," etc., and generate a target feature vector based on the identified information. Then, a tag library matching process is performed, that is, matching the target feature vector with tags in the tag library to determine the recommended tags corresponding to the target product.
[0066] After obtaining the recommendation tags corresponding to the target product, the tags are automatically assigned and saved. The text description information, text type, and recommendation tags of the target product are stored in the product information database so that when users need product recommendations in the future, the system can quickly recommend relevant content based on the recommendation tags.
[0067] In some embodiments, this application presents a tag matching algorithm based on a vector space model and semantic similarity, specifically including: a feature extraction process, which extracts keywords and topic features from text description information to form a target feature vector; a similarity calculation process, which uses methods such as cosine similarity to calculate the similarity between the target feature vector and the feature vector of the reference tag; and a tag ranking process, which ranks the reference tags according to the similarity and determines the recommended tags from them.
[0068] In an optional implementation, the process of determining recommended tags corresponding to the target product from the reference tags based on the similarity using the tag allocation model, and determining the confidence level for each recommended tag, includes: The above label assignment model is used to select candidate labels from each reference label that have a similarity to the target feature vector that is higher than a preset threshold. If the number of candidate assigned tags is greater than the preset number, the candidate tags are sorted in descending order of similarity, and the first preset number of candidate assigned tags after sorting are determined as the recommended tags corresponding to the target product. Based on the similarity of each recommended tag, the confidence level of each recommended tag is determined.
[0069] In some embodiments, this application employs a dual-constraint strategy to determine recommended tags for scenarios involving multiple recommended tags corresponding to the same target product. Specifically, among candidate assigned tags with similarity greater than a preset threshold, the top N (preset number) are selected as recommended tags. This mechanism retains only candidate assigned tags with similarity greater than the preset threshold, ensuring that the assigned recommended tags are strongly relevant to the content. Among the retained recommended assigned tags, they are sorted in descending order of similarity score, and only the top N candidate assigned tags are selected as the final result, avoiding redundancy caused by too many tags and the burden on the subsequent recommendation system.
[0070] For example, assuming the preset threshold is 0.8 and the preset number is 4, even if the similarity of 10 candidate assignment labels is greater than 0.8, the system will only select the 4 candidate assignment labels with the highest scores for final assignment. This mechanism can balance quality (accuracy) and quantity (efficiency).
[0071] In some embodiments, when determining the confidence level of each recommended label based on the similarity of each recommended label, the similarity of each recommended label can be normalized, and the normalization result can be used as its corresponding confidence level.
[0072] In some embodiments, this application configures a database connection and operation module through an MCP architecture to be responsible for the system's data storage and retrieval. Specifically, this module can be used for database selection, connection management, and data operations. When selecting a database, for databases such as tag libraries and product information databases, the system can use a combination of relational databases (such as MySQL) and non-relational databases (such as MongoDB) to meet the storage needs of different types of data. When managing connections, the system designs an efficient database connection pool to ensure stable database connections even under high concurrency. When performing data operations, the system provides rich data operation interfaces, supports data CRUD operations, and performs transaction management for critical operations to ensure data consistency and integrity.
[0073] Since database query efficiency directly affects the overall performance of the recommendation system, the database index can be optimized and a more efficient query algorithm can be adopted in this embodiment to improve the system's response speed. It has been verified that reasonable index design and query optimization can improve the processing speed by about 30%.
[0074] In an optional implementation, after selecting a recommended label corresponding to the target product from the reference labels and determining the confidence level corresponding to each recommended label, the method further includes: Receive a product recommendation request from a user, which includes the user's needs information; the needs information is used to indicate the conditions that the recommended product must meet. Based on the above requirements, a product recommendation model corresponding to the above product recommendation request is matched from multiple pre-configured large language models. Input the above demand information into the above product recommendation model, and use the above product recommendation model to match candidate recommendation tags corresponding to the above recommended products from the tag library; If the aforementioned candidate recommendation tags correspond to multiple candidate products, the evaluation index value corresponding to each candidate product is determined through the aforementioned product recommendation model, and the aforementioned product to be recommended is determined from each candidate product based on the aforementioned evaluation index value, and feedback is given to the aforementioned user.
[0075] In some embodiments, after automatically assigning recommendation tags to each target product in the manner described above, this application can recommend products to users based on the recommendation tags corresponding to each product. This product recommendation process (i.e., the use of tags) is a reverse application of the automatic recommendation tag allocation mechanism. The aforementioned user product recommendation request can be automatically triggered after the user enters the demand information when there is a need for a certain type of product, or it can be automatically triggered when the user searches for products in the application.
[0076] In some embodiments, the above-mentioned demand information can be set based on user needs. For example, it can be set to require products that are available on Fridays, have high points, and have special offers at hot pot restaurants. This includes the conditions that the recommended products need to meet, namely, the applicable time includes Fridays and the applicable scenario includes hot pot restaurants.
[0077] In some embodiments, the process of matching candidate recommendation tags corresponding to the product to be recommended from the tag library using the product recommendation model described above is similar to the tag matching process in the recommendation tag allocation process described above, and will not be repeated here.
[0078] In one optional implementation, the process of matching a product recommendation model corresponding to the product recommendation request from a pre-configured pool of multiple large language models based on the aforementioned requirement information includes: Based on the above requirements, the text description information of the related products of the products to be recommended is retrieved from the product information database; Based on the retrieved text description information, a product recommendation model corresponding to the above product recommendation request is matched from multiple pre-configured large language models. The above-mentioned demand information is input into the above-mentioned product recommendation model, including: Input the retrieved text description information and the aforementioned requirement information into the product recommendation model.
[0079] In some embodiments, before determining the product to be recommended based on the product recommendation model, this application also needs to match the text description information corresponding to the demand information from the product information database based on the demand information. This matching process can be implemented based on the similarity between texts or other methods. The aforementioned associated product can be a product in the product information database whose text description information matches the aforementioned demand information.
[0080] In some embodiments, the process of inputting demand information into the product recommendation model specifically includes: Obtain the pre-configured prompt word template; the prompt word template includes: flags corresponding to the above text description information and the requirement information respectively; Fill the corresponding flags in the prompt word template with the above text description information and the above requirement information to construct product recommendation prompt words; Input the above product recommendation prompts into the above product recommendation model.
[0081] In some embodiments, before inputting textual description information and demand information into the product recommendation model, this application also needs to construct corresponding product recommendation prompts. Specifically, in this embodiment, a prompt template for instructing the model to make product recommendations can be configured. The specific content of the prompt template can be configured based on the demand, including not only the flag bits corresponding to the aforementioned textual description information and demand information, but also the configuration of the structure of the model's output content, such as configuring it to output a natural language recommendation summary and activity description. When configuring the prompt template, since the goal is intent understanding and content generation, it is necessary to emphasize analyzing user intent, filtering and ranking, and generating attractive text in the prompt template, while combining user profiles and decision principles to emphasize extraction and structured output.
[0082] In one optional implementation, the evaluation indicators corresponding to the candidate products include at least one of relevance indicators, user preference indicators, timeliness indicators, and priority indicators; for any candidate product, the evaluation indicator value corresponding to the candidate product is determined based on at least one of the following methods: Based on the overlap between the multiple recommendation tags corresponding to the above candidate products and the candidate recommendation tags corresponding to the above recommended products, the indicator values corresponding to the above relevance indicators for the above candidate products are determined. Determine the user profile of the above users, predict the user's preference for the above candidate products based on the above user profile, and obtain the index value corresponding to the above candidate products and the above user preference index. Based on the matching degree between the usage time corresponding to the above candidate products and the time information included in the above demand information, the indicator values corresponding to the above candidate products and the above timeliness indicators are determined. Based on the pre-configured priorities of each product, the indicator values corresponding to the above candidate products and the above priority indicators are determined.
[0083] In some embodiments, multiple candidate recommendation tags are typically matched based on the product recommendation model. After obtaining each candidate recommendation tag, the candidate product corresponding to each candidate recommendation tag can be obtained. If multiple candidate products are matched, the recommendation system needs to execute a multi-dimensional decision and ranking algorithm.
[0084] Specifically, when making decisions and prioritizing, a comprehensive evaluation can be conducted based on the following indicators: The relevance index is determined by the degree of overlap and similarity between the set of candidate recommendation tags generated after identifying user intent based on user demand information and the set of recommendation tags corresponding to each candidate product. Optionally, when determining the index value in this way, the confidence level of each recommendation tag corresponding to the candidate product can be taken into account, such as by weighting the tags based on the confidence level.
[0085] User preference metrics (i.e., personalized metrics) can combine a user's historical consumption records, location information, and product information (such as level) to determine the user profile, and then personalize the matched candidate products based on the user profile. In other words, based on the user profile, the user's preference for each candidate product is predicted, and the corresponding metric value for each candidate product is determined based on the preference.
[0086] For timeliness indicators, since some products have applicable time periods, if the demand information includes time requirements (i.e., time information), when recommending products, it is necessary to consider the matching degree between candidate products and time information, and give priority to recommending products that are about to expire, or products that are most applicable at the time specified in the demand information (such as limited products).
[0087] Priority metrics: In this embodiment, the priority of each product can be pre-configured. During implementation, higher priorities can be manually set for products that are being promoted or have high conversion rates to ensure they are recommended first. The conversion relationship between priority and metric values can be pre-configured; for example, the metric values of timeliness indicators corresponding to different priorities can be configured.
[0088] In one optional implementation, if there are multiple evaluation indicators corresponding to the candidate products, then determining the product to be recommended from the candidate products based on the evaluation indicator values includes: For any candidate product, the comprehensive evaluation value of the candidate product is determined based on the weights corresponding to each evaluation indicator value (which can be set according to requirements) and the evaluation indicator values corresponding to the candidate product. Based on the comprehensive evaluation value of each candidate product, at least one product to be recommended is selected from the above candidate products.
[0089] In some embodiments, if the number of candidate products is lower than a preset quantity threshold, all candidate products can be used as recommended products, and the candidate products can be sorted by the comprehensive evaluation value determined in the above manner before feedback is given to the user; if the number of candidate products is not lower than the preset quantity threshold, the recommended products with a preset quantity threshold can be selected from the candidate products based on the comprehensive evaluation value determined in the above manner and feedback is given to the user.
[0090] For example, suppose a user's request carries the following requirements: need a product on Friday with high points and a hot pot restaurant promotion.
[0091] After receiving the demand information, the recommendation system uses a product recommendation model to identify the intent and match tags, transforming it into a standard tag set, namely the set of candidate recommendation tags mentioned above, which includes candidate recommendation tags such as high points, food and beverage, and Friday specials.
[0092] Then (from the product information database) query the candidate products associated with the above candidate recommendation tags. These candidate products include: Product A, which is associated with food and beverage and high points; Product B, which is associated with Friday limited-time offers and instant discounts; and Product C, which is associated with food and beverage.
[0093] The evaluation index values corresponding to the above candidate products and the relevance index, user preference index, and timeliness index are determined respectively, and they are ranked according to the evaluation index values. For example, the ranking result for the relevance index is A>B>C, the ranking result for the timeliness index is B=A>C, and the ranking result for the user preference index is A>B=C. Based on this, the ranking of the candidate products can be determined as A, B, C. If the preset threshold for the number of products to be recommended is 2, then the products to be recommended are determined as A and B.
[0094] It should be noted that if the final order of candidate products cannot be determined solely by ranking the individual values of each evaluation indicator, then it is necessary to determine the corresponding comprehensive evaluation value and rank the candidate products accordingly.
[0095] In some embodiments, when assigning recommendation tags based on a tag assignment model, the performance of the tag assignment model can be evaluated. Specifically, the performance evaluation process can refer to metrics such as accuracy and recall, as well as processing speed and efficiency. Among these, accuracy and recall are key evaluation metrics in recommendation tag assignment methods. Accuracy measures the proportion of tags correctly assigned by the system, while recall reflects the system's ability to identify and assign all relevant tags. Processing speed and efficiency are another important aspect of evaluating the performance of a recommendation system. In practical applications, the system needs to process a large amount of data and make recommendation decisions in a very short time. The LLM-based recommendation system provided in this application embodiment performs well in terms of processing speed, processing an average of about 500 data entries per second. However, as the amount of data increases, the system's processing efficiency will decrease. At this time, processing efficiency can be improved by optimizing the algorithm and hardware configuration.
[0096] In some embodiments, to cope with large amounts of data and high concurrency requests, this application adopts a distributed computing framework and multithreading technology to improve the parallel processing capability of the system, thereby improving processing efficiency. It has been verified that the optimized system can improve speed by about 50% when processing the same amount of data, thus better meeting the needs of real-time recommendation.
[0097] In some embodiments, the recommendation tag allocation method in this application can support multimodal fusion, combining multiple data types such as images, videos, and text to provide more comprehensive recommendation tags; it supports real-time enhancement, achieving faster tag allocation and recommendation response through algorithm and computing resource optimization; and it supports personalized customization, utilizing deep learning technology to further improve the personalization of recommendations and user satisfaction.
[0098] The recommendation tag allocation method described in this application can be applied to various scenarios, including online shopping platforms and social media platforms. Online shopping platforms typically possess massive amounts of product information and user behavior data. The LLM-based recommendation tag allocation method can automatically assign tags to these products, thereby improving the accuracy of product recommendations and user satisfaction. Social media platforms also face the challenge of processing and recommending massive amounts of information. The LLM-based recommendation tag allocation method can help these platforms manage and recommend content more effectively; by analyzing user comments, likes, and shares, LLM can automatically assign relevant tags to each piece of content, thereby improving the accuracy of recommendations and user engagement.
[0099] The above methods improve the accuracy of product recommendations and user satisfaction, thereby increasing user stickiness and conversion rates on the corresponding platforms; through more accurate content recommendations, information overload is effectively reduced, the efficiency of users obtaining information is improved, and the effective dissemination of information is promoted; in addition, this method can also help content creators better understand audience needs and improve the quality and influence of their creations.
[0100] Based on the same inventive concept, embodiments of this application provide a recommendation label allocation device, please refer to... Figure 4 The device includes: The information acquisition module 401 is used to acquire text description information corresponding to the target product in response to an instruction to assign recommendation tags to the target product. The assignment model matching module 402 is used to determine the text type corresponding to the above text description information, and based on the above text type, match the tag assignment model corresponding to the above target product from multiple pre-configured large language models. The similarity determination module 403 is used to input the above text description information into the above label allocation model, extract semantic features from the above text description information through the above label allocation model, and determine the similarity between the extracted target feature vector and the feature vector of each reference label in the label library. The label determination module 404 is used to determine the recommended label corresponding to the target product from the reference labels based on the similarity using the label allocation model, and to determine the confidence level of each recommended label.
[0101] In one possible embodiment, the similarity determination module 403 described above is specifically used for: Obtain the tag constraints and pre-configured prompt word templates corresponding to the target products mentioned above; the tag constraints are used to identify the selection range of recommended tags corresponding to the target products mentioned above; the prompt word templates include flags corresponding to the text description information and the tag constraints mentioned above respectively; Fill the corresponding flags in the prompt word template with the above text description information and the above tag constraints to construct the tag assignment prompt words; The aforementioned label assignment prompts are input into the aforementioned label assignment model, and the semantic features of the aforementioned text description information are extracted through the aforementioned label assignment model.
[0102] In one possible embodiment, the similarity determination module 403 described above is further configured to: The above-mentioned tag constraints are extracted from the above-mentioned tag allocation prompts using the above-mentioned tag allocation model; Based on the above label constraints, a reference label corresponding to the target product is determined from the labels included in the above label library.
[0103] In one possible embodiment, the label determination module 404 described above is specifically used for: The above label assignment model is used to select candidate labels from each reference label that have a similarity to the target feature vector that is higher than a preset threshold. If the number of candidate assigned tags is greater than the preset number, the candidate tags are sorted in descending order of similarity, and the first preset number of candidate assigned tags after sorting are determined as the recommended tags corresponding to the target product. Based on the similarity of each recommended tag, the confidence level of each recommended tag is determined.
[0104] In one possible embodiment, the above-described apparatus further includes: The request receiving module is used to receive product recommendation requests from users, which include the user's demand information. The demand information is used to indicate the conditions that the recommended product must meet. The recommendation model matching module is used to match the product recommendation model corresponding to the above product recommendation request from multiple pre-configured large language models based on the above requirement information. The tag matching module is used to input the above-mentioned demand information into the above-mentioned product recommendation model, and to match the candidate recommendation tags corresponding to the above-mentioned product to be recommended from the tag library through the above-mentioned product recommendation model; The product determination module is used to determine the evaluation index value corresponding to each candidate product through the product recommendation model if the above candidate recommendation tag corresponds to multiple candidate products, and to determine the product to be recommended from each candidate product based on the above evaluation index value, and to provide feedback to the above user.
[0105] In one possible embodiment, the above-described recommendation model matching module is specifically used for: Based on the above requirements, the text description information of the related products of the products to be recommended is retrieved from the product information database; Based on the retrieved text description information, a product recommendation model corresponding to the above product recommendation request is matched from multiple pre-configured large language models. The aforementioned tag matching module is specifically used for: Input the retrieved text description information and the aforementioned requirement information into the product recommendation model.
[0106] In one possible embodiment, the evaluation metrics corresponding to the candidate products include at least one of relevance metrics, user preference metrics, timeliness metrics, and priority metrics; for any candidate product, the evaluation metric value corresponding to the candidate product is determined based on at least one of the following methods: Based on the overlap between the multiple recommendation tags corresponding to the above candidate products and the candidate recommendation tags corresponding to the above recommended products, the indicator values corresponding to the above relevance indicators for the above candidate products are determined. Determine the user profile of the above users, predict the user's preference for the above candidate products based on the above user profile, and obtain the index value corresponding to the above candidate products and the above user preference index. Based on the matching degree between the usage time corresponding to the above candidate products and the time information included in the above demand information, the indicator values corresponding to the above candidate products and the above timeliness indicators are determined. Based on the pre-configured priorities of each product, the indicator values corresponding to the above candidate products and the above priority indicators are determined.
[0107] In one possible embodiment, if there are multiple evaluation indicators corresponding to the candidate products, then the product determination module is specifically used for: For any candidate product, the comprehensive evaluation value of the candidate product is determined based on the weights corresponding to each evaluation index value and the evaluation index values corresponding to the candidate product. Based on the comprehensive evaluation value of each candidate product, at least one product to be recommended is selected from the above candidate products.
[0108] Based on the same inventive concept, this application provides an electronic device that can realize the function of the recommendation tag allocation device described above. Please refer to... Figure 5 The device includes at least one processor 501 and a memory 502 connected to the at least one processor. In this embodiment, the specific connection medium between the processor 501 and the memory 502 is not limited. Figure 5 The processor 501 and memory 502 can be connected via a bus. The bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 5 The symbol is represented by only one line, but this does not mean that there is only one bus or one type of bus.
[0109] The processor 501 is the control center of the electronic device. It can connect to various parts of the electronic device through various interfaces and lines. By running or executing instructions stored in the memory 502 and calling data stored in the memory 502, it can achieve the allocation of recommended tags. Optionally, the processor 501 may include one or more processing units. The processor 501 may integrate an application processor and a modem processor. The application processor mainly handles the operating system, user interface, and applications, while the modem processor mainly handles issuing instructions. It is understood that the modem processor may not be integrated into the processor 501. In some embodiments, the processor 501 and the memory 502 may be implemented on the same chip; in some embodiments, they may also be implemented on separate chips.
[0110] Processor 501 can be a general-purpose processor, such as a central processing unit (CPU), digital signal processor, application-specific integrated circuit (ASIC), field-programmable gate array (FPGA), or other programmable logic device, discrete gate or transistor logic device, or discrete hardware component, capable of implementing or executing the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of the recommended tag allocation method can be directly manifested as execution by a hardware processor, or execution by a combination of hardware and software modules within the processor.
[0111] Memory 502, as a non-volatile computer-readable storage medium, can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules. Memory 502 may include at least one type of storage medium, such as flash memory, hard disk, multimedia card, card-type memory, random access memory (RAM), static random access memory (SRAM), programmable read-only memory (PROM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), magnetic memory, magnetic disk, optical disk, etc. Memory 502 can be any other medium capable of carrying or storing desired program code in the form of instructions or data structures that can be accessed by a computer, but is not limited thereto. In the embodiments of this application, memory 502 can also be a circuit or any other device capable of implementing storage functions for storing program instructions and / or data.
[0112] In this embodiment, the memory 502 stores a computer program that, when executed by the processor 501, causes the processor 501 to perform the steps described in the above-described recommended tag allocation method.
[0113] Based on the same inventive concept, embodiments of this application provide a computer-readable storage medium. The computer program product includes computer program code, which, when executed on a computer, causes the computer to perform any of the recommendation tag allocation methods discussed above. Since the principle by which the above-described computer-readable storage medium solves the problem is similar to that of the recommendation tag allocation method, the implementation of the above-described computer-readable storage medium can be referred to the implementation of the method, and repeated details will not be elaborated further.
[0114] Based on the same inventive concept, this application also provides a computer program product, which includes computer program code that, when run on a computer, causes the computer to execute any of the recommendation tag allocation methods discussed above. Since the principle by which the above computer program product solves the problem is similar to that of the recommendation tag allocation method, the implementation of the above computer program product can be referred to the implementation of the method, and repeated details will not be elaborated further.
[0115] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0116] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to this application. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0117] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0118] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of user-operated steps to be executed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0119] Obviously, those skilled in the art can make various modifications and variations to this application without departing from the spirit and scope of this application. Therefore, if such modifications and variations fall within the scope of the claims of this application and their equivalents, this application also intends to include such modifications and variations.
Claims
1. A method for assigning recommendation tags, characterized in that, The method includes: In response to an instruction to assign recommendation tags to a target product, obtain text description information corresponding to the target product; Determine the text type corresponding to the text description information, and based on the text type, match the tag assignment model corresponding to the target product from multiple pre-configured large language models; The text description information is input into the tag assignment model, the tag assignment model extracts semantic features from the text description information, and determines the similarity between the extracted target feature vector and the feature vectors of each reference tag in the tag library; Based on the similarity, the tag assignment model determines recommended tags corresponding to the target product from the reference tags and determines the confidence level of each recommended tag.
2. The method as described in claim 1, characterized in that, The step of inputting the text description information into the label assignment model and extracting semantic features from the text description information through the label assignment model includes: Obtain the tag constraints and pre-configured prompt word templates corresponding to the target product; the tag constraints are used to identify the selection range of recommended tags corresponding to the target product; the prompt word template includes flag bits corresponding to the text description information and the tag constraints respectively; The text description information and the tag constraints are filled into the corresponding flags in the prompt word template to construct the tag assignment prompt words; The tag assignment prompts are input into the tag assignment model, and the semantic features of the text description information are extracted through the tag assignment model.
3. The method as described in claim 2, characterized in that, Before determining the similarity between the extracted feature vector and the feature vectors of each reference tag in the tag library, the method further includes: The tag constraint conditions are extracted from the tag allocation prompts using the tag allocation model. Based on the aforementioned tag constraints, a reference tag corresponding to the target product is determined from the tags included in the tag library.
4. The method as described in claim 1, characterized in that, The step of determining recommended tags corresponding to the target product from the reference tags based on the similarity using the tag allocation model, and determining the confidence level of each recommended tag, includes: The label assignment model filters candidate labels from each reference label that have a similarity to the target feature vector higher than a preset threshold. If the number of candidate assigned tags is greater than the preset number, the candidate tags are sorted in descending order of similarity, and the first preset number of candidate assigned tags after sorting are determined as the recommended tags corresponding to the target product. Based on the similarity of each recommended tag, the confidence level of each recommended tag is determined.
5. The method according to any one of claims 1 to 4, characterized in that, After selecting a recommended label corresponding to the target product from the reference labels and determining the confidence level of each recommended label, the method further includes: Receive a product recommendation request from a user, the product recommendation request including the user's needs information; the needs information is used to indicate: the conditions that the recommended product must meet; Based on the aforementioned demand information, a product recommendation model corresponding to the product recommendation request is matched from multiple pre-configured large language models. The demand information is input into the product recommendation model, and the product recommendation model matches candidate recommendation tags corresponding to the product to be recommended from the tag library. If the candidate recommendation tag corresponds to multiple candidate products, the evaluation index value corresponding to each candidate product is determined by the product recommendation model, and the product to be recommended is determined from each candidate product based on the evaluation index value, and feedback is given to the user.
6. The method as described in claim 5, characterized in that, The step of matching a product recommendation model corresponding to the product recommendation request from a pre-configured pool of multiple large language models based on the demand information includes: Based on the aforementioned demand information, the text description information of the associated products of the product to be recommended is retrieved from the product information database; Based on the retrieved text description information, a product recommendation model corresponding to the product recommendation request is matched from multiple pre-configured large language models; The step of inputting the demand information into the product recommendation model includes: The retrieved text description information and the required information are input into the product recommendation model.
7. The method as described in claim 5, characterized in that, The evaluation metrics for the candidate products include at least one of relevance metrics, user preference metrics, timeliness metrics, and priority metrics; for any candidate product, the evaluation metric value is determined based on at least one of the following methods: Based on the overlap between the multiple recommendation tags corresponding to the candidate products and the candidate recommendation tags corresponding to the product to be recommended, the indicator value corresponding to the relevance indicator of the candidate products is determined. Determine the user profile of the user, predict the user's preference for the candidate products based on the user profile, and obtain the index value corresponding to the candidate products and the user preference index. Based on the matching degree between the usage time corresponding to the candidate product and the time information included in the demand information, the indicator value corresponding to the timeliness indicator of the candidate product is determined. Based on the pre-configured priorities of each product, the indicator values corresponding to the priority indicators of the candidate products are determined.
8. The method as described in claim 5, characterized in that, If there are multiple evaluation indicators corresponding to the candidate products, then determining the product to be recommended from the candidate products based on the evaluation indicator values includes: For any candidate product, the comprehensive evaluation value of the candidate product is determined based on the weights corresponding to each evaluation index value and the evaluation index values corresponding to the candidate product. Based on the comprehensive evaluation value of each candidate product, at least one product to be recommended is determined from the candidate products.
9. A recommendation label distribution device, characterized in that, The device includes: The information acquisition module is used to acquire text description information corresponding to the target product in response to an instruction to assign recommendation tags to the target product; The assignment model matching module is used to determine the text type corresponding to the text description information, and based on the text type, match the tag assignment model corresponding to the target product from a pre-configured set of large language models; The similarity determination module is used to input the text description information into the tag allocation model, extract semantic features from the text description information through the tag allocation model, and determine the similarity between the extracted target feature vector and the feature vectors of each reference tag in the tag library. The tag determination module is used to determine recommended tags corresponding to the target product from the reference tags based on the similarity using the tag allocation model, and to determine the confidence level of each recommended tag.
10. The apparatus as claimed in claim 9, characterized in that, The label determination module is specifically used for: The label assignment model filters candidate labels from each reference label that have a similarity to the target feature vector higher than a preset threshold. If the number of candidate assigned tags is greater than the preset number, the candidate tags are sorted in descending order of similarity, and the first preset number of candidate assigned tags after sorting are determined as the recommended tags corresponding to the target product. Based on the similarity of each recommended tag, the confidence level of each recommended tag is determined.
11. The apparatus as claimed in claim 9, characterized in that, The device further includes: The request receiving module is used to receive product recommendation requests from users, the product recommendation requests including user demand information; the demand information is used to indicate the conditions that the recommended products need to meet; The recommendation model matching module is used to match the product recommendation model corresponding to the product recommendation request from a number of pre-configured large language models based on the demand information. The tag matching module is used to input the demand information into the product recommendation model, and match candidate recommendation tags corresponding to the product to be recommended from the tag library through the product recommendation model; The product determination module is used to determine the evaluation index value corresponding to each candidate product through the product recommendation model if the candidate recommendation tag corresponds to multiple candidate products, and to determine the product to be recommended from each candidate product based on the evaluation index value, and to provide feedback to the user.
12. An electronic device, characterized in that, include: Memory, used to store program instructions; A processor is configured to invoke program instructions stored in the memory and execute the steps of the method according to any one of claims 1 to 8.
13. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program, the computer program including program instructions that, when executed by a computer, cause the computer to perform the method as described in any one of claims 1 to 8.
14. A computer program product, characterized in that, The computer program product includes: computer program code, which, when run on a computer, causes the computer to perform the method described in any one of claims 1 to 8.