Observed arrival · 2026-09-08
Tokenbrake puts guardrails on Claude Code's context window
A pair of local Claude Code hooks trims oversized shell output, caps unbounded file reads, and reports which tool results consumed a session's context.
Field notes
Tokenbrake operates through Claude Code's PreToolUse and PostToolUse hooks rather than modifying source files or compressing output. Shell results over 6,000 characters keep the first and last 40 lines plus up to 20 error- or warning-looking lines, while the complete result remains in ~/.claude/tokenbrake/out/. For oversized file reads, the page documents a 60 KB threshold and a 300-line replacement limit. A local JSONL ledger joins result sizes to tool-use IDs for session reporting.
Observed signals
Read the marks
Editorial observations of this landing page, not a rating.
One card from the complete issue