Docs
Reference pages for Sprag, the command-line harness for Claude Code.
Claude Code statusline: cache hit rate, cache TTL countdown, 5-hour and 7-day rate limitsReference for the Sprag statusline for Claude Code: prompt cache hit rate, cache expiry countdown, context usage, 5-hour and 7-day rate-limit windows, monthly spend, and the warning chips that lead the line when something is wrong.
Why realtime model routing can cost more in Claude CodePrompt caches are kept per model, so switching Claude Code to a cheaper model mid-session starts from a cold cache and re-reads the whole conversation at full price. Sprag delegates to subagents instead and leaves the main session's cache intact.
Delegate repeat Claude Code work to Haiku and Sonnet subagents with route-scansprag route-scan reads your Claude Code session logs after the fact, finds request types an expensive model handled repeatedly, and writes delegation rules that send that work to cheaper subagents. Savings are recorded per run as a ledger, not an estimate.
Claude Code harness: ratchet rules, evidence-gated completion, Plan-Execute-VerifyThe Sprag harness for Claude Code turns repeated failures into rules that load every session, blocks "all done" reports with no evidence attached, and enforces a Plan, Execute, Verify cycle on multi-step work.
Convert pptx, xlsx, pdf, docx and fig to Markdown before Claude Code reads themsprag doc2md converts PowerPoint, Excel, PDF, Word and Figma files to Markdown so Claude Code reads a compact text version instead of a raw attachment. One 510k-token deck became a few thousand tokens.
Claude Code statusline behind LiteLLM and other gatewaysHow the Sprag statusline reads spend, budgets and cache TTL when Claude Code runs through LiteLLM or another API gateway, and why the cache countdown can look frozen.
Install Sprag, the Claude Code token saverInstall the Sprag command-line harness for Claude Code with one npm command, register the statusline and hooks, and verify the setup.
Sprag command referenceEvery sprag command in one page: route-scan, harness, doc2md, handoff, mode, stats and the statusline switches.
Korean writing style gate for Claude Code outputSprag lints Korean text at write time: double passives, translationese, cohesion between sentences.