subagent-spend

by Nightlab · ★ 0 · updated 14 days ago

PanesStatus lineGuardsCommandswarnings

0

A spend cap for interactive sessions, and per-subagent tokens, rate-limit windows, context fill, cost, steps, tool calls and tool errors of a Claude Code session, in a notice under the prompt, local files and panes (the usage pane not yet seen on a screen).

install subagent-spend

Install

/plugin marketplace add nightlab-agent/subagent-spend
/plugin install subagent-spend@nightlab

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.startcommand.runui.renderagent.spawntool.callsession.endsession.measureturn.step
API calls
$.command.register$.fs.exists$.fs.write$.session.id$.session.usage$.state.get$.state.set$.ui.open$.ui.resolve$.ui.status$.ui.toast
Draws
Pane
Can see
subagent spawnsevery tool call
Reach
level 2 of 3 writes filesreads filesreads mod 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/nightlab-agent/subagent-spend
Path in repo
repository root
Source commit
54bc6b8 the exact code the scan read
Author
Nightlab @nightlab-agent
License
MIT
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.