install

A guided installer for TokenWise, a Claude Code add-on that routes different task types to different AI models. It checks the Claude Code version and existing configuration before proposing changes.

In plain words
What is it for?
Use it to configure routing rules in global or project CLAUDE.md files and settings.json. It can detect compatibility issues, preview changes, install them, or print instructions for manual installation.
Why use it?
It reduces the risk of overwriting useful settings by showing proposed differences, creating backups, and asking for confirmation per file. A dry run or manual mode lets you inspect or copy the changes without writing them.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/codeshux/tokenwise/install
Any agent
npx skills add CodeShuX/tokenwise --skill install
Clone the repo
git clone --depth 1 https://github.com/CodeShuX/tokenwise

Made for: Claude Code, Codex.

Per session 95 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,803 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00095 $0.02803
Opus 5 $0.00048 $0.01401
Sonnet 5 $0.00019 $0.00561
Haiku 4.5 $0.00010 $0.00280

Measured yesterday against content hash 0eac95277aa8, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade B, and why

install scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

- `~/.claude/settings.json` — note "missing" if absent
skills/install/SKILL.md · 241 lines

How it starts

The opening of the file, as written. The whole thing — 241 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/tokenwise:install — Configure model routing

You are the TokenWise installer. Walk the user through Phase 1 (Detect) and Phase 2 (Configure) of the TokenWise lifecycle.

Parse $ARGUMENTS

$ARGUMENTS may contain:

  • --guided — force guided mode (default if not detected as power user)
  • --manual — print copy-paste blocks, exit without writing
  • --dry-run — show all proposed changes without writing OR printing copy-paste

If empty or contains --guided, run guided mode. If --manual, run manual mode. If --dry-run, run guided flow but skip every write step — print "DRY RUN: would write to " instead.

Phase 1 — Detect

Print a header:

TokenWise Install — Phase 1: Detect
====================================

Do these checks (use Read and Bash tools):

  1. Read existing configs:

    • ~/.claude/CLAUDE.md (global) — note "missing" if absent
    • ./CLAUDE.md (project, if cwd is a git repo) — note "missing" if absent
    • ~/.claude/settings.json — note "missing" if absent
  2. Claude Code version: run claude --version via Bash. Record output.

  3. Subagent routing probe (Anthropic Issue #47488 regression test):

    • Spawn a probe Task at Haiku tier: Task(description: "probe", subagent_type: "general-purpose", model: "haiku", prompt: "Return only the string TOKENWISE_PROBE_OK")
    • If the response contains TOKENWISE_PROBE_OK, routing works. If not, mark probe as FAILED.
    • Note: if your Task tool doesn't support model:, or you have no Task tool available at all in this session, mark as "routing probe: unverifiable on this build" and proceed the same way — this is not a FAILED result and doesn't block install.
  4. Env-var probe (Anthropic Issue #36381):

    • Run bash -c 'CLAUDE_AUTOCOMPACT_PCT_OVERRIDE=80 env | grep CLAUDE_AUTOCOMPACT'
    • If output contains the override, env vars are honored. Note as "env-var probe: OK".
  5. Inventory existing skills/hooks by listing ~/.claude/plugins/cache/*/ directories — note any that look like routing or token-tracking tools.

Read the full file on GitHub · 241 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 241 lines · 95 tokens per session scan B 0eac95277aa8

Subscribe to this mod's changes

install is a skill published in the GitHub repository CodeShuX/tokenwise (3 stars, last pushed 6d ago), licensed MIT. It adds 95 tokens to every session and 2,803 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

archify

Create polished, validated architecture, workflow, sequence, data-flow, and lifecycle/state diagrams as explorable standalone HTML with inline SVG, dark/light themes, optional trace motion, and PNG/JPEG/WebP/SVG/WebM export. Accept plain-language requirements or pasted Mermaid flowchart, sequenceDiagram, and…

tt-a1i/archify · 130 tokens

vox-director

Turn ONE topic into a finished Vox-style paper-collage explainer / ad video, end to end on the Atlas Cloud API + local ffmpeg — script, collage keyframes, motion, voice-over, music, captions, all automated. Use this whenever the user wants a "Vox style" video, a paper/torn-paper collage animation, a "motion collage"…

Alisa0808/vox-director · 236 tokens

social-post

學習使用者的 Facebook/Instagram/YouTube/Threads/X 語氣與受眾,規劃、撰寫、確認後發佈內容;以已登入 Chrome 受控掃描、草擬及回覆 FB/IG/Threads 留言;並作為流量、留存與轉化的結構化帳本。使用者說「發文」「用我的口氣」「回覆留言」「自動回留言」「掃留言」「查流量」「演算法」「把數據訓練進去」「比較貼文」「優化 pattern」時使用。.

Hao0321/claude-skill-social-post · 135 tokens

privacy-jp

日本サービス向け(일본 서비스용) プライバシーポリシー・利用規約・同意モーダル・Cookieバナー 자동 생성. 個人情報保護法(APPI)·消費者契約法·特定商取引法 반영. Next.js 1316 프로젝트 대상.

kimlawtech/korean-privacy-terms · 74 tokens

higgsfield

Use this skill whenever the user asks anything about Higgsfield AI — writing or refining video/image prompts, choosing a model (Kling, Sora 2, Veo, Wan, Seedance, Minimax Hailuo, DoP, Soul, Nano Banana, Seedream, Flux, GPT Image, etc.), camera controls, named motion presets, Soul ID character consistency, Cinema…

OSideMedia/higgsfield-ai-prompt-skill · 147 tokens

higgsfield-camera

Use when the user asks about camera movements, shot types, or how to describe camera behavior in a Higgsfield prompt. Contains all named camera controls with descriptions, best use cases, and example prompt phrases.

OSideMedia/higgsfield-ai-prompt-skill · 47 tokens