Recipes

Visual Graph provides recipes to build graph databases, query them, compute graph algorithms, and prepare graph-related datasets.

Deprecated Compute PageRank recipe

The standalone Compute PageRank recipe is deprecated and kept for compatibility. For new flows, use the Graph features recipe and select the PageRank algorithm.

Graph database recipe settings

Recipes that run on a graph database can work with a graph database published by Visual Graph to a Dataiku Folder.

For Neo4j, these recipes can also target an unmanaged database directly by leaving the graph folder empty and selecting Neo4j (unmanaged), the Neo4j connection, and the database name in the recipe settings.

Common graph database settings are:

Graph folder

Optional Dataiku Folder that contains your materialized graph database. Leave it empty to run on an unmanaged Neo4j database directly.

Database type

If you provided a graph database folder, the database type is detected from that folder. Otherwise, select Neo4j (unmanaged).

Neo4j connection

If you selected a Neo4j database type, select the Neo4j connection to use.

Database name

If you are running on an unmanaged Neo4j database directly, select the database name to use.

Algorithm execution and sampling

Some Visual Graph recipes let you choose where the algorithm runs:

  • In database runs the algorithm directly in the graph database, when the selected backend supports the requested algorithm. On Neo4j, it requires a writable connection, because the recipe builds a temporary projection in the database. It also requires the Graph Data Science (GDS) library.

  • Dataiku execution loads the selected graph into Dataiku backend memory and runs the algorithm there. It supports every algorithm.

The following table summarizes execution support.

Recipe

Dataiku execution

In database, Neo4j

In database, built-in graph database

Graph features

All graph features

Degree, Eigenvector centrality, Closeness centrality, PageRank, Connected components

PageRank, Connected components

Graph clustering

All clustering algorithms

Not supported

Not supported

Compute PageRank (deprecated)

PageRank

PageRank

PageRank

The Graph features recipe runs In database or in Dataiku execution. The Graph clustering recipe runs in Dataiku execution only. The deprecated standalone Compute PageRank recipe runs In database or in Dataiku execution.

Note

Unsupported execution engine, algorithm, and sampling combinations are rejected before the algorithm starts. If a selected backend or algorithm does not support a requested mode, the job fails with an explicit error listing the unsupported algorithms, instead of silently switching to another mode.

When sampling is disabled, the recipe runs on the full selected graph. When sampling is enabled, the recipe runs on a subgraph. Sampling is useful for exploration on large graphs, but the resulting values are then computed on the subgraph, not on the full graph.

Two sampling modes are available:

  • Top N nodes/edges loads a bounded number of nodes per selected node group and relationships per selected edge group. It is available both In database and in Dataiku execution.

  • Cypher Query runs the algorithm on the subgraph returned by a Cypher query. The query returns the nodes, relationships, or paths to include. The query is used as written; add a LIMIT clause only if you want to cap its size.

Sampling support depends on the recipe and execution engine:

Recipe

Dataiku execution

In database

Graph features

Top N nodes/edges, Cypher Query

Top N nodes/edges, Cypher Query

Graph clustering

Top N nodes/edges, Cypher Query

Not supported

Compute PageRank (deprecated)

Top N nodes/edges, Cypher Query

Top N nodes/edges

Common execution settings are:

Execution engine

Choose where the algorithm runs: In database or Dataiku execution.

Enable sampling

Enable this option to compute on a subgraph instead of the full selected graph.

Sampling mode

Choose Top N nodes/edges or Cypher Query.

Sample limit per group

For Top N nodes/edges, the maximum number of nodes loaded per selected node group and relationships loaded per selected edge group.

Cypher Query

For Cypher Query, the Cypher query returning the nodes, relationships, or paths that define the subgraph to analyze.