METHOD FOR QUERYING A DATABASE ORGANIZED IN THE FORM OF A KNOWLEDGE DIAGRAM

DE602020046914T2Active Publication Date: 2025-02-26ANAMNESE
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
DE602020046914
Authority / Receiving Office
DE · DE
Patent Type
Patents
Current Assignee / Owner
Priority Date
2019-12-31
Filing Date
2020-12-31
Publication Date
2025-02-26
Estimated Expiration
2040-12-31
Patent Text Reader
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD OF THE INVENTION

[0001] The technical field of the invention is that of knowledge graphs.

[0002] The present invention relates to a method of querying a database organized as a knowledge graph. TECHNOLOGICAL BACKGROUND OF THE INVENTION

[0003] In the state of the art, applications needing to extract as much information as possible from a database based on predetermined hypotheses use different strategies.

[0004] These strategies primarily involve the use of a knowledge tree or an inference engine. Here, a knowledge tree refers to knowledge organized like a tree. Knowledge is the leaves of the tree. Each node in the tree corresponds to a measurement to be taken to progress through the tree. The measurement result determines the next node in the tree.

[0005] The disadvantage of these strategies is that they are very rigid. For example, in the case of a knowledge tree, the traversal is from the top of the tree to the bottom of the tree. Once the traversal is initiated in a branch, all branches starting at a node at the same level become unavailable.

[0006] So, if a piece of knowledge is to appear in multiple cases, each case corresponding to a path in the knowledge tree, then that knowledge must, in one way or another, correspond to multiple leaves. This can quickly lead to trees of very large dimensions, both in depth and in width.

[0007] The disadvantage of inference engines is that they work on a rule base that is applied to a set of hypotheses. They are therefore not naturally interactive.

[0008] These two strategies are more suitable for performing classification. Here, classification means determining the leaf, and therefore the knowledge, that best corresponds to the measurements made. The best class, among known classes, is determined, which corresponds to the measurements. These strategies therefore result in highlighting one piece of knowledge and hiding the others.

[0009] In practice, it also appears that the data structures associated with these strategies, as well as the materializations of these data structures, have a complexity that goes well beyond the logical complexity of the data processed. This implies an increased difficulty of maintenance for the data and the programs that process them. By maintenance, we mean at least a fine-tuning and an evolution.

[0010] This complexity also makes it more difficult for professionals in the field of knowledge recorded in the data structure to appropriate the data model.

[0011] These observations are particularly true in the medical field and even more specifically in the field of anamnesis. In these cases, specialists are needed to describe business data, and they do not prioritize it. Applying standard strategies therefore results in partial or very difficult to update results, if possible to implement.

[0012] This is due to the fact that in state-of-the-art solutions, there is a fusion between knowledge and process. That is, the knowledge path is constrained by the tree structure. The path method merges with the knowledge and becomes part of it.

[0013] The state of the art is illustrated by US 2014 / 351261 A1, with the features of the preamble of claim 1. SUMMARY OF THE INVENTION

[0014] The invention provides a solution to the problems mentioned above, by making it possible to optimize the browsing of a knowledge graph, this optimization being done by minimizing the number and complexity of the queries to be sent to a database server to browse said graph. The physical interactions between a client process and a server process are therefore minimized. Depending on the configurations of the machines implementing said processes, this therefore makes it possible to consume less energy and / or to accelerate the response time of the system.

