llm-cost-optimizer
构建 LLM 功能或讨论其成本时使用,涵盖模型选择、提示词缓存、token 限额和单功能支出。在上线前设置路由、缓存、max_tokens 和成本日志,而非收到账单后再处理。
译文已校对查看英文原文
Use whenever an LLM feature is being built or its costs come up (model choice, prompt caching, token limits, per-feature spend). Sets routing, caching, max_tokens and cost logging before launch rather than after the bill.
适用对象:AI 与流程自动化。自动收录 · 待核查。
原作者说明节选
从固定版本的 SKILL.md 提取,保留原文语言。以下内容属于作者说明,本站尚未验证安装、兼容或运行结果。
查看英文原文
原文涵盖的主题
- LLM Cost Optimizer
- Step 0: Classify Before You Ask
- Context You Need
- Mode 1: Cost Audit
- Mode 2: Optimize Existing System
- 1. Model Routing (60–80% cost reduction on routed traffic)
- 2. Prompt Caching (40–90% reduction on cacheable traffic)
- 3. Output Length Control (20–40% reduction)
You are an expert in LLM cost engineering with deep experience reducing AI API spend at scale. Your goal is to cut LLM costs by 40–80% without degrading user-facing quality -- using model routing, caching, prompt compression, and observability to make every token count. AI API costs are engineering costs. Treat them like database query costs: measure first, optimize second, monitor always. -- Before gathering context, classify which mode applies based on what the user has already said. Pull answers from the conversation first -- don't ask for what you already have. | Mode | When to use | |---|---| | Cost Audit | Spend exists but no clear picture of where it goes | | Optimize Existing System | Cost drivers are known; apply targeted fixes | | Design Cost-Efficient Architecture | Building new AI features; wire in cost controls before launch | If the mode is ambiguous, ask in one shot using the context questions below. Only ask what you don't already know. -- Current State Which LLM providers and models are in use? Monthly spend? Which features/endpoints drive it? Token usage logging in place? Cost-per-request visibility? Goals Target cost reduction? (e.g., "cut 50%", "stay under $X/mo
这里只展示节选,请以完整原文和当前要求为准。
- 来源仓库
- alirezarezvani/claude-skills
- 源文件
- engineering/llm-cost-optimizer/skills/llm-cost-optimizer/SKILL.md
- 固定版本
- 8f082544116fc0d014188e521ca40304cdfc86b0
来源与内容状态
本条为自动发现的元数据,尚未完成人工文档核查;适用性与运行结果待核查。
原作者:alirezarezvani/claude-skills · 原作者仓库元数据。文档核查:未核查。最近来源检查:2026-11-09T14:01:46.690Z。
分类由名称、说明与路径规则生成,分类不代表已核实适配。
许可与权利归属
MIT。第三方内容及版权归原作者,使用条件以原文为准。
许可原文 ↗本站没有因同步、复制或用户自报成功而将资源标为运行验证通过。
限制与注意事项
- 元数据收录不代表本站已经安装、适配、实测或进行安全审查。