Data model artifacts for Prometheus
Overall
score
93%
Evaluation — 93%
↑ 1.13xAgent success when using this tile
{
"context": "Evaluates how well the solution leans on github.com/prometheus/client_model/go to normalize and validate metric kinds. Scoring emphasizes correct use of the package's MetricType enum, its generated name/value maps, and enum helpers for canonical string handling and validation paths.",
"type": "weighted_checklist",
"checklist": [
{
"name": "MetricType usage",
"description": "MetricKindValue is backed by the package's MetricType values (e.g., MetricType_COUNTER, MetricType_HISTOGRAM) via direct import of github.com/prometheus/client_model/go instead of custom integers.",
"max_score": 20
},
{
"name": "String to enum",
"description": "ParseMetricKind normalizes input and resolves kinds through MetricType_value (or equivalent lookup against MetricType) rather than ad-hoc string lists, covering aliases like hyphen/underscore gauge histogram.",
"max_score": 25
},
{
"name": "Enum to string",
"description": "CanonicalMetricKind uses MetricType_name or the MetricType.String() helper to emit canonical uppercase names (including GAUGE_HISTOGRAM) instead of handcrafted switch strings.",
"max_score": 20
},
{
"name": "Payload gating",
"description": "ValidateMetricPayload compares payload choices against MetricType constants to enforce the single allowed payload per kind (counter, gauge, summary, untyped, histogram/gauge histogram) instead of unconstrained flags.",
"max_score": 20
},
{
"name": "Unsupported handling",
"description": "Unsupported kinds or numeric values are detected by checking absence in MetricType_name/MetricType_value (or failed MetricType parsing) and surfaced as errors without defaulting to arbitrary integers.",
"max_score": 15
}
]
}Install with Tessl CLI
npx tessl i tessl/golang-github-com-prometheus--client-modeldocs
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10