Data processing method, device, equipment and medium

By constructing a vector index library and utilizing candidate query information in object logs, the problem of inefficient and time-consuming retrieval results caused by abbreviation, non-standard or misspelling queries in the existing technology is solved, and more efficient data retrieval and matching effects are achieved. .

CN114691828BActive Publication Date: 2024-09-20TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210287730.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-23
Publication Date
2024-09-20
Estimated Expiration
2042-03-23

AI Technical Summary

Technical Problem

When existing search engines process abbreviated, non-standard or misspelled query text, the retrieval results are ineffective and time-consuming. All data need to be processed, resulting in a decrease in retrieval efficiency.

Method used

By constructing a vector index library and using candidate query information in the object log, the associated query information of the first query information is obtained, and vector retrieval is performed to improve the effectiveness of the retrieval results and reduce retrieval time.

Benefits of technology

It improves the effectiveness and efficiency of retrieval results, reduces the computational overhead in the data retrieval process, and enhances the matching and response speed to user queries.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114691828B
    Figure CN114691828B
Patent Text Reader

Abstract

The embodiment of the present application provides a data processing method, device, equipment and medium, the method comprising: obtaining first query information, obtaining a vector index library; the vector index library is determined by candidate query information that meets the search screening condition in the object log; obtaining associated query information corresponding to the first query information from the vector index library, determining the first query information and the associated query information as second query information; obtaining a retrieval result corresponding to the second query information, and determining the retrieval result of the second query information as a target retrieval result for responding to the first query information. By adopting the embodiment of the present application, the retrieval time in the data retrieval process can be reduced, and the validity of the retrieval results can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of Internet technology, and in particular to a data processing method, device, equipment and medium. Background Art

[0002] With the development of data informatization, the amount of data is growing rapidly, and big data is showing a trend of diversification and decentralization. In the environment of large-scale data, it is often necessary to search for information of interest from a large amount of data, such as searching for related service needs according to one's own needs.

[0003] In current search scenarios, you can enter a query text in a search engine, and in the search engine, you can search based on the entered query text, find data that matches the query text, and return the data as a search result to the search page for display. However, when the query text contains abbreviations, irregularities, spelling errors, etc., the returned search results are not what the user wants, resulting in low effectiveness of the search results; and in the search process of the query text, the query text and all the data in the search engine need to be processed in order to search in all the data in the search engine. When the amount of data in the search engine is large, the time consumption of the entire search process will increase. Summary of the invention

[0004] The embodiments of the present application provide a data processing method, apparatus, device and medium, which can reduce the retrieval time in the data retrieval process and improve the effectiveness of the retrieval results.

[0005] On the one hand, an embodiment of the present application provides a data processing method, including:

[0006] Obtaining first query information and obtaining a vector index library; the vector index library is determined by candidate query information satisfying a search screening condition in the object log;

[0007] Acquire associated query information corresponding to the first query information from the vector index library, and determine the first query information and the associated query information as second query information;

[0008] A search result corresponding to the second query information is obtained, and the search result of the second query information is determined as a target search result for responding to the first query information.

[0009] An embodiment of the present application provides a data processing device, including:

[0010] A first acquisition module is used to acquire first query information and acquire a vector index library; the vector index library is determined by candidate query information that meets the search screening condition in the object log;

[0011] A second acquisition module is used to acquire associated query information corresponding to the first query information from the vector index library, and determine the first query information and the associated query information as second query information;

[0012] The retrieval module is used to obtain the retrieval result corresponding to the second query information, and determine the retrieval result of the second query information as the target retrieval result for responding to the first query information.

[0013] The number of associated query information is K, where K is a positive integer;

[0014] The second acquisition module includes:

[0015] A database segmentation unit is used to obtain a first query vector corresponding to the first query information, and segment the vector data set associated with the vector index library to obtain N vector subsets; the vector data set includes a candidate query vector corresponding to the candidate query information in the object log, and N is a positive integer;

[0016] An associated vector acquisition unit, configured to acquire a target vector subset to which the first query vector belongs from the N vector subsets, and acquire K associated query vectors associated with the first query vector from the target vector subset;

[0017] The information combining unit is used to determine the candidate query information corresponding to the K associated query vectors as the associated query information, and combine the first query information with the K associated query information into the second query information.

[0018] The database segmentation unit includes:

[0019] a character conversion subunit, configured to divide the first query information into M unit characters, input the M unit characters into a target language model in sequence, and encode the M unit characters into unit character vectors respectively through the target language model; M is a positive integer;

[0020] A pooling operation subunit, used to perform a pooling operation on the M unit character vectors to obtain an initial query vector corresponding to the first query information;

[0021] The dimensionality reduction processing subunit is used to perform dimensionality reduction processing on the initial query vector according to the fully connected layer in the target language model to obtain a first query vector.

[0022] The database segmentation unit includes:

[0023] The similarity acquisition subunit is used to determine the central vector t from the vector data set associated with the vector index library. i , get each candidate query vector and the center vector t in the vector data set i The vector similarity between them; i is a positive integer less than or equal to N;

[0024] The clustering processing subunit is used to identify the j-th candidate query vector in the vector data set and the center vector t i The vector similarity of is the largest, then the j-th candidate query vector is added to the center vector t i The pending cluster C i ; j is a positive integer less than or equal to the number of candidate query information contained in the vector data set;

[0025] The cluster center update subunit is used to update the cluster center according to the i The candidate query vector contained in , updates the center vector t i , until the cluster to be processed C i The updated center vector t i and the center vector t before update i If the same, the cluster C to be processed i Determined as a subset of vectors.

[0026] Wherein, the association vector acquisition unit includes:

[0027] A subset determination subunit, used to obtain vector distances between the first query vector and the N vector subsets respectively, and determine the vector subset corresponding to the shortest vector distance as the target vector subset to which the first query vector belongs;

[0028] a candidate vector sorting subunit, configured to obtain vector associations between the first query vector and candidate query vectors in the target vector subset, and sort the candidate query vectors in the target vector subset according to the vector associations to obtain a sorted target vector subset;

[0029] The associated vector selection subunit is used to obtain K associated query vectors corresponding to the first query vector in the sorted target vector subset according to the arrangement order.

[0030] The search module includes:

[0031] An interface calling unit, used to call an application program interface in the search engine to obtain a set of data to be recommended contained in the search engine;

[0032] The data recall unit is used to recall the search results corresponding to the second query information from the to-be-recommended data set according to the data similarity between the second query information and the to-be-recommended data in the to-be-recommended data set.

[0033] The device further comprises:

[0034] A search result display module, used to display the target search result corresponding to the first query information on the query page;

[0035] The retrieval result trigger module is used to respond to the trigger operation on the target retrieval result and display the detailed description information corresponding to the target retrieval result.

[0036] The device further comprises:

[0037] A historical query information acquisition module is used to acquire a historical information set in an object log and to count the search frequencies corresponding to each historical query information in the historical information set;

[0038] A candidate query information determination module is used to determine that the historical query information s meets the search screening condition if the object log contains object operation information corresponding to the historical query information s in the historical information set, and the search frequency corresponding to the historical query information s is greater than the frequency threshold, and add the historical query information s as candidate query information to the candidate information set; s is a positive integer;

[0039] A candidate query information encoding module is used to encode each candidate query information in the candidate information set through a target language model to obtain a candidate query vector corresponding to each candidate query information;

[0040] The index library construction module is used to construct index information for the candidate query vector corresponding to each candidate query information, and generate a vector index library corresponding to the candidate information set based on the index information.

[0041] The device further comprises:

[0042] A sample data group acquisition module is used to acquire a sample data group; the sample data group includes first sample data, second sample data and a sample label, and the sample label is used to characterize the association relationship between the first sample data and the second sample data;

[0043] A sample vector acquisition module, used to input the sample data group into the initial language model, and acquire a first sample vector corresponding to the first sample data and a second sample vector corresponding to the second sample data through the initial language model;

[0044] The model training module is used to obtain the sample distance between the first sample vector and the second sample vector, correct the network parameters of the initial language model according to the contrast loss between the sample distance and the sample label, and determine the initial language model including the corrected network parameters as the target language model.

[0045] Wherein, the sample data group includes a positive sample group;

[0046] The sample data group acquisition module includes:

[0047] A first sample acquisition unit is used to acquire first sample data and second sample data within a target time range from a historical information set of an object log; the first sample data refers to historical query information without object operation information, and the second sample data refers to historical query information with object operation information;

[0048] A sample label adding unit, used to obtain a transition probability of switching from the first sample data to the second sample data, and when the transition probability is greater than a probability threshold, determine that the sample label between the first sample data and the second sample data is a first label; the first label is used to indicate that the first sample data and the second sample data have an associated relationship;

[0049] The positive sample group determination unit is used to determine the first sample data, the second sample data and the first label as a positive sample group.

[0050] Wherein, the sample data group includes a negative sample group;

[0051] The sample data group acquisition module includes:

[0052] A second sample acquisition unit is used to acquire first sample data without object operation information from the historical information set of the object log, and acquire second sample data through a random number strategy;

[0053] The negative sample group determination unit is used to determine that the sample label between the first sample data and the second sample data is a second label, and the first sample data, the second sample data and the second label are determined as a negative sample group; the second label is used to indicate that the first sample data and the second sample data have no association relationship.

[0054] On one hand, an embodiment of the present application provides a computer device, including a memory and a processor, wherein the memory is connected to the processor, the memory is used to store a computer program, and the processor is used to call the computer program so that the computer device executes the method provided in the above aspect of the embodiment of the present application.

[0055] On one hand, an embodiment of the present application provides a computer-readable storage medium, in which a computer program is stored. The computer program is suitable for being loaded and executed by a processor, so that a computer device with a processor executes the method provided in the above aspect of the embodiment of the present application.

[0056] According to one aspect of the present application, a computer program product or computer program is provided, the computer program product or computer program includes computer instructions, the computer instructions are stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the method provided in the above aspect.

[0057] The embodiment of the present application can obtain the first query information and the vector index library, and the vector index library can be determined by the candidate query information that meets the search screening conditions in the object log; and then the associated query information corresponding to the first query information can be obtained from the vector index database, and the first query information and the associated query information are determined as the second query information, and the retrieval result of the second query information can be used as the target retrieval result corresponding to the first query information. It can be seen that the vector index library can be pre-constructed by mining the candidate query information that meets the search screening conditions in the object log. In the retrieval process of the first query information, the associated query information corresponding to the first query text can be directly determined from the vector index library by vector retrieval, and then data retrieval can be performed based on the first query information and the associated query information, and the retrieval results of the first query information and the associated query information are used as the target retrieval results of the first query information; since the associated query information is introduced in the retrieval process, the effectiveness of the retrieval results can be improved, and the retrieval based on the pre-constructed vector index library can reduce the computational overhead in the retrieval process, thereby reducing the time consumption of data retrieval. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0059] Figure 1 It is a structural diagram of a network architecture provided by an embodiment of the present application;

[0060] Figure 2 This is a schematic diagram of a data retrieval scenario provided by an embodiment of the present application;

[0061] Figure 3 It is a flowchart of a data processing method provided in an embodiment of the present application;

[0062] Figure 4 is a schematic diagram of vector conversion of first query information provided by an embodiment of the present application;

[0063] Figure 5 It is a flowchart of another data processing method provided in an embodiment of the present application;

[0064] Figure 6 is a schematic diagram of a sample data group provided in an embodiment of the present application;

[0065] Figure 7 is a training diagram of an initial language model provided in an embodiment of the present application;

[0066] Figure 8 This is a schematic diagram of a data processing process framework provided by an embodiment of the present application;

[0067] Fig. 9 is a structural schematic diagram of a data processing device provided in an embodiment of the present application;

[0068] Fig.10 It is a structural diagram of a computer device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0069] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0070] To facilitate the subsequent description, the embodiments of the present application first briefly introduce the relevant terms involved in the embodiments of the present application.

[0071] Query rewriting: Based on the search query information (e.g., query text), a series of related associated query information is generated and retrieved together with the original query information to obtain richer and more accurate results.

[0072] Text vector: A text vector can refer to a fixed-length numeric vector converted from a variable-length text in some way. A text vector can be a high-dimensional sparse vector or a low-dimensional dense vector. A high-dimensional sparse vector usually uses the length of the vocabulary as the length of the vector, and each dimension represents a character. Only the dimension corresponding to the text character is non-zero, and most dimensions are zero; a low-dimensional dense vector can refer to the vector representation output by a model such as a neural network, and each dimension of the vector is basically a non-zero value.

[0073] Semantic matching: Semantic matching can refer to the semantic correlation between two pieces of text. If the correlation is greater than a preset threshold (such as an association threshold, which can be customized according to actual needs and is not limited in this application), it can be determined that the two pieces of text match.

[0074] Bigram data: In the text matching scenario, a bigram data includes two texts and a label (the label can be represented by different numerical values). For example, suppose two texts are recorded as A and B respectively. If the two texts match, the bigram data can be represented as (A, B, 1); if the two texts do not match, the bigram data can be represented as (A, B, 0).

[0075] Twin network: Twin network refers to an artificial neural network used to determine whether two comparable objects (e.g., text, image, audio, etc.) are related. The artificial neural network usually has two sub-network structures of the same type, and the two sub-network structures share weights. Each sub-network structure receives an object as input and converts it into a feature vector, which is input into a unified structure to determine the similarity between the two objects.

[0076] Vertical search: Vertical search (abbreviated as vertical search) refers to a professional search engine for a certain industry. It can be considered a subdivision and extension of ordinary search engines. It is used to integrate a certain type of special information in the database, extract the required data by field, process it, and return it to the user in some form. For example, public account search, mini program search, etc.

[0077] Service search: Service search can be considered as a vertical search business, including services provided by merchant clients in various industries, which can meet users' various service needs, such as transportation, life, education, finance, etc.

[0078] Under-recall problem: Under-recall problem may refer to the situation where after a user inputs a query text and initiates a search, the search system does not return any retrieval results associated with the query text.

[0079] See also Figure 1 , Figure 1 Schematic diagram of a network architecture provided by an embodiment of the present application. Figure 1 As shown, the network architecture may include a server 10d and a user terminal cluster, and the user terminal cluster may include one or more user terminals, and the number of user terminals is not limited here. Figure 1 As shown, the user terminal cluster may specifically include user terminal 10a, user terminal 10b and user terminal 10c, etc. Among them, server 10d may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, as well as big data and artificial intelligence platforms. User terminal 10a, user terminal 10b and user terminal 10c, etc. may include: smart phones, tablet computers, laptop computers, PDAs, mobile Internet devices (mobile internet devices, MIDs), wearable devices (such as smart watches, smart bracelets, etc.), smart voice interaction devices, smart home appliances (such as smart TVs, etc.) and vehicle-mounted devices, etc., electronic devices with data search functions. As Figure 1As shown, the user terminal 10a, the user terminal 10b and the user terminal 10c can respectively establish a network connection with the server 10d, so that each user terminal can exchange data with the server 10d through the network connection.

[0080] Taking user terminal 10a as an example, when a user needs to query information, the user can enter query information in the search input box of user terminal 10a (for the convenience of description, the query information here can be referred to as first query information), and the user terminal 10a can obtain the first query information entered by the user and send the first query information to server 10d; after receiving the first query information sent by user terminal 10a, server 10d can encode the first query information to obtain a first query vector corresponding to the first query information, and then obtain the associated query vector corresponding to the first query vector through a pre-constructed vector index library, such as the K query vectors with the highest vector association between the first query vector in the vector index library, K is a positive integer, such as K can be 1, 2, ...; the query information corresponding to the associated query vector can be referred to as associated query information, the first query information and the associated query information are retrieved together to obtain a target retrieval result for responding to the first query information, and server 10d can return the target retrieval result to user terminal 10a, and display the target retrieval result for the user in user terminal 10a. Among them, the vector index library can be generated based on the information vector corresponding to the historical query information in the user search log (also called the object log), and the vector index library can be constructed offline; the vector association degree can refer to the similarity between the query vectors corresponding to the two query information, such as the similarity between the first query vector and the historical query vector corresponding to the historical query information. The retrieval process of the server 10d for the first query information is an online retrieval process. In the online retrieval of the first query information, the online retrieval in the form of vectors through the vector index library can reduce the computational overhead and thus reduce the time consumption of the online retrieval; by retrieving the first query information and the associated query information together, the validity of the retrieval results can be improved.

[0081] It should be noted that the above-mentioned retrieval process of the first query information can be performed by a computer device, and the computer device can be Figure 1 The user terminals in the user terminal cluster shown, or Figure 1 The server 10d is shown; in short, the computer device can be a user terminal, or a server, or a combined device consisting of a server and a user terminal, or a computer program application (including program code), which is not limited in this application.

[0082] See also Figure 2 , Figure 2Schematic diagram of a data retrieval scenario provided by an embodiment of the present application. The following describes the data retrieval process by taking the service search scenario as an example. Figure 2 As shown, when a user needs to perform a service search service, the user terminal 20a (for example, Figure 1 In the corresponding embodiment, an application client is started in the user terminal 10a), which may be a communication application, such as an instant messaging application; the application client may provide different types of pages for the user, including pages corresponding to controls 1, 2, 3 and 4, such as messages, address books, discoveries and personal centers.

[0083] When the user performs a trigger operation on the control 3 in the application client, the user terminal 20a can respond to the trigger operation on the control 3 and display the main page 20b corresponding to the control 3 in the application client. The main page 20b may include multiple function entrances, such as function entrance A, function entrance B, ..., function entrance G, search entrance 20c, etc. Among them, the search entrance 20c can be used to provide a service search function in the application client; the function entrance A can be a friend circle entrance, which can be used to provide an information content publishing function in the application client; the function entrance G can be a mini program entrance, which can be used to provide a mini program management function in the application client, etc. When the user performs a trigger operation on the search entry 20c in the main page 20b, the user terminal 20a can respond to the trigger operation on the search entry 20c and display the query page 20d corresponding to the search entry 20c. In the area 20f of the query page 20d, today's hot news, such as hot spot 1, hot spot 2, and hot spot 3, can be displayed. By triggering the hot news in the area 20f, the details of the triggered hot news can be viewed on the query page 20d. Among them, the query page 20d can also include a search input box 20e, and the user can enter the query information in the search input box 20e to obtain the search results. Through the search input box 20e, the content such as the circle of friends, articles, public accounts, and mini programs in the application client can be searched.

