Recommendation intention recognition method based on soft prompt fine tuning

By employing a soft-cue-based fine-tuning method, combined with a large language model to generate semantic interpretations and a dynamic update mechanism, the challenge of identifying recommendation intent in live-stream e-commerce bullet comments is solved. This achieves efficient and accurate recommendation intent identification and real-time response, and is applicable to multiple fields.

CN121509754APending Publication Date: 2026-02-10YANGZHOU UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511671750.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-14
Publication Date
2026-02-10

AI Technical Summary

Technical Problem

In live-stream e-commerce scenarios, existing methods struggle to efficiently identify recommendation intent in bullet comments, especially since bullet comments are extremely brief, highly context-dependent, and rapidly changing, making it difficult for traditional models to dynamically update and effectively address concept drift.

Method used

We adopt a recommendation intent recognition method based on soft cue fine-tuning. By combining a large language model to generate semantic interpretations, we design a dynamic update mechanism and construct a dynamic semantic anchor word pool. We use the soft cue fine-tuning model to dynamically adjust input cue in the case of few samples, thereby optimizing the recommendation intent recognition effect.

Benefits of technology

It improves the accuracy of recommendation intent recognition and the system's real-time response capability, enabling accurate identification of recommendation intent in bullet comments under limited sample conditions, reducing manual annotation workload, lowering operating costs, and is applicable to fields such as live e-commerce and social media interaction analysis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121509754A_ABST
    Figure CN121509754A_ABST
Patent Text Reader

Abstract

The invention discloses a recommendation intention recognition method based on soft prompt fine tuning, which comprises the following steps: 1) setting a historical window to capture historical information, generating semantic interpretation by introducing a large language model, and combining the generated semantic interpretation with original bullet screen comments to form extended input representation; 2) designing a dynamic updating mechanism, constructing a dynamic semantic anchor word pool, and improving the accurate recognition of the recommendation intention by dynamically adjusting and expanding the semantic coverage range; and 3) under the condition of few samples, dynamically adjusting the input prompt by training a small number of adjustable soft prompt vectors by utilizing the soft prompt fine tuning model, thereby optimizing the recommendation intention recognition effect of the prompt learning model. According to the method, the semantic interpretation is generated in combination with the large language model, the semantic sparse problem of the short text is solved, the recommendation intention in the bullet screen comments is recognized in real time through a soft prompt fine tuning and dynamic updating mechanism, and the recognition accuracy of the recommendation intention and the real-time response capability of the system are effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of natural language processing, in particular to a recommendation intention recognition method based on soft prompt fine-tuning. BACKGROUND

[0002] With the rise of live e-commerce, live streaming platforms have gradually become one of the important sales modes of modern e-commerce. However, with the explosive growth of live streaming comments in the live streaming scene, how to efficiently and accurately identify potential recommendation intentions has become a technical problem to be solved. Traditional recommendation intention recognition methods mostly rely on user historical behavior data, but in the live e-commerce environment, due to the extremely short and highly context-dependent nature of the live streaming comments sent by the audience in real time, traditional methods cannot effectively distinguish between recommendation intentions and casual content.

[0003] Currently, deep learning-based text analysis methods are widely used in short text classification, but due to the extremely short text, sparse semantics, and rapid changes of live streaming comments in live e-commerce, existing methods are difficult to cope with this challenge. At the same time, the language of live streaming comments has strong real-time and context changes, and the model needs to quickly adapt to these changes, while traditional models often have difficulty in dynamically updating and effectively dealing with concept drift problems. SUMMARY

[0004] In view of the deficiencies in the prior art, the present application provides a recommendation intention recognition method based on soft prompt fine-tuning, which generates semantic explanations by combining large language models, solves the problem of sparse semantics of short text, and through soft prompt fine-tuning and dynamic updating mechanism, real-time recognition of recommendation intentions in live streaming comments, effectively improving the accuracy of recommendation intention recognition and the real-time response ability of the system, solving the problem that existing methods cannot efficiently recognize recommendation intentions in the live e-commerce scene.

[0005] The purpose of the present application is achieved by a recommendation intention recognition method based on soft prompt fine-tuning, comprising the following steps:

[0006] 1) Set a history window to capture historical information, generate semantic explanations by introducing a large language model, combine the generated semantic explanations with the original live streaming comments, and form an expanded input representation;

[0007] 2) Design a dynamic updating mechanism to build a dynamic semantic anchor pool, dynamically adjust and expand the semantic coverage to improve the accuracy of recommendation intention recognition;

[0008] 3) In the case of few samples, use a soft prompt fine-tuning model to dynamically adjust the input prompt by training a small number of adjustable soft prompt vectors, thereby optimizing the recommendation intention recognition effect of the prompt learning model.

[0009] Further, the step 1) specifically comprises:

[0010] Step 1.1) By setting a historical context window, the current time point t of the barrage comment is associated with its k historical barrage comments, and a historical context set H is constructed t ;

[0011] Specifically, the historical context set H t is:

[0012]

[0013] Wherein, represents the time step, C t is the barrage comment (original text) of time step t, and k is the set historical window size;

[0014] Step 1.2) The semantic interpretation of each barrage comment is generated by using a large language model, and the language model function is used to infer the potential motivation and expression intention of the user;

[0015] Specifically, the semantic interpretation E t of C t is generated by the following formula:

[0016]

[0017] Wherein, is a generation function based on a large language model, which represents the potential semantics and motivation of C t in the historical context set H t by a large language model;

[0018] Step 1.3) The generated semantic interpretation is combined with the original barrage comment to form an extended input representation, which is further passed to the downstream recommendation intention recognition model for processing;

[0019] By splicing C t and its corresponding E t , a new input sequence is formed and input into the recommendation intention recognition model, and the recommendation intention recognition model determines the intention based on the spliced information.

[0020] Further, the step 2) specifically comprises:

[0021] Step 2.1) A semantic anchor word set is constructed for each recommendation intention category;

[0022] The system constructs a semantic anchor word set for each label category , wherein Let y0 represent "casual conversation" and y1 represent "purchase intention". Define a set of anchor words that are semantically related to the category. Each anchor word set It contains several semantically related words that can represent this category, and is specifically constructed as follows:

[0023]

[0024] in, For semantic vocabulary related to category y, n y This represents the number of anchor words in this category.

[0025] Step 2.2) Construct a candidate word set and use a zero-shot classifier to filter out words relevant to the current context to further identify words related to user intent;

[0026] For C t Word segmentation is performed, and part-of-speech tagging technology is used to retain nouns, verbs, and proper nouns, thus constructing a candidate word set. , is represented as:

[0027]

[0028] Among them, Filter(C) t ) indicates that for C t Candidate words selected after word segmentation and part-of-speech tagging;

[0029] Then, the system uses a zero-shot classifier to classify the candidate word set. Mapped to a natural language template, words highly relevant to the current semantic environment are selected to form a candidate word set W related to the current context. rel The specific process is as follows:

[0030]

[0031] Here, zero-shot classifier Used to determine each candidate word Is it relevant to the current context?

[0032] Step 2.3) Assign a label category to each candidate word by calculating the semantic distance;

[0033] Obtain W rel Then, the system will... Mapped into a d-dimensional semantic embedding space, it is represented as Then, the semantic distance between the candidate word w and each label category y is calculated. The specific calculation formula is as follows:

[0034]

[0035] in, and These are the representations of candidate word w and anchor word w' in the semantic embedding space, respectively. This represents the cosine similarity function; this distance measures the semantic similarity between candidate word w and category y, and the smaller the distance, the more word w matches the semantics of category y.

[0036] By calculating the semantic distance of each candidate word w, the system assigns a most relevant label category to each word. Its decision-making rules are as follows:

[0037]

[0038] That is, the choice makes The smallest category y is used as the semantic label for candidate word w;

[0039] Step 2.4) Update the set of semantic anchor words for each category;

[0040] The system weights each candidate word w according to its semantic proximity to category y; specifically, the weights... Adjustments will be made according to the following rules in each update round:

[0041]

[0042] in, Let λ be the weight of word w in the previous iteration, and λ be the decay factor, usually set to 1. In the half-life parameter Under the control of [the system], the decay rate is set to 10;

[0043] Step 2.5) Retain the k highest-scoring anchor words for each category to construct the final dynamic semantic anchor word set;

[0044] In each update, the system will determine the semantic proximity of each candidate word to the category label y and its weight. The score is calculated using the following formula:

[0045]

[0046] The score combines the candidate word w with the current category. The higher the score of the semantic similarity and the activity of the word, the stronger the representativeness of the candidate word w for the current category.

[0047] Ultimately, in each batch, the system for each category Select the k candidate words with the highest scores to form the semantic anchor word set for this category. ,Right now:

[0048]

[0049] in, This indicates that the top k words by score are selected, resulting in the final score. This constitutes the dynamic semantic anchor word set for the current time step t;

[0050] Step 2.6) Merge all categories of dynamic anchor word sets to form the final dynamic semantic anchor word pool;

[0051] All categories of dynamic semantic anchor words and Ultimately, these are merged into the dynamic semantic anchor word pool of the entire model. , is represented as:

[0052]

[0053] in, express Within the category, the set of dynamic semantic anchor words at time step t; express Within the category, the set of dynamic semantic anchor words at time step t;

[0054] Semantic anchor word pool It is used to guide the recommendation intent recognition task during each training and inference process.

[0055] Furthermore, step 3) specifically includes:

[0056] Step 3.1) Perform task modeling for recommendation intent recognition, and construct a model for each C. t Classify them and determine whether they contain recommendation intent;

[0057] The recommendation intent recognition is modeled as a binary classification problem, where Indicates the category of recommendation intent. This indicates that it contains a recommendation intent. This refers to comments that are casual conversational or otherwise not intended for recommendation; the specific task modeling is as follows:

[0058]

[0059] in, For the predicted label, A classifier used to predict the category of recommendation intent based on the input comments and explanations;

[0060] Step 3.2) Construct and train a soft cue fine-tuning model. Using the soft cue fine-tuning model, the input cue can be dynamically adjusted by training a small number of adjustable soft cue vectors.

[0061] Step 3.3) Predict the recommendation intent category by combining mask word probability modeling with dynamic annotation mechanism, and select the category with the highest probability as the predicted recommendation intent for a given bullet screen comment.

[0062] Furthermore, step 3.2) specifically includes:

[0063] Step 3.2.1) Construct a soft suggestion template and use soft suggestion optimization methods to adjust C. t Transform it into a soft-hint template that includes dynamic learning suggestions; the template not only includes C t It also incorporates E t and a set of adjustable soft cue vectors. ;

[0064] The specific soft suggestion template T is shown below:

[0065]

[0066] in, These are the soft cue vectors learned during model training. The label location used by the model to predict recommendation intent;

[0067] Step 3.2.2) Generate hidden layer representations through PLM encoding. Input the constructed soft cue template T into the pre-trained language model. The pre-trained language model will process the template through the encoder and generate hidden vector representations of the input sequence; the process is as follows:

[0068]

[0069] in, It is C t The encoded vector, It is E t The encoded vector, This indicates the encoding result of the soft prompt symbol, e mask The encoded vector representing the mask position is used for subsequent mask prediction;

[0070] Step 3.2.3) Enhance the context adaptability of soft cue vectors by introducing a bidirectional LSTM into the soft cue symbols;

[0071] Specifically, for The updated calculation formula is as follows:

[0072]

[0073] Step 3.2.4) The learning objective of the soft cue vector is achieved by minimizing the mask prediction loss function as follows:

[0074]

[0075] in, This represents minimizing the mask prediction loss function. The target of the mask prediction task.

[0076] Furthermore, step 3.3) specifically includes:

[0077] Step 3.3.1) Predict the recommendation intent category, given... and As input sequences, these inputs are processed through a soft template structure. Embedded into the language model, the language model predicts and fills in the blanks. Position is a tag word The probability of this can be used to model the intent recognition problem as a mask word probability modeling problem:

[0078]

[0079] Combined with the dynamic labeler mechanism, each category A set of corresponding tags will be assigned. In the calculation process, it is assumed that each label contributes equally to the classification, then the predicted score of category y is... Defined as:

[0080]

[0081] Finally, the model selects the category with the highest probability as the predicted recommendation intent for a given bullet screen comment;

[0082] Step 3.3.2) During the training phase, the standard cross-entropy loss function is used with the addition of an L2 regularization term, resulting in the overall loss function. Defined as:

[0083]

[0084] Where, N a This represents the total number of training samples. It is the true label of the i-th sample, T(x) i ) represents the corresponding soft template input, and θ represents the model parameters. It is the L2 regularization term, and α is the regularization coefficient.

[0085] Compared with the prior art, the beneficial effects of the present invention are: (1) By combining large language model to generate semantic interpretation and soft prompting fine-tuning technology, the present invention can accurately identify the recommendation intent in live e-commerce under the condition of few samples, and has higher recognition accuracy and robustness than traditional methods.

[0086] (2) The dynamic update mechanism of the present invention can adjust the model input in real time by combining semantic distance and time decay strategies, adapt to the rapidly changing language environment in live e-commerce, and solve the problems of concept drift and semantic change.

[0087] (3) The recommendation intent recognition method of the present invention can automatically and in real time process bullet screen data, reduce the workload of manual annotation and screening, improve efficiency, reduce operating costs, and promote the automation of recommendation systems.

[0088] (4) This invention is not only applicable to live e-commerce platforms, but can also be extended to social media interaction analysis, sentiment analysis and other fields. It has strong adaptability and market prospects, and promotes the further development of related technologies. Attached Figure Description

[0089] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.

[0090] Figure 1 Overall block diagram of the present invention. Detailed Implementation

[0091] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0092] like Figure 1 The following is an example of a recommendation intent recognition method based on soft cue fine-tuning, comprising the following steps:

[0093] 1) A history window is set up to capture historical information. A large language model is introduced to generate semantic explanations. The generated semantic explanations are combined with the original bullet screen comments to form an extended input representation. By introducing a large language model to generate semantic explanations, the semantic representation of bullet screen comments in short texts is enhanced, solving the challenge of identifying potential intentions in short texts. This explanation generation module provides a semantic-level explanation for each bullet screen comment by analyzing historical bullet screen information, which significantly improves the model's ability to identify implicit recommendation intentions.

[0094] Step 1.1) By setting up a history context window, associate the current time point t with its k historical comments to construct a history context set H.t ;

[0095] Specifically, the historical context set H t for:

[0096]

[0097] in, Indicates time step, C t The barrage comments (original text) are at time step t, and k is the set history window size;

[0098] Step 1.2) Generate a semantic explanation for each bullet comment using a large language model, through a language model function. Inferring the user's underlying motivations and expressed intentions;

[0099] Specifically, for C t Semantic interpretation E t It is generated by the following formula:

[0100]

[0101] in, It is a generator function based on a large language model, representing the inference of C through the large language model. t In the historical context set H t The underlying semantics and motivations;

[0102] Step 1.3) Combine the generated semantic interpretation with the original bullet screen comments to form an extended input representation, which is then passed to the downstream recommendation intent recognition model for processing;

[0103] By C t Its corresponding E t The sequences are concatenated to form a new input sequence. The information is then input into the recommendation intent recognition model, which determines the intent based on the concatenated information.

[0104] 2) Design a dynamic update mechanism to build a dynamic semantic anchor word pool. By dynamically adjusting and expanding the semantic coverage, the accuracy of recommendation intent can be improved. By designing a dynamic update mechanism, the model's expanded vocabulary pool can be continuously optimized to cope with the real-time changing language environment during live streaming. This mechanism combines semantic distance and time decay strategies to effectively solve the problems of concept drift and semantic vocabulary timeliness.

[0105] Step 2.1) Construct a set of semantic anchor words for each recommendation intent category;

[0106] The system for each label category ,in Let y0 represent "casual conversation" and y1 represent "purchase intention". Define a set of anchor words that are semantically related to the category. Each anchor word set It contains several semantically related words that can represent this category, and is specifically constructed as follows:

[0107]

[0108] in, For semantic vocabulary related to category y, n y This represents the number of anchor words in this category.

[0109] Step 2.2) Construct a candidate word set and use a zero-shot classifier to filter out words relevant to the current context to further identify words related to user intent;

[0110] For C t Word segmentation is performed, and part-of-speech tagging technology is used to retain nouns, verbs, and proper nouns, thus constructing a candidate word set. , is represented as:

[0111]

[0112] Among them, Filter(C) t ) indicates that for C t Candidate words selected after word segmentation and part-of-speech tagging;

[0113] Then, the system uses a zero-shot classifier to classify the candidate word set. Mapped to a natural language template, words highly relevant to the current semantic environment are selected to form a candidate word set W related to the current context. rel The specific process is as follows:

[0114]

[0115] Here, zero-shot classifier Used to determine each candidate word Is it relevant to the current context?

[0116] Step 2.3) Assign a label category to each candidate word by calculating the semantic distance;

