tool-usage

tool-usage is a skill for Claude Code, Codex from stuartshields/claude-setup. It costs 47 tokens per session (187 once invoked), scanned A, original, MIT.

A recovery guide for handling repeated editing-tool failures and searches that do not produce an answer.

In plain words
What is it for?
Recovering from failed edits, checking for file changes made by hooks, and managing web-search and web-fetch attempts.
Why use it?
It provides limits and fallback steps so an agent can reread files, replace them safely when needed, or explain when searching has not converged.

Skill for Claude CodeCodex

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

Good fit Recovering from failed edits, checking for file changes made by hooks, and managing web-search and web-fetch attempts.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/stuartshields/claude-setup/tool-usage
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 stuartshields/claude-setup --skill tool-usage
Clone the repo
git clone --depth 1 https://github.com/stuartshields/claude-setup

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 tool-usage

README.md
[![agentmods](https://agentmods.dev/badge/skills/stuartshields/claude-setup/tool-usage/github.svg)](https://agentmods.dev/skills/stuartshields/claude-setup/tool-usage)
Your own site
<a href="https://agentmods.dev/skills/stuartshields/claude-setup/tool-usage"><img src="https://agentmods.dev/badge/skills/stuartshields/claude-setup/tool-usage/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 tool-usage

Your own site · 80×15
<a href="https://agentmods.dev/skills/stuartshields/claude-setup/tool-usage"><img src="https://agentmods.dev/badge/skills/stuartshields/claude-setup/tool-usage.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 47 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 187 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.
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.00047 $0.00187
Opus 5.5 $0.00019 $0.00075
Sonnet 5.5 $0.00009 $0.00037
Haiku 4.5 $0.00005 $0.00019

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

Security

Grade A, and why

tool-usage 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.

skills/tool-usage/SKILL.md · 15 lines

What it actually says

Tool Usage

Edit Tool

  • Edit retry limit. If Edit fails twice on the same target, re-read the file for actual content. If it still fails, use Write to replace the full file.
  • Read before Edit, always. Hooks may modify file contents after Write — the file on disk may differ from what you expect.

Search Tools

  • WebSearch/WebFetch budget: 3 searches + 2 fetches per question. If you haven't found the answer, summarise what you learned and ask the user.
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 First seen · 15 lines · 47 tokens per session scan A 5f77933536f2

Subscribe to this mod's changes

tool-usage is a skill published in the GitHub repository stuartshields/claude-setup (2 stars, last pushed 4mo ago), licensed MIT. It adds 47 tokens to every session and 187 once invoked, about $0.0002 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-08-31.

Related

Other skills, from other repositories

debug

Instrument web/web-app code with structured debug logging via a global variable (window.debuglogs). Produces a clean JSON timeline for reproducing and diagnosing bugs. Use when user wants to debug a feature or track down a bug.

Weaverse/.agents · 48 tokens

anomaly-alert

Identify anomalous sessions using Agent Monitor data — cost outliers from the pricing engine, token anomalies (cache miss spikes, compaction baseline surges), unusual event type ratios (PreToolUse/PostToolUse gaps, APIError clusters), behavioral deviations from workflow intelligence (complexity score outliers, error…

hoangsonww/Claude-Code-Agent-Monitor · 86 tokens

transcript-grep

Search a Claude Code session transcript for a string or regex pattern and show every matching message with surrounding context. Reads /api/sessions/:id/transcript and resolves sessions via /api/sessions?limit= from the Agent Monitor dashboard. Use when hunting for a specific message, prompt, tool call, or error inside…

hoangsonww/Claude-Code-Agent-Monitor · 73 tokens

regression-watch

Detect quality and efficiency regressions over time using Agent Monitor data — rising error rate (APIError events), falling cache hit rate, growing compaction frequency, and climbing cost-per-session. Splits history into an earlier baseline window and a recent window and reports which metrics are getting worse, by how…

hoangsonww/Claude-Code-Agent-Monitor · 82 tokens

hook-inventory

Inventory hooks across the user, project, and project-local settings plus the /.claude/hooks scripts directory — read through the Agent Monitor Config Explorer API — and flag hooks that POST to the network or run arbitrary commands. Reads /api/cc-config/hooks and /api/cc-config/hook-scripts. Use when auditing hook…

hoangsonww/Claude-Code-Agent-Monitor · 71 tokens

event-trace

Trace the full event chain for one Claude Code session into an ordered timeline of every event type with toolname and summary, highlighting gaps, out-of-order events, and failures. Reads /api/events?sessionid= and /api/sessions/:id from the Agent Monitor dashboard. Use when debugging what a session actually did, step…

hoangsonww/Claude-Code-Agent-Monitor · 73 tokens