.agents/skills/project-prometheus-profiles/how-tos/build-synthetic-fixture.md
A source-derived fixture proves the structure and routing of metric surfaces that one available deployment does not expose. It does not prove that those surfaces are enabled, emitted, populated, or bounded the same way in a real deployment.
Record the target before generating samples:
“All metrics” means all source-defined writer-capable families in this declared scope. It does not mean unknown future releases, downstream forks, or arbitrary runtime-generated label values.
Use primary evidence first:
Third-party dashboards and fixtures are recommended discovery evidence, not exporter-contract authority. They can be stale, collapse labels, or compute a different quantity from the title they display.
Start from a sanitized transformation of an observed dump when one exists, then add source-only families. A committed fixture MUST:
HELP, TYPE, exact family/sample names, and structural suffixes;SOURCE-SEMANTICS.yaml;Synthetic values MAY be zero when only structure is under test. Do not assert
those values as behavioral expectations. When non-zero histogram values are
needed, cumulative buckets MUST be monotonic, _count MUST agree with the
terminal bucket, and _sum MUST remain plausible for the observations.
One fixture MAY combine optional capabilities only when the source contract proves they can coexist in one producer mode. Use separate realizable fixtures and proof cases when combining surfaces would:
Keep observed and synthetic evidence separate:
A partial real dump may report dead optional charts in the strict authoring
validator after the complete profile is added. That is an evidence limitation,
not a runtime collector failure. Never relabel a synthetic PASS as full
production validation.
The proof contracts MUST record provenance without duplicating it:
SOURCE-SEMANTICS.yaml records application/exporter revisions, authoritative public source locations, source
environments, registrations, and update semantics. It is the source-backed contract; it does not classify a private
scrape as observed versus synthetic.proof.yaml names each sanitized replay fixture, declares its realizable environment, and records the independently
authored expected replay outcome. Keep private observed dumps outside the proof bundle.Coverage across those cases is source-complete; no individual case is relabeled as a complete runtime deployment when the supported surface is mutually exclusive.