[0117] Obtain W rel Then, the system will... Mapped into a d-dimensional semantic embedding space, it is represented as Then, the semantic distance between the candidate word w and each label category y is calculated. The specific calculation formula is as follows:

[0118]

[0119] in, and These are the representations of candidate word w and anchor word w' in the semantic embedding space, respectively. This represents the cosine similarity function; this distance measures the semantic similarity between candidate word w and category y, and the smaller the distance, the more word w matches the semantics of category y.

[0120] By calculating the semantic distance of each candidate word w, the system assigns a most relevant label category to each word. Its decision-making rules are as follows:

[0121]

[0122] That is, the choice makes The smallest category y is used as the semantic label for candidate word w;

[0123] Step 2.4) Update the set of semantic anchor words for each category;

[0124] The system weights each candidate word w according to its semantic proximity to category y; specifically, the weights... Adjustments will be made according to the following rules in each update round:

[0125]

[0126] in, Let λ be the weight of word w in the previous iteration, and λ be the decay factor, usually set to 1. In the half-life parameter Under the control of [the system], the decay rate is set to 10;

[0127] Step 2.5) Retain the k highest-scoring anchor words for each category to construct the final dynamic semantic anchor word set;

[0128] In each update, the system will determine the semantic proximity of each candidate word to the category label y and its weight. The score is calculated using the following formula:

[0129]

[0130] The score combines the candidate word w with the current category. The higher the score of the semantic similarity and the activity of the word, the stronger the representativeness of the candidate word w for the current category.

[0131] Ultimately, in each batch, the system for each category Select the k candidate words with the highest scores to form the semantic anchor word set for this category. ,Right now:

[0132]

[0133] in, This indicates that the top k words by score are selected, resulting in the final score. This constitutes the dynamic semantic anchor word set for the current time step t;

[0134] Step 2.6) Merge all categories of dynamic anchor word sets to form the final dynamic semantic anchor word pool;

[0135] All categories of dynamic semantic anchor words and Ultimately, these are merged into the dynamic semantic anchor word pool of the entire model. , is represented as:

[0136]

[0137] in, express Within the category, the set of dynamic semantic anchor words at time step t; express Within the category, the set of dynamic semantic anchor words at time step t;

[0138] Semantic anchor word pool It is used to guide the recommendation intent recognition task during each training and inference process.

[0139] 3) In cases with few samples, the model is fine-tuned using soft cueing. By training a small number of adjustable soft cueing vectors, the input cueing is dynamically adjusted, thereby optimizing the recommendation intent recognition performance of the cueing learning model.

[0140] Step 3.1) Perform task modeling for recommendation intent recognition, and construct a model for each C. t Classify them and determine whether they contain recommendation intent;

[0141] The recommendation intent recognition is modeled as a binary classification problem, where Indicates the category of recommendation intent. This indicates that it contains a recommendation intent. This refers to comments that are casual conversational or otherwise not intended for recommendation; the specific task modeling is as follows:

[0142]

[0143] in, For the predicted label, A classifier used to predict the category of recommendation intent based on the input comments and explanations;

[0144] Step 3.2) Construct and train a soft cue fine-tuning model. Using the soft cue fine-tuning model, the input cue can be dynamically adjusted by training a small number of adjustable soft cue vectors.

[0145] Step 3.2.1) Construct a soft suggestion template and use soft suggestion optimization methods to adjust C. t Transform it into a soft-hint template that includes dynamic learning suggestions; the template not only includes C t It also incorporates E t and a set of adjustable soft cue vectors. ;

[0146] The specific soft suggestion template T is shown below:

[0147]

[0148] in, These are the soft cue vectors learned during model training. The label location used by the model to predict recommendation intent;

[0149] Step 3.2.2) Generate hidden layer representations through PLM encoding. Input the constructed soft cue template T into the pre-trained language model. The pre-trained language model will process the template through the encoder and generate hidden vector representations of the input sequence; the process is as follows:

[0150]

[0151] in, It is C t The encoded vector, It is E t The encoded vector, This indicates the encoding result of the soft prompt symbol, e mask The encoded vector representing the mask position is used for subsequent mask prediction;

[0152] Step 3.2.3) Enhance the context adaptability of soft cue vectors by introducing a bidirectional LSTM into the soft cue symbols;

[0153] Specifically, for The updated calculation formula is as follows:

[0154]

[0155] Step 3.2.4) The learning objective of the soft cue vector is achieved by minimizing the mask prediction loss function as follows:

[0156]

[0157] in, This represents minimizing the mask prediction loss function. The target of the mask prediction task.

[0158] Step 3.3) Predict the recommendation intent category by combining mask word probability modeling with dynamic annotation mechanism, and select the category with the highest probability as the predicted recommendation intent for a given bullet screen comment.

[0159] Step 3.3.1) Predict the recommendation intent category, given... and As input sequences, these inputs are processed through a soft template structure. Embedded into the language model, the language model predicts and fills in the blanks. Position is a tag word The probability of this can be used to model the intent recognition problem as a mask word probability modeling problem:

[0160]

[0161] Combined with the dynamic labeler mechanism, each category A set of corresponding tags will be assigned. In the calculation process, it is assumed that each label contributes equally to the classification, then the predicted score of category y is... Defined as:

[0162]

[0163] Finally, the model selects the category with the highest probability as the predicted recommendation intent for a given bullet screen comment;

[0164] Step 3.3.2) During the training phase, the standard cross-entropy loss function is used with the addition of an L2 regularization term, resulting in the overall loss function. Defined as:

[0165]

[0166] Where, N a This represents the total number of training samples. It is the true label of the i-th sample, T(x) i ) represents the corresponding soft template input, and θ represents the model parameters. This is the L2 regularization term, and α is the regularization coefficient. The first term of the loss function aims to improve classification accuracy, while the second term constrains the size of the model parameters, thereby enhancing the model's stability and robustness when facing the high diversity and semantic drift in bullet comments.

[0167] To test the effectiveness of this invention, experiments were conducted on four different e-commerce live streaming bullet screen datasets: RecDY, RecKS, RecXHS, and RECTikTok. To ensure a realistic measurement of the detection performance, this paper selected four representative evaluation metrics: Accuracy, Precision, Recall, and F1 Score, defined as follows:

[0168]

[0169]

[0170]

[0171]

[0172] To validate the effectiveness of the model, we compared it with several baseline and state-of-the-art methods, including neural network methods: Text-CNN, ADB, and SimSTC; pre-trained language model methods: BERT, IntentBERT, and IntentBERT-MLM; cue-based tuning methods: KPT, KPT++, and P-tuning; and large language model methods: llama3, Deepseek-V3, Chatgpt-4o, and FaithfulRAG. The prediction results are shown in Table 1.

[0173] Table 1. Experimental results on four datasets

[0174]

[0175] As shown in Table 1, the prediction results of this invention on the Chinese click decoy dataset are superior to other methods.

[0176] Compared with traditional neural network methods (such as Text-CNN and ADB), the method proposed in this invention has significant advantages in semantic understanding and context modeling; compared with PLM-based methods (such as BERT and IntentBERT), the method proposed in this invention performs more stably in low-sample scenarios; compared with Prompt-Tuning methods (such as KPT and P-tuning), SPT-RII further improves performance through dynamic update mechanism and semantic enhancement module; even compared with the current state-of-the-art large language models (such as LLaMA3, Deepseek-V3, ChatGPT-4o, etc.), the method proposed in this invention still has significant advantages in real-time performance and task adaptability.

[0177] Experimental results show that the method proposed in this invention can still maintain near-saturation performance under extremely low resources (such as 50 training samples). For example, on the RecKS dataset, the F1 value of the 50-shot setting is only 1.53% lower than that of the 800-shot setting, showing that it has extremely low dependence on labeled data and has good few-shot learning ability.

[0178] Through repeated experiments, the standard deviation (SD) was calculated, revealing that the proposed method exhibits low performance fluctuations (SD ranging from 0.1% to 0.7%) across all datasets and sample settings, significantly lower than other baseline methods (such as ADB and KPT), indicating its good stability and reproducibility. Furthermore, SPT-RII performs excellently on both Chinese and English platforms, demonstrating strong cross-language and cross-domain generalization capabilities.

[0179] This invention proposes a recommendation intent recognition method based on soft-cue fine-tuning. By leveraging the synergy between a large-scale language model and a small-scale model, it overcomes the difficulty of identifying latent intent in short texts, effectively processes real-time bullet screen data, and achieves accurate identification of recommendation intent even with limited sample sizes. This method is widely applicable to recommendation systems in live-streaming e-commerce, social media interaction, and other fields requiring real-time processing of short text data.

