farley-score

farley-score is a command for Claude Code from mse-online/farley_score_plugin. It costs 15 tokens per session (5,384 once invoked), scanned B, original, MIT.

A command that evaluates software tests using Dave Farley's eight properties of good tests. It can review a chosen file, folder, or project.

In plain words
What is it for?
Scoring tests, reviewing a specified code path, showing an example report, or guiding a developer through the available review options.
Why use it?
It helps identify weaknesses in test quality and produces a structured review instead of relying only on informal judgment.

Command for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: reads .claude/ paths; names the AskUserQuestion tool.

Part of the msec plugin — 2 commands shipped together

Good fit Scoring tests, reviewing a specified code path, showing an example report, or guiding a developer through the available review options.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/mse-online/farley_score_plugin/farley-score
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.

Clone the repo
git clone --depth 1 https://github.com/mse-online/farley_score_plugin

Made for: Claude Code.

Or install msec, the plugin that ships this one along with the rest of its 2 commands.

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 farley-score

README.md
[![agentmods](https://agentmods.dev/badge/commands/mse-online/farley_score_plugin/farley-score.svg)](https://agentmods.dev/commands/mse-online/farley_score_plugin/farley-score)
Your own site
<a href="https://agentmods.dev/commands/mse-online/farley_score_plugin/farley-score"><img src="https://agentmods.dev/badge/commands/mse-online/farley_score_plugin/farley-score.svg" alt="Measured on agentmods" height="20"></a>
Per session 15 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 5,384 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.00015 $0.05384
Opus 5 $0.00008 $0.02692
Sonnet 5 $0.00003 $0.01077
Haiku 4.5 $0.00002 $0.00538

Measured 7d ago against content hash b79a754ce689, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade B, and why

farley-score scanned grade B with 1 finding 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 7d 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.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

1. Run: `PLUGIN_DIR=$(find ~/.claude/plugins -name "cli_calculator.py" 2>/dev/null | head -1 | sed 's|/lib/cli_calculator.py||')` -- this finds the plugin's root directory.
commands/farley-score.md · 444 lines

How it starts

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

ENTRY POINT: Determine User Intent

CRITICAL: BEFORE doing anything else, determine how the user invoked this command.

If invoked WITH a target path

If the user's message includes a file path, directory path, or specifies what to analyse (e.g., /msec:farley-score tests/, /msec:farley-score src/test/java/, /msec:farley-score evaluate test quality for the whole project), skip the welcome menu and go directly to the 4-Phase Workflow section below.

If invoked WITHOUT a target path

If the user simply typed /msec:farley-score with no additional arguments or context, present the welcome menu.

Use the AskUserQuestion tool to present the menu. Do NOT output the options as plain text. This ensures the user gets a navigable interactive menu (arrow keys + Enter) rather than having to type a number.

Question: "Welcome to Farley Score! What would you like to do?" Header: "Farley Score"

Options (use these exact labels and descriptions):

  1. Label: "What is this?" -- Description: "Learn what the Farley Score tool does and how it works"
  2. Label: "Show me a demo" -- Description: "See a complete sample report instantly from bundled example tests"
  3. Label: "Analyse my tests" -- Description: "Run a full test quality analysis on your project"
  4. Label: "Coach me" -- Description: "Switch to interactive coaching mode with Socratic questioning"

Option 1: What is this?

Present this overview to the user:

Farley Score measures test quality, not just test coverage.

It evaluates your tests against Dave Farley's 8 Properties of Good Tests -- Understandable, Maintainable, Repeatable, Atomic, Necessary, Granular, Fast, and First (TDD) -- and produces a single number: the Farley Index (0-10).

The tool reads your test code (it never modifies anything), detects quality signals and anti-patterns, scores each property on a 0-10 scale, and produces a detailed report with evidence, worst offenders, and prioritised recommendations.

Not all properties are equal. Understandable and Maintainable have the highest weight (1.5x) because tests that read like specifications and survive refactoring deliver the most long-term value. Fast has the lowest weight (0.75x) because a slow but well-designed test beats a fast but poorly designed one.

A typical analysis takes 3-5 minutes depending on the size of your test suite.

Rating scale: Exemplary (9-10), Excellent (7.5-8.9), Good (6-7.4), Fair (4.5-5.9), Poor (3-4.4), Critical (0-2.9)

Read the full file on GitHub · 444 lines

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. 7d ago First seen · 444 lines · 15 tokens per session scan B b79a754ce689

Subscribe to this mod's changes

farley-score is a command published in the GitHub repository mse-online/farley_score_plugin (27 stars, last pushed 6mo ago), licensed MIT. It adds 15 tokens to every session and 5,384 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.