RelationalAI CLI Reference#

The RelationalAI Command Line Interface (CLI) is used to initialize RelationalAI projects and manage project resources.

Installation#

The CLI is bundled with the RelationalAI Python Package and can be installed using pip or your favorite package manager:

#pip install relationalai

See Install the relationalai Python Package for details.

Basic Usage#

The CLI is invoked using the rai command. Execute rai without any arguments to see a list of all available commands:

#rai
IMPORTANT

If you encounter the error command not found: rai, you may need to activate your project’s virtual environment.

To execute a command, type rai, followed by the command name and any arguments you want to pass. For example, the following creates a new RelationalAI engine named my-engine of size S:

#rai engines:create --name my-engine --size S

To view help for a command, use the --help flag:

#rai engines:create --help

Commands#

Configuration and Profiles#

All RelationalAI projects require a configuration file, created using rai init, that specifies the project’s settings, platform credentials, and other configuration options.

Use the following commands to manage your project’s configuration and profiles:

Engines#

Engines are the compute resources used to run queries and models. Use the following commands to manage engines:

Imports#

Imports are objects imported into RAI, such as data from a Snowflake table, for use in models and queries. Use the following commands to manage imports:

Exports#

Exports are objects that are exported out of RAI for use in other systems, such as exporting query results into a Snowflake table. Use the following commands to manage exports:

NOTE

This feature is currently disabled but will be available soon!

Transactions#

Transactions are operations that modify the state of a RelationalAI model. They are created when you import data and when you run queries. Use the following commands to manage transactions: