CN-120873196-B - Searching method, searching device, computer equipment and storage medium
Abstract
The disclosure provides a searching method, a searching device, computer equipment and a storage medium, wherein the searching method comprises the steps of determining relevant information of candidate search words matched with a word to be searched in a preset database, wherein the word to be searched belongs to a text to be searched; according to the related information, an adaptation value corresponding to each first search mode of the word to be searched and a correlation degree value of the word to be searched and the target technical field are determined, according to the adaptation value, first search results corresponding to the word to be searched are generated, according to the adaptation value and the correlation degree value, a second search mode is determined, and based on the second search mode, second search results corresponding to the text to be searched are generated. By implementing the method disclosed by the invention, various adaptive searching modes can be reasonably invoked based on the related information of the candidate search words, so that the richness and diversity of the obtained searching results are improved to a great extent, and the searching experience of a user is further improved.
Inventors
- LV YIMENG
Assignees
- 中煤科工开采研究院有限公司
Dates
- Publication Date
- 20260508
- Application Date
- 20250618
Claims (7)
- 1. A search method, comprising: Determining related information of candidate search words matched with the word to be searched in a preset database, wherein the word to be searched belongs to a text to be searched; According to the related information, determining an adaptation value corresponding to each first searching mode of the word to be searched and a correlation degree value of the word to be searched and the target technical field; Generating a first search result corresponding to the word to be searched according to the adaptation value; determining a second searching mode according to the adaptation value and the association degree value; Generating a second search result corresponding to the text to be searched based on the second search mode; the determining, according to the related information, the adaptation value of the word to be searched and corresponding to each first searching mode includes: determining a first parameter, a second parameter, a third parameter, a fourth parameter, a fifth parameter and a sixth parameter of the to-be-searched word according to the related information, wherein the first parameter is used for indicating whether the to-be-searched word is a word in a proprietary knowledge graph in the preset database, the second parameter is used for indicating whether the to-be-searched word is a word in a proprietary knowledge graph base in the preset database, the third parameter is used for indicating information of the number of associated knowledge of the to-be-searched word in the proprietary knowledge graph base, the fourth parameter is used for indicating whether the to-be-searched word is a word in a graph attribute in the proprietary knowledge graph base, the fifth parameter is used for indicating information of the number of attribute associated knowledge of the to-be-searched word in the proprietary knowledge graph base, and the sixth parameter is used for indicating historical search frequency of the to-be-searched word in the preset database; determining a first adaptation value corresponding to the word to be searched and a pattern searching mode based on the first parameter, the second parameter, the third parameter, the fourth parameter, the fifth parameter and the sixth parameter, wherein the pattern searching mode belongs to a plurality of first searching modes; Determining a seventh parameter, an eighth parameter and a ninth parameter of the word to be searched according to the related information, wherein the seventh parameter is used for indicating whether the word to be searched is a word in a specific knowledge oriented question-answering library in a preset database, the eighth parameter is used for indicating information of the quantity of associated knowledge of the word to be searched in the specific oriented question-answering library, and the ninth parameter is used for indicating whether the word to be searched is an identifier in a large model vector library in the preset database; determining a tenth parameter according to the search requirement information, wherein the tenth parameter is used for indicating the importance degree of a large model search mode, and the large model search mode belongs to a plurality of first search modes; Determining a second adaptation value corresponding to the word to be searched and a directional question-answering mode based on the sixth parameter, the seventh parameter, the eighth parameter, the ninth parameter and the tenth parameter, wherein the directional question-answering mode belongs to a plurality of first searching modes; Determining a third adaptation value corresponding to the word to be searched and the large model searching mode based on the sixth parameter, the seventh parameter, the eighth parameter, the ninth parameter and the tenth parameter; generating a first search result corresponding to the word to be searched according to the adaptation value, wherein the first search result comprises at least one of the following items: when the first adaptation value is greater than or equal to a first preset threshold value, processing the word to be searched based on the map searching mode to obtain the first searching result; When the second adaptation value is greater than or equal to a second preset threshold value, processing the word to be searched based on the directional question-answering mode to obtain the first search result; determining the maximum value of the second adaptation value and the second preset threshold value, and processing the word to be searched based on the large model searching mode to obtain the first searching result when the third adaptation value is greater than or equal to the maximum value; the determining a second searching mode according to the adaptation value and the association degree value comprises the following steps: Evaluating the importance of the words to be searched in the expert knowledge graph to obtain a first evaluation value; Evaluating the importance of the word to be searched in the expertise oriented question-answering library to obtain a second evaluation value; determining a first product value of the first adaptation value and the first evaluation value, a second product value of the second adaptation value and the second evaluation value, and a third product value of the tenth parameter and the third adaptation value; Calculating and determining a third evaluation value of the word to be searched based on the association degree value, the first product value, the second product value and the third product value, wherein the third evaluation value is used for quantitatively evaluating whether the word to be searched needs text searching or not; Determining a first sum value of the third evaluation value corresponding to the word to be searched in the text to be searched; And determining the second searching mode according to the first sum value.
- 2. The method of claim 1, wherein the association degree value of the word to be searched and the target technical field is determined based on the following manner: according to the related information, determining eleventh parameters, twelfth parameters, thirteenth parameters, fourteenth parameters and fifteenth parameters of the to-be-searched words, wherein the eleventh parameters are used for indicating whether the to-be-searched words are words in a expertise tag library in the preset database, the twelfth parameters are used for indicating quantity information of knowledge identified by the to-be-searched words in the expertise tag library, the thirteenth parameters are used for indicating whether the to-be-searched words are words in a expertise directory library in the preset database, the fourteenth parameters are used for indicating quantity information of directory knowledge of the to-be-searched words in the expertise directory library, and the fifteenth parameters are used for indicating level information of the directory of the to-be-searched words in the expertise directory library; And determining the association degree value of the word to be searched and the target technical field based on the sixth parameter, the eleventh parameter, the twelfth parameter, the thirteenth parameter, the fourteenth parameter and the fifteenth parameter.
- 3. The method of claim 1, wherein said determining the second search pattern based on the first sum value comprises: when the first sum value is larger than zero, determining the similarity between the word to be searched and each candidate search word of the preset database; when the similarity is greater than or equal to a third preset threshold value, determining that the candidate search word is the similar search word of the word to be searched; determining second sum values of the association degree values of the similar search words and the target technical field corresponding to the words to be searched; Determining the average value of the second sum value corresponding to at least one word to be searched in the text to be searched; when the average value is larger than or equal to a fourth preset threshold value, determining that the character string matching search is used as the second search mode; And when the average value is smaller than the fourth preset threshold value, determining word segmentation searching as the second searching mode.
- 4. A search apparatus, comprising: The first determining module is used for determining related information of candidate search words matched with the to-be-searched words in a preset database, wherein the to-be-searched words belong to a to-be-searched text; The second determining module is used for determining an adaptation value corresponding to each first searching mode of the word to be searched and a correlation degree value of the word to be searched and the target technical field according to the related information; The first generation module is used for generating a first search result corresponding to the word to be searched according to the adaptation value; The third determining module is used for determining a second searching mode according to the adaptation value and the association degree value; the second generation module is used for generating a second search result corresponding to the text to be searched based on the second search mode; The second determining module is configured to determine, according to the related information, a first parameter, a second parameter, a third parameter, a fourth parameter, a fifth parameter, and a sixth parameter of the to-be-searched word, where the first parameter is used to indicate whether the to-be-searched word is a word in a proprietary knowledge graph in the preset database, the second parameter is used to indicate whether the to-be-searched word is a word in a proprietary knowledge graph base in the preset database, the third parameter is used to indicate information of a number of related knowledge of the to-be-searched word in the proprietary knowledge graph base, the fourth parameter is used to indicate whether the to-be-searched word is a word in a graph attribute in the proprietary knowledge graph base, the fifth parameter is used to indicate information of a number of related knowledge of the to-be-searched word in the proprietary knowledge graph base, and the sixth parameter is used to indicate a historical search frequency of the to-be-searched word in the preset database; determining a first adaptation value corresponding to the word to be searched and a pattern searching mode based on the first parameter, the second parameter, the third parameter, the fourth parameter, the fifth parameter and the sixth parameter, wherein the pattern searching mode belongs to a plurality of first searching modes; Determining a seventh parameter, an eighth parameter and a ninth parameter of the word to be searched according to the related information, wherein the seventh parameter is used for indicating whether the word to be searched is a word in a specific knowledge oriented question-answering library in a preset database, the eighth parameter is used for indicating information of the quantity of associated knowledge of the word to be searched in the specific oriented question-answering library, and the ninth parameter is used for indicating whether the word to be searched is an identifier in a large model vector library in the preset database; determining a tenth parameter according to the search requirement information, wherein the tenth parameter is used for indicating the importance degree of a large model search mode, and the large model search mode belongs to a plurality of first search modes; Determining a second adaptation value corresponding to the word to be searched and a directional question-answering mode based on the sixth parameter, the seventh parameter, the eighth parameter, the ninth parameter and the tenth parameter, wherein the directional question-answering mode belongs to a plurality of first searching modes; Determining a third adaptation value corresponding to the word to be searched and the large model searching mode based on the sixth parameter, the seventh parameter, the eighth parameter, the ninth parameter and the tenth parameter; the first generating module is configured to process the word to be searched based on the pattern searching manner to obtain the first search result when the first adaptation value is greater than or equal to a first preset threshold; When the second adaptation value is greater than or equal to a second preset threshold value, processing the word to be searched based on the directional question-answering mode to obtain the first search result; determining the maximum value of the second adaptation value and the second preset threshold value, and processing the word to be searched based on the large model searching mode to obtain the first searching result when the third adaptation value is greater than or equal to the maximum value; The third determining module is configured to evaluate importance of the word to be searched in the expert knowledge graph to obtain a first evaluation value; Evaluating the importance of the word to be searched in the expertise oriented question-answering library to obtain a second evaluation value; determining a first product value of the first adaptation value and the first evaluation value, a second product value of the second adaptation value and the second evaluation value, and a third product value of the tenth parameter and the third adaptation value; Calculating and determining a third evaluation value of the word to be searched based on the association degree value, the first product value, the second product value and the third product value, wherein the third evaluation value is used for quantitatively evaluating whether the word to be searched needs text searching or not; Determining a first sum value of the third evaluation value corresponding to the word to be searched in the text to be searched; And determining the second searching mode according to the first sum value.
- 5. A computer device, comprising: At least one processor, and A memory communicatively coupled to the at least one processor, wherein, The memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-3.
- 6. A non-transitory computer readable storage medium storing computer instructions, wherein the computer instructions are for causing the computer to perform the method of any one of claims 1-3.
- 7. A computer program product comprising a computer program which, when executed by a processor, implements the steps of the method according to any of claims 1-3.
Description
Searching method, searching device, computer equipment and storage medium Technical Field The disclosure relates to the field of computer technology, and in particular relates to a searching method, a searching device, computer equipment and a storage medium. Background With the rapid development of informatization technology, knowledge base application and management systems have become important tools for academic research and technical development, and thus many companies have developed exploitation knowledge service platforms. The exploitation knowledge service platform stores a large number of research reports, technical documents and data materials, and provides a convenient resource sharing and knowledge management platform for scientific researchers. The documents in the knowledge base management system contain a large amount of original research results and technical data, and various technologies such as text search, atlas search, directed question and answer, large models and the like are provided for providing corresponding results. In the related art, a user of the system often cannot obtain a desired accurate result during searching, and the searching experience of the user is affected. Disclosure of Invention The present disclosure aims to solve, at least to some extent, one of the technical problems in the related art. Therefore, an object of the present disclosure is to provide a search method, apparatus, computer device, and storage medium, which can reasonably call various adaptive search modes based on related information of candidate search terms, thereby improving the richness and diversity of the obtained search results to a greater extent, and further improving the user search experience. To achieve the above object, a search method provided by an embodiment of a first aspect of the present disclosure includes: Determining related information of candidate search words matched with the word to be searched in a preset database, wherein the word to be searched belongs to a text to be searched; According to the related information, determining an adaptation value corresponding to each first searching mode of the word to be searched and a correlation degree value of the word to be searched and the target technical field; Generating a first search result corresponding to the word to be searched according to the adaptation value; determining a second searching mode according to the adaptation value and the association degree value; and generating a second search result corresponding to the text to be searched based on the second search mode. To achieve the above object, a search device according to an embodiment of a second aspect of the present disclosure includes: The first determining module is used for determining related information of candidate search words matched with the to-be-searched words in a preset database, wherein the to-be-searched words belong to a to-be-searched text; The second determining module is used for determining an adaptation value corresponding to each first searching mode of the word to be searched and a correlation degree value of the word to be searched and the target technical field according to the related information; The first generation module is used for generating a first search result corresponding to the word to be searched according to the adaptation value; The third determining module is used for determining a second searching mode according to the adaptation value and the association degree value; And the second generation module is used for generating a second search result corresponding to the text to be searched based on the second search mode. The computer device provided by the embodiment of the third aspect of the disclosure comprises a memory, a processor and a computer program stored on the memory and capable of running on the processor, wherein the processor realizes the searching method provided by the embodiment of the first aspect of the disclosure when executing the program. An embodiment of a fourth aspect of the present disclosure proposes a non-transitory computer-readable storage medium, on which a computer program is stored, which when executed by a processor implements a search method as proposed by an embodiment of the first aspect of the present disclosure. An embodiment of a fifth aspect of the present disclosure proposes a computer program product which, when executed by a processor, performs a search method as proposed by an embodiment of the first aspect of the present disclosure. The searching method, the searching device, the computer equipment and the storage medium are characterized by determining relevant information of candidate search words matched with the to-be-searched words in a preset database, wherein the to-be-searched words belong to-be-searched texts, determining an adaptation value corresponding to each first search mode of the to-be-searched words and a correlation degree value of the to-be-searched words