[0180] The above description of the embodiments is only for the purpose of helping to understand the method and core ideas of the present invention. It should be noted that those skilled in the art can make several improvements and modifications to the present invention without departing from the principles of the present invention, and these improvements and modifications also fall within the protection scope of the claims of the present invention.

Claims

1. A method for identifying recommendation intent based on soft cue fine-tuning, characterized in that, Includes the following steps: 1) Set up a history window to capture historical information, generate semantic explanations by introducing a large language model, and combine the generated semantic explanations with the original bullet screen comments to form an extended input representation; 2) Design a dynamic update mechanism and build a dynamic semantic anchor word pool. By dynamically adjusting and expanding the semantic coverage, the accuracy of recommendation intent can be improved. 3) In cases with few samples, the model is fine-tuned using soft cueing. By training a small number of adjustable soft cueing vectors, the input cueing is dynamically adjusted, thereby optimizing the recommendation intent recognition performance of the cueing learning model.

2. The recommendation intent recognition method based on soft cue fine-tuning according to claim 1, characterized in that, Step 1) specifically includes: Step 1.1) By setting up a history context window, associate the current time point t with its k historical comments to construct a history context set H. t ; Specifically, the historical context set H t for: in, C represents the time step. t For each time step t, the number of bullet comments is t; k is the set size of the history window. Step 1.2) Generate a semantic explanation for each bullet comment using a large language model, through a language model function. Inferring the user's underlying motivations and expressed intentions; Specifically, for C t Semantic interpretation E t It is generated by the following formula: in, It is a generator function based on a large language model, representing the inference of C through the large language model. t In the historical context set H t The underlying semantics and motivations; Step 1.3) Combine the generated semantic interpretation with the original bullet screen comments to form an extended input representation, which is then passed to the downstream recommendation intent recognition model for processing; By C t Its corresponding E t The sequences are concatenated to form a new input sequence. The information is then input into the recommendation intent recognition model, which determines the intent based on the concatenated information.

3. The method for identifying recommendation intent based on soft cue fine-tuning according to claim 1, characterized in that, Step 2) specifically includes: Step 2.1) Construct a set of semantic anchor words for each recommendation intent category; The system for each label category ,in , It means "casual conversation". Representing "purchase intent", a set of anchor words related to category semantics is defined. Each anchor word set It contains several semantically related words that can represent this category, and is specifically constructed as follows: in, For semantic vocabulary related to category y, n y This represents the number of anchor words in this category. Step 2.2) Construct a candidate word set and use a zero-shot classifier to filter out words relevant to the current context to further identify words related to user intent; For C t Word segmentation is performed, and part-of-speech tagging technology is used to retain nouns, verbs, and proper nouns to construct a candidate word set. , is represented as: Among them, Filter(C) t ) indicates that for C t Candidate words selected after word segmentation and part-of-speech tagging; Then, the system uses a zero-shot classifier to classify the candidate word set. Mapped to a natural language template, words highly relevant to the current semantic environment are selected to form a candidate word set W related to the current context. rel The specific process is as follows: Here, zero-shot classifier Used to determine each candidate word Is it relevant to the current context? Step 2.3) Assign a label category to each candidate word by calculating the semantic distance; Obtain the candidate word set W rel Then, the system will... Mapped into a d-dimensional semantic embedding space, it is represented as Then, the semantic distance between the candidate word w and each label category y is calculated. The specific calculation formula is as follows: in, and These are the representations of candidate word w and anchor word w' in the semantic embedding space, respectively. This represents the cosine similarity function; this distance measures the semantic similarity between candidate word w and category y, and the smaller the distance, the more word w matches the semantics of category y. By calculating the semantic distance of each candidate word w, the system assigns a most relevant label category to each word. Its decision-making rules are as follows: That is, the choice makes The smallest category y is used as the semantic label for candidate word w; Step 2.4) Update the set of semantic anchor words for each category; The system weights each candidate word w according to its semantic proximity to category y; specifically, the weights... Adjustments will be made according to the following rules in each update round: in, Let λ be the weight of word w in the previous iteration, and λ be the decay factor, usually set to 1. In the half-life parameter Under the control of [the system], the decay rate is set to 10; Step 2.5) Retain the k highest-scoring anchor words for each category to construct the final dynamic semantic anchor word set; In each update, the system will determine the semantic proximity of each candidate word to the category label y and its weight. The score is calculated using the following formula: The score combines the candidate word w with the current category. The higher the score of the semantic similarity and the activity of the word, the stronger the representativeness of the candidate word w for the current category. Ultimately, in each batch, the system for each category Select the k candidate words with the highest scores to form the semantic anchor word set for this category. ,Right now: in, This indicates that the top k words by score are selected, resulting in the final score. This constitutes the dynamic semantic anchor word set for the current time step t; Step 2.6) Merge the dynamic anchor word sets of all categories to form the final dynamic semantic anchor word pool; All categories of dynamic semantic anchor words and Ultimately, these are merged into the dynamic semantic anchor word pool of the entire model. , is represented as: in, express Within the category, the set of dynamic semantic anchor words at time step t; express Within the category, the set of dynamic semantic anchor words at time step t; Semantic anchor word pool It is used to guide the recommendation intent recognition task during each training and inference process.

4. The method for identifying recommendation intent based on soft cue fine-tuning according to claim 1, characterized in that, Step 3) specifically includes: Step 3.1) Perform task modeling for recommendation intent recognition, and construct a model for each C. t Classify them and determine whether they contain recommendation intent; The recommendation intent recognition is modeled as a binary classification problem, where Indicates the category of recommendation intent. This indicates that it contains a recommendation intent. This refers to comments that are casual conversational or otherwise not intended for recommendation; the specific task modeling is as follows: in, For the predicted label, It is a classifier used to predict the category of recommendation intent based on the input comments and explanations; Step 3.2) Construct and train a soft cue fine-tuning model. Using the soft cue fine-tuning model, the input cue can be dynamically adjusted by training a small number of adjustable soft cue vectors. Step 3.3) Predict the recommendation intent category by combining mask word probability modeling with dynamic annotation mechanism, and select the category with the highest probability as the predicted recommendation intent for a given bullet screen comment.

5. The method for identifying recommendation intent based on soft cue fine-tuning according to claim 1, characterized in that, Step 3.2) specifically includes: Step 3.2.1) Construct a soft suggestion template and use soft suggestion optimization methods to adjust C. t Transform it into a soft-hint template that includes dynamic learning suggestions; the template not only includes C t It also incorporates E t and a set of adjustable soft cue vectors. ; The specific soft suggestion template T is shown below: in, These are the soft cue vectors learned during model training. The label location used by the model to predict recommendation intent; Step 3.2.2) Generate hidden layer representations through PLM encoding. Input the constructed soft cue template T into the pre-trained language model. The pre-trained language model will process the template through the encoder and generate hidden vector representations of the input sequence; the process is as follows: in, It is C t The encoded vector, It is E t The encoded vector, This indicates the encoding result of the soft prompt symbol, e mask The encoded vector representing the mask position is used for subsequent mask prediction; Step 3.2.3) Enhance the context adaptability of soft cue vectors by introducing a bidirectional LSTM into the soft cue symbols; Specifically, for The updated calculation formula is as follows: Step 3.2.4) The learning objective of the soft cue vector is achieved by minimizing the mask prediction loss function as follows: in, This represents minimizing the mask prediction loss function. The target of the mask prediction task.

6. The method for identifying recommendation intent based on soft cue fine-tuning according to claim 1, characterized in that, Step 3.3) specifically includes: Step 3.3.1) Predict the recommendation intent category, given... and As input sequences, these inputs are processed through a soft template structure. Embedded into the language model, the language model predicts and fills in the blanks. Position is a tag word The probability of this can be used to model the intent recognition problem as a mask word probability modeling problem: Combined with the dynamic labeler mechanism, each category A set of corresponding tags will be assigned. In the calculation process, it is assumed that each label contributes equally to the classification, then the predicted score of category y is... Defined as: Finally, the model selects the category with the highest probability as the predicted recommendation intent for a given bullet screen comment; Step 3.3.2) During the training phase, the standard cross-entropy loss function is used with the addition of an L2 regularization term, resulting in the overall loss function. Defined as: Where, N a This represents the total number of training samples. It is the true label of the i-th sample, T(x) i ) represents the corresponding soft template input, and θ represents the model parameters. It is the L2 regularization term, and α is the regularization coefficient.