How much would HuggingFace cost as compared to OpenAI for GPT? How would you compare the two pricing models?

Daemon

Regular Member
Joined
Dec 31, 2009
Messages
209
Reaction score
79
I am confused on how to compare the pricing of OpenAI and HuggingFace. HuggingFace says they charge $50 per million input words. OpenAI charges per 1K tokens, which I think is about 800 words.

HuggingFace:
HuggingFace pricing.jpg
OpenAI:
OpenAI pricing.jpg
How exactly should one compare this pricing to OpenAI, which charges per token? I don’t know exactly how to compare these two different pricing structures.

This is just a guess and correct me if I'm wrong, but I would guess that the parallels between EleutherAI GPT and OpenAI are like:
  • GPT Neo 125M - Ada
  • GPT Neo 1.3B - Babbage
  • GPT Neo 2.7B - Curie
  • GPT-J 6B - Davinci
Also I'm not sure how the pricing might differ based on use case. For instance if you were using HuggingFace for Pegagus to paraphrase existing content, and OpenAI to paraphrase. How that pricing might differ from using HuggingFace and OpenAI for article creation.

Does anyone know how one should compare these two in terms of pricing, and how in practice HuggingFace might cost for use with models like GPT and Pegasus, as compared to OpenAI for content generation and paraphrasing? For paraphrasing you need to pass the original content as input, so assuming an article is a thousand words, HuggingFace would cost $50 for 1K articles or $0.05 per article. OpenAI Ada would cost $0.001 per article (assuming 1250 tokens per article) and $0.075 for Davinci. Is my math correct there?

How would they compare for content generation based on an input phrase?

https://huggingface.co/pricinghttps://openai.com/api/pricing/
 
Why don't you go ahead and generate a 1000 word long article with both and then check the credits or whatever spent?
 
Why don't you go ahead and generate a 1000 word long article with both and then check the credits or whatever spent?
That's probably a good way to benchmark or A/B test the consumption.

also I'm following OP, this question has also been tickling my mind... I need insight hehe.
 
I am confused on how to compare the pricing of OpenAI and HuggingFace. HuggingFace says they charge $50 per million input words. OpenAI charges per 1K tokens, which I think is about 800 words.

HuggingFace:
View attachment 215012
OpenAI:
View attachment 215013
How exactly should one compare this pricing to OpenAI, which charges per token? I don’t know exactly how to compare these two different pricing structures.

This is just a guess and correct me if I'm wrong, but I would guess that the parallels between EleutherAI GPT and OpenAI are like:
  • GPT Neo 125M - Ada
  • GPT Neo 1.3B - Babbage
  • GPT Neo 2.7B - Curie
  • GPT-J 6B - Davinci
Also I'm not sure how the pricing might differ based on use case. For instance if you were using HuggingFace for Pegagus to paraphrase existing content, and OpenAI to paraphrase. How that pricing might differ from using HuggingFace and OpenAI for article creation.

Does anyone know how one should compare these two in terms of pricing, and how in practice HuggingFace might cost for use with models like GPT and Pegasus, as compared to OpenAI for content generation and paraphrasing? For paraphrasing you need to pass the original content as input, so assuming an article is a thousand words, HuggingFace would cost $50 for 1K articles or $0.05 per article. OpenAI Ada would cost $0.001 per article (assuming 1250 tokens per article) and $0.075 for Davinci. Is my math correct there?

How would they compare for content generation based on an input phrase?

https://huggingface.co/pricinghttps://openai.com/api/pricing/

OpenAI's GPT-3 Babbage is speculated (because there is no official statement from OAI) to have 6.7 Billion parameters. So, it would be the equivalent of EleutherAI's GPT-J 6B.
GPT-3 Curie should come with 13 Billion parameters.
Eleuther AI also released GPT-NeoX - 20 Billion Parameters
GPT-3 Davinci (175B) has no equivalent yet in the EleutherAI's range of models but it can be compared with HF BLOOM (176B) and AI21's J1 Jumbo (178B).

But the parameters are not the most important thing. For example, a fine-tuned version of GPT-J 6B can easily beat the standard GPT-3 Davinci when performing the task for which it (GPT-J) has been fine-tuned.
As a general rule, don't use any pre-trained model in its standard configuration. Fine-tune/ train it with a serious data set in order to get the best results on your specific task.

As far as I know it's not yet possible to fine-tune with Huggingface Autotrain any of the EleutherAI's models (but I don't really have the latest updates from Huggingface so don't take my word here).
Also, I can't advise you on the Huggingface pricing because I haven't used their API, but my impression was that it's quite expensive. The same feeling I have about OpenAI's pricing. The cheapest option would be to just use the open sourced models (from EleutherAI, for example) on your own/ rented infrastructure.
 
HuggingFace says $50 per million characters, not words. So if you have 4 characters per word on average and 1k words per article that's $50/250 articles or $0.20 per article
 
Back
Top