A patent retrieval method, device and equipment for multiple retrieval scenarios

By constructing a language model for the patent field and selecting patent semantic representation models, the problem of insufficient semantic extraction of highly specialized patent documents by general language models is solved, thereby improving the accuracy of patent retrieval.

CN116303989BActive Publication Date: 2025-11-25ZHEJIANG LAB
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310212099.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-02-28
Publication Date
2025-11-25
Estimated Expiration
2043-02-28

AI Technical Summary

Technical Problem

General language models struggle to fully extract semantic information from highly specialized patent documents, resulting in low accuracy of semantic vectors in patent documents, which in turn affects the accuracy of retrieval.

Method used

By acquiring patent documents containing multiple patent fields as training data, the general language model is adjusted to construct a patent domain language model. Positive and negative samples are then filtered through multi-path recall with different weights and random sampling to construct a patent semantic representation model and improve semantic representation capabilities.

Benefits of technology

It improves the semantic representation capabilities of the patent semantic representation model in various retrieval scenarios, thereby enhancing the accuracy of patent retrieval.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116303989B_ABST
    Figure CN116303989B_ABST
Patent Text Reader

Abstract

The specification discloses a patent retrieval method, device and equipment for multiple retrieval scenarios. Patent field language models are obtained by training general language models with fields of patent documents as training data. For multiple retrieval scenarios, positive and negative samples of each patent document are screened through different weight multi-path recall and random sampling, and training data of a patent semantic representation model of each retrieval scenario is constructed to train the patent field language models, and then the patent semantic representation model of each retrieval scenario is obtained to generate semantic vectors of each field of the patent, and the semantic vectors are stored in a patent retrieval vector database of each retrieval scenario. According to the semantic vectors of the retrieval fields, similar patent documents are searched from the patent retrieval vector database of the target retrieval scenario. Through the above scheme, the semantic representation ability of the patent semantic representation model for the patent fields of different retrieval scenarios is improved, and the retrieval precision is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This specification relates to the field of natural language processing, and in particular to a patent retrieval method, apparatus, and device for various retrieval scenarios. Background Technology

[0002] Patent document retrieval refers to the process of filtering patent documents from a large number of patent documents based on the search fields entered by the user to obtain patent documents related to the search fields.

[0003] With the development of artificial intelligence, it is now possible to determine the semantic vector of the patent document and the semantic vector of the search field using a general language model. Then, by measuring the similarity between the semantic vector of the search field and the semantic vector of the patent document, the patent document related to the search field can be identified.

[0004] However, some patent documents contain specialized fields, which often include a large number of unique words, syntaxes, and sentence structures. In such cases, general language models struggle to fully extract semantic information from these highly specialized patent documents, resulting in low accuracy of the semantic vectors and consequently, reduced retrieval accuracy.

[0005] Based on this, this specification provides a patent search method for various search scenarios. Summary of the Invention

[0006] This specification provides a patent search method, apparatus, and device for various search scenarios, in order to partially solve the aforementioned problems existing in the prior art.

[0007] The following technical solution is adopted in this specification:

[0008] This specification provides a patent search method for various search scenarios. For multiple pre-stored patent documents, each containing multiple patent fields relevant to different search scenarios, the method includes:

[0009] Obtain patent documents containing multiple patent fields as training data for a patent domain language model;

[0010] Based on the training data of the patent domain language model, the model parameters of the general language model are adjusted using unsupervised learning to obtain the patent domain language model.

[0011] For each retrieval scenario, positive sample documents for each patent document are determined by multi-path recall based on different weights, and negative sample documents for each patent document are determined by random sampling. Based on the patent field corresponding to the retrieval scenario, positive examples of the patent field are determined from the positive sample documents of the patent documents to which the patent field belongs, and negative examples of the patent field are determined from the negative sample documents of the patent documents to which the patent field belongs. Based on the patent field, the positive examples of the patent field, and the negative examples of the patent field, training data for the patent semantic representation model of the retrieval scenario is constructed.

[0012] Based on the training data of the patent semantic representation model for this retrieval scenario, the model parameters of the patent domain language model are learned and adjusted to obtain the patent semantic representation model for this retrieval scenario.

[0013] Based on the patent fields targeted by each retrieval scenario and the patent semantic representation model of each retrieval scenario, the semantic vector of each patent field is determined, and the correspondence between the semantic vector of each patent field and the patent document to which each patent field belongs is stored in the patent retrieval vector database of the retrieval scenario targeted by each patent field.

[0014] When a retrieval request is received, the semantic vector of the retrieval field is determined based on the target retrieval scenario corresponding to the retrieval request and the patent semantic representation model of the target retrieval scenario.

[0015] Based on the semantic vector of the search field, patent documents similar to the search field are searched from the patent search vector database of the target search scenario and returned as the search results corresponding to the search field.

[0016] Optionally, positive sample documents for each patent document are determined through a multi-path recall method based on different weights, specifically including:

[0017] For each patent document, the character similarity and semantic similarity between the patent document and the other patent documents in each patent field are determined to obtain multi-path similarity results;

[0018] Based on the search scenario, the similarity weights of the multi-path similarity results under the search scenario are determined, and the multi-path similarity results are weighted and fused according to the similarity weights to obtain the weighted similarity between the patent document and each of the other patent documents under the search scenario.

[0019] Based on the weighted similarity between the patent document and each of the other patent documents in the search scenario, patent documents similar to the patent document are identified and used as positive sample documents for the patent document.

[0020] Optionally, before determining patent documents similar to the patent document based on the weighted similarity between the patent document and each of the other patent documents in the search scenario, the method further includes:

[0021] Determine the classification number of the patent document;

[0022] Remove patent documents from the remaining patent documents that have a different classification number than the patent document in question.

[0023] Optionally, negative sample documents for each patent document are determined through random sampling, specifically including:

[0024] Determine the classification number of the patent document, and based on the classification number of the patent document, remove the patent documents from the remaining patent documents whose classification numbers are different from that of the patent document;

[0025] Random sampling is performed on the remaining patent documents to obtain candidate documents;

[0026] Determine whether the character similarity between the candidate document and the patent document in each patent field is not higher than a first similarity threshold, and whether the semantic similarity between the candidate document and the patent document in each patent field is not higher than a second similarity threshold;

[0027] If so, the candidate document is determined to be a negative sample document of the patent document;

[0028] If not, random sampling is performed again on the remaining patent documents to obtain candidate documents again, and the judgment is repeated until the number of negative sample documents for the patent document reaches the preset number.

[0029] Optionally, the character similarity between the patent document and the other patent documents in each patent field is determined, specifically including:

[0030] The patent document is segmented into words to obtain the words contained in each patent field.

[0031] For each patent field of the patent document, the character similarity between the patent document and the other patent documents in each patent field is determined based on the weight of each word contained in the patent field, the frequency of each word contained in the patent field in the patent field, and the frequency of each word contained in the patent field in the patent fields contained in the other patent documents.

[0032] Optionally, the semantic similarity between this patent document and the other patent documents in each patent field is determined, specifically including:

[0033] Each patent field of the patent document is input into the patent domain language model to obtain the semantic vector of each patent field of the patent document output by the patent domain language model.

[0034] Each patent field contained in the remaining patent documents is input into the patent domain language model to obtain the semantic vectors of each patent field contained in the remaining patent documents output by the patent domain language model.

[0035] Based on the similarity between the semantic vectors of each patent field in the patent document and the semantic vectors of each patent field in the remaining patent documents, the semantic similarity between the patent document and the remaining patent documents in each patent field is determined.

[0036] Optionally, based on the training data of the patent semantic representation model for this retrieval scenario, the model parameters of the patent domain language model are learned and adjusted to obtain the patent semantic representation model for this retrieval scenario, specifically including:

[0037] Using the patent field, positive examples of the patent field, and negative examples of the patent field in the training data of the patent semantic representation model for this retrieval scenario as input, the semantic vector of the patent field for this retrieval scenario, the semantic vector of the positive examples of the patent field for this retrieval scenario, and the semantic vector of the negative examples of the patent field for this retrieval scenario are obtained through the patent domain language model.

[0038] Determine the first similarity between the semantic vector of the patent field for this retrieval scenario and the semantic vector of the positive example of the patent field for this retrieval scenario;

[0039] Determine the second similarity between the semantic vector of a patent field for this retrieval scenario and the semantic vector of a negative example of a patent field for this retrieval scenario;

[0040] Determine the difference between the first similarity and the second similarity;

[0041] With the goal of the difference being greater than a preset parameter, the model parameters of the patent domain language model are learned and adjusted to obtain the patent semantic representation model for this retrieval scenario.

[0042] Optionally, based on the patent fields targeted by each search scenario and the patent semantic representation model of each search scenario, the semantic vector of each patent field is determined, specifically including:

[0043] For each patent field, based on the retrieval scenario that the patent field is intended for, the corresponding patent semantic representation model is determined from the patent semantic representation models of each retrieval scenario;

[0044] The patent field is input into the corresponding patent semantic representation model to obtain the semantic vector of the patent field output by the corresponding patent semantic representation model.

[0045] Optionally, from the patent search vector database of the target search scenario, patent documents similar to the search field are searched, specifically including:

[0046] Determine the similarity between the semantic vector of the search field and the semantic vectors stored in the patent search vector database of the target search scenario;

[0047] Several semantic vectors with similarity higher than a preset similarity threshold are selected as candidate vectors.

[0048] Based on the correspondence stored in the patent retrieval vector database for the target retrieval scenario, the patent documents corresponding to the candidate vectors are determined as patent documents similar to the retrieval fields.

[0049] This specification provides a patent search device for multiple search scenarios. For multiple pre-stored patent documents, each containing multiple patent fields applicable to different search scenarios, the device includes:

[0050] The patent domain language model training data generation module is used to obtain patent documents containing multiple patent fields as training data for the patent domain language model.

[0051] The patent domain language model training module is used to adjust the model parameters of the general language model using unsupervised learning based on the training data of the patent domain language model, so as to obtain the patent domain language model.

[0052] The multi-scenario patent semantic representation model training data generation module is used to determine the positive sample documents of each patent document and the negative sample documents of each patent document through multi-path recall based on different weights for each retrieval scenario. Based on the patent field corresponding to the retrieval scenario, it determines the positive examples of the patent field from the positive sample documents of the patent documents to which the patent field belongs, and the negative examples of the patent field from the negative sample documents of the patent documents to which the patent field belongs. Based on the patent field, the positive examples of the patent field, and the negative examples of the patent field, the training data of the patent semantic representation model for the retrieval scenario is constructed.

[0053] The multi-scenario patent semantic representation model training module is used to learn and adjust the model parameters of the patent domain language model based on the training data of the patent semantic representation model for the retrieval scenario, so as to obtain the patent semantic representation model for the retrieval scenario.

[0054] The multi-scenario patent semantic vector database construction module is used to determine the semantic vector of each patent field based on the patent fields targeted by each retrieval scenario and the patent semantic representation model of each retrieval scenario, and to store the correspondence between the semantic vector of each patent field and the patent document to which each patent field belongs in the patent retrieval vector database of the retrieval scenario targeted by each patent field.

[0055] The semantic vector generation module for retrieval fields is used to determine the semantic vector of the retrieval field based on the target retrieval scenario corresponding to the retrieval request and the patent semantic representation model of the target retrieval scenario when a retrieval request is received.

[0056] The multi-scenario retrieval module is used to search for patent documents similar to the search field from the patent retrieval vector database of the target retrieval scenario based on the semantic vector of the search field, and return them as the retrieval results corresponding to the search field.

[0057] This specification provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the aforementioned patent search method for various search scenarios.

[0058] This specification provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the aforementioned patent search method for various search scenarios.

[0059] The above-mentioned technical solutions adopted in this specification can achieve the following beneficial effects:

[0060] The patent retrieval method for various retrieval scenarios provided in this specification uses patent documents containing multiple patent fields as training data for a patent domain language model. This data is used to train a general language model, resulting in a patent domain language model. For each retrieval scenario, positive sample documents for each patent document are determined through multi-path recall with different weights, and negative sample documents are determined through random sampling. Positive and negative examples of each patent field are selected based on the patent fields of that retrieval scenario, and this data is used to construct training data for a patent semantic representation model for that retrieval scenario. This allows for adjustment of the model parameters of the patent domain language model, resulting in a patent semantic representation model for that retrieval scenario. The correspondence between the semantic vectors of each patent field and the patent documents to which each patent field belongs is stored in the patent retrieval vector database for the retrieval scenario each patent field is targeting. This enables the search for patent documents similar to the search field in the patent retrieval vector database of the target retrieval scenario when a retrieval request is received, based on the semantic vector of the search field. As can be seen, by training the model based on the training data of the patent domain language model, obtaining the patent domain language model, and then adjusting the parameters of the patent domain language model based on the training data of the patent semantic representation model for each retrieval scenario containing patent fields, positive examples, and negative examples, the patent semantic representation model for each retrieval scenario is obtained. This method improves the semantic representation capability of the patent semantic representation model for the semantic representation of patent fields for various different retrieval scenarios, thereby improving retrieval accuracy. Attached Figure Description

[0061] The accompanying drawings, which are included to provide a further understanding of this specification and form part of this specification, illustrate exemplary embodiments and are used to explain this specification, but do not constitute an undue limitation thereof. In the drawings:

[0062] Figure 1 This is a flowchart illustrating a patent search method for various search scenarios described in this specification.

[0063] Figure 2 This is a flowchart illustrating a patent search method for various search scenarios described in this specification.

[0064] Figure 3 This is a schematic diagram of a process for selecting positive sample documents based on multi-path recall in this specification;

[0065] Figure 4 This is a flowchart illustrating one method for selecting negative sample documents in this specification.

[0066] Figure 5 This is a schematic diagram illustrating a comparative learning and fine-tuning of a patent semantic identifier model as described in this specification;

[0067] Figure 6This specification provides a schematic diagram of a patent search device designed for various search scenarios.

[0068] Figure 7 The corresponding information provided in this specification Figure 1 A schematic diagram of an electronic device. Detailed Implementation

[0069] To make the objectives, technical solutions, and advantages of this specification clearer, the technical solutions of this specification will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this specification, and not all of them. Based on the embodiments in this specification, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this specification.

[0070] Additionally, it should be noted that all actions involving the acquisition of signals, information, or data in this invention are carried out in compliance with the relevant data protection laws and regulations of the country where the invention is located, and with authorization from the owner of the corresponding device.

[0071] With the rapid development of artificial intelligence and natural language processing technologies, there is an increasing demand in practical applications for patent document retrieval based on user-input search fields. Current patent document retrieval methods mainly include keyword matching-based retrieval and semantic-based retrieval.

[0072] For keyword-based search methods: if the search field is long, directly using the complete search field to find related patent documents will result in low search efficiency and accuracy. Therefore, keywords can be extracted from the long search field to search for patent documents. However, extracting keywords from the search field may result in the keywords not fully representing the semantics of the search field. In other words, using keywords to represent the search field loses the complete semantic information of the search field, fails to utilize the contextual information of the keywords, and limits search accuracy.

[0073] For semantic retrieval methods: Currently, a general language model can be used to determine the semantic vectors of patent documents and search fields separately. Then, the similarity between the semantic vectors of the search fields and the semantic vectors of the patent documents is used to identify patent documents related to the search fields. However, there are cases where patent documents contain specialized fields, which often contain a large number of special words, syntax, and sentence structures. In such cases, the general language model struggles to fully extract semantic information from these highly specialized patent documents, resulting in low accuracy of the semantic vectors of the patent documents, and consequently, a decrease in retrieval accuracy.

[0074] Based on this, this specification provides a patent retrieval method for various retrieval scenarios. It involves training a general language model using each field of a patent document as training data to obtain a patent domain language model. For various retrieval scenarios, positive and negative samples from each patent document are selected using multi-path recall with different weights and random sampling. This data is then used to construct training data for patent semantic representation models for each retrieval scenario. This method improves the semantic representation capabilities of the patent semantic representation model for highly specialized patent fields and for different retrieval scenarios, thereby enhancing retrieval accuracy.

[0075] Specifically, patent search refers to the process of selecting patent documents from a large number of patent documents that match the semantics represented by the search fields entered by the user.

[0076] The technical solutions provided in the various embodiments of this specification are described in detail below with reference to the accompanying drawings.

[0077] Figure 1 This specification provides a flowchart illustrating a patent search method for various search scenarios.

[0078] S100: Obtain patent documents containing multiple patent fields as training data for the patent domain language model.

[0079] This specification provides a patent search method for multiple search scenarios. The execution of this method can be performed by an electronic device such as a server that processes search requests. The language models involved in this search method include a general language model, a patent domain language model, and patent semantic representation models corresponding to each search scenario. The electronic device performing the training process can be the same as or different from the electronic device executing the patent search method for multiple search scenarios; this specification does not impose any limitations on this.

[0080] In practical applications, a general language model can be used to extract the semantics of the search field and the patent document separately, determining the semantic vectors of the search field and the patent document. The similarity between these two semantic vectors is then used to identify patent documents whose semantics are relevant to the search field, serving as the search result. In this process, the general language model is pre-trained on a general corpus, indicating its accuracy in semantic extraction from general corpora. However, there are cases where patent documents contain specialized fields, often including numerous unique words, syntaxes, and sentence structures. In these cases, the general language model's ability to extract the semantics of the patent document is weaker, leading to a decrease in the accuracy of the output semantic vector and consequently, a decline in search accuracy.

[0081] Based on this, patent documents containing patent fields can be used as training data for a patent domain language model. The model parameters of a general language model can be adjusted based on the training data of this patent domain language model, so that the patent domain language model obtained by parameter adjustment can extract the semantics of patent fields more accurately, obtain more accurate semantic vectors of patent fields, and thus improve the accuracy of retrieval.

[0082] It is understood that in one or more embodiments of this specification, the patent search method for multiple search scenarios provided in this specification searches patent documents. These patent documents contain patent fields that are targeted at multiple different search scenarios. Generally, a patent field corresponds one-to-one with its target search scenario; for example, the abstract field in a patent document is targeted at the abstract search scenario. Additionally, depending on the specific application scenario, there may be patent fields that are not targeted at any search scenario. For example, the invention content field in a patent document may not have a corresponding invention content search scenario. That is, the number of search scenarios a patent field is targeted at generally does not exceed the number of patent fields contained in the patent document. Optionally, in practical applications, there may also be composite search scenarios, such as abstract and claim search scenarios. For such composite search scenarios, in the embodiments of this specification, the search results of the composite search scenario can be determined based on the search results returned by multiple search scenarios respectively.

[0083] In this step, the patent fields can be obtained by extracting them from pre-stored patent documents. The pre-stored patent documents contain patent fields for multiple search scenarios. The search scenarios and semantics represented by each patent field are usually different. Multiple different types of patent fields can be identified from the pre-stored patent documents through manual annotation. Of course, any existing method can also be used, and this specification does not limit this.

[0084] In an optional embodiment of this specification, patent fields of various types can be determined from pre-stored patent documents using regular expression matching. First, the pre-stored patent documents can be in the form of unstructured data, such as patent documents in Extensible Markup Language (XML). Based on the pre-stored patent documents, a regular expression for extracting patent fields can be determined. The determined regular expression is then matched against each patent document, and the patent fields matched by the regular expression are taken as the extracted patent fields.

[0085] Optionally, the extracted patent fields can then be preprocessed, such as converting Chinese characters from half-width to full-width and English characters to lowercase. This specification does not specify the method of patent field preprocessing.

[0086] S102: Based on the training data of the patent domain language model, the model parameters of the general language model are adjusted using unsupervised learning to obtain the patent domain language model.

[0087] Specifically, the training data of the patent domain language model is input into a pre-trained general language model. Based on whole-word masking, the model parameters of the general language model are adjusted. According to the optimized model parameters and the model structure of the general language model, the patent domain language model is obtained. The trained patent domain language model possesses the ability to extract relatively accurate semantics from patent fields.

[0088] In the process of training the language model for the patent domain, the so-called whole-word masking method refers to the fact that in the whole-word mask, if part of a complete word is masked, then other parts belonging to the same word will also be masked.

[0089] Since the general language model has been pre-trained and has a certain ability to extract semantics, it only needs to be adapted to the patent domain corresponding to the training data of the patent domain language model. Therefore, the amount of training data for the patent domain language model can be less than the general corpus used to train the general language model.

[0090] S104: For each retrieval scenario, positive sample documents for each patent document are determined by multi-path recall based on different weights, and negative sample documents for each patent document are determined by random sampling. Based on the patent field corresponding to the retrieval scenario, positive examples of the patent field are determined from the positive sample documents of the patent documents to which the patent field belongs, and negative examples of the patent field are determined from the negative sample documents of the patent documents to which the patent field belongs. Based on the patent field, the positive examples of the patent field, and the negative examples of the patent field, training data for the patent semantic representation model of the retrieval scenario is constructed.

[0091] To further improve the accuracy of retrieval, the parameters of the already trained patent domain language model can be adjusted again for different retrieval scenarios to obtain a patent semantic representation model suitable for different retrieval scenarios. This will enable patent document retrieval based on the patent semantic representation model to be applicable not only to the patent domain but also to different subdivided retrieval scenarios within the patent domain.

[0092] Specifically, in order to obtain patent semantic representation models for different retrieval scenarios, training data for the patent semantic representation model of each retrieval scenario can be constructed. Then, based on the training data of the patent semantic representation model of the retrieval scenario, the patent semantic representation model of the retrieval scenario can be trained to obtain the patent semantic representation model of the retrieval scenario.

[0093] In the embodiments of this specification, based on the idea of ​​contrastive learning, the training data for the patent semantic representation model of the retrieval scenario is a triplet oriented towards the retrieval scenario. Each triplet contains a patent field oriented towards the retrieval scenario, a positive example of that patent field, and a negative example of that patent field. It is understood that since the training data for the patent semantic representation model of the retrieval scenario is used to train the model in subsequent steps, the positive and negative examples of the patent field are typically oriented towards the same retrieval scenario as the patent field itself.

[0094] Furthermore, for the patent field in the triple, the source of positive examples can be positive sample documents similar to the patent document to which the patent field belongs, and the source of negative examples can be negative sample documents dissimilar to the patent document to which the patent field belongs. Therefore, the positive and negative sample documents for each patent document can be determined first.

