跳到正文
原文
Hacker News Show HN· llmbrake·· 27 天前AI 评分58

LLMBrake 发布:为 OpenAI/Anthropic API 调用设置按客户美元预算上限

Show HN: LLMBrake – Per-customer dollar caps for OpenAI/Anthropic API calls

AI 导读

LLMBrake 是一个 TypeScript 库,包装 OpenAI 兼容的 chat.completions.create 调用,按每个客户设置每月美元预算,接近预算时切换到更便宜的模型,达到预算时抛出 BudgetExceededError 并阻止请求发往供应商。

社媒成稿工作台 · 一键复制

飞书同步推送 · 含数据/日期/出处/启发
核心数据发布日期信源出处独立开发启发
1440
LLMBrake 发布:为 OpenAI/Anthropic API 调用设置按客户美元预算上限

📊 核心数据与事实(2026-11-06):
LLMBrake 是一个 TypeScript 库,包装 OpenAI 兼容的 chat.completions.create 调用,按每个客户设置每月美元预算,接近预算时切换到更便宜的模型,达到预算时抛出 BudgetExceededError 并阻止请求发往供应商。
• 原文实测切片:20 : 2 ) , // USD per customer per calendar month (UTC) downgradeAt : 0.8 , // at 80% of the budget...
• 原文实测切片:Model prices: verify before relying on them DEFAULT_PRICES covers a few common OpenAI and Anthropic models in USD per 1M tokens (standard tier), read on 2026-10-09 from: OpenAI: Anthropic: Provider prices change often, and these values are not…
• 原文实测切片:LLMBrake Cloud is the optional paid layer on top: shared counters ( HostedStore ), a dashboard with spend, budget and status per customer (edit budgets live), Slack/webhook alerts at 80% and 100%, and AI cost vs. Stripe revenue per customer.

💡 对独立开发者的启发:
1/ 写代码发新版是最舒服的「伪勤奋」——大多数独立开发项目零收入不是产品不行,而是压根没做分发。
2/ 任何一次上线流量都会自然衰减;在动手写第二个工具之前,先给第一个产品建好可持续获客漏斗(SEO 长尾词、Reddit 真实复盘、社媒切片)。
3/ 把 80% 精力放分发和落地页首屏转化上:先靠单点高痛点工具跑出稳定现金流,再谈矩阵放大。

📅 日期:2026-11-06(北京时间)
📰 信息源出处:Hacker News Show HN · llmbrake(github.com)
🔗 原文:https://github.com/llmbrake/llmbrake
📡 归档:https://billionare.me/items/dnznobslhj97tqbiui0k2a4b3
去 X 发推
每天 08:00 邮件 / 08:30 飞书准点推送一手高信噪比情报与拆解免费订阅简报

来源:Hacker News Show HN · github.com