From llm-observability
Diagnoses and reduces LLM API costs using observability data. Finds expensive spans, applies context trimming, model right-sizing, caching, and retry fixes. Guards against quality regressions.
How this skill is triggered — by the user, by Claude, or both
Slash command
/llm-observability:reduce-llm-costThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Most LLM bills are dominated by a few patterns you can *see* in traces. Measure before optimizing - the biggest cost is rarely where people assume.
Most LLM bills are dominated by a few patterns you can see in traces. Measure before optimizing - the biggest cost is rarely where people assume.
From your observability tool, sort spans by cost (or input_tokens). You're looking for:
If you have no cost data yet, add tracing first (see instrument-llm-observability) - you can't optimize what you can't see.
max_tokens. Unbounded outputs cost unbounded money; set a sane ceiling.Retry-After; a backoff bug can 10× cost silently.Every cost cut is a potential quality regression. Gate changes with an eval suite (see add-llm-evals): make the cheap change, run evals, keep it only if quality holds. Then watch cost + quality together on a dashboard so a future change doesn't silently trade one for the other.
monthly_cost_of_a_span = per_call_tokens × price × calls_per_month. Optimize the span with the biggest product, not the one that looks expensive per call.
npx claudepluginhub contextjet-ai/awesome-llm-observability --plugin llm-observabilityMonitor and optimize LLM costs using Langfuse analytics. Provides instructions for token usage capture, cost queries via Metrics API, and budget alerts.
Implements comprehensive observability for LLM applications including tracing (Langfuse/Helicone), cost tracking, RAG evaluation (RAGAS), and hallucination detection.
Audits and reduces AI agent token and inference spend through context discipline, prompt caching, model routing, batching, and workflow capture.