Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Palm, Claude, Cohere, AI21, Aleph Alpha, Huggingface TGI #271

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

krrishdholakia
Copy link

@krrishdholakia krrishdholakia commented Sep 2, 2023

Hi @dandansamax @hychen-naza

This PR adds support for the models listed above using LiteLLM (https://github.com/BerriAI/litellm).

In addition, we also enable easy A/B testing of new LLM models in production:

https://docs.litellm.ai/docs/tutorials/ab_test_llms

Happy to add additional tests / update documentation, if the initial PR looks good to you.

@lightaime
Copy link
Member

Hi @krrishdholakia. Thanks for suggesting LiteLLM. It is very handy.
The only concern is the token_counting. It would be great if you could let me know how LiteLLM supports this.

@krrishdholakia
Copy link
Author

krrishdholakia commented Sep 9, 2023

Hey @lightaime - here's exactly how that works: https://docs.litellm.ai/docs/token_usage

code - https://github.com/BerriAI/litellm/blob/5ca8b23e22139a4f49bd0d4c1d5a2d4a70b49166/litellm/utils.py#L617

We'd welcome any suggestions / contributions if you see ways we can improve this

@lightaime
Copy link
Member

Hi @krrishdholakia. That looks great. However, I prefer not to depreciate openai api. I am fine with creating a model in https://github.com/camel-ai/camel/tree/master/camel/models for the LiteLLM wrapper. Let me know if you want to collaborate on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants