mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 18:54:30 +00:00
(fix) ensure stop is always a list for anthropic
This commit is contained in:
parent
f194268b80
commit
91e2aebe8c
1 changed files with 2 additions and 0 deletions
|
@ -1090,6 +1090,8 @@ def get_optional_params( # use the openai defaults
|
||||||
if stream:
|
if stream:
|
||||||
optional_params["stream"] = stream
|
optional_params["stream"] = stream
|
||||||
if stop:
|
if stop:
|
||||||
|
if type(stop) == str:
|
||||||
|
stop = [stop] # openai can accept str/list for stop
|
||||||
optional_params["stop_sequences"] = stop
|
optional_params["stop_sequences"] = stop
|
||||||
if temperature:
|
if temperature:
|
||||||
optional_params["temperature"] = temperature
|
optional_params["temperature"] = temperature
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue