mrdulasolutions/tokenclinic/token-clinic
Claude Code and agent skill by mrdulasolutions/tokenclinic
- community
Checking that the SKILL.md file is still in the repository.
Pre-flight gate before editing code. Runs cheap on-device analysis first and returns high-signal findings with tight context packets, so the model fixes real problems instead of crawling the repo to rediscover them. Use BEFORE starting a fix/refactor/cleanup pass on a TypeScript project, or when asked to "clean up", "fix the errors", "lint", or "tighten up" a codebase.
Install
npx vskill@latest install mrdulasolutions/tokenclinic/token-clinicSKILL.md
Token Clinic — pre-flight gate
Token Clinic does the cheap, deterministic work on-device before you spend model tokens: it runs the type checker plus the repo's promoted local rules, eliminates what it can for $0, and hands you a tight packet for each remaining problem. It does not call a model — you do the reasoning fixes, with your own model, from the packets it gives you. That's the point: don't pay a premium model to find a missing import a local tool already found.
When to use
Before any multi-file fix, refactor, lint, or "clean this up" pass on a TypeScript project. Run it first; act on its output; don't re-derive its findings.
How to run
(If tokenclinic isn't on PATH, run from the repo: bun run /path/to/TokenClinic/src/cli.ts scan <path> --json.)
This prints a JSON report and makes no API calls. Parse it and act on advice.
What the report means
What to do with it
- `advice.escalate` is your work list. Fix each one using its
context.snippet
— do not open and re-read the whole file or crawl the repo; the packet is the context you need. The recommendedModel tells you how hard Token Clinic judged the fix (mechanical → cheap, semantic → mid, architectural → top); use it to calibrate effort, not to switch models mid-session.
- `advice.autoApply` (the `local` lane) are $0 mechanical/promoted-rule hits.
Apply them directly if trivial and in scope; otherwise mention them — they don't warrant deep reasoning.
- Report the `eob` (e.g. "41 fixed locally for $0, 6 escalated, ~$0.40 saved
vs. crawling the repo") so the user sees what the pre-flight saved.
- Re-run `scan --json` after your fixes to confirm the findings are gone.
Notes
scanand--jsonare read-only and free; they never call a model.- For a recurring class of finding,
tokenclinic learn <path>(needs an API key)
amortizes it into a local rule so it's caught for $0 on every future scan.
- Standalone (outside this harness)
tokenclinic scan <path> --applywill do the
fixes itself with its own key — but inside a harness, prefer --json and fix with your own model, so spend and credentials stay on the harness's account.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskill/token-clinic/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/mrdulasolutions/tokenclinic/token-clinic)