模型特征归因偏移违规 - Amazon SageMaker
Amazon Web Services 文档中描述的 Amazon Web Services 服务或功能可能因区域而异。要查看适用于中国区域的差异,请参阅 中国的 Amazon Web Services 服务入门 (PDF)

模型特征归因偏移违规

特征归因偏移作业根据当前 MonitoringExecution 的分析结果评估基准配置提供的基准约束。如果检测到违规行为,则该作业会将其列在执行输出位置的 constraint_violations.json 文件中,并将执行状态标记为 解释结果

以下是特征归因偏移违规文件的架构。

  • label - 标签名称、作业分析配置 label_headers 或占位符(如 "label0")。

  • metric_name - 可解释性分析方法的名称。目前仅支持 shap

  • constraint_check_type - 监控的违规类型。目前仅支持 feature_attribution_drift_check

  • description - 解释违规行为的描述性消息。

{ "version": "1.0", "violations": [{ "label": "string", "metric_name": "string", "constraint_check_type": "string", "description": "string" }] }

对于 explanations 部分中的每个标签,监控作业在基准约束文件和作业分析结果文件 (analysis.json) 中计算其全局 SHAP 值的 nDCG 分数。如果分数低于 0.9,则会记录违规行为。将求出组合的全局 SHAP 值,因此违规条目中没有 “feature” 字段。以下输出提供了一个示例,介绍了几个记录的违规行为。

{ "version": "1.0", "violations": [{ "label": "label0", "metric_name": "shap", "constraint_check_type": "feature_attribution_drift_check", "description": "Feature attribution drift 0.7639720923277322 exceeds threshold 0.9" }, { "label": "label1", "metric_name": "shap", "constraint_check_type": "feature_attribution_drift_check", "description": "Feature attribution drift 0.7323763972092327 exceeds threshold 0.9" }] }