新增 templates/ti-cl4/impurity-forecast:声明式特征工程引擎,特征以 FeatureSpec 描述(EMA/RollingStd/RateOfChange 等 7 算子),换行业只改模板配置 features.template.yaml,引擎零改动(PRD 5.3:特征工程层跨行业差异落在 FeatureSpec,不落代码)。 - features.py:FeatureSpec 声明 + 校验 + 7 算子 + 时序对齐 + 阈值 breach + 零依赖 YAML 解析 - config/features.template.yaml:炉温/氯气/炉压/炉层 9 条特征(对齐点位字典 point_id) - tests/test_features.py:24 项单测(校验/算子/对齐/breach/配置/端到端提前量)全通过 - _sanity_check.py:冒烟脚本(配置加载 + transform + breach 可观测) 验收:一期阈值+无监督上线,提前量信号可观测(PRD 提前≥30min、误报率≤8%口径)。
30 lines
723 B
Python
30 lines
723 B
Python
# -*- coding: utf-8 -*-
|
|
"""iAOP-Template-Ti 一期 · 炉层杂质预警特征工程包(Issue #70)。
|
|
|
|
导出声明式 FeatureSpec 特征工程引擎,供预警模型训练(#71)与驾驶舱
|
|
告警面板复用。换行业只改模板配置,引擎零改动(PRD 5.3 特征工程层)。
|
|
"""
|
|
from __future__ import annotations
|
|
|
|
from .features import (
|
|
FeatureKind,
|
|
FeatureSpec,
|
|
FeatureSpecError,
|
|
FeatureValue,
|
|
FeatureVector,
|
|
FeatureEngine,
|
|
FeatureTemplateConfig,
|
|
load_feature_config,
|
|
)
|
|
|
|
__all__ = [
|
|
"FeatureKind",
|
|
"FeatureSpec",
|
|
"FeatureSpecError",
|
|
"FeatureValue",
|
|
"FeatureVector",
|
|
"FeatureEngine",
|
|
"FeatureTemplateConfig",
|
|
"load_feature_config",
|
|
]
|