Web page search result ranking adjustment method and system based on machine learning
By constructing a web page dataset and using machine learning to update keyword information, and combining user and public models to optimize search result ranking, the problem of lack of personalization in ranking results in existing technologies is solved, and a more targeted search result display is achieved.
Patent Information
- Application Number
- CN202510286112.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-12
- Publication Date
- 2025-09-12
- Estimated Expiration
- 2045-03-12
AI Technical Summary
Existing web search engines are unable to automatically adjust search strategies based on changes in user search habits, and are unable to balance the differences in search capabilities and strategies of different users, resulting in a lack of personalization and intelligence in the sorting results.
Build a web page dataset to store keyword sets, click counts, browsing time, and matching weights. Update this data through machine learning, adjust the search result ranking based on the user's historical operation information and semantic similarity, and further optimize it by combining user models and public models.
It realizes the dynamic adjustment of search result sorting according to user behavior, improves the pertinence and personalization of sorting, reflects the participation of user behavior in search results, and enhances the accuracy of search results and user experience.
Smart Images

Figure CN119782629B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of web page search, and in particular to a method and system for adjusting the ranking of web page search results based on machine learning. Background Art
[0002] Various search engines have important value in network applications. Users can obtain the information they need based on the search functions provided by the engines.
[0003] Faced with massive network resources, different servers provide different search methods to provide users with accurate information; the server extracts the required information from the user's search information, and then based on their own different strategies, algorithms, etc., screens out resources corresponding to the search information from the massive network resources.
[0004] However, the screening methods and web page sorting methods currently provided by servers are mostly fixed. For the same search information, the sorting results provided are also fixed; it is impossible to adaptively adjust the search strategy based on changes in user search habits.
[0005] In addition, for the same information needs, different users have different search strategies, and the search capabilities between users vary greatly. The server cannot balance the differences in users' search capabilities and strategies, and cannot intelligently expand and match search strategies and results for users. Summary of the Invention
[0006] To address the deficiencies of the prior art, the present invention provides a method for adjusting the ranking of web page search results based on machine learning, comprising the following steps:
[0007] S1: Constructs a dataset corresponding to the web page. The dataset stores:
[0008] Category tags of web pages;
[0009] At least one keyword set and the total number of clicks, total browsing time, and matching weight of each keyword set with the web page;
[0010] The quantity identifier of each keyword in the set of all keywords;
[0011] S2: Based on the historical operation information, the total number of clicks, total browsing time, matching weight with the web page, and the number of keywords in each keyword set are updated;
[0012] S3: Get the user's current search information;
[0013] S4: Obtaining semantic similarity between the user's current search information and the webpage dataset information, and adjusting the webpage ranking based on the semantic similarity to obtain a first ranking;
[0014] S5: adjusting the first ranking based on the user model and the public model to obtain a second ranking;
[0015] S6: Based on the semantic similarity between the user's historical search information and the current search information, adjust the second ranking to obtain a third ranking.
[0016] In S1, when constructing the data set, at least one keyword set is initialized based on the content information of the web page, and a number of keywords, a total number of clicks, a total browsing time, and a matching weight are initialized for each keyword set. The initial total number of clicks, the initial total browsing time, and the initial matching weight of each keyword set are 0, 0, and the same;
[0017] The matching degree between all the keywords in each keyword set is greater than a first predetermined value;
[0018] A quantity identifier is initialized for each keyword in the keyword set, and the initial value of the quantity identifier is 0.
[0019] The updating of the matching weight, total click count, total browsing time of each keyword set, and the quantity identifier of each keyword in each keyword set based on the historical operation information includes the following steps:
[0020] S21: Acquire search information corresponding to a search operation in which a click operation is performed on a webpage and the stay time on the webpage exceeds a first predetermined time period;
[0021] S22: extract all keywords from the search information as keywords to be matched;
[0022] Perform the following operations for each keyword to be matched:
[0023] S23: traverse all keyword sets of the web page, and for each keyword set, obtain a keyword as an existing keyword;
[0024] S24: Obtain the matching degree between the keyword to be matched and the existing keyword, and determine whether there is an existing keyword that reaches a first predetermined value:
[0025] If so, determine whether there is a keyword that is consistent with the keyword to be matched in the keyword set where the existing keyword that has reached the first predetermined value is located: if there is a consistency, update the quantity identifier of the keyword that is consistent with the keyword to be matched, and increase its value by 1; if there is no consistency, add the keyword to be matched to the keyword set where the existing keyword that has reached the first predetermined value is located, and initialize its quantity identifier to 1; at the same time, update the total number of clicks, total browsing time and matching weight of the keyword set where the existing keyword is located;
[0026] If it does not exist, create a new keyword set and add the keywords to be matched to the new keyword set, initialize its quantity identifier to 1, and initialize a matching weight, total number of clicks, and total browsing time for the new keyword set, and update the matching weight.
[0027] The following steps are used to update the matching weight of the keyword set where the existing keyword is located:
[0028] Q=Q inital + (x1+T ime / n) / x2+(y1+n) / y2;
[0029] Among them, Q is the matching weight, Q inital is the initial matching weight, x1, x2, y1 and y2 are adjustment factors, T ime is the total browsing time, n is the total number of clicks;
[0030] When there is an existing keyword that reaches the first predetermined value, the total number of clicks of the keyword set to which the existing keyword belongs is increased by 1, and the total browsing time is added to the dwell time obtained in S21.
[0031] When traversing all keyword sets of a web page, for each keyword set, the keyword with the largest quantity identifier is obtained as the existing keyword;
[0032] If there are multiple keywords with the maximum number of identifiers in a keyword set, one is randomly selected as the existing keyword.
[0033] The matching degree between the keywords to be matched and the existing keywords is obtained by performing sequence conversion on the keywords to be matched and the existing keywords based on the BOW model to obtain the first vector and the second vector respectively, and calculating the inner product of the first vector and the second vector. The inner product value is the matching degree.
[0034] The following steps are used to obtain the semantic similarity between the user's current search information and the webpage dataset information, and the webpage search ranking is adjusted based on the semantic similarity to obtain the first ranking:
[0035] S41: extracting keywords from current search information;
[0036] S42: Obtain the mean of the sum of the word vectors of all keywords in S41 as the first word vector;
[0037] S43: Obtain one keyword from each of the keyword sets on the web page;
[0038] S44: Obtain the second word vector using the following formula: ;
[0039] Among them, C is the second word vector, m is the total number of keywords extracted in S43, is the word vector of the keyword extracted in S43; For word vector The weight value is the matching weight corresponding to the keyword set to which the keyword belongs.
[0040] In S43, a keyword with the largest number identifier is obtained from all keyword sets on the web page. If a keyword set contains multiple keywords with the largest number identifiers, one is randomly selected.
[0041] The present invention further provides a webpage search result ranking adjustment system based on machine learning, comprising:
[0042] Client, used to receive user search information;
[0043] A server, connected to the client, is used to adjust the ranking of web page search results based on the user's search information;
[0044] The server stores a data set for each web page. The data set for each web page contains:
[0045] Category tags of web pages;
[0046] At least one keyword set and the total number of clicks, total browsing time, and matching weight of each keyword set with the web page;
[0047] The quantity identifier of each keyword in the set of all keywords;
[0048] The server updates the total number of clicks, total browsing time, matching weight with web pages, and quantity identifiers of each keyword in each keyword set based on the historical operation information;
[0049] When the server adjusts the ranking of web page search results, it obtains the semantic similarity between the user's current search information and the web page dataset information, and adjusts the web page ranking based on the semantic similarity to obtain a first ranking.
[0050] When the server adjusts the ranking of web page search results, it also includes:
[0051] Adjust the first ranking based on the user model and the public model to obtain a second ranking;
[0052] Based on the semantic similarity between the user's historical search information and the current search information, the second ranking is adjusted to obtain a third ranking.
[0053] When sorting web pages, the present invention fully considers the user's historical operations on the web pages, matches the user's operations with the search information, and updates the web page data set information based on the search information, continuously completing keywords and related matching weights, and assigning different quantity identifiers to different keywords, and assigning different matching weights to different keyword sets; the sorting results of web pages are no longer determined by the server or developer in a single dimension; but are continuously improved based on the user's operation behavior over time, and can automatically improve the missing keywords in the data set; the more search behaviors the user has, the more targeted the ranking given, which fully reflects the participation of user behavior in the search results. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] Figure 1 : A flow chart of updating a web page data set in the web page search result ranking adjustment method based on machine learning of the present invention.
[0055] Figure 2 : System architecture diagram of the web page search result ranking adjustment system based on machine learning of the present invention. DETAILED DESCRIPTION
[0056] In order to have a further understanding of the technical solution and beneficial effects of the present invention, the technical solution and beneficial effects of the present invention are described in detail below with reference to the accompanying drawings.
[0057] 1. Construction of Web Page Dataset
[0058] For each web page that needs to be indexed, the present invention constructs a data set for it, which stores:
[0059] 1. The classification label of the web page. This classification label is pre-set and represents the category of the content provided by the web page, such as computers, architecture, chemistry, life encyclopedia, food, etc.
[0060] 2. At least one keyword set and the total number of clicks, total browsing time, and matching weight of each keyword set with the web page.
[0061] For web pages, there should be more than one set of keywords that can represent the attributes of the web pages. When constructing a data set, the present invention initializes at least one keyword set for each web page based on the content information of the web page and initializes several keywords, a total number of clicks, a total browsing time and a matching weight for each keyword set.
[0062] Each keyword set characterizes the attributes of a webpage from a different perspective; the multiple keywords in each keyword set are synonymous with each other. The total number of clicks, total browsing time, and matching weight corresponding to the keyword set represent, from different perspectives, the reliability and satisfaction of users in finding the webpage based on the keywords in the keyword set, and also the degree of fit between the keywords in the keyword set and the webpage. Each keyword set has an initial total number of clicks of 0, an initial total browsing time of 0, and an initial matching weight that is the same. The specific value of the initial matching weight can be adaptively set based on actual needs.
[0063] As described above, the multiple keywords in each keyword set are synonymous with each other, so the matching degree between all the keywords in each keyword set is greater than a first predetermined value.
[0064] The method for determining the matching degree between keywords is as follows: represent the two keywords as the first keyword and the second keyword respectively, perform sequence conversion on the first keyword and the second keyword based on the BOW model, obtain the first vector of the first keyword and the second vector of the second keyword respectively, calculate the inner product of the first vector and the second vector, and the inner product value is the matching degree.
[0065] The first predetermined value may be set in advance based on needs, or may be determined by calculating the matching degrees of two keywords in an existing keyword set and performing a certain linear summation on the calculated multiple matching degrees.
[0066] For example, suppose a webpage is titled "Methods for Extracting Pigments from Carrots" and its content mainly introduces how to obtain pigments through solvent extraction. The category tag of the webpage can be "Chemistry". When the webpage is initialized, the following keyword set can be constructed for it:
[0067] The first keyword set includes the following keywords: carrot, red lettuce, small ginseng;
[0068] The second keyword set includes the following keywords: pigment, carotene;
[0069] The third keyword set includes the following keywords: extraction and extraction.
[0070] 3. The number of each keyword in the set of all keywords
[0071] The quantity identifier of a keyword is usually used to represent the user's tendency to type the keyword when searching for related web pages. The larger the value of the quantity identifier, the more inclined the user is to search using the keyword when searching for this type of web pages.
[0072] The present invention initializes a quantity identifier for each keyword in the keyword set, and the initial value of the quantity identifier is 0.
[0073] 2. Update of Web Dataset
[0074] Please combine Figure 1 , is a flow chart for updating a web page data set of the present invention. The present invention updates the total number of clicks, total browsing time, matching weight of each keyword set, and the quantity identifier of each keyword in each keyword set based on historical operation information.
[0075] Historical operation information can be understood as after the data set of the web page is built, as the user continues to search and browse, different web pages are clicked under the user's different search strategies; therefore, the present invention updates the data set of the web page based on the search information typed by the user and the user's operations on the web page under the relevant search information, so as to continuously improve and optimize the search information that the data set can provide to the user, and continuously increase the pertinence and accuracy of subsequent searches.
[0076] The present invention can periodically obtain historical operation information of users and update web page data sets according to the obtained historical operation information.
[0077] The specific update steps are as follows:
[0078] 1. Acquire search information corresponding to a search operation in which a click operation is performed on a web page and the stay time on the web page exceeds a first predetermined time period.
[0079] When a user clicks on a web page and stays on the page for more than a certain period of time, it means that the web page provides the information the user needs. Then it can be considered that there is a high degree of match between the search information of the user when performing the search operation and the content provided by the web page; therefore, in this case, the search information corresponding to the user's search operation is obtained.
[0080] Suppose a user types "how to extract carotenoids" in the search box, clicks on the webpage "Methods for extracting pigments from carrots" in the search results, and browses for a certain period of time. Then, the dataset of the webpage "Methods for extracting pigments from carrots" needs to be updated based on "how to extract carotenoids".
[0081] For each search information, perform the following operations.
[0082] 2. Extract all keywords from the search information as keywords to be matched.
[0083] The search information is the search information typed by the user when searching for a web page. It can be sentence information or keywords. When it is sentence information, keywords need to be extracted through a pre-trained keyword extraction model, or keywords can be extracted from the sentence information through a word segmentation tool.
[0084] Assume that a user types "how to extract carotenoids" in the search box, then the keywords "carotenoids" and "extraction" are extracted through the keyword extraction model or word segmentation tool.
[0085] 3. Perform the following operations for each keyword to be matched (corresponding to Figure 1 After traversing the logical content of the keywords to be matched)
[0086] (1) Traverse all keyword sets of the web page, and for each keyword set, obtain a keyword from it as the existing keyword;
[0087] As described above, each keyword in each keyword set has a quantity identifier, which represents the number of times the user used this keyword when searching for this web page, and represents the user's tendency or selection habit for keywords when searching for this web page. Using the keyword with the most search times for subsequent matching operations can also improve matching efficiency; therefore, when determining existing keywords from the keyword set, the present invention obtains the keyword with the largest quantity identifier as the existing keyword; if there is more than one keyword with the largest quantity identifier in a keyword set, one is randomly selected as the existing keyword.
[0088] (2) Obtaining the matching degree between the keyword to be matched and the existing keyword, and determining whether there is an existing keyword that reaches a first predetermined value;
[0089] The method for determining the matching degree between keywords is the same as above: represent the two keywords as the first keyword and the second keyword respectively, perform sequence conversion on the first keyword and the second keyword based on the BOW model, obtain the first vector of the first keyword and the second vector of the second keyword respectively, calculate the inner product of the first vector and the second vector, and the inner product value is the matching degree.
[0090] (3) Choose different update strategies based on different situations
[0091] The first case: there are existing keywords that reach the first predetermined value;
[0092] At this time, it is further determined whether there is a keyword that is consistent with the keyword to be matched in the keyword set where the existing keywords that have reached the first predetermined value are located:
[0093] If there is a match, update the quantity flag of the keyword that matches the keyword to be matched, and increase its value by 1;
[0094] If there is no match, the keyword to be matched is added to the keyword set where the existing keywords that have reached the first predetermined value are located, and its quantity flag is initialized to 1;
[0095] Finally, update the total number of clicks, total browsing time and matching weight of the keyword set where the existing keyword is located;
[0096] The second situation: there are no existing keywords that reach the first predetermined value; at this time, a new keyword set is created, and the keywords to be matched are added to the newly created keyword set, and its quantity identifier is initialized to 1. A matching weight, total number of clicks, and total browsing time are initialized for the newly created keyword set, and the matching weight is updated.
[0097] For the first scenario, as described above, the user searches for "How to extract carotenoids" and finds the webpage "Methods for extracting pigments from carrots." In this case, the keyword "carotenoids" is used as a matching keyword and matched one-to-one with the existing keywords selected from the first keyword set, the second keyword set, and the third keyword set. Assume that the keywords selected from the first keyword set, the second keyword set, and the third keyword set are "carrot," "carotene," and "extraction." After calculating the matching degree, it is determined that the matching degree between "carotene" and "carotenoids" is greater than a first predetermined value. Therefore, it can be determined that "carotene" and "carotenoids" are synonyms within the content provided by the webpage.
[0098] At this point, determine whether the keyword "carotenoids" exists in the second keyword set where "carotene" is located: since the keyword "carotenoids" does not exist in the second keyword set at this time, "carotenoids" is added to the second keyword set and a quantity flag is initialized to 1 for it; (at this point, the keyword "carotenoids" exists in the second keyword set. When another user finds this webpage based on the keyword "carotenoids" and previews it for a certain period of time, the quantity flag of "carotenoids" is increased by 1 based on the above update step, and is counted as 2).
[0099] Finally, the total number of clicks, total browsing time, and matching weight of the second keyword set are updated.
[0100] In addition, for the keyword "extraction" to be matched, the same update operation as above is used to update the quantity identifier of the keyword "extraction" in the third keyword set, and the total number of clicks, total browsing time and matching weight of the third keyword set are updated.
[0101] It is not difficult to understand that the updated total number of clicks is the original total number of clicks plus 1; the updated total browsing time is the original total browsing time plus the browsing time after the user opens the webpage in this round of update operation.
[0102] The matching weights of the second keyword set and the third keyword set are updated using the following formula:
[0103] Q=Q inital + (x1+T ime / n) / x2+(y1+n) / y2;
[0104] Among them, Q is the matching weight, Q inital is the initial matching weight, x1, x2, y1 and y2 are adjustment factors, T ime is the total browsing time, and n is the total number of clicks.
[0105] “T ime " / n" can represent the average browsing time of the web page in the user's historical operations, "T ime / n" and "n" represent the user's satisfaction with the webpage and the matching degree of the webpage to the user's search information from different dimensions. ime / n" and "n" update the matching weight, which makes the representation degree of web page information by different keyword sets more concrete; for the same web page, the higher the matching weight corresponding to the keyword set, the more users are inclined to search for the web page using the keywords in it.
[0106] In the above formula, by introducing the adjustment factors x1, x2, y1 and y2, a buffer is provided for the influence of the average browsing time and total number of clicks on the web page on the matching weight, thereby avoiding large fluctuations in the matching weight due to changes in the average browsing time and total number of clicks, and enhancing the stability of the search method.
[0107] For the second case, for example, suppose the method described in the webpage "Method for Extracting Pigments from Carrots" is pectinase cell wall breaking, and a user finds the webpage based on the keyword "cell wall". Obviously, the keywords in all the keyword sets of the webpage currently do not match "cell wall"; at this time, it can be judged that the existing keyword set in the current webpage dataset cannot fully represent the content information of the webpage; at this time, a new keyword set is created, "cell wall" is added to this newly created keyword set, its quantity identifier is initialized to 1, and a matching weight Q is initialized for this newly created keyword set. inital, total click count 1 and total browsing time (i.e., the browsing time of the user on the web page in this round of update operation), and update the matching weight. The matching weight updating method is the same as that described in the first case and will not be repeated here.
[0108] That is, when sorting web pages, the present invention fully considers the user's historical operations on the web pages, matches the user's historical operations with the search information, and updates the web page data set information based on the search information, continuously improving the keywords and related matching weights, and assigning different quantity identifiers to different keywords, and assigning different matching weights to different keyword sets; the sorting results of web pages are no longer determined by the server or developer in a single dimension; but are constantly improved based on the user's operation behavior over time, and can automatically improve the missing keywords in the data set; the more search behaviors the user has, the more targeted the ranking given, which fully reflects the participation of user behavior in the search results.
[0109] 3. Get the user's current search information
[0110] The user searches for web pages based on the search information, which is consistent with the historical search information. The current search information may also be sentence information or keywords.
[0111] 4. Get the first ranking
[0112] The present invention obtains a first ranking based on the semantic similarity between the user's current search information and the webpage dataset information, specifically comprising the following steps:
[0113] 1. Extract keywords from current search information;
[0114] 2. Get the mean of the sum of the keyword vectors as the first word vector;
[0115] 3. Obtain one keyword from each of the keyword sets on the webpage. Specifically, obtain a keyword with the largest quantity identifier from each of the keyword sets on the webpage. If a keyword set contains multiple keywords with the largest quantity identifiers, select one keyword at random. The specific reason for this is detailed above. The keyword with the largest quantity identifier best represents the user's search habits.
[0116] 4. Obtain the second word vector using the following formula: ;
[0117] Among them, C is the second word vector, m is the total number of keywords extracted in step 3, is the word vector of the keyword extracted in step 3; For word vector The weight value is the matching weight corresponding to the keyword set to which the keyword belongs;
[0118] 5. Obtain the absolute value of the cosine value of the first word vector and the second word vector as the semantic similarity between the user's current search information and the web page dataset information;
[0119] 6. Adjust the ranking of web pages based on the order of semantic similarity from high to low to obtain the first ranking.
[0120] That is, when calculating semantic similarity, with respect to web pages, the present invention assigns the matching weight corresponding to the keyword set to which the keyword belongs to the weight value of the keyword word vector, performs weighted summation on the keyword word vectors and obtains the average value. In this way, when solving the second word vector of the web page, different keywords have different importance in the final second word vector. In this way, when solving the word vector of the web page, the degree of fit between different keywords and the web page is taken into account, so that the second word vector finally obtained can better represent the content information that the web page can provide.
[0121] 5. Get the second ranking
[0122] The present invention adjusts the first ranking based on the user model and the public model to obtain a second ranking.
[0123] The user model is constructed based on the data of the user's historical operation of the web page, and is expressed in the form of (α1, α2...α p ); where p is the total number of classification labels, α1, α2...α p They respectively represent the proportion of the total browsing time of users on web pages with category labels 1, 2, ..., p to the total browsing time of users browsing web pages of all categories.
[0124] The mass model is constructed based on the probability that each keyword belongs to each category. For each keyword, the probability of it belonging to each category can be estimated based on the Bayesian classification method (for example, the keyword "apple" may belong to the "digital" category or the "fruit" category). Therefore, the mass model of each keyword can be obtained, which is expressed as (β1, β2...β p ), where p is the total number of classification labels, β1, β2, ... β p They represent the probability that the corresponding keyword belongs to category 1, 2, ..., p respectively.
[0125] Based on the user model and the public model, the first ranking is adjusted to obtain the second ranking as follows.
[0126] 1. Extract all keywords from the user’s current search information.
[0127] 2. Build a mass model for each keyword:
[0128]
[0129] Where q is the number of keywords extracted from the user's current search information.
[0130] 3. Obtain the web page classification model through the following formula:
[0131] ;
[0132] In the above formula, i refers to a specific keyword; x is the adjustment factor;
[0133] The meaning of this formula is to integrate the probability of the user's inclination towards each category into a user vector (a probability set that represents the user's interest in each category). At the same time, the keywords in the user's search information are obtained, and the probability of each keyword belonging to each category is integrated into several public vectors. The values in the public vectors are summed and averaged (the final representation is the probability set of the user's input search information belonging to each category). After multiplying the two probability sets by the corresponding adjustment factors, the resulting web page classification model is also a probability set. The final probability set integrates both the probability information in the user's search information and the user's own inclination information towards content in different categories.
[0134] 4. From the web page classification model, obtain the value corresponding to the category to which the web page belongs.
[0135] Specifically, if the category to which the webpage belongs belongs to the last one, the last probability value is extracted from the webpage classification model P: .
[0136] 5. Integrate the value obtained in step 4 with the semantic similarity during the first sorting, and adjust the first sorting with the final integrated value to obtain the second order.
[0137] The specific integration strategy can be to linearly sum the semantic similarity and the probability values corresponding to the categories to which the webpages belong, or to assign different weights to the semantic similarity and the probability values corresponding to the categories to which the webpages belong, to perform a weighted summation, and then adjust the first order based on the weighted summation. This will not be elaborated here.
[0138] In summary, by introducing the consideration of classification, on the basis of keyword-based search, we further consider the information of the category to which the keyword belongs, the category to which the web page belongs, and the category preferred by the user, thus avoiding the situation where the same keyword may correspond to different fields, resulting in interference fields in the final detected web pages.
[0139] 6. Get the third ranking
[0140] The present invention adjusts the second ranking based on the semantic similarity between the user's historical search information and the current search information to obtain a third ranking.
[0141] In a preferred embodiment, the adjustment method is as follows:
[0142] 1. Obtain at least one historical search information of the user within a predetermined time period before the current search operation;
[0143] 2. For each historical search information, extract keywords from it and obtain the mean of the sum of the keyword word vectors as the third word vector;
[0144] 3. Extract keywords from the user's current search information and obtain the mean of the sum of the keyword vectors as the first word vector;
[0145] 4. Obtain the absolute value of the cosine value of the first word vector and the third word vector, and select the historical search information corresponding to the absolute value of the cosine value greater than the second predetermined value as the target historical search information;
[0146] 5. Obtaining a target webpage corresponding to the target historical search information, where the target webpage is a webpage that the user clicked on and browsed for a time greater than a predetermined time period when searching based on the target historical search information;
[0147] 6. Sort the target web pages in descending order according to the absolute value of the cosine value in step 4;
[0148] 7. Randomly insert the target web page into the second ranked web page set according to the first ratio;
[0149] 8. Integrate duplicate web pages to obtain the third ranked web pages.
[0150] For steps 7-8, the specific technical implementation is as follows: after steps 1-6, target web page 1, target web page 2, target web page 3, target web page 4, and target web page 5 are found (the absolute values of the cosine values corresponding to target web page 1, target web page 2, target web page 3, target web page 4, and target web page 5 are sequentially decreased), and in the second sorting, the first 20 web pages obtained are existing web page 1 to existing web page 20; assuming that the target web pages are inserted into the second sorted web page set at a ratio of 2:10, then target web page 1 and target web page 2 are randomly inserted into any position between existing web page 1 to existing web page 10 (but the insertion position of target web page 1 should be before target web page 2, that is, after insertion, the order of the target web pages remains unchanged); similarly, target web page 3 and target web page 4 are randomly inserted into any position between existing web page 11 to existing web page 20, and so on.
[0151] This situation mainly targets some users who need to continuously consult relevant information over a period of time. For example, some users will continuously consult a certain type of information while writing a paper or doing a project. The search strategy used each time for consultation, or the search statement typed during the search, may have certain deviations. If the user does not organize the information in a timely manner, it may result in the inability to find the web pages that have been found before and meet their needs. Therefore, the present invention uses this method to retrieve the web pages that meet the needs of the user encountered in the previous search process, and intersperse them in the search results this time, thereby greatly improving the pertinence of web page sorting and the convenience of user use.
[0152] It should be noted that the purpose of this step of the present invention is to find web pages that are more in line with user needs. At the same time, in actual operations, the reason why users adopt different search strategies to search for web pages is partly because the previous search strategies do not fully meet their needs. Therefore, in step 5, when obtaining the target web page based on the predetermined time, the predetermined time should be at least equal to the first predetermined time, and preferably, should be greater than the first predetermined time. In other words, the target web page found by the predetermined time must be ensured to be what the user needs.
[0153] 7. Get the fourth ranking
[0154] The present invention adjusts the third ranking based on the associated search information of the web page to obtain a fourth ranking.
[0155] In a preferred embodiment, the adjustment method is as follows:
[0156] 1. Obtaining related search information in which a predetermined number of web pages ranked first in the existing third ranking results are searched by other search information, clicked on, and browsed for a predetermined time period;
[0157] 2. For each associated search information, extract keywords from it and obtain the mean of the sum of the keyword word vectors as the fourth word vector;
[0158] 3. Extract keywords from the user's current search information and obtain the mean of the sum of the keyword vectors as the first word vector;
[0159] 4. Obtain the absolute value of the cosine value of the first word vector and the fourth word vector, and select the associated search information corresponding to the absolute value of the cosine value greater than the second predetermined value as the target search information;
[0160] 5. For each target search information, perform a web search based on it to obtain related web pages. Based on the semantic similarity between each target search information and the web page dataset information, adjust the order of the related web pages (the adjustment method is the same as the adjustment idea of the first order in the fourth part above);
[0161] 6. Randomly insert the associated web pages into the third-ranked web page set according to the second ratio (see Section 6 above for specific implementation methods);
[0162] 7. Integrate the duplicate web pages to obtain the fourth ranked web pages.
[0163] The significance of setting this step is that in actual work and life, different users have different search capabilities, and for users with poor search capabilities, they lack the ability to change search strategies to obtain more complete information. Therefore, the present invention provides the function of associated search; for web pages searched based on the user's current search information, find the web pages with higher rankings, and see which search strategies these web pages can be searched through. This is equivalent to helping users expand their search strategies and search results, weakening the search engine's demand for users' search capabilities, and providing more intelligent search services.
[0164] Figure 2 This is a system architecture diagram of the web search result ranking adjustment system based on machine learning of the present invention, which is used to implement the adjustment method described above, including a client and a server. The client and the server are connected via a wired or wireless network. The client is configured on various mobile terminals and is used to receive user search information. The server is used to adjust the ranking of web search results based on the user's search information.
[0165] The server stores a data set for each web page. The data set for each web page contains:
[0166] Category tags of web pages;
[0167] At least one keyword set and the total number of clicks, total browsing time, and matching weight of each keyword set with the web page;
[0168] The quantity identifier of each keyword in the set of all keywords;
[0169] The server updates the total number of clicks, total browsing time, matching weight with web pages, and quantity identifiers of each keyword in each keyword set based on the historical operation information;
[0170] When the server adjusts the ranking of web page search results, it obtains the semantic similarity between the user's current search information and the web page dataset information, and adjusts the web page ranking based on the semantic similarity to obtain a first ranking;
[0171] Adjust the first ranking based on the user model and the public model to obtain a second ranking;
[0172] Based on the semantic similarity between the user's historical search information and the current search information, the second ranking is adjusted to obtain a third ranking.
[0173] Although the present invention has been described using the above preferred embodiments, they are not intended to limit the scope of protection of the present invention. Any person skilled in the art may make various changes and modifications to the above embodiments without departing from the spirit and scope of the present invention. These changes and modifications are still within the scope of protection of the present invention. Therefore, the scope of protection of the present invention shall be based on the definition of the claims.
Claims
1. A method for adjusting the ranking of web page search results based on machine learning, characterized in that: The steps include: S1: Constructs a dataset corresponding to the web page. The dataset stores: Category tags of web pages; At least one keyword set and the total number of clicks, total browsing time, and matching weight of each keyword set with the web page; The quantity identifier of each keyword in the set of all keywords; S2: Based on the historical operation information, the total number of clicks, total browsing time, matching weight with the web page, and the number of keywords in each keyword set are updated; S3: Get the user's current search information; S4: Based on S41-S44, the first ranking is obtained: S41: extract keywords from the user's current search information, and obtain the mean of the sum of the keyword word vectors as the first word vector; S42: Obtain one keyword from each keyword set of the web page; S43: Obtain the second word vector using the following formula: ; Among them, C is the second word vector, m is the total number of keywords extracted in S42, is the word vector of the keyword extracted in S42; For word vector The weight value is the matching weight corresponding to the keyword set to which the keyword belongs; S44: Obtaining the absolute value of the cosine value of the first word vector and the second word vector, and adjusting the webpage ranking based on the absolute value of the cosine value to obtain a first ranking; S5: adjusting the first ranking based on the user model and the public model to obtain a second ranking; S6: Obtain at least one historical search information of the user within a predetermined time period before the current search operation and a third word vector corresponding to the historical search information; adjust the second ranking based on the absolute value of the cosine value of the first word vector and the third word vector to obtain a third ranking; S7: Obtain associated search information and a fourth word vector corresponding to the associated search information based on the third ranking, and adjust the third ranking based on the absolute value of the cosine value of the first word vector and the fourth word vector to obtain a fourth ranking.
2. The method for adjusting the ranking of web page search results based on machine learning according to claim 1, wherein: In S1, when constructing the data set, at least one keyword set is initialized based on the content information of the web page, and a number of keywords, a total number of clicks, a total browsing time, and a matching weight are initialized for each keyword set. The initial total number of clicks, the initial total browsing time, and the initial matching weight of each keyword set are 0, 0, and the same; The matching degree between all the keywords in each keyword set is greater than a first predetermined value; A quantity identifier is initialized for each keyword in the keyword set, and the initial value of the quantity identifier is 0.
3. The method for adjusting the ranking of web page search results based on machine learning according to claim 2, wherein: Updating the matching weight, total click count, total browsing time of each keyword set, and the quantity identifier of each keyword in each keyword set based on historical operation information includes the following steps: S21: Acquire search information corresponding to a search operation in which a click operation is performed on a webpage and the stay time on the webpage exceeds a first predetermined time period; S22: extract all keywords from the search information as keywords to be matched; Perform the following operations for each keyword to be matched: S23: traverse all keyword sets of the web page, and for each keyword set, obtain a keyword as an existing keyword; S24: Obtain the matching degree between the keyword to be matched and the existing keyword, and determine whether there is an existing keyword that reaches a first predetermined value: If so, determine whether there is a keyword that is consistent with the keyword to be matched in the keyword set where the existing keyword that has reached the first predetermined value is located: if there is a consistency, update the quantity identifier of the keyword that is consistent with the keyword to be matched, and increase its value by 1; if there is no consistency, add the keyword to be matched to the keyword set where the existing keyword that has reached the first predetermined value is located, and initialize its quantity identifier to 1; at the same time, update the total number of clicks, total browsing time and matching weight of the keyword set where the existing keyword is located; If it does not exist, create a new keyword set and add the keywords to be matched to the new keyword set, initialize its quantity identifier to 1, and initialize a matching weight, total number of clicks, and total browsing time for the new keyword set, and update the matching weight.
4. The method for adjusting the ranking of web page search results based on machine learning according to claim 3, wherein: Update the matching weight of the keyword set where the existing keywords are located by following the steps below: Q=Q inital +(x1+T ime / n) / x2+(y1+n) / y2; Among them, Q is the matching weight, Q inital is the initial matching weight, x1, x2, y1 and y2 are adjustment factors, T ime is the total browsing time, n is the total number of clicks; When there is an existing keyword that reaches the first predetermined value, the total number of clicks of the keyword set to which the existing keyword belongs is increased by 1, and the total browsing time is added to the dwell time obtained in S21.
5. The method for adjusting the ranking of web page search results based on machine learning according to claim 3, wherein: When traversing all keyword sets of a web page, for each keyword set, the keyword with the largest quantity identifier is obtained as the existing keyword; If there are multiple keywords with the maximum number of identifiers in a keyword set, one is randomly selected as the existing keyword.
6. The method for adjusting the ranking of web page search results based on machine learning according to claim 3, wherein: The matching degree between the keyword to be matched and the existing keyword is obtained in the following way: the keyword to be matched and the existing keyword are sequence-converted based on the BOW model to obtain the first vector and the second vector respectively, and the inner product of the first vector and the second vector is calculated. The inner product value is the matching degree.
7. The method for adjusting the ranking of web page search results based on machine learning according to claim 1, wherein: In S42, a keyword with the largest number identifier is obtained from all keyword sets on the web page. If a keyword set contains multiple keywords with the largest number identifiers, one is randomly selected.
8. An adjustment system based on the webpage search result ranking adjustment method based on machine learning according to any one of claims 1 to 7, characterized in that: include: Client, used to receive user search information; A server, connected to the client, is used to adjust the ranking of web page search results based on the user's search information; The server stores a data set for each web page. The data set for each web page contains: Category tags of web pages; At least one keyword set and the total number of clicks, total browsing time, and matching weight of each keyword set with the web page; The quantity identifier of each keyword in the set of all keywords; The server updates the total number of clicks, total browsing time, matching weight with web pages, and quantity identifiers of each keyword in each keyword set based on the historical operation information; When the server adjusts the ranking of web page search results, it obtains the semantic similarity between the user's current search information and the web page dataset information, and adjusts the web page ranking based on the semantic similarity to obtain a first ranking.
9. The adjustment system of the webpage search result ranking adjustment method based on machine learning according to claim 8, characterized in that: When the server adjusts the ranking of web page search results, it also includes: Adjust the first ranking based on the user model and the public model to obtain a second ranking; Based on the semantic similarity between the user's historical search information and the current search information, the second ranking is adjusted to obtain a third ranking.
Citation Information
Patent Citations
Personalized searching method and system
CN102737027A
User behavior-based search method and system
CN104035927A
Information pushing method and device, computer equipment and storage medium
CN114222000A