All Products
Search
Document Center

Artificial Intelligence Recommendation:Grant permissions on offline storage to AIRec

Last Updated:Apr 01, 2026

Before Artificial Intelligence Recommendation (AIRec) can read from or write to your MaxCompute project, you must grant the ALIYUN$openias service account the required permissions on your MaxCompute project and tables.

When you need to grant permissions

Grant permissions before either of the following tasks:

TaskPermissions required
Starting an AIRec instance with historical data (configuring data sources)Read
Starting an AIRec instance with historical data (configuring offline data sources)Read and write
Customizing recall links and sorting models (configuring feature, behavior, or sample data)Read

For details on starting an instance with historical data, see Use historical data to start an instance.

Required permissions

The following table lists the permissions required on your MaxCompute project and tables.

ObjectActionDescriptionRequired for
ProjectReadView project information, such as creation time. Does not include objects within the project.Read and write
ProjectListQuery all object types in a project.Read and write
ProjectCreateInstanceCreate an instance in a project.Write only
ProjectCreateTableCreate a table in a project.Write only
TableDescribeRead table metadata.Read and write
TableSelectRead data from a table.Read and write
TableAlterModify table metadata, or create and delete partitions.Write only
TableUpdateOverwrite or insert data in a table.Write only

For more information, see MaxCompute permissions.

Grant permissions on MaxCompute to AIRec

Choose one of the following methods to run the authorization statements.

Note: If your DataWorks workspace is in standard mode, it is associated with both a development environment project and a production environment project. To grant permissions on the production environment project, add the following statement before the authorization statements and run them together:
use [project]; -- Specify the production environment project name.

Grant permissions by using the MaxCompute console

  1. Open an ODPS SQL window in the MaxCompute console.

  2. Add the ALIYUN$openias service account:

    -- Add the openias account.
    add user `ALIYUN$openias`;
    -- Verify that the account was added.
    list users;
  3. Grant read permissions:

    -- Replace [project] with your MaxCompute project name.
    -- Replace [table] with your table name.
    grant Read ON PROJECT [project] to user `ALIYUN$openias`;
    grant List ON PROJECT [project] to user `ALIYUN$openias`;
    grant Describe ON TABLE [table] to user `ALIYUN$openias`;
    grant Select ON TABLE [table] to user `ALIYUN$openias`;
  4. If you are configuring offline data sources, grant write permissions as well:

    -- Replace [project] with your MaxCompute project name.
    grant Read ON PROJECT [project] to user `ALIYUN$openias`;
    grant List ON PROJECT [project] to user `ALIYUN$openias`;
    grant CreateTable ON PROJECT [project] to user `ALIYUN$openias`;
    grant CreateInstance ON PROJECT [project] to user `ALIYUN$openias`;

Grant permissions by using the MaxCompute client

  1. Download and configure the MaxCompute client.

  2. Run the following command to access the MaxCompute environment:

    ./bin/odpscmd
  3. Add the ALIYUN$openias service account:

    -- Add the openias account.
    add user `ALIYUN$openias`;
    -- Verify that the account was added.
    list users;
  4. Grant read permissions:

    -- Replace [project] with your MaxCompute project name.
    -- Replace [table] with your table name.
    grant Read ON PROJECT [project] to user `ALIYUN$openias`;
    grant List ON PROJECT [project] to user `ALIYUN$openias`;
    grant Describe ON TABLE [table] to user `ALIYUN$openias`;
    grant Select ON TABLE [table] to user `ALIYUN$openias`;
  5. If you are configuring offline data sources, grant write permissions as well:

    -- Replace [project] with your MaxCompute project name.
    grant Read ON PROJECT [project] to user `ALIYUN$openias`;
    grant List ON PROJECT [project] to user `ALIYUN$openias`;
    grant CreateTable ON PROJECT [project] to user `ALIYUN$openias`;
    grant CreateInstance ON PROJECT [project] to user `ALIYUN$openias`;

What's next