# token-efficiency

Sets token-saving habits for Claude Code by prioritizing bash filtering, minimal terminal outputs, and targeted file reads.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode · 2500 installs · ★ 22
- Author: Delphine-L
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/Delphine-L/claude_global/tree/HEAD/skills/claude-meta/token-efficiency/SKILL.md
- Updated: 2026-05-14
- HTML: https://affpapa.org/en/nevibecode/skills/token-efficiency

## What it does

The skill embeds practical token-saving guardrails into the agent's workflow. Instead of loading whole files into context, the agent defaults to tools like `grep`, `tail`, `wc -l`, or `jq`. For simple line substitutions, appends, and file copies, the instructions require direct commands such as `sed` and `cp` instead of reading text into memory.

It outlines a model selection pattern: use Opus for initial repository architecture review, then switch to Sonnet for development and debugging. This model split cuts token expenses by around 50% compared to running Opus continuously.

The bash-first rule intentionally yields when editing source code like `.py`, `.js`, or `.tsx`. Whenever diff clarity matters or syntax validation is crucial, the agent switches back to standard file read and edit tools.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add Delphine-L/claude_global --skill token-efficiency -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/token-efficiency/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/token-efficiency/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add Delphine-L/claude_global --skill token-efficiency -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/token-efficiency/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add Delphine-L/claude_global --skill token-efficiency -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/token-efficiency/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install Delphine-L/claude_global token-efficiency
```

2. **Manually: put the files in place**
- File: `.github/skills/token-efficiency/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add Delphine-L/claude_global --skill token-efficiency -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/Delphine-L/claude_global --path skills/claude-meta/token-efficiency
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/token-efficiency/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add Delphine-L/claude_global --skill token-efficiency -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/Delphine-L/claude_global/tree/HEAD/skills/claude-meta/token-efficiency/SKILL.md

## When to use it
- cut token burn during codebase exploration
- inspect structured data and logs using CLI filters instead of context dumps
- split workloads between Opus and Sonnet to reduce spending
- suppress noisy terminal outputs with quiet flags

## Example prompts
- Check app.log for recent errors without dumping the full file
- Inspect metadata in data.json using bash tools
- Summarize the architecture of src under token-efficiency guidelines

## Similar
- [token-optimizer](https://affpapa.org/en/nevibecode/skills/token-optimizer.md) — skill · 976 installs
- [context-optimization](https://affpapa.org/en/nevibecode/skills/context-optimization.md) — skill · 356 installs
- [hedera-token-service](https://affpapa.org/en/nevibecode/skills/hedera-token-service.md) — skill · 547 installs
- [cost-summary](https://affpapa.org/en/nevibecode/skills/cost-summary.md) — skill · 683 installs
- [tax-efficiency](https://affpapa.org/en/nevibecode/skills/tax-efficiency.md) — skill · 690 installs
- [caveman-compress](https://affpapa.org/en/nevibecode/skills/caveman-compress.md) — skill · 411500 installs

## Other versions with the same name
- [token-efficiency · superclaude-org](https://affpapa.org/en/nevibecode/skills/superclaude-org-token-efficiency.md) — ★ 23911

From the same set: [delphine-l/claude_global](https://affpapa.org/en/nevibecode/by/delphine-l/claude_global.md) — 2 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
