ClaudeCodeMod

All shelves / Mods / Usage

compactly

By swapnildahiphale

compactly is a Claude Code usage mod by swapnildahiphale.

Opens a cost and cache pane with each turn's cost and when the cache goes cold, and compacts at a natural break a Sonnet judge picks, with a handoff summary.

Draws

Install

The marketplace name is compactly.

In Claude Code
/plugin marketplace add swapnildahiphale/compactly
/plugin install compactly@compactly
Open the repo

It runs inside the Claude Code process. The side panel is only what the author's README names. Read the repo before you install, or run claude plugin validate on the plugin folder.

Version
0.1.0
License
Apache-2.0
Repo stars
4
Last change
2026-10-22

What it can reach

  • Draws in the session
  • Reads usage or context figures
  • Sees tool calls
  • Runs a command when you press

Requires Claude Code 2.1.295 or later. Start a new session afterwards. From a shell, the same install is claude plugin install compactly --marketplace swapnildahiphale/compactly. In the CLI, clicking the panel's buttons needs /tui fullscreen; the hotkeys work without it. mode is auto by default (suggest only notifies, off does nothing), judge is sonnet, haiku, or off, and minTokens is 150000. Compaction before the cache expires only runs while Claude Code stays open.

The marketplace name is compactly, and it holds only this plugin. Cost and compaction are why this page files it under usage. smart-compact, by hellosverre, offers /compact in a dialog after a commit, when tests go green, or before the cache expires. compact-adviser, by kunchenguid, draws a hint to run /compact when Jev calls the session a finished checkpoint. This one has Claude Sonnet, through Claude Code, judge whether your new prompt starts after a natural break; if so it holds the prompt back, compacts with a handoff summary, and then sends it. A band asks whether it was a natural break, and each no makes the judge more careful. After a commit, push, or PR with no prompt following, it compacts 5 minutes before the 1-hour cache expires. Saved by compacting tallies what compactions saved, with levels from Cache Rookie to Compaction Legend. The README says the plugin makes no network calls of its own.

Demo

The author's screenshot of compactly in the Claude Code CLI, with ten parts labeled: the Cost & cache panel beside the session, with the model, cache TTL, and a Compact button; stat tiles with sparklines for session cost, cache hit, re-read per turn, and rebuild if cold; the cache clock, warm for 59 minutes; context used against the window; hints as actions; and the cost of the last turn by part. In the session, a git commit is a boundary, compactly compacts there, 29K to 3K, the next task starts on the small context, and the footer line shows the cache state. The figures are the author's.
From the author's repo.

What it hooks into

  • session.startWhen a session starts
  • command.runWhen you run its slash command
  • prompt.submitWhen you send a prompt
  • session.measureWhen usage is measured
  • session.compactWhen the context is compacted
  • turn.startWhen Claude starts a turn
  • tool.callAround a tool call, where it can hold one
  • turn.completeWhen a turn ends
  • ui.renderDraws into the sessionAbovePromptSessionModePane

Read from the on() calls in its hook modules. Open its source under Files to check what each one does.

Files

The author's README and source, 4 files. They load when you open them.

Facts

Author
swapnildahiphale
Category
Usage
Marketplace
compactly
Repo
swapnildahiphale/compactly
Folder
plugin/compactly
Version
0.1.0
License
Apache-2.0
Repo stars
4
Last change
2026-10-22
Language
TypeScript
Files
26

Other mods in Usage

cache-meterT-AI-LabsDraws one row above the prompt with how much of the last turn the prompt cache served, how long it stays warm, and a Keep warm switch that refreshes it.context-meterT-AI-LabsDraws one row above the prompt with the context fill against an auto-compact threshold you pick, and Compact and Clear buttons.usage-limitsT-AI-LabsDraws one row above the prompt with how much of the 5-hour and weekly limits is used, with the time until each resets.context-usageT-AI-LabsDraws the context fill with an auto-compact threshold, Compact and Clear buttons, and the 5-hour and weekly limits in two rows above the prompt.rich-statuslineTheBabaYagaDraws one line above the prompt with the directory, git branch and changes, model and effort, and bars for context and the 5-hour and 7-day limits.cachebeat404MayankKeeps the prompt cache warm while you are away with a small background request, and draws a beating heart under the prompt and a beat count under your turn.tokensaverAGregDevPuts Clawd in a pane and a band above the prompt, trims noisy shell output before Claude reads it, warns as the context fills, and routes subagents by tier.colorwheelAlexeyHRDesignDraws a band in the desktop app with your 5-hour and 7-day limits on its edges and the context as weather, and redraws replies with full-width diagrams.model-pickeralfredtmDraws a band above the prompt when a session opens that lists the models by digit, and runs /model for the one you press; 0 keeps the current one.context-meterAndrewDongminYooDraws the measured context fill above the prompt past 50%, and skips an auto-compact set off when an advisor request makes the session read twice as full.effort-cycleAnercoSteps the effort level of the agent in view with Ctrl+↑ and Ctrl+↓, and draws it as a colored meter in the footer and in each subagent's tasks list row.dotclaudeCarloArnoneHolds a commandOpens a Workspace pane of live context, rate-limit, and cost traces with ten panels, and refuses Claude's file edits until your message approves.
All 183 in Usage