Skip to main content

cuGraph SQL API

DataFusion Nexus exposes NVIDIA RAPIDS cuGraph algorithms as SQL table functions over DataFusion SQL sessions, whether the session is embedded in a Rust process or served remotely through Flight SQL. Each cugraph_* function reads an edge relation, builds a GPU graph, runs an algorithm, and returns rows you can compose with ordinary SQL.

This section helps you choose a graph function, provide its edge relation, and understand its execution and reuse boundaries.

Graph input and call shape

Every algorithm follows one positional shape:

cugraph_<algorithm>(table_name [, src_col, dst_col [, weight_col [, options_json]]])
  • table_name — an edge relation (a registered table or view of edges).
  • src_col / dst_col — endpoint columns; default to src / dst.
  • weight_col — optional edge weight column. Whether it affects results depends on the function's Weight column entry in the cheat sheet below.
  • options_json — a JSON string of algorithm and graph options.

A few functions take extra positional arguments (for example, cugraph_bfs takes a source vertex); see each function's page for its exact signature.

The relation name must resolve to a table or view registered in the session. That relation can be backed by the session's configured sources, including Parquet and Iceberg. See Integrating Nexus for source and session setup, and Graph Inputs and Construction for vertex-ID contracts, directedness, vertex renumbering, and edge normalization.

Functions

Start with Browse functions to choose an algorithm by family or compare the generated catalog descriptors.

Discovery and validation

Use Discover & Validate GPU Functions for the shared list, describe, validate, and execute workflow. The exact metadata response and validation-request schemas are in the GPU Function Catalog API.

Reuse in bounded servers

A bounded Flight SQL server can retain constructed graphs for repeat calls with a strongly identified, eligible input. The current reusable path covers BFS without include_edges, PageRank, Jaccard, Sorensen, Overlap, and Cosine; other calls bypass the cache. Configure and observe it through Cache Design.

Next steps