feat(litellm): add provider namespaces with legacy compatibility
This commit is contained in:
@@ -4,11 +4,11 @@ from pathlib import Path
|
||||
|
||||
import yaml
|
||||
|
||||
from provider_routes import build_config
|
||||
from provider_routes import build_config, namespace_config
|
||||
|
||||
|
||||
def build_hk_config(catalog, env):
|
||||
config = build_config(catalog, env, lambda path: False)
|
||||
config = build_config(catalog, env, lambda path: False, namespaced=False)
|
||||
config['general_settings'] = {'master_key': 'os.environ/LITELLM_MASTER_KEY'}
|
||||
routes = config['model_list']
|
||||
routes[:] = [route for route in routes if route['model_name'] != 'gemini-transcribe-personal']
|
||||
@@ -47,7 +47,7 @@ def build_hk_config(catalog, env):
|
||||
'model': 'vertex_ai/' + model,
|
||||
'vertex_project': 'os.environ/VERTEXAI_PROJECT',
|
||||
'vertex_location': 'os.environ/VERTEXAI_LOCATION'}})
|
||||
return config
|
||||
return namespace_config(config)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
Reference in New Issue
Block a user