cost-guard

by Tigran Aleksanyan · ★ 0 · updated 14 Oct 2026

BandsStatus lineCommandsPromptvalidates

0

Holds a message that would cost more than your token or dollar limit (cold prompt cache or a very large message), explains why, and asks before sending. Can also keep the cache warm during a break.

install cost-guard

Install

/plugin marketplace add tgralex/claude-mods
/plugin install cost-guard@claude-mods

Then run /reload-plugins or start a new session. Requires Claude Code 2.1.287+.

View source on GitHub

What it hooks into

From an automated scan with claude plugin validate, not a security review. Mods run with your permissions; read the code before installing.

Events
session.startsession.measureturn.startturn.completeprompt.submitcommand.runui.render
API calls
$.clock.every$.clock.now$.command.register$.env.get$.model.fork$.prompt.fill$.prompt.submit$.session.id$.session.model$.session.usage$.settings.read$.state.get$.state.set$.store.delete$.store.get$.store.set$.ui.log$.ui.resolve$.ui.status$.ui.toast
Draws
AbovePrompt
Can see
every prompt
Reach
level 2 of 3 drives Claudewrites the prompt boxreads env varsreads settingsreads mod statepersists statedraws

Origin

How it got here
Automated scan of public GitHub repos, via the CC0 dataset awesome-claude-code-mods (scan of ).
Repository
github.com/tgralex/claude-mods
Path in repo
mods/cost-guard
Source commit
b15c240 the exact code the scan read
Author
Tigran Aleksanyan @tgralex
License
No license declared — ask the author before reusing code.
First published
Last pushed
First listed here

Name and description come from the mod's own manifest. We link to the code; we don't host it, and it stays under its author's license.

More from tgralex/claude-mods

read-aloud

tgralex/claude-mods

Reads Claude's replies and plans aloud, whole or just the text you selected, with a Stop button while it reads.

★ 0BandsReskinsCommands