DESCRIBE MODEL MONITOR¶
Displays information about a specific model monitor. This command displays all the information shown by the SHOW MODEL MONITORS command, plus additional information.
DESCRIBE 可以缩写为 DESC。
语法
参数
monitor_name指定要描述的模型监控器的标识符。
If the identifier contains spaces or special characters, the entire string must be enclosed in double quotes. Identifiers enclosed in double quotes are also case-sensitive.
For more information, see Identifier requirements.
输出
命令输出在以下列中提供模型监控器属性和元数据:
| Column | Description |
|---|---|
created_on | Date and time when the model monitor was created. |
name | Name of the model monitor. |
database_name | Database in which the model monitor is stored. |
schema_name | Schema in which the model monitor is stored. |
warehouse_name | Warehouse used to monitor the model. |
refresh_interval | The refresh interval (target lag) for triggering refresh of the model monitor. |
aggregation_window | The aggregation window for calculating metrics. |
model_task | The task of the model being monitored, either TABULAR_BINARY_CLASSIFICATION or TABULAR_REGRESSION. |
monitor_state | 模型监控器的状态:
|
source | String representation of a JSON object detailing the source table or view on which aggregations are based. If the table does not exist or is not accessible, the value is an empty string. See Table JSON object specification. |
baseline | String representation of a JSON object detailing baseline table being used for monitoring, of which a clone is embedded in the model monitor object. See Table JSON object specification. |
model | String representation of a JSON object containing information specifically about the model being monitored. See Model JSON object specification. |
comment | Comment about the model monitor. |
| *The following columns are the additional columns displayed by DESCRIBE compared to SHOW* | |
aggregation_status | JSON object containing aggregation status for each dynamic table type. Keys:
Values: |
aggregation_last_error | JSON object containing the last error for each dynamic table type. Keys: Same as Values: Error message, or empty string if successful |
aggregation_last_data_timestamp | JSON object containing the last update timestamp for each dynamic table type. Keys: Same as Values: Timestamp of last successful update |
columns | A string representation of a JSON object that contains names of columns being used in the source table. See Column JSON object specification. |
表 JSON 对象规范¶
The following is the format of the JSON representation of a table, as used by the source and baseline columns in the command output:
name | Name of the source or baseline table or view. |
|---|---|
database_name | Database in which the table or view is stored. |
schema_name | Schema in which the table or view is stored. |
status | 表的状态:
|
模型 JSON 对象规范¶
The following is the format of the JSON representation of a model, as used by the model column in the command output:
| 字段 | 描述 |
|---|---|
model_name | 被监控的模型的名称。 |
version_name | 被监控的模型版本的版本名称。 |
function_name | 指定模型版本中被监控的特定函数的名称。 |
database_name | 存储模型的数据库。 |
schema_name | 存储模型的架构。 |
model_status | 模型的状态。可以是 ACTIVE、MASKED 或 DELETED。MASKED 表示用户无权访问模型;其他字段显示为一系列星号。 |
version_status | 模型版本的状态。可以是 ACTIVE 或 DELETED。(MASKED 不是模型版本的有效状态,因为它们没有访问控制。) |
列 JSON 对象规范¶
The following is the format of the JSON representation of columns, as used by the columns column in the command output:
| 字段 | 描述 |
|---|---|
timestamp_column | 数据源中时间戳列的名称。 |
id_columns | 字符串列名称的数组,它们一起唯一标识源数据中的每行。 |
prediction_class_columns | 用于命名数据源中所有预测类列的字符串数组。 |
prediction_score_columns | 用于命名数据源中所有预测分数列的字符串数组。 |
actual_class_columns | 用于命名数据源中所有实际类列的字符串数组。 |
numerical_columns | 用于命名模型监控器从源表中使用的所有数值特征列的字符串数组。 |
string_columns | 用于命名模型监控器从源表中使用的所有字符串(分类)特征列的字符串数组。 |
boolean_columns | 用于命名模型监控器从源表中使用的所有布尔(分类)特征列的字符串数组。 |
segment_columns | An array of strings naming all segment columns in the data source. For existing model monitors created without segments, this field will be an empty array. |
访问控制要求
A role used to execute this operation must have the following privileges at a minimum:
| 权限 | 对象 | 备注 |
|---|---|---|
| 任意 | 模型监控器 |
Operating on an object in a schema requires at least one privilege on the parent database and at least one privilege on the parent schema.
For instructions on creating a custom role with a specified set of privileges, see Creating custom roles.
For general information about roles and privilege grants for performing SQL actions on securable objects, see Overview of Access Control.
使用说明
-
To post-process the output of this command, you can use the pipe operator (
->>) or the RESULT_SCAN function. Both constructs treat the output as a result set that you can query.For example, you can use the pipe operator or RESULT_SCAN function to select specific columns from the SHOW command output or filter the rows.
When you refer to the output columns, use double-quoted identifiers for the column names. For example, to select the output column
type, specifySELECT "type".You must use double-quoted identifiers because the output column names for SHOW commands are in lowercase. The double quotes ensure that the column names in the SELECT list or WHERE clause match the column names in the SHOW command output that was scanned.