Data model artifacts for Prometheus
Overall
score
93%
Evaluation — 93%
↑ 1.13xAgent success when using this tile
{
"context": "Evaluates whether BuildCounterMetric uses github.com/prometheus/client_model/go to construct and marshal a single counter MetricFamily with exemplar and creation timestamp handling that matches the spec. Scoring is solely based on correct population of the Prometheus proto fields and serialization behavior.",
"type": "weighted_checklist",
"checklist": [
{
"name": "MetricFamily type",
"description": "Populates io_prometheus_client.MetricFamily with Name/Help and sets Type to io_prometheus_client.MetricType_COUNTER while emitting exactly one Metric entry.",
"max_score": 15
},
{
"name": "Counter payload",
"description": "Uses io_prometheus_client.Metric.Counter with Counter.Value set from input and leaves other metric variants nil to ensure a pure counter metric.",
"max_score": 20
},
{
"name": "Creation timestamp",
"description": "Maps CreatedTimestampMs to Counter.CreatedTimestamp using google.golang.org/protobuf/types/known/timestamppb and omits CreatedTimestamp when the input is zero.",
"max_score": 15
},
{
"name": "Exemplar content",
"description": "Builds Counter.Exemplar with label pairs, value, and timestamp by setting Exemplar.Label, Exemplar.Value, and Exemplar.Timestamp; omits the exemplar when exemplar inputs are absent.",
"max_score": 20
},
{
"name": "Label pairs",
"description": "Converts input label maps into []*io_prometheus_client.LabelPair on Metric.Label and (when present) Exemplar.Label with correct name/value mapping.",
"max_score": 10
},
{
"name": "Serialization",
"description": "Serializes the MetricFamily via proto.Marshal (or equivalent) from google.golang.org/protobuf/proto and returns the resulting bytes without altering the proto structure post-marshal.",
"max_score": 10
},
{
"name": "Validation errors",
"description": "Rejects invalid inputs (e.g., empty Name or negative ExemplarTimestampMs) with an error before marshaling and without returning serialized bytes.",
"max_score": 10
}
]
}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