Memgraph Advanced Graph Extensions, MAGE to friends, is an open-source repository that contains graph algorithms and modules written by the team behind Memgraph and its users in the form of query modules. The project aims to give everyone the tools they need to tackle the most interesting and challenging graph analytics problems.
Query module is a concept introduced by Memgraph and it refers to user-defined procedures, grouped into modules that extend the Cypher query language. Procedures are implementations of various algorithms in multiple programming languages and they are all runnable inside Memgraph.
Start utilizing the power of MAGE with these simple steps.
1. Install MAGE
Install MAGE using a prepared image from the Docker Hub or by building a Docker image from the official MAGE GitHub repository. On Linux, you can also install MAGE from source but be aware you will also need to install additional dependencies.
2. Load query modules
To use certain procedures, first, you need to load the query modules to the appropriate directory.
3. Call procedures
You are ready to call procedures within queries and tackle that graph analytics problem that's been keeping you awake.
What to do next?
Browse the spellbook of query modules
The spellbook has been written to help you utilize all the currently available query modules.
|betweenness_centrality||C++||The betweenness centrality of a node is defined as the sum of the of all-pairs shortest paths that pass through the node divided by the number of all-pairs shortest paths in the graph. The algorithm has O(nm) time complexity.|
|biconnected_components||C++||Algorithm for calculating maximal biconnected subgraph. A biconnected subgraph is a subgraph with a property that if any vertex were to be removed, the graph will remain connected.|
|bipartite_matching||C++||Algorithm for calculating maximum bipartite matching, where matching is a set of nodes chosen in such a way that no two edges share an endpoint.|
|bridges||C++||A bridge is an edge, which when deleted, increases the number of connected components. The goal of this algorithm is to detect edges that are bridges in a graph.|
|community_detection_online||C++||A dynamic community detection algorithm suitable for large-scale graphs based upon label propagation. Runs in O(m) time and has O(mn) space complexity.|
|cycles||C++||Algorithm for detecting cycles on graphs|
|distance_calculator||Python||Module for finding the geographical distance between two points defined with 'lng' and 'lat' coordinates.|
|graph_analyzer||Python||This Graph Analyzer query module offers insights about the stored graph or a subgraph.|
|graph_coloring||Python||Algorithm for assigning labels to the graph elements subject to certain constraints. In this form, it is a way of coloring the graph vertices such that no two adjacent vertices are of the same color.|
|json_util||Python||A module for loading JSON from a local file or remote address.|
|node2vec||Python||An algorithm for calculating node embeddings on static graph.|
|node2vec_online||Python||An algorithm for calculating node embeddings as new edges arrive|
|node_similarity||Python||A module that contains similarity measures for calculating the similarity between two nodes.|
|nxalg||Python||A module that provides NetworkX integration with Memgraph and implements many NetworkX algorithms|
|pagerank||C++||Algorithm that yields the influence measurement based on the recursive information about the connected nodes influence|
|pagerank_online||C++||A dynamic algorithm made for calculating PageRank in a graph streaming scenario.|
|rust_example||Rust||Example of a basic module with input parameters forwarding, made in Rust.|
|set_cover||Python||The algorithm for finding minimum cost subcollection of sets that covers all elements of a universe.|
|tsp||Python||An algorithm for finding the shortest possible route that visits each vertex exactly once.|
|union_find||Python||A module with an algorithm that enables the user to check whether the given nodes belong to the same connected component.|
|uuid_generator||C++||A module that generates a new universally unique identifier (UUID).|
|vrp||Python||Algorithm for finding the shortest route possible between the central depot and places to be visited. The algorithm can be solved with multiple vehicles that represent a visiting fleet.|
|weakly_connected_components||C++||A module that finds weakly connected components in a graph.|
Create query modules
If you need some assistance in creating and running your own Python and C++ query modules How-to guides are here for you.
Learn about algorithms and their usage
Make MAGE even better by contributing your own algorithm implementations and ideas or reporting pesky bugs.
Browse through the Changelog
Want to know what's new in MAGE? Take a look at Changelog to see a list of new features.