[0095] Specifically, positive sample documents for each patent document are determined using a multi-path recall method with different weights. Multi-path recall refers to recalling other patent documents similar to the patent document in each of the patent fields that are relevant to multiple different search scenarios. The positive sample documents for the patent document are then determined by combining the weights of these other similar patent documents in each search scenario.

[0096] Negative sample documents for each patent document are determined using a random sampling method. The randomly sampled candidate negative sample documents can be determined based on the multipath recall results obtained during the process of obtaining positive sample documents described above.

[0097] This specification does not limit the number of positive and negative sample documents for each patent document, but generally, the number of positive sample documents for a patent document is the same as the number of negative sample documents for that patent document.

[0098] Subsequently, for each retrieval scenario, the positive examples of the patent field determined from the positive sample documents of the patent document to which the patent field belongs, and the negative examples of the patent field determined from the negative sample documents of the patent document to which the patent field belongs, are combined to obtain the training data of the patent semantic representation model for that retrieval scenario.

[0099] For example, for patent document A, patent document B is identified as the positive sample document and patent document C as the negative sample document. Then, for the abstract retrieval scenario, the abstract field a1 of patent document A, the abstract field b1 of patent document B, and the abstract field c1 of patent document C are identified, which constitute the training data (a1, b1, c1) of the patent semantic representation model for the abstract retrieval scenario.

[0100] S106: Based on the training data of the patent semantic representation model for this retrieval scenario, the model parameters of the patent domain language model are learned and adjusted to obtain the patent semantic representation model for this retrieval scenario.

[0101] Specifically, the patent fields, positive examples of patent fields, and negative examples of patent fields contained in the training data of the patent semantic representation model for this retrieval scenario can be used as inputs to the patent domain language model. The semantic vectors of the patent fields, the semantic vectors of the positive examples of patent fields, and the semantic vectors of the negative examples of patent fields in the training data of the patent semantic representation model for this retrieval scenario can be obtained through the patent domain language model.

[0102] Furthermore, based on the idea of ​​contrastive learning, a loss function is determined according to the semantic vectors of patent fields, positive examples of patent fields, and negative examples of patent fields output by the patent domain language model. The model parameters of the patent domain language model are adjusted with the minimization of the loss function as the optimization objective, resulting in optimized model parameters. Then, based on the optimized model parameters and the model structure of the patent domain language model, a patent semantic representation model for this retrieval scenario is obtained.

[0103] Through the above training process, patent semantic representation models for various retrieval scenarios are obtained. These models can extract semantics from highly specialized patent fields with relatively high accuracy and are adaptable to different types of retrieval scenarios. This achieves the precision and contextualization of semantic vectors, thereby further improving retrieval accuracy.

[0104] S108: Based on the patent fields targeted by each retrieval scenario and the patent semantic representation model of each retrieval scenario, determine the semantic vector of each patent field, and store the correspondence between the semantic vector of each patent field and the patent document to which each patent field belongs in the patent retrieval vector database of the retrieval scenario targeted by each patent field.

[0105] Specifically, in actual search scenarios, users can input different types of search fields under different search conditions. For example, the patent field type can be a patent abstract type or a background technology type, etc. Users can determine whether to conduct a patent search in the abstract search scenario or the background technology search scenario according to their actual search needs.

[0106] Based on this, the semantic representation models for each retrieval scenario trained in step S106 above are used to extract semantics from the patent fields for each retrieval scenario, resulting in semantic vectors for each patent field. In this embodiment of the specification, patent documents related to the retrieval fields under different retrieval scenarios are determined based on vector retrieval. Therefore, the semantic vectors of each patent field can be stored in a patent retrieval vector database for each retrieval scenario according to the retrieval scenario to which the patent field is directed. The correspondence between the semantic vectors of each patent field and the patent documents to which the patent field belongs is also stored in the patent retrieval vector database for each retrieval scenario. This correspondence is used as an index for retrieval, allowing for quick searching of patent documents related to the retrieval fields from the patent retrieval vector database, thereby improving retrieval efficiency.

[0107] Specifically, for each patent field, based on the retrieval scenario it targets, the patent field is input into the patent semantic representation model corresponding to that retrieval scenario to obtain its semantic vector. Further, the semantic vector of the patent field, the correspondence between the semantic vector and the patent document to which the patent field belongs, are stored in the patent retrieval vector database corresponding to the retrieval scenario targeted by that patent field.

[0108] S110: When a retrieval request is received, the semantic vector of the retrieval field is determined based on the target retrieval scenario corresponding to the retrieval request and the patent semantic representation model of the target retrieval scenario.

[0109] Generally, when users enter search fields, they can select the search scenario they need, so that they can obtain patent documents related to the search fields in the desired search scenario.

[0110] Alternatively, if the user does not select a search scenario, the search scenario of the user's previous searches can be determined as the target search scenario for this search.

[0111] The search text is input into a patent semantic representation model for the target search scenario, and the model outputs a semantic vector of the search field.

[0112] Optionally, users can input search fields without restricting the search scenario they correspond to. In this case, the search fields can be input into the patent semantic representation models corresponding to each type of patent field, resulting in semantic vectors for each type of patent field output by the respective models. These semantic vectors are then fused to obtain a fused semantic vector, which serves as the semantic vector for the search field. Whether or not to restrict the search scenario corresponding to the search field can be determined based on the specific application scenario; this specification does not impose specific limitations on this.

[0113] S112: Based on the semantic vector of the search field, search for patent documents similar to the search field from the patent search vector database of the target search scenario, and return them as the search results corresponding to the search field.

[0114] Specifically, based on the target retrieval scenario, the source of semantic vectors that are semantically similar to the retrieval field can be determined from the corresponding patent retrieval vector database. The semantic vectors contained in the patent retrieval vector database corresponding to the target retrieval scenario are compared with the semantic vectors of the retrieval field to determine their similarity. Several semantic vectors similar to the semantic vectors of the retrieval field are identified, and patent documents related to the retrieval field are selected as retrieval results based on the correspondence determined in step S110 above. Subsequently, several patent documents related to the retrieval field are returned to the user as retrieval results. The number of retrieval results returned to the user is not limited in this specification.

[0115] Optionally, when the search scenario is not restricted, several semantic vectors similar to the semantic vector of the search field can be determined from the semantic vectors stored in the patent search vector database for all search scenarios, based on the semantic vector of the search field, and then the search results can be obtained.

[0116] The patent retrieval method provided in this specification for various retrieval scenarios obtains a patent domain language model based on training data of the patent domain language model, and then obtains a patent semantic representation model for each retrieval scenario based on training data of the patent semantic representation model for each retrieval scenario, which includes patent fields, positive examples, and negative examples. This improves the semantic representation capability of the patent semantic representation model for the semantic representation of patent fields for various different retrieval scenarios, thereby improving retrieval accuracy.

[0117] In one or more embodiments of this specification, in such Figure 1Step S104 shows the process of determining positive sample documents for each patent document using a multi-path recall method based on different weights, such as... Figure 2 The specific solution is as follows:

[0118] S200: For each patent document, determine the character similarity and semantic similarity between the patent document and the other patent documents in each patent field to obtain multi-path similarity results.

[0119] In the embodiments of this specification, character similarity refers to the degree of similarity between characters. For example, the patent field "prediction result" and the patent field "prediction probability" both contain the word "prediction," and based on this, the character similarity between these two patent fields can be determined. Semantic similarity can also refer to the degree of similarity or resemblance between the semantic meanings represented by patent fields. For example, the patent fields "accuracy" and "precision" both represent the semantic meaning of "accuracy," and based on this, the semantic similarity between these two patent fields can be determined.

