-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Use LiteLLM DB for determining model tool capability #4698
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
Conversation
@emerzon is attempting to deploy a commit to the Danswer Team on Vercel. A member of the Team first needs to authorize it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Summary
This PR updates the model tool capability detection by leveraging LiteLLM's database instead of hardcoded lists, enabling support for newer AI models to use native tools.
- Replaced hardcoded
OPEN_AI_TOOL_CALLING_MODELS
with dynamic lookup inbackend/onyx/tools/utils.py
usingsupports_function_calling
attribute - Updated LiteLLM from 1.66.3 to 1.69.0 in both requirements files to support the new functionality
- Implementation in
explicit_tool_calling_supported()
now usesget_model_map()
and_find_model_obj()
for more flexible model support
3 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great, thanks @emerzon!
* Bump LiteLLM * Use LiteLLM DB for determining model tool capability instead of using hardcoded list * Make function defaults explicit
* Bump LiteLLM * Use LiteLLM DB for determining model tool capability instead of using hardcoded list * Make function defaults explicit
* Bump LiteLLM * Use LiteLLM DB for determining model tool capability instead of using hardcoded list * Make function defaults explicit
* Bump LiteLLM * Use LiteLLM DB for determining model tool capability instead of using hardcoded list * Make function defaults explicit
Description
Use LiteLLM DB for determining model tool capability instead of using a hardcoded list.
This enables newer models (Ie.
gpt-4.1
,gemini-2.5
) to use native tools.How Has This Been Tested?
Checked new models now can execute tools.