[0015] One aspect of the invention relates to a computer-implemented method of traversing a database organized as a knowledge graph to update in a memory a state of knowledge, the graph comprising a plurality of nodes and a plurality of relationships between the nodes of the plurality of nodes, the method comprising the following steps: A knowledge state is a set of [node reference, value] pairs; At least one node of the plurality of nodes comprises an identifier and a navigation attribute, said navigation attribute being structured as a list of sets of references to nodes, the method being characterized in that: each set of the list being associated with a first coefficient, each referenced node being associated with a second coefficient, the selection of a next node from a current node being done according to the following steps: Updating the knowledge state by adding a pair in the knowledge state, said pair comprising a reference of the current node and a value depending on a relationship having led to the current node;For each neighboring node of the current node having a navigation attribute, calculating a node score based on at least one set score, each set score being based on each second coefficient associated with a referenced node and on each value in the knowledge state associated with said referenced node, each second coefficient and each value being considered when said referenced node is present in the knowledge state, each set score being weighted by the first coefficient of said set. Selecting, from among all the nodes referenced by the neighboring node having the highest score, the node which is not referenced by the knowledge state and which has the second highest coefficient. ;

[0016] In addition to the characteristics which have just been mentioned in the preceding paragraph, the method according to one aspect of the invention may have one or more additional characteristics among the following, considered individually or according to all technically possible combinations: For a node reference, the possible values ​​belong to a discrete set; A node has a weighting attribute taken into account in calculating the node score; The relationship leading to the current node is determined by the following steps: Selection of a predetermined relationship among relationships leaving the current node to lead to an evaluation node; Selection of a relationship leaving the evaluation node and returning to the current node based on a measurement; The measurement comes from a sensor; The sensor is an input device; The measurement is the result of the evaluation of a function of the state of knowledge.

[0017] The invention and its various applications will be better understood by reading the following description and examining the accompanying figures. BRIEF DESCRIPTION OF THE FIGURES

[0018] The figures are presented for information purposes only and in no way limit the invention. FIG.1 shows an illustration of technical means for implementing the method according to the invention. FIG.2 shows an illustration of the structure of a node in a graph-oriented database for implementing the method according to the invention. FIG.3 shows an illustration of the structure of a state of knowledge. FIG.4 shows an illustration of a graph-oriented database structure that allows you to arrive at a current node. FIG.5 shows an illustration of steps of the method according to the invention.

[0019] In the figures, identical elements have the same references. DETAILED DESCRIPTION

[0020] There figure 1 shows a processing device 100. The processing device 100 comprises: A microprocessor 110; Storage means 120.

[0021] Storage means are understood here to represent all the storage means of the processing device. This includes in particular working memories, of the transient memory type, and persistent memories of the non-transient type.

[0022] There figure 1 shows that the storage means of the processing device comprise several zones: An area 120.1 instruction code which includes instruction codes for implementing the method according to the invention; An area 120.2 graph-oriented database. Such a database is, for example, Neo4j (registered trademark) or OrientDB; An area 120.3 state of knowledge.

[0023] In this description, when an action is attributed to a device or a program, this action is carried out for a microprocessor of the device implementing instruction codes loaded from storage means of the device. If it is a program then this program, and the corresponding instruction codes, are associated with a device comprising a microprocessor.

[0024] There figure 2shows a schematic representation of a structure of a first node 200 of the database of the area 120.2 database of the storage means of the processing device. In practice, a node is a memory area structured to record data. Each data recorded in a node is an attribute of this node. The attributes are named for clarity. In a graph-oriented database, not all nodes necessarily have the same structure. In the invention, there is at least the following structure for the first node 200, which includes: A 210 node identifier attribute. This is a unique identifier that distinguishes the node from all nodes in the database. A 220 navigation attribute structured as a double list. That is, the 220 navigation attribute is a list of lists.

[0025] There figure 2shows that the navigation attribute 220 comprises at least a first structure 221 of references. The structure is so named because it is structured to contain references to nodes. The structure 221 comprises: An attribute 2211 titles references; An attribute 2212 first numerical coefficient valid for the entire structure; A table 2213 of references. Each row of the reference table has its own numerical coefficient 22131 and a node identifier 22132. This allows a link to be established to other nodes.

[0026] There figure 2 shows that the navigation attribute 220 may contain a plurality of structures such as those previously described for the first structure, for example a second structure 221b structured like the first structure.

[0027] There figure 2shows that, in a variant of the invention, the first node 200 comprises a weighting attribute 230. This attribute is a numerical coefficient. This coefficient is valid for the node.

[0028] In the invention, it is interesting to note that, although using a graph-oriented database, links are defined without going through the relationship mechanism specific to graph-oriented databases.

[0029] This, at least, speeds up database queries by acting as a cache of query results. This will become more apparent when describing the process steps.

[0030] In practice, a graph-oriented database makes it possible to establish relationships between nodes. For the invention, there is at least one type of relationship that can be established between nodes having a structure identical to that described for the first node 200. This produces a node graph, i.e. a set of nodes that can be traversed by following the relationships that link them.

[0031] There figure 3 shows that area 120.3 knowledge status is structured as follows: A 310 session ID; A 320 state table.

[0032] The identifier 310 allows multiple knowledge states to be managed in the case of simultaneous database browsing. If the database, or the application that uses it, is single-user, and without history, this identifier is superfluous. Note here that the representation given illustrates the fact that the table is associated with a session identifier. The session itself can be silent, like anonymous sessions on websites without authentication. The session can be associated with a user in the case of authentication.

[0033] There figure 3 shows that the 320 state table can be seen as a table, with each row in the table containing: A node ID of 321; a value of 322.

[0034] The value 322 is a discrete value. In a preferred embodiment, it depends on a relationship that led to the node identified by node identifier 321.

[0035] There figure 4shows a second evaluation node 400. We could also talk about a sensor node. Once we arrive at this node, we exit by carrying out an evaluation or a measurement described by the node. An evaluation is, for example, the answer to a question, the reading of a measurement on a temperature sensor, the reading of a measurement on a pressure sensor, the reading of a color on an image, the reading of a measurement on a sound level meter, etc. The list is not exhaustive. The second node 400 therefore includes one or more attributes allowing the evaluation to be carried out to be defined.

[0036] There figure 4 shows that there is a Q-type relationship between the first node and the second node. Here Q is an arbitrary label used to predetermine a type.

[0037] There figure 4shows three relationships R1, R2 and R3 of type R between the second node and the first node. Each of these three relationships is associated with a value. This association can be achieved in at least two ways: By an attribute of the relationship; By an intermediate node between the second node and the first node.

[0038] In the case described in figure 4 , the result of the evaluation, or measurement, is therefore included in a set formed of three values. This is a discrete set.

[0039] These three values ​​are, for example in the case of a question: Yes, No, I don't know.

[0040] There can of course be more or less values ​​in the discrete set. Another response set can be: Greater than S, Less than S. In this case S is a threshold linked to the nature of the sensor.

[0041] Another discrete set can be a set of frequencies described as follows: 1 time per T, 3 times per T, 5 times per T, More. Here T is a predetermined period, for example, one hour, twelve hours or twenty-four hours, one month...

[0042] Via one of the R-type relationships, we arrive at the first node by being able to associate a value with the identifier of the first node. We can therefore update the state of knowledge.

[0043] There figure 4 shows a third node 410 neighboring the first node 200. The third node has the same structure as the first node. The third node 410 is neighboring the first node 200 because there is a type V relationship between the first node and the second node. Type V is a predetermined type that makes it possible to determine the neighbors, according to the invention, of a node. The neighbors of a node are, for example, all the nodes that have a type V relationship with this node.

[0044] In a variant of the invention, the neighboring nodes are the nodes referenced by the navigation attribute of the current node.

[0045] In a variant of the invention, the neighboring nodes are the NV0 nodes corresponding to at least one of the preceding definitions to which are added the neighboring nodes, according to at least one of the preceding definitions, of the NV0 nodes.

[0046] In other variants of the invention, the neighboring nodes correspond to a union of at least two of the sets of neighboring nodes previously described.

[0047] There figure 4 shows a fourth node 420 neighboring the first node.

[0048] In this description, only two neighboring nodes are represented according to one of the possible definitions of “neighboring node” but the invention applies regardless of the number of neighboring nodes.

[0049] There Figure 5shows a preliminary step 500 in which the method according to the invention arrives at the first node 200. The manner in which the method arrives at the node 500 is not important here. It can be arrived at either as a result of implementing a step of the method according to the invention or in another manner. Another manner is, for example, a process for selecting a first node, including a random process.

[0050] There Figure 5 shows a step 510 of activating a sensor. In this step, a relationship of type Q is searched among the relationships established by the first node 200. Here, type Q is a predetermined type. By predetermined, we mean a parameter of the method according to the invention. If such a relationship exists, then the other end of the relationship is a sensor node. A sensor node describes a measurement to be carried out by the method according to the invention.

[0051] For example, the second sensor node 400 is a question to ask a user. The second node then contains a question that will be submitted to the user. The second node also establishes R-type relationships, a predetermined type, with the first node. These R-type relationships are associated with possible response values. It is therefore possible to ask a question whose answer belongs to a finite set of values.

[0052] In a step 520, the method reads the value of the sensor, i.e. the answer chosen by the user. In this case, the sensor is composed of a screen to display the question and an input device to select the answer. Depending on the answer selected by the user, the method returns to the first node by one of the R-type relationships. The sensor is therefore an input device.

[0053] Alternatively, the sensor may also be such that the measurement is the result of evaluating a function of the knowledge state, i.e. the sensor is a function of the knowledge state that returns a discrete value as a function of that knowledge state. It is recalled here that the number of rows in table 320 is a characteristic of the knowledge state.

[0054] In the case of a client-server application, it is understood that the sensor, seen by the device, which is considered as the server, implementing the method is assimilated to an exchange of messages: A message sent to define the sensor at the client; A message received as a result of the reading.

[0055] In a step 530, the result of the sensor reading is used to update the knowledge state 120.3.

[0056] The knowledge state is updated by adding a new row to the knowledge state table 320. This new row contains the current node identifier and the value associated with the relationship that led to the current node.

[0057] We then move on to a step 540 of determining the next node. In this step, we analyze each neighboring node of the current node to associate a score with it. A neighboring node of the current node is a node that establishes a relationship with the current node and that has a navigation attribute. In the example of the description, this is the third node and the fourth node. We calculate 541 the score of each neighboring node.

[0058] The calculation of a node score is done as follows: For each reference structure 221 of the navigation attribute, calculation of a structure score: For each row in the reference table 2213: Calculation of a row score depending on the coefficient 22131 of the row and the value associated with the identifier 22132 of the row in the knowledge state. If the identifier is not in the knowledge state then the row is ignored for the calculation of the row score; Aggregation of row scores, for example by a simple sum; Weighting of the aggregation by the first numerical coefficient 2212 of the reference structure to obtain the structure score. Aggregation of the structure scores to obtain a node score. This aggregation is, for example, a sum or the selection of the highest score. The result of the aggregation is the node score.

[0059] In one variation, the node has a weighted attribute 230. In this variation this attribute is used to weight the node's score.

[0060] By weighting we mean multiplication.

[0061] We then select 542 the node with the highest score. Then we move on to a step 543 of selecting the next node from the navigation attribute of the next node. This node is the one that: Is not already referenced by the knowledge state, and Which has the highest coefficient in the reference tables of the reference structures of the navigation attribute.

[0062] Alternatively, for the next node selection step, the coefficients are weighted by the first coefficient of the reference structure to which they belong.

[0063] Once the node is selected, it is used as the new current node and the process can be resumed at preliminary step 500.

[0064] The process can be based on several criteria depending on the implementation method: A predetermined number of rows in the knowledge state is reached; there are no more neighboring nodes that are not already in the knowledge state.

[0065] The values ​​associated with a type R relationship are either numeric or can be associated with a numeric value. If they are numeric, then the calculations described are immediate. If they can be associated with a numeric value, then the association must be performed before the calculation to use the associated value during the calculation.

[0066] For example, if values ​​associated with one of the R-type relationships are: “Yes”, “No”, or “I don’t know”.