[0120] Generally, patent documents with character similarity and semantic similarity both exceeding a preset threshold can be considered as positive samples of the patent document to which that patent field belongs. However, in practical applications, the above screening scheme is too strict and may result in too few positive samples of the patent document to which that patent field belongs. Therefore, a method of setting similarity thresholds for the determined character similarity and semantic similarity can be used for separate screening.

[0121] In this step, the character similarity and semantic similarity between the patent document and the other patent documents in each patent field are determined. The other patent documents refer to all patent documents other than the patent document in the pre-stored patent documents.

[0122] For each patent document, there are multiple patent fields, such as title, abstract, technical field, background art, and claims. For each patent field in the patent document that is relevant to a specific search scenario, the character similarity and semantic similarity between that patent field and the patent fields in other patent documents that are relevant to that search scenario can be determined.

[0123] For example, for the title field a1 and the abstract field a2 contained in patent document A, the character similarity between the title field a1 and the title field b1 of patent document B can be determined, and the character similarity and semantic similarity between the abstract field a2 and the abstract field b2 of patent document B can be determined.

[0124] Optionally, the similarity used to determine the positive samples of patent documents to which a particular patent field belongs can be dynamically adjusted based on different actual situations and the professional field to which the patent documents belong. Taking the patent field as an example, in patent documents, since the title type of patent field is a high-level summary of the specific content of the patent document, there may be cases where the semantic information is too limited. Therefore, when filtering the positive samples of patent documents to which the title type of patent field belongs, positive samples similar to the patent documents to which the patent field belongs can be determined solely based on character similarity.

[0125] Then, based on the determined character similarity and semantic similarity, as well as the preset similarity threshold, the recall results for the patent document under each patent field are determined. It is understandable that under a single patent field, the patent document may have two recall results. Optionally, under the title field, recall may be based solely on character similarity. Therefore, as... Figure 3 As shown, for the five fields of title, abstract, technical field, background art, and claims contained in a patent document, nine recall results can be obtained based on character similarity and semantic similarity. Each recall result includes multiple patent documents with the highest similarity to the patent document obtained from the current recall loop, as well as the corresponding similarity scores.

[0126] Furthermore, the similarity of the recalled patent documents was normalized.

[0127] S202: Based on the search scenario, determine the similarity weights of the multi-path similarity results under the search scenario, and perform weighted fusion of the multi-path similarity results according to the similarity weights to obtain the weighted similarity between the patent document and each of the other patent documents under the search scenario.

[0128] In this step, based on the nine-way recall results determined in step S200 above, different similarity weights can be assigned to the in-path recall results of the patent document in different retrieval scenarios. These similarity weights can be preset or dynamically adjusted; this specification does not limit their application.

[0129] For each recalled patent document and its similarity, different similarity weights are assigned, and the results of multiple recalls are weighted and summed to obtain the weighted similarity between the patent document and each of the other patent documents.

[0130] S204: Based on the weighted similarity between the patent document and each of the other patent documents in the search scenario, determine the patent documents similar to the patent document and use them as positive sample documents for the patent document.

[0131] Generally, multiple patent documents with a weighted similarity greater than a preset similarity threshold are used as positive sample documents for that patent document.

[0132] Optionally, before determining the positive samples of the patent documents to which the patent field belongs based on weighted similarity, the remaining patent documents can be further filtered according to the attribute information of the patent documents to which the patent field belongs. Specifically, a specified attribute of the patent document to which the patent field belongs is determined, and patent documents from the remaining patent documents that have different attributes from the specified attribute of the patent document to which the patent field belongs are removed. The specified attribute can be the classification number of the patent document.

[0133] In one or more embodiments of this specification, in such Figure 2 Step S200 involves determining the character similarity and semantic similarity between the patent document and the other patent documents in each patent field. This can be achieved through the following scheme:

[0134] The scheme for determining character similarity is as follows: each patent field of the patent document is segmented into words to obtain the words contained in each patent field; for each patent field of the patent document, the character similarity between the patent document and the other patent documents in each patent field is determined based on the weight of each word contained in the patent field, the frequency of each word contained in the patent field in the patent field, and the frequency of each word contained in the patent field in the patent fields contained in the other patent documents.

[0135] The scheme for determining semantic similarity is as follows: Each patent field of the patent document is input into the patent domain language model to obtain the semantic vector of each patent field of the patent document output by the patent domain language model; Each patent field contained in the remaining patent documents is input into the patent domain language model to obtain the semantic vector of each patent field contained in the remaining patent documents output by the patent domain language model; Based on the similarity between the semantic vector of each patent field of the patent document and the semantic vector of each patent field contained in the remaining patent documents, the semantic similarity between the patent document and the remaining patent documents in each patent field is determined.

[0136] Furthermore, in one or more embodiments of this specification, in such... Figure 1 Step S104 shows that negative sample documents for each patent document are determined by random sampling, which can be based on the above. Figure 2 The character similarity and semantic similarity determined as shown identify negative sample documents, such as... Figure 4 As shown, the specific solution is as follows:

[0137] S300: Determine the classification number of the patent document, and based on the classification number of the patent document, remove the patent documents from the remaining patent documents whose classification numbers are different from that of the patent document.

[0138] Determine the part, major class, and minor class of the IPC classification number of the patent document, and then randomly sample from the remaining patent documents among the candidate patents that have the same part, major class, and minor class of the PC classification number of the patent document.

[0139] S302: Randomly sample from the remaining patent documents to obtain candidate documents.

[0140] S304: Determine whether the character similarity between the candidate document and the patent document in each patent field is not higher than the first similarity threshold, and whether the semantic similarity between the candidate document and the patent document in each patent field is not higher than the second similarity threshold. If yes, proceed to step S306; otherwise, proceed to step S308.

[0141] Specifically, the negative sample documents for this patent document are generally not listed above. Figure 2 In step S200, the character similarity and semantic similarity between the candidate document and the patent document obtained from multiple recalls, or in any one of the recall results, are not higher than the corresponding similarity thresholds. Therefore, the character similarity and patent similarity between the candidate document and the patent document in each patent field are determined, and only candidate documents whose character similarity in each patent field is not higher than the first similarity threshold, and whose semantic similarity in each patent field is not higher than the second similarity threshold, are selected as negative sample documents for the patent document.

[0142] S306: Determine that the candidate document is a negative sample document of the patent document.

[0143] S308: Determine whether the number of negative sample documents for the patent document is the preset number. If yes, proceed to step S310; otherwise, return to step S302.

[0144] S310: End.

[0145] In one or more embodiments of this specification, such as Figure 1 As shown in step S106, the model parameters of the patent domain language model are learned and adjusted based on the training data of the patent semantic representation model for this retrieval scenario to obtain the patent semantic representation model for this retrieval scenario. The specific scheme is as follows:

[0146] Step 1: Using the patent field, positive examples of the patent field, and negative examples of the patent field from the training data of the patent semantic representation model for this retrieval scenario as input, and through the patent domain language model, obtain the semantic vector of the patent field for this retrieval scenario, the semantic vector of the positive examples of the patent field for this retrieval scenario, and the semantic vector of the negative examples of the patent field for this retrieval scenario.

[0147] like Figure 5 The diagram illustrates parameter adjustments to a patent domain language model based on training data from a patent semantic representation model. For each retrieval scenario, the training data of the patent semantic representation model for that scenario is input into the patent domain language model. In this step, the input to the patent domain language model is actually the patent fields contained in the training data of that type of patent semantic representation model, including one patent field specific to the retrieval scenario, positive examples of that patent field, and negative examples of that patent field. These three patent fields are then input into the patent domain language model, mapping the one patent field, the positive examples, and the negative examples of that patent field from the training data of that type of patent semantic representation model into the semantic space, resulting in the semantic vectors of the patent field specific to the retrieval scenario, the semantic vectors of the positive examples of that patent field, and the semantic vectors of the negative examples of that patent field.

