Inference API budget, billing limit

Hi, it would be nice to be able to limit inference API spending.

I like the simple OpenAI system: soft and hard limit.

Would be useful, especially when someone makes the mistake of an infinite loop calling the API :stuck_out_tongue:

12 Likes

Second this - a hard limit to billing would be fantastic

3 Likes

Actually hard and soft limit, i.e. to get warnings after exceeding soft limit (so one can e.g. reconsider budget, change app usage or whatever e.g. to stay operational, or increase hard limit before it kicks in) , and ofc hard limit for safety reasons!

3 Likes

Yes to both - I’d feel safer knowing I’d get en email notification if an improperly configured experiment starts blowing through our budget.

2 Likes

This feature is definitely overdue

5 Likes

Think how easy it is to implement ‘if expense > limit then stop & send email’… it’s not an oversight.

2 Likes

Any news on this front? The lack of a billing limit makes me afraid to use HF Spaces as a private user. What if my apps go viral and I have to pay hundreds to thousands of dollars?

2 Likes

Yes, I agree. I want to build a public app and this is an essential feature.

3 Likes

HF can you please implement this already???

1 Like

April 2025 and still looking for this feature.

How is this not a thing…

1 Like

Not limited to inference, but it seems like a $100 circuit breaker (variable) has been included by default for the past year or so…

I only have a Pro subscription, so I haven’t actually tried it to see if it works…

Hi @John6666, @FilippTrigub, and @im93! This feature now exists for Enterprise Hub organizations for Inference Providers billing! You can check out what setting a limit looks like in the screenshot here: Pricing and Billing.

For more info and to subscribe to Enterprise Hub, head here: Enterprise Hub - Hugging Face.

1 Like