Claude Code usage

Pxpipe

cut Claude Code token usage by rendering text context as images

7,576 stars 656 forksUsage & cost trackers Source

Install

Install
npx pxpipe-proxy                                  # proxy on 127.0.0.1:47821

Found in the project README. Check it for setup steps after installing.

From source
git clone https://github.com/teamchong/pxpipe.git

From the README

pxpipe

Cut coding-agent input tokens by rendering bulky context as images — the same system prompt, tool docs, and history, in a fraction of the tokens.

An image's token cost is fixed by its pixel dimensions, not by how much text
is inside it. Dense content (code, JSON, tool output) packs ~3.1 chars per
image-token vs ~1 char per text-token on real Claude Code traffic. The
reader is the same vision channel that Anthropic's computer use already
relies on for screenshots. pxpipe is a local proxy that uses that channel
for context: it rewrites the bulky parts of each request into compact PNGs
before it leaves your machine. On the original June 2026 claude-fable-5
runs, that landed as a ~59–70% lower end-to-end bill (10/10 SWE-bench Lite,
14/19 SWE-bench Pro, 13/15 dense hex). Since then, Gemini 4 (gemini-4-argon)
reached 15/15 on pure-image dense hex (with no factsheet in the benchmark), while later
Claude releases (claude-fable-5-1, claude-opus-5-5, claude-sonnet-5-5,
claude-haiku-5-5) regressed sharply on dense pixel reading (0/15–6/15 hex; see
The honest part). Durable token savings are measured
per-request against a free count_tokens counterfactual in
~/.pxpipe/events.jsonl.

This is what the model sees instead of text:

*~48k chars of system prompt + tool docs: ≈25k tokens as text, ≈2.7k image
tokens as this page. Real pipeline output; Gemini 4 Argon (15/15 pure-image hex, 100/100
pure-image arithmetic), Gemini 3.6–3.8 Flash (14/15 hex), and original
Fable 5 (13/15 hex) read renders like this at full fidelity, whereas later
Claude 5.5 / Fable 5.1 releases do not (see model tiers).*

![chart: characters a frontier context window holds, 2018–2026 — vendor text series including Grok 4.5; orange measured overlays are Fable 5 [1m] + pxpipe ~19.0M (4.8×) and Gemini 3.6…
Read the full README on GitHub

Details

Language
TypeScript
License
MIT
Last updated
1 November 2026

FAQ

What is Pxpipe?

cut Claude Code token usage by rendering text context as images It is a usage for Claude Code, from teamchong/pxpipe on GitHub.

How do I install Pxpipe?

Run npx pxpipe-proxy # proxy on 127.0.0.1:47821, then follow the setup in the README.

Is Pxpipe popular?

teamchong/pxpipe has 7,576 GitHub stars and 656 forks. It was last updated on 1 November 2026.

More usage & cost trackers

Browse the most popular Claude Code mods, all usage & cost trackers, or the skills and MCP server directories.