[0148] Step 2: Determine the first similarity between the semantic vector of the patent field for this retrieval scenario and the semantic vector of the positive examples of the patent field for this retrieval scenario.

[0149] Step 2: Determine the second similarity between the semantic vector of the patent field for this retrieval scenario and the semantic vector of the negative example of the patent field for this retrieval scenario;

[0150] Step 3: Determine the difference between the first similarity and the second similarity.

[0151] Furthermore, it remains the same. Figure 5 As shown, based on the idea of ​​contrastive learning, the training objectives are to reduce the distance between the mapping of the patent field in the semantic space and the mapping of positive examples of the patent field in the semantic space, and to increase the distance between the mapping of the patent field in the semantic space and the mapping of negative examples of the patent field in the semantic space. This trains a patent domain language model to obtain a patent semantic representation model for the retrieval scenario. That is, the training objective is to obtain a patent semantic representation model for the retrieval scenario with the difference between the first similarity and the second similarity exceeding a set threshold. In the embodiments of this specification, the maximization and minimization of the training objectives can be determined according to the specific application scenario, and this specification does not limit this.

[0152] Step 4: Using the difference being greater than a preset parameter as the optimization objective, the model parameters of the patent domain language model are learned and adjusted to obtain the patent semantic representation model for this retrieval scenario.

[0153] Specifically, since maximizing the difference between the first and second similarities may lead to convergence difficulties, preset parameters can be set to construct a loss function based on the difference and the preset parameters.

[0154] Optionally, the function representation of the optimization objective whose difference is greater than the preset parameter can be as follows:

[0155] L=max(d(a,p)-d(a,n)+magin,0)

[0156] Where 'a' represents the semantic vector of the patent field, 'p' represents the semantic vector of the positive example of the patent field, 'n' represents the semantic vector of the negative example of the patent field, and 'd' represents the semantic vector distance calculation function. This calculation function can be any existing function of a defined vector distance, such as Euclidean distance, Chebyshev distance, or cosine distance; this specification does not limit its use. Furthermore, 'margin' in the above formula is a preset parameter that can be determined according to the specific application scenario; this specification does not limit its use. Optionally, in the embodiments of this specification, it can be set to 0.95.

[0157] By adjusting the parameters of the patent domain language model by the above difference being greater than the preset parameters, a patent semantic representation model for this retrieval scenario is obtained, which aims to improve the semantic representation capability of the patent semantic representation model for patent fields in this retrieval scenario.

[0158] Specifically, by adjusting the model parameters of the patent domain language model through backpropagation training, the distance d1 between the semantic vector of the patent field in this retrieval scenario and the semantic vector of the positive examples of the patent field in this retrieval scenario should be smaller, while the distance d2 between the semantic vector of the patent field in this retrieval scenario and the semantic vector of the negative examples of the patent field in this retrieval scenario should be larger, and d2-d1>margin. That is, as... Figure 5 The changes shown before and after training shorten the distance between the semantic space mapping of the patent field in the retrieval scenario obtained by the patent semantic representation model and the semantic space mapping of the positive examples of the patent field in the retrieval scenario obtained by the patent semantic representation model, and increase the distance between the semantic space mapping of the patent field in the retrieval scenario obtained by the patent semantic representation model and the semantic space mapping of the negative examples of the patent field in the retrieval scenario obtained by the patent semantic representation model.

[0159] Figure 6This specification provides a schematic diagram of a patent search device for various search scenarios. The device includes pre-stored patent documents containing patent fields applicable to different search scenarios, specifically:

[0160] The patent domain language model training data generation module 400 is used to obtain patent documents containing multiple patent fields as training data for the patent domain language model.

[0161] The patent domain language model training module 402 is used to adjust the model parameters of the general language model using unsupervised learning based on the training data of the patent domain language model to obtain the patent domain language model.

[0162] The multi-scenario patent semantic representation model training data generation module 404 is used to determine the positive sample documents of each patent document and the negative sample documents of each patent document through multi-way recall based on different weights for each retrieval scenario. Based on the patent field corresponding to the retrieval scenario, it determines the positive examples of the patent field from the positive sample documents of the patent documents to which the patent field belongs, and the negative examples of the patent field from the negative sample documents of the patent documents to which the patent field belongs. Based on the patent field, the positive examples of the patent field, and the negative examples of the patent field, the training data of the patent semantic representation model for the retrieval scenario is constructed.

[0163] The multi-scenario patent semantic representation model training module 406 is used to learn and adjust the model parameters of the patent domain language model based on the training data of the patent semantic representation model of the retrieval scenario, so as to obtain the patent semantic representation model of the retrieval scenario.

[0164] The multi-scenario patent semantic vector database construction module 408 is used to determine the semantic vector of each patent field based on the patent fields targeted by each retrieval scenario and the patent semantic representation model of each retrieval scenario, and to store the correspondence between the semantic vector of each patent field and the patent document to which each patent field belongs in the patent retrieval vector database of the retrieval scenario to which each patent field is targeted.

[0165] The semantic vector generation module 410 for retrieval fields is used to determine the semantic vector of the retrieval field based on the target retrieval scenario corresponding to the retrieval request and the patent semantic representation model of the target retrieval scenario when a retrieval request is received.

[0166] The multi-scenario retrieval module 412 is used to search for patent documents similar to the retrieval field from the patent retrieval vector database of the target retrieval scenario based on the semantic vector of the retrieval field, and return them as the retrieval results corresponding to the retrieval field.

[0167] Optionally, the multi-scenario patent semantic representation model training data generation module 404 is specifically used to: for each patent document, determine the character similarity and semantic similarity between the patent document and the other patent documents in each patent field to obtain multi-path similarity results; determine the similarity weight of the multi-path similarity results under the retrieval scenario, and perform weighted fusion of the multi-path similarity results according to the similarity weight to obtain the weighted similarity between the patent document and the other patent documents under the retrieval scenario; and determine the patent documents similar to the patent document as positive sample documents of the patent document based on the weighted similarity between the patent document and the other patent documents under the retrieval scenario.

[0168] Optionally, before the multi-scenario patent semantic representation model training data generation module 404 determines the patent documents similar to the patent document based on the weighted similarity between the patent document and the remaining patent documents in the retrieval scenario, the multi-scenario patent semantic representation model training data generation module 404 is further used to determine the classification number of the patent document; and to remove patent documents from the remaining patent documents whose classification numbers are different from those of the patent document.

[0169] Optionally, the multi-scenario patent semantic representation model training data generation module 404 is specifically used to: determine the classification number of the patent document; and based on the classification number of the patent document, remove patent documents from the remaining patent documents whose classification numbers are different from the patent document's; randomly sample from the remaining patent documents to obtain candidate documents; determine whether the character similarity between the candidate document and the patent document in each patent field is not higher than a first similarity threshold, and whether the semantic similarity between the candidate document and the patent document in each patent field is not higher than a second similarity threshold; if yes, determine the candidate document as a negative sample document of the patent document; if no, randomly sample from the remaining patent documents again to obtain candidate documents again, and re-determine until the number of negative sample documents of the patent document reaches a preset number.

[0170] Optionally, the multi-scenario patent semantic representation model training data generation module 404 is specifically used to: segment each patent field of the patent document to obtain each word contained in each patent field; and for each patent field of the patent document, determine the character similarity between the patent document and the other patent documents in each patent field based on the weight of each word contained in the patent field, the frequency of each word contained in the patent field in the patent field, and the frequency of each word contained in the patent field in the patent fields contained in the other patent documents.

[0171] Optionally, the multi-scenario patent semantic representation model training data generation module 404 is specifically used to: input each patent field of the patent document into the patent domain language model to obtain the semantic vector of each patent field of the patent document output by the patent domain language model; input each patent field contained in the remaining patent documents into the patent domain language model to obtain the semantic vector of each patent field contained in the remaining patent documents output by the patent domain language model; and determine the semantic similarity between the patent document and the remaining patent documents in each patent field based on the similarity between the semantic vector of each patent field of the patent document and the semantic vector of each patent field contained in the remaining patent documents.

[0172] Optionally, the multi-scenario patent semantic representation model training module 406 is specifically used to take the patent field, positive examples of the patent field, and negative examples of the patent field in the training data of the patent semantic representation model for the retrieval scenario as input, and obtain the semantic vectors of the patent field, the semantic vectors of the positive examples of the patent field, and the semantic vectors of the negative examples of the patent field for the retrieval scenario through the patent domain language model; determine a first similarity between the semantic vectors of the patent field and the semantic vectors of the positive examples of the patent field for the retrieval scenario; determine a second similarity between the semantic vectors of the patent field and the semantic vectors of the negative examples of the patent field for the retrieval scenario; determine the difference between the first similarity and the second similarity; and learn and adjust the model parameters of the patent domain language model with the difference being greater than a preset parameter as the optimization target to obtain the patent semantic representation model for the retrieval scenario.

[0173] Optionally, the multi-scenario patent semantic vector database construction module 408 is specifically used to: for each patent field, determine the patent semantic representation model corresponding to the patent field from the patent semantic representation models of each retrieval scenario according to the retrieval scenario to which the patent field is directed; input the patent field into the patent semantic representation model corresponding to the patent field to obtain the semantic vector of the patent field output by the patent semantic representation model corresponding to the patent field.

[0174] Optionally, the multi-scenario retrieval module 412 is specifically used to: determine the similarity between the semantic vector of the retrieval field and each semantic vector stored in the patent retrieval vector database of the target retrieval scenario; select several semantic vectors with similarity higher than a preset similarity threshold as candidate vectors; and determine the patent document corresponding to the candidate vector as a patent document similar to the retrieval field based on the correspondence stored in the patent retrieval vector database of the target retrieval scenario.

[0175] This specification also provides a computer-readable storage medium storing a computer program that can be used to execute the above-described... Figure 1 The patent search method shown is designed for various search scenarios.

[0176] This instruction manual also provides Figure 7 The diagram shows a schematic structural representation of the electronic device. Figure 7 At the hardware level, the electronic device includes a processor, internal bus, network interface, memory, and non-volatile memory, and may also include other hardware required for the business operations. The processor reads the corresponding computer program from the non-volatile memory into memory and then runs it to achieve the above-mentioned functions. Figure 1 The patent search method shown is designed for various search scenarios. Of course, in addition to software implementation, this specification does not exclude other implementation methods, such as logic devices or a combination of hardware and software, etc. In other words, the execution subject of the following processing flow is not limited to individual logic units, but can also be hardware or logic devices.

[0177] In the 1990s, improvements to a technology could be clearly distinguished as either hardware improvements (e.g., improvements to the circuit structure of diodes, transistors, switches, etc.) or software improvements (improvements to the methodology). However, with technological advancements, many methodological improvements today can be considered direct improvements to the hardware circuit structure. Designers almost always obtain the corresponding hardware circuit structure by programming the improved methodology into the hardware circuit. Therefore, it cannot be said that a methodological improvement cannot be implemented using hardware physical modules. For example, a Programmable Logic Device (PLD) (such as a Field Programmable Gate Array (FPGA)) is such an integrated circuit whose logic function is determined by the user programming the device. Designers can program and "integrate" a digital system onto a PLD themselves, without needing chip manufacturers to design and manufacture dedicated integrated circuit chips. Furthermore, nowadays, instead of manually manufacturing integrated circuit chips, this programming is mostly implemented using "logic compiler" software. Similar to the software compiler used in program development, the original code before compilation must be written in a specific programming language, called a Hardware Description Language (HDL). There are many HDLs, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, and RHDL (Ruby Hardware Description Language). Currently, the most commonly used are VHDL (Very-High-Speed ​​Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art should understand that by simply performing some logic programming on the method flow using one of these hardware description languages ​​and programming it into an integrated circuit, the hardware circuit implementing the logical method flow can be easily obtained.

[0178] The controller can be implemented in any suitable manner. For example, it can take the form of a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, application-specific integrated circuits (ASICs), programmable logic controllers, and embedded microcontrollers. Examples of controllers include, but are not limited to, the following microcontrollers: ARC625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicon Labs C8051F320. A memory controller can also be implemented as part of the control logic of the memory. Those skilled in the art will also recognize that, in addition to implementing the controller in purely computer-readable program code form, the same functionality can be achieved by logically programming the method steps to make the controller take the form of logic gates, switches, ASICs, programmable logic controllers, and embedded microcontrollers. Therefore, such a controller can be considered a hardware component, and the means included therein for implementing various functions can also be considered as structures within the hardware component. Alternatively, the means for implementing various functions can be considered as both software modules implementing the method and structures within the hardware component.

[0179] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, a computer can be, for example, a personal computer, laptop computer, cellular phone, camera phone, smartphone, personal digital assistant, media player, navigation device, email device, game console, tablet computer, wearable device, or any combination of these devices.

[0180] For ease of description, the above devices are described in terms of function, divided into various units. Of course, in implementing this specification, the functions of each unit can be implemented in one or more software and / or hardware.

[0181] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0182] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0183] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0184] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0185] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0186] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.

[0187] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.

[0188] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0189] Those skilled in the art will understand that the embodiments of this specification can be provided as methods, systems, or computer program products. Therefore, this specification may take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this specification may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0190] This specification can be described in the general context of computer-executable instructions that are executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform a specific task or implement a specific abstract data type. This specification can also be practiced in distributed computing environments, where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.

[0191] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the system embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments.

[0192] The above description is merely an embodiment of this specification and is not intended to limit this specification. Various modifications and variations can be made to this specification by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of the claims of this specification.

Claims

1. A patent search method for multiple search scenarios, characterized in that, For multiple pre-stored patent documents, each containing multiple patent fields designed for different search scenarios, the method includes: Obtain patent documents containing multiple patent fields as training data for a patent domain language model; Based on the training data of the patent domain language model, the model parameters of the general language model are adjusted using unsupervised learning to obtain the patent domain language model. For each retrieval scenario, positive sample documents for each patent document are determined by multi-path recall based on different weights, and negative sample documents for each patent document are determined by random sampling. Based on the patent field corresponding to the retrieval scenario, positive examples of the patent field are determined from the positive sample documents of the patent documents to which the patent field belongs, and negative examples of the patent field are determined from the negative sample documents of the patent documents to which the patent field belongs. Based on the patent field, the positive examples of the patent field, and the negative examples of the patent field, training data for the patent semantic representation model of the retrieval scenario is constructed. Based on the training data of the patent semantic representation model for this retrieval scenario, the model parameters of the patent domain language model are learned and adjusted to obtain the patent semantic representation model for this retrieval scenario. Based on the patent fields targeted by each retrieval scenario and the patent semantic representation model of each retrieval scenario, the semantic vector of each patent field is determined, and the correspondence between the semantic vector of each patent field and the patent document to which each patent field belongs is stored in the patent retrieval vector database of the retrieval scenario targeted by each patent field. When a retrieval request is received, the semantic vector of the retrieval field is determined based on the target retrieval scenario corresponding to the retrieval request and the patent semantic representation model of the target retrieval scenario. Based on the semantic vector of the search field, patent documents similar to the search field are searched from the patent search vector database of the target search scenario and returned as the search results corresponding to the search field.

2. The method as described in claim 1, characterized in that, Positive sample documents for each patent document are determined through a multi-path recall method based on different weights, specifically including: For each patent document, the character similarity and semantic similarity between the patent document and the other patent documents in each patent field are determined to obtain multi-path similarity results; Based on the search scenario, the similarity weights of the multi-path similarity results under the search scenario are determined, and the multi-path similarity results are weighted and fused according to the similarity weights to obtain the weighted similarity between the patent document and each of the other patent documents under the search scenario. Based on the weighted similarity between the patent document and each of the other patent documents in the search scenario, patent documents similar to the patent document are identified and used as positive sample documents for the patent document.

3. The method as described in claim 2, characterized in that, Before determining patent documents similar to the patent document based on the weighted similarity between the patent document and each of the other patent documents in this retrieval scenario, the method further includes: Determine the classification number of the patent document; Remove patent documents from the remaining patent documents that have a different classification number than the patent document in question.

4. The method as described in claim 2, characterized in that, Negative sample documents for each patent document are determined through random sampling, specifically including: Determine the classification number of the patent document, and based on the classification number of the patent document, remove the patent documents from the remaining patent documents whose classification numbers are different from that of the patent document; Random sampling is performed on the remaining patent documents to obtain candidate documents; Determine whether the character similarity between the candidate document and the patent document in each patent field is not higher than a first similarity threshold, and whether the semantic similarity between the candidate document and the patent document in each patent field is not higher than a second similarity threshold; If so, the candidate document is determined to be a negative sample document of the patent document; If not, random sampling is performed again on the remaining patent documents to obtain candidate documents again, and the judgment is repeated until the number of negative sample documents for the patent document reaches the preset number.

5. The method as described in claim 2, characterized in that, Determine the character similarity between this patent document and other patent documents in each patent field, specifically including: The patent document is segmented into words to obtain the words contained in each patent field. For each patent field of the patent document, the character similarity between the patent document and the other patent documents in each patent field is determined based on the weight of each word contained in the patent field, the frequency of each word contained in the patent field in the patent field, and the frequency of each word contained in the patent field in the patent fields contained in the other patent documents.

6. The method as described in claim 2, characterized in that, Determine the semantic similarity between this patent document and the other patent documents in each patent field, specifically including: Each patent field of the patent document is input into the patent domain language model to obtain the semantic vector of each patent field of the patent document output by the patent domain language model. Each patent field contained in the remaining patent documents is input into the patent domain language model to obtain the semantic vectors of each patent field contained in the remaining patent documents output by the patent domain language model. Based on the similarity between the semantic vectors of each patent field in the patent document and the semantic vectors of each patent field in the remaining patent documents, the semantic similarity between the patent document and the remaining patent documents in each patent field is determined.

7. The method as described in claim 1, characterized in that, Based on the training data of the patent semantic representation model for this retrieval scenario, the model parameters of the patent domain language model are learned and adjusted to obtain the patent semantic representation model for this retrieval scenario, specifically including: Using the patent field, positive examples of the patent field, and negative examples of the patent field in the training data of the patent semantic representation model for this retrieval scenario as input, the semantic vector of the patent field for this retrieval scenario, the semantic vector of the positive examples of the patent field for this retrieval scenario, and the semantic vector of the negative examples of the patent field for this retrieval scenario are obtained through the patent domain language model. Determine the first similarity between the semantic vector of the patent field for this retrieval scenario and the semantic vector of the positive example of the patent field for this retrieval scenario; Determine the second similarity between the semantic vector of a patent field for this retrieval scenario and the semantic vector of a negative example of a patent field for this retrieval scenario; Determine the difference between the first similarity and the second similarity; With the goal of the difference being greater than a preset parameter, the model parameters of the patent domain language model are learned and adjusted to obtain the patent semantic representation model for this retrieval scenario.

8. The method as described in claim 1, characterized in that, Based on the patent fields targeted by each search scenario and the patent semantic representation model for each search scenario, the semantic vector of each patent field is determined, specifically including: For each patent field, based on the retrieval scenario that the patent field is intended for, the corresponding patent semantic representation model is determined from the patent semantic representation models of each retrieval scenario; The patent field is input into the corresponding patent semantic representation model to obtain the semantic vector of the patent field output by the corresponding patent semantic representation model.

9. The method as described in claim 1, characterized in that, From the patent search vector database of the target search scenario, search for patent documents similar to the search fields, specifically including: Determine the similarity between the semantic vector of the search field and the semantic vectors stored in the patent search vector database of the target search scenario; Several semantic vectors with similarity higher than a preset similarity threshold are selected as candidate vectors. Based on the correspondence stored in the patent retrieval vector database for the target retrieval scenario, the patent documents corresponding to the candidate vectors are determined as patent documents similar to the retrieval fields.

10. A patent search device for multiple search scenarios, characterized in that, For multiple pre-stored patent documents, each containing multiple patent fields designed for different search scenarios, the device includes: The patent domain language model training data generation module is used to obtain patent documents containing multiple patent fields as training data for the patent domain language model. The patent domain language model training module is used to adjust the model parameters of the general language model using unsupervised learning based on the training data of the patent domain language model, so as to obtain the patent domain language model. The multi-scenario patent semantic representation model training data generation module is used to determine the positive sample documents of each patent document and the negative sample documents of each patent document through multi-path recall based on different weights for each retrieval scenario. Based on the patent field corresponding to the retrieval scenario, it determines the positive examples of the patent field from the positive sample documents of the patent documents to which the patent field belongs, and the negative examples of the patent field from the negative sample documents of the patent documents to which the patent field belongs. Based on the patent field, the positive examples of the patent field, and the negative examples of the patent field, the training data of the patent semantic representation model for the retrieval scenario is constructed. The multi-scenario patent semantic representation model training module is used to learn and adjust the model parameters of the patent domain language model based on the training data of the patent semantic representation model for the retrieval scenario, so as to obtain the patent semantic representation model for the retrieval scenario. The multi-scenario patent semantic vector database construction module is used to determine the semantic vector of each patent field based on the patent fields targeted by each retrieval scenario and the patent semantic representation model of each retrieval scenario, and to store the correspondence between the semantic vector of each patent field and the patent document to which each patent field belongs in the patent retrieval vector database of the retrieval scenario targeted by each patent field. The semantic vector generation module for retrieval fields is used to determine the semantic vector of the retrieval field based on the target retrieval scenario corresponding to the retrieval request and the patent semantic representation model of the target retrieval scenario when a retrieval request is received. The multi-scenario retrieval module is used to search for patent documents similar to the search field from the patent retrieval vector database of the target retrieval scenario based on the semantic vector of the search field, and return them as the retrieval results corresponding to the search field.

11. A computer-readable storage medium, characterized in that, The storage medium stores a computer program, which, when executed by a processor, implements the method described in any one of claims 1 to 9.

12. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the method described in any one of claims 1 to 9.

Citation Information

Patent Citations

  • Training method, device and equipment of retrieval matching model, and storage medium

    CN112579870A

  • Intelligent patent similarity searching method and device based on semantic retrieval

    CN113821646A