mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-08 03:08:45 +00:00
fix(ollama): keep routing suppression on assignment line
This commit is contained in:
parent
3f69357104
commit
fc9ee293e2
1 changed files with 1 additions and 3 deletions
|
|
@ -5310,9 +5310,7 @@ def completion(
|
|||
if custom_llm_provider == "ollama" and (tools or functions):
|
||||
custom_llm_provider = "ollama_chat" # rebind-ok: /api/generate has no native tool calling
|
||||
if api_base is not None:
|
||||
api_base = api_base.rstrip("/").removesuffix(
|
||||
"/api/generate"
|
||||
) # rebind-ok: preserve generate URLs for native tool requests
|
||||
api_base = api_base.rstrip("/").removesuffix("/api/generate") # rebind-ok: chat path
|
||||
elif custom_llm_provider == "ollama":
|
||||
tools = None # rebind-ok: empty tools must not change plain completion behavior
|
||||
functions = None # rebind-ok: empty functions must not change plain completion behavior
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue