LiteLLM: List all LLM Providers and Models
I was just playing around with different LLMs for creating an application to use chat app with your own keys. More on that later (you would find it next week)
But the thing I was blown away by was the sheer amount of providers and their models.
There are till date 931 variations of models supported by LiteLLM.
NOTE:
These models might be duplicate and have different provider and infrastructure
Some of the models are deprecated and older
This is not inclusive of the Local LLM models that you can run, because LiteLLM gives the ollama name convention support and most of the models will just work out of the box
So taking those into consideration, below is the snippet that can list the number of providers and their models respectively.
# !pip install litellm
from litellm import models_by_provider
providers = list(models_by_provider.keys())
print(len(providers))
# 51
models = [model for models in models_by_provider.values() for model in models]
print(len(models))
# 931
That is a crazy number. I have barely lived that many days. If you want another analogy.
Count the number of days between today and the day when ChatGPT launched, its barely 1000 days.
If my math is correct, people (AI Engineers are nuts) have almost launched a model every day. That is insane.
It feels so old that we believed that ChatGPT with GPT-3.5-turbo was not going to do anything beyond text completion. But years passed and now we have
Function/Tool Calling
(Almost perfect) Image and Video generation
LLMs with scratchpad (reasoning, some think its useless, but I think its interesting)
Local Models (not quite the state of the art, but improving significantly day by day)
We have come a long way and its just been 2 years!
Back to LiteLLM,
We can't just list providers and models we can definitely call any of them (provided api keys wherever needed) and get a idea of what the model is about.
Let's explore further
Back to exploring this interesting transformer mamoths.