Information retrieval methods, devices and electronic equipment
By constructing a graph containing entities and their relationships, the problem of inaccurate retrieval results in existing technologies is solved, achieving more accurate and efficient information retrieval.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SILEXON AI TECH CO LTD
- Filing Date
- 2023-08-23
- Publication Date
- 2026-06-30
AI Technical Summary
Existing technologies using keyword retrieval methods can only retrieve information sources containing a few keywords, leading to inaccurate search results.
By constructing a retrieval graph, including multiple entities and entity relationship pointers, the target information source is determined from a preset database in response to the retrieval operation, thus achieving accurate retrieval.
It improves the accuracy and efficiency of information retrieval and solves the problem of inaccurate results caused by keyword retrieval.
Smart Images

Figure CN117076606B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of knowledge graphs, and more specifically, to an information retrieval method, apparatus, and electronic device. Background Technology
[0002] In certain search scenarios, it's necessary to search for results related to specific target graphs, such as literature information related to two targets that simultaneously target disease A and are acted upon by drug B. Related technologies primarily rely on keyword retrieval. For example, entering the search query "disease A and drug B and act on and two targets" will only retrieve literature containing these keywords, failing to reveal the specific relationships between the entities, leading to inaccurate search results.
[0003] There is currently no effective solution to the above problems. Summary of the Invention
[0004] This invention provides an information retrieval method, apparatus, and electronic device to at least solve the technical problem in related technologies where keyword retrieval can only retrieve information sources containing a few keywords, leading to inaccurate retrieval results.
[0005] According to one aspect of the present invention, an information retrieval method is provided, comprising: determining a target graph to be retrieved, wherein the target graph includes at least: multiple entities, entity relationships between the multiple entities, and entity relationship pointers between the multiple entities; in response to a retrieval operation on the target graph, determining a target information source matching the target graph from a preset database, wherein the preset database includes multiple information sources and information source graphs corresponding to the multiple information sources respectively.
[0006] According to another aspect of the present invention, an information retrieval device is also provided, comprising: a map determination module, configured to determine a map to be retrieved, wherein the map to be retrieved includes at least: multiple entities, entity relationships between the multiple entities, and entity relationship pointers between the multiple entities; and a retrieval module, configured to, in response to a retrieval operation on the map to be retrieved, determine a target information source matching the map to be retrieved from a preset database, wherein the preset database includes multiple information sources and information source maps corresponding to the multiple information sources respectively.
[0007] According to another aspect of the present invention, an electronic device is also provided, including one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement any of the above-described information retrieval methods.
[0008] In this embodiment of the invention, by determining a target graph to be retrieved, wherein the target graph includes at least: multiple entities, entity relationships between the multiple entities, and entity relationship pointers between the multiple entities; in response to a retrieval operation on the target graph, a target information source matching the target graph is determined from a preset database, wherein the preset database includes multiple information sources and information source graphs corresponding to the multiple information sources respectively, thereby achieving the purpose of accurate retrieval through graph construction, thus realizing the technical effect of improving the accuracy and efficiency of information retrieval, and solving the technical problem in related technologies that mainly rely on keyword retrieval, which can only retrieve information sources containing a few keywords, resulting in inaccurate retrieval results. Attached Figure Description
[0009] The accompanying drawings, which are included to provide a further understanding of the invention and form part of this invention, illustrate exemplary embodiments of the invention and are used to explain the invention, but do not constitute an undue limitation of the invention. In the drawings:
[0010] Figure 1 This is a schematic diagram of an information retrieval method according to an embodiment of the present invention;
[0011] Figure 2 This is a schematic diagram of an optional retrieval map according to an embodiment of the present invention;
[0012] Figure 3 This is a schematic diagram of an optional target map setting according to an embodiment of the present invention;
[0013] Figure 4 This is a schematic diagram of another optional target map setting according to an embodiment of the present invention;
[0014] Figure 5 This is a schematic diagram of an optional method for drawing a target graph based on an entity database and an entity relation database according to an embodiment of the present invention;
[0015] Figure 6 This is a schematic diagram of an optional search result according to an embodiment of the present invention;
[0016] Figure 7 This is a schematic diagram of an information retrieval device according to an embodiment of the present invention. Detailed Implementation
[0017] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.
[0018] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0019] According to an embodiment of the present invention, an information retrieval method embodiment is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.
[0020] Figure 1 This is a flowchart of an information retrieval method according to an embodiment of the present invention, such as... Figure 1 As shown, the method includes the following steps:
[0021] Step S102: Determine the target graph, wherein the target graph includes at least: multiple entities, entity relationships between multiple entities, and entity relationship pointers between multiple entities.
[0022] Optionally, multiple entities can be entity terms in the medical field, such as targets, diseases, drugs, etc. The corresponding entity relationships include, but are not limited to, medical entity relationships, such as acting on, activating, and inhibiting. Entity levels can include, but are not limited to, first-level entities and second-level entities, with first-level entities having a higher level than second-level entities. Entity relationship levels can also include, but are not limited to, first-level entity relationships and second-level entity relationships, with first-level entity relationships having a higher level than second-level entity relationships. For example, in the medical field, targets, diseases, and drugs are first-level entities, while specific target locations, specific diseases, and specific drugs are second-level entities. Entity relationships include: acting on, activating, inhibiting, and treating; acting on is a first-level entity relationship, while activation, inhibition, and treatment are second-level entity relationships.
[0023] In one optional embodiment, the multiple entities included in the above-mentioned map to be retrieved are connected by directed arrows, which are used to indicate the entity relationship between any two entities among the multiple entities.
[0024] Optionally, the searchable graph in this embodiment of the invention includes not only entities and entity relationships, but also the entity relationship pointers between entities. Taking entity A acting on entity B as an example, existing technologies can only retrieve information sources containing "entity A, acting on, entity B", resulting in an excessively broad search scope. However, in this embodiment of the invention, directed arrows indicate the entity relationship pointers between any two entities, enabling the precise retrieval of whether entity A acts on entity B, entity B acts on entity A, or other forms including "entity A, acting on, entity B". In other words, this embodiment of the invention can accurately retrieve information sources where "entity A acts on entity B", thereby improving the accuracy of the search results.
[0025] Optional, Figure 2 This is a schematic diagram of an optional retrieval map according to an embodiment of the present invention, such as... Figure 2 As shown, in the target graph, the entities include drugs, target 1, target 2, and diseases. The corresponding entity relationships are: target 1 acts on drugs, target 2 acts on drugs, target 1 acts on diseases, and target 2 acts on diseases. The direction of the corresponding arrows is the direction of the entity relationship, that is, the direction of action between two entities.
[0026] In an optional embodiment, determining the search graph includes: determining search information, wherein the search information is multiple search keywords or a statement containing multiple search keywords; drawing an initial search graph based on the search information; and, in response to a first modification operation on the initial search graph, using the modified initial search graph as the search graph, wherein the first modification operation includes at least one of the following: entity modification, entity-level modification, entity relationship modification, entity relationship-level modification, entity relationship pointer modification, addition or deletion of entities, addition or deletion of entity relationships, or addition or deletion of entity relationship levels.
[0027] Optionally, the aforementioned search information is used to indicate the entity to be searched and the relationships between entities. The aforementioned search information may, but is not limited to, include multiple search keywords, or statements containing search keywords. The aforementioned search information may, but is not limited to, search information in the medical field.
[0028] Optionally, if the information to be retrieved includes multiple search keywords, the multiple search keywords can be directly identified to determine that the information to be retrieved includes multiple entities and the entity relationships between the multiple entities.
[0029] Optionally, if the information to be retrieved is a statement containing search keywords, then drawing an initial retrieval graph based on the information to be retrieved includes: performing named entity recognition on the information to be retrieved to obtain multiple entities included in the information to be retrieved; extracting entity relationships from the multiple entities included in the information to obtain the entity relationships between the multiple entities included in the information to be retrieved; and drawing the initial retrieval graph based on the multiple entities included in the information to be retrieved and the entity relationships between the multiple entities. Through the above method, by sequentially performing named entity recognition and entity relationship extraction on the information to be retrieved, the multiple entities included in the information to be retrieved and the entity relationships between the multiple entities can be obtained quickly.
[0030] Optionally, the aforementioned search graph may further include entity levels corresponding to multiple entities and entity relationship levels between multiple entities. When the aforementioned search graph also includes entity levels corresponding to multiple entities and entity relationship levels between multiple entities, the process of drawing the initial search graph based on the multiple entities included in the search information and the entity relationships between multiple entities includes: determining the entity levels corresponding to the multiple entities included in the search information and the entity relationship levels between multiple entities; and drawing the initial search graph based on the multiple entities included in the search information, the entity levels corresponding to the multiple entities, the entity relationships between the multiple entities, and the entity relationship levels.
[0031] Optionally, the initial search graph drawn based on the aforementioned information may deviate from the user's actual needs. For example, the identified entities or entity relationships may not be what the user wants, the entity relationships between entities may not be shown, or the entity relationship pointers may be incorrect. Therefore, after obtaining the initial search graph, it is displayed in the graph drawing interface so that the user can intuitively see whether there is a deviation between the initial search graph and the actual search requirements. If a deviation exists, a first modification operation is performed on the initial search graph (entity modification, entity level modification, entity relationship modification, entity relationship level modification, entity relationship pointer modification, entity addition or deletion, entity relationship addition or deletion, entity relationship level addition or deletion, etc.). This results in a more accurate search graph that better meets the actual search needs.
[0032] In one optional embodiment, determining the map to be retrieved includes: responding to a selection operation of a target map template in a map template library, wherein the map template library includes multiple map templates; and obtaining the map to be retrieved based on the target map template.
[0033] Optionally, each of the aforementioned graph templates includes multiple entities, entity relationships between these entities, and entity relationship pointers between these entities. The entities and entity relationships included in the graph templates are the highest-level entities (e.g., first-level entities such as target, disease, and drug; first-level entity relationships such as target, disease, and drug). After obtaining the target graph template, it is determined whether the target graph template meets the actual retrieval requirements. If it does, the target graph template is directly used as the graph to be retrieved; otherwise, the target graph needs to be modified (e.g., entity modification, entity level modification, entity relationship modification, entity relationship level modification, entity relationship pointer modification, entity addition or deletion, entity relationship addition or deletion, entity relationship level addition or deletion, etc.), and the modified target graph template is used as the graph to be retrieved.
[0034] In an optional embodiment, obtaining the target graph based on the target graph template includes: in response to a second modification operation on the target graph template, obtaining a modified target graph template, wherein the second modification operation includes at least one of the following: entity modification, entity level modification, entity relationship modification, entity relationship level modification, entity relationship pointer modification, addition or deletion of entities, addition or deletion of entity relationships, addition or deletion of entity relationship level; and using the modified target graph template as the target graph.
[0035] Optional, Figure 3 This is a schematic diagram of an optional target map setting according to an embodiment of the present invention, such as... Figure 3 As shown, the left side of the graph drawing interface contains a graph template library with multiple graph templates, and the right side is the drawing area. A target graph template is selected from the multiple graph templates. The target graph template is moved to the drawing area by double-clicking, dragging, etc. The target graph template is modified accordingly in the drawing area, and higher-level entities and / or entity relationships in the target candidate graph are further set. Figure 4 This is a schematic diagram of another optional retrieval map setting according to an embodiment of the present invention, such as... Figure 4 As shown, after determining the target candidate atlas, the diseases in the target candidate atlas are further identified, that is, the specific disease forms are determined from multiple diseases to obtain the atlas to be retrieved. Through the above method, target atlas templates are selected from a pre-built atlas template library for drawing the atlas to be retrieved, improving the efficiency of target atlas template drawing while enhancing the user experience.
[0036] In an optional embodiment, determining the target graph includes: obtaining a plurality of initial entities in response to a selection operation of entities included in an entity database; obtaining initial entity relationships between the plurality of initial entities in response to a selection operation of entity relationships included in an entity relationship database; determining entity relationship pointers between the plurality of initial entities; and drawing the target graph based on the plurality of initial entities, the initial entity relationships between the plurality of initial entities, and the entity relationship pointers between the plurality of initial entities.
[0037] Optionally, besides drawing the target graph based on the information to be retrieved or a graph template, the target graph can also be drawn based on an entity database or an entity relationship database, using a user-defined method. The target graph is drawn by selecting multiple initial entities from the entity database and the entity relationship database, along with the initial entity relationships between these entities and the relationships pointing to each other. An initial graph template (such as a first graph template) can be constructed based on the selected initial entities, their initial entity relationships, and the relationships pointing to each other. If this first graph template meets the retrieval requirements, it is directly used as the target graph template for information retrieval. If the first graph template does not meet the retrieval requirements, the entity levels of the entities included in the first graph template, or the levels of entity relationships between entities, need to be modified accordingly. The modified first graph template is then used as the target graph for information retrieval.
[0038] Optionally, the above method further includes: obtaining a first atlas template based on the aforementioned multiple initial entities, the initial entity relationships between the multiple initial entities, and the entity relationship pointers between the multiple initial entities. The obtained first atlas template can also be saved to an atlas template library. When a user wants to perform information retrieval based on an atlas similar to the first atlas template, they can directly call the first atlas template from the atlas template library to determine the atlas to be retrieved, thereby improving retrieval efficiency.
[0039] Optional, Figure 5 This is a schematic diagram illustrating an optional method for drawing a searchable graph based on an entity database and an entity relation database according to an embodiment of the present invention, such as... Figure 5 As shown, the left side of the graph drawing interface includes an entity library and an entity relationship library. Different entities correspond to different identifiers, and different entity relationships correspond to directed arrows of different line types. The right side of the graph drawing interface is the graph drawing area. First, move the required entities to the graph drawing area by double-clicking or dragging, as shown below. Figure 5 As shown in (a); add entity relationships between entities as needed, with the arrow direction indicating the direction of the entity relationship between two entities, such as... Figure 5 As shown in (b); after adding all entity relations, the final first atlas template is as follows: Figure 5 As shown in (c) above. Clicking the "Save Template" control in the atlas drawing interface will save the first atlas template to the atlas template library.
[0040] In an optional embodiment, the above-described method of drawing the target graph based on the plurality of initial entities, the initial entity relationships between the plurality of initial entities, and the entity relationship pointers between the plurality of initial entities includes: obtaining modified plurality of initial entities in response to a third modification operation at the entity level of any one of the plurality of initial entities; obtaining modified initial entity relationships between the plurality of initial entities in response to a fourth modification operation of the initial entity relationships between any two initial entities; and obtaining the target graph based on the modified plurality of initial entities, the modified initial entity relationships between the plurality of initial entities, and the entity relationship pointers between the plurality of initial entities.
[0041] Optionally, if the first atlas template drawn based on the above-mentioned multiple initial entities, the initial entity relationships between the multiple initial entities, and the entity relationships between the multiple initial entities cannot meet the actual retrieval needs, the entity level of the multiple initial entities and the entity relationship level of the initial entity relationships between the multiple initial entities can be modified, and the modified first atlas template can be used as the atlas to be retrieved for information retrieval.
[0042] Step S104: In response to the retrieval operation of the above-mentioned map to be retrieved, a target information source matching the map to be retrieved is determined from a preset database, wherein the preset database includes multiple information sources and information source maps corresponding to the multiple information sources respectively.
[0043] Optionally, the aforementioned target information sources may include, but are not limited to, biomedical literature, patents, clinical experience, etc.
[0044] Optionally, the aforementioned preset database may be, but is not limited to, a medical database, and the information sources included in the preset database may be, but are not limited to, medical literature. Each information source corresponds to an information source map, which includes multiple entities included in the information source, the entity relationships between the multiple entities, and the entity relationship pointers between the multiple entities. It may also include the entity levels corresponding to the multiple entities and the entity relationship levels between the multiple entities.
[0045] Optionally, the target information source map corresponding to the target information source map is determined by comparing and matching the target information source map with the information source maps corresponding to multiple information sources included in the database. Further, the target information source matching the target information source map is determined, and this target information source is the final search result. The final output search result format is as follows: Figure 6 As shown.
[0046] Optionally, the target information source mentioned above covers all entities and entity relationships included in the target graph, and has the same entity relationship pointers as the target graph.
[0047] In an optional embodiment, the above-mentioned method of determining a target information source matching the target information source from a preset database in response to a retrieval operation on the target information source includes: determining a target information source information source information source from a preset database in response to a retrieval operation on the target information source information source, wherein the number of entities included in the target information source information source is greater than or equal to the number of entities included in the target information source information source, the number of entity relationships included in the target information source information source is greater than or equal to the number of entity relationships included in the target information source, and the entity relationships included in the target information source information source correspond to the entity relationships included in the matching information source in the target information source information source; and using the information source in the preset database that corresponds to the target information source information source as the target information source.
[0048] Optionally, before performing information source retrieval, a retrieval graph is first drawn based on the multiple entities corresponding to the information to be retrieved, the entity relationships between these entities, and the relationships pointing to each entity. This retrieval graph is then compared and matched with the information source graphs corresponding to multiple information sources included in the database to determine the target information source graph that corresponds to the retrieval graph. Further, the target information sources that match the retrieval graph are identified based on these target information source graphs. The target information sources selected through this process encompass all entities and entity relationships included in the retrieval graph and share the same entity relationship pointings as those in the retrieval graph. These target information sources are the final retrieval results, resulting in more accurate retrieval results.
[0049] In one optional embodiment, the entity level corresponding to the entity included in the above-mentioned search map is greater than or equal to the entity level of the corresponding entity in the above-mentioned target information source map, and the entity relationship level corresponding to the entity relationship included in the above-mentioned search map is greater than or equal to the entity relationship level of the corresponding entity in the above-mentioned target information source map.
[0050] Optionally, in the actual retrieval process, the user's input search terms may be at a higher level, meaning the identified entity level or entity relation level is higher. Using the above methods, lower-level entities or entity relations can be filtered out during the retrieval process, thereby improving the comprehensiveness of the search results. For example, if the user's input entity is determined to include the first-level entity "cancer," then all information sources containing specific diseases (such as lung cancer, stomach cancer, etc.) can be filtered from the preset database; if the user's input entity is determined to include the first-level entity relation "acts on," then all information sources containing lower-level entity relations such as activation, inhibition, and treatment can be filtered from the preset database.
[0051] In an optional embodiment, before determining the target information source matching the target information source from the preset database in response to the retrieval operation on the target information source, the method further includes: determining the multiple entities included in the multiple information sources and the entity relationships between the multiple entities; determining the entity levels corresponding to the multiple entities included in the multiple information sources and the entity relationship levels between the multiple entities; constructing information source information sources corresponding to the multiple information sources based on the multiple entities included in the multiple information sources, the entity levels corresponding to the multiple entities, the entity relationships between the multiple entities, and the entity relationship levels, wherein the information source information sources include entity relationship pointers between the multiple entities; and establishing an index relationship between the multiple information sources and the corresponding information source information sources to obtain the preset database.
[0052] Optionally, before searching the target graph, a pre-defined database needs to be constructed. This involves acquiring multiple information sources, sequentially performing named entity recognition and entity relationship extraction on each source to obtain the entities included in each source and the entity relationships between them. Furthermore, the entity level and relationship level for each entity are determined and identified, and the entity relationship pointers are determined based on the context information in the information source. Based on the multiple entities included in each source, their corresponding entity levels, entity relationships, and relationship levels, information source graphs corresponding to each source are constructed, and an index relationship is established between each information source graph and its corresponding information source, ultimately resulting in the pre-defined database. In subsequent searches, the target graph is simply compared and matched with the information source graphs included in the pre-defined database. The target information source matching the target graph is then determined based on the matched target information source graph.
[0053] In one optional embodiment, determining the multiple entities included in the multiple information sources and the entity relationships between the multiple entities includes: performing named entity recognition on the multiple information sources to obtain the multiple entities included in the multiple information sources; and extracting entity relationships from the multiple entities included in the multiple information sources to obtain the entity relationships between the multiple entities included in the multiple information sources.
[0054] Optionally, multiple entities included in multiple information sources can be identified by named entity recognition, and entity relationships between multiple entities included in multiple information sources can be identified by entity relationship extraction.
[0055] Optionally, the entity relationships between multiple entities included in any one of the multiple information sources can be determined as follows: multiple entities included in any one information source are concatenated in pairs to obtain multiple concatenation results; the multiple concatenation results are mapped to a two-dimensional space to obtain two-dimensional space mapping results corresponding to the multiple concatenation results, wherein the two-dimensional space is used to indicate the probability of a relationship and no relationship between the two concatenated entities; the entity relationships between the multiple entities are determined based on the two-dimensional space mapping results corresponding to the multiple concatenation results.
[0056] Through the above steps S102 to S104, the goal of accurate retrieval through graph construction can be achieved, thereby improving the accuracy and efficiency of information retrieval. This solves the technical problem in related technologies where keyword retrieval can only retrieve information sources containing a few keywords, leading to inaccurate retrieval results.
[0057] Based on the above embodiments and optional embodiments, the present invention proposes an implementation method for an optional information retrieval method, the method comprising:
[0058] Step S11: Determine the information to be retrieved.
[0059] Step S12: Based on the multiple entities included in the information to be retrieved, the entity levels corresponding to the multiple entities, the entity relationships between the multiple entities, and the entity relationship levels, construct a retrieval graph. The retrieval graph includes directed arrows to indicate the entity relationship between any two entities among the multiple entities.
[0060] Step S13, Construction of the Preset Database. Specifically, this includes: determining the multiple entities included in each of the multiple information sources, and the entity relationships between these entities; determining the entity levels corresponding to each of the multiple entities included in the multiple information sources, and the entity relationship levels between these entities; constructing information source graphs corresponding to each of the multiple information sources based on the multiple entities included in the multiple information sources, the corresponding entity levels, the entity relationships between these entities, and the entity relationship levels, wherein the information source graphs include pointers to the entity relationships between the multiple entities; establishing index relationships between the multiple information sources and their corresponding information source graphs to obtain the preset database.
[0061] Step S14: In response to the retrieval operation of the target graph, a target information source graph matching the target graph is determined from a preset database. The target information source graph contains entities of equal or greater number than the target graph, and the target information source graph contains entity relationships of equal or greater number than the target graph. The entity level of the entities in the target graph is equal or greater than the entity level of the corresponding entities in the target information source graph, and the entity relationship level of the entity relationships in the target graph is equal or greater than the entity relationship level of the corresponding entities in the target information source graph. The entity relationships in the target information source graph point to the entity relationships in the target graph that match the target graph. The information source in the preset database that corresponds to the target information source graph is then selected as the target information source.
[0062] This embodiment also provides an information retrieval device for implementing the above embodiments and preferred embodiments; details already described will not be repeated. As used below, the terms "module" and "device" can refer to a combination of software and / or hardware that performs a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.
[0063] According to an embodiment of the present invention, an apparatus embodiment for implementing the above-described information retrieval method is also provided. Figure 7This is a schematic diagram of the structure of an information retrieval device according to an embodiment of the present invention, such as... Figure 7 As shown, the above-mentioned information retrieval device includes: a map determination module 700 and a retrieval module 702, wherein:
[0064] The aforementioned graph determination module 700 is used to determine the graph to be retrieved, wherein the graph to be retrieved includes at least: multiple entities, entity relationships between multiple entities, and entity relationship pointers between multiple entities;
[0065] The aforementioned retrieval module 702 is connected to the aforementioned map determination module 700 and is used to determine, in response to the retrieval operation of the aforementioned map to be retrieved, a target information source matching the aforementioned map to be retrieved from a preset database. The aforementioned preset database includes multiple information sources and information source maps corresponding to the aforementioned multiple information sources.
[0066] In this embodiment of the invention, the graph determination module 700 is used to determine the graph to be retrieved, wherein the graph to be retrieved includes at least: multiple entities, entity relationships between the multiple entities, and entity relationship pointers between the multiple entities; the retrieval module 702 is connected to the graph determination module 700 and is used to determine the target information source matching the graph to be retrieved from a preset database in response to the retrieval operation of the graph to be retrieved, wherein the preset database includes multiple information sources and information source graphs corresponding to the multiple information sources, thereby achieving the purpose of accurate retrieval through graph construction, thereby realizing the technical effect of improving the accuracy and efficiency of information retrieval, and solving the technical problem in related technologies that mainly rely on keyword retrieval, which can only retrieve information sources containing a few keywords, resulting in inaccurate retrieval results.
[0067] It should be noted that the above modules can be implemented by software or hardware. For example, for the latter, it can be implemented in the following ways: the above modules can be located in the same processor; or the above modules can be located in different processors in any combination.
[0068] It should be noted that the above-mentioned map determination module 700 and retrieval module 702 correspond to steps S102 to S104 in the embodiments. The instances and application scenarios implemented by the above modules and corresponding steps are the same, but are not limited to the content disclosed in the above embodiments. It should be noted that the above modules, as part of the device, can run in a computer terminal.
[0069] It should be noted that the optional or preferred implementation methods of this embodiment can be found in the relevant descriptions in the embodiments, and will not be repeated here.
[0070] The aforementioned information retrieval device may also include a processor and a memory. The map determination module 700, retrieval module 702, etc., are all stored in the memory as program modules, and the processor executes the aforementioned program modules stored in the memory to realize the corresponding functions.
[0071] The processor contains a core that retrieves the corresponding program modules from memory. One or more cores may be configured. Memory may include non-persistent memory 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 includes at least one memory chip.
[0072] According to an embodiment of the present invention, an embodiment of a non-volatile storage medium is also provided. Optionally, in this embodiment, the non-volatile storage medium includes a stored program, wherein, when the program is running, it controls the device where the non-volatile storage medium is located to execute any of the aforementioned information retrieval methods.
[0073] Optionally, in this embodiment, the non-volatile storage medium may be located in any computer terminal in a group of computer terminals in a computer network, or in any mobile terminal in a group of mobile terminals, and the non-volatile storage medium includes stored programs.
[0074] Optionally, during program execution, the device containing the non-volatile storage medium is controlled to perform the following functions: determine a target graph to be retrieved, wherein the target graph to be retrieved includes at least: multiple entities, entity relationships between the multiple entities, and entity relationship pointers between the multiple entities; in response to a retrieval operation on the target graph to be retrieved, determine a target information source matching the target graph to be retrieved from a preset database, wherein the preset database includes multiple information sources and information source graphs corresponding to the multiple information sources respectively.
[0075] According to an embodiment of the present invention, an embodiment of a processor is also provided. Optionally, in this embodiment, the processor is used to run a program, wherein the program executes any of the above-described information retrieval methods during runtime.
[0076] According to an embodiment of the present invention, an embodiment of a computer program product is also provided, which, when executed on a data processing device, is adapted to execute a program that initializes any of the above-described information retrieval method steps.
[0077] Optionally, when the above-mentioned computer program product is executed on a data processing device, it is suitable to execute a program that initializes the following steps: determining a target graph to be retrieved, wherein the target graph to be retrieved includes at least: multiple entities, entity relationships between the multiple entities, and entity relationship pointers between the multiple entities; in response to a retrieval operation on the target graph to be retrieved, determining a target information source matching the target graph to be retrieved from a preset database, wherein the preset database includes multiple information sources and information source graphs corresponding to the multiple information sources respectively.
[0078] This invention provides an electronic device, which includes a processor, a memory, and a program stored in the memory and executable on the processor. When the processor executes the program, it performs the following steps: determining a target graph to be retrieved, wherein the target graph includes at least: multiple entities, entity relationships between the multiple entities, and entity relationship pointers between the multiple entities; in response to a retrieval operation on the target graph, determining a target information source matching the target graph from a preset database, wherein the preset database includes multiple information sources and information source graphs corresponding to the multiple information sources.
[0079] The order of the above embodiments of the present invention is merely for description and does not represent the superiority or inferiority of the embodiments.
[0080] In the above embodiments of the present invention, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0081] In the several embodiments provided by this invention, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of modules described above can be a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, or indirect coupling or communication connection between modules, and may be electrical or other forms.
[0082] The modules described above as separate components may or may not be physically separate. Similarly, the components shown as modules may or may not be physical modules; they may be located in one place or distributed across multiple modules. Some or all of the modules can be selected to achieve the purpose of this embodiment, depending on actual needs.
[0083] Furthermore, the functional modules in the various embodiments of the present invention can be integrated into one processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The integrated modules described above can be implemented in hardware or as software functional modules.
[0084] If the aforementioned integrated modules are implemented as software functional modules and sold or used as independent products, they can be stored in a computer-readable non-volatile storage medium. Based on this understanding, the technical solution of this invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a non-volatile storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this invention. The aforementioned non-volatile storage medium includes various media capable of storing program code, such as USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks.
[0085] The above are merely preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. An information retrieval method, characterized in that, include: The target graph is determined, wherein the target graph includes at least: multiple entities, entity relationships between multiple entities, and entity relationship pointers between multiple entities; In response to the retrieval operation of the target graph, a target information source matching the target graph is determined from a preset database. The preset database includes multiple information sources and information source graphs corresponding to the multiple information sources. The entity relationship pointers included in the target information source graphs correspond to the entity relationship pointers included in the matching graph of the target graph. The process of determining the target graph includes: drawing the target graph by selecting a graph template or a user-defined method based on the identified target information; the user-defined method involves obtaining multiple initial entities in response to a selection operation of entities included in an entity database; obtaining initial entity relationships between the multiple initial entities in response to a selection operation of entity relationships included in an entity relationship database; determining the entity relationship pointers between the multiple initial entities; obtaining modified multiple initial entities in response to a third modification operation at the entity level of any one of the multiple initial entities; obtaining modified initial entity relationships between the multiple initial entities in response to a fourth modification operation of the initial entity relationships between any two initial entities; and obtaining the target graph based on the modified multiple initial entities, the modified initial entity relationships between the multiple initial entities, and the entity relationship pointers between the multiple initial entities.
2. The method according to claim 1, characterized in that, The process of determining the map to be retrieved includes: Determine the information to be retrieved, wherein the information to be retrieved is multiple search keywords, or a statement containing multiple search keywords; Based on the information to be retrieved, an initial retrieval map is drawn; In response to a first modification operation on the initial retrieval map, the modified initial retrieval map is used as the map to be retrieved, wherein the first modification operation includes at least one of the following: entity modification, entity level modification, entity relationship modification, entity relationship level modification, entity relationship pointer modification, entity addition or deletion, entity relationship addition or deletion, and entity relationship level addition or deletion.
3. The method according to claim 1, characterized in that, The process of determining the map to be retrieved includes: In response to the selection of a target atlas template in the atlas template library, wherein the atlas template library includes multiple atlas templates; Based on the target map template, the map to be retrieved is obtained.
4. The method according to claim 3, characterized in that, The process of obtaining the target map based on the target map template includes: In response to a second modification operation on the target atlas template, a modified target atlas template is obtained, wherein the second modification operation includes at least one of the following: entity modification, entity level modification, entity relationship modification, entity relationship level modification, entity relationship pointing modification, entity addition or deletion, entity relationship addition or deletion, entity relationship level addition or deletion. The modified target map template is used as the map to be retrieved.
5. The method according to claim 1, characterized in that, The step of responding to a retrieval operation on the target map by determining a target information source matching the target map from a preset database includes: In response to a retrieval operation on the target graph, a target information source graph matching the target graph is determined from the preset database, wherein the number of entities included in the target information source graph is greater than or equal to the number of entities included in the target graph, the number of entity relationships included in the target information source graph is greater than or equal to the number of entity relationships included in the target graph, and the entity relationships included in the target information source graph correspond to the entity relationships included in the matching target graph. The information source corresponding to the target information source map in the preset database is taken as the target information source.
6. The method according to claim 5, characterized in that, The entity level of the entity included in the target information source map is greater than or equal to the entity level of the corresponding entity in the target information source map, and the entity relationship level of the entity relationship included in the target information source map is greater than or equal to the entity relationship level of the corresponding entity in the target information source map.
7. The method according to claim 1, characterized in that, Before determining the target information source matching the target map from a preset database in response to the retrieval operation on the target map, the method further includes: Determine the multiple entities included in each of the multiple information sources, and the entity relationships between the multiple entities; Determine the entity level corresponding to each entity included in the multiple information sources, and the entity relationship level between the multiple entities; Based on the multiple entities included in the multiple information sources, the entity levels corresponding to the multiple entities, the entity relationships and entity relationship levels between the multiple entities, an information source map corresponding to the multiple information sources is constructed, wherein the information source map includes entity relationship pointers between multiple entities; Establish an index relationship between the multiple information sources and their corresponding information source maps to obtain the preset database.
8. The method according to any one of claims 1 to 7, characterized in that, The multiple entities included in the map to be retrieved are connected by directed arrows, which are used to indicate the entity relationship between any two entities among the multiple entities.
9. An information retrieval device, characterized in that, include: The graph determination module is used to determine the graph to be retrieved, wherein the graph to be retrieved includes at least: multiple entities, entity relationships between multiple entities, and entity relationship pointers between multiple entities; The retrieval module is used to respond to the retrieval operation of the target graph and determine the target information source that matches the target graph from a preset database. The preset database includes multiple information sources and information source graphs corresponding to the multiple information sources. The entity relationship pointers included in the target information source graph correspond to the entity relationship pointers included in the matching of the target graph. The graph determination module is further configured to draw the graph to be retrieved based on the identified information to be retrieved, selecting a graph template or a user-defined method. The user-defined method involves obtaining multiple initial entities in response to a selection operation of entities included in the entity database; obtaining initial entity relationships between the multiple initial entities in response to a selection operation of entity relationships included in the entity relationship database; determining the entity relationship pointers between the multiple initial entities; obtaining modified multiple initial entities in response to a third modification operation at the entity level of any one of the multiple initial entities; obtaining modified initial entity relationships between the multiple initial entities in response to a fourth modification operation of the initial entity relationships between any two initial entities; and obtaining the modified initial entity relationships between the multiple initial entities based on the modified multiple initial entities, the modified initial entity relationships between the multiple initial entities, and the entity relationship pointers between the multiple initial entities.
10. An electronic device, characterized in that, It includes one or more processors and a memory, the memory being used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors cause the one or more processors to implement the information retrieval method according to any one of claims 1 to 8.