[0067] Then it is possible, in a variant, to proceed with the following association: “Yes” is associated with the value 1, “No” is associated with the value 0, “I don’t know” is associated with the value 0.5

[0068] In the same order of values ​​associated with the relations we could have, instead of the numerical values ​​[1, 0, 0.5] the numerical values ​​[1, -1, 0].

[0069] With the invention, the use of the navigation attribute makes it possible to avoid having to establish relationships to establish navigation links between nodes. If these links were established, it would be necessary to issue queries involving relationships to the database to determine the next node. From this point of view, the navigation attribute can therefore be seen as a query response cache and therefore as an optimization of the graph traversal.

[0070] The invention finds its application at least in the medical field for carrying out anamnesis, and in the legal field for establishing robot portraits.

[0071] In the case of an anamnesis a navigation attribute can be structured like the following list of lists: First list of important symptoms, coefficient 0.8 Node X1, coefficient 0.8; Node X2, coefficient 0.7 Second list of symptoms, coefficient 0.6 Node X3, coefficient 0.8 Node X4, coefficient 0.65 Node X5, coefficient 0.7 Third list of minor coefficients, coefficient 0.3 Node X6, coefficient 0.8

[0072] In the case of anamnesis, some of the nodes in the graph are medical entities such as symptoms, risk factors or diseases, while other nodes are sensors.

[0073] Still in the case of anamnesis we can have the following nodes Acute myocardial infarction, which is the father of: Unspecified (acute) myocardial infarction, unspecified management, which is the father of: Unspecified (acute) myocardial infarction, initial management.

[0074] Each of these nodes comprises a navigation attribute, for example structured as previously described, which allows the application of the method according to the invention.

[0075] In this example, the filiations are type V relationships as previously described. These relationships allow a person skilled in graph knowledge to naturally traverse the graph because the graph does not contain any computer processing constraints. Note that a node can establish several type V relationships.

Claims

1. A computer implemented method for scrolling through a database organised as a knowledge graph to update a knowledge state in a memory, the graph including a plurality of nodes and a plurality of relationships between nodes of the plurality of nodes, the method comprising the following steps: - A knowledge state (120.3) is a set of [node reference, value] pairs; - at least one node (200) of the plurality of nodes includes an identifier (210) and a browsing attribute (220), said browsing attribute being structured as a list of sets of references to nodes, the method being characterised in that: each set of the list being associated with a first coefficient, each referenced node being associated with a second coefficient, selecting a next node from a current node being carried out according to the following steps of: - Updating (530) the knowledge state by adding a pair to the knowledge state, said pair comprising a reference of the current node and a value as a function of a relationship (R1, R2, R3) that led to the current node; - For each neighbouring node (410, 420) of the current node (200) including a browsing attribute, calculating (541) a node score based on at least one set score, each set score being based on each second coefficient associated with a referenced node and on each value in the knowledge state associated with said referenced node, each second coefficient and each value being considered when said referenced node is present in the knowledge state, each set score being weighted by the first coefficient of said set; - Selecting (543), from all the nodes referenced by the neighbouring node having the highest score, the node which is not referenced by the knowledge state and which has the second highest coefficient.

2. The computer implemented method for scrolling through a database according to claim 1, characterised in that, for a node reference, the possible values belong to a discrete set.

3. The method according to one of the preceding claims, characterised in that a node includes a weighting attribute (230) taken into account in calculating the score of the node.

4. The method according to one of the preceding claims, characterised in that the relationship for leading to the current node is determined by the following steps: - Selecting (510) a predetermined relationship from among relationships leaving the current node to lead to an evaluation node; - Selecting (520) a relationship leaving the evaluation node and returning to the current node as a function of a measurement.

5. The method according to claim 4, characterised in that the measurement is derived from a sensor.

6. The method according to claim 5, characterised in that the sensor is an input device.

7. The method according to claim 4, characterised in that the measurement is the evaluation result of a function of the knowledge state.