A patent search method, search system and storage medium based on similarity
Through the patent retrieval method based on similarity, word segmentation and vectorization technology combined with the TF-IDF algorithm solve the redundant and irrelevant problems caused by keyword matching in the existing technology, achieve efficient and accurate patent document retrieval, and ensure The search results are highly relevant to the search keywords.
Patent Information
- Application Number
- CN202311270171.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-27
- Publication Date
- 2024-08-23
- Estimated Expiration
- 2043-09-27
AI Technical Summary
Existing patent search methods mainly rely on keyword matching, which leads to an increase in redundant and irrelevant information, affecting search efficiency and accuracy, especially when there are words with different meanings but similar text composition to the search keywords.
A patent search method based on similarity is used to calculate the similarity between the search keywords and the patent text through word segmentation, keyword extraction and quantification. The TF-IDF algorithm and inverse document frequency are used to screen out highly relevant patent documents. , arrange the results in descending order to improve retrieval efficiency and accuracy.
It effectively reduces the feedback of redundant information and irrelevant information, improves the accuracy and efficiency of search results, ensures that search results are highly relevant to search keywords, shortens the search cycle, and maintains high accuracy under the increasing number of patent documents. sex.
Smart Images

Figure CN117112811B
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of patent information processing, and in particular relates to a patent search method, a search system and a storage medium based on similarity. Background Art
[0002] Patents can not only protect intellectual property rights, but also provide commercial benefits such as increasing revenue and protecting market share. Therefore, with the continuous development and innovation of science and technology, patents have become one of the important assets of many companies and organizations. In the process of scientific and technological innovation and R&D, in order to understand the latest technology and avoid the problem of infringement of innovative achievements, people often search for relevant patents in the preparation stage. However, with the increase in the number of patent documents, how to quickly and accurately retrieve relevant patents has become the primary problem faced by many scientific and technological enterprises.
[0003] In the prior art, the method of searching patents is mainly to perform keyword matching, which arranges the patent documents in front of the searcher from high to low according to the frequency of occurrence of the keywords in the patent documents based on several keywords typed by the searcher.
[0004] However, this method can only match relevant documents according to the keywords typed by the searcher, and this method will also match some keywords. This means that if there are words in a patent document that are different in meaning from the search keywords typed in but have similar text composition, then the patent document will be fed back to the searcher as a search result that is highly relevant to the search keywords, and the true similarity of the documents retrieved in this way will be greatly affected. In addition, the matching of some keywords in this method will bring a large amount of redundant information and irrelevant information to the search process, extend the entire search cycle, increase the resource usage of the server during the search process, reduce the effectiveness of the search results, and make subsequent patent analysis difficult and inefficient. For example, if the complete keyword typed in is "senile dementia", the keyword matching method will match some of the keywords "senile" and "dementia" of "senile dementia" with the patent document respectively, so that many patent documents unrelated to "senile dementia" will be introduced into the search results, such as the patent document of "senile booster" and the patent document of "frontotemporal dementia". Summary of the invention
[0005] The purpose of the present invention is to overcome the deficiencies of the prior art and to provide a similarity-based patent search method that can quickly and efficiently search for patent documents that are highly relevant to the search keywords.
[0006] To achieve the above object, the present invention adopts the following technical solutions:
[0007] A similarity-based patent search method comprises the following steps:
[0008] S1: After deduplication, the patent documents captured from major platforms and patent subject databases are stored in the local database. The local database sends the newly added patent documents to the text module for preprocessing to obtain the patent text. The text module then sends the newly added patent text to the word segmentation module. The word segmentation module converts each patent text into a corresponding word segmentation set and transmits it to the extraction module in real time / periodic time.
[0009] S2, the extraction module extracts a number of keywords from each word set to form patent keyword groups corresponding to each patent text, and vectorizes each patent keyword group and sends it to the calculation module; when the searcher types in the search keyword group, the search keyword group enters the extraction module, is vectorized, and then sent to the calculation module;
[0010] S3, the calculation module calculates the similarity between each patent keyword group and the current search keyword group, and transmits the similarity to the output module after arranging it in descending order;
[0011] S4, the output module feeds back the first L patent texts ranked from high to low in similarity to the current search keyword group as search results to the searcher.
[0012] Preferably, S1 also includes the following sub-steps:
[0013] S11: compare the patent documents captured from major platforms and patent subject databases with the patent documents stored in the local database. When the patent documents are in foreign languages or abbreviations, the foreign patent documents or abbreviations are translated into Chinese and compared with the patent documents stored in the local database. If the content of the currently captured patent document is repeated with that of the patent document stored in the patent database, the current patent document is discarded. Otherwise, the currently captured patent document is sent to the local database. After the local database binds a unique number to each patent document, it is stored in the form of "patent document + number";
[0014] S12, the local database sends the newly added "patent document + number" to the text module, and the text module removes the illegal content in each patent document to obtain the corresponding patent text. Each patent text is still bound to the number bound to the original patent document, and the "patent text + number" format is formed and stored in the text module. One patent document obtains one patent text;
[0015] Illegal content refers to characters that are not Arabic numerals and do not meet the rules for the use of Chinese characters and Chinese article symbols;
[0016] S13, the text module then sends the newly added "patent text + number" to the word segmentation module for word segmentation. The text module uses a pre-trained language model combined with a conditional random field based on machine learning to segment each patent text, and obtains a word segmentation set P(d) = {P d1 ,...,P dc ,...,P df}, and then transmitted to the extraction module in real time / periodic time, where P(d) represents the word set corresponding to the patent text numbered d, P dc It represents the cth word in the word set P(d), where a word is a separate Chinese character or phrase, 1<c<f, and c and f are positive integers.
[0017] Preferably, S2 also includes the following sub-steps:
[0018] S21, the extraction module retains only once the repeated segmented words in the current segmented word set P(d), and forms a corresponding candidate keyword set W(d) = {W d1 ,...,W da ,...,W db},
[0019] Among them, W(d) represents the candidate keyword set corresponding to the patent text numbered d, and W da represents the ath candidate keyword in the candidate keyword set W(d), 1<a<b≤f, and a and b are positive integers;
[0020] Record the number of times each candidate keyword in the candidate keyword set W(d) appears in the corresponding word set P(d), and calculate the word frequency of each candidate keyword in the patent text numbered d:
[0021] TF(W da )=E da / f,
[0022] Among them, TF(W da ) represents the candidate keyword W da The frequency of the word in the patent text numbered d, E da Represents the candidate keyword W da The number of occurrences in the corresponding word set P(d), f represents the total number of word sets P(d);
[0023] S22, the extraction module records the total number g of all word sets in the current extraction module, and respectively records the number of word sets containing each candidate keyword in the current candidate keyword set W(d) in these g word sets, and the word sets containing the candidate keyword W(d) da The number of word sets is recorded as H da , calculate the current candidate keyword W daThe inverse document frequency IDF(W da ):
[0024] IDF(W da )=[log 2 (g)-log 2 (H da )];
[0025] g word sets correspond to g patent texts, so H da It also means that the candidate keyword W appears in this patent text. da Patent text;
[0026] S23, respectively calculate the weight of each keyword in the candidate keyword set W(d) in the current patent text:
[0027] TF-IDF(W da )=TF(W da )×IDF(W da )=(E da / f)×[log 2 (g)-log 2 (H da )],
[0028] Among them, TF-IDF(W da ) represents the candidate keyword W in the candidate keyword set W(d) da The weight in the patent text numbered d;
[0029] S24, arranging the weights of the keywords in the current candidate keyword set W(d) in descending order, and selecting the candidate keywords corresponding to the first n weights as the patent keyword group K(d) of the current patent text numbered d:
[0030] K(d)={K d1 ,...,K dm ,...,K dn},
[0031] Among them, K dm represents the mth patent keyword in the patent keyword group K(d), 1≤m≤n, and m and n are positive integers;
[0032] S25, vectorize the patent keyword group K(d) of the current patent text numbered d and send it to the calculation module:
[0033] V(d)={V d1 ,...,V dm ,...,V dn},
[0034] Among them, V(d) is the vectorized representation of the patent keyword group K(d). The number of dimensions in V(d) is the same as the number of patent keywords in the patent keyword group K(d), and each dimension in V(d) corresponds to the patent keyword in the patent keyword group K(d). dm represents the value of the mth dimension in V(d), V dm The value is the patent keyword K dm The weight in the corresponding patent text.
[0035] Preferably, when the searcher enters a search keyword phrase, S2 also includes the following sub-steps S21' to S24' performed in parallel with S21 to S25:
[0036] S21', the searcher enters q different search keywords to form a search keyword group R: R = {R 1 ,...,R i ,...,R n}, where R i represents the i-th search keyword in the current search keyword group R, 1≤i≤n, 1≤q≤n, and i, q, n are positive integers.
[0037] When the search keyword entered by the searcher is a foreign language or abbreviation, the foreign language or abbreviation is translated into Chinese words / characters to form the search keyword group R.
[0038] When q<n, the (q+1)th search keyword R in the search keyword group R is q+1 、nth search keyword R n And the search keywords between them are all represented by "NULL";
[0039] S22', the search keyword group R enters the extraction module, and the extraction module records the number of times each search keyword in the current search keyword group R appears in each word segmentation set currently contained in the extraction module, the number of word segmentation sets in which each search keyword in the current search keyword group R appears, and the total number t of word segmentation sets currently contained in the extraction module, and calculates the word frequency of each search keyword in the current search keyword group R:
[0040]
[0041] Where P(s) represents the word set corresponding to the patent text numbered s, and the word set P(s) is one of the t word sets currently contained in the extraction module, TF[R i |P(s)] represents the search keyword R i The frequency of words appearing in the word set P(s) currently contained in the extraction module, that is, the frequency of words appearing in the patent text numbered s, E[Ri |P(s)] represents the search keyword R i The number of occurrences in the word set P(s), f[P(s)] represents the total number of words contained in the word set P(s);
[0042] Calculate the inverse document frequency of each search keyword in the current search keyword group R:
[0043] IDF(R i )={log 2 (t)-log 2 [H(R i )]},
[0044] Among them, IDF(R i ) indicates the search keyword R i The inverse document frequency of the t word sets currently contained in the extraction module, H(R i ) indicates that the current t word sets of the extraction module contain the search keyword R i The number of word sets;
[0045] S23', respectively calculate the weight of each search keyword in the current search keyword group R in the patent text corresponding to the t word sets currently contained in the extraction module:
[0046]
[0047] Among them, TF-IDF[R i |P(s)] represents the search keyword R in the current search keyword group R i The weight in the patent text corresponding to the word set P(s) currently contained in the extraction module;
[0048] S24', vectorize the current search keyword group R based on the t word sets currently contained in the extraction module, form t vector representations and send them to the calculation module:
[0049] V[R|P(s)]={V[R 1 |P(s)],...,V[R u |P(s)],...,V[R n |P(s)]},
[0050] Where 1≤u≤n, and u and n are positive integers. V[R|P(s)] is the vectorized representation of the current search keyword set R based on the word set P(s). The number of dimensions in V[R|P(s)] is the same as the number of search keywords in the current search keyword set R, both of which are n dimensions. Moreover, each dimension in V[R|P(s)] corresponds to a search keyword in the current search keyword set R one by one. u|P(s)] represents the value of the u-th dimension in V[R|P(s)], V[R u The value of |P(s)] is the search keyword R u The weight in the patent text corresponding to the word set P(s) currently contained in the extraction module.
[0051] Preferably, S3 also includes the following sub-steps:
[0052] S31, the calculation module calculates the similarity between the current search keyword group R and the patent text corresponding to each vectorized patent keyword group in the current calculation module:
[0053]
[0054] in, It represents the arithmetic mean of the weights of each search keyword in the current search keyword group R in the patent text numbered s corresponding to the word set P(s);
[0055]
[0056] in, represents the arithmetic mean of the weights of each patent keyword in the patent keyword group K(s) in the corresponding patent text numbered s, V sm represents the mth patent keyword K in the patent keyword group K(s) dm The arithmetic mean of the weights in the corresponding patent text numbered s;
[0057]
[0058] Among them, ρ(R,s) represents the similarity between the current search keyword group R and the patent text numbered s.
[0059] V[R i |P(s)] represents the i-th search keyword R in the current search keyword group R i The weight of the patent text numbered s corresponding to the word set P(s), 1≤i≤n, and i is a positive integer,
[0060] V sz represents the zth patent keyword K in the patent keyword group K(s) sz The weight in the corresponding patent text numbered s, 1≤z≤n, and z is a positive integer;
[0061] S32, after arranging the similarities between the current search keyword group R and the patent texts corresponding to the patent keyword groups represented by the vectorization in the current calculation module in descending order, the arrangement result is transmitted to the output module.
[0062] Preferably, S4 also includes the following:
[0063] The output module takes the first L similarities in the current similarity descending order, and retrieves the patent documents bound to the corresponding numbers in the local database according to the numbers attached to these L similarities. It then arranges the patent documents in descending order of similarity and outputs them as search results, which are then fed back to the searcher.
[0064] Preferably, the searcher can set the number of feedback articles for the search results in advance, and the output module retrieves the patent documents arranged in descending order of similarity according to the number of feedback articles set by the searcher for output feedback.
[0065] Preferably, L is 30 and n is 6.
[0066] The present invention also provides a patent search system based on similarity, comprising:
[0067] Capture module, local database, text module, word segmentation module, extraction module, calculation module, output module;
[0068] The capture module is used to capture patent documents from major platforms and patent subject databases and remove the duplicate patent documents stored in the local database before sending them to the local database;
[0069] The local database is used to store the patent documents sent by the crawling module and send the newly added patent documents to the text module;
[0070] The text module is used to process the patent documents sent from the local database to obtain patent texts, and send the patent texts to the word segmentation module;
[0071] The word segmentation module is used to segment the patent text sent by the text module to form a word set, and then send the word set to the extraction module;
[0072] The extraction module is used to extract keywords from the word set to form patent keyword groups, and then vectorize them and send them to the calculation module. When the searcher types in the search keyword group, the extraction module vectorizes the search keyword group and sends it to the calculation module;
[0073] The calculation module is used to calculate the similarity between each patent keyword group and the current search keyword group, and output them in descending order to the output module;
[0074] The output module feeds back the corresponding patent text to the searcher based on the results sorted in descending order of similarity;
[0075] Each module is programmed or configured to execute the steps of the above-mentioned similarity-based patent search method.
[0076] The present invention also provides a computer-readable storage medium storing a computer program programmed or configured to execute a similarity-based patent retrieval method as described above.
[0077] The beneficial effects of the present invention are as follows:
[0078] (1) The present invention uses a patent keyword group composed of several patent keywords highly relevant to the current patent text to equivalently replace the current patent text, greatly simplifying the content of the current patent text and facilitating the accurate calculation of the similarity between the retrieval keyword and the patent document with a lower resource occupancy in the subsequent process. Moreover, in the process of forming patent keywords in the present invention, not only the frequency of the current candidate keyword appearing in the current patent text is considered, but also the inverse document frequency is used to exclude the influence of words such as "de" (的) and "le" (了) that frequently appear in almost every patent text, that is, to find the words that frequently appear in the current patent text but rarely appear in different patent documents in the patent database, so as to truly screen out several patent keywords that can highly summarize the current patent text and comprehensively summarize the current patent text in the form of a patent keyword group.
[0079] (2) Compared with the disadvantage of less feature information in the low-dimensional vector, the present invention converts the retrieval keyword group and the patent keyword groups of each patent document into high-dimensional vector representations, which can better and more express different features of an unstructured patent document. At the same time, compared with the disadvantages of the Euclidean distance formula in the prior art being unable to handle high-dimensional vectors and the Jaccard similarity calculation method being unable to handle continuous data, the similarity calculation method of the present invention can quickly, efficiently and accurately calculate the linear similarity degree between the retrieval keyword group and each patent keyword group, especially for comparison objects such as the retrieval keyword group and the patent keyword group that contain several consecutive keywords, and quantify the similarity between the retrieval keyword and each patent document. At the same time, in the process of calculating the similarity degree between the retrieval keyword group and the patent document, the retrieval method of the present invention will not result in a high similarity degree between the patent document where a patent keyword is located and the current entire retrieval keyword group just because the similarity degree between a retrieval keyword and a certain patent keyword is high (for example, there is a situation where there is a word in a certain patent document that has a different meaning but very similar literal composition to a certain retrieval keyword in the current retrieval keyword group).
[0080] (3) The weight of each search keyword in the search keyword group of the present invention is calculated based on the corresponding patent text. The weight of a search keyword in different patent texts is also different. At the same time, the similarity degree finally calculated by the present invention reflects the overall similarity between the current search keyword group and each patent keyword group. Only when each search keyword in the current search keyword group is very similar / identical to all the patent keywords in a certain patent keyword group can the calculated similarity degree be closer to 1. The calculation method of the similarity degree is more reasonable. Finally, after the similarity between the search keyword group and the current patent keyword groups is calculated, the search feedback results are output in descending order of similarity, which reduces the redundant information and irrelevant information mixed in the search feedback, and provides the searcher with the patent documents that are truly highly relevant to the search keywords, thereby improving the effectiveness and accuracy of the search feedback results.
[0081] (4) Because the present invention is constantly capturing patent documents in various platforms and patent databases in real time, that is, non-duplicate patent documents are constantly being added to the local database, and the newly added patent documents are also converted into corresponding search keyword groups in real time / periodically, and enter the calculation module after vectorization, that is, the calculation module has already stored in advance the vectorized search keyword groups of the patent documents that have just been released. When the searcher conducts a search, it is no longer necessary to occupy a large amount of resources to calculate and process each patent document from the beginning based on the search keywords, as in the keyword matching search method in the prior art. Instead, it only takes a small amount of resources to vectorize each search keyword and calculate the correlation between the search keyword group and each patent keyword group, thereby shortening the entire search cycle and improving the efficiency of subsequent patent analysis work.
[0082] (5) As the number of patent documents captured from major platforms and patent databases increases, and / or the number of search keywords entered is increased without exceeding the upper limit of the number of search keywords, the accuracy of the search feedback of the present invention will be improved accordingly. BRIEF DESCRIPTION OF THE DRAWINGS
[0083] Figure 1 A flowchart of a similarity-based patent search method of the present invention;
[0084] Figure 2 A comparison curve of the time consumption for searching feedback between the present invention and the prior art;
[0085] Figure 3 A comparison curve of the accuracy of search feedback results between the present invention and the prior art;
[0086] Figure 4 The figure is a schematic diagram of the structure and data flow of a similarity-based patent search system of the present invention. DETAILED DESCRIPTION
[0087] In order to make the technical solution of the present invention clearer and more specific, the present invention is clearly and completely described below in conjunction with the accompanying drawings. Any equivalent replacement of the technical features of the technical solution of the present invention and any solution derived by conventional reasoning by ordinary technicians in the field without making any creative work shall fall within the protection scope of the present invention.
[0088] like Figure 1 A similarity-based patent search method is shown, comprising the following steps:
[0089] S1: After deduplication, the patent documents captured from major platforms and patent subject databases are stored in the local database. The local database sends the newly added patent documents to the text module for preprocessing to obtain the patent text. The text module then sends the newly added patent text to the word segmentation module. The word segmentation module converts each patent text into a corresponding word segmentation set and transmits it to the extraction module in real time / periodic time.
[0090] S2, the extraction module extracts a number of keywords from each word set to form patent keyword groups corresponding to each patent text, and vectorizes each patent keyword group and sends it to the calculation module; when the searcher types in the search keyword group, the search keyword group enters the extraction module, is vectorized, and then sent to the calculation module;
[0091] S3, the calculation module calculates the similarity between each patent keyword group and the current search keyword group, and transmits the similarity to the output module after arranging it in descending order;
[0092] S4, the output module feeds back the first L patent texts ranked from high to low in similarity to the current search keyword group as search results to the searcher.
[0093] S1 also includes the following sub-steps:
[0094] S11: compare the patent documents captured from major platforms and patent subject databases with the patent documents stored in the local database. When the patent documents are in foreign languages or abbreviations, the foreign patent documents or abbreviations are translated into Chinese and compared with the patent documents stored in the local database. If the content of the currently captured patent document is repeated with that of the patent document stored in the patent database, the current patent document is discarded. Otherwise, the currently captured patent document is sent to the local database. After the local database binds a unique number to each patent document, it is stored in the form of "patent document + number";
[0095] S12, the local database sends the newly added "patent document + number" to the text module, and the text module removes the illegal content in each patent document to obtain the corresponding patent text. Each patent text is still bound to the number bound to the original patent document, and the "patent text + number" format is formed and stored in the text module. One patent document obtains one patent text;
[0096] Illegal content refers to HTML tags, spaces, graphics, underscores, backslashes, and other characters that are not Arabic numerals and do not meet the rules for the use of Chinese characters and Chinese article symbols;
[0097] S13, the text module then sends the newly added "patent text + number" to the word segmentation module for word segmentation. The text module uses a pre-trained language model combined with a conditional random field based on machine learning to segment each patent text, and obtains a word segmentation set P(d) = {P d1 ,...,P dc ,...,P df}, and then transmitted to the extraction module in real time / periodic time, where P(d) represents the word set corresponding to the patent text numbered d, P dc It represents the cth word in the word set P(d), where a word is a separate Chinese character or phrase, 1<c<f, and c and f are positive integers.
[0098] Because there may be repeated characters / words in the patent text numbered d, there may also be repeated word segments in the word segmentation set P(d).
[0099] S2 also includes the following sub-steps:
[0100] S21, the extraction module retains only once the repeated segmented words in the current segmented word set P(d), and forms a corresponding candidate keyword set W(d) = {W d1 ,...,W da ,...,W db},
[0101] Among them, W(d) represents the candidate keyword set corresponding to the patent text numbered d, and W da represents the ath candidate keyword in the candidate keyword set W(d), 1<a<b≤f, and a and b are positive integers;
[0102] Record the number of times each candidate keyword in the candidate keyword set W(d) appears in the corresponding word set P(d), and calculate the word frequency of each candidate keyword in the patent text numbered d:
[0103] TF(W da )=E da / f,
[0104] Among them, TF(W da ) represents the candidate keyword W da The frequency of the word in the patent text numbered d, E da Represents the candidate keyword W da The number of times it appears in the corresponding word set P(d), and f represents the total number of word segments contained in the word set P(d).
[0105] S22, the extraction module records the total number g of all word sets in the current extraction module, and respectively records the number of word sets containing each candidate keyword in the current candidate keyword set W(d) in these g word sets, and the word sets containing the candidate keyword W(d) da The number of word sets is recorded as H da , calculate the current candidate keyword W da The inverse document frequency IDF(W da ):
[0106] IDF(W da )=[log 2 (g)-log 2 (H da )].
[0107] g word sets correspond to g patent texts, so H da It also means that the candidate keyword W appears in this patent text. da Patent text.
[0108] S23, respectively calculate the weight of each keyword in the candidate keyword set W(d) in the current patent text:
[0109] TF-IDF(W da )=TF(W da )×IDF(W da )=(E da / f)×[log 2 (g)-log 2 (H da )],
[0110] Among them, TF-IDF(W da ) represents the candidate keyword W in the candidate keyword set W(d) da The weight in the patent text numbered d;
[0111] S24, arranging the weights of the keywords in the current candidate keyword set W(d) in descending order, and selecting the candidate keywords corresponding to the first n weights as the patent keyword group K(d) of the current patent text numbered d:
[0112] K(d)={K d1 ,...,Kdm ,...,K dn},
[0113] Among them, K dm represents the mth patent keyword in the patent keyword group K(d), 1≤m≤n, and m and n are positive integers.
[0114] In this embodiment, n is 6.
[0115] S25, vectorize the patent keyword group K(d) of the current patent text numbered d and send it to the calculation module:
[0116] V(d)={V d1 ,...,V dm ,...,V dn},
[0117] Among them, V(d) is the vectorized representation of the patent keyword group K(d). The number of dimensions in V(d) is the same as the number of patent keywords in the patent keyword group K(d), and each dimension in V(d) corresponds to the patent keyword in the patent keyword group K(d). dm represents the value of the mth dimension in V(d), V dm The value is the patent keyword K dm The weight in the corresponding patent text.
[0118] When the searcher enters a search keyword phrase, S2 also includes the following sub-steps S21' to S24' that are performed in parallel with S21 to S25:
[0119] S21', the searcher enters q different search keywords to form a search keyword group R: R = {R 1 ,...,R i ,...,R n}, where R i represents the i-th search keyword in the current search keyword group R, 1≤i≤n, 1≤q≤n, and i, q, n are positive integers.
[0120] When the search keyword entered by the searcher is a foreign language or abbreviation, the foreign language or abbreviation is translated into Chinese words / characters to form the search keyword group R.
[0121] When q<n, the (q+1)th search keyword R in the search keyword group R is q+1 、nth search keyword R n And the search keywords between them are all represented by "NULL".
[0122] In S2 and its sub-steps, we set the patent keyword group corresponding to each patent text to contain n patent keywords, so we also set the maximum number of search keywords that can be entered in one search to n, to avoid the problem of the search taking too long because the searcher types too many keywords in one search. This also avoids the problem of excessive resource usage during the search process.
[0123] S22', the search keyword group R enters the extraction module, and the extraction module records the number of times each search keyword in the current search keyword group R appears in each word segmentation set currently contained in the extraction module, the number of word segmentation sets in which each search keyword in the current search keyword group R appears, and the total number t of word segmentation sets currently contained in the extraction module, and calculates the word frequency of each search keyword in the current search keyword group R:
[0124]
[0125] Where P(s) represents the word set corresponding to the patent text numbered s, and the word set P(s) is one of the t word sets currently contained in the extraction module, TF[R i |P(s)] represents the search keyword R i The frequency of words appearing in the word set P(s) currently contained in the extraction module, that is, the frequency of words appearing in the patent text numbered s, E[R i |P(s)] represents the search keyword R i The number of occurrences in the word set P(s), f[P(s)] represents the total number of words contained in the word set P(s);
[0126] That is, it is necessary to calculate the word frequencies of the n search keywords in the current search keyword group R corresponding to the t word sets currently contained in the extraction module, totaling (n×t) word frequencies;
[0127] Calculate the inverse document frequency of each search keyword in the current search keyword group R:
[0128] IDF(R i )={log 2 (t)-log 2 [H(R i )]},
[0129] Among them, IDF(R i ) indicates the search keyword R i The inverse document frequency of the t word sets currently contained in the extraction module, H(R i ) indicates that the current t word sets of the extraction module contain the search keyword R i The number of word sets.
[0130] S23', respectively calculate the weight of each search keyword in the current search keyword group R in the patent text corresponding to the t word sets currently contained in the extraction module:
[0131]
[0132] Among them, TF-IDF[R i |P(s)] represents the search keyword R in the current search keyword group R i The weight in the patent text corresponding to the word set P(s) currently contained in the extraction module;
[0133] That is, a total of (n×t) weights need to be calculated;
[0134] S24', vectorize the current search keyword group R based on the t word sets currently contained in the extraction module, form t vector representations and send them to the calculation module:
[0135] V[R|P(s)]={V[R 1 |P(s)],...,V[R u |P(s)],...,V[R n |P(s)]},
[0136] Where 1≤u≤n, and u and n are positive integers. V[R|P(s)] is the vectorized representation of the current search keyword set R based on the word set P(s). The number of dimensions in V[R|P(s)] is the same as the number of search keywords in the current search keyword set R, both of which are n dimensions. Moreover, each dimension in V[R|P(s)] corresponds to a search keyword in the current search keyword set R one by one. u |P(s)] represents the value of the u-th dimension in V[R|P(s)], V[R u The value of |P(s)] is the search keyword R u The weight in the patent text corresponding to the word set P(s) currently contained in the extraction module.
[0137] The following sub-steps are also included in S3:
[0138] S31, the calculation module calculates the similarity between the current search keyword group R and the patent text corresponding to each vectorized patent keyword group in the current calculation module:
[0139]
[0140] in, It represents the arithmetic mean of the weights of each search keyword in the current search keyword group R in the patent text numbered s corresponding to the word set P(s);
[0141]
[0142] in, represents the arithmetic mean of the weights of each patent keyword in the patent keyword group K(s) in the corresponding patent text numbered s, V sm represents the mth patent keyword K in the patent keyword group K(s) dm The arithmetic mean of the weights in the corresponding patent text numbered s;
[0143]
[0144] Among them, ρ(R,s) represents the similarity between the current search keyword group R and the patent text numbered s.
[0145] V[R i |P(s)] represents the i-th search keyword R in the current search keyword group R i The weight of the patent text numbered s corresponding to the word set P(s), 1≤i≤n, and i is a positive integer,
[0146] V sz represents the zth patent keyword K in the patent keyword group K(s) sz The weight in the corresponding patent text numbered s, 1≤z≤n, and z is a positive integer;
[0147] The value range of ρ(R,s) is [-1,1]. When ρ(R,s)=1, it means that there is a complete positive correlation between the current search keyword group R and the patent text numbered s, that is, the patent text numbered s completely meets the searcher's search requirements; when ρ(R,s)=0, it means that there is no correlation between the current search keyword group R and the patent text numbered s, that is, the patent text numbered s does not meet the searcher's search requirements at all; when ρ(R,s)=-1, it means that there is a complete negative correlation between the current search keyword group R and the patent text numbered s, that is, the patent text numbered s is completely opposite to the searcher's search requirements.
[0148] S32, after arranging the similarities between the current search keyword group R and the patent texts corresponding to the patent keyword groups represented by the vectorization in the current calculation module in descending order, the arrangement result is transmitted to the output module.
[0149] The following are also included in S4:
[0150] The output module selects the top L similarities from the results sorted in descending order of the current similarity. After retrieving the patent documents bound to the corresponding numbers in the local database according to the numbers carried by these L similarities, the patent documents are arranged in the order of descending similarity and output as the retrieval results, which are then fed back to the retriever.
[0151] Optionally, the retriever can set the number of feedback documents of the retrieval results in advance, and the output module will retrieve and output the patent documents sorted in descending order of similarity according to the number of feedback documents set by the retriever. When the retriever does not set the number of feedback documents of the retrieval results, the default feedback quantity of the present invention is to feedback L patent documents.
[0152] In this embodiment, L is taken as 30.
[0153] The present invention uses a patent keyword group composed of several patent keywords highly relevant to the current patent text to equivalently replace the current patent text, greatly simplifying the content of the current patent text and facilitating the accurate calculation of the similarity between the retrieval keywords and the patent documents with a relatively low resource occupancy in the subsequent process. Moreover, in the process of forming patent keywords in the present invention, not only is the frequency of the current candidate keyword appearing in the current patent text considered, but also the inverse document frequency is used to exclude the influence brought by words such as "de" (的) and "le" (了) that appear frequently in almost every patent text, that is, to find the words that appear frequently in the current patent text but rarely appear in different patent documents in the patent database, so as to truly screen out several patent keywords that can highly summarize the current patent text and comprehensively summarize the current patent text in the form of a patent keyword group.
[0154] Compared with the shortcoming that feature information is few in low-dimensional vector, the present invention converts the patent keyword group of search keyword group and each patent document into high-dimensional vector representation, which can better and more express the different features of an unstructured patent document. At the same time, compared with the shortcomings that the Euclidean distance formula in the prior art cannot process high-dimensional vectors and the Jaccard similarity calculation method cannot process continuous data, the similarity calculation method of the present invention can quickly, efficiently and accurately calculate the linear similarity between the search keyword group and each patent keyword group, especially for the comparison objects such as search keyword group and patent keyword group that contain several continuous keywords, quantify the similarity between the search keyword and each patent document. At the same time, the search method of the present invention, in the process of calculating the similarity between the search keyword group and the patent document, will not be because of the high similarity between a search keyword and a certain patent keyword (for example, there is a situation in a certain patent document that the meaning of a certain search keyword in the current search keyword group is different but the text composition is very similar to the situation of words), which will cause the patent document where the patent keyword is located to be high in similarity with the current entire search keyword group. The weight of each search keyword in the search keyword group of the present invention is calculated based on the corresponding patent text, and the weight of a search keyword is different in different patent texts; at the same time, the similarity degree finally calculated by the present invention reflects the overall similarity between the current search keyword group and each patent keyword group. Only when each search keyword in the current search keyword group is very similar / identical to all the patent keywords in a patent keyword group can the calculated similarity degree be closer to 1, and the calculation method of the similarity degree is more reasonable. After the similarity between the search keyword group and the current patent keyword groups is finally calculated, the search feedback results are output in descending order of similarity, which reduces redundant information and irrelevant information mixed in the search feedback, and feeds back patent documents that are truly highly relevant to the search keywords to the searcher, thereby improving the effectiveness and accuracy of the search feedback results.
[0155] Because the present invention is constantly capturing patent documents in various platforms and patent databases in real time, that is to say, non-duplicate patent documents are constantly being added to the local database, and the newly added patent documents are also being converted into corresponding search keyword groups in real time / periodically, and enter the calculation module after being vectorized, that is to say, the calculation module has already stored in advance the vectorized search keyword groups of the patent documents that have just been released. When the searcher conducts a search, it is no longer necessary to occupy a large amount of resources to calculate and process each patent document from the beginning according to the search keywords, as in the keyword matching search method in the prior art. Instead, it only needs to occupy a small amount of resources to vectorize each search keyword and calculate the correlation between the search keyword group and each patent keyword group, thereby shortening the entire search cycle and improving the efficiency of subsequent patent analysis work.
[0156] As the number of patent documents captured from major platforms and patent databases increases, and / or the number of search keywords entered is increased without exceeding the upper limit of the number of search keywords, the accuracy of the search feedback of the present invention will be improved accordingly.
[0157] Combined with data to better reflect the beneficial effects of the present invention:
[0158] The searcher randomly inputs 50 groups of search keywords, and each group of search keywords is searched using a patent search method based on similarity of the present invention and a search method based on keyword matching of the prior art, for a total of 100 searches, and 30 patent documents are fed back for each search. The similarity between the patent documents fed back by the search and the search keywords is manually reviewed with high quality, and the results of the manual review are used as the reference standard to obtain the following results: Figure 2 The line graph showing the comparison of the search feedback time between the present invention and the prior art is shown in FIG. Figure 3 A line graph comparing the accuracy of search feedback results between the present invention and the prior art is shown.
[0159] from Figure 2-Figure 3 It can be seen intuitively that the retrieval feedback efficiency of the patent documents of the same number obtained by using a similarity-based patent retrieval method of the present invention is significantly higher than that of the keyword matching retrieval method of the prior art; the accuracy of its retrieval feedback results is also significantly higher than that of the keyword matching retrieval method of the prior art; and as the number of retrievals increases, the accuracy of the retrieval feedback results of the retrieval method of the present invention gradually improves; while the keyword matching retrieval method of the prior art, as the number of retrievals increases, introduces some keywords for matching in the retrieval process, and the accuracy of the retrieval feedback results decreases instead; in the samples experimented with the present invention, when the number of experiments exceeds 20 times (that is, after searching more than 20 groups of retrieval keywords), the accuracy of the retrieval feedback results of the retrieval method of the present invention is significantly higher than that of the prior art.
[0160] The invention also provides a patent search system based on similarity, such as Figure 4 As shown, including:
[0161] Capture module, local database, text module, word segmentation module, extraction module, calculation module, output module;
[0162] The capture module is used to capture patent documents from major platforms and patent subject databases and remove the duplicate patent documents stored in the local database before sending them to the local database;
[0163] The local database is used to store the patent documents sent by the crawling module and send the newly added patent documents to the text module;
[0164] The text module is used to process the patent documents sent from the local database to obtain patent texts, and send the patent texts to the word segmentation module;
[0165] The word segmentation module is used to segment the patent text sent by the text module to form a word set, and then send the word set to the extraction module;
[0166] The extraction module is used to extract keywords from the word set to form patent keyword groups, and then vectorize them and send them to the calculation module. When the searcher types in the search keyword group, the extraction module vectorizes the search keyword group and sends it to the calculation module;
[0167] The calculation module is used to calculate the similarity between each patent keyword group and the current search keyword group, and output them in descending order to the output module;
[0168] The output module feeds back the corresponding patent text to the searcher based on the results sorted in descending order of similarity;
[0169] Each module is programmed or configured to execute the steps of the above-mentioned similarity-based patent search method.
[0170] The present invention also provides a computer-readable storage medium storing a computer program programmed or configured to execute the above-mentioned similarity-based patent search method.
[0171] The techniques, shapes, and structural parts not described in detail in the present invention are all well-known techniques.
Claims
1. A patent search method based on similarity, characterized in that: The following steps are involved: S1: After deduplication, the patent documents captured from major platforms and patent subject databases are stored in the local database. The local database sends the newly added patent documents to the text module for preprocessing to obtain the patent text. The text module then sends the newly added patent text to the word segmentation module. The word segmentation module converts each patent text into a corresponding word segmentation set and transmits it to the extraction module in real time / periodic time. S2, the extraction module extracts a number of keywords from each word set to form patent keyword groups corresponding to each patent text, and vectorizes each patent keyword group and sends it to the calculation module; when the searcher types in the search keyword group, the search keyword group enters the extraction module, is vectorized, and then sent to the calculation module; S3, the calculation module calculates the similarity between each patent keyword group and the current search keyword group, and transmits the similarity to the output module after arranging it in descending order; S4, the output module feeds back the first L patent texts arranged in descending order of similarity with the current search keyword group as search results to the searcher; S1 also includes the following sub-steps: S11: compare the patent documents captured from major platforms and patent subject databases with the patent documents stored in the local database. When the patent documents are in foreign languages or abbreviations, the foreign patent documents or abbreviations are translated into Chinese and compared with the patent documents stored in the local database. If the content of the currently captured patent document is repeated with that of the patent document stored in the patent database, the current patent document is discarded. Otherwise, the currently captured patent document is sent to the local database. After the local database binds a unique number to each patent document, it is stored in the form of "patent document + number"; S12, the local database sends the newly added "patent document + number" to the text module, and the text module removes the illegal content in each patent document to obtain the corresponding patent text. Each patent text is still bound to the number bound to the original patent document, and the "patent text + number" format is formed and stored in the text module. One patent document obtains one patent text; Illegal content refers to characters that are not Arabic numerals and do not meet the rules for the use of Chinese characters and Chinese article symbols; S13, the text module then sends the newly added "patent text + number" to the word segmentation module for word segmentation. The text module uses a pre-trained language model combined with a conditional random field based on machine learning to segment each patent text, and obtains the word segmentation set P(d) = {P d1 ,...,P dc ,...,P df }, and then transmitted to the extraction module in real time / periodic time, where P(d) represents the word set corresponding to the patent text numbered d, P dc represents the cth word in the word set P(d), where a word is a separate Chinese character or phrase, 1<c<f, and c and f are positive integers; S2 also includes the following sub-steps: S21, the extraction module retains only once the repeated segmented words in the current segmented word set P(d), and forms a corresponding candidate keyword set W(d) = {W d1 ,...,W da ,...,W db }, Among them, W(d) represents the candidate keyword set corresponding to the patent text numbered d, and W da represents the ath candidate keyword in the candidate keyword set W(d), 1<a<b≤f, and a and b are positive integers; Record the number of times each candidate keyword in the candidate keyword set W(d) appears in the corresponding word set P(d), and calculate the word frequency of each candidate keyword in the patent text numbered d: TF(W da )=E da / f, Among them, TF(W da ) represents the candidate keyword W da The frequency of the word in the patent text numbered d, E da Represents the candidate keyword W da The number of occurrences in the corresponding word set P(d), f represents the total number of word sets P(d); S22, the extraction module records the total number g of all word sets in the current extraction module, and respectively records the number of word sets containing each candidate keyword in the current candidate keyword set W(d) in these g word sets, and the word sets containing the candidate keyword W(d) da The number of word sets is recorded as H da , calculate the current candidate keyword W da The inverse document frequency IDF(W da ): IDF(W da )=[log2(g)-log2(H da )]; g word sets correspond to g patent texts, so H da It also means that the candidate keyword W appears in this patent text. da Patent text; S23, respectively calculate the weight of each keyword in the candidate keyword set W(d) in the current patent text: TF-IDF(W da )=TF(W da )×IDF(W da )=(E da / f)×[log2(g)-log2(H da )], Among them, TF-IDF(W da ) represents the candidate keyword W in the candidate keyword set W(d) da The weight in the patent text numbered d; S24, arranging the weights of the keywords in the current candidate keyword set W(d) in descending order, and selecting the candidate keywords corresponding to the first n weights as the patent keyword group K(d) of the current patent text numbered d: K(d)={K d1 ,...,K dm ,...,K dn }, Among them, K dm represents the mth patent keyword in the patent keyword group K(d), 1≤m≤n, and m and n are positive integers; S25, vectorize the patent keyword group K(d) of the current patent text numbered d and send it to the calculation module: V(d)={V d1 ,...,V dm ,...,V dn }, Among them, V(d) is the vectorized representation of the patent keyword group K(d). The number of dimensions in V(d) is the same as the number of patent keywords in the patent keyword group K(d), and each dimension in V(d) corresponds to the patent keyword in the patent keyword group K(d). dm represents the value of the mth dimension in V(d), V dm The value is the patent keyword K dm The weight in the corresponding patent text; When the searcher enters a search keyword phrase, S2 also includes the following sub-steps S21' to S24' that are performed in parallel with S21 to S25: S21', the searcher enters q different search keywords to form a search keyword group R: R = {R1, ..., R i ,...,R n }, where R i represents the i-th search keyword in the current search keyword group R, 1≤i≤n, 1≤q≤n, and i, q, n are positive integers. When the search keyword entered by the searcher is a foreign language or abbreviation, the foreign language or abbreviation is translated into Chinese words / characters to form the search keyword group R. When q<n, the (q+1)th search keyword R in the search keyword group R is q+1 、nth search keyword R n And the search keywords between them are all represented by "NULL"; S22', the search keyword group R enters the extraction module, and the extraction module records the number of times each search keyword in the current search keyword group R appears in each word segmentation set currently contained in the extraction module, the number of word segmentation sets in which each search keyword in the current search keyword group R appears, and the total number t of word segmentation sets currently contained in the extraction module, and calculates the word frequency of each search keyword in the current search keyword group R: Where P(s) represents the word set corresponding to the patent text numbered s, and the word set P(s) is one of the t word sets currently contained in the extraction module, TF[R i |P(s)] represents the search keyword R i The frequency of words appearing in the word set P(s) currently contained in the extraction module, that is, the frequency of words appearing in the patent text numbered s, E[R i |P(s)] represents the search keyword R i The number of occurrences in the word set P(s), f[P(s)] represents the total number of words contained in the word set P(s); Calculate the inverse document frequency of each search keyword in the current search keyword group R: IDF(R i )={log2(t)-log2[H(R i )]}, Among them, IDF(R i ) indicates the search keyword R i The inverse document frequency of the t word sets currently contained in the extraction module, H(R i ) indicates that the current t word sets of the extraction module contain the search keyword R i The number of word sets; S23', respectively calculate the weight of each search keyword in the current search keyword group R in the patent text corresponding to the t word sets currently contained in the extraction module: Among them, TF-IDF[R i |P(s)] represents the search keyword R in the current search keyword group R i The weight in the patent text corresponding to the word set P(s) currently contained in the extraction module; S24', vectorize the current search keyword group R based on the t word sets currently contained in the extraction module, form t vector representations and send them to the calculation module: V[R|P(s)]={V[R1|P(s)],...,V[R u |P(s)],...,V[R n |P(s)]}, Where 1≤u≤n, and u and n are positive integers. V[R|P(s)] is the vectorized representation of the current search keyword set R based on the word set P(s). The number of dimensions in V[R|P(s)] is the same as the number of search keywords in the current search keyword set R, both of which are n dimensions. Moreover, each dimension in V[R|P(s)] corresponds to a search keyword in the current search keyword set R one by one. u |P(s)] represents the value of the u-th dimension in V[R|P(s)], V[R u The value of |P(s)] is the search keyword R u The weight in the patent text corresponding to the word set P(s) currently contained in the extraction module; The following sub-steps are also included in S3: S31, the calculation module calculates the similarity between the current search keyword group R and the patent text corresponding to each vectorized patent keyword group in the current calculation module: in, It represents the arithmetic mean of the weights of each search keyword in the current search keyword group R in the patent text numbered s corresponding to the word set P(s); in, represents the arithmetic mean of the weights of each patent keyword in the patent keyword group K(s) in the corresponding patent text numbered s, V sm represents the mth patent keyword K in the patent keyword group K(s) dm The arithmetic mean of the weights in the corresponding patent text numbered s; Among them, ρ(R,s) represents the similarity between the current search keyword group R and the patent text numbered s. V[R i |P(s)] represents the i-th search keyword R in the current search keyword group R i The weight of the patent text numbered s corresponding to the word set P(s), 1≤i≤n, and i is a positive integer, V sz represents the zth patent keyword K in the patent keyword group K(s) sz The weight in the corresponding patent text numbered s, 1≤z≤n, and z is a positive integer; S32, after arranging the similarities between the current search keyword group R and the patent texts corresponding to the patent keyword groups represented by the vectorization in the current calculation module in descending order, the arrangement result is transmitted to the output module.
2. A similarity-based patent search method according to claim 1, characterized in that: The following are also included in S4: The output module takes the first L similarities in the current similarity descending order, and retrieves the patent documents bound to the corresponding numbers in the local database according to the numbers attached to these L similarities. It then arranges the patent documents in descending order of similarity and outputs them as search results, which are then fed back to the searcher.
3. A similarity-based patent search method according to claim 2, characterized in that: The searcher can set the number of feedback articles for the search results in advance. The output module retrieves the patent documents arranged in descending order of similarity according to the number of feedback articles set by the searcher for output feedback.
4. A similarity-based patent search method according to claim 3, characterized in that: L is 30 and n is 6.
5. A similarity-based patent search system, characterized in that: include: Capture module, local database, text module, word segmentation module, extraction module, calculation module, output module; The capture module is used to capture patent documents from major platforms and patent subject databases and remove the duplicate patent documents stored in the local database before sending them to the local database; The local database is used to store the patent documents sent by the crawling module and send the newly added patent documents to the text module; The text module is used to process the patent documents sent from the local database to obtain patent texts, and send the patent texts to the word segmentation module; The word segmentation module is used to segment the patent text sent by the text module to form a word set, and then send the word set to the extraction module; The extraction module is used to extract keywords from the word set to form patent keyword groups, and then vectorize them and send them to the calculation module. When the searcher types in the search keyword group, the extraction module vectorizes the search keyword group and sends it to the calculation module; The calculation module is used to calculate the similarity between each patent keyword group and the current search keyword group, and output them in descending order to the output module; The output module feeds back the corresponding patent text to the searcher based on the results sorted in descending order of similarity; Each module is programmed or configured to execute the steps of a similarity-based patent search method as described in any one of claims 1-4.
6. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program programmed or configured to execute a similarity-based patent search method as described in any one of claims 1 to 4.
