0xGondarxyz/claude-code-mods/tree/main/usage-meter
usage-meter
一个 Claude Code mod,在状态行显示 Claude 的 5 小时和每周速率限制,并在 80% 和 90% 时发送 toast。
关于这个 mod
usage-meter
一个 Claude Code mod,在状态行显示 Claude 的 5 小时和每周速率限制,并在 80% 和 90% 时发送 toast。
安装
/plugin marketplace add 0xGondarxyz/claude-code-mods
/plugin install usage-meter@claude-code-mods
也可以不安装直接试用:
git clone https://github.com/0xGondarxyz/claude-code-mods
claude --plugin-dir claude-code-mods/usage-meter
Mod 不受沙箱限制,拥有与 Claude Code 相同的访问权限。包括这个 mod 在内,安装任何 mod 前都应先阅读源代码。
它显示的内容
状态行:
Claude 5h 62% (resets 18:40) · week 41%
当某个窗口第一次达到 80% 时提示一次,达到 90% 时再提示一次:
Claude 5h limit at 82%, resets 18:40. Good time to hand big tasks to Sonnet.
如果读数从低于 80% 直接跳过 90%,只发送 90% 的 toast。当使用量回落到 80% 以下后(窗口重置时就会发生),它会再次发出警告。
| 窗口 | 标签 |
| --- | --- |
| 5 小时 | 5h |
| 7 天 | week |
| Spend limit (Claude gateway) | spend |
| 其他 | 窗口自身的名称 |
重置时间使用本地时间制式,为 24 小时制,并且只显示在 5h 部分。缺少重置时间时不会显示。
备注
- 需要 Claude 订阅。使用 API key 时没有速率限制窗口,因此不会显示任何内容。
- 每回合结束后(以及窗口整体移动一格时)更新数字,所以窗口刚重置后可能会有延迟。
测试
claude plugin test .
MIT
安装
请先查看作者 README 确认 marketplace 和插件名称;命令可能随仓库结构改变。
claude plugin marketplace add 0xGondarxyz/claude-code-mods claude plugin install usage-meter
原文 / README
usage-meter
A Claude Code mod that shows your Claude 5 hour and weekly rate limits in the status line and sends a toast at 80% and 90%.
Install
/plugin marketplace add 0xGondarxyz/claude-code-mods
/plugin install usage-meter@claude-code-mods
Or try it without installing:
git clone https://github.com/0xGondarxyz/claude-code-mods
claude --plugin-dir claude-code-mods/usage-meter
Mods are not sandboxed. They run with the same access as Claude Code. Read the source before you install any mod, including this one.
What it shows
Status line:
Claude 5h 62% (resets 18:40) · week 41%
Toast, once when a window first reaches 80% and once more at 90%:
Claude 5h limit at 82%, resets 18:40. Good time to hand big tasks to Sonnet.
If a reading jumps from below 80% straight past 90%, only the 90% toast is sent. It warns again after usage falls back under 80%, which happens when the window resets.
| Window | Label |
| --- | --- |
| 5 hour | 5h |
| 7 day | week |
| Spend limit (Claude gateway) | spend |
| Anything else | the window's own name |
The reset time is local, 24 hour, and shown on the 5h part only. It is left out when the reset time is missing.
Notes
- Needs a Claude subscription. With an API key there are no rate-limit windows, so it shows nothing.
- Figures update after each turn (and when a window moves a whole point), so they can lag right after a window resets.
Tests
claude plugin test .
MIT
其他同名作品
- usage-meterhamzafer · ★ 91
- usage-metermishgoldenberg · ★ 3
- usage-meterLeeHigma0201 · ★ 3
- usage-metereshin087 · ★ 0
- usage-meterPimzino · ★ 0
- usage-meterarafathusayn · ★ 0