- Home
- Skills
- Code Quality & Review
- 💸 LLM Cost Leak Linter
More screenshots
Works with the AI Agents you already use
💸 LLM Cost Leak Linter
The problem LLM application code often contains hidden patterns that drain budgets before billing alerts trigger.
$12
💸 LLM Cost Leak Linter
Example session with this skill installed
Scan the src directory for potential LLM cost leaks and tell me if I am wasting tokens.
- Read your context and instructions
- Compiled the llm cost leak
Found 3 cost leaks:
- LCL002 (High): Loop in
chains.py:42calls gpt-4-turbo without a max_retries limit. - LCL005 (Med):
loaders.ts:12passes raw file buffer to prompt without truncation. - LCL003 (Low): Using gpt-4 for sentiment analysis on line 88; consider gpt-3.5-turbo.
Connects securely to your tools. The creator never sees your data.
About this skill
The problem
LLM application code often contains hidden patterns that drain budgets before billing alerts trigger. Developers lack automated ways to detect uncapped generations, expensive models used for trivial tasks, or inefficient prompting patterns during development.
What it does
- Scans source files for LLM calls lacking output caps or truncation logic.
- Identifies model calls inside loops or retry blocks without attempt limits.
- Flags expensive models used for high-frequency or simple tasks based on
model-pricing.json. - Detects instances where entire files are injected into prompts without preprocessing.
- Points out missing token usage logging and cost instrumentation.
Frameworks & tools
Supports Python, JavaScript, TypeScript, and React (JSX/TSX). Works with any LLM provider but requires manual updates to pricing reference files.
Why this beats prompting it yourself
Generic LLMs often miss specific architectural cost leaks like loop retry logic or missing backoff limits. This skill provides a structured heuristic scan that maps code patterns to specific cost-risk IDs rather than offering vague advice.
Use cases
- Pre-production audit of AI features to prevent runaway costs.
- Reviewing legacy LLM implementations for potential savings.
- Standardizing cost-conscious coding practices across a team.
Known limitations
This is a heuristic linter, not a runtime monitor. It identifies risky patterns but does not track real-world token usage or live expenditure.
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Code Quality & Review.
Heuristic. It flags cost-risk patterns for you to review. It does not measure your actual spend, count live tokens, or run your code, and it cannot confirm a fix works end to end. The expensive-model and cache checks are advisory. The model tiers and prices are only as current as the editable model-pricing.json you maintain. It reads code and structure, not runtime behavior.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 4 months ago
Permissions
File Scopes
This skill needs Read Files only. It reads your source files to scan for cost-leak patterns, and reads its own references/model-pricing.json for the model tiers. Findings are returned as text in the conversation. It does not write to disk, run shell commands, make network calls, or read environment variables or secrets.