Atlas display method, device, computer device and readable storage medium
By acquiring the relationship density of knowledge graph nodes and adjusting the display size and color/shape accordingly, the problem of node indistinguishability in existing technologies is solved, enabling richer graph information display and improved user experience.
Patent Information
- Application Number
- CN202010671039.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-07-13
- Publication Date
- 2026-02-27
- Estimated Expiration
- 2041-03-29
AI Technical Summary
Existing knowledge graphs do not differentiate the way nodes are displayed, making it difficult to distinguish different nodes when they are the same size, which affects the user experience, especially when the number of nodes is large.
By obtaining the relationship density of nodes, the display size and color/shape of nodes are determined based on the relationship density, and the display styles of different nodes are distinguished so that the relationship density of nodes with larger display sizes is greater than that of nodes with smaller display sizes. The central node is also adjusted according to user interaction.
It enables richer display of graph information, helping users better understand the graph structure and content, and improving the user experience.
Smart Images

Figure CN113934893B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present disclosure relates to the technical field of computer, and particularly relates to a knowledge graph display method and device, a computer device and a readable storage medium. BACKGROUND
[0002] With the continuous development of artificial intelligence technology, the knowledge graph technology as one of the important branches of artificial intelligence has more and more applications in various industries.
[0003] The knowledge graph is a graph database that stores a large amount of knowledge, but its node-relation edge-node structure is quite different from that of the traditional database. The knowledge graph can realize a graphical display mode, which is convenient for users to directly read related content from the graphical knowledge graph. However, the inventors have found in the process of implementing the present disclosure that the existing knowledge graph does not distinguish the display mode of the node when displaying, and the size of the node is often only related to the level, and the node can directly express less information. For the no-level state, if the node size is consistent, but the number is large, it is difficult to distinguish different nodes on the knowledge graph, which affects the user experience. SUMMARY
[0004] In order to solve the above technical problems or at least partially solve the above technical problems, the present disclosure provides a knowledge graph display method, device, equipment and readable storage medium.
[0005] The first aspect of the embodiment of the present disclosure provides a knowledge graph display method, which comprises:
[0006] obtaining attribute information of a node in a knowledge graph to be displayed, wherein the attribute information comprises a relation density of the node, and the relation density is used to indicate the number of relations and / or events in which the node is involved;
[0007] obtaining a display size of the node based on the relation density of the node;
[0008] displaying the knowledge graph based on the display size of the node, so that in the displayed knowledge graph, the relation density of the node with a larger display size is greater than the relation density of the node with a smaller display size.
[0009] In some embodiments, the obtaining of the display size of the node based on the relation density of the node comprises:
[0010] dividing the relation density of all nodes into at least two density intervals, and setting a corresponding display size for each density interval;
[0011] determining the display size of the node according to the density interval in which the relation density of the node is located.
[0012] In some embodiments, the relationship density of all nodes is divided into intervals to obtain at least two density intervals, including:
[0013] Based on the relationship density of all nodes, the maximum density value, the minimum density value and the median density value are obtained;
[0014] Based on the maximum density value and the median density value, at least two density intervals are determined, and / or, based on the median density value and the minimum density value, at least two density intervals are determined.
[0015] In some embodiments, the attribute information further includes a node type, and the method further includes:
[0016] Based on the node type of the node, the display color and / or the display shape of the node are obtained,
[0017] The graph is displayed based on the display size of the node, including:
[0018] The graph is displayed based on the display size of the node, and the display color and / or the display shape, so that different node types of nodes in the displayed graph have different display colors and / or display shapes.
[0019] In some embodiments, the node type includes at least one of a first entity type, a second entity type and an event type.
[0020] In some embodiments, before displaying the graph, the method further includes:
[0021] determining a first center node in the graph to be displayed that meets a first preset condition;
[0022] Then, when displaying the graph, the first center node is highlighted and displayed.
[0023] In some embodiments, the first center node that meets the first preset condition includes a predetermined number of nodes with the highest relationship density.
[0024] In some embodiments, before displaying the graph, the method further includes:
[0025] determining the node level of the node relative to the first center node;
[0026] Then, when displaying the graph, the node level of the node relative to the first center node is different, and the display brightness and / or the display transparency of the node are different, wherein the display brightness of the node gradually decreases as the node level increases, or the display transparency of the node gradually decreases as the node level increases.
[0027] In some embodiments, the determining the node level of the node relative to the first center node comprises:
[0028] determining the node level of other nodes in the graph to be displayed based on the distance value of the other nodes from the first center node.
[0029] In some embodiments, only a predetermined number of node levels are displayed in the displayed graph, and / or the largest node level in the displayed graph is displayed in the extinguished state.
[0030] In some embodiments, after displaying the graph, the method further comprises:
[0031] determining a second center node in the displayed graph based on a triggering operation of the user;
[0032] switching the displayed graph to a second graph that highlights the second center node.
[0033] In some embodiments, the determining the second center node in the graph to be displayed based on the triggering operation of the user comprises:
[0034] determining the second center node in the displayed graph based on at least one of a node clicking operation, a hovering operation, or a searching operation of the user.
[0035] In some embodiments, in the second graph, nodes of a predetermined node level associated with the second center node are displayed in the normal state, and other nodes are displayed in the extinguished state.
[0036] In some embodiments, the method further comprises:
[0037] providing a graph construction interface, the graph construction interface displaying a to-be-confirmed question and a third graph corresponding to the to-be-confirmed question, wherein the to-be-confirmed question is associated with at least one node in the third graph, and the associated node is highlighted in the third graph.
[0038] In some embodiments, after providing the graph construction interface, the method further comprises at least one of:
[0039] after obtaining a determination result of the user for the to-be-confirmed question, highlighting at least one node associated with the to-be-confirmed question in the third graph;
[0040] after obtaining a negative result of the user for the to-be-confirmed question, displaying at least one node associated with the to-be-confirmed question in the third graph in the extinguished state;
[0041] After obtaining the uncertain result of the user for the to-be-confirmed question, the normal state of at least one node associated with the to-be-confirmed question in the third graph is maintained.
[0042] In some embodiments, the method further comprises:
[0043] A configuration graph interface is provided, and the configuration graph interface displays a user configuration type control and a fourth graph corresponding to the user configuration type, wherein the display size of the node in the fourth graph is associated with the construction times of the node.
[0044] In a second aspect, the present disclosure provides a display device of a graph, comprising:
[0045] An attribute information acquisition module is configured to acquire attribute information of a node in a graph to be displayed, wherein the attribute information includes a relationship density of the node, and the relationship density is used to indicate the number of relationships and / or events in which the node is involved.
[0046] A display size acquisition module is configured to acquire a display size of the node based on the relationship density of the node.
[0047] A graph display module is configured to display the graph based on the display size of the node, so that in the displayed graph, the relationship density of a node with a large display size is greater than the relationship density of a node with a small display size.
[0048] In some embodiments, the display size acquisition module comprises:
[0049] A density interval division unit is configured to divide the relationship densities of all nodes into at least two density intervals, and each density interval is provided with a corresponding display size.
[0050] A size determination unit is configured to determine the display size of the node according to the density interval in which the relationship density of the node is located.
[0051] In some embodiments, the density interval division unit is specifically configured to:
[0052] Based on the relationship densities of all nodes, a maximum density value, a minimum density value, and a median density value are acquired.
[0053] At least two density intervals are determined based on the maximum density value and the median density value, and / or at least two density intervals are determined based on the median density value and the minimum density value.
[0054] In some embodiments, the attribute information further includes a node type, and the device further comprises a display parameter module, which is specifically configured to:
[0055] obtain a display color and / or a display shape of the node based on a node type of the node,
[0056] The atlas display module is specifically configured to:
[0057] display the atlas based on the display size, the display color and / or the display shape of the node, so that nodes of different node types in the displayed atlas have different display colors and / or display shapes.
[0058] In some embodiments, the node types include at least one of a first entity type, a second entity type, and an event type.
[0059] In some embodiments, the apparatus further includes a first center node module configured to, before displaying the atlas,
[0060] determine a first center node in the atlas to be displayed that meets a first preset condition;
[0061] When displaying the atlas, the first center node is highlighted.
[0062] In some embodiments, the first center node that meets the first preset condition includes a predetermined number of nodes with the highest relationship density.
[0063] In some embodiments, the apparatus further includes a node level module configured to, before displaying the atlas,
[0064] determine a node level of the node relative to the first center node;
[0065] When displaying the atlas, the node level of the node relative to the first center node is different, and the display brightness and / or the display transparency of the node are different, wherein the display brightness of the node gradually decreases as the node level increases, or the display transparency of the node gradually decreases as the node level increases.
[0066] In some embodiments, the node level module is specifically configured to:
[0067] determine the node level of the other node based on a distance value of the other node from the first center node in the atlas to be displayed.
[0068] In some embodiments, only a predetermined number of node levels are displayed in the displayed atlas, and / or the largest node level in the displayed atlas is displayed in an extinguished state.
[0069] In some embodiments, the apparatus further includes a second center node module configured to, after displaying the atlas,
[0070] determine a second center node in the displayed graph based on a trigger operation of the user;
[0071] switch the displayed graph to a second graph in which the second center node is highlighted.
[0072] In some embodiments, the second center node module is specifically configured to:
[0073] determine a second center node in the displayed graph based on at least one of a node clicking operation, a hovering operation, and a searching operation of the user.
[0074] In some embodiments, in the second graph, nodes of a predetermined node level associated with the second center node are displayed in a normal state, and other nodes are displayed in an off state.
[0075] In some embodiments, the device further comprises a checking module, which is specifically configured to:
[0076] provide a graph building interface on which a to-be-confirmed question and a third graph corresponding to the to-be-confirmed question are displayed, wherein the to-be-confirmed question is associated with at least one node in the third graph, and the associated node is highlighted in the third graph.
[0077] In some embodiments, the device further comprises a third graph display module, which specifically comprises at least one of:
[0078] a first display unit configured to, after obtaining a determination result of the user for the to-be-confirmed question, display at least one node associated with the to-be-confirmed question in the third graph in a highlight state;
[0079] a second display unit configured to, after obtaining a negative result of the user for the to-be-confirmed question, display at least one node associated with the to-be-confirmed question in the third graph in an off state;
[0080] a third display unit configured to, after obtaining an uncertain result of the user for the to-be-confirmed question, maintain a normal state display of at least one node associated with the to-be-confirmed question in the third graph.
[0081] In some embodiments, the device further comprises a configuration graph module, which is specifically configured to:
[0082] provide a configuration graph interface on which a user configuration type control and a fourth graph corresponding to the user configuration type are displayed, and in the third graph, the display size of the node is associated with the number of times of building the node.
[0083] In a third aspect, the present disclosure provides a computer device, comprising:
[0084] A processor configured to implement the steps of the method in any one of the preceding aspects when the processor executes the computer program stored in the memory.
[0085] In a fourth aspect, the present disclosure provides a computer readable storage medium having stored thereon computer instructions that, when executed by a processor, implement the steps of the method in any one of the preceding aspects.
[0086] The technical solution provided by the embodiments of the present disclosure is to obtain attribute information of a node in a graph to be displayed, the attribute information including relationship density of the node, the relationship density being used to indicate the number of relationships and / or events in which the node is involved; obtain a display size of the node based on the relationship density of the node; and display the graph based on the display size of the node, so that in the displayed graph, the relationship density of a node with a large display size is greater than the relationship density of a node with a small display size, thereby providing a solution for displaying a graph based on relationship density of a node. With the above technical solution, the display size of different nodes is determined by the relationship density of the nodes, and then the graph can be displayed based on the display size of different nodes. Since the size of each node in the graph represents the relationship density of the node, more dimensional graph information can be displayed, thereby helping users better understand the graph. BRIEF DESCRIPTION OF DRAWINGS
[0087] The accompanying drawings, which are incorporated herein and constitute part of the specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the disclosure.
[0088] In order to more clearly illustrate the technical solutions in the embodiments of the present disclosure or the prior art, brief introductions to the drawings needed in the embodiments or prior art descriptions will be given below. Obviously, for those of ordinary skill in the art, other drawings can also be obtained from these drawings without any creative effort.
[0089] Figure 1 A flowchart of a graph display method provided by the embodiments of the present disclosure;
[0090] Figure 2 A graph diagram provided by the embodiments of the present disclosure;
[0091] Figure 3 A flowchart of another graph display method provided by the embodiments of the present disclosure;
[0092] Figure 4 Another graph diagram provided by the embodiments of the present disclosure;
[0093] Figure 5 An interface schematic diagram of a constructed graph interface provided by an embodiment of the present disclosure;
[0094] Figure 6 An exemplary interface schematic diagram of a fourth graph provided by an embodiment of the present disclosure,
[0095] Figure 7 A structural schematic diagram of a graph display device provided by an embodiment of the present disclosure;
[0096] Figure 8 A structural schematic diagram of another graph display device provided by an embodiment of the present disclosure. DETAILED DESCRIPTION
[0097] In order to more clearly understand the above-mentioned purposes, features and advantages of the present disclosure, the schemes of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments can be combined with each other without conflict.
[0098] In the following description, many specific details are set forth in order to provide a thorough understanding of the present disclosure, but the present disclosure can also be implemented in other ways different from those described herein; obviously, the embodiments in the description are only some of the embodiments of the present disclosure, not all the embodiments.
[0099] In an embodiment of the present disclosure, the graph involved therein can be a knowledge graph, which can be defined as a graph-like organization form of knowledge and data, and entity nodes, event nodes and relationship edges are the main three constituent elements, which can become knowledge triples; in the knowledge graph, the entity nodes and event nodes therein can be associated by different types of relationship edges.
[0100] The entity node in the knowledge graph refers to a semantic word with specific meaning, such as information of a person, a place, an organization or a number.
[0101] The event node in the knowledge graph refers to one or more entity nodes with specific meaning and a pre-defined event name connected by a specific relationship word, forming a set of associated information, thereby depicting a dynamic behavior, and the one or more entity nodes with specific meaning and the pre-defined event name node can be called an event node. The following describes a financing event, a film shooting event and a film and television work release event respectively.
[0102] For the financing event, the content can include:
[0103] Financing event-finance time-2020.5.20
[0104] Financing event-finance party-XXX company
[0105] Financing Event - Financing Amount - $1,000,000,000
[0106] Financing Event - Investors - XXX Corporation
[0107] For a film production event, the following information can be included:
[0108] Production Location - Atlanta
[0109] Production Location - Berlin
[0110] Production Location - Puerto Rico
[0111] Production Location - Iceland
[0112] Production Dates - April 30, 2015 - August 22, 2015
[0113] For a film release event, the following information can be included:
[0114] Film Release Event - Film Title - Title
[0115] Film Release Event - Release Date - Date
[0116] Film Release Event - Release Location - Location
[0117] Film Release Event - Director - Person Name
[0118] Film Release Event - Starring - Person Name
[0119] For an example, for a specific film release event, the following information can be included:
[0120] Production Year - 2016
[0121] Production Company - Marvel Studios, Inc. (USA) - Distributor - The Walt Disney Studios (USA)
[0122] Production Country - USA
[0123] Production Budget - $250,000,000
[0124] Running Time - 147 minutes
[0125] Release Date - May 6, 2016 (China, Mainland, USA)
[0126] Rating - PG-13
[0127] For a specific film release event 01, the relationship edges that it can include can include the following:
[0128] Film Release Event 01 - Film Title - Iron Man
[0129] Movie release event 01 - Release date - April 30, 2008
[0130] Movie release event 01 - Release country - China
[0131] Movie release event 01 - Director - Jon Favreau
[0132] Movie release event 01 - Main actor - Robert Downey Jr.
[0133] Movie release event 01 - Main actor - Gwyneth Paltrow
[0134] Movie release event 01 - Main actor - Terrence Howard
[0135] Movie release event 01 - Main actor - Jeff Bridges
[0136] The knowledge graph in the embodiments of the present disclosure can adopt a manual annotation and / or model extraction manner to extract graph knowledge, and then construct a knowledge graph based on the above graph knowledge. During the construction of the knowledge graph, or after the construction of the knowledge graph is completed, the knowledge graph needs to be displayed so that the user can directly read the related content from the graphical knowledge graph. However, when the existing knowledge graph is displayed, the display method of the node is often not distinguished. When the number of nodes displayed on the knowledge graph is large, it is difficult to distinguish different nodes on the knowledge graph, which affects the user experience. The technical scheme provided by the embodiments of the present disclosure acquires attribute information of nodes in a graph to be displayed, the attribute information including relationship density of the nodes, the relationship density being used to indicate the number of relationships and / or events in which the nodes are located; acquires display size of the nodes based on the relationship density of the nodes; and displays the graph based on the display size of the nodes, so that in the displayed graph, the relationship density of a node with large display size is greater than the relationship density of a node with small display size, thereby providing a scheme for displaying a graph based on relationship density of nodes. By using the above technical scheme, the display size of different nodes is determined by the relationship density of the nodes, and then the graph can be displayed based on the display size of different nodes. Since the size of each node in the graph represents the relationship density of the node, more dimensional graph information can be displayed, thereby helping the user to better understand the graph.
[0137] Figure 1 A flowchart of a method for displaying a graph according to an embodiment of the present disclosure is shown in FIG. 1, which includes the following steps: Figure 1
[0138] Step 101: Acquire attribute information of nodes in a graph to be displayed, the attribute information including relationship density of the nodes, the relationship density being used to indicate the number of relationships and / or events in which the nodes are located.
[0139] The to-be-presented knowledge graph refers to a knowledge graph that has been constructed, and can include multiple nodes. The attribute information of a node can be understood as the characteristic information of the node itself and the distribution information of the node in the knowledge graph. The specific information included in the attribute information of the node can be various, and the relationship density of the node is one of them. The relationship density of the node can reflect the number of relationships and / or events in which the node is involved, that is, the relationship density of the current node can be represented by calculating the sum of the total number of times that the current node is a preceding node, a succeeding node, and exists in an event. The relationship densities of different nodes can be different.
[0140] For example, the main actor of Iron Man is Robert Downey Jr., so on the graph, the node "Iron Man" is connected to the node "Robert Downey Jr." through the relationship edge "actor", and "Iron Man" is the preceding node of "Robert Downey Jr.", and "Robert Downey Jr." is the succeeding node of Iron Man. Assuming that the number of times that "Iron Man" is a preceding node is m, the number of times that "Iron Man" is a succeeding node is n, and there is a movie and television work release event (1 event), the relationship density of the node "Iron Man" can be m+n+1.
[0141] In the embodiments of the present disclosure, after the construction of the knowledge graph is completed, the related information of the knowledge graph can be stored in a preset database, and the attribute information of the node can be obtained from the database.
[0142] Step 102, obtaining the display size of the node based on the relationship density of the node.
[0143] The display size of the node is information used to represent the size in the display style of the node. The relationship density of the node is different, the display size of the node is different, and the greater the relationship density of the node is, the greater the display size of the node can be.
[0144] In the embodiments of the present disclosure, obtaining the display size of the node based on the relationship density of the node can include: dividing the relationship densities of all nodes into at least two density intervals, each density interval being provided with a corresponding display size; and determining the display size of the node according to the density interval in which the relationship density of the node is located. The density interval refers to a density range from a smaller relationship density to a larger relationship density, which can include multiple relationship densities. The number of divided density intervals can be set according to actual conditions, and is not limited. In the embodiments of the present disclosure, different density intervals can be provided with different display sizes. After the relationship density of the node is determined, the density interval in which the relationship density is located can be determined first, and then the display size of the node is determined.
[0145] In some embodiments, the interval division of the relationship density of all nodes to obtain at least two density intervals can include: obtaining a maximum density value, a minimum density value and a median density value based on the relationship density of all nodes; determining at least two density intervals based on the maximum density value and the median density value, and / or determining at least two density intervals based on the median density value and the minimum density value. When dividing the density interval, the relationship density of all nodes can be sorted first, the maximum density value and the minimum density value are determined, the node whose relationship density is in the median is determined, and the relationship density of the node is the median density value. Then, the density interval can be determined between the maximum density value and the median density value and / or between the median density value and the minimum density value according to the number of preset density intervals.
[0146] For example, assuming that the sorted relationship density of all nodes is: 5, 5, 10, 100, 100, 100, 1000, wherein the maximum density value is 1000, the minimum density value is 5, and the median density value is 100. The density interval can be determined based on the above three density values.
[0147] Step 103, based on the display size of the node, the graph is displayed, so that in the displayed graph, the relationship density of the node with large display size is greater than the relationship density of the node with small display size.
[0148] In the embodiments of the present disclosure, after determining the display size of the node based on the relationship density of the node, all nodes can be rendered on the constructed knowledge graph to obtain a knowledge graph including nodes with different display sizes, and the knowledge graph is displayed on the knowledge graph interface. In the displayed graph, the relationship density of the node with large display size is greater than the relationship density of the node with small display size.
[0149] For example, Figure 2 A schematic diagram of a graph provided by an embodiment of the present disclosure is shown in FIG. 1. Figure 2 As shown in the figure, the sizes of different nodes in the displayed graph are different, for example, the sizes of the nodes of Iron Man, Thor, Avengers 4, Avengers 3 and Captain America 3 are larger than those of other nodes.
[0150] The technical scheme provided by the embodiments of the present disclosure comprises: obtaining attribute information of a node in a graph to be displayed, the attribute information comprising a relationship density of the node, the relationship density being used to indicate a number of relationships and / or events in which the node is involved; obtaining a display size of the node based on the relationship density of the node; and displaying the graph based on the display size of the node, so that in the displayed graph, the relationship density of a node with a large display size is greater than the relationship density of a node with a small display size. Thus, a scheme for displaying a graph based on the relationship density of a node is provided. With the above technical scheme, the display size of different nodes is determined by the relationship density of the nodes, and then the graph can be displayed based on the display size of different nodes, so that the display of graph information in more dimensions is realized. When a user views the graph, the user can perceive the relationship density of a node through the size of the node, and thus the user can easily obtain information about nodes with a large or small relationship density in the graph, and thus the user can better understand the graph.
[0151] In some embodiments, the attribute information can further comprise a node type. The method for displaying a graph provided by the embodiments of the present disclosure can further comprise: obtaining a display color and / or a display shape of the node based on the node type of the node; and displaying the graph based on the display size, the display color and / or the display shape of the node, so that in the displayed graph, the size of a node is not only related to the relationship density, but also different node types have different display colors and / or display shapes, and thus more information can be conveyed to the user and the user can better understand the graph.
[0152] The node type can comprise at least one of a first entity type, a second entity type and an event type. The nodes in the graph can be divided into three types based on events and relationships, and can comprise nodes of the first entity type, nodes of the second entity type and nodes of the event type. The nodes of the first entity type mainly represent entity nodes that do not belong to any relationship edge, and are independent nodes in the graph without preceding nodes, following nodes and connecting lines. The nodes of the second entity type mainly represent nodes with preceding nodes and following nodes related to relationship edges. The nodes of the event type are nodes in an event, and represent nodes included in the event. In the embodiments of the present disclosure, different variable description types and states can be set for different node types, and when displayed in the front end, a specific variable can be read from the back end. For example, the front end can indicate the display style of a node, i.e., different display colors and / or display shapes, through a "style" tag. The back end can distinguish different node types through "type". When the graph is displayed, the back end can transmit the "type" variable to the "style" of the front end, so as to display the nodes of different node types in different styles, so as to realize the display of different node types.
[0153] Different node types can be distinguished by different display colors and / or display shapes. In this embodiment, the display color and / or display shape of each node can be determined based on a pre-established correspondence between node types, display colors, and display shapes. The graph is then displayed based on the node's display size, display color, and / or display shape. Display colors and / or display shapes can include various types, such as red, yellow, and blue. Display shapes can also include various types, such as star shapes and circles. In one specific embodiment, assuming the node types include three types: a first entity type, a second entity type, and an event type, then in the graph, nodes of the second entity type are displayed in blue, nodes of the event type are displayed in purple, and nodes of the first entity type are displayed in green.
[0154] In the above embodiments, the display graph is displayed based on the display color and / or display shape determined by the node type and the display size determined by the relationship density of the nodes. The content displayed in the graph is more multi-dimensional and vivid. Users can distinguish the type of node based on color or shape, which can help users better understand the existence form and structure of the knowledge graph and improve the user experience.
[0155] Based on the above embodiments, Figure 3 A flowchart illustrating another method for displaying a spectrum provided in this embodiment of the present disclosure is shown below. Figure 3 As shown, before displaying the atlas, the atlas display method provided in this embodiment may further include steps 301 and 302; after displaying the atlas, the atlas display method provided in this embodiment may further include steps 304-305. Specifically:
[0156] Step 301: Determine the first central node in the graph to be displayed that meets the first preset condition.
[0157] The central node can be a node that the user may be interested in or pay close attention to, and there are various ways to determine the central node. The first preset condition can be a sorting range of relationship density. For example, the first preset condition can be the nodes sorted from largest to smallest relationship density, with the sorting range from first to fifth. In some embodiments, the first central node that satisfies the first preset condition includes a predetermined number of nodes with the highest relationship density. The preset number can be set according to actual conditions, for example, 5.
[0158] Step 302: Determine the node level relative to the first central node.
[0159] The node level can be understood as the degree of association between the current node and the center node when the center node exists in the graph, and can be measured by the distance from the center node, i.e., the number of relationship edges contained in the shortest path between the two nodes. For example, for a node of the second entity type, the distance between the preceding node and the following node of the same relationship is 1.
[0160] In some embodiments, determining the node level of the node relative to the first center node can include determining the node levels of other nodes in the graph to be displayed based on the distance values of the other nodes from the first center node. The greater the distance value of a node from the first center node, the greater the node level.
[0161] Since the number of nodes in the graph is large, in some embodiments, only a predetermined number of node levels are displayed in the displayed graph, and / or the largest node level in the displayed graph is displayed in an extinguished state. The predetermined number can be set according to actual conditions, for example, the predetermined number can be 2, i.e., only the first center node and the nodes at the first and second levels relative to the first center node are displayed.
[0162] Since the number of nodes in the graph is large, in some embodiments, the largest node level in the displayed graph is displayed in an extinguished state. For example, if only the first center node and the nodes at the first and second levels relative to the first center node are displayed, the nodes at the second level can be displayed in an extinguished state.
[0163] It should be noted that the highlight, normal, and extinguished in the embodiments of the present application can be understood as three relative degrees of visual perception, with the highlight being the most eye-catching, the normal being the second, and the extinguished being the last. For example, the extinguished state described above can be a low transparency state, indicating that the node is not within the display range, and the transparency of the node can be different according to the distance value from the first center node.
[0164] Step 303, displaying the graph.
[0165] After determining the first center node in the above steps, the first center node is highlighted and displayed prominently when the graph is displayed.
[0166] After determining the level of the node relative to the first center node in the above steps, when the graph is displayed, the display brightness and / or display transparency of the node are different for different node levels relative to the first center node, wherein the display brightness of the node gradually decreases as the node level increases, or the display transparency of the node gradually decreases as the node level increases. The display of the above graph can help the user quickly complete the preliminary overview of the graph information.
[0167] For example, Figure 2The graph in the figure can reflect the node density of the node, and the node type can be reflected by the different colors of the node, so that the user can preliminarily understand the density distribution of the graph, and the first center node with the top five relationship density in the current graph is highlighted and displayed, which is Iron Man, Thor, Avengers 4, Avengers 3 and Captain America 3. The first center node can display the 2-level node, the 3-level node is in the extinguished state, and the remaining nodes are in the normal state; in Figure 2 In this hot spot view, the nodes in the maximum node level of the current display level can be displayed in the extinguished state, for example, the current display level is level 3, and the level 3 node is in the extinguished state; when the current display level is scaled to level 2, the level 2 node is in the extinguished state.
[0168] Step 304, determining the second center node in the displayed graph based on the triggering operation of the user.
[0169] Among them, the second center node can be a center node determined after the first center node in the graph is determined.
[0170] In some embodiments, based on the triggering operation of the user, the second center node of the graph to be displayed can include: determining the second center node in the displayed graph based on at least one of the node clicking operation, the hovering operation, and the search operation of the user. Based on the interactive operation of the user, the second center node of the graph that has been displayed can be determined, and the user action can be associated with the graph display. For example, the user searches for "Iron Man", and then determines the node "Iron Man" as the second center node.
[0171] Step 305, switching the displayed graph to a second graph highlighting the second center node.
[0172] After determining the second center node, the highlighted node can be switched from the first center node to the second center node, and the second graph can be displayed with the second center node as the center. The nodes in the second graph are different from the node level of the second center node, and the display brightness and / or display transparency of the nodes are different. The second graph is different from the center node of the graph that has been displayed, that is, the emphasis of the display is different.
[0173] In some embodiments, in the second graph, the nodes of the predetermined node level associated with the second center node are displayed in the normal state, and the other nodes are displayed in the extinguished state. When the node is in the display range but is not the center node, it can be displayed in the normal state.
[0174] Specifically, the highlighted display of the first center node in the displayed graph is canceled, the second center node is highlighted and displayed, and the second graph is displayed in the center of the current display interface.
[0175] Exemplary, Figure 4 Another schematic diagram of a graph provided by an embodiment of the present disclosure, the graph in the diagram can embody a center node, the degree of association of other nodes with the center node, node density, and node type; the diagram takes the node "Iron Man" selected by the user as a second center node and displays it in the center of the screen for continuous highlighting, only keeps the first-level nodes associated with the second center node in a normal state, and the second-level nodes are all in an extinguished state, which does not change in the extinguished state due to user zooming; and the user can control whether the nodes at the second level and above are in the extinguished state through a focus control, the focus control is enabled by default, if the user disables it, the second center node is still highlighted, and the rest of the logic is the same as the display logic of the first center node. When switching from the first center node to the second center node, a switching effect can be added, after the user triggers the operation on the control, the displayed graph can be rotated and zoomed as a whole, the rotation direction can be determined by the relative position of the node and the center line, and the rotation direction can include clockwise or counterclockwise, and the second center node is placed in the center of the screen. Optionally, if the user selects a node that is originally invisible in the graph through a search operation and a node click operation, the node and the first-level nodes associated with the node can be displayed in the center of the screen after the effect is rotated by 180 degrees.
[0176] In the above embodiments, the graph can be displayed based on the center node, and the center node can be switched based on the user's selection, which can help the user focus on the center node and distinguish the nodes at different levels centered on the center node through visual effects such as node transparency, thereby improving the user experience.
[0177] Most of the current graph data visualization focuses on the user's operation on the graph itself, of course, it is an important task for graph visualization to provide a series of auxiliary functions to help the user focus, view, search, and understand the content of the graph, but for platform-type graph products, in addition to querying the graph, the user also has other work tasks, such as checking the correctness, configuring nodes, etc. At this time, focusing only on the graph itself is of limited help to the user to complete other work. If the user's operation can be linked to the graph through flexible linkage, it will help the user understand the current task and provide positive incentives.
[0178] Manual checking is an essential part of building a knowledge graph. The display method of the graph provided by the embodiment of the present disclosure can further include: providing a graph building interface, and the graph building interface displays a to-be-confirmed question and a third graph corresponding to the to-be-confirmed question, wherein the to-be-confirmed question is associated with at least one node in the third graph, and the associated node is highlighted in the third graph.
[0179] The interface for constructing the knowledge graph is an interface for constructing a knowledge graph. Since the knowledge graph can be constructed by using the knowledge labeling method in the form of question and answer in the embodiment of the present disclosure, the question and answer form of the knowledge graph can be combined with the display feedback of the graph to check.
[0180] In the embodiment of the present disclosure, the part to be checked can be converted into a to-be-confirmed question, which is displayed on the interface for constructing the graph, and a third graph corresponding to the to-be-confirmed question can also be displayed. The nodes associated with the to-be-confirmed question in the third graph can be highlighted.
[0181] In some embodiments, after providing the interface for constructing the graph, the method further includes at least one of the following: after obtaining a determination result of the user for the to-be-confirmed question, highlighting at least one node associated with the to-be-confirmed question in the third graph; after obtaining a negative result of the user for the to-be-confirmed question, extinguishing at least one node associated with the to-be-confirmed question in the third graph; and after obtaining an uncertain result of the user for the to-be-confirmed question, maintaining the normal state display of at least one node associated with the to-be-confirmed question in the third graph.
[0182] The user can answer the to-be-confirmed question displayed on the interface for constructing the graph. According to the answer result of the user, the nodes associated with the to-be-confirmed question can be displayed differently. When the user has a determination result for the to-be-confirmed question, the nodes associated with the to-be-confirmed question can be highlighted. When the user has a negative result for the to-be-confirmed question, the nodes associated with the to-be-confirmed question can be extinguished. When the user has an uncertain result for the to-be-confirmed question, the nodes associated with the to-be-confirmed question can be normally displayed.
[0183] For example, Figure 5 The interface schematic diagram of the interface for constructing the graph provided by the embodiment of the present disclosure is shown in the figure. A to-be-confirmed question "Is the movie Iron Man produced by the American Marvel movie studio?" and the graph corresponding to the to-be-confirmed question are exemplarily displayed. The graph display range in the lower right corner is the nodes of the first entity type, the nodes of the second entity type, and the event type nodes of the current to-be-confirmed question, and the first-level nodes thereof. The nodes are normally displayed. The second-level nodes and the nodes above the second-level nodes are extinguished. After the user clicks "Yes", the nodes corresponding to the to-be-confirmed question are highlighted. After the user clicks "No", the nodes corresponding to the to-be-confirmed question are extinguished. When the user clicks "Uncertain", the graph display effect does not change.
[0184] In the embodiments of the present disclosure, when the to-be-confirmed question is switched, the change of the graph is equivalent to switching different nodes as the center node in the same graph. The specific effect can be that the to-be-confirmed question moves in from left to right, and moves out from right after answering, while the new to-be-confirmed question moves in from left. The action sequence can include: clicking the answer-graph highlighting feedback-to-be-confirmed question moving out / new to-be-confirmed question moving in-according to the graph, switching the center node to highlight the new to-be-confirmed question.
[0185] In the above embodiments, the part to be checked can be converted into a question, and the nodes related to the question can be displayed in the form of a center view in the page, thereby assisting the user in understanding the question and more intuitively seeing the relationship between the nodes involved in the question. The user completes the check by answering the question, and the user's judgment result for the question will have different feedback in the graph. The real-time feedback on the graph can have a certain positive incentive effect. According to different user check tasks, a plurality of interaction mechanisms are provided to associate the user actions / tasks with the graph display, which can help the user understand the current task and provide positive incentives.
[0186] In some embodiments, the graph display method can further include providing a configuration graph interface, and constructing a fourth graph on the graph interface, wherein the user configuration type control and the fourth graph corresponding to the user configuration type are displayed on the graph interface, and in the fourth graph, the display size of the node is associated with the construction number of the node.
[0187] The user configuration type control is a control provided to the user to complete the configuration operation. The control can include a plurality of controls, such as at least one of a deletion control, an editing control, an adding control, a viewing source control, a hiding relationship name control, and a batch operation control. Different controls correspond to different functions. For example, when the user triggers the deletion control, the corresponding node in the graph can be deleted. When the user triggers the adding control, the corresponding node can be added to the graph.
[0188] In the embodiments of the present disclosure, the user configuration type control and the corresponding fourth graph can be displayed on the graph construction interface, that is, the change of the graph can be displayed while the user is configuring. In the fourth graph, the display size of the node can be associated with the construction number in the construction information of the node. The more the construction number, the larger the display size of the node, which can assist the user in more intuitively understanding the construction of the current graph. The construction number can also be divided into different construction number intervals according to the processing method of the node density described above, and different construction number intervals correspond to different display sizes.
[0189] It should be noted that in the embodiments of the present disclosure, the user configuration type can be understood as the node type that the user wants to include in the graph to be constructed, for example, the user wants to include nodes of the types of movies, leading actors, box office, production companies, box office amounts, etc. in the graph to be constructed, and therefore, instances of these nodes need to be constructed, i.e., the content of each node needs to be concretized through manual annotation, model extraction, etc. to construct the instance nodes in the graph, such as constructing the nodes of the type of movies into instance nodes such as Iron Man, Farewell My Concubine, and Transformers, and the number of construction times is the number of instance nodes corresponding to the nodes of the type of movies. If the user initializes the graph, the nodes of these types have not yet been constructed into instances, and the nodes in the fourth graph can be of the same size, but if it is not an initial configuration graph, all or part of the nodes have been constructed into instance nodes, and the size can be used in the fourth graph to reflect the number of construction times, i.e., the number of instance nodes. Different construction times and node sizes can help the user more intuitively understand the construction status of the current graph.
[0190] Exemplary, Figure 6 An exemplary interface schematic diagram of the fourth graph provided by the embodiments of the present disclosure is shown in the figure. When constructing the graph, the user can add or delete nodes of the first entity type, nodes of the second entity type, and nodes of the event type that need to be displayed in the graph on the left side; and the user's adding, deleting, etc. operations are real-time drawn in the right graph area and displayed to the user, for example, after creating a node of the second entity type, a connection line between the two nodes is synchronously drawn in the graph. In addition, the number of constructed instances is associated with the node size. It is assumed that the number of instances constructed for "movie" is the largest, so the size of the node of "movie" is the largest, and the number of instances constructed for "work" is the smallest, so the size of the node of "work" is the smallest. In addition, to help the user understand the current graph construction status, a "reflect instance number" switch is set. When the switch is off, the sizes of the nodes are consistent, and when the switch is on, the sizes of the nodes are related to the number of construction times.
[0191] In the above embodiments, the process of configuring the graph by the user can be combined with the feedback of the graph to help the user understand the change process of the graph and better configure the graph.
[0192] Corresponding to the above method embodiments, the embodiments of the present disclosure also provide a graph display device, Figure 7 A structural schematic diagram of a graph display device provided by the embodiments of the present disclosure is shown in the figure, Figure 7 As shown, the device includes an attribute information acquisition module 71, a display size acquisition module 72, and a graph display module 73.
[0193] The attribute information acquisition module 71 is configured to acquire attribute information of a node in a to-be-presented graph. The attribute information includes a relationship density of the node, which indicates a number of relationships and / or events in which the node is involved. The to-be-presented graph refers to a knowledge graph that has been constructed. The knowledge graph can include a plurality of nodes. The attribute information of the node can be understood as characteristic information of the node itself and distribution information of the node in the knowledge graph. The attribute information of the node can include a plurality of specific information, and the relationship density of the node is one of the specific information. The relationship density of the node can reflect the number of relationships and / or events in which the node is involved, that is, the relationship density of the current node can be represented by calculating the sum of the total number of times that the current node is a preceding node, a succeeding node, and exists in an event. The relationship densities of different nodes can be different.
[0194] For example, the main actor of the Iron Man is Robert Downey Jr., and a node "Iron Man" is connected to a node "Robert Downey Jr." through a relationship edge "actor" on the graph. The "Iron Man" is a preceding node of the "Robert Downey Jr.", and the "Robert Downey Jr." is a succeeding node of the "Iron Man". Assuming that the number of times that the "Iron Man" is a preceding node is m, the number of times that the "Iron Man" is a succeeding node is n, and there is one event of a movie being released, the relationship density of the node "Iron Man" can be m+n+1.
[0195] In the embodiments of the present disclosure, after the knowledge graph is constructed, the related information of the knowledge graph can be stored in a preset database, and the attribute information of the node can be acquired from the database.
[0196] The display size acquisition module 72 is configured to acquire a display size of the node based on the relationship density of the node. The display size of the node is information used to represent the size in the display style of the node. The display size of the node is different when the relationship density of the node is different. The larger the relationship density of the node is, the larger the display size of the node can be.
[0197] In some embodiments, the display size acquisition module 72 includes a density interval division unit configured to divide the relationship densities of all nodes into at least two density intervals, and each density interval is provided with a corresponding display size; and a size determination unit configured to determine the display size of the node according to the density interval in which the relationship density of the node is located. The density interval refers to a density range from a smaller relationship density to a larger relationship density, which can include a plurality of relationship densities. The number of divided density intervals can be set according to actual conditions, and is not limited specifically. In the embodiments of the present disclosure, different density intervals can be provided with different display sizes. After the relationship density of the node is determined, the density interval in which the relationship density is located can be determined first, and then the display size of the node can be determined.
[0198] In some embodiments, the density interval division unit is specifically configured to: obtain a maximum density value, a minimum density value and a median density value based on the relationship density of all nodes; determine at least two density intervals based on the maximum density value and the median density value, and / or determine at least two density intervals based on the median density value and the minimum density value. When dividing the density interval, the relationship density of all nodes can be sorted first, the maximum density value and the minimum density value are determined, the node whose relationship density is in the median is determined, and the relationship density of the node is the median density value. Then, the density interval can be determined between the maximum density value and the median density value and / or between the median density value and the minimum density value according to the number of preset density intervals.
[0199] For example, assuming that the sorted relationship density of all nodes is: 5, 5, 10, 100, 100, 100, 1000, wherein the maximum density value is 1000, the minimum density value is 5, and the median density value is 100. The density interval can be determined based on the above three density values.
[0200] The atlas display module 73 is configured to display the atlas based on the display size of the nodes, so that in the displayed atlas, the relationship density of the node with a large display size is greater than the relationship density of the node with a small display size. In the embodiments of the present disclosure, after the display size of the node is determined based on the relationship density of the node, all nodes can be rendered on the constructed knowledge graph to obtain a knowledge graph including nodes with different display sizes, and the knowledge graph is displayed on the knowledge graph interface. In the displayed atlas, the relationship density of the node with a large display size is greater than the relationship density of the node with a small display size.
[0201] For example, Figure 2 A schematic diagram of an atlas provided by the embodiments of the present disclosure is as follows: Figure 2 As shown in the figure, the sizes of different nodes in the displayed atlas are different, for example, the sizes of the nodes of Iron Man, Thor, Avengers 4, Avengers 3 and Captain America 3 are greater than the sizes of other nodes.
[0202] In the embodiments of the present disclosure, attribute information of a node in a to-be-displayed graph is acquired, the attribute information including a relationship density of the node, the relationship density being used to indicate a number of relationships and / or events in which the node is involved; a display size of the node is acquired based on the relationship density of the node; and the graph is displayed based on the display size of the node, so that in the displayed graph, the relationship density of a node with a large display size is greater than the relationship density of a node with a small display size, thereby providing a scheme for displaying a graph based on a relationship density of a node. By using the above technical scheme, the display size of different nodes is determined by the relationship density of the nodes, and then the graph can be displayed based on the display size of different nodes, thereby achieving display of more-dimensional graph information, and when a user views the graph, the user can perceive the relationship density of the nodes through the node size, and thus can easily obtain information about nodes with greater or smaller relationship density in the graph, thereby helping the user to better understand the graph.
[0203] In some embodiments, the attribute information further includes a node type, and the device further includes a display parameter module, which is specifically configured to acquire a display color and / or a display shape of the node based on the node type of the node, and the graph display module 73 is specifically configured to display the graph based on the display size of the node, and the display color and / or the display shape of the node, so that in the displayed graph, the node size and the relationship density are related, and nodes of different node types have different display colors and / or display shapes, thereby expressing more information to the user and helping the user to better understand the graph.
[0204] In some embodiments, the node type includes at least one of a first entity type, a second entity type, and an event type. The nodes in the graph can be divided into three types based on events and relationships, and can include nodes of the first entity type, nodes of the second entity type, and nodes of the event type. The nodes of the first entity type mainly represent entity nodes that do not belong to any relationship edge, and are independent nodes without preceding nodes, following nodes, and connection lines when displayed in the graph. The nodes of the second entity type mainly represent preceding nodes and following nodes related to relationship edges. The nodes of the event type are nodes in events, and represent nodes included in events. In the embodiments of the present disclosure, different variable description types and states can be set for different node types, and when displayed in the front end, specific variables in the back end can be read. For example, the front end can represent the display style of the node, i.e., different display colors and / or display shapes, through a "style" tag, and the back end can distinguish different node types through "type". When the graph is displayed, the back end can transmit the "type" variable to the "style" of the front end, so as to display the nodes of different node types in different styles, thereby achieving differentiated display.
[0205] Different node types can be distinguished by different display colors and / or display shapes. In the embodiments of the present disclosure, the display color and / or display shape corresponding to each node can be determined based on a pre-established correspondence between node types, display colors and display shapes, and the graph can be displayed based on the display size of the node and the display color and / or display shape. The display color and / or display shape can include multiple colors, such as red, yellow and blue, and the display shape can also include multiple shapes, such as star shape and circle shape. In one specific embodiment, assuming that the node types include three types of first entity type, second entity type and event type, in the graph, the nodes of the second entity type are displayed in blue, the nodes of the event type are displayed in purple, and the nodes of the first entity type are displayed in green.
[0206] In the above embodiments, the graph is displayed based on the display color and / or display shape determined based on the node type and the display size determined based on the relationship density of the node. The content displayed by the graph is more multi-dimensional and visual, the user can distinguish the type of node based on the color or shape, which can help the user better understand the existence form and structure of the knowledge graph, and improve the user experience.
[0207] On the basis of the above embodiments, Figure 8 Another structural schematic diagram of a graph display device provided by the embodiments of the present disclosure is shown in FIG. 7. As shown in FIG. 7, the device further includes a first center node module 74, a node level module 75, a second center node module 76, a checking module 77, a third graph display module 78 and a configuration graph module 79. Figure 8
[0208] The first center node module 74 is specifically configured to determine a first center node that meets a first preset condition in a graph to be displayed before displaying the graph, and the first center node is highlighted and displayed prominently when the graph is displayed.
[0209] The center node can be a node that the user is likely to be interested in or focus on, and the center node can be determined in multiple ways. The first preset condition can be a sorting range of relationship density, for example, the first preset condition can be nodes whose relationship density is sorted from large to small, and the nodes in the sorting range from the first to the fifth. In some embodiments, the first center node that meets the first preset condition includes a predetermined number of nodes with the highest relationship density, and the predetermined number can be set according to actual conditions, for example, set to 5.
[0210] The node level module 75 is specifically configured to: before displaying the graph, determine a node level of the node relative to the first center node; and then, when displaying the graph, the node level of the node relative to the first center node is different, and the display brightness and / or display transparency of the node are different, wherein the display brightness of the node gradually decreases as the node level increases, or the display transparency of the node gradually decreases as the node level increases. The node level can be understood as the degree of association of the current node with the center node when the graph has the center node, and can be measured by the distance from the center node, that is, the number of relationship edges contained in the shortest path between the two nodes. For example, for a node of the second entity type, the distance between the preceding node and the following node of the same relationship is 1.
[0211] The display of the above graph can help the user quickly complete the preliminary graph information overview.
[0212] For example, Figure 2 The graph in the figure can reflect the node density of the node, and the node type can be reflected by the different colors of the node. The user can preliminarily understand the density distribution of the graph, and the first center nodes with the top five relationship density rankings in the current graph are highlighted and displayed, which are Iron Man, Thor, Avengers 4, Avengers 3 and Captain America 3. The 2nd level nodes can be displayed around the first center node, the 3rd level nodes are in the extinguished state, and the remaining nodes are in the normal state. Figure 2 In this hot spot view, the nodes in the maximum node level of the current display level can be displayed in the extinguished state. For example, if the current display level is level 3, the 3rd level nodes are in the extinguished state. When the current display level is scaled to level 2, the 2nd level nodes are in the extinguished state.
[0213] In some embodiments, the node level module 75 is specifically configured to determine the node level of other nodes in the graph to be displayed based on the distance value of the other nodes from the first center node. The greater the distance value of the node from the first center node, the greater the node level.
[0214] Because the number of nodes in the graph is large, in some embodiments, only a predetermined number of node levels are displayed in the displayed graph, and / or the maximum node level in the displayed graph is displayed in the extinguished state. The predetermined number can be set according to actual conditions, for example, the predetermined number can be 2, that is, only the first center node and the nodes of the 1st and 2nd levels relative to the first center node are displayed. The above extinguished state refers to a low transparency state, indicating that the node is not in the display range, and the transparency of the node can be different according to the distance value from the first center node.
[0215] Since the number of nodes in the graph is large, in some embodiments, the largest node level in the displayed graph is displayed in the extinguished state. For example, if only the first center node and the nodes of the first and second levels relative to the first center node are displayed, the nodes of the second level can be displayed in the extinguished state.
[0216] It should be noted here that the high light, normal and extinguished in the embodiments of the application can be understood as three relative visual perception degrees, the high light is the most eye-catching for the user, the normal is the second, and the extinguished is the last. For example, the extinguished state described above can be a low transparency state, indicating that the node is not in the display range, and the transparency of the node can be different according to the distance value from the first center node.
[0217] The second center node module 76 is specifically configured to: determine a second center node in the displayed graph based on a triggering operation of the user after displaying the graph; and switch the displayed graph to a second graph highlighting the second center node. The second center node can be a center node determined again after the first center node in the graph is determined.
[0218] In some embodiments, the second center node module 76 is specifically configured to determine the second center node in the displayed graph based on at least one of a node clicking operation, a hovering operation, and a search operation of the user. Based on the interactive operation of the user, the second center node of the graph that has been displayed can be determined, and the user action can be associated with the graph display. For example, the user searches for "Iron Man", and the node of Iron Man is determined as the second center node.
[0219] After the second center node is determined, the high light highlighting node can be switched from the first center node to the second center node, and the second graph is displayed with the second center node as the center. The nodes in the second graph are at different node levels relative to the second center node, and the display brightness and / or display transparency of the nodes are different. The second graph is different from the center node of the graph that has been displayed, that is, the emphasis of the display is different.
[0220] In some embodiments, in the second graph, the nodes of the predetermined node level associated with the second center node are displayed in the normal state, and the other nodes are displayed in the extinguished state. When the node is in the display range but is not the center node, it can be displayed in the normal state.
[0221] Specifically, the high light highlighting of the first center node in the displayed graph is canceled, the high light highlighting of the second center node is switched, and the second graph is displayed by moving to the center of the current display interface.
[0222] For example, Figure 4Another schematic diagram of the graph provided by the embodiment of the present disclosure, the graph in the figure can embody the center node, the association degree of other nodes with the center node, the node density and the node type; the user-selected node "Iron Man" in the figure is taken as a second center node and placed in the center of the screen for continuous highlight display, only the first-level nodes associated with the second center node are kept in the normal state, and the second-level nodes are all in the extinguished state, at this time, the extinguished state does not change due to user zooming; and the user can control whether the nodes at the level of 2 and above are in the extinguished state through the focus control, the focus control is turned on by default, if the user turns it off, the second center node is still highlighted, and the rest of the logic is the same as the display logic of the first center node. When switching from the first center node to the second center node, a switching effect can be added, after the user triggers the operation on the control, the displayed graph can be rotated and zoomed as a whole, the rotation direction can be determined by the relative position of the node and the center line, and the rotation direction can include clockwise or counterclockwise, and the second center node is placed in the center of the screen. Optionally, if the user selects a node that is originally invisible in the graph through the search operation and the node click operation, the node and the first-level nodes associated with the node can be displayed in the center of the screen after the effect is rotated by 180 degrees.
[0223] In the above embodiments, the graph can be displayed based on the center node, and the center node can be switched based on the user's selection, which can help the user focus on the center node, and help the user distinguish the nodes at different levels centered on the center node through visual effects such as node transparency, thereby improving the user experience.
[0224] Most of the current graph data visualization focuses on the user's operation on the graph itself. Of course, it is an important task for graph visualization to provide a series of auxiliary functions to help users focus, view, search and understand the content of the graph, but for platform-type graph products, in addition to querying the graph, users also have other work tasks such as checking correctness, configuring nodes, etc. At this time, focusing only on the graph itself is of limited help to users to complete other work. If the user's operation can be linked to the graph through flexible linkage, it will help users understand the current task and provide positive incentives.
[0225] Artificial checking is an indispensable link in constructing a knowledge graph. In some embodiments, the checking module 77 is specifically configured to: provide a graph construction interface, and the graph construction interface displays a to-be-confirmed question and a third graph corresponding to the to-be-confirmed question, wherein the to-be-confirmed question is associated with at least one node in the third graph, and the associated node is highlighted in the third graph.
[0226] The interface for constructing the knowledge graph is an interface for constructing a knowledge graph. Since the knowledge graph can be constructed by using the knowledge labeling method in the form of question and answer in the embodiment of the present disclosure, the question and answer form of the knowledge graph can be verified in combination with the display feedback of the graph.
[0227] In the embodiment of the present disclosure, the part to be verified can be converted into a to-be-verified question, displayed on the interface for constructing the graph, and the third graph corresponding to the to-be-verified question can also be displayed. The nodes associated with the to-be-verified question in the third graph can be highlighted.
[0228] In some embodiments, the third graph display module 78 specifically includes at least one of the following: a first display unit configured to highlight at least one node associated with the to-be-verified question in the third graph after obtaining a determination result of the to-be-verified question from the user; a second display unit configured to extinguish at least one node associated with the to-be-verified question in the third graph after obtaining a negative result of the to-be-verified question from the user; and a third display unit configured to maintain the normal state of at least one node associated with the to-be-verified question in the third graph after obtaining an uncertain result of the to-be-verified question from the user.
[0229] The user can answer the to-be-verified question displayed on the interface for constructing the graph. According to the answer result of the user, the nodes associated with the to-be-verified question can be displayed differently. When the user has a determination result for the to-be-verified question, the nodes associated with the to-be-verified question can be highlighted. When the user has a negative result for the to-be-verified question, the nodes associated with the to-be-verified question can be extinguished. When the user has an uncertain result for the to-be-verified question, the nodes associated with the to-be-verified question can be normally displayed.
[0230] For example, Figure 5 The interface schematic diagram of the interface for constructing the graph provided by the embodiment of the present disclosure is shown in the figure. A to-be-verified question "Is the movie Iron Man produced by the American Marvel movie studio?" and the graph corresponding to the to-be-verified question are exemplarily displayed. The graph display range in the lower right corner is the nodes of the first entity type, the nodes of the second entity type, and the event type nodes of the current to-be-verified question, and the first-level nodes thereof. The nodes are normally displayed. The second-level nodes and the nodes above the second-level nodes are extinguished. After the user clicks "Yes", the nodes corresponding to the to-be-verified question are highlighted. After the user clicks "No", the nodes corresponding to the to-be-verified question are extinguished. When the user clicks "Uncertain", the graph display effect does not change.
[0231] In the embodiments of the present disclosure, when the to-be-confirmed question is switched, the graph change is equivalent to switching different nodes as the center node in the same graph, and the specific effect can be that the to-be-confirmed question moves in from left to right, moves out from the right after answering, and at the same time, a new to-be-confirmed question moves in from the left. The action sequence can include: clicking the answer-graph highlighting feedback-to-be-confirmed question moving out / new to-be-confirmed question moving in-according to the graph, switching the center node to highlight the display of the new to-be-confirmed question.
[0232] In the above embodiments, the part to be checked can be converted into a question, and the question-related nodes can be displayed in the form of a center view in the page to assist the user in understanding the question and more intuitively seeing the connection between the nodes involved in the question. The user completes the check by answering the question, and the user's judgment result for the question will have different feedback in the graph. The real-time feedback on the graph can have a certain positive incentive effect. According to different user check tasks, a plurality of interaction mechanisms are provided to associate the user actions / tasks with the graph display, which can help the user understand the current task and provide positive incentives.
[0233] In some embodiments, the configuration graph module 79 is specifically configured to provide a configuration graph interface, and build a fourth graph displayed on the configuration graph interface, wherein the user configuration type control and the fourth graph corresponding to the user configuration type are displayed on the configuration graph interface, and in the fourth graph, the display size of the node is associated with the construction number of the node.
[0234] The user configuration type control is a control provided to the user to complete the configuration operation, and the control can be various, for example, can include at least one of a delete control, an edit control, an add control, a view source control, a hide relationship name control, and a batch operation control. Different controls have different functions. For example, when the user triggers the delete control, the corresponding node in the graph can be deleted; when the user triggers the add control, the corresponding node can be added to the graph.
[0235] In the embodiments of the present disclosure, the user configuration type control and the corresponding fourth graph can be displayed on the configuration graph interface, that is, the change of the graph can be displayed while the user is configuring. In the fourth graph, the display size of the node can be associated with the construction number in the construction information of the node. The more the construction number, the larger the display size of the node, which can assist the user to more intuitively understand the construction of the current graph. The construction number can also be divided into different construction number intervals according to the processing method of the node density described above, and different construction number intervals correspond to different display sizes.
[0236] It should be noted that in the embodiments of the present disclosure, the user configuration type can be understood as the node type that the user wants to include in the graph to be constructed, for example, the user wants to include nodes of the types of movie, leading actor, box office, production company, box office amount, etc. in the graph to be constructed, therefore, instances of these nodes need to be constructed, that is, the content of each node needs to be concretized through manual annotation, model extraction and other ways to construct the instance nodes in the graph, such as constructing the node of the type of movie into instance nodes such as Iron Man, Farewell My Concubine, Transformers, etc. The construction number is the number of instance nodes corresponding to the node of the type of movie. If the user initializes the graph, the nodes of these types have not been constructed into instances, then the nodes in the fourth graph can be of the same size, but if it is not an initial configuration graph, all or part of the nodes have been constructed into instance nodes, then the size can be used in the fourth graph to reflect the construction number, that is, the number of instance nodes. The different construction numbers and node sizes can help the user more intuitively understand the construction of the current graph.
[0237] Exemplarily, Figure 6 An exemplary interface schematic diagram of the fourth graph provided by the embodiments of the present disclosure is shown in the following figure. When constructing the graph, the user can add or delete nodes of the first entity type, nodes of the second entity type and nodes of the event type that need to be displayed in the graph on the left side. The user's adding, deleting and other operations are real-time drawn in the right graph area and displayed to the user, for example, after creating a node of the second entity type, a connection line between the two nodes is synchronously drawn in the graph. In addition, the number of constructed instances is associated with the node size. It is assumed that the number of instances constructed for "movie" is the largest, therefore, the size of the node of "movie" is the largest, and the number of instances constructed for "work" is the smallest, therefore, the size of the node of "work" is the smallest. In addition, to help the user understand the construction of the current graph, a "reflect instance number" switch is set. When the switch is off, the sizes of the nodes are consistent, and when the switch is on, the sizes of the nodes are related to the construction number.
[0238] In the above embodiments, the process of configuring the graph by the user can be combined with the feedback of the graph to help the user understand the change process of the graph and better configure the graph.
[0239] The embodiments of the present disclosure provide a computer device, which comprises:
[0240] The processor is used to realize the steps of the graph display method as described above when executing the computer program stored in the memory.
[0241] The processor can be a central processing unit (CPU) or other forms of processing units with data processing capability and / or instruction execution capability, and can control other components in the computer to perform desired functions.
[0242] The memory can include one or more computer program products that can include various forms of computer-readable storage media, such as volatile and / or non-volatile memory. The volatile memory, for example, can include random access memory (RAM) and / or cache memory and / or the like. The non-volatile memory, for example, can include read-only memory (ROM), hard disk, flash memory, and / or the like. The computer-readable storage media can store one or more computer program instructions implementing the method steps of the various embodiments of the present application described above and / or other desired function.
[0243] The embodiments of the present disclosure provide a computer-readable storage medium, which stores computer instructions, and the computer instructions are executed by a processor to implement the steps of the method shown in the above diagram.
[0244] In addition to the above method and device, the embodiments of the present application can also be a computer program product, which includes computer program instructions, and the computer program instructions make the processor execute the method steps of various embodiments of the present application when the processor runs.
[0245] The computer program product can be written in any combination of one or more programming languages to perform the operations of embodiments of the present application, including an object-oriented programming language, such as Java, C++, and / or the like, and / or a conventional procedural programming language, such as the "C" programming language or similar programming languages. The program code can be executed entirely on the user computing device, partially on the user device, as an independent software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server.
[0246] In addition, the embodiments of the present application can also be a computer-readable storage medium, which stores computer program instructions, and the computer program instructions make the processor execute the method steps of various embodiments of the present application when the processor runs.
[0247] The computer-readable storage medium can use any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium, for example, can include but is not limited to an electrical, a magnetic, an optical, an electromagnetic, an infrared, or a semiconductor system, device or apparatus, or any combination of the above. More specific examples (a non-exhaustive list) of the readable storage medium include an electrical connection having one or more wires, a portable disc, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0248] It has to be noted that, in the present document, relational terms are intended to encompass the various possible relationships between alternatives, such as those individuals or entities that have been in contact with one another as well as those individuals or entities that merely have information regarding each other — without ever having been in direct contact. In the claims, the term comprising does not exclude other elements being in the product, process, or apparatus, and does not exclude that one or more additional steps can be carried out in addition to those described or claimed. In the claims, the term comprising does not exclude other elements being in the product, process, or apparatus, and does not exclude that one or more additional steps can be carried out in addition to those described or claimed. Recitation of ranges of values herein are merely intended to serve as a shorthand method of referring individually to each separate value falling within the range. Unless otherwise indicated herein, each individual value is incorporated into the specification as if it were individually recited herein. All methods described herein can be performed in any suitable order unless otherwise indicated herein or otherwise clearly contradicted by context. The use of any and all examples, or exemplary language (e.g., "such as"), provided herein is intended merely to better illuminate the application and does not pose a
[0249] The foregoing is merely illustrative of the principles of this disclosure and various modifications can be made by those skilled in the art without departing from the spirit and scope of the disclosure. The disclosure is not intended to be limited to the embodiments described herein but is to be accorded the full scope of the claims, wherein reference to an element in the singular is not intended to mean "one and only one" unless specifically so stated, but rather "one or more." Unless otherwise indicated, the words comprising, including, containing or consisting of are to be construed as meaning "including, but not limited to."
Claims
1. A method of presenting a map, characterized by, The method comprises: obtaining attribute information of a node in a to-be-displayed graph, the attribute information comprising a relationship density of the node, the relationship density being used to indicate a number of relationships and / or events in which the node is involved, the relationship density of the node being a sum of a total number of times that the node is involved as a preceding node, a succeeding node and in an event, the to-be-displayed graph comprising entity nodes, event nodes and relationship edges, the event nodes comprising one or more entity nodes and a predefined event name node, the one or more entity nodes and the predefined event name being connected by a specific relationship word to form a set of associated information to describe an event, the event node indicating a dynamic behavior of the entity node; obtaining a display size of the node based on the relationship density of the node; displaying the graph based on the display size of the node, so that, in the displayed graph, the relationship density of a node with a large display size is greater than the relationship density of a node with a small display size. providing a graph construction interface, displaying a to-be-confirmed question and a third graph corresponding to the to-be-confirmed question on the graph construction interface, the to-be-confirmed question being used for knowledge labeling in a question and answer form, wherein the to-be-confirmed question is associated with at least one node in the third graph, and the associated node is highlighted in the third graph; in response to user feedback on the to-be-confirmed question, adjusting the display effect of the associated node; wherein the to-be-confirmed question and the third graph are used for checking and verifying the displayed graph.
2. The method of claim 1, wherein, The method comprises: dividing the relationship densities of all nodes into at least two density intervals, each density interval being provided with a corresponding display size; determining the display size of the node according to the density interval in which the relationship density of the node is located.
3. The method of claim 2, wherein, The method comprises: obtaining a maximum density value, a minimum density value and a median density value based on the relationship densities of all nodes; determining at least two density intervals based on the maximum density value and the median density value, and / or determining at least two density intervals based on the median density value and the minimum density value.
4. The method of claim 1, wherein, The attribute information further comprises a node type, and the method further comprises: obtaining a display color and / or a display shape of the node based on the node type of the node, The method comprises: displaying the graph based on the display size, the display color and / or the display shape of the node, so that, in the displayed graph, nodes of different node types have different display colors and / or display shapes.
5. The method of claim 4, wherein, The node type comprises at least one of a first entity type, a second entity type and an event type.
6. The method according to any one of claims 1 to 5, characterized in that, Before displaying the graph, the method further comprises: determining a first center node in the to-be-displayed graph that satisfies a first preset condition; and when the graph is displayed, the first center node is highlighted.
7. The method of claim 6, wherein, The first center node satisfying the first preset condition includes a predetermined number of nodes with the highest relationship density.
8. The method of claim 6, wherein, Before displaying the graph, the method further includes: determining the node level of the node relative to the first center node; When displaying the graph, the node level of the node relative to the first center node is different, and the display brightness and / or display transparency of the node are different, wherein the display brightness of the node gradually decreases as the node level increases, or the display transparency of the node gradually decreases as the node level increases.
9. The method of claim 8, wherein, The determination of the node level of the node relative to the first center node includes: determining the node level of other nodes based on the distance value of other nodes in the graph to be displayed and the first center node.
10. The method of claim 8, wherein, The displayed graph only displays a predetermined number of node levels, and / or the largest node level in the displayed graph is displayed in an extinguished state.
11. The method according to any one of claims 1 to 5, characterized in that, After displaying the graph, the method further includes: determining a second center node in the displayed graph based on a user's triggering operation; switching the displayed graph to a second graph that highlights the second center node.
12. The method of claim 11, wherein, The determination of the second center node in the displayed graph based on the user's triggering operation includes: determining the second center node in the displayed graph based on at least one of the user's node clicking operation, hovering operation, and searching operation.
13. The method of claim 11, wherein, In the second graph, the nodes of the predetermined node level associated with the second center node are displayed in a normal state, and other nodes are displayed in an extinguished state.
14. The method of claim 1, wherein, After providing the graph construction interface, the method further includes at least one of: after obtaining the user's determination result for the to-be-confirmed question, highlighting at least one node associated with the to-be-confirmed question in the third graph; after obtaining the user's negative result for the to-be-confirmed question, displaying at least one node associated with the to-be-confirmed question in the third graph in an extinguished state; after obtaining the user's uncertain result for the to-be-confirmed question, maintaining the normal state display of at least one node associated with the to-be-confirmed question in the third graph.
15. The method of claim 1, wherein, The method further includes: providing a configuration graph interface, the configuration graph interface displaying a user configuration type control and a fourth graph corresponding to the user configuration type, and in the fourth graph, the display size of the node is associated with the construction times of the node.
16. An apparatus for displaying a map, characterized by The device includes: The attribute information acquisition module is configured to acquire attribute information of a node in a to-be-displayed graph, the attribute information including a relationship density of the node, the relationship density being used to indicate a number of relationships and / or events in which the node is involved, the relationship density of the node being a sum of a total number of times that the node is used as a preceding node, a succeeding node, and an event node, the to-be-displayed graph including entity nodes, event nodes, and relationship edges, the event node including one or more entity nodes and a predefined event name node, the one or more entity nodes and the predefined event name being connected by a specific relationship word to form a set of associated information to describe an event, the event node indicating a dynamic behavior of the entity node; The display size acquisition module is configured to acquire a display size of the node based on the relationship density of the node. The graph display module is configured to display the graph based on the display size of the node, so that, in the displayed graph, the relationship density of a node with a large display size is greater than the relationship density of a node with a small display size. The checking module is configured to provide a graph construction interface, display a to-be-confirmed question and a third graph corresponding to the to-be-confirmed question on the graph construction interface, and use a question and answer form to perform knowledge labeling on the to-be-confirmed question, wherein the to-be-confirmed question is associated with at least one node in the third graph, and the associated node is highlighted in the third graph; and the to-be-confirmed question and the third graph are used to check the displayed graph. The third graph display module is configured to adjust a display effect of the associated node in response to user feedback on the to-be-confirmed question.
17. The apparatus of claim 16, wherein, The display size acquisition module includes: The density interval division unit is configured to divide the relationship densities of all nodes into at least two density intervals, and each density interval is provided with a corresponding display size. The size determination unit is configured to determine the display size of the node according to the density interval in which the relationship density of the node is located.
18. The apparatus of claim 17, wherein, The density interval division unit is specifically configured to: acquire a maximum density value, a minimum density value, and a median density value based on the relationship densities of all nodes; determine at least two density intervals based on the maximum density value and the median density value, and / or determine at least two density intervals based on the median density value and the minimum density value.
19. The apparatus of claim 16, wherein, The attribute information further includes a node type, and the device further includes a display parameter module, which is specifically configured to: acquire a display color and / or a display shape of the node based on the node type of the node, The graph display module is specifically configured to: display the graph based on the display size, the display color, and / or the display shape of the node, so that different node types of nodes in the displayed graph have different display colors and / or display shapes.
20. The apparatus of claim 19, wherein, The node type includes at least one of a first entity type, a second entity type, and an event type.
21. The apparatus of any of claims 16-20, wherein, The device further includes a first center node module, which is specifically configured to determine a first center node that meets a first preset condition in the to-be-displayed graph before displaying the graph. Then, the first center node is highlighted when the graph is displayed.
22. The apparatus of claim 21, wherein, The first center node satisfying the first preset condition comprises a predetermined number of nodes with the highest relationship density.
23. The apparatus of claim 21, wherein, The device further comprises a node level module, specifically configured to: determine the node level of the node relative to the first center node before displaying the graph, Then, the node level of the node relative to the first center node is different when the graph is displayed, and the display brightness and / or display transparency of the node are different, wherein the display brightness of the node gradually decreases as the node level increases, or the display transparency of the node gradually decreases as the node level increases.
24. The device of claim 23, wherein, The node level module is specifically configured to: determine the node level of other nodes based on the distance value of other nodes in the graph to be displayed and the first center node.
25. The apparatus of claim 23, wherein, Only a predetermined number of node levels are displayed in the displayed graph, and / or the largest node level in the displayed graph is displayed in an extinguished state.
26. The apparatus of any one of claims 16-20, wherein, The device further comprises a second center node module, specifically configured to: determine a second center node in the displayed graph based on a triggering operation of the user after displaying the graph, switch the displayed graph to a second graph highlighting the second center node.
27. The apparatus according to claim 26, characterized in that, The second center node module is specifically configured to: determine the second center node in the displayed graph based on at least one of the node click operation, the hovering operation, and the search operation of the user.
28. The device of claim 26, wherein, In the second graph, the nodes of the predetermined node level associated with the second center node are displayed in a normal state, and other nodes are displayed in an extinguished state.
29. The apparatus of claim 16, wherein, The device further comprises a third graph display module, specifically comprising at least one of the following: a first display unit for highlighting at least one node associated with the to-be-confirmed question in the third graph after obtaining the determination result of the user for the to-be-confirmed question; a second display unit for displaying at least one node associated with the to-be-confirmed question in an extinguished state in the third graph after obtaining the negative result of the user for the to-be-confirmed question; a third display unit for maintaining the normal state display of at least one node associated with the to-be-confirmed question in the third graph after obtaining the uncertain result of the user for the to-be-confirmed question.
30. The apparatus of claim 16, wherein, The device further comprises a configuration graph module, specifically configured to: provide a configuration graph interface, and the configuration graph interface displays a user configuration type control and a fourth graph corresponding to the user configuration type, wherein the display size of the node in the fourth graph is associated with the construction times of the node.
31. A computer apparatus, comprising: The computer device comprises: a processor for implementing the steps of the method according to any one of claims 1-15 when executing the computer program stored in the memory.
32. A computer readable storage medium having stored thereon computer instructions, wherein, The computer instructions are executed by the processor to implement the steps of the method according to any one of claims 1-15.
Citation Information
Patent Citations
Associated data visualization display method
CN105488130A
Knowledge graph display method and device, computer equipment and storage medium
CN109657067A
Knowledge graph display method and device, mobile terminal and readable storage medium
CN110019766A
Access behavior processing method and device
CN110969472A