IP Library Granted Patent US 11,720,631
Granted Patent B2
US 11,720,631 · App. 17/236,842 · Granted Aug 8, 2023

Tool to build and store a data model and queries for a graph database

Inventors: Daniel Eric Monk (Frederick, MD); Navneet Mathur (Mountain View, CA)
Assignee: Neo4j Sweden AB
G06F16/9024G06F16/2358G06F16/245G06F16/288G06F21/6218G06F3/04847
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,720,631
App. No.
17/236,842
Granted
Aug 8, 2023
Kind
B2
Abstract

A system is disclosed to build and store a data model and queries for a graph database. In various embodiments, data defining one or more aspects of a data model associated with a graph database is received. A set of data that represents the data model is stored as a graph that includes one or more nodes to represent each of the following: data model metadata, one or more node labels comprising the graph database, one or more relationship types of the graph database, and one or more property definitions each associated with a property of at least one of a node label and a relationship type of the graph database.

Claims (59)

1. A system, comprising:

a memory or other data storage device; and

a processor coupled to the memory or other data storage device and configured to:

receive data defining one or more aspects of a data model associated with a graph database;

store as a graph a set of data that represents the data model, the graph including one or more nodes to represent each of the following: data model metadata, one or more node labels comprising the graph database, one or more relationship types of the graph database, and one or more property definitions each associated with a property of at least one of a node label and a relationship type of the graph database, wherein the graph is stored as a subgraph of a global graph, the global graph including a plurality of subgraphs, each subgraph representing a corresponding data model of a graph database associated with that data model and each subgraph has associated therewith a universally unique identifier (UUID) of the data model with which the subgraph is associated;

receive a request associated with the data model and allow access to the data model based at least in part on a determination that a user with which the request is associated is authorized to access the data model;

receive a request to write to the set of data that represents the data model and to add the UUID to an entity name included in the request;

receive a request to read data comprising the set of data that represents the data model;

retrieve response data from the set of data, the response data including an identification of one or more entities comprising the graph, the identification including the UUID; and

remove the UUID from the response data prior to sending at least a subset of the response data in response to the request.

2. The system of claim 1 , wherein the property definition defines a data type.

3. The system of claim 1 , wherein the graph comprises a subgraph of a global graph, the subgraph including data usable to retrieve the entire subgraph in a single query.

4. The system of claim 3 , wherein the subgraph comprises an instance of a graph document and the global graph includes a plurality of graph documents, each having a subgraph root node that includes data usable to retrieve the associated subgraph in a single query.

5. The system of claim 1 , wherein the processor is configured to determine at least a portion of the data model by reverse engineering a query statement associated with the graph database.

6. The system of claim 1 , wherein the processor is configured to use the data model to provide a visual tool to define a pattern associated with the graph database.

7. The system of claim 6 , wherein the processor is configured to use the data model at least in part by extract from the data model a plurality of node labels and including in a graphical user interface of the visual tool a set of selectable buttons, each associated with a corresponding node label, and wherein the processor is further configured to generate and include in one or both of a visual representation of the pattern and a query statement expression of the pattern, in response to user selection of one of the selectable buttons, a node pattern corresponding to a node label associated with the selected button.

8. The system of claim 7 , wherein the processor is further configured to include in one or both of the visual representation of the pattern and the query statement expression of the pattern a relationship between a first node associated with the node label associated with the selected button and a second node associated with a second node label added previously to the pattern.

9. The system of claim 8 , wherein the processor is further configured to store as a pattern graph data representing the pattern defined via the visual tool.

10. The system of claim 1 , wherein the processor is configured to validate a query statement associated with the graph database at least in part by using the data model to determine as a set of valid node labels for the graph database, comparing the determined set of valid node labels to a corresponding set of node labels extracted from the query statement, and returning a result indicating which, if any, of the node labels extracted from the query statement is or are invalid.

11. A system comprising:

a memory or other data storage device; and

a processor coupled to the memory or other data storage device and configured to:

receive data defining one or more aspects of a data model associated with a graph database;

store as a graph a set of data that represents the data model, the graph including one or more nodes to represent each of the following: data model metadata, one or more node labels comprising the graph database, one or more relationship types of the graph database, and one or more property definitions each associated with a property of at least one of a node label and a relationship type of the graph database;

store change tracking data to track changes made at a client system to data comprising the graph, including by tracking which nodes of the graph are affected by changes made at the client system;

determine to auto-save changes; and

use the change tracking data to save to the graph as stored in a graph database, including by using the change tracking data to identify a subset of entities comprising the graph to be updated.