[0084] like Figure 2As shown, when the user enters "rental extraction" in the search input box 20e and triggers the search operation, the user terminal 20a can obtain the text content "rental extraction" entered by the user, and refer to the text content "rental extraction" as the first query information 20g; since the first query information 20g is a text content described in natural language, it is necessary to convert the first query information 20g into a text vector 20h (also referred to as a first query vector) that can be understood by a computer, that is, a numerical representation of the first query information 20g, and the first query information 20g can be converted into a vector representation of a fixed length. For example, the user terminal 20a can perform word segmentation processing on the first query information 20g to obtain a unit character set corresponding to the first query information 20g, and the unit character set can include unit characters such as "rent", "house", "withdrawal", and "take". The word segmentation processing method here can be a word segmentation algorithm based on a dictionary, or a word segmentation algorithm based on statistics, etc., and this application does not limit this. Furthermore, each unit character in the unit character set can be converted into a unit word vector. For example, the unit characters "rent", "room", "withdraw", and "take" can be converted into unit word vectors of fixed length. By pooling the unit word vectors corresponding to the unit characters "rent", "room", "withdraw", and "take", the text vector 20h corresponding to the first query information 20g is obtained.

[0085] The user terminal 20a can obtain the vector index library 20i in the retrieval system corresponding to the search entry 20c. The vector index library 20i is generated offline by the query vector corresponding to the historical query information in the user search log. The construction process of the vector index library 20i can be found in the following Figure 5In the description of the corresponding embodiment, the user search log may include query information searched by each user, and whether the search results returned by each query information have object operation information (for example, whether the user has clicked on the search results). Through the vector index library 20i, K (K is a positive integer) associated query vectors corresponding to the text vector 20h can be retrieved. The K associated query vectors can correspond to K associated query information. The karaoke associated query information here may include "provident fund withdrawal", and then the search system can be searched together based on the first query information 20g ("housing withdrawal") and the associated query information ("provident fund withdrawal") to obtain the search results corresponding to "housing withdrawal" and "provident fund withdrawal". The search results here can be used as the target search results corresponding to the first query information 20g and displayed in the query page 20d. Among them, the target search results may include public accounts 20j and mini programs 20k, and users can select corresponding results for viewing according to their own needs; for all target search results recalled by the retrieval system, they can all be displayed in the query page 20d in the form of a list, or the target search results can be displayed by category, such as only displaying the public accounts in the target search results, or only displaying the mini programs in the target search results, etc.

[0086] In an embodiment of the present application, if a search is performed based on the first query information 20g ("housing withdrawal") in the retrieval system corresponding to the search entrance 20c, the results desired by the user ("Provident Fund Withdrawal" public account, "Provident Fund Withdrawal" applet) may not be retrieved. However, the associated query information ("Provident Fund Withdrawal") corresponding to the first query information 20g is retrieved through the vector index library 20i, and a search is performed based on "housing withdrawal" and "Provident Fund Withdrawal" together. This can retrieve the results desired by the user, thereby improving the effectiveness of the search results. By pre-constructing the vector index library 20i and performing data retrieval in the form of vector retrieval, the computational overhead in the retrieval process can be reduced, thereby reducing the time required for retrieval.

[0087] See also Figure 3 , Figure 3 is a flow chart of a data processing method provided in an embodiment of the present application. Figure 3 As shown, the data processing method may include the following steps S101 to S103:

[0088] Step S101, obtaining first query information and obtaining a vector index library; the vector index library is determined by candidate query information satisfying a search screening condition in an object log.

[0089] Specifically, when a user searches a search engine (e.g. Figure 2 The corresponding embodiment of the search entry 20c) inputs data content (for example, Figure 2When searching for the text content "rental extraction" in the corresponding embodiment, the computer device can obtain the data content input by the user and determine the data content input by the user as the first query information. The first query information may include but is not limited to: text data, image data, audio data, and this application does not limit the data type of the first query information. For the convenience of description, the embodiments of this application are described by taking the first query data as text data as an example.

[0090] The computer device can obtain a pre-built vector index library in the search engine (for example, Figure 2 The vector index library 20i in the corresponding embodiment can be determined by the candidate query information that meets the search screening conditions in the object log. The vector index library can be constructed offline by mining the candidate query information in the object log. The vector index library includes the index information of the candidate query vector corresponding to the candidate query information. In the vector index library, online search can be performed in a vector manner to save the time of converting the candidate query information into the candidate query vector, thereby reducing the computational overhead of data retrieval. The vector index library can include but is not limited to Faiss (an index library) and nmslib (an index library). The present application does not limit the type of the vector index library. The object log can also be called a user search log, which is used to record the historical query information entered by the user in the search engine during the search, as well as the user's operation information on the retrieval results of the historical query information. The search screening conditions may include: the historical query information in the object log has object operation information (for example, the retrieval results recalled by the historical query information have been clicked and viewed by the user), and the search frequency of the historical query information recorded in the object log is greater than the frequency threshold (the frequency threshold can be set according to actual needs, and the present application does not limit this). In other words, the candidate query information may refer to historical query information in the object log that has object operation information and has a search frequency greater than a frequency threshold.

[0091] Step S102: acquiring associated query information corresponding to the first query information from the vector index library, and determining the first query information and the associated query information as second query information.

[0092] Specifically, the computer device can obtain the first query vector corresponding to the first query information, search based on the first query vector in the vector index library, determine the candidate query vector associated with the first query vector as the associated query vector, and the candidate query information corresponding to the associated query vector can be called the associated query information, and then the first query information and the second query information can be combined into the second query information. Among them, the associated query information can refer to the rewritten query information generated based on the first query information, and the number of associated query information can be one or more, such as the number of associated query information can be recorded as K, K can be a positive integer; the associated query vector can refer to the K candidate query vectors with the highest vector association between the first query vector in the vector index library. The above-mentioned vector association degree can be considered as the similarity between different vectors, and the calculation method of the vector association degree can include but is not limited to: Euclidian distance, Manhattan distance, Minkowski distance, cosine similarity, Pearson correlation coefficient, and the present application does not limit the calculation method of the vector association degree.

[0093] Optionally, when the first query information is text data, the computer device can divide the first query information into M unit characters (which can be recorded as tokens, such as single characters in Chinese, or words in English), and input the M unit characters into the target language model in sequence, and encode the M unit characters into unit character vectors through the target language model, where M is a positive integer and M is used to represent the number of unit characters contained in the first query information; then, the M unit character vectors can be pooled to obtain an initial query vector corresponding to the first query information; and the initial query vector is subjected to dimensionality reduction processing according to the fully connected layer in the target language model to obtain a first query vector. Among them, the target language model can be used to convert the first query information into a first query vector, and the target language model can include but is not limited to: Bert (Bidirectional Encoder Representations from Transformers) model, XLNet model (language model similar to Bert), ELECTRA (Efficiently Learning an Encoder that Classifies Token Replacements Accurately) model, and this application does not limit the type of the target language model.

[0094] Among them, the following takes the Bert model as an example to describe the vector conversion process of the first query information. The Bert model can convert text of indefinite length (such as the first query information) into a low-dimensional dense numerical vector representation. The Bert model can be trained using masked learning, such as randomly masking some unit characters in the text data, and using the remaining unit characters to predict these masked unit characters. The vector representation of the unit characters can be learned through masked learning; the Bert model can also be trained using next sentence prediction, such as taking a sentence in the text data as input to predict the next sentence, and learning the vector representation of the sentence through next sentence prediction; this application does not limit the training method of the Bert model. Among them, the Bert model may include one or more pooling layers and one or more fully connected layers (Fully-Connected Layer, FC layer), and this application does not limit the number of pooling layers and fully connected layers. A fully connected layer can be composed of multiple artificial neurons, and each artificial neuron in the current fully connected layer can be connected to all neurons in the previous fully connected layer, and non-neighboring fully connected layers are not connected. Pooling layers can be used to reduce the number of model parameters and reduce overfitting. Commonly used pooling layers can be divided into average pooling layers and maximum pooling layers. Both pooling layers can convert the feature vector extracted by the previous network layer into a lower-dimensional feature vector. The average pooling layer calculates the average value within a set dimensional range, while the maximum pooling layer calculates the maximum value.

[0095] The computer device can use the Bert model (target language model) to encode each of the M unit characters into a unit character vector (also called a unit word vector), that is, the first query information can be encoded into M unit character vectors, where the dimensions of the M unit character vectors are the same (for example, each unit character vector can be 768-dimensional); then, the M unit character vectors can be pooled through the pooling layer in the Bert model to obtain an initial query vector corresponding to the first query information, and the dimension of the initial query vector is the same as the dimension of the above-mentioned unit character vector. The larger the dimension of the initial query vector, the longer it takes to perform online vector retrieval in the search engine. Therefore, the initial query vector can be reduced in dimension through the fully connected layer in the Bert model to obtain a first query vector, that is, the dimension of the first query vector is smaller than the dimension of the initial query vector, such as the 768-dimensional initial query vector can be reduced in dimension to a 200-dimensional first query vector.

[0096] See also Figure 4 , Figure 4 Schematic diagram of vector conversion of first query information provided by an embodiment of the present application. Figure 4As shown, for the first query information, it can be divided into unit character 1, unit character 2, auxiliary character 3, ..., unit character M. The Bert model can be used to encode each unit character as a unit character vector, such as unit character 1 can be encoded as a unit character vector 30a, unit character 2 can be encoded as a unit character vector 30b, unit character 3 can be encoded as a unit character vector 30c, ..., unit character M can be encoded as a unit character vector 30d; then, unit character vector 30a, unit character vector 30b, unit character vector 30c and unit character vector 30d can be input into the pooling layer in the Bert model, and an initial query vector 30e can be obtained by performing a pooling operation on the above unit character vectors; through the fully connected layer in the Bert model, the initial query vector 30e can be reduced in dimension to obtain a first query vector 30f corresponding to the first query information.

[0097] It should be noted that the candidate query vector and the first query vector involved in the embodiment of the present application are encoded using the same target language model. The candidate query vector can be used to construct a vector index library. Therefore, the candidate query vector is obtained through offline encoding, and the first query vector is obtained through online encoding. The vector conversion process of the candidate query information will not be described in detail later.

[0098] Step S103: Acquire the search result corresponding to the second query information, and determine the search result of the second query information as the target search result for responding to the first query information.

[0099] Specifically, the computer device can call the application program interface in the search engine to obtain the data set to be recommended contained in the search engine, and then calculate the data similarity between each data to be recommended in the data set to be recommended and the second query information; since the second query information contains the first query information and the associated query information, the data similarity between each data to be recommended in the data set to be recommended and the first query information, and the data similarity between each data to be recommended and the associated query information can be calculated, and then based on the data similarity, the retrieval results corresponding to the second query information can be recalled from the data set to be recommended, and the target retrieval results corresponding to the first query information can be displayed on the query page.

[0100] Optionally, when the user is interested in the target search result, a trigger operation can be performed on the target search result. At this time, the computer device can respond to the trigger operation on the target search result and display the detailed description information corresponding to the target search result. Among them, the target search result corresponding to the first query information may include one or more data to be recommended, and then can be displayed in the query page in order from large to small according to the data similarity; or one or more target search results can be classified and displayed based on the data type corresponding to one or more target search results. The data type may include but is not limited to: articles, videos, audios, public accounts, and mini programs. For example, if the target search result includes search results of data types such as public accounts, mini programs, and articles, when the user performs a trigger operation on the public account type, the computer device can respond to the trigger operation on the public account type and display the search results belonging to the public account type in one or more target search results on the query page.

[0101] In an embodiment of the present application, a vector index library can be pre-constructed by mining candidate query information that meets the search screening conditions in the object log. During the retrieval process of the first query information, the associated query information corresponding to the first query text can be directly determined from the vector index library by means of vector retrieval, and then data retrieval can be performed based on the first query information and the associated query information, and the retrieval results of the first query information and the associated query information are used as the target retrieval results of the first query information. Since the associated query information is introduced in the retrieval process, the effectiveness of the retrieval results can be improved. Retrieval based on the pre-constructed vector index library can save the time for converting the candidate query information into the candidate query vector, that is, reduce the computational overhead in the retrieval process, and thus reduce the time-consuming data retrieval.

[0102] See also Figure 5 , Figure 5 FIG. 1 is a flow chart of another data processing method provided in an embodiment of the present application. Figure 5 As shown, the data processing method may include the following steps S201-S210:

[0103] Step S201, obtaining a sample data group; the sample data group includes first sample data, second sample data and a sample label, and the sample label is used to represent the association relationship between the first sample data and the second sample data.

[0104] Specifically, before using the target language model to encode text data, the language model needs to be trained. The following describes the training process of the language model through steps S201 to S203. In the embodiment of the present application, the language model in the training stage can be referred to as an initial language model, and the trained initial language model can be referred to as a target language model.

[0105] The computer device may obtain a sample data group for training an initial language model, where the sample data group may be a binary data, that is, the sample data group may include first sample data, second sample data, and a sample label, where the sample label is used to characterize the association relationship between the first sample data and the second sample data. For example, when the sample label is a first label (for example, the first label may be a value of 1), it indicates that the first sample data and the second sample data have an association relationship, that is, the first sample data and the second sample data match, and the sample data group at this time may be called a positive sample group; when the sample label is a second label (for example, the first label may be a value of 0), it indicates that the first sample data and the second sample data have no association relationship, that is, the first sample data and the second sample data do not match, and the sample data group at this time may be called a negative sample group. In other words, the sample data group may include a positive sample group and a negative sample group.

[0106] Among them, the training process of the initial language model requires a large amount of labeled data, and the computer device can automatically label the sample data group through the object log. For example, the computer device can obtain the first sample data and the second sample data within the target time range from the historical information set of the object log; the first sample data refers to the historical query information without object operation information, and the second sample data refers to the historical query information with object operation information. For example, the computer device obtains the first sample data without object operation data from the historical information set (the user did not click to view the retrieval results of the first sample data), within the target time range (which can be set according to actual needs, such as the target time range is 10 minutes, or half an hour, etc.), if the user switches to the second sample data and clicks to trigger the retrieval results of the second sample data, then the second sample data can be considered to be the rewritten query information of the first sample data. Then, the transition probability of the first sample data switching to the second sample data can be obtained, and the transition probability can refer to the ratio of the number of times the first sample data switches to the second sample data in the object log to the total number of times the first sample data switches; when the transition probability is greater than the probability threshold (which can be set according to actual needs), the sample label between the first sample data and the second sample data is determined to be the first label, and the first sample data, the second sample data and the first label are determined to be a positive sample group, and the positive sample group can be recorded as (first sample data, second sample data, first label).

[0107] Optionally, the computer device can obtain the first sample data without object operation information in the historical information set of the object log, obtain the second sample data through the random number strategy, and then determine that the sample label between the first sample data and the second sample data is the second label, and determine the first sample data, the second sample data and the second label as a negative sample group, which can be recorded as (first sample data, second sample data, second label). Among them, the above-mentioned random number strategy may include but is not limited to: a random number table, a random number dice, and a random number generated by a computer. After obtaining the first sample data, the second sample data can be selected using a random number table, a random number dice or a random number generated by a computer. The embodiment of the present application can obtain the object operation information of the historical query information, the total number of occurrences, and the number of times one historical query information switches to another historical query information by mining the object log, and can automatically annotate the sample data group required by the initial language model, which can save a lot of manpower annotation costs.

[0108] See also Figure 6 , Figure 6 is a schematic diagram of a sample data set provided in an embodiment of the present application. Figure 6 As shown, the computer device can perform normalization preprocessing on the historical query information in the user search log (object log), and the normalization preprocessing may include but is not limited to: converting uppercase and lowercase English letters, converting simplified and traditional Chinese characters, removing special characters, removing blank characters, etc.; normalization preprocessing can improve the statistical validity of the data and improve the quality of the sample data group.

[0109] The computer device can filter historical query information A (which can be called first sample data and does not have object operation information) that the user has searched but has not clicked to view the search results from the normalized preprocessed historical query information. Within the target time range, if the user switches from historical query information A to historical query information B and clicks to view the search results (with object operation information), it can be considered that historical query information B may be the rewritten query information of historical query information A, and then the transition probability of historical query information A switching to historical query information B can be counted in the object log, and the transition probability is equal to the ratio of the number of times historical query information A switches to historical query information B to the total number of times historical query information A switches to historical query information B. If the transition probability is greater than the probability threshold, the first label can be marked for historical query information A and historical query information B, which can be marked as (A, B, 1), where the value 1 can represent the first label, which is used to indicate that historical query information A matches historical query information B, that is, historical query information B is the rewritten query information of historical query information A, and at this time (A, B, 1) can be represented as a positive sample group. Furthermore, the computer device can randomly select and extract historical query information C from the object log, and mark the historical query information A and the historical query information C as (A, C, 0), where the value 1 can represent the second label, which is used to indicate that the historical query information A does not match the historical query information C. At this time, (A, C, 0) can be represented as a negative sample group. Here, the historical query information B and the historical query information C can both be considered as the second sample data.

[0110] Optionally, in addition to automatically annotating sample data groups in the manner described above, other methods of automatically annotating sample data groups may also be used, such as constructing a candidate sample data group through historical query information in the object log, and then performing data cleaning through a sample denoising algorithm to obtain a sample data group for training an initial language model. The present application does not limit the method of automatically annotating sample data groups.

[0111] Step S202: input the sample data set into an initial language model, and obtain a first sample vector corresponding to the first sample data and a second sample vector corresponding to the second sample data through the initial language model.

[0112] Specifically, the computer device can input the sample data group into the initial language model, and the initial language model can be a twin network, that is, the initial language model can include two sub-network structures of the same type, and then the first sample data and the second sample data in the sample data group can be input into the two sub-network structures respectively, and the first sample vector corresponding to the first sample data can be output through one of the sub-network structures, and the second sample vector corresponding to the second sample data can be output through the other sub-network structure. Among them, the initial language model can be a dual-tower model sharing Bert, such as a Bert model with two sub-network structures sharing weights.

[0113] Step S203, obtaining a sample distance between the first sample vector and the second sample vector, correcting the network parameters of the initial language model according to the contrast loss between the sample distance and the sample label, and determining the initial language model including the corrected network parameters as the target language model.

[0114] Specifically, the computer device can obtain the sample distance between the first sample vector and the second sample vector, such as the semantic correlation between the first sample vector and the second sample vector, which can also be called the similarity between the first sample vector and the second sample vector. The calculation method can be the same as the calculation method of the aforementioned vector association degree, which will not be repeated here. The computer device can calculate the contrast loss corresponding to the initial language model based on the sample distance and the sample label, and adjust the parameters in the initial language model by back propagation through the contrast loss. When the number of training times of the initial language model reaches the preset maximum number of iterations, or the training of the initial language model reaches the convergence condition, the network parameters at this time can be saved, and the initial language model containing these network parameters can be determined as the target language model. Optionally, since the initial language model contains two sub-network structures with shared weights (such as a dual-tower model based on Bert sharing), the target language model may refer to a network model that contains only one sub-network structure. For example, after the initial language model training is completed, a sub-network structure in the trained initial language model is determined as the target language model. For example, the target language model may be recorded as a Bert-FC model, which may refer to a network model after a fully connected layer is added to the Bert model. The trained target language model may be deployed to an online GPU (Graphics Processing Unit) module.

[0115] The sample distance between the first sample vector and the second sample vector can be recorded as r, and the sample distance r can be expressed as the following formula (1):

[0116] r=||Emb1-Emb2|| (1)

[0117] Among them, Emb1 can be expressed as the first sample vector, and Emb2 can be expressed as the second sample vector. The contrast loss Loss can be calculated by the sample distance r and the sample label y. The contrast loss Loss can be expressed as the following formula (2):

[0118]

[0119] Among them, y represents the sample label. When the sample data group is a positive sample group, y can take the value of 1, and when the sample data group is a negative sample group, y can take the value of 0; V represents the number of sample data groups; margin is a hyperparameter. If the first sample vector and the second sample vector are unrelated and the sample distance r is greater than margin, the contrast loss Loss is zero. Through this contrast loss Loss, the sample distance r between the matching sample data is made as close as possible, and the unmatched sample data greater than margin is ignored, which can improve the under-recall problem and improve the effectiveness of the retrieval results.

[0120] See also Figure 7 , Figure 7 is a schematic diagram of training an initial language model provided in an embodiment of the present application. Figure 7 As shown, the computer device can split the first sample data and the second sample data in the sample data group into multiple unit characters (which can be recorded as tokens), and use the initial language model to encode each unit character into a unit character vector. For example, when the first sample data is split into M unit character vectors, the initial language model can be used to encode M unit character vectors, and the dimension of each unit character vector is the same, such as the dimension of each vector can be 768 dimensions; then the average pooling layer can be used (here the pooling layer in the initial language model is assumed to be the average pooling layer; of course, the maximum pooling layer can also be used, and this application does not limit this) to convert the M unit character vectors into a fixed-length vector 40a, and the dimension of the vector 40a can be the same as the dimension of the aforementioned unit character vector, such as 768 dimensions. Similarly, for the second sample data in the sample data group, the average pooling layer can also be used to convert all unit character vectors corresponding to the second sample data into a fixed-length vector 40b, and the dimension of vector 40b is the same as the dimension of vector 40a.

[0121] Among them, each sub-network structure in the initial language model can add a fully connected layer on the basis of the Bert model. Through the fully connected layer in the initial language model, the vector 40a can be reduced to a first sample vector 40c, and the vector 40b can be reduced to a second sample vector 40d. That is, by adding a fully connected layer to the initial language model, the dimension of the sample vector can be reduced, thereby reducing the time consumption of online vector retrieval during data retrieval. Further, the computer device can calculate the sample distance r between the first sample vector 40c and the second sample vector 40d through the above formula (1), and calculate the contrast loss Loss between the sample distance r and the sample label y through the above formula (2). By minimizing and optimizing the contrast loss Loss, the network parameters in the initial language model are adjusted until the network parameters of the initial language model reach a convergence state.

[0122] In an embodiment of the present application, a target language model can be obtained through training to represent the semantic information of the query information (first query information, candidate query information) itself. Since the target language model has learned a large number of semantic grammatical rules through a massive sample data set, it can effectively represent the meaning of the query information itself, thereby improving the generalization of the model to improve the quality of the rewritten query information.

[0123] Step S204: Obtain a historical information set in the object log, and count the search frequencies corresponding to each piece of historical query information in the historical information set.

[0124] Specifically, the computer device can collect historical query information in the object log, and combine the historical query information in the object log into a historical information set, and then count the search frequency of each historical query information in the historical information set in the object log. The search frequency can be considered as the number of searches based on the historical query information recorded in the object log.

[0125] Step S205, if the object log contains object operation information corresponding to the historical query information s in the historical information set, and the search frequency corresponding to the historical query information s is greater than the frequency threshold, then it is determined that the historical query information s meets the search screening condition, and the historical query information s is added as candidate query information to the candidate information set; s is a positive integer.

[0126] Specifically, for any historical query information in the historical information set (for example, historical query information s, s is a positive integer less than or equal to the number of historical query information contained in the historical information set), if the object operation information of the historical query information s is recorded in the object log, and the search frequency corresponding to the historical query information s is greater than the frequency threshold (which can be customized according to actual needs), it can be determined that the historical query information s meets the search screening condition, and the historical query information s is used as a candidate query information in the candidate information set. Among them, the object operation information can refer to the operation information generated by the user clicking to view the search result of the historical query information s after the corresponding search result is recalled based on the historical query information s; since each candidate query information has object operation data in the object log, that is, each candidate query information can recall valid search results, the situation of invalid rewriting can be reduced.

[0127] Step S206, encoding each candidate query information in the candidate information set through the target language model to obtain a candidate query vector corresponding to each candidate query information; constructing index information for the candidate query vector corresponding to each candidate query information, and generating a vector index library corresponding to the candidate information set based on the index information.

[0128] Specifically, since the candidate query information contained in the candidate information set is large in number and the calculation is very time-consuming, the target language model trained above can be used to offline calculate the candidate query vector corresponding to each candidate query information. The process of obtaining the candidate query vector can refer to the above Figure 3 The description of the first query vector acquisition process in step S102 of the corresponding embodiment is not repeated here. Then, index information can be set for each candidate query vector, and a vector index library corresponding to the candidate information set can be generated based on the index information. For example, a vector index building tool (for example, Faiss or nmslib) can be used to build the vector index library, and the built vector index library is provided to the online retrieval system in the search engine.

[0129] Step S207, obtain the first query information, obtain the vector index library, obtain the first query vector corresponding to the first query information, and segment the vector data set associated with the vector index library to obtain N vector subsets; the vector data set includes the candidate query vector corresponding to the candidate query information in the object log, and N is a positive integer.

[0130] Specifically, when a user enters text content in a search engine to search, the computer device can determine the text content entered by the user as the first query information, and call the target language model deployed in the online GPU module to obtain the first query vector corresponding to the first query information. The computer device can also obtain the vector index library constructed offline as mentioned above, input the first query vector into the vector index library, and retrieve K (K is a positive integer) candidate query vectors with the highest vector correlation with the first query vector. The candidate query information corresponding to the K candidate query vectors here can be called associated query information, that is, K rewritten query information can be generated based on the first query information.

[0131] When performing vector retrieval based on the first query vector in the vector index library, different search methods can be used for vector retrieval, such as a tree-based method, a locality sensitive hashing (LSH), an inverted method, etc., which are not limited in this application. The following describes the vector retrieval process of the vector index library by taking the inverted method as an example.

[0132] The computer device may divide the vector data set associated with the vector index library to obtain N vector subsets, which may include candidate query vectors corresponding to each candidate query information in the candidate query information, and N is a positive integer, which is used to represent the number of vector subsets, that is, the number of divisions of the vector data set. Specifically, the computer device may divide the vector data set using a clustering method, and the operation flow of the clustering method may be described as follows: determine the center vector t from the vector data set associated with the vector index library i , get each candidate query vector and the center vector t in the vector data set i The vector similarity between them; i is a positive integer less than or equal to N; if the jth candidate query vector in the vector data set is similar to the center vector t i The vector similarity of is the largest, then the j-th candidate query vector is added to the center vector t i The pending cluster C i ; j is a positive integer less than or equal to the number of candidate query information contained in the vector data set; according to the cluster to be processed C i The candidate query vector contained in , updates the center vector t i , until the cluster to be processed C i The updated center vector t i and the center vector t before update i If the same, the cluster C to be processed i Determined as a subset of vectors.

[0133] The user terminal may pre-set the number of clusters (also referred to as the number of clusters) corresponding to all candidate query vectors in the vector data set. When the number of clusters is N (N is a positive integer less than the number of candidate query vectors in the vector data set), N candidate query vectors may be randomly selected from the vector data set as the initial center vector, i.e., the center vector t i (i is a positive integer less than or equal to N); the number of clusters set in the clustering algorithm can affect the final clustering effect of the candidate query vectors. If the number of clusters is too large, similar candidate query vectors may be divided into different clusters. If the number of clusters is too small, dissimilar candidate query vectors may be divided into the same cluster. In the embodiment of the present application, the number of clusters can be set based on experience, such as N=1000. Of course, the number of clusters can also be determined by methods such as cross-validation.

[0134] Optionally, in order to achieve a better clustering effect, the user terminal can select N candidate query vectors that are as far away from each other as possible from the vector data set as the initial center vector. The specific selection method is: randomly select a candidate query vector from the vector data set as the first center vector t1, and then select the candidate query vector farthest from the first center vector t1 from the remaining candidate query vectors in the vector data set (unselected candidate query vectors) as the second center vector t2; the center point between the first center vector t1 and the second center vector t2 can be calculated (the center point can be the candidate query vector corresponding to the average value of the first center vector t1 and the second center vector t2), and select the candidate query vector farthest from the center point from the remaining candidate query vectors in the vector data set as the third center vector t3, and so on, until the Nth center vector t is determined. N , N center vectors can be determined.

[0135] The user terminal can calculate the distance between each candidate query vector and each central vector in the vector data set (the distance between two candidate query vectors can be measured by the vector similarity between the two candidate query vectors. The greater the vector similarity, the shorter the distance, and the smaller the vector similarity, the greater the distance). That is, the distance between each candidate query vector and each central vector t in the vector data set is k The distance between them is divided into the candidate query vector (such as the j-th candidate query vector, j is a positive integer) to the nearest center vector t i Pending C i , N clusters to be processed can be preliminarily obtained (each center vector corresponds to a cluster to be processed), and each cluster to be processed can include multiple candidate query vectors (the number of candidate query vectors in each cluster to be processed can be different). Among them, the method used to calculate the distance between two candidate query vectors can be the same as the method used for the aforementioned association similarity, which will not be repeated here.

[0136] For the N clusters to be processed obtained above, the mean of all candidate query vectors contained in each cluster to be processed can be calculated, and the center vector corresponding to the cluster to be processed can be updated according to the mean to obtain a new center vector, and then the candidate query vector contained in each cluster to be processed can be updated according to the distance between each candidate query vector in the vector data set and each new center vector. The above process is repeated continuously, and when the candidate query vector contained in each cluster to be processed no longer changes, that is, the center vector corresponding to each cluster to be processed is fixed, the N clusters to be processed at this time can be determined as the final clustering result of the vector data set, that is, N vector subsets.

[0137] Step S208 : acquiring a target vector subset to which the first query vector belongs from the N vector subsets, and acquiring K associated query vectors associated with the first query vector from the target vector subset.

[0138] Specifically, the computer device can obtain the vector distances between the first query vector and the N vector subsets (similar to the aforementioned calculation method of vector similarity), and determine the vector subset corresponding to the shortest vector distance as the target vector subset to which the first query vector belongs; then the vector associations between the first query vector and the candidate query vectors in the target vector subset can be obtained, and the candidate query vectors in the target vector subset are sorted according to the vector associations to obtain the sorted target vector subset; in the sorted target vector subset, K associated query vectors corresponding to the first query vector are obtained according to the arrangement order. In other words, the target vector subset to which the first query vector belongs can be selected based on the vector distances between the first query vector and the center vectors of the N vector subsets in the N vector subsets, and then the first K candidate query vectors with the highest vector associations with the first query vector can be determined in the target vector subset, and the K candidate query vectors at this time are determined as the K associated query vectors corresponding to the first query vector.

[0139] Optionally, the aforementioned clustering method is only an example in the embodiment of the present application. The present application may also adopt other clustering methods for processing, such as hierarchical clustering algorithm, which is not limited in the present application.

[0140] Step S209: determine the candidate query information corresponding to the K associated query vectors as associated query information, and combine the first query information with the K associated query vectors into second query information.

[0141] Step S210: obtaining a search result corresponding to the second query information, and determining the search result of the second query information as a target search result for responding to the first query information.

[0142] The specific implementation process of step S209 and step S210 can be found in the above Figure 3 Step S102 and step S103 in the corresponding embodiment will not be described in detail here.

[0143] See also Figure 8 , Figure 8 This is a schematic diagram of a data processing process framework provided by an embodiment of the present application. Figure 8 As shown, the overall process of data processing may include a stage of automatically labeling sample data groups, a stage of model training, a stage of building an offline vector index library, and a stage of online retrieval.

[0144] The automatic labeling of sample data sets stage can label a large number of sample data sets for the initial language model. The automatic labeling process of the sample data sets can be referred to in the above Figure 6 The description in the corresponding embodiment will not be repeated here. The automatic labeling of the sample data group stage can effectively reduce the cost of manual labeling.

[0145] In the model training phase, the initial language model can be trained based on the sample data set generated in the automatic labeling sample data set phase. Figure 8 As shown, for the positive sample group (A, B, 1), that is, historical query information A (first sample data), historical query information B (second sample data) and sample label "1", the historical query information A and the historical query information B can be encoded respectively through the two sub-network structures (also called encoders) in the initial language model, and the vector A (first sample vector) corresponding to the historical query information A and the vector B (second sample vector) corresponding to the historical query information B can be obtained. The contrast loss is calculated through the vector distance between vector A and vector B, and the sample label of the positive sample group, and then the network parameters in the encoder can be adjusted through back propagation. The detailed description of the training process can be seen in Figure 7 According to the description in the corresponding embodiment, the text semantics of the query information can be learned in the model training phase, thereby improving the generalization of the associated query information.

[0146] In the offline vector index library construction stage, the target language model obtained in the model training stage can be used to generate offline candidate query vectors corresponding to each candidate query information in the candidate information set, and a vector index creation tool can be used to construct the vector index library. The construction process of the vector index library can be found in the description of steps S204 to S206. The vector index library can be deployed in the vector retrieval module of the search engine. The offline vector index library construction stage can effectively reduce the online time-consuming overhead.

[0147] In the online retrieval stage, if the user enters the first query information in the search engine, the target language model can be called to perform vector conversion on the first query information to generate a first query vector, and then the first query vector can be input into the vector retrieval module, and the associated query information corresponding to the first query information is obtained based on the vector index library. The search engine is searched based on the first query information and the associated query information, and the target retrieval result for responding to the first query information is recalled. The target retrieval result can be displayed in the query page corresponding to the search engine for the user to view.

[0148] It is understandable that in the specific implementation of this application, user search operation information may be involved. When the above embodiments of this application are applied to specific products or technologies, the user's permission or consent is required, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.

[0149] In an embodiment of the present application, a vector index library can be pre-constructed by mining candidate query information that meets the search screening conditions in the object log. During the retrieval process of the first query information, the associated query information corresponding to the first query text can be directly determined from the vector index library by means of vector retrieval, and then data retrieval can be performed based on the first query information and the associated query information, and the retrieval results of the first query information and the associated query information are used as the target retrieval results of the first query information. Since the associated query information is obtained based on the vector index library during the retrieval process, the generalization of the associated query information can be improved, and the effectiveness of the retrieval results can be improved. Retrieval based on the pre-constructed vector index library can save the time for converting the candidate query information into the candidate query vector, that is, reduce the computational overhead in the retrieval process, and thus reduce the time-consuming data retrieval.

[0150] Please attend Fig. 9 , Fig. 9 Schematic diagram of a data processing device provided in an embodiment of the present application. Fig. 9 As shown, the data processing device 1 may include: a first acquisition module 11, a second acquisition module 12, and a retrieval module 13;

[0151] A first acquisition module 11 is used to acquire first query information and acquire a vector index library; the vector index library is determined by candidate query information that meets the search screening condition in the object log;

[0152] A second acquisition module 12 is used to acquire associated query information corresponding to the first query information from the vector index library, and determine the first query information and the associated query information as second query information;

[0153] The search module 13 is used to obtain the search result corresponding to the second query information, and determine the search result of the second query information as the target search result for responding to the first query information.

[0154] The specific functional implementation of the first acquisition module 11, the second acquisition module 12, and the search module 13 can be found in Figure 3 Steps S101 to S103 in the corresponding embodiment will not be described in detail here.

[0155] In one or more embodiments, the number of associated query information is K, where K is a positive integer;

[0156] The second acquisition module 12 may include: a database segmentation unit 121, a correlation vector acquisition unit 122, and an information combination unit 123;

[0157] The database segmentation unit 121 is used to obtain a first query vector corresponding to the first query information, and segment the vector data set associated with the vector index library to obtain N vector subsets; the vector data set includes the candidate query vector corresponding to the candidate query information in the object log, and N is a positive integer;

[0158] The associated vector acquisition unit 122 is used to acquire a target vector subset to which the first query vector belongs from the N vector subsets, and acquire K associated query vectors associated with the first query vector from the target vector subset;

[0159] The information combining unit 123 is configured to determine the candidate query information corresponding to the K associated query vectors as associated query information, and combine the first query information with the K associated query vectors into second query information.

[0160] The specific functional implementation of the database segmentation unit 121, the association vector acquisition unit 122, and the information combination unit 123 can be found in Figure 5 Steps S207 to S209 in the corresponding embodiment will not be described in detail here.

[0161] In one or more embodiments, the database segmentation unit 121 includes: a character conversion subunit 1211, a pooling operation subunit 1212, and a dimensionality reduction processing subunit 1213;

[0162] The character conversion subunit 1211 is used to divide the first query information into M unit characters, input the M unit characters into the target language model in sequence, and encode the M unit characters into unit character vectors respectively through the target language model; M is a positive integer;

[0163] A pooling operation subunit 1212, configured to perform a pooling operation on the M unit character vectors to obtain an initial query vector corresponding to the first query information;

[0164] The dimensionality reduction processing subunit 1213 is used to perform dimensionality reduction processing on the initial query vector according to the fully connected layer in the target language model to obtain a first query vector.

[0165] The specific functional implementation of the character conversion subunit 1211, the pooling operation subunit 1212, and the dimension reduction processing subunit 1213 can be found in Figure 3 Step S102 in the corresponding embodiment will not be described in detail here.

[0166] In one or more embodiments, the database segmentation unit 121 includes: a similarity acquisition subunit 1214, a clustering processing subunit 1215, and a cluster center updating subunit 1216;

[0167] Similarity acquisition subunit 1214 is used to determine the center vector t from the vector data set associated with the vector index library. i , get each candidate query vector and the center vector t in the vector data set i The vector similarity between them; i is a positive integer less than or equal to N;

[0168] The clustering processing subunit 1215 is used to: if the j-th candidate query vector in the vector data set is consistent with the central vector t i The vector similarity of is the largest, then the j-th candidate query vector is added to the center vector t i The pending cluster C i ; j is a positive integer less than or equal to the number of candidate query information contained in the vector data set;

[0169] The cluster center updating subunit 1216 is used to update the cluster center according to the i The candidate query vector contained in , updates the center vector t i , until the cluster to be processed C i The updated center vector t i and the center vector t before update i If the same, the cluster to be processed C i Determined as a subset of vectors.

[0170] In one or more embodiments, the association vector acquisition unit 122 includes: a subset determination subunit 1221, a candidate vector sorting subunit 1222, and an association vector selection subunit 1223;

[0171] The subset determination subunit 1221 is used to obtain the vector distances between the first query vector and the N vector subsets respectively, and determine the vector subset corresponding to the shortest vector distance as the target vector subset to which the first query vector belongs;

[0172] The candidate vector sorting subunit 1222 is used to obtain the vector associations between the first query vector and the candidate query vectors in the target vector subset, and sort the candidate query vectors in the target vector subset according to the vector associations to obtain a sorted target vector subset;

[0173] The associated vector selection subunit 1223 is used to obtain K associated query vectors corresponding to the first query vector in the sorted target vector subset according to the arrangement order.

[0174] The specific functional implementation of the similarity acquisition subunit 1214, the clustering processing subunit 1215, the cluster center updating subunit 1216, the subset determination subunit 1221, the candidate vector sorting subunit 1222, and the associated vector selection subunit 1223 can be found in Figure 5 Step S207 and step S208 in the corresponding embodiment will not be described in detail here.

[0175] In one or more embodiments, the retrieval module 13 includes: an interface calling unit 131, a data recall unit 132;

[0176] The interface calling unit 131 is used to call the application program interface in the search engine to obtain the set of data to be recommended contained in the search engine;

[0177] The data recall unit 132 is configured to recall the search result corresponding to the second query information from the to-be-recommended data set according to the data similarity between the second query information and the to-be-recommended data in the to-be-recommended data set.

[0178] In one or more embodiments, the data processing device 1 further includes: a search result display module 14, a search result trigger module 15;

[0179] A search result display module 14, used to display the target search result corresponding to the first query information on the query page;

[0180] The search result triggering module 15 is used to respond to the triggering operation on the target search result and display the detailed description information corresponding to the target search result.

[0181] The specific functional implementation of the interface calling unit 131, the data recall unit 132, the search result display module 14, and the search result triggering module 15 can be found in Figure 3 Step S103 in the corresponding embodiment will not be described in detail here.

[0182] In one or more embodiments, the data processing device 1 further includes: a historical query information acquisition module 16, a candidate query information determination module 17, a candidate query information encoding module 18, an index library construction module 19, a sample data group acquisition module 20, a sample vector acquisition module 21, and a model training module 22;

[0183] The historical query information acquisition module 16 is used to acquire the historical information set in the object log and count the search frequency corresponding to each historical query information in the historical information set;

[0184] The candidate query information determination module 17 is used to determine that the historical query information s meets the search screening condition if the object log contains object operation information corresponding to the historical query information s in the historical information set, and the search frequency corresponding to the historical query information s is greater than the frequency threshold, and add the historical query information s as candidate query information to the candidate information set; s is a positive integer;

[0185] A candidate query information encoding module 18 is used to encode each candidate query information in the candidate information set through a target language model to obtain a candidate query vector corresponding to each candidate query information;

[0186] The index library construction module 19 is used to construct index information for the candidate query vector corresponding to each candidate query information, and generate a vector index library corresponding to the candidate information set based on the index information.

[0187] The sample data group acquisition module 20 is used to acquire a sample data group; the sample data group includes first sample data, second sample data and a sample label, and the sample label is used to characterize the association relationship between the first sample data and the second sample data;

[0188] A sample vector acquisition module 21 is used to input the sample data group into the initial language model, and obtain a first sample vector corresponding to the first sample data and a second sample vector corresponding to the second sample data through the initial language model;

[0189] The model training module 22 is used to obtain the sample distance between the first sample vector and the second sample vector, and to modify the network parameters of the initial language model according to the contrast loss between the sample distance and the sample label, and to determine the initial language model including the modified network parameters as the target language model.

[0190] The specific functional implementation of the historical query information acquisition module 16, the candidate query information determination module 17, the candidate query information encoding module 18, the index library construction module 19, the sample data group acquisition module 20, the sample vector acquisition module 21, and the model training module 22 can be found in Figure 5 Steps S201 to S206 in the corresponding embodiment will not be described in detail here.

[0191] In one or more embodiments, the sample data set includes a positive sample set;

[0192] The sample data group acquisition module 20 includes: a first sample acquisition unit 201, a sample label adding unit 202, and a positive sample group determination unit 203;

[0193] The first sample acquisition unit 201 is used to acquire first sample data and second sample data within a target time range from a historical information set of an object log; the first sample data refers to historical query information without object operation information, and the second sample data refers to historical query information with object operation information;

[0194] The sample label adding unit 202 is used to obtain the transition probability of switching from the first sample data to the second sample data, and when the transition probability is greater than the probability threshold, determine that the sample label between the first sample data and the second sample data is the first label; the first label is used to indicate that the first sample data and the second sample data have an association relationship;

[0195] The positive sample group determining unit 203 is used to determine the first sample data, the second sample data and the first label as a positive sample group.

[0196] Optionally, the sample data group includes a negative sample group;

[0197] The sample data group acquisition module 20 includes: a second sample acquisition unit 204, a negative sample group determination unit 205;

[0198] The second sample acquisition unit 204 is used to acquire first sample data without object operation information from the historical information set of the object log, and acquire second sample data by using a random number strategy;

[0199] The negative sample group determination unit 205 is used to determine that the sample label between the first sample data and the second sample data is a second label, and determine the first sample data, the second sample data and the second label as a negative sample group; the second label is used to indicate that the first sample data and the second sample data have no association relationship.

[0200] The specific functional implementation of the first sample acquisition unit 201, the sample label adding unit 202, the positive sample group determination unit 203, the second sample acquisition unit 204, and the negative sample group determination unit 205 can be found in Figure 5 The step S201 in the corresponding embodiment will not be described in detail here.

[0201] In an embodiment of the present application, a vector index library can be pre-constructed by mining candidate query information that meets the search screening conditions in the object log. During the retrieval process of the first query information, the associated query information corresponding to the first query text can be directly determined from the vector index library by means of vector retrieval, and then data retrieval can be performed based on the first query information and the associated query information, and the retrieval results of the first query information and the associated query information are used as the target retrieval results of the first query information. Since the associated query information is obtained based on the vector index library during the retrieval process, the generalization of the associated query information can be improved, and the effectiveness of the retrieval results can be improved. Retrieval based on the pre-constructed vector index library can save the time for converting the candidate query information into the candidate query vector, that is, reduce the computational overhead in the retrieval process, and thus reduce the time-consuming data retrieval.

[0202] For further information, see Fig.10 , Fig.10 Schematic diagram of the structure of a computer device provided in an embodiment of the present application. Fig.10 As shown, the computer device 1000 may be a user terminal, for example, Figure 1 The user terminal 10a in the corresponding embodiment may also be a server, for example, Figure 1 The server 10d in the corresponding embodiment will not be limited here. For ease of understanding, this application takes the computer device as a user terminal as an example. The computer device 1000 may include: a processor 1001, a network interface 1004 and a memory 1005. In addition, the computer device 1000 may also include: a user interface 1003, and at least one communication bus 1002. Among them, the communication bus 1002 is used to realize the connection and communication between these components. Among them, the user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface). The memory 1005 may be a high-speed RAM memory, or it may be a non-volatile memory (non-volatile memory), such as at least one disk storage. The memory 1005 may optionally also be at least one storage device located away from the aforementioned processor 1001. As Fig.10 As shown, the memory 1005 as a computer-readable storage medium may include an operating system, a network communication module, a user interface module, and a device control application program.

[0203] The network interface 1004 in the computer device 1000 can also provide a network communication function, and the optional user interface 1003 can also include a display screen (Display) and a keyboard (Keyboard). Fig.10In the computer device 1000 shown, the network interface 1004 can provide a network communication function; the user interface 1003 is mainly used to provide an input interface for the user; and the processor 1001 can be used to call the device control application stored in the memory 1005 to achieve:

[0204] Obtaining first query information and obtaining a vector index library; the vector index library is determined by candidate query information satisfying a search screening condition in the object log;

[0205] Acquire associated query information corresponding to the first query information from the vector index library, and determine the first query information and the associated query information as second query information;

[0206] A search result corresponding to the second query information is obtained, and the search result of the second query information is determined as a target search result for responding to the first query information.

[0207] It should be understood that the computer device 1000 described in the embodiment of the present application can execute the above Figure 3 and Figure 5 The description of the data processing method in any corresponding embodiment can also be performed as described above. Fig. 9 The description of the data processing device 1 in the corresponding embodiment will not be repeated here. In addition, the description of the beneficial effects of the same method will not be repeated here either.

[0208] In addition, it should be pointed out that: the embodiment of the present application also provides a computer-readable storage medium, and the computer-readable storage medium stores a computer program executed by the data processing device 1 mentioned above, and the computer program includes program instructions. When the processor executes the program instructions, it can execute the above-mentioned Figure 3 and Figure 5 The description of the data processing method in any corresponding embodiment will not be repeated here. In addition, the description of the beneficial effects of the same method will not be repeated. For technical details not disclosed in the computer-readable storage medium embodiment involved in this application, please refer to the description of the method embodiment of this application. As an example, program instructions can be deployed on a computing device for execution, or on multiple computing devices located at one location, or on multiple computing devices distributed at multiple locations and interconnected by a communication network. Multiple computing devices distributed at multiple locations and interconnected by a communication network can constitute a blockchain system.

[0209] In addition, it should be noted that: the embodiment of the present application also provides a computer program product or a computer program, which may include computer instructions, and the computer instructions may be stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor may execute the computer instructions, so that the computer device executes the above Figure 3 and Figure 5 The description of the data processing method in any corresponding embodiment will not be repeated here. In addition, the description of the beneficial effects of the same method will not be repeated. For technical details not disclosed in the computer program product or computer program embodiment involved in this application, please refer to the description of the method embodiment of this application.

[0210] It should be noted that, for the above-mentioned various method embodiments, for the sake of simplicity of description, they are all expressed as a series of action combinations, but those skilled in the art should be aware that this application is not limited by the order of the actions described, because according to this application, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by this application.

[0211] The steps in the method of the embodiment of the present application can be adjusted in order, combined and deleted according to actual needs.

[0212] The modules in the device of the embodiment of the present application can be merged, divided and deleted according to actual needs.

[0213] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing related hardware through a computer program, and the computer program can be stored in a computer-readable storage medium, and when the program is executed, it can include the processes of the embodiments of the above-mentioned methods. The storage medium can be a magnetic disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM), etc.

[0214] The above disclosure is only the preferred embodiment of the present application, which certainly cannot be used to limit the scope of rights of the present application. Therefore, equivalent changes made according to the claims of the present application are still within the scope covered by the present application.

Claims

1. A data processing method, characterized in that: include: Obtain a historical information set in the object log, and count the search frequencies corresponding to each historical query information in the historical information set, wherein the historical information set includes historical query information searched for each object and indication information indicating whether a search result returned by each historical query information has object operation information; If the historical query information s in the historical information set has object operation information, and the search frequency corresponding to the historical query information s is greater than the frequency threshold, it is determined that the historical query information s meets the search screening condition, and the historical query information s is added to the candidate information set as candidate query information, where s is a positive integer; Encoding each candidate query information in the candidate information set by using a target language model to obtain a candidate query vector corresponding to each candidate query information; Constructing index information for the candidate query vectors corresponding to each candidate query information, and generating a vector index library corresponding to the candidate information set based on the index information; Acquire first query information and acquire the vector index library; Acquire associated query information corresponding to the first query information from the vector index library, and determine the first query information and the associated query information as second query information; A search result corresponding to the second query information is obtained, and the search result of the second query information is determined as a target search result for responding to the first query information.

2. The method according to claim 1, characterized in that The number of the associated query information is K, where K is a positive integer; The acquiring, from the vector index library, associated query information corresponding to the first query information, and determining the first query information and the associated query information as second query information includes: Obtaining a first query vector corresponding to the first query information, and segmenting the vector data set associated with the vector index library to obtain N vector subsets; the vector data set includes a candidate query vector corresponding to the candidate query information in the object log, where N is a positive integer; Acquire a target vector subset to which the first query vector belongs from the N vector subsets, and acquire K associated query vectors associated with the first query vector from the target vector subset; The candidate query information respectively corresponding to the K associated query vectors is determined as associated query information, and the first query information and the K associated query information are combined into the second query information.

3. The method according to claim 2, characterized in that The obtaining a first query vector corresponding to the first query information includes: Divide the first query information into M unit characters, input the M unit characters into the target language model in sequence, and encode the M unit characters into unit character vectors respectively through the target language model; M is a positive integer; Performing a pooling operation on the M unit character vectors to obtain an initial query vector corresponding to the first query information; According to the fully connected layer in the target language model, dimension reduction processing is performed on the initial query vector to obtain the first query vector.

4. The method according to claim 2, characterized in that: The vector data set associated with the vector index library is segmented to obtain N vector subsets, including: Determine the center vector t from the vector data set associated with the vector index library i , obtain each candidate query vector in the vector data set and the center vector t i The vector similarity between them; i is a positive integer less than or equal to N; If the jth candidate query vector in the vector data set is consistent with the center vector t i The vector similarity of is the largest, then the j-th candidate query vector is added to the center vector t i The pending cluster C i ; j is a positive integer less than or equal to the number of candidate query information contained in the vector data set; According to the cluster C to be processed i The candidate query vector contained in , updates the center vector t i , until the to-be-processed cluster C i The updated center vector t i and the center vector t before update i If the same, the to-be-processed cluster C i Determined as a subset of vectors.

5. The method according to claim 2, characterized in that: The step of obtaining a target vector subset to which the first query vector belongs from the N vector subsets, and obtaining K associated query vectors associated with the first query vector from the target vector subset includes: Obtaining vector distances between the first query vector and the N vector subsets respectively, and determining the vector subset corresponding to the shortest vector distance as the target vector subset to which the first query vector belongs; Obtaining vector associations between the first query vector and candidate query vectors in the target vector subset, and sorting the candidate query vectors in the target vector subset according to the vector associations to obtain a sorted target vector subset; In the sorted target vector subset, K associated query vectors corresponding to the first query vector are obtained in order of arrangement.

6. The method according to claim 1, characterized in that The obtaining of the search result corresponding to the second query information includes: Calling an application program interface in a search engine to obtain a set of data to be recommended contained in the search engine; According to the data similarity between the second query information and the data to be recommended in the data set to be recommended, the search result corresponding to the second query information is recalled from the data set to be recommended.

7. The method according to claim 1, characterized in that Also includes: Displaying the target search results corresponding to the first query information on the query page; In response to a trigger operation on the target search result, detailed description information corresponding to the target search result is displayed.

8. The method according to claim 1 or 3, characterized in that: The method further comprises: Acquire a sample data group; the sample data group includes first sample data, second sample data, and a sample label, wherein the sample label is used to characterize the association relationship between the first sample data and the second sample data; Inputting the sample data group into an initial language model, and obtaining a first sample vector corresponding to the first sample data and a second sample vector corresponding to the second sample data through the initial language model; A sample distance between the first sample vector and the second sample vector is obtained, network parameters of the initial language model are corrected according to a contrast loss between the sample distance and the sample label, and the initial language model including the corrected network parameters is determined as the target language model.

9. The method according to claim 8, characterized in that The sample data group includes a positive sample group; The obtaining of the sample data set comprises: In the historical information set of the object log, first sample data and second sample data within a target time range are obtained; the first sample data refers to historical query information without object operation information, and the second sample data refers to historical query information with object operation information; Obtaining a transition probability of switching from the first sample data to the second sample data, and when the transition probability is greater than a probability threshold, determining that the sample label between the first sample data and the second sample data is a first label; the first label is used to represent that the first sample data and the second sample data have an association relationship; The first sample data, the second sample data, and the first label are determined as a positive sample group.

10. The method according to claim 8, characterized in that The sample data group includes a negative sample group; The obtaining of the sample data set comprises: In the historical information set of the object log, first sample data without object operation information is obtained, and second sample data is obtained by using a random number strategy; Determine that the sample label between the first sample data and the second sample data is a second label, and determine the first sample data, the second sample data and the second label as a negative sample group; the second label is used to characterize that the first sample data and the second sample data have no association relationship.

11. A data processing device, characterized in that: include: A historical query information acquisition module is used to acquire a historical information set in an object log, and to count the search frequencies corresponding to each historical query information in the historical information set, wherein the historical information set includes historical query information searched for each object and indication information indicating whether a search result returned by each historical query information has object operation information; a candidate query information determination module, configured to determine that the historical query information s satisfies the search screening condition if the historical query information s in the historical information set has object operation information and the search frequency corresponding to the historical query information s is greater than the frequency threshold, and add the historical query information s as candidate query information to the candidate information set, where s is a positive integer; A candidate query information encoding module, used to encode each candidate query information in the candidate information set through a target language model to obtain a candidate query vector corresponding to each candidate query information; An index library construction module, used to construct index information for the candidate query vector corresponding to each candidate query information, and generate a vector index library corresponding to the candidate information set based on the index information; A first acquisition module, used to acquire first query information and acquire the vector index library; A second acquisition module is used to acquire associated query information corresponding to the first query information from the vector index library, and determine the first query information and the associated query information as second query information; The retrieval module is used to obtain the retrieval result corresponding to the second query information, and determine the retrieval result of the second query information as the target retrieval result for responding to the first query information.

12. A computer device, characterized in that: including memory and processor; The memory is connected to the processor, the memory is used to store a computer program, and the processor is used to call the computer program so that the computer device executes the method according to any one of claims 1 to 10.

13. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and the computer program is suitable for being loaded and executed by a processor, so that a computer device having the processor executes the method according to any one of claims 1 to 10.

14. A computer program product, characterized in that The method comprises a computer program / instruction, which implements the method according to any one of claims 1 to 10 when executed by a processor.