From context-diet
Trims huge tool outputs (logs, JSON, diffs, grep, file lists) before they reach Claude's context, and saves the full text to a file Claude can read
6 events · 15 calls
Ships in context-diet. Installing the plugin adds it to Claude Code.
A mod runs inside Claude Code as you, unsandboxed. This is what its source calls.
tool.callfs.writefs.existsfs.readEach event it registers a hook on, with the matcher when it sets one
session.starttool.callsession.append{door=tool-result}command.run{command=diet}ui.close{id=context-diet}ui.render{component=Pane, requestId=context-diet}Every mods API method its source calls, by namespace
nowregisterexistsreadwritecwdgetsetgetsetinvalidateopenresolvestatustoastWhere Claude Code finds the mod
hooks/hooks.jsonhooks/register.tsx (written ./register.tsx)Read from the source, never run. Claude Code checks a mod again when it loads it and can refuse code this reading accepts; claude plugin validate shows its own list.
npx claudepluginhub hy4hy/context-diet --plugin context-diet