A method and system for automatically recommending website content based on search keywords
By introducing semantic vectors and confidence weight analysis into the website content recommendation system, the problems of noise identification and semantic fusion were solved, enabling more accurate understanding of user intent and content recommendation, thereby improving the accuracy of recommendations and user satisfaction.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SHANGHAI TIANQING TIANTUO SOFTWARE TECH CO LTD
- Filing Date
- 2026-02-04
- Publication Date
- 2026-06-05
AI Technical Summary
Existing technologies lack the ability to identify and tolerate noise (such as spelling errors and non-standard expressions) in user-input search keywords. They also fail to effectively integrate lexical morphological similarity and semantic similarity, resulting in inaccurate recommendation results that ignore content popularity and freshness, thus affecting user experience.
By mapping search keywords to semantic vectors, standard candidate words are generated, and edit distance and semantic vectors are calculated. A confidence weight analysis model is established to generate reconstructed query words. Recommendation scores are calculated by combining website content feature vectors, taking into account both morphological and semantic similarity.
It improves the accuracy of capturing users' true intentions, resulting in more accurate and relevant recommendations that are timely and practical, significantly enhancing the accuracy of website content recommendations and user satisfaction.
Smart Images

Figure CN122153153A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of website content recommendation technology, and in particular relates to a method and system for automatically recommending website content based on search keywords. Background Technology
[0002] With the explosive growth of internet information, it has become increasingly difficult for users to quickly locate the information they need from massive amounts of website content. Automatic content recommendation based on user-input search keywords has become a key technology for improving information retrieval efficiency and user experience. However, user-input search terms often suffer from ambiguity, spelling errors, colloquialisms, or mismatches with the website's standard keyword database, posing a significant challenge to accurately understanding the user's true intent and recommending relevant content.
[0003] Currently, website content recommendation technologies are mainly divided into two categories: one is traditional search recommendation based on exact keyword matching or inverted indexes, the effectiveness of which heavily depends on the accuracy of the query terms; the other is vectorized similarity matching based on semantic embedding (such as Word2Vec and BERT), which can capture certain semantics, but has limited ability to handle noise that is a mixture of form and meaning, such as spelling errors, synonyms, and near-synonyms. Existing methods usually perform content matching directly after receiving the query, lacking a process of cleaning, standardizing, and reconstructing intent from the original query terms.
[0004] However, existing technologies have significant drawbacks: First, they lack effective identification and tolerance mechanisms for noise in user queries (such as spelling errors and non-standard expressions), leading to biases in intent understanding. Second, they fail to effectively integrate morphological similarity (such as edit distance) with semantic similarity to quantify the confidence level of each candidate word, affecting the accuracy of query reconstruction. Third, recommendation models often only consider the semantic relevance between content and query, ignoring actual influencing factors such as the popularity and freshness of the content itself, resulting in relevant but not necessarily matching user needs. Summary of the Invention
[0005] To address the shortcomings of existing technologies, this invention provides a method and system for automatically recommending website content based on search keywords, thus solving the aforementioned problems.
[0006] To achieve the above objectives, the present invention provides the following technical solution: an automatic website content recommendation method based on search keywords, the method specifically comprising: Extract each word element from the search keywords and map each word element into a word element semantic vector; Based on the semantic vector of the word element, standard candidate words are generated; where standard candidate words refer to standard keywords that match the word elements in the search keywords. Obtain the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words. Based on the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words, establish a confidence weight analysis model to generate the confidence weight of the standard candidate words. Based on the confidence weight of the standard candidate terms, the standard candidate terms are filtered to generate reconstructed query terms; Obtain the semantic vector of the reconstructed query term, and generate a standardized user search intent vector based on the semantic vector of the reconstructed query term; Obtain the feature vectors of website content, build a website content recommendation analysis model based on the standardized user search intent vectors and website content feature vectors, and generate the final recommendation score for website content. The website content is recommended based on its final recommendation score.
[0007] Based on the above technical solutions, the present invention also provides the following optional technical solutions: Further technical solution: The specific method for generating the standard candidate words includes: Through the formula: ; Generate standard candidate words In the formula, This represents the terminology in the search keywords. semantic vectors, This represents the semantic vector of the word l in the standard keyword library L, and * is the dot product operator for vectors. It represents a word element. The modulus of a semantic vector It represents the modulus of the semantic vector of the word l.
[0008] Further technical solution: The specific method for generating the confidence weights of the standard candidate words includes: Based on the edit distance between the lexical units of the standard candidate words and the search keywords, morphological similarity is generated; Generate semantic similarity based on the semantic vectors of standard candidate words; A confidence weight analysis model is established based on morphological similarity and semantic similarity to generate confidence weights for standard candidate words.
[0009] Further technical solutions: The specific methods for generating the morphological similarity include: Through the formula: ; Generating morphological similarity In the formula, This represents the standard candidate words. Terminology of search keywords Edit distance between This represents the terminology of the search keywords. The length of the string. This represents the standard candidate words. The length of the string.
[0010] Further technical solutions: The specific methods for generating semantic similarity include: Through the formula: Generate semantic similarity In the formula, semantic similarity This refers to the terminology in the search keywords. Compared with standard candidate words Semantic similarity between them This represents the terminology in the search keywords. semantic vectors, This represents the standard candidate words. The semantic vector, where * is the dot product operator for vectors. It represents a word element. The modulus of a semantic vector This represents the standard candidate words. The modulus. Further technical solution: The expression of the confidence weight analysis model is specifically as follows: In the expression, This represents the standard candidate words. Confidence weights This indicates morphological similarity. This represents semantic similarity, where a and b are both proportional coefficients, and a+b=1.
[0011] Further technical solution: The standardized user retrieval intent vector generation method specifically includes: through the formula: Generate standardized user search intent vectors In the formula, This represents the j-th reconstructed query term. semantic vectors, This represents the j-th reconstructed query term. The weight coefficient is m, which represents the total number of reconstructed query terms.
[0012] Further technical solutions: The specific methods for generating the final recommendation score for website content include: Based on standardized user search intent vectors and website content feature vectors, a preliminary recommendation score for website content is generated. Based on the initial recommendation score of website content, a website content recommendation analysis model is established to generate the final recommendation score of website content. The specific expression for the website content recommendation analysis model is as follows: In the expression, This refers to the website content. Final recommended score This refers to the website content. Preliminary recommended score, This refers to the website content. Popularity indicator value This refers to the website content. Freshness index value All are weighting ratio coefficients, and .
[0013] Further technical solutions: The specific methods for generating the preliminary recommendation score for website content include: Through the formula: ; Generate preliminary recommendation scores for website content In the formula, This represents a standardized user search intent vector. This refers to the website content. The eigenvectors are represented by , and * is the dot product operator for vectors. This represents the magnitude of the standardized user search intent vector. This refers to the website content. The modulus of the eigenvectors.
[0014] An automatic website content recommendation system based on search keywords, the system being used to execute the aforementioned automatic website content recommendation method based on search keywords, specifically including: The data acquisition unit is used to acquire each word element in the search keywords and map each word element into a word element semantic vector. The standard candidate word analysis unit is used to generate standard candidate words based on the semantic vector of the word element; where standard candidate words refer to standard keywords that match the word elements in the search keywords. The confidence weight analysis unit is used to obtain the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words. Based on the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words, a confidence weight analysis model is established to generate the confidence weight of the standard candidate words. The filtering unit is used to filter standard candidate terms based on their confidence weights and generate reconstructed query terms. The retrieval intent analysis unit is used to obtain the semantic vector of the reconstructed query terms and generate a standardized user retrieval intent vector based on the semantic vector of the reconstructed query terms. The recommendation score analysis unit is used to obtain the feature vector of website content, build a website content recommendation analysis model based on the standardized user search intent vector and the feature vector of website content, and generate the final recommendation score of website content. The recommendation unit is used to recommend website content based on the final recommendation score.
[0015] This invention provides a method and system for automatically recommending website content based on search keywords, which has the following advantages compared with the prior art: This invention effectively achieves intelligent correction and standardization of noisy query terms by integrating both morphological and semantic similarity to calculate confidence weights. By reconstructing query terms and generating standardized user search intent vectors, it improves the accuracy of capturing users' true intentions. Finally, by integrating semantic relevance, content popularity, and freshness in the recommendation model, the recommendation results are not only accurate and relevant but also more timely and practical, significantly improving the accuracy of website content recommendations and user satisfaction. Attached Figure Description
[0016] Figure 1 This is a flowchart illustrating an automatic website content recommendation method based on search keywords provided by the present invention.
[0017] Figure 2 This is a flowchart illustrating step S30 of the present invention.
[0018] Figure 3 This is a flowchart illustrating step S60 of the present invention.
[0019] Figure 4 This is a schematic diagram of the structure of an automatic website content recommendation system based on search keywords provided by the present invention.
[0020] Figure 5 This is a schematic diagram of the confidence weight analysis unit provided by the present invention.
[0021] Figure 6 This is a schematic diagram of the structure of the recommendation score analysis unit provided by the present invention. Detailed Implementation
[0022] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.
[0023] The specific implementation of the present invention will be described in detail below with reference to specific embodiments.
[0024] Please see Figure 1 The present invention provides an automatic website content recommendation method based on search keywords, comprising the following steps: Step S10: Obtain each word element in the search keywords and map each word element to a word element semantic vector; Step S20: Generate standard candidate words based on the semantic vector of the word element; where standard candidate words refer to standard keywords that match the word elements in the search keywords; Step S30: Obtain the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words. Based on the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words, establish a confidence weight analysis model to generate the confidence weight of the standard candidate words. Step S40: Based on the confidence weight of the standard candidate terms, filter the standard candidate terms to generate reconstructed query terms; Step S50: Obtain the semantic vector of the reconstructed query term, and generate a standardized user search intent vector based on the semantic vector of the reconstructed query term; Step S60: Obtain the feature vector of the website content, establish a website content recommendation analysis model based on the standardized user search intent vector and the feature vector of the website content, and generate the final recommendation score of the website content; Step S70: Recommend website content based on the final recommendation score; Among them, a term refers to the smallest semantic unit that constitutes a search keyword, such as a Chinese word or an English word; Reconstructing query terms refers to creating new query terms by combining or modifying standard candidate terms with higher confidence weights after filtering standard candidate terms. The aim is to express the user's search intent more accurately and in a more standardized way. The feature vector of website content refers to the numerical vector that is extracted and quantified to represent the core features of the content after processing such as text analysis and image recognition. This vector is used to describe the semantic theme, category and other information of the website content. Specifically, in step S10, each word element in the search keywords is obtained, and each word element is mapped to a word element semantic vector. This step can be implemented by: first, segmenting the user-input search keywords into independent word elements. For example, a dictionary-based segmentation algorithm or a statistical model-based segmentation algorithm can be used. Then, each word element is converted into its corresponding semantic vector. This can be achieved by consulting a pre-trained word vector model (e.g., a word embedding model trained on a large-scale corpus) or by inputting the word elements into a pre-encoder to generate their vector representation.
[0025] In step S20, standard candidate words are generated based on the semantic vectors of the word elements. These standard candidate words refer to standard keywords that match the word elements in the search keywords. This step can be implemented by: calculating the similarity between each word element semantic vector and all word element semantic vectors in the standard keyword library; then, selecting several standard keywords with the highest similarity to the word element semantic vectors of the search keywords as standard candidate words.
[0026] In step S30, the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words are obtained. A confidence weight analysis model is then established based on the edit distance and semantic vector to generate the confidence weights of the standard candidate words. This step can be implemented as follows: First, the edit distance between each standard candidate word and the lexical units of the original search keywords is calculated; this distance reflects the morphological similarity of the words. For example, the Levenshtein distance algorithm can be used for calculation. Simultaneously, the semantic vector of each standard candidate word is obtained; this vector reflects the semantic information of the word. Then, the edit distance and semantic vector are used as input, and a pre-defined confidence weight analysis model is used to calculate the confidence weight of each standard candidate word.
[0027] In step S40, the standard candidate words are filtered according to their confidence weights to generate reconstructed query terms. This step can be implemented by setting a confidence weight threshold and retaining only standard candidate words with a confidence weight higher than that threshold. For example, all candidate words with a confidence weight lower than the threshold are excluded; alternatively, the standard candidate words can be sorted in descending order according to their confidence weights, and the top N candidate words are selected. After filtering, these retained standard candidate words are combined or concatenated to form one or more reconstructed query terms to more accurately express the user's search intent.
[0028] In step S50, the semantic vectors of the reconstructed query terms are obtained, and a standardized user search intent vector is generated based on the semantic vectors of the reconstructed query terms. This step can be implemented by: first, obtaining the semantic vector of each reconstructed query term. This can be achieved by performing a weighted average or summation of the semantic vectors of each word element in the reconstructed query term, where the weights can be allocated according to the importance of the word element in the reconstructed query term. Subsequently, the obtained semantic vectors of the reconstructed query terms are standardized. This standardization process helps eliminate the influence of vector length on similarity calculation, ensuring the comparability between different query intent vectors.
[0029] In step S60, the feature vectors of the website content are obtained. A website content recommendation analysis model is established based on the standardized user search intent vector and the feature vectors of the website content to generate the final recommendation score for the website content. This step can be implemented as follows: First, semantic analysis is performed on the website's text content (such as titles, abstracts, and body text) to extract its core features and represent them as numerical vectors. For example, a pre-trained document embedding model can be used to generate the feature vectors of the website content. Then, the standardized user search intent vector and the feature vectors of the website content are used as input, and a website content recommendation analysis model is used to calculate the final recommendation score for the website content. The website content recommendation analysis model can be a comprehensive scoring model that considers multiple factors (such as semantic relevance, content quality, etc.).
[0030] In step S70, website content is recommended based on its final recommendation score. This step can be implemented by sorting all the website content to be recommended in descending order of its final recommendation score. Then, the top-scoring website content is presented to the user. For example, the user may be shown the top 5 or 10 website content items. This recommendation process aims to ensure that users receive high-quality website content that is highly relevant to their search intent.
[0031] In summary, this embodiment constructs a more robust and accurate automatic website content recommendation framework by introducing lexical semantic vectors, confidence weight analysis of morphological and semantic fusion, and standardized reconstruction of user search intent, effectively improving the accuracy of user intent understanding and the quality of website content recommendation.
[0032] Preferably, the present invention further proposes a method for generating the standard candidate words, specifically including: Through the formula: ; Generate standard candidate words In the formula, This represents the terminology in the search keywords. semantic vectors, This represents the semantic vector of the word l in the standard keyword library L, and * is the dot product operator for vectors. It represents a word element. The modulus of a semantic vector It represents the modulus of the semantic vector of the word unit l; The standard candidate word generation method aims to find the semantically closest match for each word element in the search keyword from a predefined standard keyword library. The core of this method lies in using semantic vectors to quantify the semantic relationships between word elements and selecting the best match through mathematical calculation. Furthermore, the calculation formula for standard candidate words calculates the cosine similarity between the semantic vector of a word element in the search keyword and the semantic vector of each word element in the standard keyword library. Cosine similarity is represented by dividing the dot product of the vectors by the product of their moduli; its value ranges from -1 to 1, with a higher value indicating a closer semantic relationship. By taking the maximum value, it ensures that the selected standard candidate words are the most semantically relevant to the original word elements. The semantic vector of a word in a search keyword is a numerical representation of that word in a multi-dimensional space, capturing its semantic information. This semantic vector can be generated using various techniques. For example, pre-trained word embedding models such as Word2Vec, GloVe, and FastText can be used to map words into a fixed-dimensional vector space; alternatively, context-sensitive word embedding models such as BERT and ELMo can be used to generate semantic vectors based on the specific context of the word in the sentence. The semantic vectors of words in the standard keyword library are generated in a similar way to those of words in the search keywords. They typically use the same word embedding model and method to ensure consistency and comparability between semantic vectors. In addition, the standard keyword library can be a pre-built dictionary containing domain-specific or general vocabulary. Its purpose is to provide a standardized vocabulary set for matching and understanding user search intent. * is the dot product operator for vectors, used to calculate the sum of the products of the components of two vectors along the same dimension; geometrically, the dot product is proportional to the cosine of the angle between the two vectors and is the basis for measuring vector similarity. The magnitude of a vector, i.e., the length or size of the vector, can be divided in cosine similarity calculation to eliminate the influence of the vector length on the similarity calculation, so that the similarity depends only on the direction of the vector, thus more accurately reflecting the semantic closeness. Specifically, this invention first obtains each word element in the search keywords and maps it to a word element semantic vector. To address the problem of accurately selecting standard candidate words from a standard keyword library that best match the semantics of these word elements, this invention proposes a generation method based on cosine similarity. Specifically, for each word element in the search keywords, its semantic vector is cosine similar to the semantic vectors of all word elements in the standard keyword library. Cosine similarity measures the angle between two vectors by calculating the dot product of the two vectors and dividing by the product of their respective moduli, thus reflecting the degree of semantic closeness. In this way, the system can identify the standard keywords that are semantically closest to the word elements and select them as standard candidate words. This process ensures that the generated standard candidate words are highly semantically related to the original search words, laying an accurate foundation for subsequent confidence weight analysis and the generation of user search intent vectors, thereby improving the accuracy of website content recommendations.
[0033] Through the above technical solution, this application can accurately measure the semantic similarity between lexical units in the search keywords and lexical units in the standard keyword library. By using cosine similarity as the metric and selecting the standard keywords with the highest semantic similarity as standard candidate words, it effectively solves the problem of how to accurately match user search intent from a massive amount of standard vocabulary in complex semantic environments. This significantly improves the semantic accuracy of standard candidate words, thereby enabling the subsequently generated reconstructed query terms and user search intent vectors to more realistically reflect the user's actual needs, ultimately improving the accuracy of website content recommendations and user satisfaction.
[0034] For preferred options, please refer to [link / reference]. Figure 2 The present invention further proposes a method for generating the confidence weights of the standard candidate words, specifically including: Step S31: Generate morphological similarity based on the edit distance between the lexical units of the standard candidate words and the search keywords; Step S32: Generate semantic similarity based on the semantic vectors of the standard candidate words; Step S33: Establish a confidence weight analysis model based on morphological similarity and semantic similarity to generate confidence weights for standard candidate words; In step S31, edit distance is a metric that measures the difference between two strings, typically referring to the minimum number of single-character editing operations (such as insertion, deletion, and replacement) required to transform one string into another. For example, algorithms such as Levenshtein distance, Damerau-Levenshtein distance, or Jaro-Winkler distance can be used to calculate edit distance. Morphological similarity, on the other hand, is a quantitative representation of the morphological similarity of strings based on edit distance. Its value is typically between 0 and 1, with a higher value indicating greater morphological similarity. By calculating morphological similarity, morphologically similar words such as spelling errors, variant words, or abbreviations can be effectively identified.
[0035] In step S32, semantic vectors are numerical representations of lexical units in a multidimensional space, capturing their semantic information and contextual relationships. These semantic vectors can be obtained through pre-trained word embedding models (such as Word2Vec, GloVe, and FastText) or more complex language models (such as BERT and the GPT series). Semantic similarity is an indicator that measures the closeness of two lexical units in the semantic space. It is usually obtained by calculating the cosine similarity between their semantic vectors, and its value is typically between -1 and 1, with a larger value indicating greater semantic similarity. Through semantic similarity, lexical units with different forms but similar meanings can be identified, such as synonyms or near-synonyms.
[0036] In step S33, the confidence weight analysis model is a mathematical model used to comprehensively evaluate the degree of matching between the lexical units of the standard candidate words and the search keywords. This model takes morphological similarity and semantic similarity as input and outputs a confidence weight representing the reliability or importance of the standard candidate words.
[0037] This application's solution refines the generation process of confidence weights for standard candidate words into three steps, thereby more comprehensively and accurately assessing the reliability of standard candidate words. First, by calculating the edit distance between the standard candidate words and the lexical units of the search keywords, the morphological similarity is quantified, generating morphological similarity. This helps identify word form differences caused by spelling errors or variations. Second, using the semantic vectors of the standard candidate words, the semantic similarity between them and the lexical units of the search keywords is calculated, thereby capturing the deep-seated semantic connections between lexical units. This helps identify lexical units with different forms but similar meanings. Finally, using these two different dimensions of similarity as input, a confidence weight analysis model is established. This model comprehensively considers the morphological and semantic features of lexical units, avoiding the bias that may arise from single-dimensional evaluation, such as words with similar forms but completely unrelated meanings, or words with significant morphological differences but highly related meanings. In this way, the solution generates more accurate and robust confidence weights for standard candidate words, providing a more reliable basis for subsequent screening and query term reconstruction, thus effectively solving the problem of inaccurate confidence weight calculations that may result from only broadly processing edit distance and semantic vectors.
[0038] By employing the aforementioned technical solution, the generation process of confidence weights for standard candidate words is refined into separate calculations and comprehensive evaluations of morphological similarity and semantic similarity. This allows for a more comprehensive and accurate measurement of the matching degree between standard candidate words and the lexical units of the search keywords. This dual-dimensional evaluation mechanism effectively avoids misjudgments that may arise from a single similarity measure. For example, words that are morphologically similar but semantically inconsistent may be incorrectly assigned high weights, while words with significant morphological differences but highly related semantics may be underestimated. Therefore, the generated confidence weights are more accurate and reliable, making subsequent screening of standard candidate words more effective. This allows for more accurate identification of reconstructed query terms that truly match the user's search intent, ultimately significantly improving the accuracy of website content recommendations and user satisfaction.
[0039] Preferably, the present invention further proposes a method for generating the morphological similarity, specifically including: Through the formula: ; Generating morphological similarity In the formula, This represents the standard candidate words. Terminology of search keywords Edit distance between This represents the terminology of the search keywords. The length of the string. This represents the standard candidate words. The length of the string; Among them, the edit distance between the standard candidate words and the search keywords is usually the number of single-character editing operations (such as insertion, deletion or replacement) required to convert one string into another. For example, it can be calculated using the Levenshtein distance algorithm. The similarity is calculated by considering the string length of the keyword term (i.e., the number of characters contained in the term) and the string length of the standard candidate word (i.e., the number of characters contained in the standard candidate word). The edit distance is normalized by dividing the edit distance by the maximum of the two string lengths, thus eliminating the influence of string length on the similarity calculation and ensuring comparability of morphological similarity between terms of different lengths and standard candidate words. Finally, the morphological similarity is obtained by subtracting the normalized edit distance from 1, ensuring that a higher similarity value indicates greater morphological similarity.
[0040] This application's solution introduces a clear formula to calculate morphological similarity, thus providing a quantitative and standardized basis for generating confidence weights for standard candidate words. When generating the confidence weights for standard candidate words, both morphological and semantic similarity between the standard candidate words and the lexical units of the search keywords need to be considered. The formula normalizes the edit distance between the lexical unit and the standard candidate word by dividing it by the maximum of the two string lengths. This normalization ensures that the morphological similarity value is always between 0 and 1, where 1 represents identical and 0 represents completely different. In this way, even if the length difference between the lexical unit and the standard candidate word is large, their morphological similarity can be fairly evaluated. This precise and standardized morphological similarity calculation method, combined with semantic similarity, can more accurately reflect the matching degree between the standard candidate words and the original search lexical units, thereby improving the accuracy of the confidence weight analysis model and laying the foundation for subsequently selecting more relevant reconstructed query terms.
[0041] By employing the above technical solution and using normalized edit distance to calculate morphological similarity, bias in similarity assessment caused by significant differences in length between lexical units and standard candidate words can be effectively avoided. This standardized calculation method allows morphological similarity to more accurately reflect the character-level matching degree between lexical units and standard candidate words. When this precise morphological similarity is combined with semantic similarity, the accuracy of the confidence weight analysis model can be significantly improved, thereby more reliably assessing the confidence of each standard candidate word. This ultimately helps to filter out reconstructed query terms that are highly matched to the user's original search intent in both morphology and semantics, thereby generating a more accurate user search intent vector and ultimately improving the accuracy of website content recommendations and user satisfaction.
[0042] Preferably, the present invention further proposes a method for generating the semantic similarity, specifically including: Through the formula: Generate semantic similarity In the formula, semantic similarity This refers to the terminology in the search keywords. Compared with standard candidate words Semantic similarity between them This represents the terminology in the search keywords. semantic vectors, This represents the standard candidate words. The semantic vector, where * is the dot product operator for vectors. It represents a word element. The modulus of a semantic vector This represents the standard candidate words. The model; Semantic similarity refers to the degree of semantic relevance between the lexical units in the search keywords and the standard candidate words. Its role is to assess the matching degree between the two at a semantic level, providing important semantic basis for the subsequent calculation of confidence weights. The formula for calculating semantic similarity is to calculate the cosine of the angle between two vectors, thereby measuring their directional consistency in the semantic space; its value range is usually between -1 and 1, the closer the value is to 1, the more similar the semantics are, the closer to -1, the less related or opposite the semantics are, and the closer to 0, the less related the semantics are. The modulus of standard candidate words, i.e. the length or size of the semantic vector of standard candidate words, serves a similar purpose to the modulus of the semantic vector of the lexical units of the search keywords, and is used for normalization processing.
[0043] This application addresses the problem of accurately quantifying the semantic relevance between lexical units in search keywords and standard candidate words by introducing a cosine similarity calculation method based on semantic vectors. Specifically, when generating the confidence weights of standard candidate words, both morphological and semantic similarity need to be considered. This solution obtains the semantic vectors of lexical units in search keywords and the semantic vectors of standard candidate words, and calculates them using the cosine similarity formula. This method effectively captures the directional consistency between lexical units and standard candidate words in a multidimensional semantic space, thus accurately reflecting the degree of semantic relevance between them. The semantic similarity obtained in this way can be more accurately input into the confidence weight analysis model, enabling the confidence weights of the final generated standard candidate words to more realistically reflect their semantic matching degree with the user's search intent, thereby improving the quality of subsequent query word reconstruction and the accuracy of website content recommendations.
[0044] Through the above technical solution, this application can accurately quantify the semantic relevance between lexical units in search keywords and standard candidate words. By employing cosine similarity calculation based on semantic vectors, it can effectively capture the deep semantic information of words, avoiding semantic biases that may result from relying solely on literal matching or morphological similarity. This allows the generation of confidence weights for standard candidate words to more accurately reflect their semantic matching degree with the user's search intent, thereby improving the reliability of the confidence weights. Ultimately, this helps generate reconstructed query terms that better match the user's true intent, thus significantly improving the accuracy of website content recommendations and user satisfaction.
[0045] Preferably, the present invention further proposes the following expression for the confidence weight analysis model: In the expression, This represents the standard candidate words. Confidence weights This indicates morphological similarity. This represents semantic similarity, where a and b are both proportional coefficients, and a+b=1; The confidence weight analysis model is used to calculate the confidence weight of standard candidate words. Its core lies in merging two different types of similarity metrics, morphological similarity and semantic similarity, into a unified confidence score through weighted combination. This expression provides a structured method to balance the importance of word form matching and word meaning matching in evaluating standard candidate words, thereby reflecting the degree of association between standard candidate words and original search terms more comprehensively and accurately. The proportional coefficients 'a' and 'b' are used to adjust the relative importance of morphological and semantic similarity when calculating confidence weights. By adjusting the values of 'a' and 'b', the model's emphasis on word form matching and word meaning matching can be flexibly controlled. For example, when the value of 'a' is large, the model tends to select standard candidate words that are highly similar to the original word units in spelling; when the value of 'b' is large, the model tends to select standard candidate words that are highly related to the original word units in semantics. These coefficients can be optimized through machine learning methods (such as regression analysis, gradient descent, etc.) on labeled datasets, or they can be preset based on domain expert experience.
[0046] This application's solution addresses the problem of effectively quantifying the confidence of standard candidate words by introducing a clear confidence weight analysis model expression that weights and fuses morphological and semantic similarity. The expression linearly combines morphological similarity and normalized semantic similarity. Semantic similarity is mapped to a 0-1 range by adding 1 and dividing by 2, ensuring consistency with the morphological similarity range and thus guaranteeing comparability between the two similarity metrics during fusion. Proportion coefficients a and b (with a+b=1) act as adjustment factors, allowing the system to flexibly adjust the contribution ratio of morphological and semantic similarity to the final confidence weight based on the needs of the actual application scenario. For example, in scenarios sensitive to spelling errors, the value of a can be appropriately increased; while in scenarios focusing more on semantic generalization and synonym matching, the value of b can be increased. This weighted fusion mechanism enables the confidence weight to comprehensively reflect the degree of matching between the standard candidate words and the lexical units of the search keywords in both form and meaning, thus providing a more accurate and reliable basis for subsequently selecting the reconstructed query terms that best represent the user's search intent. In this way, the solution can more accurately identify standard candidate words that are both similar in form and related in meaning, significantly improving the accuracy of understanding the user's search intent.
[0047] Through the above technical solution, this application provides a structured and adjustable mechanism for comprehensively evaluating the confidence level of standard candidate words. This solution weights and fuses morphological and semantic similarity, introducing an adjustable ratio coefficient, allowing the system to flexibly balance the importance of word form matching and word meaning matching according to actual needs. This not only solves the limitations of a single similarity indicator but also captures the correlation between standard candidate words and original search terms more comprehensively and accurately. Therefore, this solution can effectively improve the screening accuracy of standard candidate words, reduce misjudgments caused by spelling errors or semantic comprehension biases, thus laying a solid foundation for the subsequent generation of standardized user search intent vectors, and ultimately significantly improving the accuracy of website content recommendations and user satisfaction.
[0048] Preferably, the present invention further proposes a method for generating the standardized user search intent vector, specifically including: Through the formula: Generate standardized user search intent vectors In the formula, This represents the j-th reconstructed query term. semantic vectors, This represents the j-th reconstructed query term. The weight coefficient, m represents the total number of reconstructed query terms; The standardized user search intent vector aims to comprehensively represent a user's overall intent when making a search. Its "standardization" is reflected in the normalization of the vector's magnitude, ensuring comparability of intent vectors generated by different users or different queries in subsequent similarity calculations and avoiding bias introduced by differences in vector length. This vector forms the basis for subsequent matching and scoring in website content recommendation analysis models.
[0049] The weight coefficient of the j-th reconstructed query term reflects the importance or confidence level of each reconstructed query term in expressing the user's overall search intent. This weight coefficient can be derived from the confidence weights of the standard candidate terms generated in the previous step S30. For example, if the reconstructed query term is directly selected from a certain standard candidate term, then... You can directly use the corresponding This application's solution generates a standardized user search intent vector by weighted summation of the semantic vectors of reconstructed query terms and normalization of the results. Specifically, firstly, for each reconstructed query term, its corresponding semantic vector is obtained, which carries the semantic information of the word. Simultaneously, each reconstructed query term is assigned a weight coefficient, which is derived from the confidence weights of its source standard candidate terms and reflects the reliability and importance of the reconstructed query term in expressing user intent. Then, the semantic vector of each reconstructed query term is multiplied by its corresponding weight coefficient to obtain a weighted semantic vector. Next, all weighted semantic vectors are summed to form a comprehensive intent vector. Finally, to eliminate the influence of the vector magnitude on subsequent similarity calculations, this comprehensive intent vector is normalized by dividing it by its own magnitude, thus obtaining a standardized user search intent vector. In this way, this application can effectively integrate the semantic information of multiple reconstructed query terms with different importance into a unified and standardized vector representation, so that the vector can accurately and comprehensively reflect the user's overall search intent and lay the foundation for efficient and accurate similarity calculation with website content feature vectors, thereby overcoming the complexity and inaccuracy of directly using multiple reconstructed query terms for matching.
[0050] Through the above technical solution, this application can effectively integrate the semantic information of multiple reconstructed query terms and assign different weights based on their confidence levels, thereby generating a unified and standardized user search intent vector. This weighted summation and normalization process not only more accurately captures the user's complex search intent and avoids information distortion that may result from simple averaging or splicing, but also ensures the standardization of the intent vector. This allows for fair and effective comparison when calculating similarity with website content feature vectors, significantly improving the accuracy and relevance of website content recommendations. Especially when the number and importance of reconstructed query terms vary, this solution can flexibly adapt, ensuring that the final recommendation results better meet the user's actual needs.
[0051] For preferred options, please refer to [link / reference]. Figure 3 The present invention further proposes a method for generating the final recommendation score for website content, specifically including: Step S61: Generate a preliminary recommendation score for website content based on the standardized user search intent vector and the feature vector of website content; Step S62: Based on the preliminary recommendation score of the website content, establish a website content recommendation analysis model and generate the final recommendation score of the website content; The specific expression for the website content recommendation analysis model is as follows: In the expression, This refers to the website content. Final recommended score This refers to the website content. Preliminary recommended score, This refers to the website content. Popularity indicator value This refers to the website content. Freshness index value All are weighting ratio coefficients, and Step S61 aims to quantify the semantic relevance between user search intent and website content. This can be achieved by calculating the cosine similarity between the standardized user search intent vector and the feature vector of the website content, thereby obtaining a preliminary semantic matching score. This score is a fundamental indicator for measuring the semantic relevance of content.
[0052] Step S62 aims to construct a comprehensive recommendation evaluation model based on the initial semantic matching score and other considerations. This model aims to comprehensively evaluate multiple dimensions of website content to generate a more comprehensive recommendation score that better meets user expectations. In addition to semantic relevance, the model can also integrate non-semantic factors such as content popularity and freshness, thereby providing more practically valuable recommendation results.
[0053] The final recommendation score for website content is the final evaluation value output by the website content recommendation analysis model. It is used to quantify the overall recommendation priority of specific website content relative to a user's search intent. The higher the score, the more suitable the website content is to be recommended to the user.
[0054] The website content popularity index reflects the popularity or attention a website's content receives among its user base. It can be calculated based on various metrics, such as statistical and weighted averages of user interaction data like page views, shares, likes, comments, and saves; or it can be evaluated based on dynamic indicators like content access trends over a specific time period and the breadth of its social media reach.
[0055] The website content freshness indicator represents the timeliness or update frequency of website content. It can be calculated based on timestamp information such as the content's publication date, last modified date, and update frequency; or it can be qualitatively or quantitatively evaluated based on attributes such as the timeliness and newsworthiness of the topic.
[0056] Weighting ratio coefficient These coefficients are used to adjust the relative importance of the initial recommendation score, popularity indicator, and freshness indicator for website content in the website content recommendation analysis model. These coefficients can be determined in various ways, for example, by training and optimizing historical user behavior data using machine learning algorithms such as linear regression and gradient boosting trees.
[0057] This application optimizes the generation method of the final recommendation score for website content by introducing a website content recommendation analysis model. Specifically, after obtaining standardized user search intent vectors and website content feature vectors, step S61 is first executed to generate a preliminary recommendation score for the website content based on the semantic similarity between the two. This preliminary score only reflects the semantic matching degree between the content and the user's intent. Based on this, step S62 is executed, that is, based on the generated preliminary recommendation score of the website content and combined with other factors, a website content recommendation analysis model is established to generate the final recommendation score for the website content. This model not only considers the aforementioned preliminary recommendation score of the website content, but also incorporates the website content popularity indicator value and the website content freshness indicator value. By integrating these three key indicators in a weighted summation manner, the final recommendation score for the website content is generated. This integration mechanism enables the recommendation system to go beyond simple semantic matching, comprehensively considering the popularity and timeliness of the content, thereby more accurately capturing the diverse needs of users. For example, for news content, freshness may be given higher weight; while for classic tutorials or entertainment content, popularity may be more crucial. In this way, the solution can flexibly adjust the influence of various factors according to different content types or user preferences, so that the final recommendation results are not only semantically relevant, but also more attractive and practical.
[0058] Through the aforementioned technical solution, this application, when generating the final recommendation score for website content, not only considers the semantic matching degree between the user's search intent and the website content, but also creatively incorporates website content popularity and freshness indicators. This multi-dimensional evaluation mechanism effectively compensates for the limitations of recommendation results that may arise from single semantic matching, enabling the recommendation system to more comprehensively understand user needs. Specifically, the introduction of website content popularity indicators allows the system to identify and prioritize recommending high-quality content that is currently attracting significant attention and has frequent user interaction, thereby improving the efficiency and experience of users obtaining trending information. Simultaneously, the introduction of website content freshness indicators ensures the timeliness of recommended content, especially for scenarios with high real-time requirements such as news and technology updates, ensuring that the latest information is presented to users promptly and avoiding the recommendation of outdated content. Therefore, this solution can generate a more accurate, attractive, and user-centric final recommendation score for website content, significantly improving the quality of automatic website content recommendation and user satisfaction.
[0059] Preferably, the present invention further proposes a method for generating the preliminary recommendation score for website content, specifically including: Through the formula: ; Generate preliminary recommendation scores for website content In the formula, This represents a standardized user search intent vector. This refers to the website content. The eigenvectors are represented by , and * is the dot product operator for vectors. This represents the magnitude of the standardized user search intent vector. This refers to the website content. The magnitude of the eigenvectors; The feature vector of website content is the representation of the semantic features of the website content in a vector space. Its function is to abstract various forms of information from website content, such as text, images, and videos, into a unified numerical form for comparison with the user's search intent vector. This vector can be encoded into a fixed-length vector by performing text analysis (such as TF-IDF, word embedding averaging, and document embedding models like Doc2Vec), image feature extraction (such as CNN features), and video feature extraction on the website content.
[0060] This application's solution generates a preliminary recommendation score for website content by calculating the cosine similarity between a standardized user search intent vector and a feature vector of the website content. Specifically, firstly, a standardized user search intent vector representing the user's deep semantic intent is obtained. This vector has already aggregated and standardized the semantic information of the user's search intent by processing the user's input search keywords through a series of processes (such as lexicalization, semantic vector mapping, standard candidate word selection, and query term reconstruction). Simultaneously, a feature vector representing the semantic information of the website content is obtained; this vector is the result of feature extraction and encoding of the website content. Then, by calculating the dot product of these two vectors and dividing by the product of their respective moduli, a value between -1 and 1 is obtained, namely the cosine similarity. This value intuitively reflects the directional consistency between the user's search intent and the website content in the semantic space; the larger the value, the higher the semantic relevance. This cosine similarity-based calculation method can effectively capture the deep semantic relationship between user intent and website content, overcoming problems such as word form changes, synonyms, and polysemous words that may exist in traditional keyword matching. This provides a more accurate semantic matching metric for subsequent website content recommendation analysis models, significantly improving the accuracy and relevance of recommendations.
[0061] By employing the aforementioned technical solution, the initial recommendation score is quantified using the cosine similarity between the standardized user search intent vector and the feature vector of website content. This effectively overcomes the limitations of traditional keyword-based recommendation methods in handling semantic complexity. This method can deeply mine the semantic connections between user search intent and website content. Even if keywords do not perfectly match, a high semantic relevance can still yield a high matching score. This significantly improves the accuracy and relevance of recommendation results, enabling the recommendation system to more accurately understand user needs and recommend website content that better matches their underlying intentions, thereby increasing user satisfaction and recommendation efficiency.
[0062] For preferred options, please refer to [link / reference]. Figure 4 The present invention also proposes an automatic website content recommendation system based on search keywords. This system is used to execute the above-mentioned automatic website content recommendation method based on search keywords, specifically including: Data acquisition unit 10 is used to acquire each word element in the search keywords and map each word element into a word element semantic vector; The standard candidate word analysis unit 20 is used to generate standard candidate words based on the semantic vector of the word element; wherein, the standard candidate word refers to the standard keyword that matches the word elements in the search keyword; The confidence weight analysis unit 30 is used to obtain the edit distance between the lexical units of the standard candidate words and the search keywords and the semantic vector of the standard candidate words. Based on the edit distance between the lexical units of the standard candidate words and the search keywords and the semantic vector of the standard candidate words, a confidence weight analysis model is established to generate the confidence weight of the standard candidate words. The filtering unit 40 is used to filter standard candidate words according to their confidence weights and generate reconstructed query terms. The retrieval intent analysis unit 50 is used to obtain the semantic vector of the reconstructed query term and generate a standardized user retrieval intent vector based on the semantic vector of the reconstructed query term. The recommendation score analysis unit 60 is used to obtain the feature vector of the website content, establish a website content recommendation analysis model based on the standardized user search intent vector and the feature vector of the website content, and generate the final recommendation score of the website content. Recommendation Unit 70 is used to recommend website content based on the final recommendation score of the website content.
[0063] For preferred options, please refer to [link / reference]. Figure 5 The present invention further proposes that the confidence weight analysis unit 30 specifically includes: The morphological analysis module 31 is used to generate morphological similarity based on the edit distance between the lexical units of the standard candidate words and the search keywords; The semantic analysis module 32 is used to generate semantic similarity based on the semantic vectors of standard candidate words; The confidence weight output module 33 is used to establish a confidence weight analysis model based on morphological similarity and semantic similarity, and generate the confidence weight of standard candidate words.
[0064] For preferred options, please refer to [link / reference]. Figure 6 The present invention further proposes that the recommendation score analysis unit 60 specifically includes: The preliminary analysis module 61 is used to generate a preliminary recommendation score for website content based on the standardized user search intent vector and the feature vector of website content. The comprehensive analysis module 62 is used to build a website content recommendation analysis model based on the preliminary recommendation score of the website content and generate the final recommendation score of the website content.
[0065] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.
Claims
1. A method for automatically recommending website content based on search keywords, characterized in that, include: Extract each word element from the search keywords and map each word element into a word element semantic vector; Based on the semantic vector of the word element, standard candidate words are generated; where standard candidate words refer to standard keywords that match the word elements in the search keywords. Obtain the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words. Based on the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words, establish a confidence weight analysis model to generate the confidence weight of the standard candidate words. Based on the confidence weight of the standard candidate terms, the standard candidate terms are filtered to generate reconstructed query terms; Obtain the semantic vector of the reconstructed query term, and generate a standardized user search intent vector based on the semantic vector of the reconstructed query term; Obtain the feature vectors of website content, build a website content recommendation analysis model based on the standardized user search intent vectors and website content feature vectors, and generate the final recommendation score for website content. The website content is recommended based on its final recommendation score.
2. The method for automatically recommending website content based on search keywords according to claim 1, characterized in that, The specific methods for generating the standard candidate words include: Through the formula: ; Generate standard candidate words In the formula, This represents the terminology in the search keywords. semantic vectors, This represents the semantic vector of word l in the standard keyword library L, and * is the dot product operator for vectors. It represents a word element. The modulus of a semantic vector It represents the modulus of the semantic vector of the word l.
3. The method for automatically recommending website content based on search keywords according to claim 1, characterized in that, The specific methods for generating the confidence weights of the standard candidate words include: Based on the edit distance between the lexical units of the standard candidate words and the search keywords, morphological similarity is generated; Generate semantic similarity based on the semantic vectors of standard candidate words; A confidence weight analysis model is established based on morphological similarity and semantic similarity to generate confidence weights for standard candidate words.
4. The method for automatically recommending website content based on search keywords according to claim 3, characterized in that, The specific methods for generating the morphological similarity include: Through the formula: ; Generating morphological similarity In the formula, This represents the standard candidate words. Terminology of search keywords Edit distance between This represents the terminology of the search keywords. The length of the string. This represents the standard candidate words. The length of the string.
5. The method for automatically recommending website content based on search keywords according to claim 3, characterized in that, The specific methods for generating semantic similarity include: Through the formula: Generate semantic similarity In the formula, semantic similarity This refers to the terminology in the search keywords. Compared with standard candidate words Semantic similarity between them This represents the terminology in the search keywords. semantic vectors, This represents the standard candidate words. The semantic vector, where * is the dot product operator for vectors. It represents a word element. The modulus of a semantic vector This represents the standard candidate words. The model.
6. The method for automatically recommending website content based on search keywords according to claim 3, characterized in that, The specific expression of the confidence weight analysis model is as follows: In the expression, This represents the standard candidate words. Confidence weights This indicates morphological similarity. This represents semantic similarity, where a and b are both proportional coefficients, and a+b=1.
7. The method for automatically recommending website content based on search keywords according to claim 1, characterized in that, The standardized method for generating user search intent vectors specifically includes: Through the formula: Generate standardized user search intent vectors In the formula, This represents the j-th reconstructed query term. semantic vectors, This represents the j-th reconstructed query term. The weight coefficient is m, which represents the total number of reconstructed query terms.
8. The method for automatically recommending website content based on search keywords according to claim 1, characterized in that, The specific methods for generating the final recommendation score for website content include: Based on standardized user search intent vectors and website content feature vectors, a preliminary recommendation score for website content is generated. Based on the initial recommendation score of website content, a website content recommendation analysis model is established to generate the final recommendation score of website content. The specific expression for the website content recommendation analysis model is as follows: In the expression, This refers to the website content. Final recommended score This refers to the website content. Preliminary recommended score, This refers to the website content. Popularity indicator value This refers to the website content. Freshness index value All are weighting ratio coefficients, and .
9. The method for automatically recommending website content based on search keywords according to claim 8, characterized in that, The specific methods for generating the preliminary recommendation score for website content include: Through the formula: ; Generate preliminary recommendation scores for website content In the formula, This represents a standardized user search intent vector. This refers to the website content. The eigenvectors are represented by , and * is the dot product operator for vectors. This represents the magnitude of the standardized user search intent vector. This refers to the website content. The modulus of the eigenvectors.
10. A website content automatic recommendation system based on search keywords, characterized in that, The system is used to execute the automatic website content recommendation method based on search keywords as described in any one of claims 1-9, specifically including: The data acquisition unit is used to acquire each word element in the search keywords and map each word element into a word element semantic vector. The standard candidate word analysis unit is used to generate standard candidate words based on the semantic vector of the word element; where standard candidate words refer to standard keywords that match the word elements in the search keywords. The confidence weight analysis unit is used to obtain the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words. Based on the edit distance between the lexical units of the standard candidate words and the search keywords, and the semantic vector of the standard candidate words, a confidence weight analysis model is established to generate the confidence weight of the standard candidate words. The filtering unit is used to filter standard candidate terms based on their confidence weights and generate reconstructed query terms. The retrieval intent analysis unit is used to obtain the semantic vector of the reconstructed query terms and generate a standardized user retrieval intent vector based on the semantic vector of the reconstructed query terms. The recommendation score analysis unit is used to obtain the feature vector of website content, build a website content recommendation analysis model based on the standardized user search intent vector and the feature vector of website content, and generate the final recommendation score of website content. The recommendation unit is used to recommend website content based on the final recommendation score.