feat: align monitor metric labels with HAMi and Prometheus conventions #160
All Vouch review confidence checks passed
Residual risk 0.17 = Change Risk (0.42) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.42 · 330 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.347
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #160"
general
weight: 0.35
fishman
What type of PR is this?
/kind feature
What this PR does / why we need it:
Aligns
hami_dra_metric labels and device names with HAMi and Prometheus conventions so dashboards can be shared with HAMi.| Old label | New label |
| --- | --- |
|
nodeid|node||
deviceuuid|device_uuid||
deviceidx|device_index||
devicename|device_name||
deviceproductname|device_type||
devicebrand| removed ||
podnamespace|namespace||
podname|pod|hami_dra_vgpu_) only keepnode,device_uuid,namespaceandpod.device_typefollows HAMi's names:Tesla P4→NVIDIA-Tesla P4(likeNormalizeDeviceModel),310P3→Ascend310P(from the device config ConfigMap's Ascend chip table).--device-config-file(default:/device-config.yaml) and falls back to built-in defaults if it's missing.--legacy-metrics) keep their old names, labels and values.honor_labels.Which issue(s) this PR fixes:
Fixes #146
Special notes for your reviewer:
devicebrandis removed becausedevice_typenow includes the vendor.0–1vs0–100), so shared dashboards need to account for this.Does this PR introduce a user-facing change?:
The
hami_dra_metrics use new label names,devicebrandis removed, and per-pod metrics drop the device labels. Legacy metrics are unchanged.Related: https://github.com/Project-HAMi/HAMi/issues/2126
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
<!-- coderabbit-ai-generated:v1 -->
Summary by CodeRabbit
New Features
Device types can be customized through a configuration file, with built-in defaults used when it is missing. Configuration changes trigger monitor and webhook pod updates.
Prometheus metrics use normalized device types and shorter label names. Pod metrics combine allocations for the same pod and device; standard pod metrics are omitted when a device UUID is unavailable.
Documentation
Updated metric examples and documented legacy labels and how to preserve metric labels when they conflict with target labels.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->