Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By patientlyv0.1.4MIT AND Apache-2.0In 1 marketplace
Routes I/O-heavy implementer work to a cheap worker model through anti-tangent-mcp. PreToolUse hooks block oversized full-file reads and redirect them to the bulk_read MCP tool, so a large file corpus never enters the implementer's context.
Claude loads one when your task matches it, or you run it by name.
1 caution to review before installing
A hook runs when Claude uses the Bash tool
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Routes I/O-heavy implementer work to a cheap worker model, keeping the implementer's context small and token-efficient.
This plugin provides PreToolUse hooks that intercept oversized Read and Bash
calls, redirecting them to anti-tangent-mcp's bulk_read tool. The server
reads the files server-side and sends their full contents to the configured
worker provider (ANTI_TANGENT_WORKER_MODEL) to answer the question, returning
only the answer to the implementer. This keeps large file corpora out of the
implementer's context entirely, but it does mean the redirected files' contents
leave the machine to that provider — the documented purpose of the delegation,
not an incidental leak, and worth knowing before pointing this at anything
sensitive.
The plugin requires the anti-tangent-mcp server to be installed and configured
with an ANTI_TANGENT_WORKER_MODEL env var pointing to a cheap model (e.g.
anthropic:claude-haiku-4-5-20251001; see the root README's "Model tiers"
table for other allowlisted options). The server must be launched before
Claude Code can route calls.
Add the plugin via the Claude Code marketplace:
claude plugin marketplace add patiently/anti-tangent-mcp
Then install the anti-tangent-shunt plugin from the repository:
claude plugin install anti-tangent-shunt@anti-tangent-mcp
This plugin requires jq to be available in your PATH for hook execution.
The plugin reads one env var to decide when to delegate a read — both the
Read hook (check-file-size) and the Bash hook (check-bash-read, which
catches cat/head/tail/less/more on the same files) use it:
ANTI_TANGENT_SHUNT_MIN_LINES — threshold file line count (default: 350).
Reads of files exceeding this limit are routed to bulk_read; smaller reads
proceed normally.The server configuration is separate: the anti-tangent-mcp server must be
started with an ANTI_TANGENT_WORKER_MODEL env var set to the cheap model to
use for delegated work (e.g. anthropic:claude-haiku-4-5-20251001 — see the
root README's "Model tiers" table for the full allowlist). The server routes
the actual questions to that model.
Both hooks ask the same question — is this read bounded to something small? — and only two things answer it.
head/tail. head -n 5 large.go and head -100 large.go are allowed: the count is at or under
ANTI_TANGENT_SHUNT_MIN_LINES, so the read is genuinely small. head -n 100000 large.go is blocked — the count is the whole file.limit bounds a Read; an offset does not. Read(offset: 0, limit: 50) is allowed. Read(offset: 0) and Read(offset: 100) are
blocked: an offset says where to start, never how much to take.This is a correction, and the earlier behaviour was a bypass. Until
CodeRabbit caught it on PR #65, the ported parser stripped -n as an option
and read the count as the path — so head -n 100000 large.go sailed
through and put the entire file in context, defeating the hook outright. The
same held for Read(offset: 0), where a legitimate 0 was treated as absent.
Both are now closed, each with a regression case proven to fail against the
unfixed hook.
An earlier round of this release documented that parser behaviour as an
inherited quirk to be preserved for upstream fidelity, and amended the design
doc to match it. That was the wrong call: fidelity to a pinned port is not
worth shipping a one-token defeat of the feature. Five of the seventeen ported
upstream cases changed as a result, and are marked as deliberate divergences
in bash-hook-evals.json and hook-evals.json.
The plugin includes a test suite for the hook routing logic. To run it:
bash plugin/anti-tangent-shunt/evals/run.sh
The suite includes:
Upstream reports these figures against a 162K-line Java monorepo, delegating
through Portal/AiKA (read from spotify/portal-ai-plugins@3c24ca30ff63e1f5bbad1c43fe5324daff579123,
plugins/shunt/README.md — the accompanying blog post returns HTTP 403 from
this environment and was not read):
| Scenario | Lines | Without | With | Savings |
|---|---|---|---|---|
| Single large file | 4,014 | 33,684 | 5,737 | 82% |
| Source + test pair | 7,408 | 75,990 | 4,148 | 94% |
| Multi-file cross-service | 1,281 | 16,221 | 821 | 94% |
| Code-write | 3,667 | 40,614 + generation | 833 lines to disk | — |
Built from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.
npx claudepluginhub patiently/anti-tangent-mcp --plugin anti-tangent-shuntPlugins from other owners that cover similar ground