goodharts-law

goodharts-law is a skill for Claude Code, Codex from deciqAI/knowledge-skills. It costs 92 tokens per session (1,827 once invoked), scanned A, original, MIT.

A guide to Goodhart's Law, the idea that people may optimize a measured target instead of the real outcome it represents. It explains why a rising key performance indicator, or KPI, may not mean genuine improvement.

In plain words
What is it for?
Use it when designing KPIs, bonuses, audits, benchmarks, algorithmic goals, or score-based resource allocation.
Why use it?
It helps identify gaming, unintended behavior, and flawed evaluation systems before a single metric distorts work or rewards the wrong result.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when designing KPIs, bonuses, audits, benchmarks, algorithmic goals, or score-based resource allocation.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/deciqai/knowledge-skills/goodharts-law
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add deciqAI/knowledge-skills --skill goodharts-law
Clone the repo
git clone --depth 1 https://github.com/deciqAI/knowledge-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for goodharts-law

README.md
[![agentmods](https://agentmods.dev/badge/skills/deciqai/knowledge-skills/goodharts-law/github.svg)](https://agentmods.dev/skills/deciqai/knowledge-skills/goodharts-law)
Your own site
<a href="https://agentmods.dev/skills/deciqai/knowledge-skills/goodharts-law"><img src="https://agentmods.dev/badge/skills/deciqai/knowledge-skills/goodharts-law/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for goodharts-law

Your own site · 80×15
<a href="https://agentmods.dev/skills/deciqai/knowledge-skills/goodharts-law"><img src="https://agentmods.dev/badge/skills/deciqai/knowledge-skills/goodharts-law.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 92 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,827 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00092 $0.01827
Opus 5.5 $0.00037 $0.00731
Sonnet 5.5 $0.00018 $0.00365
Haiku 4.5 $0.00009 $0.00183

Measured 1mo ago against content hash c22e95f0de74, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

goodharts-law scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

goodharts-law/SKILL.md · 125 lines

How it starts

The opening of the file, as written. The whole thing — 125 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Goodhart's Law

Overview

Goodhart's Law: when a metric controls behavior, people optimize the metric rather than the underlying goal. Formulated by economist Charles Goodhart (1975) on UK monetary policy; sharpened by Marilyn Strathern (1997): "When a measure becomes a target, it ceases to be a good measure." Four failure mechanisms (Manheim & Garrabrant 2018): Regressional, Extremal, Causal, Adversarial. Countermeasure is always multi-metric + audit + rotation.

Composes with feedback-loops, principal-agent, okr-goal-setting, survivorship-bias.

When to Use

  • A KPI is being introduced or its weight is increasing in performance evaluation
  • A metric is "improving" without corresponding improvement in the underlying goal
  • People are visibly optimizing for a number rather than the work it was meant to track
  • Algorithmic optimization is producing outcomes the designers didn't intend
  • Resource allocation is driven by a single composite score or ranking
  • An AI model, benchmark, or engagement metric is being optimized (or used to justify AI capex / adoption / AI-native competition) and the score is rising faster than real capability or user value

Not when: metric and goal are identical; stakes too low for gaming; metric is purely descriptive with no reward/punishment; question is which metric to use, not whether the measurement-reward system is sound.

Coaching Novices (Adaptive Front Door)

  • Engine mode: user has a concrete metric or system → run The Process directly.
  • Coach mode: user is unfamiliar or has no concrete case → guide step by step.

In Coach mode, respond one step at a time. Each [WAIT] is a hard stop — output only that step's question, then stop.

  1. One-line: before relying on a metric to control behavior, predict how people will game it — choose the system that survives that prediction.
  2. Check fit: if the metric is purely descriptive (no reward attached), Goodhart's law doesn't apply yet.
  3. Elicit the specific metric and the underlying goal: what's being measured? What's the actual outcome you care about?

[WAIT — do not advance until user responds]

  1. One question at a time: proxy gap? How would a clever agent game this? Which Goodhart category? What countermeasure fits?

[WAIT — do not advance until user responds]

  1. Close: name the gaming-resistant design (multi-metric, audit, rotation, paired-constraint) + monitoring schedule.

[WAIT — do not advance until user responds]

Read the full file on GitHub · 125 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed c22e95f0de74
  2. 3mo ago First seen · 125 lines · 92 tokens per session scan A b3e6321ddf6a

Subscribe to this mod's changes

goodharts-law is a skill published in the GitHub repository deciqAI/knowledge-skills (18 stars, last pushed 1mo ago), licensed MIT. It adds 92 tokens to every session and 1,827 once invoked, about $0.0004 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

goodharts-law compared with skills from other repositories

goodharts-law next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
goodharts-lawdeciqAI/knowledge-skillsSkill181mo agoMITA92Claude Code, Codex
account-intelligencealebgl77/claude-incSkill233d agoMITA23Claude Code
ai-adoption-leadalebgl77/claude-incSkill233d agoMITA24Claude Code
compliance-checkalebgl77/claude-incSkill233d agoMITA21Claude Code
ui-ux-pro-maxalebgl77/claude-incSkill233d agoMITA23Claude Code
cto-advisoralebgl77/claude-incSkill233d agoMITA18Claude Code
growth-engineeringalebgl77/claude-incSkill233d agoMITA16Claude Code