Skip to content
Agentmart
Submit a tool

check-usage

Report the Claude Code 5-hour and weekly (Max plan) rate-limit state — percent used, reset time, and the exhaustion forecast at the current pace.

Skill by koteitan

IndexedMIT★ 1
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/koteitan-check-usage

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Report the Claude Code 5-hour and weekly (Max plan) rate-limit state — percent used, reset time, and the exhaustion forecast at the current pace. Use when the user asks how much of the limit is left or when it resets, and before committing to a large workflow fanout that could die mid-run.

Use cases: documents, productivity, agent-building

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found
Runs as
Python package

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/check-usage

What's inside

Skill name
check-usage
Description
Report the Claude Code 5-hour and weekly (Max plan) rate-limit state — percent used, reset time, and the exhaustion forecast at the current pace. Use when the user asks how much of the limit is left or when it resets, and before committing to a large workflow fanout that could die mid-run.
License
MIT
Instructions
52 lines in SKILL.md · view on GitHub

Before installing

  • Ships executable scripts

Files (4)

  • README-ja.md
  • README.md
  • SKILL.md
  • check-usage.py · scripts/

SKILL.md (first lines)

# check-usage

Run the script and report its output:

```bash
python3 ~/.claude/skills/check-usage/scripts/check-usage.py
```

It prints, for both windows:

```
5 hours limit:  90% used, will reset at 07/17 08:00, limited at 07/17 07:12 in the current pace
weekly limit :  51% used, will reset at 07/18 05:00, not projected to hit the limit before the reset
```

## Pacing a workflow

A rate-limit death mid-fanout destroys every in-flight subagent's context: the
`agent()` call is journaled as `{"type":"result","value":null}`, and a
`resumeFromRunId` restarts it from the bare prompt. Only files on disk survive.
So:

- Run this before committing to a large fanout, and again between phases. Prefer
  several smaller workflows in sequence, checking here in the main loop between
  them — a workflow script cannot read the log itself (no filesystem access), so
  self-pacing inside a script costs a sentinel agent per round.
- **Read the forecast asymmetrically.** If it names a time, believe it and don't
  start the fanout. If it doesn't, that is not proof of headroom: the slope is
  extrapolated from past pace, and a fanout is precisely what breaks that pace.
- To size a fanout, read `~/.claude/statusline-usage.log` directly: how much the
  percentage moved during the last comparable wave is a better cost estimate than
  the forecast.
- Weekly and 5-hour are asymmetric — burning the weekly costs days, the 5-hour at
  most five hours. Degrade harder when the weekly is thin.
- Never make disk discipline conditional on this reading (1 agent = 1 file, draft
  early, no in-memory accumulation). Context is also lost to API errors, compaction
  and interrupts, and the forecast is least reliable exactly when it says you are
  fine.

## Notes

- Data comes from `~/.claude/statusline-usage.log`, which `statusline-command.sh`
  appends from the **server-side** `rate_limits` fields Claude Code feeds the
  statusline. This is authoritative — do not reconstruct windows from local JSONL
  (e.g. `ccusage blocks` infers boundaries and drifts from the real reset).
- The forecast is a wall-clock slope extrapolation over the current window's
  samples, so idle time counts. It is only shown when 100% would be reached
  before the reset; otherwise the reset wins and there is nothing to warn about.
- Early in a window the percentage may not have moved yet (1% resolution), so no
  forecast appears — which is also when plenty remains.

From koteitan/my-skills, MIT.

More from koteitan/my-skills

Signals

Stars
1
Forks
0
Open issues
0
Last commit (this folder)
Jul 17, 2026 (3 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from koteitan

Cite this page

check-usage skill. Agent Mart. https://agentmart.dev/skills/koteitan-check-usage (last updated 2026-10-24)