Skip to content

zerogpu/zerogpu-router

Repository files navigation

ZeroGPU

ZeroGPU Router

Cut inference costs without dumbing down your agent.
Route summarize, classify, PII redaction, JSON extraction, and short chat to small/nano models via the zerogpu CLI — executed locally by your agent's Bash tools.

Open ZeroGPU platform   Open ZeroGPU platform

GitHub stars License Beta OpenClaw Claude Code Website

What is ZeroGPU Router?

ZeroGPU Router is a smart task router for AI agents. It exposes task-specific skills — summarize, classify, redact PII, extract JSON, and more — that shell out to the local zerogpu CLI, backed by small language models that run for a fraction of the cost of a frontier model.

Your agent keeps doing the heavy reasoning. The boring stuff gets routed to ZeroGPU.

  • OpenClaw — install the zerogpu CLI plus zerogpu-router (see agents/openclaw/). Skills run locally through your agent's Bash tools.
  • Claude Code — install the zerogpu CLI plus the marketplace plugin and you get 11 auto-invoked skills plus a cost-savings readout (see agents/claude/).
  • Cheap by default — small models for trivial work, frontier model untouched for everything else.
  • Per-call savings — every routed task returns model, latency, and a real savings_usd figure.
  • CLI, no infra — everything runs through the local zerogpu CLI your agent already calls. No servers, MCP endpoints, or infra to stand up.

OpenClaw quick start

You need a ZeroGPU API key. Grab it at platform.zerogpu.ai.

1. Install the OpenClaw plugin (zerogpu-router):

openclaw plugins install clawhub:zerogpu-router

The plugin's skills provision the zerogpu CLI automatically on first use (via a node install spec), so there's no separate global install — you just need a package manager (npm by default) available.

2. Authenticate:

zerogpu login

You'll be prompted for your API key (zgpu-api-…).

Pin a release: clawhub:zerogpu-router@2.0.0.

4. Try it:

summarize this account note: Renewal call with Acme Corp went well overall. They
are happy with uptime but frustrated by slow support response times over the last
two months. Their VP hinted at evaluating a competitor if the SLA does not improve
before the December renewal. They also asked about volume pricing for a second
team of about 40 seats. Action items: loop in support leadership and send an
updated enterprise quote by Friday.

The agent runs the summarize skill — which executes zerogpu summarize locally via its Bash tool — and returns a concise, slightly mechanical summary plus a savings line, for example:

Positive Acme Corp renewal call — happy with uptime, frustrated by slow support
the last two months. VP may evaluate a competitor if the SLA does not improve
before the December renewal; also asked about volume pricing for ~40 more seats.
Next: loop in support leadership, send an updated enterprise quote by Friday.

💰 ZeroGPU savings so far: $1.87 (16,320 Claude tokens offloaded)

Claude Code quick start

The Claude Code plugin ships 14 skills — 11 inference skills that Claude auto-invokes when your request matches ("summarize this", "redact the PII", "classify by sentiment and topic"), plus the manual signin, status, and cost-savings skills. You can also call any skill manually with /zerogpu-router:<name>. Run /zerogpu-router:cost-savings anytime to see how much you've saved by routing trivial work to ZeroGPU.

Grab a ZeroGPU API key at platform.zerogpu.ai, then:

1. Install the zerogpu CLI (the plugin shells out to it):

npm install -g zerogpu-cli

2. Authenticate:

zerogpu login

You'll be prompted for your API key (zgpu-api-…).

3. Install the Claude Code plugin — start a Claude Code session by running claude in your terminal, then:

/plugin marketplace add zerogpu/zerogpu-router
/plugin install zerogpu-router@zerogpu
/reload-plugins

4. Try it:

Redact PII from this support ticket before I paste it into our public bug tracker:

Hi team — this is Sarah Chen (sarah.chen@northwind-labs.com, +1 415-555-0182).
Our prod database started throwing connection timeouts around 2:14 AM PT last
night. The on-call engineer Marcus Rivera (slack: @mrivera) restarted the
pgbouncer pod but the issue came back within 20 minutes. Billing should go to
our CFO Priya Patel at priya.patel@northwind-labs.com, billing address 1455
Market St, Suite 600, San Francisco, CA 94103. Please call me back at the
number above.

Claude routes to /zerogpu-router:redact-pii automatically and returns the same passage with names, emails, phone numbers, social handles, and street addresses replaced by uppercase label placeholders like [PERSON], [EMAIL], [PHONE_NUMBER], [ADDRESS] — safe to paste into a public tracker. The gliner-multi-pii-v1 edge model does the masking, not Claude, so the raw PII never enters Claude's context window.

The model is tuned for the standard PII categories above. Project-specific identifiers (internal hostnames, IPs, contract numbers, card last-fours) won't be caught — strip those yourself, or pipe the result through /zerogpu-router:extract-entities with your own custom labels.

Full walkthrough — prerequisites, every skill documented in detail, troubleshooting: agents/claude/README.md.

Routes

ZeroGPU Router exposes eleven task-specific routes:

Route Workload Model
zerogpu_classify_iab IAB topic classification zlm-v1-iab-classify-edge
zerogpu_classify_iab_enriched IAB categories plus topics, keywords, intent zlm-v1-iab-classify-edge-enriched
zerogpu_summarize TL;DRs, abstracts, meeting note summaries llama-3.1-8b-instruct-fast
zerogpu_classify_zero_shot Classify against a flat label list deberta-v3-small
zerogpu_classify_structured Multi-axis schema classification gliner2-base-v1
zerogpu_extract_entities Extract people, places, companies, dates, custom entities gliner2-base-v1
zerogpu_extract_json Pull structured fields into grouped JSON gliner2-base-v1
zerogpu_redact_pii Mask emails, phones, names, addresses, other PII gliner-multi-pii-v1
zerogpu_extract_pii Extract PII grouped by category gliner-multi-pii-v1
zerogpu_chat Short small-model chat replies LFM2.5-1.2B-Instruct
zerogpu_chat_thinking Short chat replies with a visible reasoning trace LFM2.5-1.2B-Thinking

Every route returns { <task fields>, model, usage, savings }.

Packages

Package Role
agents/openclaw/ OpenClaw: zerogpu-cli + package/plugin id zerogpu-router + CLI-based skills
agents/claude/ Claude Code: zerogpu-cli + marketplace plugin (/plugin install zerogpu-router@zerogpu)

Quick Links

About

Cut inference costs without dumbing down your agent.

Resources

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages