TWI507897B - Search methods and devices - Google Patents

Search methods and devices Download PDF

Info

Publication number
TWI507897B
TWI507897B TW099115483A TW99115483A TWI507897B TW I507897 B TWI507897 B TW I507897B TW 099115483 A TW099115483 A TW 099115483A TW 99115483 A TW99115483 A TW 99115483A TW I507897 B TWI507897 B TW I507897B
Authority
TW
Taiwan
Prior art keywords
execution
module
search
result
execution module
Prior art date
Application number
TW099115483A
Other languages
Chinese (zh)
Other versions
TW201140344A (en
Original Assignee
Alibaba Group Holding Ltd
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 Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to TW099115483A priority Critical patent/TWI507897B/en
Publication of TW201140344A publication Critical patent/TW201140344A/en
Application granted granted Critical
Publication of TWI507897B publication Critical patent/TWI507897B/en

Links

Description

搜尋方法和裝置Search method and device

本案關於網路技術領域,特別是關於一種搜尋方法和裝置。This case is about the field of network technology, especially about a search method and device.

隨著電腦技術和網路技術的高速發展,以及近年來國內網際網路環境的改善,網際網路逐漸成為一種獲取資訊的重要管道,而網上資訊也得到了爆炸性的增長。搜尋技術的出現為網路用戶快速找到所需資訊提供了便捷的手段,傳統的搜尋方法主要使用三種類型的搜尋引擎,即機器人搜尋引擎(Robot)、目錄式搜尋引擎(Directory or Catalog)和元搜尋引擎(Meta)。傳統的搜尋方法主要採用關鍵字匹配來實現對資訊的檢索,由於用戶很難簡單地用關鍵字或關鍵字串來忠實地表達真正需要檢索的內容,表達困難導致檢索困難,而且自然語言隨著時間、地域或領域的改變,同一概念可以用不同的語言表現形式來表達,對同一概念的檢索,不同的用戶可能使用不同的關鍵字查詢,結果導致大量的無關資訊返回用戶。With the rapid development of computer technology and network technology, and the improvement of the domestic Internet environment in recent years, the Internet has gradually become an important channel for obtaining information, and online information has also experienced explosive growth. The emergence of search technology provides a convenient means for Internet users to quickly find the information they need. The traditional search method mainly uses three types of search engines, namely, robot search engine (Robot), directory search engine (Directory or Catalog) and Meta Search Engine (Meta). The traditional search method mainly uses keyword matching to realize the retrieval of information. Because it is difficult for users to simply use keywords or keyword strings to faithfully express the content that really needs to be retrieved, the difficulty of expression leads to difficulty in searching, and the natural language The change of time, region or domain, the same concept can be expressed in different language expressions. For the same concept retrieval, different users may use different keyword queries, resulting in a large amount of irrelevant information returning to the user.

為解決上述問題,業內出現了以智慧搜尋方法為基礎的智慧搜尋引擎,採取以知識庫為基礎的語義分析技術,利用分詞技術、短語識別、處理同義詞等手段,根據特徵對用戶輸入的搜尋參數進行分析,產生不同的搜尋方案,即搜尋計畫。其中,用戶輸入的搜尋參數可以是具有一定特徵的辭彙,可以是音譯詞或同音詞。如果用戶輸錯了搜尋參數,例如,用戶錯誤地將“諾基亞”輸入成“諾記亞”,系統平臺可以對錯詞進行分析,自動推薦出用“諾基亞”進行搜尋的方案,該搜尋方案即為對應用戶輸入的搜尋參數的一個搜尋計畫。另外,當用戶過於口語化的描述“我要採購手機”時,實際上搜尋的是“手機”,因此,搜尋引擎可以僅保留“手機”作為搜尋計畫。上述兩種產生搜尋計畫的方案,可以在搜尋引擎中分別透過拼寫糾錯模組和重寫模組實現。其中,拼寫糾錯模組可以將錯誤的輸入詞改變成正確的輸入詞;重寫模組可以進行輸入詞分詞,找出中心詞等,改寫成適合搜尋應用的詞。In order to solve the above problems, a smart search engine based on the smart search method has appeared in the industry. The knowledge base-based semantic analysis technology is used, and word-of-word technology, phrase recognition, and synonym are used to search for user input according to features. The parameters are analyzed to produce different search scenarios, ie search plans. The search parameter input by the user may be a vocabulary with certain characteristics, and may be a transliteration word or a homophone. If the user enters the wrong search parameter, for example, the user mistakenly inputs "Nokia" into "Nuo Ke Ya", the system platform can analyze the wrong word and automatically recommend the "Nokia" search scheme, the search scheme is A search plan for the search parameters entered by the user. In addition, when the user is too colloquial to describe "I want to purchase a mobile phone", the user actually searches for "mobile phone", so the search engine can only keep the "mobile phone" as a search plan. The above two schemes for generating a search plan can be implemented in the search engine through a spelling correction module and a rewrite module, respectively. Among them, the spelling correction module can change the wrong input word into the correct input word; the rewriting module can input the word segmentation, find the center word, etc., and rewrite it into a word suitable for searching for the application.

現有技術中,通常採用動態載入模組的方式產生搜尋計畫。具體地,在現有的開源服務平臺,例如Apache伺服器,可以透過寫C代碼實現動態擴展模組。其中,Apache伺服器是一個回應HTTP(Hyper Text Transfer Protocol,超文本傳輸協定)請求的web伺服器,用於回應最基本的web服務。在Apache伺服器上動態載入模組時,首先需要充分瞭解Apache伺服器的運行機制,或是編寫PHP(Hypertext Preprocessor,超級文本預處理語言)模組,利用PHP模組對Apache介面進行再次封裝,將PHP模組編譯後動態裝載到Apache伺服器中提供服務。上述動態載入模組採用普通的責任鏈模式的設計,一旦模組的任務完成,則立即退出應用。In the prior art, a search program is usually generated by using a dynamic loading module. Specifically, in an existing open source service platform, such as an Apache server, a dynamic expansion module can be implemented by writing C code. Among them, the Apache server is a web server that responds to HTTP (Hyper Text Transfer Protocol) requests to respond to the most basic web services. When dynamically loading a module on an Apache server, you first need to fully understand the operating mechanism of the Apache server, or write a PHP (Hypertext Preprocessor) module to repackage the Apache interface with a PHP module. The PHP module is compiled and dynamically loaded into the Apache server to provide services. The above dynamic loading module adopts the design of the ordinary responsibility chain mode, and once the task of the module is completed, the application is immediately exited.

在實現本案的過程中,發明人發現現有技術至少存在如下問題:由於Apache伺服器本身的設計過於複雜,實現Apache動態模組會直接導致實現模組成本很高,增加了維護的難度。另外,模組之間無法協調工作,也不能對模組的編寫進行統一控制。當出現衝突的Apache模組時,如果直接提高對模組的編寫要求,則在新增模組時需要修改以前的模組,當模組數量較多時,成本會很大,會降低模組的擴展性;如果透過使用PHP模組擴展,又會增加依賴性和維護的難度。In the process of implementing the present case, the inventor found that at least the following problems exist in the prior art: because the design of the Apache server itself is too complicated, implementing the Apache dynamic module directly leads to high module cost and increased maintenance difficulty. In addition, there is no coordination between the modules, and the module cannot be uniformly controlled. When there is a conflicting Apache module, if you directly improve the programming requirements of the module, you need to modify the previous module when adding new modules. When the number of modules is large, the cost will be large, and the module will be reduced. Scalability; if you use PHP module extensions, it will increase the difficulty of dependency and maintenance.

本案提供了一種搜尋方法和裝置,能夠更快地獲取搜尋詞,方便了對執行模組的管理。This case provides a search method and device, which can acquire search terms more quickly and facilitate the management of the execution module.

本案提出一種搜尋方法,包括以下步驟:獲取用戶端輸入的搜尋參數,根據預先配置的或者該用戶端選擇的搜尋標籤確定處理該搜尋參數的執行序列;按照該執行序列依次調用該執行序列對應的執行模組,獲取該執行模組對該搜尋參數的輸出結果,根據該執行模組的輸出結果的精確度等級產生搜尋計畫,該搜尋計畫包括處理該搜尋參數的執行模組;使用該搜尋計畫確定的執行模組處理該搜尋參數,獲取該確定的執行模組的執行結果,並按照該執行結果進行搜尋,獲取搜尋結果。The present invention provides a search method, which includes the following steps: acquiring a search parameter input by a user terminal, determining an execution sequence for processing the search parameter according to a pre-configured or search tag selected by the user terminal; and sequentially calling the execution sequence corresponding to the execution sequence according to the execution sequence Executing a module, obtaining an output result of the execution module for the search parameter, and generating a search plan according to an accuracy level of an output result of the execution module, where the search plan includes an execution module for processing the search parameter; The execution module determined by the search plan processes the search parameter, obtains the execution result of the determined execution module, and performs a search according to the execution result to obtain the search result.

較佳地,該根據該執行模組的輸出結果的精確度等級產生搜尋計畫,具體包括:判斷該執行模組的輸出結果的精確度等級是否滿足第一精確度要求,如果滿足,則確定由該執行模組處理該搜尋參數。Preferably, the generating the search plan according to the accuracy level of the output result of the execution module comprises: determining whether the accuracy level of the output result of the execution module satisfies the first accuracy requirement, and if so, determining The search parameter is processed by the execution module.

較佳地,該判斷執行模組的輸出結果的精確度等級滿足精確度要求之後,還包括:判斷該滿足第一精確度要求的執行模組之間是否互相衝突,如果互相衝突,則由該互相衝突的執行模組中輸出結果的精確度等級最高的執行模組處理該搜尋參數。Preferably, after determining that the accuracy level of the output result of the execution module meets the accuracy requirement, the method further includes: determining whether the execution modules satisfying the first accuracy requirement conflict with each other, and if they conflict with each other, The execution module having the highest accuracy level of the output result in the conflicting execution module processes the search parameter.

較佳地,該判斷滿足精確度要求的執行模組之間是否互相衝突,具體包括:判斷該滿足第一精確度要求的執行模組中是否存在至少兩個包含在預定義的衝突序列中的執行模組;如果存在,則判斷該滿足第一精確度要求的執行模組之間互相衝突;如果不存在,則判斷該滿足第一精確度要求的執行模組之間不互相衝突。Preferably, the determining whether the execution modules satisfying the accuracy requirement conflict with each other comprises: determining whether at least two execution modules in the execution module that meet the first accuracy requirement are included in the predefined conflict sequence. Executing the module; if present, determining that the execution modules satisfying the first accuracy requirement conflict with each other; if not, determining that the execution modules satisfying the first accuracy requirement do not conflict with each other.

較佳地,該執行模組的輸出結果還包括該執行模組的執行結果,當該執行模組的輸出結果滿足第二精確度要求且該搜尋參數滿足預設的複雜度要求時,按照該執行模組的執行結果進行搜尋,獲取搜尋結果。Preferably, the output result of the execution module further includes an execution result of the execution module. When the output result of the execution module meets the second accuracy requirement and the search parameter meets the preset complexity requirement, according to the Execute the execution result of the module to search and obtain the search result.

較佳地,該執行模組的輸出結果包括該執行模組的執行結果時,該獲取執行模組對該搜尋參數的輸出結果之後,還包括:將該執行模組的輸出結果中的執行結果通知該執行序列中的後續執行模組,使該後續執行模組根據該執行模組的執行結果產生輸出結果。Preferably, after the output result of the execution module includes the execution result of the execution module, after the output of the search parameter is obtained by the execution module, the method further includes: executing the result in the output result of the execution module The subsequent execution module in the execution sequence is notified, so that the subsequent execution module generates an output result according to the execution result of the execution module.

較佳地,該的方法,還包括:為該執行序列中的各個執行模組設置統一的介面,透過該介面為該各個執行模組的輸出結果設置統一的精確度等級。Preferably, the method further includes: setting a unified interface for each execution module in the execution sequence, and setting a uniform accuracy level for outputting the execution modules through the interface.

本案還提出一種搜尋裝置,包括:獲取模組,用於獲取用戶端輸入的搜尋參數,根據預先配置的或者該用戶端選擇的搜尋標籤確定處理該搜尋參數的執行序列;調用模組,用於按照該獲取模組確定的執行序列依次調用該執行序列對應的執行模組,獲取該執行模組對該搜尋參數的輸出結果,根據該執行模組的輸出結果的精確度等級產生搜尋計畫,該搜尋計畫包括處理該搜尋參數的執行模組;搜尋模組,用於使用該調用模組產生的搜尋計畫確定的執行模組處理該搜尋參數,獲取該確定的執行模組的執行結果,並按照該執行結果進行搜尋,獲取搜尋結果。The present invention also provides a search device, comprising: an acquisition module, configured to acquire a search parameter input by a user terminal, and determine an execution sequence for processing the search parameter according to a pre-configured or search tag selected by the user terminal; The execution module corresponding to the execution sequence is sequentially invoked according to the execution sequence determined by the acquisition module, and the output result of the execution module is obtained, and the search plan is generated according to the accuracy level of the output result of the execution module. The search plan includes an execution module for processing the search parameter, and a search module for processing the search parameter by using an execution module determined by the search plan generated by the call module to obtain an execution result of the determined execution module. And search according to the execution result to obtain search results.

較佳地,該調用模組,具體用於判斷該執行模組的輸出結果的精確度等級是否滿足第一精確度要求,如果滿足,則確定由該執行模組處理該搜尋參數。Preferably, the calling module is specifically configured to determine whether the accuracy level of the output result of the execution module satisfies the first accuracy requirement, and if so, determine that the search parameter is processed by the execution module.

較佳地,該調用模組,還用於判斷該滿足第一精確度要求的執行模組之間是否互相衝突,如果互相衝突,則由該互相衝突的執行模組中輸出結果的精確度等級最高的執行模組處理該搜尋參數。Preferably, the calling module is further configured to determine whether the execution modules satisfying the first accuracy requirement conflict with each other, and if they conflict with each other, the accuracy level of the output result by the conflicting execution modules The highest execution module processes the search parameters.

較佳地,該調用模組,具體用於判斷該滿足第一精確度要求的執行模組中是否存在至少兩個包含在預定義的衝突序列中的執行模組;如果存在,則判斷該滿足第一精確度要求的執行模組之間互相衝突;如果不存在,則判斷該滿足第一精確度要求的執行模組之間不互相衝突。Preferably, the calling module is specifically configured to determine whether there are at least two execution modules included in the predefined conflict sequence in the execution module that meet the first accuracy requirement; if yes, determine that the The execution modules of the first accuracy requirement conflict with each other; if not, it is determined that the execution modules satisfying the first accuracy requirement do not conflict with each other.

較佳地,該執行模組的輸出結果還包括該執行模組的執行結果,該搜尋模組,還用於在該執行模組的輸出結果滿足第二精確度要求且該搜尋參數滿足預設的複雜度要求時,按照該執行模組的執行結果進行搜尋,獲取搜尋結果。Preferably, the output of the execution module further includes an execution result of the execution module, and the search module is further configured to: the output result of the execution module meets a second accuracy requirement and the search parameter meets a preset When the complexity is required, the search result is performed according to the execution result of the execution module, and the search result is obtained.

較佳地,該執行模組的輸出結果包括該執行模組的執行結果時,該調用模組,還用於將該執行模組的輸出結果中的執行結果通知該執行序列中的後續執行模組,使該後續執行模組根據該執行模組的執行結果產生輸出結果。Preferably, when the output result of the execution module includes the execution result of the execution module, the calling module is further configured to notify the execution result in the output result of the execution module to the subsequent execution mode in the execution sequence. The group is configured to generate an output result according to the execution result of the execution module.

較佳地,該的裝置,還包括:設置模組,用於為該執行序列中的各個執行模組設置統一的介面,透過該介面為該各個執行模組的輸出結果設置統一的精確度等級,供該調用模組使用。Preferably, the device further includes: a setting module, configured to set a unified interface for each execution module in the execution sequence, and set a uniform accuracy level for outputting the execution modules through the interface. For use by the calling module.

本案包括以下優點,根據執行模組的執行結果的精確度對可能衝突的執行模組進行協調,方便了對執行模組的管理,在不改變原有的執行模組的前提下,能夠輸出更優的搜尋詞。另外,對執行模組的調用採用獨立的服務,不影響搜尋引擎核心查詢服務的穩定性,且執行模組可以進行分佈部署,不與搜尋引擎服務綁定,也不與搜尋引擎競爭伺服器資源,對伺服器產生的壓力小,處理速度快。當然,實施本案的任一產品並不一定需要同時達到以上所述的所有優點。The present invention includes the following advantages: the execution module of the conflicting execution module is coordinated according to the accuracy of the execution result of the execution module, and the management of the execution module is facilitated, and the output module can be output without changing the original execution module. Excellent search term. In addition, the execution of the module is independent, does not affect the stability of the search engine core query service, and the execution module can be distributed, not bound to the search engine service, or compete with the search engine for server resources. The pressure generated on the server is small and the processing speed is fast. Of course, implementing any of the products of the present invention does not necessarily require all of the advantages described above to be achieved at the same time.

本案的主要思想包括,使用獨立的平臺統一控制搜尋詞的產生,按照統一的介面管理同一執行序列中的多個執行模組,根據各個執行模組的輸出結果的精確度等級確定處理搜尋參數的執行模組,並根據該確定的執行模組的執行結果,使用搜尋引擎進行搜尋,並獲取搜尋結果。例如,當系統同時選擇拼寫糾錯模組和重寫模組處理搜尋參數時,當拼寫糾錯模組和重寫模組的輸出結果均滿足執行序列對應的精確度要求時,則搜尋計畫中包括拼寫糾錯模組和重寫模組,可以獲取拼寫糾錯模組和重寫模組的執行結果以及搜尋引擎對該執行結果的搜尋結果;如果拼寫糾錯模組和重寫模組互相衝突,則根據拼寫糾錯模組和重寫模組的輸出結果的精確度等級確定保留在搜尋計畫中的執行模組。The main idea of this case includes using an independent platform to uniformly control the generation of search terms, managing multiple execution modules in the same execution sequence according to a unified interface, and determining the processing search parameters according to the accuracy level of the output results of each execution module. The module is executed, and based on the determined execution result of the execution module, the search engine is used to search and obtain the search result. For example, when the system selects the spelling correction module and the rewriting module to process the search parameters at the same time, when the output of the spelling error correction module and the rewriting module meets the accuracy requirements of the execution sequence, the search plan is searched. The spelling correction module and the rewriting module can be used to obtain the execution result of the spelling correction module and the rewriting module, and the search result of the search engine for the execution result; if the spelling correction module and the rewriting module In conflict with each other, the execution module retained in the search plan is determined according to the accuracy level of the output of the spelling correction module and the rewriting module.

其中,執行模組的輸出結果可以是對是否需要使用該執行模組處理搜尋參數的判斷結果,包括“是”和“否”;也可以是該執行模組對搜尋參數的處理結果,即執行模組的執行結果。系統可以設定對執行模組的輸出結果的精確度要求,當執行模組的輸出結果滿足預設的精確度要求時,則執行該執行模組,獲取該執行模組的執行結果。The output result of the execution module may be a judgment result of whether the execution module needs to be used to process the search parameter, including “Yes” and “No”; or may be the processing result of the execution module on the search parameter, that is, execution The execution result of the module. The system can set an accuracy requirement for the output result of the execution module. When the output result of the execution module meets the preset accuracy requirement, the execution module is executed to obtain the execution result of the execution module.

另外,為便於比較不同執行模組的輸出結果的精確度,系統可以為各個執行模組的輸出結果設置統一的精確度等級。將執行模組的輸出結果以及該輸出結果對應的搜尋參數作為精確度演算法的計算因數,進行精確度計算,可以獲取執行模組的輸出結果的精確度等級。其中,精確度等級用於表徵執行模組處理搜尋參數的適合程度。In addition, in order to facilitate the comparison of the accuracy of the output results of different execution modules, the system can set a uniform accuracy level for the output of each execution module. The output result of the execution module and the search parameter corresponding to the output result are used as the calculation factors of the accuracy algorithm, and the accuracy calculation is performed, and the accuracy level of the output result of the execution module can be obtained. The accuracy level is used to characterize the suitability of the execution module to process the search parameters.

此外,系統還可以為執行序列設置精確度要求,透過比較該精確度要求與執行模組的輸出結果的精確度等級之間的關係,判斷執行序列對應的各個執行模組的輸出結果是否滿足要求。如果執行模組的輸出結果的精確度等級大於執行序列對應的精確度要求,則判斷該執行模組的輸出結果滿足執行序列對應的精確度要求;否則,則判斷該執行模組的輸出結果不滿足執行序列對應的精確度要求。In addition, the system can also set an accuracy requirement for the execution sequence, and by comparing the relationship between the accuracy requirement and the accuracy level of the output result of the execution module, determine whether the output result of each execution module corresponding to the execution sequence satisfies the requirement. . If the accuracy level of the output result of the execution module is greater than the accuracy requirement corresponding to the execution sequence, it is determined that the output result of the execution module satisfies the accuracy requirement corresponding to the execution sequence; otherwise, the output result of the execution module is not determined Meet the accuracy requirements of the execution sequence.

下面將結合本案中的附圖,對本案中的技術方案進行清楚、完整的描述,顯然,所描述的實施例是本案的一部分實施例,而不是全部的實施例。基於本案中的實施例,本領域普通技術人員在沒有作出創造性勞動的前提下所獲得的所有其他實施例,都屬於本案保護的範圍。The technical solutions in the present invention will be clearly and completely described in the following with reference to the drawings in the present invention. It is obvious that the described embodiments are a part of the embodiments of the present invention, and not all of the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by those skilled in the art without creative efforts are within the scope of the present disclosure.

如圖1所示,為本案實施例一中的一種搜尋方法流程圖,包括以下步驟:As shown in FIG. 1 , a flowchart of a search method in the first embodiment of the present invention includes the following steps:

步驟101,獲取用戶端輸入的搜尋參數,根據預先配置的或者該用戶端選擇的搜尋標籤確定處理搜尋參數的執行序列。Step 101: Acquire a search parameter input by the user end, and determine an execution sequence of processing the search parameter according to a pre-configured or search tag selected by the user end.

其中,搜尋標籤為用戶端輸入的搜尋參數對應的搜尋結果的類別,可以包括“產品”、“資訊”、“技術”和“全部”等類別。用戶端可以根據用戶需求選擇搜尋標籤,當用戶端沒有選擇搜尋標籤時,系統可以使用預先配置的搜尋標籤,即“全部”的搜尋標籤。The search tag is a category of the search result corresponding to the search parameter input by the user, and may include categories such as “product”, “information”, “technology”, and “all”. The user can select the search tag according to the user's needs. When the user does not select the search tag, the system can use the pre-configured search tag, that is, the "all" search tag.

不同的搜尋標籤對應不同的執行序列,執行序列為系統預先設定的包含一個或多個執行模組的封裝包,執行序列中的執行模組可以是自定義的模組。系統可以定義包含部分執行模組的執行序列,透過該執行序列對執行模組進行選擇執行;也可以將執行序列默認配置為全部的執行模組。系統設定的各個執行序列可以對用戶端輸入的搜尋參數進行不同的處理,對應不同的處理功能和對輸出結果的精確度要求。用戶端可以根據用戶的需求,選擇對應所需處理功能對應的搜尋標籤,並輸入待處理的搜尋參數,系統以及該搜尋標籤確定處理該搜尋參數的執行序列。Different search tags correspond to different execution sequences, and the execution sequence is a package package of one or more execution modules preset by the system, and the execution module in the execution sequence may be a customized module. The system may define an execution sequence including a part of the execution module, and perform execution selection on the execution module through the execution sequence; or configure the execution sequence as a default execution module by default. Each execution sequence set by the system can perform different processing on the search parameters input by the user end, corresponding to different processing functions and accuracy requirements on the output results. The user terminal may select a search tag corresponding to the required processing function according to the user's needs, and input the search parameter to be processed, and the system and the search tag determine an execution sequence for processing the search parameter.

步驟102,按照執行序列依次調用執行序列對應的執行模組,獲取該執行模組對該搜尋參數的輸出結果,根據執行模組的輸出結果的精確度等級產生搜尋計畫。Step 102: sequentially execute an execution module corresponding to the execution sequence according to the execution sequence, obtain an output result of the execution module for the search parameter, and generate a search plan according to an accuracy level of the output result of the execution module.

其中,搜尋計畫可以包括處理搜尋參數的執行模組,還可以執行模組對搜尋參數的處理策略。The search plan may include an execution module that processes the search parameters, and may also execute a processing strategy of the module for the search parameters.

具體地,可以為該執行序列中的各個執行模組設置統一的介面,透過該介面為該各個執行模組的輸出結果設置統一的精確度等級。系統可以判斷該執行模組的輸出結果的精確度等級是否滿足第一精確度要求,如果滿足,則確定由該執行模組處理該搜尋參數,即該執行模組包括在搜尋計畫中。Specifically, a unified interface may be set for each execution module in the execution sequence, and a uniform accuracy level is set for the output result of each execution module through the interface. The system can determine whether the accuracy level of the output result of the execution module satisfies the first accuracy requirement, and if so, determine that the search module processes the search parameter, that is, the execution module is included in the search plan.

當判斷執行模組的輸出結果的精確度等級滿足精確度要求之後,還可以判斷該滿足第一精確度要求的執行模組之間是否互相衝突,如果互相衝突,則由該互相衝突的執行模組中輸出結果的精確度等級最高的執行模組處理該搜尋參數,即在搜尋計畫中僅保留該互相衝突的執行模組中輸出結果的精確度等級最高的執行模組。After determining that the accuracy level of the output result of the execution module satisfies the accuracy requirement, it may also be determined whether the execution modules satisfying the first accuracy requirement conflict with each other, and if they conflict with each other, the conflicting execution modes are The execution module with the highest accuracy level of the output result in the group processes the search parameter, that is, only the execution module with the highest accuracy level of the output result in the conflicting execution module is retained in the search plan.

上述判斷滿足精確度要求的執行模組之間是否互相衝突,具體包括:判斷該滿足第一精確度要求的執行模組中是否存在至少兩個包含在預定義的衝突序列中的執行模組;如果存在,則判斷該滿足第一精確度要求的執行模組之間互相衝突;如果不存在,則判斷該滿足第一精確度要求的執行模組之間不互相衝突。The determining whether the execution modules satisfying the accuracy requirement conflict with each other may include: determining whether there are at least two execution modules included in the predefined conflict sequence in the execution module that meets the first accuracy requirement; If yes, it is determined that the execution modules satisfying the first accuracy requirement conflict with each other; if not, it is determined that the execution modules satisfying the first accuracy requirement do not conflict with each other.

該執行模組的輸出結果還可以包括該執行模組的執行結果,當該執行模組的輸出結果滿足第二精確度要求且該搜尋參數滿足預設的複雜度要求時,按照該執行模組的執行結果進行搜尋,獲取搜尋結果。上述第二精確度要求高於第一精確度要求。The output result of the execution module may further include an execution result of the execution module. When the output result of the execution module meets the second accuracy requirement and the search parameter meets a preset complexity requirement, the execution module is followed. The results of the execution are searched to obtain search results. The second accuracy requirement above is higher than the first accuracy requirement.

其中,執行模組對搜尋參數的執行結果可以為該執行模組修正後的搜尋參數。例如,當執行模組為拼寫糾錯模組、搜尋參數為“諾記亞”時,拼寫糾錯模組的執行結果為修正後的搜尋參數,即“諾基亞”;當執行模組為重寫模組、搜尋參數為“我要採購手機”時,重寫模組的執行結果為修正後的搜尋參數,即“手機”。當執行模組的輸出結果包括該執行模組的執行結果時,上述獲取執行模組對該搜尋參數的輸出結果之後,還可以將該執行模組的輸出結果中的執行結果通知該執行序列中的後續執行模組,使該後續執行模組根據該執行模組的執行結果產生輸出結果。The execution result of the execution module on the search parameter may be a search parameter corrected by the execution module. For example, when the execution module is a spelling correction module and the search parameter is “Nuo Ke Ya”, the execution result of the spelling correction module is the corrected search parameter, ie “Nokia”; when the execution module is rewritten When the module and the search parameter are "I want to purchase a mobile phone", the execution result of the rewrite module is the corrected search parameter, that is, "mobile phone". When the output result of the execution module includes the execution result of the execution module, after obtaining the output result of the search parameter by the execution module, the execution result in the output result of the execution module may be notified to the execution sequence. The subsequent execution module causes the subsequent execution module to generate an output result according to the execution result of the execution module.

步驟103,使用搜尋計畫確定的執行模組處理搜尋參數,獲取該確定的執行模組的執行結果,並按照該執行結果進行搜尋,獲取搜尋結果。Step 103: The search module determined by the search plan processes the search parameter, obtains the execution result of the determined execution module, and performs a search according to the execution result to obtain the search result.

具體地,可以使用搜尋計畫中的各個執行模組分別處理搜尋參數,獲取各個執行模組的執行結果,並判斷執行結果的個數是否大於指定輸出個數;如果該執行結果的個數大於該指定輸出個數,則將該保留的執行結果中精確度等級最高的執行結果作為搜尋詞發送到搜尋引擎,透過搜尋引擎獲取搜尋結果。Specifically, each execution module in the search plan may separately process the search parameters, obtain the execution result of each execution module, and determine whether the number of execution results is greater than the specified output number; if the number of execution results is greater than The designated output number is sent to the search engine as the search term, and the search result is obtained by the search engine.

此外,在將執行模組的執行結果發送到搜尋引擎進行搜尋的同時,系統還可以將執行模組的執行結果返回給用戶端,供用戶端使用。系統也可以將執行模組的執行結果僅返回給用戶端,而不再發送給搜尋引擎,以減輕搜尋引擎的壓力。例如,執行模組為違禁詞的過濾模組時,可以將執行結果直接返回給用戶端,而不再根據執行結果進行搜尋。In addition, while the execution result of the execution module is sent to the search engine for searching, the system may also return the execution result of the execution module to the client for use by the user. The system can also return the execution result of the execution module to the client only, and no longer send it to the search engine to reduce the pressure on the search engine. For example, when the execution module is a filter module for the prohibited word, the execution result can be directly returned to the client without searching according to the execution result.

本案包括以下優點,根據執行模組的執行結果的精確度對可能衝突的執行模組進行協調,能夠更加快速準確地獲取搜尋參數背後的用戶意圖並將用戶意圖轉換為搜尋引擎能夠理解的機器語言和執行策略,方便了對執行模組的管理,在不改變原有的執行模組的前提下,能夠輸出更優的搜尋詞。另外,對執行模組的調用採用獨立的服務,不影響搜尋引擎核心查詢服務的穩定性,且執行模組可以進行分佈部署,不與搜尋引擎服務綁定,也不與搜尋引擎競爭伺服器資源,對伺服器產生的壓力小,處理速度快。當然,實施本案的任一產品並不一定需要同時達到以上所述的所有優點。The present invention includes the following advantages: coordinate the execution modules that may conflict according to the accuracy of the execution result of the execution module, and can obtain the user intention behind the search parameters more quickly and accurately and convert the user intention into a machine language that the search engine can understand. And the execution strategy facilitates the management of the execution module, and can output better search terms without changing the original execution module. In addition, the execution of the module is independent, does not affect the stability of the search engine core query service, and the execution module can be distributed, not bound to the search engine service, or compete with the search engine for server resources. The pressure generated on the server is small and the processing speed is fast. Of course, implementing any of the products of the present invention does not necessarily require all of the advantages described above to be achieved at the same time.

本案中的搜尋方法,可應用於如圖2所示的系統架構中,該系統包括用戶端、參數處理伺服器和搜尋引擎伺服器,其中,用戶端用於向參數處理伺服器發送搜尋請求,輸入搜尋參數並選擇參數處理伺服器預先設定的搜尋標籤;參數處理伺服器根據用戶端選擇的執行序列調用該執行序列對應的執行模組,獲取執行模組對搜尋參數的輸出結果,當執行模組的輸出結果滿足執行序列對應的精確度要求時,將該執行模組的執行結果發送到搜尋引擎伺服器和用戶端;搜尋引擎伺服器將來自參數處理伺服器的執行結果作為搜尋詞,對搜尋詞進行搜尋,獲取搜尋結果。The search method in the present case can be applied to the system architecture shown in FIG. 2, the system includes a client, a parameter processing server, and a search engine server, wherein the client is used to send a search request to the parameter processing server. Enter a search parameter and select a search tag preset by the parameter processing server; the parameter processing server invokes an execution module corresponding to the execution sequence according to an execution sequence selected by the user terminal, and obtains an output result of the execution module on the search parameter, when the execution mode is performed When the output result of the group satisfies the accuracy requirement corresponding to the execution sequence, the execution result of the execution module is sent to the search engine server and the client; the search engine server uses the execution result from the parameter processing server as a search term, Search for words to search for results.

具體地,參數處理伺服器包括糾錯模組、重寫模組,以及其他執行模組,上述各執行模組可以分別對搜尋參數進行處理,分別獲取輸出結果,當該輸出結果滿足執行序列對應的精確度要求時,可以執行模組的執行結果作為搜尋詞返回給用戶端,並發送到搜尋引擎伺服器。搜尋引擎伺服器包括解析模組、查詢模組和合併模組,其中,解析模組用於對來自參數處理伺服器的執行結果進行解析,獲取搜尋詞;查詢模組用於根據搜尋詞查詢網站資料庫,如網路爬蟲結構,獲取查詢結果;合併模組用於對查詢模組的查詢結果進行合併處理,獲取搜尋結果。Specifically, the parameter processing server includes an error correction module, a rewriting module, and other execution modules, and each of the execution modules may separately process the search parameters to obtain an output result respectively, and when the output result satisfies the execution sequence corresponding When the accuracy is required, the execution result of the execution module can be returned to the client as a search term and sent to the search engine server. The search engine server includes an analysis module, a query module, and a merge module, wherein the parsing module is configured to parse the execution result from the parameter processing server to obtain a search term; the query module is configured to query the website according to the search term. The database, such as the web crawler structure, obtains the query result; the merge module is used to merge the query results of the query module to obtain the search result.

需要說明的是,在本案的具體實施方式中,上述系統架構中的參數處理伺服器和搜尋引擎伺服器可以分別獨立部署,也可以將參數處理伺服器和搜尋引擎伺服器合併為系統中的同一個裝置。上述參數處理伺服器和搜尋引擎伺服器的部署方式,不影響本案的保護範圍。It should be noted that, in the specific implementation manner of the present invention, the parameter processing server and the search engine server in the system architecture may be separately deployed, or the parameter processing server and the search engine server may be merged into the same system. a device. The above parameters processing server and search engine server deployment methods do not affect the scope of protection of this case.

以下結合上述應用場景,對本案中的搜尋方法進行詳細、具體的描述。The search method in this case is described in detail below in combination with the above application scenarios.

如圖3所示,為本案實施例二中的一種搜尋方法流程圖,包括以下步驟:As shown in FIG. 3, a flow chart of a search method in the second embodiment of the present invention includes the following steps:

步驟301,參數處理伺服器獲取用戶端輸入的搜尋參數,根據預先配置的或者用戶端選擇的搜尋標籤確定處理搜尋參數的執行序列。Step 301: The parameter processing server acquires the search parameter input by the user end, and determines an execution sequence of processing the search parameter according to the pre-configured or search tag selected by the user end.

步驟302,參數處理伺服器按照執行序列依次調用該執行序列對應的執行模組,獲取執行模組對搜尋參數的輸出結果。Step 302: The parameter processing server sequentially calls the execution module corresponding to the execution sequence according to the execution sequence, and obtains an output result of the execution module to the search parameter.

步驟303,參數處理伺服器判斷執行模組的輸出結果的精確度等級是否滿足第一精確度要求。Step 303: The parameter processing server determines whether the accuracy level of the output result of the execution module satisfies the first accuracy requirement.

如果判斷結果為是,則執行步驟304;否則,結束流程。If the result of the determination is yes, then step 304 is performed; otherwise, the process ends.

步驟304,參數處理伺服器判斷滿足第一精確度要求的執行模組之間是否互相衝突。Step 304: The parameter processing server determines whether the execution modules satisfying the first accuracy requirement conflict with each other.

如果滿足第一精確度要求的執行模組之間互相衝突,則執行模組305;否則,執行步驟306。If the execution modules that meet the first accuracy requirement conflict with each other, the module 305 is executed; otherwise, step 306 is performed.

步驟305,參數處理伺服器確定由互相衝突的執行模組中輸出結果的精確度等級最高的執行模組處理搜尋參數,在搜尋計畫中保留該執行模組,獲取執行模組的執行結果。Step 305: The parameter processing server determines that the execution module is processed by the execution module with the highest accuracy level of the output result in the conflicting execution module, and the execution module is retained in the search plan to obtain the execution result of the execution module.

步驟306,參數處理伺服器使用搜尋計畫確定的執行模組處理搜尋參數,獲取該確定的執行模組的執行結果。Step 306: The parameter processing server processes the search parameter by using the execution module determined by the search plan, and obtains the execution result of the determined execution module.

步驟307,參數處理伺服器判斷執行模組的執行結果的個數是否大於指定輸出個數。Step 307: The parameter processing server determines whether the number of execution results of the execution module is greater than a specified number of outputs.

如果執行結果的個數大於指定輸出個數,則執行步驟308;否則,執行步驟309。If the number of execution results is greater than the specified number of outputs, step 308 is performed; otherwise, step 309 is performed.

步驟308,參數處理伺服器將執行模組的執行結果中精確度等級最高的執行結果作為搜尋詞發送給搜尋引擎伺服器,並將執行結果返回用戶端。Step 308: The parameter processing server sends the execution result with the highest accuracy level in the execution result of the execution module as a search term to the search engine server, and returns the execution result to the client.

需要說明的是,執行完本步驟後,可以繼續執行步驟310。It should be noted that after performing this step, step 310 can be continued.

步驟309,參數處理伺服器將所有執行結果作為搜尋詞發送給搜尋引擎伺服器,並將執行結果返回用戶端。In step 309, the parameter processing server sends all execution results as search words to the search engine server, and returns the execution result to the client.

具體地,可以為執行序列中的各個執行模組設置統一的介面,透過該介面為各個執行模組的執行結果設置統一的精確度等級。當保留的執行結果的個數大於指定輸出個數時,則將各個執行結果按照精確度等級進行排序,選取指定個數的精確度等級高的執行結果作為搜尋計畫。Specifically, a unified interface may be set for each execution module in the execution sequence, and a uniform accuracy level is set for the execution result of each execution module through the interface. When the number of retained execution results is greater than the specified number of outputs, the execution results are sorted according to the accuracy level, and the execution result with the specified number of precision levels is selected as the search plan.

在具體的實現過程中,由於系統中的執行模組的輸出存在多個可能性,即對輸入的關鍵字等條件有精確的匹配度。如果輸入的關鍵字與模組中的詞嚴格匹配,則該模組的輸出精准度就高。由於各個模組的詞典索引是獨立的,不同模組的輸出精准度之間沒有相關性。由於各模組相互獨立,在新增新的模組的時候不用改變以前的模組,可以對模組輸出設置一個統一的介面,用於模組對輸出的準確度進行設置。各模組對精確度演算法不一樣,結果不具有可比性,在介面中將輸出結果統一到幾個精確度等級,作為輸出時統一選擇的參考依據。In the specific implementation process, there are multiple possibilities due to the output of the execution module in the system, that is, the matching of the input keywords and the like. If the entered keyword exactly matches the word in the module, the output accuracy of the module is high. Since the dictionary index of each module is independent, there is no correlation between the output precision of different modules. Since each module is independent of each other, it is not necessary to change the previous module when adding a new module, and a unified interface can be set for the module output for the module to set the accuracy of the output. Each module has different accuracy algorithms, and the results are not comparable. The output results are unified to several accuracy levels in the interface, which serves as a reference for unified selection at the time of output.

步驟310,搜尋引擎伺服器對搜尋詞進行搜尋,獲取搜尋結果。In step 310, the search engine server searches for the search term and obtains the search result.

需要說明的是,本案也可以透過各個模組獨立搭建服務來實現,由用戶端分別調用各自的服務可以將服務整合在一起。本案提出的技術方案可以使用C++實現,在Linux系統上運行能達到最佳的實施效果。It should be noted that the case can also be realized by independently setting up a service by each module, and the service can be integrated by the user terminal respectively calling their respective services. The technical solution proposed in this case can be implemented in C++, and running on a Linux system can achieve the best implementation effect.

本案包括以下優點,根據執行模組的執行結果的精確度對可能衝突的執行模組進行協調,能夠更加快速準確地獲取搜尋參數背後的用戶意圖並將用戶意圖轉換為搜尋引擎能夠理解的機器語言和執行策略,方便了對執行模組的管理,在不改變原有的執行模組的前提下,能夠輸出更優的搜尋詞。另外,對執行模組的調用採用獨立的服務,不影響搜尋引擎核心查詢服務的穩定性,且執行模組可以進行分佈部署,不與搜尋引擎服務綁定,也不與搜尋引擎競爭伺服器資源,對伺服器產生的壓力小,處理速度快。當然,實施本案的任一產品並不一定需要同時達到以上所述的所有優點。The present invention includes the following advantages: coordinate the execution modules that may conflict according to the accuracy of the execution result of the execution module, and can obtain the user intention behind the search parameters more quickly and accurately and convert the user intention into a machine language that the search engine can understand. And the execution strategy facilitates the management of the execution module, and can output better search terms without changing the original execution module. In addition, the execution of the module is independent, does not affect the stability of the search engine core query service, and the execution module can be distributed, not bound to the search engine service, or compete with the search engine for server resources. The pressure generated on the server is small and the processing speed is fast. Of course, implementing any of the products of the present invention does not necessarily require all of the advantages described above to be achieved at the same time.

本案上述實施例提供了搜尋方法和應用場景,相應地,本案還透過以下實施例提供了應用上述方法的裝置。The foregoing embodiment of the present invention provides a search method and an application scenario. Accordingly, the present invention also provides an apparatus for applying the above method through the following embodiments.

如圖4所示,為本案實施例三中的一種產生搜尋計畫的裝置結構示意圖,包括:As shown in FIG. 4, a schematic structural diagram of a device for generating a search plan in the third embodiment of the present invention includes:

獲取模組410,用於獲取用戶端輸入的搜尋參數,根據預先配置的或者該用戶端選擇的搜尋標籤確定處理該搜尋參數的執行序列。The obtaining module 410 is configured to obtain a search parameter input by the user end, and determine an execution sequence for processing the search parameter according to a pre-configured or search tag selected by the user end.

調用模組420,用於按照該獲取模組410確定的執行序列依次調用該執行序列對應的執行模組,獲取該執行模組對該搜尋參數的輸出結果,根據該執行模組的輸出結果的精確度等級產生搜尋計畫,該搜尋計畫包括處理該搜尋參數的執行模組。The calling module 420 is configured to sequentially call the execution module corresponding to the execution sequence according to the execution sequence determined by the acquisition module 410, and obtain an output result of the execution module for the search parameter, according to the output result of the execution module. The accuracy level produces a search plan that includes an execution module that processes the search parameters.

搜尋模組430,用於使用該調用模組420產生的搜尋計畫確定的執行模組處理該搜尋參數,獲取該確定的執行模組的執行結果,並按照該執行結果進行搜尋,獲取搜尋結果。The search module 430 is configured to process the search parameter by using the execution module determined by the search plan generated by the call module 420, obtain the execution result of the determined execution module, and perform a search according to the execution result to obtain the search result. .

本案包括以下優點,根據執行模組的執行結果的精確度對可能衝突的執行模組進行協調,能夠更加快速準確地獲取搜尋參數背後的用戶意圖並將用戶意圖轉換為搜尋引擎能夠理解的機器語言和執行策略,方便了對執行模組的管理,在不改變原有的執行模組的前提下,能夠輸出更優的搜尋詞。當然,實施本案的任一產品並不一定需要同時達到以上所述的所有優點。The present invention includes the following advantages: coordinate the execution modules that may conflict according to the accuracy of the execution result of the execution module, and can obtain the user intention behind the search parameters more quickly and accurately and convert the user intention into a machine language that the search engine can understand. And the execution strategy facilitates the management of the execution module, and can output better search terms without changing the original execution module. Of course, implementing any of the products of the present invention does not necessarily require all of the advantages described above to be achieved at the same time.

如圖5所示,為本案實施例四中的一種產生搜尋計畫的裝置結構示意圖,包括:As shown in FIG. 5, a schematic structural diagram of a device for generating a search plan in the fourth embodiment of the present invention includes:

獲取模組510,用於獲取用戶端輸入的搜尋參數,根據預先配置的或者該用戶端選擇的搜尋標籤確定處理該搜尋參數的執行序列。The obtaining module 510 is configured to obtain a search parameter input by the user end, and determine an execution sequence for processing the search parameter according to a pre-configured or search tag selected by the user end.

調用模組520,用於按照該獲取模組510確定的執行序列依次調用該執行序列對應的執行模組,獲取該執行模組對該搜尋參數的輸出結果,根據該執行模組的輸出結果的精確度等級產生搜尋計畫,該搜尋計畫包括處理該搜尋參數的執行模組。The calling module 520 is configured to sequentially call the execution module corresponding to the execution sequence according to the execution sequence determined by the acquisition module 510, and obtain an output result of the execution module for the search parameter, according to the output result of the execution module. The accuracy level produces a search plan that includes an execution module that processes the search parameters.

上述調用模組520,具體用於判斷該執行模組的輸出結果的精確度等級是否滿足第一精確度要求,如果滿足,則確定由該執行模組處理該搜尋參數。The calling module 520 is specifically configured to determine whether the accuracy level of the output result of the execution module satisfies the first accuracy requirement, and if so, determine that the search parameter is processed by the execution module.

上述調用模組520,還用於判斷該滿足第一精確度要求的執行模組之間是否互相衝突,如果互相衝突,則由該互相衝突的執行模組中輸出結果的精確度等級最高的執行模組處理該搜尋參數。The calling module 520 is further configured to determine whether the execution modules satisfying the first accuracy requirement conflict with each other. If they conflict with each other, the execution level of the conflicting execution module has the highest accuracy level. The module processes the search parameters.

上述調用模組520,具體用於判斷該滿足第一精確度要求的執行模組中是否存在至少兩個包含在預定義的衝突序列中的執行模組;如果存在,則判斷該滿足第一精確度要求的執行模組之間互相衝突;如果不存在,則判斷該滿足第一精確度要求的執行模組之間不互相衝突。The calling module 520 is specifically configured to determine whether there are at least two execution modules included in the predefined conflict sequence in the execution module that meet the first accuracy requirement; if yes, determine that the first accuracy is satisfied. The execution modules of the degree requirements conflict with each other; if not, it is determined that the execution modules satisfying the first accuracy requirement do not conflict with each other.

當上述執行模組的輸出結果包括該執行模組的執行結果時,上述調用模組520,還用於將該執行模組的輸出結果中的執行結果通知該執行序列中的後續執行模組,使該後續執行模組根據該執行模組的執行結果產生輸出結果。When the output result of the execution module includes the execution result of the execution module, the calling module 520 is further configured to notify the subsequent execution module in the execution sequence of the execution result in the output result of the execution module. The subsequent execution module is caused to generate an output result according to the execution result of the execution module.

搜尋模組530,用於使用該調用模組520產生的搜尋計畫確定的執行模組處理該搜尋參數,獲取該確定的執行模組的執行結果,並按照該執行結果進行搜尋,獲取搜尋結果。The search module 530 is configured to process the search parameter by using the execution module determined by the search plan generated by the call module 520, obtain the execution result of the determined execution module, and perform a search according to the execution result to obtain the search result. .

上述執行模組的輸出結果還包括該執行模組的執行結果,上述搜尋模組530,還用於在該執行模組的輸出結果滿足第二精確度要求且該搜尋參數滿足預設的複雜度要求時,按照該執行模組的執行結果進行搜尋,獲取搜尋結果。The output of the execution module further includes an execution result of the execution module, and the search module 530 is further configured to: the output result of the execution module meets a second accuracy requirement, and the search parameter meets a preset complexity When required, the search is performed according to the execution result of the execution module, and the search result is obtained.

設置模組540,用於為該執行序列中的各個執行模組設置統一的介面,透過該介面為該各個執行模組的輸出結果設置統一的精確度等級,供該調用模組520使用。The setting module 540 is configured to set a unified interface for each execution module in the execution sequence, and set a uniform accuracy level for the output of the execution modules through the interface for the calling module 520 to use.

本案包括以下優點,根據執行模組的執行結果的精確度對可能衝突的執行模組進行協調,能夠更加快速準確地獲取搜尋參數背後的用戶意圖並將用戶意圖轉換為搜尋引擎能夠理解的機器語言和執行策略,方便了對執行模組的管理,在不改變原有的執行模組的前提下,能夠輸出更優的搜尋詞。當然,實施本案的任一產品並不一定需要同時達到以上所述的所有優點。The present invention includes the following advantages: coordinate the execution modules that may conflict according to the accuracy of the execution result of the execution module, and can obtain the user intention behind the search parameters more quickly and accurately and convert the user intention into a machine language that the search engine can understand. And the execution strategy facilitates the management of the execution module, and can output better search terms without changing the original execution module. Of course, implementing any of the products of the present invention does not necessarily require all of the advantages described above to be achieved at the same time.

透過以上的實施方式的描述,本領域的技術人員可以清楚地瞭解到本案可借助軟體加必需的通用硬體平臺的方式來實現,當然也可以透過硬體,但很多情況下前者是更佳的實施方式。基於這樣的理解,本案的技術方案本質上或者說對現有技術做出貢獻的部分可以以軟體產品的形式體現出來,該電腦軟體產品儲存在一個儲存媒體中,包括若干指令用以使得一台終端設備(可以是手機,個人電腦,伺服器,或者網路設備等)執行本案各個實施例該的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the present invention can be implemented by means of a software plus a necessary universal hardware platform, and of course, can also be through hardware, but in many cases, the former is better. Implementation. Based on this understanding, the technical solution of the present invention can be embodied in the form of a software product in essence or in the form of a software product, which is stored in a storage medium and includes a plurality of instructions for making a terminal. The device (which may be a cell phone, a personal computer, a server, or a network device, etc.) performs the method of the various embodiments of the present invention.

以上所述僅是本案的較佳實施方式,應當指出,對於本技術領域的普通技術人員來說,在不脫離本案原理的前提下,還可以做出若干改進和潤飾,這些改進和潤飾也應視為本案的保護範圍。The above description is only a preferred embodiment of the present invention, and it should be noted that those skilled in the art can make some improvements and retouching without departing from the principle of the present invention, and these improvements and retouchings should also be It is regarded as the scope of protection of this case.

本領域技術人員可以理解實施例中的裝置中的模組可以按照實施例描述進行分佈於實施例的裝置中,也可以進行相應變化位於不同於本實施例的一個或多個裝置中。上述實施例的模組可以集成於一體,也可以分離部署;可以合併為一個模組,也可以進一步拆分成多個子模組。上述本案實施例序號僅僅為了描述,不代表實施例的優劣。A person skilled in the art can understand that the modules in the apparatus in the embodiment can be distributed in the apparatus of the embodiment according to the description of the embodiment, or the corresponding changes can be located in one or more apparatuses different from the embodiment. The modules of the above embodiments may be integrated into one or separately deployed; they may be combined into one module, or may be further split into multiple sub-modules. The serial numbers of the above embodiments are merely for the description, and do not represent the advantages and disadvantages of the embodiments.

以上揭示的僅為本案的幾個具體實施例,但是,本案並非侷限於此,任何本領域的技術人員能思之的變化都應落入本案的保護範圍。The above disclosure is only a few specific embodiments of the present invention, but the present invention is not limited thereto, and any changes that can be considered by those skilled in the art should fall within the scope of protection of the present case.

410...獲取模組410. . . Get module

420...調用模組420. . . Call module

430...搜尋模組430. . . Search module

510...獲取模組510. . . Get module

520...調用模組520. . . Call module

530...搜尋模組530. . . Search module

540...設置模組540. . . Setting module

為了更清楚地說明本案或現有技術中的技術方案,下面將對本案或現有技術描述中所需要使用的附圖作簡單的介紹,顯而易見地,下面描述中的附圖僅僅是本案的一些實施例,對於本領域普通技術人員來講,在不付出創造性勞動的前提下,還可以根據這些附圖獲得其他的附圖。In order to more clearly illustrate the present invention or the technical solutions in the prior art, the drawings used in the present disclosure or the description of the prior art will be briefly described below. Obviously, the drawings in the following description are only some embodiments of the present disclosure. Other drawings may also be obtained from those of ordinary skill in the art in light of the inventive work.

圖1為本案實施例一中的一種搜尋方法流程圖;1 is a flow chart of a search method in the first embodiment of the present invention;

圖2為本案實施例二中的一種搜尋系統架構示意圖;2 is a schematic diagram of a search system architecture in the second embodiment of the present invention;

圖3為本案實施例二中的一種搜尋方法流程圖;3 is a flow chart of a search method in the second embodiment of the present invention;

圖4為本案實施例三中的一種搜尋裝置結構示意圖;4 is a schematic structural diagram of a search device in Embodiment 3 of the present invention;

圖5為本案實施例四中的一種搜尋裝置結構示意圖。FIG. 5 is a schematic structural diagram of a search device in Embodiment 4 of the present invention.

Claims (10)

一種搜尋方法,其特徵在於,包括以下步驟:獲取用戶端輸入的搜尋參數,根據預先配置的或者該用戶端選擇的搜尋標籤確定處理該搜尋參數的執行序列,其中,該搜尋標籤對應所需處理功能,且該執行序列為執行該處理功能按照的順序;按照該執行序列依次調用該執行序列對應的執行模組,獲取該執行模組對該搜尋參數的輸出結果,根據該執行模組的輸出結果的精確度等級產生搜尋計畫,該搜尋計畫包括處理該搜尋參數的執行模組,其中,該根據該執行模組的輸出結果的精確度等級產生搜尋計畫,具體包括:判斷該執行模組的輸出結果的精確度等級是否滿足第一精確度要求,如果滿足,則判斷該滿足第一精確度要求的執行模組之間是否互相衝突,如果互相衝突,則由該互相衝突的執行模組中輸出結果的精確度等級最高的執行模組處理該搜尋參數;以及使用該搜尋計畫確定的執行模組處理該搜尋參數,獲取該確定的執行模組的執行結果,並按照該執行結果進行搜尋,以獲取搜尋結果。 A search method, comprising the steps of: acquiring a search parameter input by a user terminal, and determining, according to a pre-configured or search tag selected by the user terminal, an execution sequence for processing the search parameter, wherein the search tag corresponds to a required process a function, and the execution sequence is an order in which the processing function is executed; the execution module corresponding to the execution sequence is sequentially called according to the execution sequence, and an output result of the execution module is obtained according to the output of the execution module. The accuracy level of the result generates a search plan, the search plan includes an execution module for processing the search parameter, wherein the search plan is generated according to the accuracy level of the output result of the execution module, and specifically includes: determining the execution Whether the accuracy level of the output result of the module satisfies the first accuracy requirement, and if so, whether the execution modules satisfying the first accuracy requirement conflict with each other, and if they conflict with each other, the conflicting execution The execution module with the highest accuracy level of the output result in the module processes the search parameter And using the search program execution module processes the determined search parameters to obtain the results of the implementation of the module determined, in accordance with the execution and search results to get search results. 如申請專利範圍第1項所述的方法,其中,該判斷滿足精確度要求的執行模組之間是否互相衝突,具體包括:判斷該滿足第一精確度要求的執行模組中是否存在至少兩個包含在預定義的衝突序列中的執行模組; 如果存在,則判斷該滿足第一精確度要求的執行模組之間互相衝突;及如果不存在,則判斷該滿足第一精確度要求的執行模組之間不互相衝突。 The method of claim 1, wherein the determining whether the execution modules satisfying the accuracy requirement conflict with each other comprises: determining whether at least two of the execution modules satisfying the first accuracy requirement exist. Execution modules contained in a predefined sequence of conflicts; If so, it is determined that the execution modules satisfying the first accuracy requirement conflict with each other; and if not, it is determined that the execution modules satisfying the first accuracy requirement do not conflict with each other. 如申請專利範圍第1項所述的方法,其中,該執行模組的輸出結果還包括該執行模組的執行結果,當該執行模組的輸出結果滿足第二精確度要求且該搜尋參數滿足預設的複雜度要求時,按照該執行模組的執行結果進行搜尋,以獲取搜尋結果。 The method of claim 1, wherein the output result of the execution module further includes an execution result of the execution module, when an output result of the execution module satisfies a second accuracy requirement and the search parameter is satisfied. When the preset complexity is required, the search is performed according to the execution result of the execution module to obtain the search result. 如申請專利範圍第1項所述的方法,其中,該執行模組的輸出結果包括該執行模組的執行結果時,該獲取執行模組對該搜尋參數的輸出結果之後,還包括:將該執行模組的輸出結果中的執行結果通知該執行序列中的後續執行模組,使該後續執行模組根據該執行模組的執行結果產生輸出結果。 The method of claim 1, wherein the outputting result of the execution module includes an execution result of the execution module, and after the obtaining execution module outputs the search parameter, the method further includes: The execution result in the output result of the execution module notifies the subsequent execution module in the execution sequence, so that the subsequent execution module generates an output result according to the execution result of the execution module. 如申請專利範圍第1項所述的方法,其中,還包括:為該執行序列中的各個執行模組設置統一的介面,透過該介面為該各個執行模組的輸出結果設置統一的精確度等級。 The method of claim 1, further comprising: setting a unified interface for each execution module in the execution sequence, and setting a uniform accuracy level for outputting the execution modules through the interface; . 一種搜尋裝置,其特徵在於,包括:獲取模組,用於獲取用戶端輸入的搜尋參數,根據預先配置的或者該用戶端選擇的搜尋標籤確定處理該搜尋參數的執行序列其中,該搜尋標籤對應所需處理功能,且該 執行序列為執行該處理功能按照的順序,;調用模組,用於按照該獲取模組確定的執行序列依次調用該執行序列對應的執行模組,獲取該執行模組對該搜尋參數的輸出結果,根據該執行模組的輸出結果的精確度等級產生搜尋計畫,該搜尋計畫包括處理該搜尋參數的執行模組,具體用於判斷該執行模組的輸出結果的精確度等級是否滿足第一精確度要求,如果滿足,則判斷該滿足第一精確度要求的執行模組之間是否互相衝突,如果互相衝突,則由該互相衝突的執行模組中輸出結果的精確度等級最高的執行模組處理該搜尋參數;以及搜尋模組,用於使用該調用模組產生的搜尋計畫確定的執行模組處理該搜尋參數,獲取該確定的執行模組的執行結果,並按照該執行結果進行搜尋,以獲取搜尋結果。 A search device, comprising: an obtaining module, configured to acquire a search parameter input by a user end, and determine, according to a pre-configured or search tag selected by the user end, an execution sequence for processing the search parameter, where the search tag corresponds to Required processing function, and The execution sequence is an order in which the processing function is executed, and the calling module is configured to sequentially call the execution module corresponding to the execution sequence according to the execution sequence determined by the acquisition module, and obtain an output result of the execution module for the search parameter. And generating a search plan according to the accuracy level of the output result of the execution module, where the search plan includes an execution module for processing the search parameter, specifically for determining whether the accuracy level of the output result of the execution module satisfies An accuracy requirement, if satisfied, determining whether the execution modules satisfying the first accuracy requirement conflict with each other, and if they conflict with each other, the execution of the conflicting execution module has the highest level of accuracy The module processes the search parameter; and the search module is configured to process the search parameter by using an execution module determined by the search plan generated by the call module, obtain an execution result of the determined execution module, and follow the execution result. Search to get search results. 如申請專利範圍第6項所述的裝置,其中,該調用模組,具體用於判斷該滿足第一精確度要求的執行模組中是否存在至少兩個包含在預定義的衝突序列中的執行模組;如果存在,則判斷該滿足第一精確度要求的執行模組之間互相衝突;及如果不存在,則判斷該滿足第一精確度要求的執行模組之間不互相衝突。 The device of claim 6, wherein the calling module is specifically configured to determine whether there are at least two executions included in the predefined conflict sequence in the execution module that meets the first accuracy requirement. a module; if present, determining that the execution modules satisfying the first accuracy requirement conflict with each other; and if not, determining that the execution modules satisfying the first accuracy requirement do not conflict with each other. 如申請專利範圍第6項所述的裝置,其中,該執行模組的輸出結果還包括該執行模組的執行結果,該搜尋模組,還用於在該執行模組的輸出結果滿足第二精確度要求且該搜尋參數滿足預設的複雜度要求時,按照該執行模組的執行結果進行搜尋,以獲取搜尋結果。 The device of claim 6, wherein the output of the execution module further includes an execution result of the execution module, and the search module is further configured to: When the accuracy is required and the search parameter meets the preset complexity requirement, the search result is performed according to the execution result of the execution module to obtain the search result. 如申請專利範圍第6項所述的裝置,其中,該執行模組的輸出結果包括該執行模組的執行結果時,該調用模組,還用於將該執行模組的輸出結果中的執行結果通知該執行序列中的後續執行模組,使該後續執行模組根據該執行模組的執行結果產生輸出結果。 The device of claim 6, wherein the output module includes an execution result of the execution module, and the calling module is further configured to execute the output result of the execution module. The result is notified to the subsequent execution module in the execution sequence, so that the subsequent execution module generates an output result according to the execution result of the execution module. 如申請專利範圍第6項所述的裝置,其中,還包括:設置模組,用於為該執行序列中的各個執行模組設置統一的介面,透過該介面為該各個執行模組的輸出結果設置統一的精確度等級,供該調用模組使用。 The device of claim 6, further comprising: a setting module, configured to set a unified interface for each execution module in the execution sequence, and output the output of the execution modules through the interface Set a uniform level of accuracy for use by the calling module.
TW099115483A 2010-05-14 2010-05-14 Search methods and devices TWI507897B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW099115483A TWI507897B (en) 2010-05-14 2010-05-14 Search methods and devices

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW099115483A TWI507897B (en) 2010-05-14 2010-05-14 Search methods and devices

Publications (2)

Publication Number Publication Date
TW201140344A TW201140344A (en) 2011-11-16
TWI507897B true TWI507897B (en) 2015-11-11

Family

ID=46760272

Family Applications (1)

Application Number Title Priority Date Filing Date
TW099115483A TWI507897B (en) 2010-05-14 2010-05-14 Search methods and devices

Country Status (1)

Country Link
TW (1) TWI507897B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106897343A (en) * 2016-07-20 2017-06-27 阿里巴巴集团控股有限公司 The lookup method of executive plan, storage method and device

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110825864A (en) * 2019-11-13 2020-02-21 北京香侬慧语科技有限责任公司 Method and device for obtaining answers to questions

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030200198A1 (en) * 2000-06-28 2003-10-23 Raman Chandrasekar Method and system for performing phrase/word clustering and cluster merging
US20060230035A1 (en) * 2005-03-30 2006-10-12 Bailey David R Estimating confidence for query revision models
TW200928814A (en) * 2007-09-17 2009-07-01 Yahoo Inc Customization of search results
TW200951743A (en) * 2008-06-05 2009-12-16 Tornado Technologies Co Ltd Method and system of using text characteristics to expand a query scope, data query method capable of searching word phrases having similar characteristics, and search engine server

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030200198A1 (en) * 2000-06-28 2003-10-23 Raman Chandrasekar Method and system for performing phrase/word clustering and cluster merging
US20060230035A1 (en) * 2005-03-30 2006-10-12 Bailey David R Estimating confidence for query revision models
TW200928814A (en) * 2007-09-17 2009-07-01 Yahoo Inc Customization of search results
TW200951743A (en) * 2008-06-05 2009-12-16 Tornado Technologies Co Ltd Method and system of using text characteristics to expand a query scope, data query method capable of searching word phrases having similar characteristics, and search engine server

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106897343A (en) * 2016-07-20 2017-06-27 阿里巴巴集团控股有限公司 The lookup method of executive plan, storage method and device

Also Published As

Publication number Publication date
TW201140344A (en) 2011-11-16

Similar Documents

Publication Publication Date Title
JP7383737B2 (en) Pinning artifacts to expand search keys and search spaces in natural language understanding (NLU) frameworks
JP5481570B2 (en) Search query processing
EP3514694B1 (en) Query translation
Campagna et al. Genie: A generator of natural language semantic parsers for virtual assistant commands
US9183511B2 (en) System and method for universal translating from natural language questions to structured queries
JP5357326B2 (en) Apparatus and method for rendering a page
US10698654B2 (en) Ranking and boosting relevant distributable digital assistant operations
JP6939384B2 (en) Data processing equipment, methods and programs
US9448772B2 (en) Generating program fragments using keywords and context information
CN106547527B (en) JavaScript file construction method and device
CN108369591B (en) System and method for caching and parameterizing IR
KR20160061305A (en) Method and apparatus for customized software development kit (sdk) generation
US10930272B1 (en) Event-based semantic search and retrieval
JP2013522798A (en) Indexing and searching using virtual documents
US8175997B2 (en) Method of applying user-defined inference rule using function of searching knowledge base and knowledge base management system therefor
WO2020103345A1 (en) Session flow processing method and apparatus, and computer-readable storage medium
US20180113686A1 (en) Automatically Determining Data Dependencies to Facilitate Code Execution
US20160299972A1 (en) Providing app store search results
TWI507897B (en) Search methods and devices
CN111221852A (en) Mixed query processing method and device based on big data
RU2603535C2 (en) METHOD AND SYSTEM FOR USING A Web-BROWSER
CN111221860A (en) Mixed query optimization method and device based on big data
CN111221841A (en) Real-time processing method and device based on big data
Dunka et al. Simplifying Web Application Development Using-Mean Stack Technologies
Kyriakakis et al. Enabling ontology-based search: a case study in the bioinformatics domain

Legal Events

Date Code Title Description
MM4A Annulment or lapse of patent due to non-payment of fees