mcpField
D
deterministic-metric-design

deterministic-metric-design

github.com/pproencaData & databases218129 installsUpdated 11w ago
Repository

About deterministic-metric-design

A reference skill for designing metrics that are computable, deterministic, valid, and resistant to gaming. It guides researchers and developers from defining a construct through proof, validation, and adoption.

Key features

  1. 0144 rules across eight categories
  2. 02Construct and proxy definition
  3. 03Computability and tractability guidance
  4. 04Metric property proofs
  5. 05Determinism and reproducibility checks
  6. 06Validity and anti-gaming practices

Use cases

  1. 01Designing a new score or index
  2. 02Reviewing a proposed metric for rigor
  3. 03Setting an optimization target for an agent
  4. 04Making a research metric reproducible and usable

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/pproenca/dot-skills --skill deterministic-metric-design

After installing, type/deterministic-metric-designin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

AGENTS.md
metadata.json
README.md
assets/templates/
_template.md
references/
_sections.md
agg-report-uncertainty-not-false-precision.md
agg-respect-scale-in-aggregation.md
agg-ship-reference-impl-and-test-vectors.md
agg-version-the-metric-publicly.md
comp-bound-approximation-error-explicitly.md
comp-choose-a-decidable-observational-equivalence.md
comp-design-a-proxy-with-a-proven-error-direction.md
comp-do-not-define-metric-as-uncomputable-ideal.md
comp-keep-the-metric-tractable.md
comp-prefer-monotone-confluent-transformations.md
comp-respect-rices-theorem-for-semantic-properties.md
def-anchor-to-the-decision.md
def-fix-unit-of-analysis.md
def-name-the-latent-construct.md
def-operationalize-behavior-and-size.md
def-separate-construct-from-proxy.md
def-write-falsifiable-operational-definition.md
det-control-floating-point-and-accumulation.md
det-make-the-metric-a-pure-function.md
det-pin-iteration-and-tie-break-order.md
det-pin-the-input-representation.md
det-version-and-record-the-toolchain.md
game-detect-reward-hacking-with-audits.md
game-hard-block-construct-violating-wins.md
game-make-cheapest-improvement-the-right-one.md

Details

From the project README

dot-skills Deterministic Metric Design Best Practices

Design metrics that are deterministic, computable, provable, and valid — measures an agent can trust and optimize against without gaming them. The 44 rules across 8 categories take a metric from a fuzzy construct to an adoptable, machine-checkable number: define the construct, confront computability limits with sound proxies, ground it in measurement theory, prove its properties, pin its determinism, validate it empirically, harden it against optimization pressure, and package it for adoption.

A running example threads through every category — a deterministic measure of behavior-preserving codebase-size reduction (shrink code without changing how the app works). It is the ideal stress test because its ideal form is provably out of reach (Kolmogorov complexity is uncomputable; program equivalence is undecidable by Rice's theorem), so the whole craft is building a deterministic, tractable proxy with a proven guarantee.

This is the measurement-design layer that the *-algorithms skills apply (Big-O, NDCG, cyclomatic, MoJoFM) but never teach.

When to Apply

Use this skill when:

  • Designing a new metric, score, or index — or reviewing someone's proposed metric for rigor
  • Asked to "quantify", "measure", "score", or "rank" a property that has no agreed measure yet
  • Building a deterministic optimization target an agent will push on (e.g., reduce code size without changing behavior)
  • Auditing an existing metric that "feels off" — it suspiciously tracks LOC, jumps between runs, or gets gamed
  • Turning a research idea or formula into something computable, reproducible, and adoptable

Workflow: Define → Make Computable → Prove → Validate → Harden

The categories are ordered by cascade severity — an upstream mistake poisons everything below it. Work top-down, and jump straight to a category using this table:

If you are…Start inFirst rule
Starting from a fuzzy propertydef-def-name-the-latent-construct
Worried the ideal is uncomputable / undecidablecomp-comp-do-not-define-metric-as-uncomputable-ideal
Unsure whether you can average or take ratiosmeas-meas-declare-the-scale-type
Claiming the metric behaves a certain wayprop-prop-prove-monotonicity
Getting different numbers between runsdet-det-pin-iteration-and-tie-break-order
Unsure it measures the real thingvalid-valid-discriminant-not-just-loc
Letting an agent optimize the metricgame-game-hard-block-construct-violating-wins
Publishing the metric for othersagg-agg-ship-reference-impl-and-test-vectors

Each reference file is a {category}-{slug}.md containing: WHY it matters, an Incorrect example with the failure annotated, a Correct example with the minimal fix, and a reference. The incorrect/correct examples are metric definitions and procedures, not application code — the contrast is a badly-designed measure versus the fixed one.

Rule Categories by Priority

#CategoryPrefixImpactRules
1Construct Definition & Operationalizationdef-CRITICAL6
2Computability & Tractabilitycomp-CRITICAL7
3Measurement-Theoretic Foundationsmeas-HIGH5
4Proof of Metric Propertiesprop-HIGH6
5Determinism & Reproducibilitydet-HIGH5
6Construct Validity & Calibrationvalid-MEDIUM-HIGH6
7Optimization Safety & Anti-Gaminggame-MEDIUM5
8Aggregation, Reporting & Adoptionagg-LOW-MEDIUM4

See references/_sections.md for the full ordering rationale.

Quick Reference

1. Construct Definition & Operationalization (CRITICAL)
2. Computability & Tractability (CRITICAL)
3. Measurement-Theoretic Foundations (HIGH)
4. Proof of Metric Properties (HIGH)
5. Determinism & Reproducibility (HIGH)
6. Construct Validity & Calibration (MEDIUM-HIGH)
7. Optimization Safety & Anti-Gaming (MEDIUM)
8. Aggregation, Reporting & Adoption (LOW-MEDIUM)

How to Use

  1. Identify where you are with the Workflow table and open the matching first rule.
  2. Work the categories top-down — def- and comp- are CRITICAL because a fuzzy construct or an uncomputable ideal makes everything downstream noise or unusable.
  3. When proposing or critiquing a metric, quote the rule by file path so reviewers can check the reasoning.
  4. For a new metric, produce a one-page spec naming: construct, proxy, scale + unit + zero, proven properties, determinism guarantees, validity evidence, guardrails, and version — one line per category here.
  5. See references/_sections.md for ordering rationale and assets/templates/_template.md when adding rules.

Reference Files

FileDescription
references/_sections.mdCategory definitions, impact levels, and ordering rationale
assets/templates/_template.mdTemplate for adding new rules
metadata.jsonDiscipline, type, and source references

Related Skills

  • same-results-less-code, code-simplifier, complexity-optimizer, knip-deadcode — prescriptive code-reduction skills. This skill supplies the measurement layer they lack: a deterministic, behavior-preserving reduction metric to target and verify.
  • algorithmic-complexity-review, computer-science-algorithms — apply existing measures (Big-O). This skill teaches how to design new ones.
  • opensearch-function-scoring-algorithms — applied ranking metrics (NDCG, A/B tests). This skill is the foundational methodology beneath its eval- category.

Comments

Markdown supported