mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-26 11:14:04 +00:00
(fix) use deepcopy for model list
This commit is contained in:
parent
ac91543848
commit
5e9286ed41
1 changed files with 2 additions and 0 deletions
|
@ -17,6 +17,7 @@ import inspect, concurrent
|
|||
from openai import AsyncOpenAI
|
||||
from collections import defaultdict
|
||||
from litellm.router_strategy.least_busy import LeastBusyLoggingHandler
|
||||
import copy
|
||||
class Router:
|
||||
"""
|
||||
Example usage:
|
||||
|
@ -81,6 +82,7 @@ class Router:
|
|||
self.set_verbose = set_verbose
|
||||
self.deployment_names: List = [] # names of models under litellm_params. ex. azure/chatgpt-v-2
|
||||
if model_list:
|
||||
model_list = copy.deepcopy(model_list)
|
||||
self.set_model_list(model_list)
|
||||
self.healthy_deployments: List = self.model_list
|
||||
self.deployment_latency_map = {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue