forked from phoenix/litellm-mirror
(fix) proxy: /embeddings
This commit is contained in:
parent
5c18771f9d
commit
486037ff8b
1 changed files with 2 additions and 2 deletions
|
@ -625,8 +625,8 @@ async def embeddings(request: Request):
|
||||||
router_model_names = [m["model_name"] for m in llm_model_list] if llm_model_list is not None else []
|
router_model_names = [m["model_name"] for m in llm_model_list] if llm_model_list is not None else []
|
||||||
if llm_router is not None and data["model"] in router_model_names: # model in router model list
|
if llm_router is not None and data["model"] in router_model_names: # model in router model list
|
||||||
response = await llm_router.aembedding(**data)
|
response = await llm_router.aembedding(**data)
|
||||||
else:
|
else:
|
||||||
response = litellm.aembedding(**data)
|
response = await litellm.aembedding(**data)
|
||||||
return response
|
return response
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
traceback.print_exc()
|
traceback.print_exc()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue