WO2022116324A1 - Search model training method, apparatus, terminal device, and storage medium - Google Patents

Search model training method, apparatus, terminal device, and storage medium Download PDF

Info

Publication number
WO2022116324A1
WO2022116324A1 PCT/CN2020/140016 CN2020140016W WO2022116324A1 WO 2022116324 A1 WO2022116324 A1 WO 2022116324A1 CN 2020140016 W CN2020140016 W CN 2020140016W WO 2022116324 A1 WO2022116324 A1 WO 2022116324A1
Authority
WO
WIPO (PCT)
Prior art keywords
search
scholar
matrix
keyword
training
Prior art date
Application number
PCT/CN2020/140016
Other languages
French (fr)
Chinese (zh)
Inventor
吴嘉澍
王洋
须成忠
叶可江
Original Assignee
中国科学院深圳先进技术研究院
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 中国科学院深圳先进技术研究院 filed Critical 中国科学院深圳先进技术研究院
Publication of WO2022116324A1 publication Critical patent/WO2022116324A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/3331Query processing
    • G06F16/334Query execution
    • G06F16/3346Query execution using probabilistic model
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/3331Query processing
    • G06F16/334Query execution
    • G06F16/3344Query execution using natural language analysis
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Definitions

  • the invention belongs to the technical field of information retrieval, and in particular relates to a search model training method, device, terminal equipment and storage medium.
  • the information retrieval system can retrieve a variety of entities, such as text, audio, games, videos, etc. Taking the search of text as an example, the retrieval system will determine whether each text is related to the keyword according to the keyword searched. Relevance is ranked, resulting in satisfactory search results.
  • each text is independently considered for its relevance to the search keywords, but unlike the search for entities such as text, the search for scholars often requires a search for all the books written by a scholar.
  • the literature is considered in a centralized and comprehensive manner, rather than considering each literature individually.
  • the embodiments of the present invention provide a search model training method, apparatus, terminal device and storage medium to solve the problems of low search quality and low accuracy in the search model training in the prior art.
  • a first aspect of the embodiments of the present invention provides a search model training method, including:
  • the data set includes literature data and search key data
  • the literature data includes scholars and literature, each scholar includes at least two literatures
  • the search key data includes search keywords
  • search keywords perform two matrix transformation processing on the document-keyword matrix to obtain the scholar-keyword matrix
  • the Bayesian optimization network is used to update the parameters of the search model to be trained
  • a second aspect of the embodiments of the present invention provides a search model training device, including:
  • an acquisition module configured to acquire a data set, wherein the data set includes literature data and search key data, the literature data includes Sri and literature, each scholar includes at least two literatures, and the search key data includes search keywords;
  • the preprocessing module is used to preprocess the document data to obtain a document-keyword matrix
  • the matrix transformation module is used to perform two matrix transformation processing on the document-keyword matrix to obtain the scholar-keyword matrix
  • the training module is used to input the scholar-keyword matrix into the search model to be trained for training, and output the average training loss;
  • the parameter adjustment module is used to update the parameters of the search model to be trained by using the Bayesian optimization network if the average training loss does not reach the preset loss threshold;
  • the training completion module is used to retrain the updated search model to be trained, and stop training until the average training loss reaches the preset loss threshold, and use the search model to be trained at this time as the scholar search model.
  • a third aspect of the embodiments of the present invention provides a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements the steps of the above search model training method when the computer program is executed .
  • a fourth aspect of the embodiments of the present invention provides a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the steps of the above search model training method are implemented.
  • the document-keyword matrix is obtained by preprocessing the document data, and the document-keyword matrix is processed twice according to the search keywords, so as to obtain the scholar-keyword matrix, and the scholar-keyword matrix is input.
  • the model stops training until the average training loss reaches the preset loss threshold, and the search model to be trained at this time is used as the scholar search model, that is, the information of each document in the document-keyword is converted into a matrix by the scholar.
  • FIG. 1 is a schematic diagram of a process flow and an optimization framework of a search model training method according to an embodiment of the present invention
  • FIG. 2 is a schematic flowchart of a search model training method according to an embodiment of the present invention.
  • FIG. 3 is a schematic diagram of another embodiment of a process and an optimization framework of a search model training method according to an embodiment of the present invention
  • Fig. 4 is the document-keyword matrix, scholar-keyword matrix and LSA matrix decomposition schematic diagram of the embodiment of the present invention.
  • FIG. 5 is a schematic diagram of a search model training device provided by an embodiment of the present invention.
  • FIG. 6 is a schematic diagram of a hardware structure of a terminal device provided by an embodiment of the present invention.
  • the execution subject of the process is a terminal device
  • the terminal device includes but is not limited to a notebook computer, a computer, a server, a tablet computer, a smart phone, and other terminal devices with software development functions.
  • the terminal device executes the process in the implementation of the present invention, it can be used to provide the native application with the bearing function of the desktop application or the display of the front-end interface, and provide the interface assembly framework for the desktop application.
  • FIG. 1 is a schematic diagram of a process and an optimization framework of a search model training method according to an embodiment of the present invention, which specifically includes: preprocessing the document text to remove the punctuation to obtain the text, and performing the text on the text. Entry extraction is used to obtain document entries of the document text, and the knowledge tree is used to expand the document entries, and the expanded expanded entries and document entries are transformed to generate a document-entry matrix.
  • the document-entry matrix is transformed into a scholar-entry matrix through the first round of matrix transformation, and pseudo-relevance feedback is calculated according to the scholar-entry matrix, and the second round of matrix transformation is guided by the pseudo-relevance feedback, so that after the first round of matrix transformation,
  • the scholar-entry matrix after the second round of transformation is used as the training data for training the XGBoost model (a gradient boosting tree model), and the average loss value of the XGBoost model is calculated.
  • the Bayesian optimization network is used. Search to update the parameters of the XGBoost model, stop training until the average loss of training converges, and use the updated XGBoost model at this time as the earliest search model.
  • the present invention can aggregate the information of each document in the document-entry matrix into the scholar-entry matrix by two matrix transformation methods, in the unit of researchers, so that the algorithm can reach the scholar in the process of searching for scholars.
  • the purpose of unified and comprehensive consideration of all the literatures written is that the present invention cleverly uses pseudo-correlation feedback to assist the transformation of the matrix in the transformation process, so that the search is more accurate and efficient.
  • FIG. 2 is a schematic flowchart of a search model training method according to an embodiment of the present invention, which is described in detail as follows:
  • the document data includes a data set of each scholar and the academic documents written by them.
  • each article includes the title of the article, the abstract of the article, the text of the article, and the name of the academic conference/journal in which the article was published.
  • the search key data also includes result information corresponding to the search keywords, that is, the result information is documents marked by the search keywords, and the search key data can be used for the training of the search model, which is convenient for comparing the quality of the training results.
  • the document data is in a text format
  • the text data is converted from the text format into a corresponding matrix by preprocessing, which specifically includes:
  • cleaning the document data includes lowercase text data, deleting redundant spaces, punctuation, and clauses, so as to obtain text in plain text; the text is extracted by a preset word segmentation algorithm.
  • the algorithm can be a dictionary-based method, such as the forward maximum matching idea MM, the reverse maximum matching algorithm RMM, and the Bi-directction Matching method (BM), etc.; Matching, the words that match the matching degree are used as the expansion entries of the entry.
  • BM25F is an improved algorithm of typical BM25.
  • BM25 considers documents as a whole when calculating relevance, and each document is divided into multiple independent domains, especially for vertical searches. For example, web pages may be divided into domains such as title, content, and subject words. The contributions of these domains to the topic of the article cannot be treated equally, so the weight should be biased.
  • BM25 did not consider this point, so BM25F made some improvements on this basis, that is, it no longer only considers words as individuals, and divides documents into individual considerations according to field (region), so BM25F score is each keyword. Weighted summation of scores in each field.
  • a document-keyword matrix is constructed for the initial entry and the expanded entry, where the number of rows of the document-keyword matrix is the total number of articles in all documents, and the number of columns in the matrix is the total number of keywords in all documents, namely The total number of initial entries and extended words, the value stored in the i-th row and j column is the BM25F score of the j-th keyword in the i-th document in the entire dataset.
  • the document-keyword matrix is shown in Figure 3.
  • the present invention in order to obtain pseudo-relevance feedback information, the present invention needs to perform two rounds of matrix transformation on the document-keyword matrix. After the first round of matrix transformation, the transformed scholar-keyword matrix will be used to retrieve scholars most relevant to the search keywords and their most relevant literature, and generate pseudo-relevance feedback information. During the second round of rotation, the obtained pseudo-correlation feedback information will be used to guide the second round of matrix transformation to make the transformation more reasonable. Specifically, as shown in FIG. The process of the first matrix transformation and the second matrix transformation described in the schematic diagram of the embodiment.
  • the initial scholar-keyword matrix is transformed into a scholar-keyword matrix based on pseudo-relevant feedback information.
  • pseudo-relevant feedback also known as blind-relevant feedback
  • automates part of the manual operation of relevant feedback so users no longer need to perform additional interactions, that is, the normal retrieval process is performed first, and the most relevant documents are returned to form the initial set , then assume that the top k documents are relevant, and finally do the relevant feedback as before on this assumption.
  • the transformation process can assign higher scores to scholars who are more relevant than relevant feedback and lower scores to scholar who are less relevant and have larger gaps than relevant feedback , this matrix transformation based on pseudo-relevance feedback makes each keyword score in the matrix more reasonable.
  • the initial scholar-keyword matrix is constructed according to formula (1), that is, the score of each document-keyword for a scholar is equal to the sum of the scores of the document-keyword in all the documents written by the scholar (the numerator is the first item), multiplied by the logarithm of the number of papers in which the keyword appears in the literature written by the scholar (the second term in the numerator), and divided by the logarithm of the total number of papers written by the scholar (the denominator term).
  • a parameter ⁇ 1 , ⁇ 2 and ⁇ 3 are respectively assigned to the above three items to balance the importance of the items.
  • the pseudo-related feedback information includes:
  • the search researchers are selected from the researchers, and the search researchers are the top n scholar with the highest correlation with the search keywords;
  • the top n documents of each search scholar with the highest relevance to the search keywords are selected from the documents;
  • the mean value of the third cosine similarity is calculated, and the obtained first mean value is used as pseudo-correlation feedback information.
  • the initial scholar-keyword matrix is decomposed into a matrix by an LSA (Latent Semantic Analysis) model, and a scholar vector is obtained, wherein the LSA model is an existing algorithm model, which will not be explained here. .
  • the matrix decomposition process is shown in Figure 4, which is a schematic diagram of the decomposition of the literature-keyword matrix, the scholar-keyword matrix and the LSA matrix.
  • the initial scholar-keyword matrix (that is, the scholar-keyword matrix in Figure 4) is decomposed into the product of three matrices by the LSA model, including the keyword latent space matrix, latent space matrix (uncertain variable matrix) and Scholars matrix, which consists of scholar vectors.
  • n is a positive integer, and in the embodiment of the present invention, n is 5.
  • the initial scholar-keyword matrix is subjected to matrix decomposition operation using LSA, and after the matrix decomposition, the cosine formula is used to calculate the first cosine between the search keyword (in the form of a vector) and the scholar vector
  • the scholars are sorted according to the first cosine similarity in descending order, and the top 5 scholars most relevant to the search keywords are selected.
  • the literature-keyword matrix is matrix-decomposed to obtain the literature vector.
  • LSA is also used to perform the matrix decomposition operation, and after the matrix decomposition, the cosine formula is used to calculate the search keyword (in the form of a vector) and the literature vector.
  • the second cosine similarity and according to the sorting order of the second cosine similarity from large to small, the top n documents of each search scholar with the highest correlation with the search keywords are screened. Since the above setting n is 5, It can also be set to 5 here, that is, the setting of n remains the same.
  • the score in the scholar-keyword matrix will also be higher; if the scholar contains the literature-keywords, the higher the number of literature The higher the score in the scholar-keyword matrix, the higher the score in the scholar-keyword matrix; if the total number of literatures written by the scholar is large, the probability of the keyword appearing will naturally be high, so the total number of literatures written by the scholar will be high. as the denominator to reflect this fact.
  • the information of each document in the document-keyword matrix will be aggregated into the scholar-keyword matrix on a scholar-by-scholar basis, so that when a scholar is searched, all documents written by the scholar can be searched. comprehensive consideration.
  • the first mean obtained by averaging the third cosine similarity represents the highly related search keywords.
  • the degree of similarity that the literature should have, that is, the first mean value can be used as pseudo-related feedback information, and the pseudo-related feedback information is used to guide the second matrix transformation. For example, when the pseudo-related feedback information is a scholar's top 5 related documents and If the average similarity of search keywords is higher than the first average of the feedback, a higher score is assigned to the initial scholar-keyword matrix. Therefore, the matrix transformation method of the above pseudo-correlation feedback can more effectively transform the matrix, and improve the search quality when the transformed matrix is used for scholar search.
  • converting the initial scholar-keyword matrix into a scholar-keyword matrix according to the pseudo-relevant feedback information includes:
  • the initial scholar-keyword matrix is transformed into a scholar-keyword matrix.
  • formula (2) is used to calculate the score of each element of the scholar-keyword matrix.
  • the denominator part in formula (2) adds the average relevance (ie the second mean) of the author's more relevant literature and the obtained pseudo-relevance feedback information (ie the above-mentioned the first mean of ) for comparison.
  • the method of obtaining the top n documents of each scholar with the highest correlation with the search keywords is the same as the above-mentioned calculation method of selecting the search scholars from scholars according to the first cosine similarity, that is, by calculating the search keywords.
  • the cosine similarity with the documents-keywords in the first n documents of each scholar is sorted according to the cosine similarity from large to small to filter out the top n documents; the cosine similarity is also used to calculate the cosine similarity of each scholar.
  • the fourth cosine similarity between the first n documents and the search keywords is calculated, and the fourth cosine similarity corresponding to each scholar is accumulated and averaged to obtain the second mean.
  • the scholar-keyword matrix is input into the search model to be trained for training, and the average training loss is output.
  • the search model to be trained is an XGBoost model (eXtreme Gradient Boosting, extreme gradient boosting), and the XGBoost model converts the search ranking problem of scholar search into a two-classification problem of judging the sequence of results, that is, result A and result B , whether result A should be ranked in front of result B is a two-class judgment problem, thus reducing the demand for data, and training and learning can still be performed even when the supervised sorting data information is limited.
  • the corresponding loss value is obtained in the XGBoost model training, and all the loss values are averaged to obtain the current training average loss of the XGBoost model.
  • a Bayesian optimization network is used to update the parameters of the search model to be trained.
  • the preset loss threshold can be set according to the actual training situation, for example, the preset loss threshold is 0.1.
  • a Bayesian optimization network (Bayesian Optimization) is used to optimize and select the parameters of the current search model to be trained, thereby minimizing the loss value of the search model to be trained.
  • the Bayesian optimization network is a black-box optimization algorithm, which is used to solve the extreme value problem of the function with unknown expression.
  • the search principle of the Bayesian optimization network is to first generate an initial set of candidate solutions, and then search for these points The next most likely point is the extreme value, add this point to the set, repeat this step until the iteration is terminated, and finally find the point with the largest function value from these points as the solution of the extreme value problem. It is more efficient than other grid searches and random searches because the solution utilizes information from previously searched points. Because the Bayesian optimization network will consider the effect of the previous parameter selection before making a new parameter selection decision to optimize the next parameter selection, so as to more efficiently select and optimize the parameters of the training search model to achieve more efficient High-quality scholar search.
  • the search model to be trained after the parameters are updated in the above step S205 is used as the current training model, and the training is repeated, and the training average loss of each training output is compared with the preset loss threshold until the training average loss reaches the preset loss threshold. Stop training and use the current parameters as the final parameters of the search model to be trained, and then form a scholar search model
  • the data sets used in the training of the present invention are Chinese literature data, thesaurus and search ranking data sets, that is, the trained scholar search model can be used for keywords expressed in Chinese to search for Chinese scholars.
  • the scholar's search model can also operate, and the training and optimization frameworks remain unchanged, which is general to the language and reduces the limitations of the search model.
  • a document-keyword matrix is obtained by preprocessing the document data, and the document-keyword matrix is subjected to two matrix transformation processing according to the search keywords, so as to obtain a scholar-keyword matrix, and the scholar-keyword matrix is converted into a scholar-keyword matrix.
  • the matrix is input into the search model to be trained for training, and the average training loss is output.
  • the Bayesian optimization network is used to update the parameters of the search model to be trained, and the updated Train the search model, stop training until the average training loss reaches the preset loss threshold, and use the search model to be trained at this time as the scholar search model, that is, the information of each document in the document-keyword is converted into a scholar by matrix transformation. It is integrated into the scholar-keyword matrix as a unit, so that when conducting a scholar search, all literatures written by scholars will be comprehensively and comprehensively considered, that is, the correlation between scholar and search keywords can be accurately reflected. Therefore, the search task for scholars can be better completed, and the search results are more accurate and the search quality is efficient.
  • the present invention only relies on a small amount of marked search keywords and unmarked document data for training, it reduces the need for a large number of sorting.
  • the dependence of labeled supervision information enables training and learning under the condition of limited supervision information.
  • a search model training apparatus is also provided, and each module included in the search model training apparatus is used to execute each step in the embodiment corresponding to FIG. 2 .
  • FIG. 5 shows a schematic structural diagram of the first embodiment of the search model training device of the present invention, including an acquisition module 51, a difference module 52, a trajectory extraction module 53, and a target acquisition module 53:
  • the acquisition module 51 is used to acquire a data set, wherein the data set includes document data and search key data, the document data includes Sri and documents, each scholar includes at least two documents, and the search key data includes search keywords;
  • the preprocessing module 52 is used for preprocessing the document data to obtain a document-keyword matrix
  • the matrix transformation module 53 is used to perform two matrix transformation processes on the document-keyword matrix according to the search keywords, so as to obtain the scholar-keyword matrix;
  • the training module 54 is used to input the scholar-keyword matrix into the search model to be trained for training, and output the average training loss;
  • the parameter adjustment module 55 is used to update the parameters of the search model to be trained by using a Bayesian optimization network if the average training loss does not reach the preset loss threshold;
  • the training completion module 56 is used to retrain the updated search model to be trained, stop training until the average training loss reaches a preset loss threshold, and use the search model to be trained at this time as a scholar search model.
  • the preprocessing module 52 includes:
  • the cleaning unit is used to clean the literature data to obtain text
  • the extraction unit is used to extract the entry from the text to obtain the initial entry
  • the expansion unit is used to expand the initial entry to obtain the expanded entry
  • the transformation unit is used to transform the initial entry and the expanded entry into a document-keyword matrix.
  • the matrix conversion module 53 includes:
  • a first conversion unit used to convert a document-keyword matrix into an initial scholar-keyword matrix
  • Pseudo-correlation unit used to determine pseudo-correlation feedback information according to the initial scholar-keyword matrix and search keywords
  • the second conversion unit is configured to convert the initial scholar-keyword matrix into a scholar-keyword matrix according to the pseudo-relevant feedback information.
  • the pseudo-correlation unit includes:
  • the first decomposition subunit is used to perform matrix decomposition on the initial scholar-keyword matrix to obtain a scholar vector
  • the first calculation subunit is used to calculate the first cosine similarity between the search keyword and the scholar vector
  • the first screening subunit is used to screen out the search professionals from the scholars according to the first cosine similarity, wherein the search professionals are the top n universities with the highest correlation with the search keywords;
  • the second decomposition subunit is used to perform matrix decomposition on the document-keyword matrix to obtain a document vector
  • the second calculation subunit is used to calculate the second cosine similarity between the search keyword and the document vector
  • the second screening subunit is used to screen out the top n documents of each search scholar with the highest correlation with the search keywords from the documents according to the second cosine similarity;
  • the third calculation subunit is used to calculate the third cosine similarity between the top n documents of each search scholar and the search keywords respectively;
  • the first mean value subunit is used to calculate the mean value of the third cosine similarity, and use the obtained first mean value as pseudo-correlation feedback information.
  • the second conversion unit includes:
  • the acquisition subunit is used to acquire the top n documents of each scholar that are most relevant to the search keywords;
  • the fourth calculation subunit is used to calculate the fourth cosine similarity between the first n documents of each scholar and the search keywords;
  • the second mean subunit is used to perform mean calculation on the fourth cosine similarity to obtain the second mean
  • the conversion subunit is used to convert the initial scholar-keyword matrix into a scholar-keyword matrix according to the first mean value and the second mean value.
  • each module/unit in the above search model training apparatus corresponds to each step in the above search model training method embodiment, and the functions and implementation process thereof will not be repeated here.
  • FIG. 6 is a schematic diagram of a terminal device provided by an embodiment of the present invention.
  • this embodiment/terminal device 6 includes: a processor 60 , a memory 61 , and a computer program 62 stored in the memory 61 and executable on the processor 60 , such as a software development program.
  • the processor 60 executes the computer program 62
  • the steps in each of the foregoing software development method embodiments are implemented, for example, steps S101 to S104 shown in FIG. 1 .
  • the processor 60 executes the computer program 62
  • the functions of the modules/units in the above-mentioned system embodiments are implemented, for example, the functions of the modules 51 to 56 shown in FIG. 5 .
  • the computer program 62 may be divided into one or more modules/units, and the one or more modules/units are stored in the memory 61 and executed by the processor 60 to complete the this invention.
  • the one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, and the instruction segments are used to describe the execution process of the computer program 62 in the search model training apparatus/terminal device 6 .
  • the computer program 62 can be divided into an acquisition module, an execution module, and a generation module (modules in a virtual device), and the specific functions of each module are as described above, which will not be repeated here.
  • the terminal device 6 may be a computing device such as a desktop computer, a notebook, a palmtop computer, and a cloud server.
  • the terminal 6 device may include, but is not limited to, a processor 60 and a memory 61 .
  • FIG. 6 is only an example of the terminal device 6, and does not constitute a limitation on the terminal device 6, and may include more or less components than the one shown, or combine some components, or different components
  • the terminal device 6 may further include an input and output device, a network access device, a bus, and the like.
  • the so-called processor 60 may be a central processing unit (Central Processing Unit, CPU), or other general-purpose processors, digital signal processors (Digital Signal Processors, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), Off-the-shelf programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • a general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
  • the memory 61 may be an internal storage unit of the terminal device 6 , such as a hard disk or a memory of the terminal device 6 .
  • the memory 61 may also be an external storage device of the terminal device 6, such as a plug-in hard disk equipped on the terminal device, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card. , Flash Card (Flash Card) and so on.
  • the memory 61 may also include both an internal storage unit of the terminal device 6 and an external storage device.
  • the memory 61 is used to store the computer program and other programs and data required by the terminal device.
  • the memory 61 can also be used to temporarily store data that has been output or will be output.
  • the disclosed system/terminal device and method may be implemented in other manners.
  • the system/terminal device embodiments described above are only illustrative.
  • the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units. Or components may be combined or integrated into another device, or some features may be omitted, or not implemented.
  • the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
  • each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
  • the above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
  • the integrated modules/units if implemented in the form of software functional units and sold or used as independent products, may be stored in a computer-readable storage medium.
  • the present invention can implement all or part of the processes in the methods of the above embodiments, and can also be completed by instructing relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium.
  • the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form, and the like.
  • the computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, removable hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory) , Random Access Memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium, etc. It should be noted that the content contained in the computer-readable media may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction, for example, in some jurisdictions, according to legislation and patent practice, the computer-readable media Electric carrier signals and telecommunication signals are not included.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Probability & Statistics with Applications (AREA)
  • Artificial Intelligence (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

A search model training method, an apparatus, a terminal device, and a storage medium, applicable in the technical field of information retrieval. The search model training method comprises: pre-processing publication data to produce a publication-keyword matrix (S202); performing twice matrix conversion processing with respect to the publication-keyword matrix on the basis of a search keywork to produce scholar-keyword matrix (S203); inputting the scholar-keyword matrix into a search model to be trained for training, outputting a training average loss (S204); if the training average loss does not reach a preset loss threshold, then employing a Bayesian optimization network to update a parameter of said search model (S205); retraining said updated search model, stopping training when the training average loss reaches the preset loss threshold, and using said search model of this moment as a scholar search model (S206), thus allowing a high-quality and efficient search in the publications of a scholar, and increasing the accuracy of search results.

Description

搜索模型训练方法、装置、终端设备及存储介质Search model training method, device, terminal device and storage medium 技术领域technical field
本发明属于信息检索技术领域,尤其涉及一种搜索模型训练方法、装置、终端设备及存储介质。The invention belongs to the technical field of information retrieval, and in particular relates to a search model training method, device, terminal equipment and storage medium.
背景技术Background technique
信息检索技术随着现今大数据的快速发展变得愈发重要,其需要能够从海量的数据信息中根据用户的需求检索出相关的信息。信息检索系统可以对多样的实体进行检索,如对文本、音频、游戏、视频等进行检索,以对文本的搜索为例,检索系统会根据搜索的关键词来判断各个文本是否与关键词相关并对相关性进行排序,从而产生令人满意的搜索结果。然而,在普通的文本检索当中,每个文本都会被独立地被考量其与搜索关键词的相关性,但与对文本等实体的搜索不同,针对学者的搜索往往需要对一个学者所著的所有文献进行集中全面的考量,而不是对每一篇文献单独进行考量。With the rapid development of today's big data, information retrieval technology has become more and more important, and it needs to be able to retrieve relevant information from massive data information according to the needs of users. The information retrieval system can retrieve a variety of entities, such as text, audio, games, videos, etc. Taking the search of text as an example, the retrieval system will determine whether each text is related to the keyword according to the keyword searched. Relevance is ranked, resulting in satisfactory search results. However, in ordinary text retrieval, each text is independently considered for its relevance to the search keywords, but unlike the search for entities such as text, the search for scholars often requires a search for all the books written by a scholar. The literature is considered in a centralized and comprehensive manner, rather than considering each literature individually.
与此同时,随着数据量的日渐增多,手工标注搜索系统训练所需的包括搜索关键词及其正确排序的数据集变得愈发困难,这使得算法在监督信息有限的条件下进行训练、学习的能力更难,导致现有的搜索方法不适用于搜索模型训练,搜索质量低,准确率不高的问题。At the same time, with the increasing amount of data, it becomes more and more difficult to manually label the data sets required for the training of search systems, including search keywords and their correct ordering, which makes the algorithm training under the condition of limited supervision information, The ability to learn is more difficult, resulting in existing search methods not suitable for search model training, low search quality, and low accuracy.
发明内容SUMMARY OF THE INVENTION
有鉴于此,本发明实施例提供了搜索模型训练方法、装置、终端设备及存储 介质,以解决现有技术中对搜索模型训练存在的搜索质量低、准确率不高的问题。In view of this, the embodiments of the present invention provide a search model training method, apparatus, terminal device and storage medium to solve the problems of low search quality and low accuracy in the search model training in the prior art.
本发明实施例的第一方面提供了一种搜索模型训练方法,包括:A first aspect of the embodiments of the present invention provides a search model training method, including:
获取数据集,其中,数据集包括文献数据和搜索关键数据,文献数据包括学者和文献,每一学者包括至少两篇文献,搜索关键数据包括搜索关键词;Acquiring a data set, wherein the data set includes literature data and search key data, the literature data includes scholars and literature, each scholar includes at least two literatures, and the search key data includes search keywords;
将文献数据预处理得到文献-关键词矩阵;Preprocess the literature data to obtain a literature-keyword matrix;
根据搜索关键词,对文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵;According to the search keywords, perform two matrix transformation processing on the document-keyword matrix to obtain the scholar-keyword matrix;
将学者-关键词矩阵输入到待训练搜索模型中进行训练,并输出训练平均损失;Input the scholar-keyword matrix into the search model to be trained for training, and output the average training loss;
若训练平均损失未达到预设损失阈值,则采用贝叶斯优化网络更新待训练搜索模型的参数;If the average training loss does not reach the preset loss threshold, the Bayesian optimization network is used to update the parameters of the search model to be trained;
重新训练更新后的待训练搜索模型,直到训练平均损失达到预设损失阈值时停止训练,并将此时的待训练搜索模型作为学者搜索模型。Retrain the updated search model to be trained, stop training until the average training loss reaches the preset loss threshold, and use the search model to be trained at this time as the scholar search model.
本发明实施例的第二方面提供了一种搜索模型训练装置,包括:A second aspect of the embodiments of the present invention provides a search model training device, including:
获取模块,用于获取数据集,其中,数据集包括文献数据和搜索关键数据,文献数据包括学者和文献,每一学者包括至少两篇文献,搜索关键数据包括搜索关键词;an acquisition module, configured to acquire a data set, wherein the data set includes literature data and search key data, the literature data includes scholars and literature, each scholar includes at least two literatures, and the search key data includes search keywords;
预处理模块,用于将文献数据预处理得到文献-关键词矩阵;The preprocessing module is used to preprocess the document data to obtain a document-keyword matrix;
矩阵转化模块,用于对文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵;The matrix transformation module is used to perform two matrix transformation processing on the document-keyword matrix to obtain the scholar-keyword matrix;
训练模块,用于将学者-关键词矩阵输入到待训练搜索模型中进行训练,并输出训练平均损失;The training module is used to input the scholar-keyword matrix into the search model to be trained for training, and output the average training loss;
调参模块,用于若训练平均损失未达到预设损失阈值,则采用贝叶斯优化网络更新待训练搜索模型的参数;The parameter adjustment module is used to update the parameters of the search model to be trained by using the Bayesian optimization network if the average training loss does not reach the preset loss threshold;
训练完成模块,用于重新训练更新后的待训练搜索模型,直到训练平均损失达到预设损失阈值时停止训练,并将此时的待训练搜索模型作为学者搜索模型。The training completion module is used to retrain the updated search model to be trained, and stop training until the average training loss reaches the preset loss threshold, and use the search model to be trained at this time as the scholar search model.
本发明实施例的第三方面提供了一种终端设备,包括存储器、处理器以及存储在存储器中并可在处理器上运行的计算机程序,处理器执行计算机程序时实现上述搜索模型训练方法的步骤。A third aspect of the embodiments of the present invention provides a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements the steps of the above search model training method when the computer program is executed .
本发明实施例的第四方面提供了一种计算机可读存储介质,计算机可读存储介质存储有计算机程序,计算机程序被处理器执行时实现如上述搜索模型训练方法的步骤。A fourth aspect of the embodiments of the present invention provides a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the steps of the above search model training method are implemented.
本发明实施例与现有技术相比存在的有益效果是:The beneficial effects that the embodiment of the present invention has compared with the prior art are:
在本发明中,通过将文献数据预处理得到文献-关键词矩阵,根据搜索关键词对文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵,将学者-关键词矩阵输入到待训练搜索模型中进行训练,并输出训练平均损失,若训练平均损失未达到预设损失阈值,则采用贝叶斯优化网络更新待训练搜索模型的参数,并重新训练更新后的待训练搜索模型,直到训练平均损失达到预设损失阈值时停止训练,并将此时的待训练搜索模型作为学者搜索模型,也就是将文献-关键词中各个文献的信息通过矩阵转化的方式以学者为单位整合到学者-关键词矩阵中,从而在进行学者搜索时,会对学者所著的所有文献进行全面、综合性的考量,即能够准确地反映学者与搜索关键词之间的相关性,从而更好地完成针对学者的搜索任务,使得搜索结果更加准确、搜索质量高效,同时,由于本发明仅依靠少量的已标记的搜索关键词和无标记的文献数据进行训练,减少了对大量排序标记监督信息的依赖,使得可以在监督信息有限的条件下进行训练与学习。In the present invention, the document-keyword matrix is obtained by preprocessing the document data, and the document-keyword matrix is processed twice according to the search keywords, so as to obtain the scholar-keyword matrix, and the scholar-keyword matrix is input. Go to the search model to be trained for training, and output the average training loss. If the average training loss does not reach the preset loss threshold, use the Bayesian optimization network to update the parameters of the search model to be trained, and retrain the updated search to be trained. The model stops training until the average training loss reaches the preset loss threshold, and the search model to be trained at this time is used as the scholar search model, that is, the information of each document in the document-keyword is converted into a matrix by the scholar. It is integrated into the scholar-keyword matrix, so that when conducting a scholar search, all literature written by scholars will be comprehensively and comprehensively considered, that is, it can accurately reflect the correlation between scholars and search keywords, so as to improve The search task for scholars is well completed, so that the search results are more accurate and the search quality is efficient. At the same time, because the present invention only relies on a small number of marked search keywords and unmarked literature data for training, it reduces the supervision of a large number of sorting marks. The dependence of information makes it possible to train and learn under the condition of limited supervision information.
附图说明Description of drawings
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to illustrate the technical solutions in the embodiments of the present invention more clearly, the following briefly introduces the accompanying drawings that need to be used in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only for the present invention. In some embodiments, for those of ordinary skill in the art, other drawings can also be obtained according to these drawings without any creative effort.
图1是本发明实施例的搜索模型训练方法的流程及优化框架示意图;1 is a schematic diagram of a process flow and an optimization framework of a search model training method according to an embodiment of the present invention;
图2是本发明实施例的搜索模型训练方法的流程示意图;2 is a schematic flowchart of a search model training method according to an embodiment of the present invention;
图3是本发明实施例的搜索模型训练方法的流程及优化框架的又一实施例示意图;3 is a schematic diagram of another embodiment of a process and an optimization framework of a search model training method according to an embodiment of the present invention;
图4是本发明实施例的文献-关键词矩阵、学者-关键词矩阵及LSA矩阵分解示意图;Fig. 4 is the document-keyword matrix, scholar-keyword matrix and LSA matrix decomposition schematic diagram of the embodiment of the present invention;
图5是本发明实施例提供的搜索模型训练装置的示意图;5 is a schematic diagram of a search model training device provided by an embodiment of the present invention;
图6是本发明实施例提供的终端设备的硬件结构示意图。FIG. 6 is a schematic diagram of a hardware structure of a terminal device provided by an embodiment of the present invention.
具体实施方式Detailed ways
以下描述中,为了说明而不是为了限定,提出了诸如特定系统结构、技术之类的具体细节,以便透彻理解本发明实施例。然而,本领域的技术人员应当清楚,在没有这些具体细节的其它实施例中也可以实现本发明。在其它情况中,省略对众所周知的系统、装置、电路以及方法的详细说明,以免不必要的细节妨碍本发明的描述。In the following description, for the purpose of illustration rather than limitation, specific details such as specific system structures and technologies are set forth in order to provide a thorough understanding of the embodiments of the present invention. However, it will be apparent to those skilled in the art that the present invention may be practiced in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present invention with unnecessary detail.
为了说明本发明所述的技术方案,下面通过具体实施例来进行说明。In order to illustrate the technical solutions of the present invention, the following specific embodiments are used for description.
在本发明实施例中,流程的执行主体为终端设备,该终端设备包括但不限于 笔记本电脑、计算机、服务器、平板电脑以及智能手机等具有软件开发功能的终端设备。特别地,该终端设备执行本发明实施中的流程时能够用于为原生应用提供桌面应用的承载功能或前端界面的展示,为桌面应用提供界面组装框架。In the embodiment of the present invention, the execution subject of the process is a terminal device, and the terminal device includes but is not limited to a notebook computer, a computer, a server, a tablet computer, a smart phone, and other terminal devices with software development functions. In particular, when the terminal device executes the process in the implementation of the present invention, it can be used to provide the native application with the bearing function of the desktop application or the display of the front-end interface, and provide the interface assembly framework for the desktop application.
进一步地,与传统的文本搜索对文本独立进行考虑的做法不同,针对学者的搜索需要对该学者所著的所有文献进行统一全面的考虑,这使得一种将文献-关键词矩阵转化为学者-关键词矩阵的转化方式变得十分重要,图1为本发明实施例的搜索模型训练方法的流程及优化框架示意图,具体包括:将文献文本经过预处理去除掉标点符合后得到文本,对文本进行词条抽取,以获取文献文本的文献词条,利用知识树对文献词条做词条拓展,将拓展后的拓展词条和文献词条转化生成文献-词条矩阵。Further, unlike the traditional text search that considers the text independently, the search for a scholar requires a unified and comprehensive consideration of all the literature written by the scholar, which makes a method of transforming the literature-keyword matrix into a scholar- The transformation method of the keyword matrix becomes very important, and FIG. 1 is a schematic diagram of a process and an optimization framework of a search model training method according to an embodiment of the present invention, which specifically includes: preprocessing the document text to remove the punctuation to obtain the text, and performing the text on the text. Entry extraction is used to obtain document entries of the document text, and the knowledge tree is used to expand the document entries, and the expanded expanded entries and document entries are transformed to generate a document-entry matrix.
进一步地,将文献-词条矩阵经过第一轮矩阵转化生成学者-词条矩阵,并根据学者-词条矩阵计算伪相关性反馈,通过伪相关性反馈指导第二轮矩阵转化,使得经过第二轮转化后的学者-词条矩阵作为训练XGBoost模型(一种梯度提升树模型)的训练数据,计算XGBoost模型的平均损失值,当平均损失值未达到收敛条件时,通过贝叶斯优化网络搜索来更新XGBoost模型的参数,直至所训练的平均损失收敛时,停止训练,并将此时更新过的XGBoost模型作为最早的搜索模型。由于本发明通过两次矩阵转化方式可以将文献-词条矩阵中各篇文献的信息以学者为单位聚合至学者-词条矩阵中,从而使得算法可以达到在进行学者搜索的过程中对该学者所著的所有文献进行统一全面考量的目的,即本发明在转化过程中,巧妙借助了伪相关性反馈来辅助矩阵的转化,使得搜索更加准确高效。Further, the document-entry matrix is transformed into a scholar-entry matrix through the first round of matrix transformation, and pseudo-relevance feedback is calculated according to the scholar-entry matrix, and the second round of matrix transformation is guided by the pseudo-relevance feedback, so that after the first round of matrix transformation, The scholar-entry matrix after the second round of transformation is used as the training data for training the XGBoost model (a gradient boosting tree model), and the average loss value of the XGBoost model is calculated. When the average loss value does not reach the convergence condition, the Bayesian optimization network is used. Search to update the parameters of the XGBoost model, stop training until the average loss of training converges, and use the updated XGBoost model at this time as the earliest search model. Because the present invention can aggregate the information of each document in the document-entry matrix into the scholar-entry matrix by two matrix transformation methods, in the unit of scholars, so that the algorithm can reach the scholars in the process of searching for scholars. The purpose of unified and comprehensive consideration of all the literatures written is that the present invention cleverly uses pseudo-correlation feedback to assist the transformation of the matrix in the transformation process, so that the search is more accurate and efficient.
继续参考图2,图2为本发明实施例的搜索模型训练方法的流程示意图,详述如下:Continuing to refer to FIG. 2, FIG. 2 is a schematic flowchart of a search model training method according to an embodiment of the present invention, which is described in detail as follows:
S201,获取数据集,其中,数据集包括文献数据和搜索关键数据,文献数据包括学者和文献,每一学者包括至少两篇文献,搜索关键数据包括搜索关键词。S201. Acquire a data set, wherein the data set includes document data and search key data, the document data includes scholars and documents, each scholar includes at least two documents, and the search key data includes search keywords.
在本发明实施例中,文献数据包括各个学者及其所著学术文献的数据集。在文献数据中,每篇文献包括文献题目、文献摘要、文献正文以及文献所发表在的学术会议/期刊的名称。In the embodiment of the present invention, the document data includes a data set of each scholar and the academic documents written by them. In the literature data, each article includes the title of the article, the abstract of the article, the text of the article, and the name of the academic conference/journal in which the article was published.
进一步地,搜索关键数据还包括搜索关键词对应的结果信息,即结果信息为被搜索关键词标记过的文献,搜索关键数据可用于搜索模型的训练,便于对照训练结果的好坏。Further, the search key data also includes result information corresponding to the search keywords, that is, the result information is documents marked by the search keywords, and the search key data can be used for the training of the search model, which is convenient for comparing the quality of the training results.
S202,将文献数据预处理得到文献-关键词矩阵。S202, preprocessing the document data to obtain a document-keyword matrix.
具体地,文献数据为文本格式,通过预处理方式将所述文本数据从文本格式转化成相应的矩阵,具体包括:Specifically, the document data is in a text format, and the text data is converted from the text format into a corresponding matrix by preprocessing, which specifically includes:
将文献数据清洗得到文本;Clean literature data to get text;
将文本进行词条抽取得到初始词条;Extract the entry from the text to get the initial entry;
对初始词条拓展,以得到拓展词条;Expand the initial entry to get the expanded entry;
将初始词条和拓展词条转化成文献-关键词矩阵。Convert the initial and extended terms into a document-keyword matrix.
在本发明实施例中,对文献数据进行清洗包括对文本数据小写化、删除多余空格及标点、分句,以得到纯文字的文本;通过预设的分词算法对文本进行词条抽取,其中分词算法可以是基于词典的方法,例如正向最大匹配思想MM、逆向最大匹配算法RMM以及双向最大匹配法(Bi-directction Matching method,BM)等;将词条与预设的词表中的词语进行匹配,将符合匹配程度的词语作为该词条的拓展词条。In the embodiment of the present invention, cleaning the document data includes lowercase text data, deleting redundant spaces, punctuation, and clauses, so as to obtain text in plain text; the text is extracted by a preset word segmentation algorithm. The algorithm can be a dictionary-based method, such as the forward maximum matching idea MM, the reverse maximum matching algorithm RMM, and the Bi-directction Matching method (BM), etc.; Matching, the words that match the matching degree are used as the expansion entries of the entry.
由于学术文献具有严谨的逻辑性,且文献所包括的上述四部分(即文献题目、 文献摘要、文献正文以及文献所发表在的学术会议/期刊的名称)在重要性以及精炼性上存在差异,所以,在进行搜索时,对文献的不同部分赋以不同分数是较为常见的做法,本文采取了BM25F这一常用指标作为衡量关键词在文献中的分数的指标。Due to the rigorous logic of academic literature, and the differences in importance and refinement of the above four parts (namely, the title of the literature, the abstract of the literature, the text of the literature, and the name of the academic conference/journal in which the literature was published), Therefore, it is a common practice to assign different scores to different parts of the literature when searching. This paper adopts the commonly used index BM25F as an index to measure the scores of keywords in the literature.
其中,BM25F是典型BM25的改进算法。BM25在计算相关性时把文档当做总体来考虑,每个文档都会被切分成多个独立的域,尤其是垂直化的搜索。比如网页有可能被切分成标题,内容,主题词等域,这些域对文章主题的贡献不能同等对待,所以权重就要有所偏重。BM25没有考虑这点,所以BM25F在此基础上做了一些改进,就是不再单单的将单词作为个体考虑,并且将文档也依照field(区域)划分为个体考虑,所以BM25F分数是每一个关键词在各个field(区域)中分值的加权求和。Among them, BM25F is an improved algorithm of typical BM25. BM25 considers documents as a whole when calculating relevance, and each document is divided into multiple independent domains, especially for vertical searches. For example, web pages may be divided into domains such as title, content, and subject words. The contributions of these domains to the topic of the article cannot be treated equally, so the weight should be biased. BM25 did not consider this point, so BM25F made some improvements on this basis, that is, it no longer only considers words as individuals, and divides documents into individual considerations according to field (region), so BM25F score is each keyword. Weighted summation of scores in each field.
进一步地,对初始词条和拓展词条构建文献-关键词矩阵,其中,文献-关键词矩阵的行数为所有文献的总篇数,矩阵的列数为所有文献中的关键词总数,即初始词条和拓展词的总数,在第i行j列存储的值为整个数据集中第j个关键词在第i篇文献中的BM25F分数,文献-关键词矩阵如图3所示。Further, a document-keyword matrix is constructed for the initial entry and the expanded entry, where the number of rows of the document-keyword matrix is the total number of articles in all documents, and the number of columns in the matrix is the total number of keywords in all documents, namely The total number of initial entries and extended words, the value stored in the i-th row and j column is the BM25F score of the j-th keyword in the i-th document in the entire dataset. The document-keyword matrix is shown in Figure 3.
S203,根据搜索关键词,对文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵。S203, according to the search keywords, perform two matrix transformation processes on the document-keyword matrix to obtain a scholar-keyword matrix.
在本发明实施例中,为了能够得到伪相关性反馈信息,本发明需要对文献-关键词矩阵进行两轮矩阵转化。第一轮矩阵转化之后,转化所得到的学者-关键词矩阵将用于检索与搜索关键词最相关的学者及其所著的最相关的文献,并生成伪相关性反馈信息。第二轮转过程中,将利用所得到的伪相关性反馈信息指导第二轮矩阵转化,使得转化更加合理,具体如图3所示的本发明的搜索模型训练方 法的流程及优化框架的又一实施例示意图中所述的第一矩阵转化和第二矩阵转化的过程。In the embodiment of the present invention, in order to obtain pseudo-relevance feedback information, the present invention needs to perform two rounds of matrix transformation on the document-keyword matrix. After the first round of matrix transformation, the transformed scholar-keyword matrix will be used to retrieve scholars most relevant to the search keywords and their most relevant literature, and generate pseudo-relevance feedback information. During the second round of rotation, the obtained pseudo-correlation feedback information will be used to guide the second round of matrix transformation to make the transformation more reasonable. Specifically, as shown in FIG. The process of the first matrix transformation and the second matrix transformation described in the schematic diagram of the embodiment.
进一步地,根据搜索关键词,对文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵包括:Further, according to the search keywords, perform two matrix transformation processing on the document-keyword matrix to obtain the scholar-keyword matrix including:
将文献-关键词矩阵转化成初始学者-关键词矩阵;Convert the literature-keyword matrix into the initial scholar-keyword matrix;
根据初始学者-关键词矩阵和搜索关键词,确定伪相关反馈信息;Determine pseudo-relevant feedback information according to the initial scholar-keyword matrix and search keywords;
根据伪相关反馈信息将初始学者-关键词矩阵转换成学者-关键词矩阵。The initial scholar-keyword matrix is transformed into a scholar-keyword matrix based on pseudo-relevant feedback information.
其中,伪相关反馈,也称为盲相关反馈,它将相关反馈的人工操作部分自动化,因此,用户不再需要进行额外的交互,即首先进行正常的检索过程,返回最相关的文档构成初始集,然后假设排名靠前的k篇文档是相关的,最后在此假设上像以往一样进行相关反馈。如果对伪相关性反馈信息加以利用,转化过程就可以为比相关性反馈相关性更高的学者赋以更高分数,为比相关性反馈相关性低且差距大的学者赋以更低的分数,这种基于伪相关性反馈的矩阵转化使得矩阵中的每个关键词得分更加合理。Among them, pseudo-relevant feedback, also known as blind-relevant feedback, automates part of the manual operation of relevant feedback, so users no longer need to perform additional interactions, that is, the normal retrieval process is performed first, and the most relevant documents are returned to form the initial set , then assume that the top k documents are relevant, and finally do the relevant feedback as before on this assumption. If the pseudo-relevance feedback information is exploited, the transformation process can assign higher scores to scholars who are more relevant than relevant feedback and lower scores to scholars who are less relevant and have larger gaps than relevant feedback , this matrix transformation based on pseudo-relevance feedback makes each keyword score in the matrix more reasonable.
进一步地,根据公式(1)构建初始学者-关键词矩阵,即每一个文献-关键词对于一个学者的分数为等于该文献-关键词在该学者所著所有文献中的分数总和(分子第一项),乘以该学者所著文献中出现该关键词的文献篇数的对数(分子第二项),除以该学者所著文献的总篇数的对数(分母项)。同时,在公式(1)中为上述三项分别赋以一个参数ω 1、ω 2以及ω 3以平衡项与项的重要性。 Further, the initial scholar-keyword matrix is constructed according to formula (1), that is, the score of each document-keyword for a scholar is equal to the sum of the scores of the document-keyword in all the documents written by the scholar (the numerator is the first item), multiplied by the logarithm of the number of papers in which the keyword appears in the literature written by the scholar (the second term in the numerator), and divided by the logarithm of the total number of papers written by the scholar (the denominator term). Meanwhile, in formula (1), a parameter ω 1 , ω 2 and ω 3 are respectively assigned to the above three items to balance the importance of the items.
Figure PCTCN2020140016-appb-000001
Figure PCTCN2020140016-appb-000001
其中,
Figure PCTCN2020140016-appb-000002
为初始学者-关键词矩阵中每个元素的分数,
Figure PCTCN2020140016-appb-000003
为文献-关键词在该学者所著所有文献中的分数,
Figure PCTCN2020140016-appb-000004
为学者所著的文献中出现该文献-关键词的 文献篇数,
Figure PCTCN2020140016-appb-000005
为该学者所著文献的总篇数,i表示学者个数,J表示所有文献-关键词矩阵中文献关键词的总数。通过计算每个
Figure PCTCN2020140016-appb-000006
以构成初始学者-关键词矩阵中的每个元素的分数,即初始学者-关键词矩阵的行数为所有学者的个数,矩阵的列数为所有文献中的关键词总数,即初始词条和拓展词的总数。
in,
Figure PCTCN2020140016-appb-000002
is the score for each element in the initial scholar-keyword matrix,
Figure PCTCN2020140016-appb-000003
is the score of the literature-keyword in all literatures written by the scholar,
Figure PCTCN2020140016-appb-000004
The number of documents in which the document-keyword appears in the documents written by scholars,
Figure PCTCN2020140016-appb-000005
is the total number of literatures written by the scholar, i represents the number of scholars, and J represents the total number of literature keywords in all literature-keyword matrix. by calculating each
Figure PCTCN2020140016-appb-000006
Take the score of each element in the initial scholar-keyword matrix, that is, the number of rows of the initial scholar-keyword matrix is the number of all scholars, and the number of columns of the matrix is the total number of keywords in all documents, that is, the initial entry and the total number of extended words.
进一步地,根据初始学者-关键词矩阵和搜索关键词,确定伪相关反馈信息包括:Further, according to the initial scholar-keyword matrix and search keywords, it is determined that the pseudo-related feedback information includes:
将初始学者-关键词矩阵进行矩阵分解,得到学者向量;Perform matrix decomposition on the initial scholar-keyword matrix to obtain the scholar vector;
计算搜索关键词与学者向量的第一余弦相似度;Calculate the first cosine similarity between the search keyword and the scholar vector;
根据第一余弦相似度从学者中筛选出搜索学者,其中,搜索学者为与搜索关键词相关性最高的前n位学者;According to the first cosine similarity, the search scholars are selected from the scholars, and the search scholars are the top n scholars with the highest correlation with the search keywords;
将文献-关键词矩阵进行矩阵分解,得到文献向量;Perform matrix decomposition on the document-keyword matrix to obtain the document vector;
计算搜索关键词与文献向量的第二余弦相似度;Calculate the second cosine similarity between the search keyword and the document vector;
根据第二余弦相似度从文献中筛选出与搜索关键词相关性最高的每位搜索学者的前n篇文献;According to the second cosine similarity, the top n documents of each search scholar with the highest relevance to the search keywords are selected from the documents;
分别计算每位搜索学者的前n篇文献与搜索关键词的第三余弦相似度;Calculate the third cosine similarity between the top n documents of each search scholar and the search keywords respectively;
将第三余弦相似度进行均值计算,并将得到的第一均值作为伪相关反馈信息。The mean value of the third cosine similarity is calculated, and the obtained first mean value is used as pseudo-correlation feedback information.
在本发明实施例中,通过LSA(Latent Semantic Analysis,潜在语义分析)模型将初始学者-关键词矩阵进行矩阵分解,得到学者向量,其中,LSA模型为现有的算法模型,此处不再解释。矩阵分解过程如图4所示,图4为文献-关键词矩阵、学者-关键词矩阵及LSA矩阵分解示意图。通过LSA模型将初始学者-关键词矩阵(即图4中的学者-关键词矩阵)分解为三个矩阵的积,三个矩阵包括关键词隐空间矩阵、隐空间矩阵(不确定变量矩阵)以及学者矩阵,学者矩阵 由学者向量组成。In the embodiment of the present invention, the initial scholar-keyword matrix is decomposed into a matrix by an LSA (Latent Semantic Analysis) model, and a scholar vector is obtained, wherein the LSA model is an existing algorithm model, which will not be explained here. . The matrix decomposition process is shown in Figure 4, which is a schematic diagram of the decomposition of the literature-keyword matrix, the scholar-keyword matrix and the LSA matrix. The initial scholar-keyword matrix (that is, the scholar-keyword matrix in Figure 4) is decomposed into the product of three matrices by the LSA model, including the keyword latent space matrix, latent space matrix (uncertain variable matrix) and Scholars matrix, which consists of scholars vectors.
其中,n为正整数,本发明实施例取n为5。Wherein, n is a positive integer, and in the embodiment of the present invention, n is 5.
在本发明实施例中,将初始学者-关键词矩阵利用LSA进行矩阵分解操作,并在矩阵分解之后,采用余弦公式计算搜索关键词(以向量的形式)与学者向量之间的第一余弦相似度,并根据第一余弦相似度由大到小的顺序对学者进行排序,选取出与搜索关键词最相关的前5位学者。In the embodiment of the present invention, the initial scholar-keyword matrix is subjected to matrix decomposition operation using LSA, and after the matrix decomposition, the cosine formula is used to calculate the first cosine between the search keyword (in the form of a vector) and the scholar vector The scholars are sorted according to the first cosine similarity in descending order, and the top 5 scholars most relevant to the search keywords are selected.
进一步地,将文献-关键词矩阵进行矩阵分解,得到文献向量的方式同样采用用LSA进行矩阵分解操作,并在矩阵分解之后,采用余弦公式计算搜索关键词(以向量的形式)与文献向量的第二余弦相似度,并根据第二余弦相似度从大到小的排序顺序,筛选出与搜索关键词相关性最高的每位搜索学者的前n篇文献,由于上述设置n为5,此处同样可以设置为5,即n的设置保持一致。Further, the literature-keyword matrix is matrix-decomposed to obtain the literature vector. LSA is also used to perform the matrix decomposition operation, and after the matrix decomposition, the cosine formula is used to calculate the search keyword (in the form of a vector) and the literature vector. The second cosine similarity, and according to the sorting order of the second cosine similarity from large to small, the top n documents of each search scholar with the highest correlation with the search keywords are screened. Since the above setting n is 5, It can also be set to 5 here, that is, the setting of n remains the same.
进一步地,由于文献-关键词在该学者所著所有文献中的分数总和越高,在学者-关键词矩阵中的分数也会越高;如果该学者包含该文献-关键词的文献篇数越多,在学者-关键词矩阵中的分数也会越高;如果该学者所著的文献总篇数很多,则该关键词出现的概率自然会高,故将该学者所著的文献总篇数作为分母以反映这一事实。通过这一转化方式,文献-关键词矩阵中各个文献的信息会被以学者为单位被聚合到学者-关键词矩阵中,从而使得在进行学者搜索时,可以对该学者所著的所有文献进行全面的考量。Further, since the sum of the scores of the literature-keyword in all the literatures written by the scholar is higher, the score in the scholar-keyword matrix will also be higher; if the scholar contains the literature-keywords, the higher the number of literature The higher the score in the scholar-keyword matrix, the higher the score in the scholar-keyword matrix; if the total number of literatures written by the scholar is large, the probability of the keyword appearing will naturally be high, so the total number of literatures written by the scholar will be high. as the denominator to reflect this fact. Through this transformation method, the information of each document in the document-keyword matrix will be aggregated into the scholar-keyword matrix on a scholar-by-scholar basis, so that when a scholar is searched, all documents written by the scholar can be searched. comprehensive consideration.
因此,通过计算每位搜索学者的前n篇文献与搜索关键词的第三余弦相似度,将第三余弦相似度进行均值计算所得到的第一均值代表了与搜索关键词高度相关的文献应有的相似程度,即该第一均值可作为伪相关反馈信息,伪相关反馈信息用于指导第二次矩阵转化,例如,当伪相关反馈信息为某一学者的前5相关的 文献与搜索关键词的平均相似度高于所反馈的第一均值,则对初始学者-关键词矩阵赋以更高的分数。因此,上述伪相关性反馈的矩阵转化方式可以更有效地进行矩阵的转化,并使得转化之后的矩阵用于学者搜索时能提高搜索质量。Therefore, by calculating the third cosine similarity between the top n documents of each search scholar and the search keywords, the first mean obtained by averaging the third cosine similarity represents the highly related search keywords. The degree of similarity that the literature should have, that is, the first mean value can be used as pseudo-related feedback information, and the pseudo-related feedback information is used to guide the second matrix transformation. For example, when the pseudo-related feedback information is a scholar's top 5 related documents and If the average similarity of search keywords is higher than the first average of the feedback, a higher score is assigned to the initial scholar-keyword matrix. Therefore, the matrix transformation method of the above pseudo-correlation feedback can more effectively transform the matrix, and improve the search quality when the transformed matrix is used for scholar search.
进一步地,根据伪相关反馈信息将初始学者-关键词矩阵转换成学者-关键词矩阵包括:Further, converting the initial scholar-keyword matrix into a scholar-keyword matrix according to the pseudo-relevant feedback information includes:
获取与搜索关键词相关性最高的出每位学者的前n篇文献;Obtain the top n literatures of each scholar that are most relevant to the search keywords;
计算每位学者的前n篇文献与搜索关键词的第四余弦相似度;Calculate the fourth cosine similarity between each scholar's top n literature and search keywords;
将第四余弦相似度进行均值计算,得到第二均值;Calculate the mean of the fourth cosine similarity to obtain the second mean;
根据第一均值和第二均值,将初始学者-关键词矩阵转换成学者-关键词矩阵。According to the first mean and the second mean, the initial scholar-keyword matrix is transformed into a scholar-keyword matrix.
具体地,采用公式(2)计算学者-关键词矩阵的每个元素的分数。其中,与公式(1)相比,公式(2)中的分母部分新增了将该作者的较相关文献的平均相关度(即第二均值)与所得到的伪相关性反馈信息(即上述的第一均值)进行对比的项。Specifically, formula (2) is used to calculate the score of each element of the scholar-keyword matrix. Among them, compared with formula (1), the denominator part in formula (2) adds the average relevance (ie the second mean) of the author's more relevant literature and the obtained pseudo-relevance feedback information (ie the above-mentioned the first mean of ) for comparison.
Figure PCTCN2020140016-appb-000007
Figure PCTCN2020140016-appb-000007
其中,
Figure PCTCN2020140016-appb-000008
表示计算学者-关键词矩阵的每个元素的分数,AVG τ表示第二均值,avg τ表示第一均值,其余各项表示与公式(1)一样,此处不再赘述。
in,
Figure PCTCN2020140016-appb-000008
Represents the score of each element of the scholar-keyword matrix, AVG τ represents the second mean value, avg τ represents the first mean value, and the rest of the expressions are the same as formula (1), and will not be repeated here.
进一步地,获取与搜索关键词相关性最高的出每位学者的前n篇文献的方式与上述根据第一余弦相似度从学者中筛选出搜索学者的计算方式相同,即通过计算搜索关键词与每位学者的前n篇文献中的文献-关键词的余弦相似度,根据余弦相似度由大到小排序,以筛选出排名前n篇的文献;同样通过余弦相似度计算每位学者的前n篇文献与搜索关键词的第四余弦相似度,并将每个学者对应的第四余弦相似度进行累加求平均,以得到第二均值。Further, the method of obtaining the top n documents of each scholar with the highest correlation with the search keywords is the same as the above-mentioned calculation method of selecting the search scholars from scholars according to the first cosine similarity, that is, by calculating the search keywords. The cosine similarity with the documents-keywords in the first n documents of each scholar is sorted according to the cosine similarity from large to small to filter out the top n documents; the cosine similarity is also used to calculate the cosine similarity of each scholar. The fourth cosine similarity between the first n documents and the search keywords is calculated, and the fourth cosine similarity corresponding to each scholar is accumulated and averaged to obtain the second mean.
通过公式(2)可知,若该学者的较相关文献的平均相关度大于等于伪相关性反馈信息(即AVG τ>avg τ,0),则该项(即
Figure PCTCN2020140016-appb-000009
)会有个较小的值。反之,如果该学者的较相关文献的平均相关度小于伪相关性反馈,则如果差距越大,该项的值就会越大,公式(2)整体式子的值就会越小,即为该学者赋以一个更小的分数。所以,所得到的伪相关性反馈信息会被作为一个标杆,若该学者与标杆差距越大,分数就会越差,使得这一转化方式得到的学者-关键词矩阵中的分数更加合理。
According to formula (2), if the average correlation degree of the scholar's more relevant documents is greater than or equal to the pseudo-relevance feedback information (ie AVG τ >avg τ ,0), then this item (ie
Figure PCTCN2020140016-appb-000009
) will have a smaller value. Conversely, if the average relevance of the scholar's more relevant literature is less than the pseudo-relevance feedback, then if the gap is larger, the value of this item will be larger, and the overall value of formula (2) will be smaller, that is, The scholar assigns a smaller score. Therefore, the obtained pseudo-relevance feedback information will be used as a benchmark. If the gap between the scholar and the benchmark is larger, the score will be worse, making the score in the scholar-keyword matrix obtained by this transformation method more reasonable.
S204,将学者-关键词矩阵输入到待训练搜索模型中进行训练,并输出训练平均损失。S204, the scholar-keyword matrix is input into the search model to be trained for training, and the average training loss is output.
本发明实施例中,待训练搜索模型为XGBoost模型(eXtreme Gradient Boosting,极端梯度提升),XGBoost模型将学者搜索这一搜索排序问题转化为结果先后顺序的判断二分类问题,即结果A与结果B,结果A是否应排在结果B前面这一判断是否正确的二分类判断问题,从而减少了对数据的需求量,即使在监督排序数据信息有限时,依旧可以进行训练学习。根据学者-关键词矩阵中的每个学者-关键词在XGBoost模型中训练均得到对应的损失值,并将所有的损失值进行均值计算,以得到XGBoost模型在当前训练的训练平均损失。In the embodiment of the present invention, the search model to be trained is an XGBoost model (eXtreme Gradient Boosting, extreme gradient boosting), and the XGBoost model converts the search ranking problem of scholar search into a two-classification problem of judging the sequence of results, that is, result A and result B , whether result A should be ranked in front of result B is a two-class judgment problem, thus reducing the demand for data, and training and learning can still be performed even when the supervised sorting data information is limited. According to each scholar-keyword in the scholar-keyword matrix, the corresponding loss value is obtained in the XGBoost model training, and all the loss values are averaged to obtain the current training average loss of the XGBoost model.
S205,若训练平均损失未达到预设损失阈值,则采用贝叶斯优化网络更新待训练搜索模型的参数。S205 , if the average training loss does not reach the preset loss threshold, a Bayesian optimization network is used to update the parameters of the search model to be trained.
其中,预设损失阈值可以根据实际训练情况进行设置,例如预设损失阈值为0.1。当训练平均损失大于该预设损失阈值时,采用贝叶斯优化网络((Bayesian Optimization)对当前的待训练搜索模型的参数进行优化选取,从而最小化待训练搜索模型的损失值。The preset loss threshold can be set according to the actual training situation, for example, the preset loss threshold is 0.1. When the average training loss is greater than the preset loss threshold, a Bayesian optimization network (Bayesian Optimization) is used to optimize and select the parameters of the current search model to be trained, thereby minimizing the loss value of the search model to be trained.
其中,贝叶斯优化网络是一种黑盒优化算法,用于求解表达式未知的函数的极值问题,贝叶斯优化网络的搜索原理是首先生成一个初始候选解集合,然后根据这些点寻找下一个最有可能是极值的点,将该点加入集合中,重复这一步骤,直至迭代终止,最后从这些点中找出函数值最大的点作为极值问题的解。由于求解过程中利用之前已搜索点的信息,因此比其他网格搜索和随机搜索更为有效。由于贝叶斯优化网络在做出新的参数选择决策前会对上一次参数选择的效果进行考量,以优化下一次参数的选取,从而更高效地对待训练搜索模型的参数进行选取优化以实现更高质量的学者搜索。Among them, the Bayesian optimization network is a black-box optimization algorithm, which is used to solve the extreme value problem of the function with unknown expression. The search principle of the Bayesian optimization network is to first generate an initial set of candidate solutions, and then search for these points The next most likely point is the extreme value, add this point to the set, repeat this step until the iteration is terminated, and finally find the point with the largest function value from these points as the solution of the extreme value problem. It is more efficient than other grid searches and random searches because the solution utilizes information from previously searched points. Because the Bayesian optimization network will consider the effect of the previous parameter selection before making a new parameter selection decision to optimize the next parameter selection, so as to more efficiently select and optimize the parameters of the training search model to achieve more efficient High-quality scholar search.
S206,重新训练更新后的待训练搜索模型,直到训练平均损失达到预设损失阈值时停止训练,并将此时的待训练搜索模型作为学者搜索模型。S206, retrain the updated search model to be trained, stop training until the average training loss reaches a preset loss threshold, and use the search model to be trained at this time as a scholar search model.
将上述步骤S205更新参数后的待训练搜索模型作为当前的训练模型,并重复执行训练,将每次训练输出的训练平均损失与预设损失阈值进行比较,直到训练平均损失达到预设损失阈值时停止训练,并将当前的参数作为待训练搜索模型的最终参数,进而形成学者搜索模型The search model to be trained after the parameters are updated in the above step S205 is used as the current training model, and the training is repeated, and the training average loss of each training output is compared with the preset loss threshold until the training average loss reaches the preset loss threshold. Stop training and use the current parameters as the final parameters of the search model to be trained, and then form a scholar search model
需要说明的是,本发明的训练所使用的数据集为中文的文献数据、词库及搜索排序数据集,即训练后的学者搜索模型可以用于中文表达的关键词进行中文学者的搜索。同样地,如果所用数据集为法语,本学者搜索模型同样可以进行运作,且训练、优化框架均不变,具有对语言的一般性,减小了搜索模型的局限性。It should be noted that the data sets used in the training of the present invention are Chinese literature data, thesaurus and search ranking data sets, that is, the trained scholar search model can be used for keywords expressed in Chinese to search for Chinese scholars. Similarly, if the data set used is French, the scholar's search model can also operate, and the training and optimization frameworks remain unchanged, which is general to the language and reduces the limitations of the search model.
在本发明实施例中,通过将文献数据预处理得到文献-关键词矩阵,根据搜索关键词对文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵,将学者-关键词矩阵输入到待训练搜索模型中进行训练,并输出训练平均损失,若训练平均损失未达到预设损失阈值,则采用贝叶斯优化网络更新待训练搜索模 型的参数,并重新训练更新后的待训练搜索模型,直到训练平均损失达到预设损失阈值时停止训练,并将此时的待训练搜索模型作为学者搜索模型,也就是将文献-关键词中各个文献的信息通过矩阵转化的方式以学者为单位整合到学者-关键词矩阵中,从而在进行学者搜索时,会对学者所著的所有文献进行全面、综合性的考量,即能够准确地反映学者与搜索关键词之间的相关性,从而更好地完成针对学者的搜索任务,使得搜索结果更加准确、搜索质量高效,同时,由于本发明仅依靠少量的已标记的搜索关键词和无标记的文献数据进行训练,减少了对大量排序标记监督信息的依赖,使得可以在监督信息有限的条件下进行训练与学习。In the embodiment of the present invention, a document-keyword matrix is obtained by preprocessing the document data, and the document-keyword matrix is subjected to two matrix transformation processing according to the search keywords, so as to obtain a scholar-keyword matrix, and the scholar-keyword matrix is converted into a scholar-keyword matrix. The matrix is input into the search model to be trained for training, and the average training loss is output. If the average training loss does not reach the preset loss threshold, the Bayesian optimization network is used to update the parameters of the search model to be trained, and the updated Train the search model, stop training until the average training loss reaches the preset loss threshold, and use the search model to be trained at this time as the scholar search model, that is, the information of each document in the document-keyword is converted into a scholar by matrix transformation. It is integrated into the scholar-keyword matrix as a unit, so that when conducting a scholar search, all literatures written by scholars will be comprehensively and comprehensively considered, that is, the correlation between scholars and search keywords can be accurately reflected. Therefore, the search task for scholars can be better completed, and the search results are more accurate and the search quality is efficient. At the same time, because the present invention only relies on a small amount of marked search keywords and unmarked document data for training, it reduces the need for a large number of sorting. The dependence of labeled supervision information enables training and learning under the condition of limited supervision information.
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本发明实施例的实施过程构成任何限定。It should be understood that the size of the sequence numbers of the steps in the above embodiments does not mean the sequence of execution, and the execution sequence of each process should be determined by its functions and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
本发明实施例中,还提供了一种搜索模型训练装置,搜索模型训练装置包括的各模块用于执行图2对应的实施例中的各步骤。具体请参阅图2对应的实施例中的相关描述。图5示出了本发明的搜索模型训练装置的第一实施例的结构示意图,包括获取模块51、差分模块52、轨迹提取模块53以及目标获取模块53:In the embodiment of the present invention, a search model training apparatus is also provided, and each module included in the search model training apparatus is used to execute each step in the embodiment corresponding to FIG. 2 . For details, please refer to the relevant description in the embodiment corresponding to FIG. 2 . 5 shows a schematic structural diagram of the first embodiment of the search model training device of the present invention, including an acquisition module 51, a difference module 52, a trajectory extraction module 53, and a target acquisition module 53:
获取模块51,用于获取数据集,其中,数据集包括文献数据和搜索关键数据,文献数据包括学者和文献,每一学者包括至少两篇文献,搜索关键数据包括搜索关键词;The acquisition module 51 is used to acquire a data set, wherein the data set includes document data and search key data, the document data includes scholars and documents, each scholar includes at least two documents, and the search key data includes search keywords;
预处理模块52,用于将文献数据预处理得到文献-关键词矩阵;The preprocessing module 52 is used for preprocessing the document data to obtain a document-keyword matrix;
矩阵转化模块53,用于根据搜索关键词,对文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵;The matrix transformation module 53 is used to perform two matrix transformation processes on the document-keyword matrix according to the search keywords, so as to obtain the scholar-keyword matrix;
训练模块54,用于将学者-关键词矩阵输入到待训练搜索模型中进行训练, 并输出训练平均损失;The training module 54 is used to input the scholar-keyword matrix into the search model to be trained for training, and output the average training loss;
调参模块55,用于若训练平均损失未达到预设损失阈值,则采用贝叶斯优化网络更新待训练搜索模型的参数;The parameter adjustment module 55 is used to update the parameters of the search model to be trained by using a Bayesian optimization network if the average training loss does not reach the preset loss threshold;
训练完成模块56,用于重新训练更新后的待训练搜索模型,直到训练平均损失达到预设损失阈值时停止训练,并将此时的待训练搜索模型作为学者搜索模型。The training completion module 56 is used to retrain the updated search model to be trained, stop training until the average training loss reaches a preset loss threshold, and use the search model to be trained at this time as a scholar search model.
进一步地,预处理模块52包括:Further, the preprocessing module 52 includes:
清洗单元,用于将文献数据清洗得到文本;The cleaning unit is used to clean the literature data to obtain text;
抽取单元,用于将文本进行词条抽取得到初始词条;The extraction unit is used to extract the entry from the text to obtain the initial entry;
拓展单元,用于对初始词条拓展,以得到拓展词条;The expansion unit is used to expand the initial entry to obtain the expanded entry;
转化单元,用于将初始词条和拓展词条转化成文献-关键词矩阵。The transformation unit is used to transform the initial entry and the expanded entry into a document-keyword matrix.
进一步地,矩阵转化模块53包括:Further, the matrix conversion module 53 includes:
第一转化单元,用于将文献-关键词矩阵转化成初始学者-关键词矩阵;a first conversion unit, used to convert a document-keyword matrix into an initial scholar-keyword matrix;
伪相关单元,用于根据初始学者-关键词矩阵和搜索关键词,确定伪相关反馈信息;Pseudo-correlation unit, used to determine pseudo-correlation feedback information according to the initial scholar-keyword matrix and search keywords;
第二转化单元,用于根据伪相关反馈信息将初始学者-关键词矩阵转换成学者-关键词矩阵。The second conversion unit is configured to convert the initial scholar-keyword matrix into a scholar-keyword matrix according to the pseudo-relevant feedback information.
进一步地,伪相关单元包括:Further, the pseudo-correlation unit includes:
第一分解子单元,用于将初始学者-关键词矩阵进行矩阵分解,得到学者向量;The first decomposition subunit is used to perform matrix decomposition on the initial scholar-keyword matrix to obtain a scholar vector;
第一计算子单元,用于计算搜索关键词与学者向量的第一余弦相似度;The first calculation subunit is used to calculate the first cosine similarity between the search keyword and the scholar vector;
第一筛选子单元,用于根据第一余弦相似度从学者中筛选出搜索学者,其中,搜索学者为与搜索关键词相关性最高的前n位学者;The first screening subunit is used to screen out the search scholars from the scholars according to the first cosine similarity, wherein the search scholars are the top n scholars with the highest correlation with the search keywords;
第二分解子单元,用于将文献-关键词矩阵进行矩阵分解,得到文献向量;The second decomposition subunit is used to perform matrix decomposition on the document-keyword matrix to obtain a document vector;
第二计算子单元,用于计算搜索关键词与文献向量的第二余弦相似度;The second calculation subunit is used to calculate the second cosine similarity between the search keyword and the document vector;
第二筛选子单元,用于根据第二余弦相似度从文献中筛选出与搜索关键词相关性最高的每位搜索学者的前n篇文献;The second screening subunit is used to screen out the top n documents of each search scholar with the highest correlation with the search keywords from the documents according to the second cosine similarity;
第三计算子单元,用于分别计算每位搜索学者的前n篇文献与搜索关键词的第三余弦相似度;The third calculation subunit is used to calculate the third cosine similarity between the top n documents of each search scholar and the search keywords respectively;
第一均值子单元,用于将第三余弦相似度进行均值计算,并将得到的第一均值作为伪相关反馈信息。The first mean value subunit is used to calculate the mean value of the third cosine similarity, and use the obtained first mean value as pseudo-correlation feedback information.
进一步地,第二转化单元包括:Further, the second conversion unit includes:
获取子单元,用于获取与搜索关键词相关性最高的出每位学者的前n篇文献;The acquisition subunit is used to acquire the top n documents of each scholar that are most relevant to the search keywords;
第四计算子单元,用于计算每位学者的前n篇文献与搜索关键词的第四余弦相似度;The fourth calculation subunit is used to calculate the fourth cosine similarity between the first n documents of each scholar and the search keywords;
第二均值子单元,用于将第四余弦相似度进行均值计算,得到第二均值;The second mean subunit is used to perform mean calculation on the fourth cosine similarity to obtain the second mean;
转换子单元,用于根据第一均值和第二均值,将初始学者-关键词矩阵转换成学者-关键词矩阵。The conversion subunit is used to convert the initial scholar-keyword matrix into a scholar-keyword matrix according to the first mean value and the second mean value.
其中,上述搜索模型训练装置中各个模块/单元的功能实现与上述搜索模型训练方法实施例中各步骤相对应,其功能和实现过程在此处不再一一赘述。The function implementation of each module/unit in the above search model training apparatus corresponds to each step in the above search model training method embodiment, and the functions and implementation process thereof will not be repeated here.
图6是本发明一实施例提供的终端设备的示意图。如图6所示,该实施例/终端设备6包括:处理器60、存储器61以及存储在所述存储器61中并可在所述处理器60上运行的计算机程序62,例如软件开发程序。所述处理器60执行所述计算机程序62时实现上述各个软件开发方法实施例中的步骤,例如图1所示的步骤S101至S104。或者,所述处理器60执行所述计算机程序62时实现上述各 系统实施例中各模块/单元的功能,例如图5所示模块51至56的功能。FIG. 6 is a schematic diagram of a terminal device provided by an embodiment of the present invention. As shown in FIG. 6 , this embodiment/terminal device 6 includes: a processor 60 , a memory 61 , and a computer program 62 stored in the memory 61 and executable on the processor 60 , such as a software development program. When the processor 60 executes the computer program 62 , the steps in each of the foregoing software development method embodiments are implemented, for example, steps S101 to S104 shown in FIG. 1 . Alternatively, when the processor 60 executes the computer program 62, the functions of the modules/units in the above-mentioned system embodiments are implemented, for example, the functions of the modules 51 to 56 shown in FIG. 5 .
示例性的,所述计算机程序62可以被分割成一个或多个模块/单元,所述一个或者多个模块/单元被存储在所述存储器61中,并由所述处理器60执行,以完成本发明。所述一个或多个模块/单元可以是能够完成特定功能的一系列计算机程序指令段,该指令段用于描述所述计算机程序62在所述搜索模型训练装置/终端设备6中的执行过程。例如,所述计算机程序62可以被分割成获取模块、执行模块、生成模块(虚拟装置中的模块),各模块具体功能如上所述,此处不再赘述。Exemplarily, the computer program 62 may be divided into one or more modules/units, and the one or more modules/units are stored in the memory 61 and executed by the processor 60 to complete the this invention. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, and the instruction segments are used to describe the execution process of the computer program 62 in the search model training apparatus/terminal device 6 . For example, the computer program 62 can be divided into an acquisition module, an execution module, and a generation module (modules in a virtual device), and the specific functions of each module are as described above, which will not be repeated here.
所述终端设备6可以是桌上型计算机、笔记本、掌上电脑及云端服务器等计算设备。所述终端6设备可包括,但不仅限于,处理器60、存储器61。本领域技术人员可以理解,图6仅仅是终端设备6的示例,并不构成对终端设备6的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件,例如所述终端设备6还可以包括输入输出设备、网络接入设备、总线等。The terminal device 6 may be a computing device such as a desktop computer, a notebook, a palmtop computer, and a cloud server. The terminal 6 device may include, but is not limited to, a processor 60 and a memory 61 . Those skilled in the art can understand that FIG. 6 is only an example of the terminal device 6, and does not constitute a limitation on the terminal device 6, and may include more or less components than the one shown, or combine some components, or different components For example, the terminal device 6 may further include an input and output device, a network access device, a bus, and the like.
所称处理器60可以是中央处理单元(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现成可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。The so-called processor 60 may be a central processing unit (Central Processing Unit, CPU), or other general-purpose processors, digital signal processors (Digital Signal Processors, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), Off-the-shelf programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
所述存储器61可以是所述终端设备6的内部存储单元,例如终端设备6的硬盘或内存。所述存储器61也可以是所述终端设备6的外部存储设备,例如所述终端设备上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全 数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。进一步地,所述存储器61还可以既包括所述终端设备6的内部存储单元也包括外部存储设备。所述存储器61用于存储所述计算机程序以及所述终端设备所需的其他程序和数据。所述存储器61还可以用于暂时地存储已经输出或者将要输出的数据。The memory 61 may be an internal storage unit of the terminal device 6 , such as a hard disk or a memory of the terminal device 6 . The memory 61 may also be an external storage device of the terminal device 6, such as a plug-in hard disk equipped on the terminal device, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card. , Flash Card (Flash Card) and so on. Further, the memory 61 may also include both an internal storage unit of the terminal device 6 and an external storage device. The memory 61 is used to store the computer program and other programs and data required by the terminal device. The memory 61 can also be used to temporarily store data that has been output or will be output.
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述系统的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。另外,各功能单元、模块的具体名称也只是为了便于相互区分,并不用于限制本发明的保护范围。上述系统中单元、模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that, for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned functions can be allocated to different functional units, Module completion means dividing the internal structure of the system into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiment may be integrated in one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit, and the above-mentioned integrated units may adopt hardware. It can also be realized in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing from each other, and are not used to limit the protection scope of the present invention. For the specific working process of the units and modules in the above-mentioned system, reference may be made to the corresponding process in the foregoing method embodiments, which will not be repeated here.
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。In the foregoing embodiments, the description of each embodiment has its own emphasis. For parts that are not described or described in detail in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本发明的范围。Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Skilled artisans may implement the described functionality using different methods for each particular application, but such implementations should not be considered beyond the scope of the present invention.
在本发明所提供的实施例中,应该理解到,所揭露的系统/终端设备和方法,可以通过其它的方式实现。例如,以上所描述的系统/终端设备实施例仅仅是示意 性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个装置,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。In the embodiments provided by the present invention, it should be understood that the disclosed system/terminal device and method may be implemented in other manners. For example, the system/terminal device embodiments described above are only illustrative. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units. Or components may be combined or integrated into another device, or some features may be omitted, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
所述集成的模块/单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明实现上述实施例方法中的全部或部分流程,也可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读介质可以包括:能够携带所述计算机程序代码的任何实体或装置、记录介质、U盘、移动硬盘、磁碟、光盘、计算机存储器、只读存储器(ROM,Read-Only Memory)、随机存取存储 器(RAM,Random Access Memory)、电载波信号、电信信号以及软件分发介质等。需要说明的是,所述计算机可读介质包含的内容可以根据司法管辖区内立法和专利实践的要求进行适当的增减,例如在某些司法管辖区,根据立法和专利实践,计算机可读介质不包括电载波信号和电信信号。The integrated modules/units, if implemented in the form of software functional units and sold or used as independent products, may be stored in a computer-readable storage medium. Based on this understanding, the present invention can implement all or part of the processes in the methods of the above embodiments, and can also be completed by instructing relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium. When the program is executed by the processor, the steps of the foregoing method embodiments can be implemented. . Wherein, the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form, and the like. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, removable hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory) , Random Access Memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium, etc. It should be noted that the content contained in the computer-readable media may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction, for example, in some jurisdictions, according to legislation and patent practice, the computer-readable media Electric carrier signals and telecommunication signals are not included.
以上所述实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的精神和范围,均应包含在本发明的保护范围之内。The above-mentioned embodiments are only used to illustrate the technical solutions of the present invention, but not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: it is still possible to implement the foregoing implementations. The technical solutions described in the examples are modified, or some technical features thereof are equivalently replaced; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should be included in the within the protection scope of the present invention.

Claims (10)

  1. 一种搜索模型训练方法,其特征在于,包括:A method for training a search model, comprising:
    获取数据集,其中,所述数据集包括文献数据和搜索关键数据,所述文献数据包括学者和文献,每一学者包括至少两篇文献,所述搜索关键数据包括搜索关键词;acquiring a data set, wherein the data set includes document data and search key data, the document data includes scholars and documents, each scholar includes at least two documents, and the search key data includes search keywords;
    将所述文献数据预处理得到文献-关键词矩阵;Preprocessing the document data to obtain a document-keyword matrix;
    根据所述搜索关键词,对所述文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵;According to the search keywords, perform two matrix transformation processes on the document-keyword matrix to obtain a scholar-keyword matrix;
    将所述学者-关键词矩阵输入到待训练搜索模型中进行训练,并输出训练平均损失;Inputting the scholar-keyword matrix into the search model to be trained for training, and outputting the average training loss;
    若所述训练平均损失未达到预设损失阈值,则采用贝叶斯优化网络更新所述待训练搜索模型的参数;If the training average loss does not reach the preset loss threshold, use a Bayesian optimization network to update the parameters of the search model to be trained;
    重新训练更新后的所述待训练搜索模型,直到所述训练平均损失达到所述预设损失阈值时停止训练,并将此时的待训练搜索模型作为学者搜索模型。Retrain the updated search model to be trained, stop training until the average training loss reaches the preset loss threshold, and use the search model to be trained at this time as a scholar search model.
  2. 如权利要求1所述的搜索模型训练方法,其特征在于,所述将所述文献数据预处理得到文献-关键词矩阵包括:The search model training method according to claim 1, wherein the preprocessing of the document data to obtain a document-keyword matrix comprises:
    将所述文献数据清洗得到文本;Cleaning the literature data to obtain text;
    将所述文本进行词条抽取得到初始词条;Extracting the entry from the text to obtain the initial entry;
    对所述初始词条拓展,以得到拓展词条;Expanding the initial entry to obtain an expanded entry;
    将所述初始词条和所述拓展词条转化成文献-关键词矩阵。The initial term and the expanded term are converted into a document-keyword matrix.
  3. 如权利要求1所述的搜索模型训练方法,其特征在于,所述根据所述搜索关键词,对所述文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵包括:The search model training method according to claim 1, wherein, according to the search keywords, performing two matrix transformation processes on the document-keyword matrix to obtain the scholar-keyword matrix comprises:
    将所述文献-关键词矩阵转化成初始学者-关键词矩阵;Converting the document-keyword matrix into an initial scholar-keyword matrix;
    根据所述初始学者-关键词矩阵和所述搜索关键词,确定伪相关反馈信息;Determine pseudo-relevant feedback information according to the initial scholar-keyword matrix and the search keywords;
    根据所述伪相关反馈信息将所述初始学者-关键词矩阵转换成学者-关键词矩 阵。The initial scholar-keyword matrix is converted into a scholar-keyword matrix according to the pseudo-relevant feedback information.
  4. 如权利要求3所述的搜索模型训练方法,其特征在于,所述根据所述初始学者-关键词矩阵和所述搜索关键词,确定伪相关反馈信息包括:The search model training method according to claim 3, wherein the determining of the pseudo-related feedback information according to the initial scholar-keyword matrix and the search keywords comprises:
    将所述初始学者-关键词矩阵进行矩阵分解,得到学者向量;Perform matrix decomposition on the initial scholar-keyword matrix to obtain a scholar vector;
    计算所述搜索关键词与所述学者向量的第一余弦相似度;calculating the first cosine similarity between the search keyword and the scholar vector;
    根据所述第一余弦相似度从所述学者中筛选出搜索学者,其中,所述搜索学者为与所述搜索关键词相关性最高的前n位学者;According to the first cosine similarity, search scholars are selected from the scholars, wherein the search scholars are the top n scholars with the highest correlation with the search keywords;
    将所述文献-关键词矩阵进行矩阵分解,得到文献向量;Perform matrix decomposition on the document-keyword matrix to obtain a document vector;
    计算所述搜索关键词与所述文献向量的第二余弦相似度;calculating the second cosine similarity between the search keyword and the document vector;
    根据所述第二余弦相似度从所述文献中筛选出与所述搜索关键词相关性最高的每位所述搜索学者的前n篇文献;According to the second cosine similarity, filter out the top n documents of each of the search scholars with the highest correlation with the search keywords from the documents;
    分别计算每位搜索学者的所述前n篇文献与所述搜索关键词的第三余弦相似度;Calculate the third cosine similarity between the first n documents of each search scholar and the search keyword respectively;
    将所述第三余弦相似度进行均值计算,并将得到的第一均值作为伪相关反馈信息。Perform mean value calculation on the third cosine similarity, and use the obtained first mean value as pseudo-correlation feedback information.
  5. 如权利要求4所述的搜索模型训练方法,其特征在于,所述根据所述伪相关反馈信息将所述初始学者-关键词矩阵转换成学者-关键词矩阵包括:The search model training method according to claim 4, wherein the converting the initial scholar-keyword matrix into a scholar-keyword matrix according to the pseudo-relevant feedback information comprises:
    获取与所述搜索关键词相关性最高的出每位学者的前n篇文献;Obtain the top n documents of each scholar that are most relevant to the search keywords;
    计算每位学者的前n篇文献与所述搜索关键词的第四余弦相似度;Calculate the fourth cosine similarity between each scholar's top n documents and the search keyword;
    将所述第四余弦相似度进行均值计算,得到第二均值;performing mean calculation on the fourth cosine similarity to obtain a second mean;
    根据所述第一均值和所述第二均值,将所述初始学者-关键词矩阵转换成学者-关键词矩阵。The initial scholar-keyword matrix is converted into a scholar-keyword matrix according to the first mean value and the second mean value.
  6. 一种搜索模型训练装置,其特征在于,包括:A search model training device, comprising:
    获取模块,用于获取数据集,其中,所述数据集包括文献数据和搜索关键数据,所述文献数据包括学者和文献,每一学者包括至少两篇文献,所述搜索关键 数据包括搜索关键词;An acquisition module for acquiring a data set, wherein the data set includes document data and search key data, the document data includes scholars and documents, each scholar includes at least two documents, and the search key data includes search keywords ;
    预处理模块,用于将所述文献数据预处理得到文献-关键词矩阵;a preprocessing module for preprocessing the document data to obtain a document-keyword matrix;
    矩阵转化模块,用于根据所述搜索关键词,对所述文献-关键词矩阵执行两次矩阵转化处理,以得到学者-关键词矩阵;a matrix transformation module, configured to perform two matrix transformation processes on the document-keyword matrix according to the search keywords to obtain a scholar-keyword matrix;
    训练模块,用于将所述学者-关键词矩阵输入到待训练搜索模型中进行训练,并输出训练平均损失;A training module for inputting the scholar-keyword matrix into the search model to be trained for training, and outputting the average training loss;
    调参模块,用于若所述训练平均损失未达到预设损失阈值,则采用贝叶斯优化网络更新所述待训练搜索模型的参数;A parameter adjustment module, configured to update the parameters of the search model to be trained by using a Bayesian optimization network if the average training loss does not reach a preset loss threshold;
    训练完成模块,用于重新训练更新后的所述待训练搜索模型,直到所述训练平均损失达到所述预设损失阈值时停止训练,并将此时的待训练搜索模型作为学者搜索模型。The training completion module is used to retrain the updated search model to be trained, stop training until the average loss of training reaches the preset loss threshold, and use the search model to be trained at this time as the scholar search model.
  7. 如权利要求6所述的搜索模型训练装置,其特征在于,所述预处理模块包括:The search model training device according to claim 6, wherein the preprocessing module comprises:
    清洗单元,用于将所述文献数据清洗得到文本;a cleaning unit, used for cleaning the document data to obtain text;
    抽取单元,用于将所述文本进行词条抽取得到初始词条;an extraction unit, used for extracting entries from the text to obtain an initial entry;
    拓展单元,用于对所述初始词条拓展,以得到拓展词条;an expansion unit, used to expand the initial entry to obtain an expanded entry;
    转化单元,用于将所述初始词条和所述拓展词条转化成文献-关键词矩阵。A conversion unit, configured to convert the initial entry and the expanded entry into a document-keyword matrix.
  8. 如权利要求7所述的搜索模型训练装置,其特征在于,所述矩阵转化模块包括:The search model training device according to claim 7, wherein the matrix transformation module comprises:
    第一转化单元,用于将所述文献-关键词矩阵转化成初始学者-关键词矩阵;a first conversion unit, for converting the document-keyword matrix into an initial scholar-keyword matrix;
    伪相关单元,用于根据所述初始学者-关键词矩阵和所述搜索关键词,确定伪相关反馈信息;A pseudo-correlation unit, configured to determine pseudo-related feedback information according to the initial scholar-keyword matrix and the search keywords;
    第二转化单元,用于根据所述伪相关反馈信息将所述初始学者-关键词矩阵转换成学者-关键词矩阵。The second conversion unit is configured to convert the initial scholar-keyword matrix into a scholar-keyword matrix according to the pseudo-related feedback information.
  9. 一种终端设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时实现如权利要求1至5任一项所述搜索模型训练方法的步骤。A terminal device, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that, when the processor executes the computer program, the process according to claim 1 to 5 any one of the steps of the search model training method.
  10. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1至5任一项所述搜索模型训练方法的步骤。A computer-readable storage medium storing a computer program, characterized in that, when the computer program is executed by a processor, the search model training method according to any one of claims 1 to 5 is implemented. step.
PCT/CN2020/140016 2020-12-04 2020-12-28 Search model training method, apparatus, terminal device, and storage medium WO2022116324A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011403845.7 2020-12-04
CN202011403845.7A CN112434134B (en) 2020-12-04 2020-12-04 Search model training method, device, terminal equipment and storage medium

Publications (1)

Publication Number Publication Date
WO2022116324A1 true WO2022116324A1 (en) 2022-06-09

Family

ID=74691140

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/140016 WO2022116324A1 (en) 2020-12-04 2020-12-28 Search model training method, apparatus, terminal device, and storage medium

Country Status (2)

Country Link
CN (1) CN112434134B (en)
WO (1) WO2022116324A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117891959A (en) * 2024-03-15 2024-04-16 中国标准化研究院 Document metadata storage method and system based on Bayesian network

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113934872A (en) * 2021-10-29 2022-01-14 北京达佳互联信息技术有限公司 Search result sorting method, device, equipment and storage medium
CN117909491B (en) * 2024-03-18 2024-05-14 中国标准化研究院 Document metadata analysis method and system based on Bayesian network

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105550216A (en) * 2015-12-03 2016-05-04 百度在线网络技术(北京)有限公司 Searching method and device of academic research information and excavating method and device of academic research information
WO2017096777A1 (en) * 2015-12-07 2017-06-15 百度在线网络技术(北京)有限公司 Document normalization method, document searching method, corresponding apparatuses, device, and storage medium
CN106951420A (en) * 2016-01-06 2017-07-14 富士通株式会社 Literature search method and apparatus, author's searching method and equipment
CN108763354A (en) * 2018-05-16 2018-11-06 浙江工业大学 A kind of academic documents recommendation method of personalization
CN110807101A (en) * 2019-10-15 2020-02-18 中国科学技术信息研究所 Scientific and technical literature big data classification method
CN111581949A (en) * 2020-05-12 2020-08-25 上海市研发公共服务平台管理中心 Method and device for disambiguating name of learner, storage medium and terminal

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105550216A (en) * 2015-12-03 2016-05-04 百度在线网络技术(北京)有限公司 Searching method and device of academic research information and excavating method and device of academic research information
WO2017096777A1 (en) * 2015-12-07 2017-06-15 百度在线网络技术(北京)有限公司 Document normalization method, document searching method, corresponding apparatuses, device, and storage medium
CN106951420A (en) * 2016-01-06 2017-07-14 富士通株式会社 Literature search method and apparatus, author's searching method and equipment
CN108763354A (en) * 2018-05-16 2018-11-06 浙江工业大学 A kind of academic documents recommendation method of personalization
CN110807101A (en) * 2019-10-15 2020-02-18 中国科学技术信息研究所 Scientific and technical literature big data classification method
CN111581949A (en) * 2020-05-12 2020-08-25 上海市研发公共服务平台管理中心 Method and device for disambiguating name of learner, storage medium and terminal

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117891959A (en) * 2024-03-15 2024-04-16 中国标准化研究院 Document metadata storage method and system based on Bayesian network
CN117891959B (en) * 2024-03-15 2024-05-10 中国标准化研究院 Document metadata storage method and system based on Bayesian network

Also Published As

Publication number Publication date
CN112434134B (en) 2023-10-20
CN112434134A (en) 2021-03-02

Similar Documents

Publication Publication Date Title
CN110162593B (en) Search result processing and similarity model training method and device
CN109101479B (en) Clustering method and device for Chinese sentences
Alami et al. Unsupervised neural networks for automatic Arabic text summarization using document clustering and topic modeling
WO2022116324A1 (en) Search model training method, apparatus, terminal device, and storage medium
US20200081899A1 (en) Automated database schema matching
CN105183833B (en) Microblog text recommendation method and device based on user model
Qian et al. Social event classification via boosted multimodal supervised latent dirichlet allocation
US8694303B2 (en) Systems and methods for tuning parameters in statistical machine translation
US10482146B2 (en) Systems and methods for automatic customization of content filtering
CN108647322B (en) Method for identifying similarity of mass Web text information based on word network
CN108509521B (en) Image retrieval method for automatically generating text index
CN110569289B (en) Column data processing method, equipment and medium based on big data
D’Silva et al. Unsupervised automatic text summarization of Konkani texts using K-means with Elbow method
Papadopoulos et al. Image clustering through community detection on hybrid image similarity graphs
CN113962293A (en) LightGBM classification and representation learning-based name disambiguation method and system
CN110705247A (en) Based on x2-C text similarity calculation method
CN115203421A (en) Method, device and equipment for generating label of long text and storage medium
CN106570196B (en) Video program searching method and device
CN114298020A (en) Keyword vectorization method based on subject semantic information and application thereof
Ma et al. Chinese social media entity linking based on effective context with topic semantics
CN111723179B (en) Feedback model information retrieval method, system and medium based on conceptual diagram
CN113761125A (en) Dynamic summary determination method and device, computing equipment and computer storage medium
Qu et al. A multi-label classification algorithm based on label-specific features
Meiyu et al. Image semantic description and automatic semantic annotation
CN108345605B (en) Text search method and device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20964169

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20964169

Country of ref document: EP

Kind code of ref document: A1