mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-12 03:48:56 +00:00
Add tool calling support parameters on Gradient LLM
Added basic gradient ai tool call logic
This commit is contained in:
parent
d0330aa4e3
commit
ce9b3ff588
1 changed files with 8 additions and 0 deletions
|
|
@ -73,6 +73,11 @@ class GradientAIConfig(OpenAILikeChatConfig):
|
|||
"include_guardrails_info",
|
||||
"provide_citations",
|
||||
"retrieval_method",
|
||||
# Tool calling support
|
||||
"tools",
|
||||
"tool_choice",
|
||||
"parallel_tool_calls",
|
||||
"response_format"
|
||||
]
|
||||
return supported_params
|
||||
|
||||
|
|
@ -137,6 +142,9 @@ class GradientAIConfig(OpenAILikeChatConfig):
|
|||
for param, value in non_default_params.items():
|
||||
if param in supported_openai_params:
|
||||
optional_params[param] = value
|
||||
elif param in ["tools", "tool_choice", "parallel_tool_calls"]:
|
||||
# Allow explicitly if the params definition changes
|
||||
optional_params[param] = value
|
||||
elif not drop_params:
|
||||
from litellm.utils import UnsupportedParamsError
|
||||
raise UnsupportedParamsError(
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue