ashlr-hook-timings

ashlr-hook-timings is a command for Claude Code from ashlrai/ashlr-plugin. It costs 27 tokens per session (369 once invoked), scanned A, original, MIT.

A command that reports how long coding-agent hooks take to run. Hooks are automatic actions that run around tool calls, and the report shows typical, slow, and worst-case times for each one.

In plain words
What is it for?
Use it to inspect recent hook latency, compare it with an earlier period, or print only hooks that exceed the listed speed limits.
Why use it?
It helps find hooks that make the agent feel slow or frequently fail. A comparison option shows whether hook speed has improved or worsened over time.

Command for Claude Code

Written for Claude Code: argument-hint in frontmatter.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the ashlr plugin — 11 skills, 36 commands, 5 agents, 7 hooks, 1 MCP server shipped together

Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add ashlrai/ashlr-plugin
Claude Code
/plugin install ashlr

Made for: Claude Code.

Or install ashlr, the plugin that ships this one along with the rest of its 11 skills, 36 commands, 5 agents, 7 hooks, 1 MCP server.

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 ashlr-hook-timings

README.md
[![agentmods](https://agentmods.dev/badge/commands/ashlrai/ashlr-plugin/ashlr-hook-timings.svg)](https://agentmods.dev/commands/ashlrai/ashlr-plugin/ashlr-hook-timings)
Your own site
<a href="https://agentmods.dev/commands/ashlrai/ashlr-plugin/ashlr-hook-timings"><img src="https://agentmods.dev/badge/commands/ashlrai/ashlr-plugin/ashlr-hook-timings.svg" alt="Measured on agentmods" height="20"></a>
Per session 27 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 369 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00027 $0.00369
Opus 5 $0.00014 $0.00185
Sonnet 5 $0.00005 $0.00074
Haiku 4.5 $0.00003 $0.00037

Measured 5d ago against content hash 19ba1b9a9c82, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

ashlr-hook-timings 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 5d 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.

commands/ashlr-hook-timings.md · 31 lines

What it actually says

Run the hook timings report and render its output to the user.

bun run "${CLAUDE_PLUGIN_ROOT}/scripts/hook-timings-report.ts" $ARGUMENTS

Capture stdout and display it verbatim inside a fenced code block (```) so column alignment renders correctly.

The report covers:

  • Header: total records, time window, overall median latency.
  • Per-hook table: calls, p50, p95, max, error%, block%.
  • Flagging lines for hooks where p95 > 200ms (⚠ threshold exceeded) or max >= 1s.
  • If no records yet: a single plain-text prompt to enable hooks.

Flags:

  • --hours N — narrow or widen the time window (default: 24h).
  • --compare — show trend indicators (↓ improved / ↑ regressed) next to each hook's p95, comparing the current window against the previous equal-length window. A hook is "improved" when p95 dropped ≥20%, "regressed" when it grew ≥20%.
  • --flags-only — output only the slow-hook warning lines (compact alert mode). Useful for scripting or quick checks. Exits silently when no flags exist.

After the verbatim block, add at most one short line:

  • If the output contains "no records yet": "No timings recorded yet — run a few tool calls with hooks enabled."
  • Otherwise: say nothing extra. The report speaks for itself.

Do not paraphrase the numbers.

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. 5d ago First seen · 31 lines · 27 tokens per session scan A 19ba1b9a9c82

Subscribe to this mod's changes

ashlr-hook-timings is a command published in the GitHub repository ashlrai/ashlr-plugin (3 stars, last pushed 5d ago), licensed MIT. It adds 27 tokens to every session and 369 once invoked, about $0.0001 per session on Opus 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-08-31.