12. The system of claim 11 , wherein the change tracking data includes for each of a plurality of entities comprising the graph a changed flag and wherein the processor is configured to set the changed flag to a value indicating the corresponding entity has been changed.

13. The system of claim 12 , wherein the change tracking data includes a timestamp indicating a time associated with a change to the corresponding entity.

14. The system of claim 13 , wherein the processor is configured to save the changes to the graph by creating and sending to a remote graph database application server a JSON or other package that includes change data for each entity determined to have been changed.

15. The system of claim 14 , wherein data models may be built collaboratively over the internet.

16. The system of claim 14 , wherein data models are firewalled to members of a particular organization.

17. A method, comprising:

receiving data defining one or more aspects of a data model associated with a graph database;

storing as a graph a set of data that represents the data model, the graph including one or more nodes to represent each of the following: data model metadata, one or more node labels comprising the graph database, one or more relationship types of the graph database, and one or more property definitions each associated with a property of at least one of a node label and a relationship type of the graph database, wherein the graph is stored as a subgraph of a global graph, the global graph including a plurality of subgraphs, each subgraph representing a corresponding data model of a graph database associated with that data model and each subgraph has associated therewith a universally unique identifier (UUID) of the data model with which the subgraph is associated;

receiving a request associated with the data model and allow access to the data model based at least in part on a determination that a user with which the request is associated is authorized to access the data model;

receiving a request to write to the set of data that represents the data model and to add the UUID to an entity name included in the request receiving a request to read data comprising the set of data that represents the data model;

retrieving response data from the set of data, the response data including an identification of one or more entities comprising the graph, the identification including the UUID; and

removing the UUID from the response data prior to sending at least a subset of the response data in response to the request.

18. A non-transitory computer readable medium including a computer program product, the computer program product comprising computer instructions for:

receiving data defining one or more aspects of a data model associated with a graph database;

storing as a graph a set of data that represents the data model, the graph including one or more nodes to represent each of the following: data model metadata, one or more node labels comprising the graph database, one or more relationship types of the graph database, and one or more property definitions each associated with a property of at least one of a node label and a relationship type of the graph database, wherein the graph is stored as a subgraph of a global graph, the global graph including a plurality of subgraphs, each subgraph representing a corresponding data model of a graph database associated with that data model and each subgraph has associated therewith a universally unique identifier (UUID) of the data model with which the subgraph is associated;

receiving a request associated with the data model and allow access to the data model based at least in part on a determination that a user with which the request is associated is authorized to access the data model;

receiving a request to write to the set of data that represents the data model and to add the UUID to an entity name included in the request;

receiving a request to read data comprising the set of data that represents the data model;

retrieving response data from the set of data, the response data including an identification of one or more entities comprising the graph, the identification including the UUID; and

removing the UUID from the response data prior to sending at least a subset of the response data in response to the request.

19. A method, comprising:

receiving data defining one or more aspects of a data model associated with a graph database;

storing as a graph a set of data that represents the data model, the graph including one or more nodes to represent each of the following: data model metadata, one or more node labels comprising the graph database, one or more relationship types of the graph database, and one or more property definitions each associated with a property of at least one of a node label and a relationship type of the graph database;

storing change tracking data to track changes made at a client system to data comprising the graph, including by tracking which nodes of the graph are affected by changes made at the client system;

determining to auto-save changes; and

using the change tracking data to save to the graph as stored in a graph database, including by using the change tracking data to identify a subset of entities comprising the graph to be updated.

20. A non-transitory computer readable medium including a computer program product, the computer program product comprising computer instructions for:

receiving data defining one or more aspects of a data model associated with a graph database;

storing as a graph a set of data that represents the data model, the graph including one or more nodes to represent each of the following: data model metadata, one or more node labels comprising the graph database, one or more relationship types of the graph database, and one or more property definitions each associated with a property of at least one of a node label and a relationship type of the graph database;

storing change tracking data to track changes made at a client system to data comprising the graph, including by tracking which nodes of the graph are affected by changes made at the client system;

determining to auto-save changes; and

using the change tracking data to save to the graph as stored in a graph database, including by using the change tracking data to identify a subset of entities comprising the graph to be updated.

Assignments (2)
SECURITY INTEREST Recorded Mar 31, 2026
From: NEO4J, INC.; NEO4J SWEDEN AB
To: HERCULES CAPITAL, INC., AS AGENT
Reel/Frame 074237/0314 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jul 1, 2021
From: MONK, DANIEL ERIC; MATHUR, NAVNEET
To: NEO4J SWEDEN AB
Reel/Frame 056735/0098 →
Continuity (1)
Related Publication 20220342932A1 · Oct 27, 2022