Skip to content

Commit

Permalink
fix(agents-api): Fix embedding model litellm error (#870)
Browse files Browse the repository at this point in the history
<!-- ELLIPSIS_HIDDEN -->



> [!IMPORTANT]
> Commented out a line in `aembedding()` in `litellm.py` to prevent
errors with `voyage/voyage-3` model.
> 
>   - **Behavior**:
> - Commented out line in `aembedding()` in `litellm.py` to prevent
errors with `voyage/voyage-3` model.
>     - The line `model = f"openai/{model}"` is temporarily disabled.
>   - **Misc**:
>     - No other changes or fixes are included in this PR.
> 
> <sup>This description was created by </sup>[<img alt="Ellipsis"
src="https://img.shields.io/badge/Ellipsis-blue?color=175173">](https://www.ellipsis.dev?ref=julep-ai%2Fjulep&utm_source=github&utm_medium=referral)<sup>
for 3d429be. It will automatically
update as commits are pushed.</sup>

<!-- ELLIPSIS_HIDDEN -->

---------

Co-authored-by: HamadaSalhab <[email protected]>
  • Loading branch information
HamadaSalhab and HamadaSalhab authored Nov 22, 2024
1 parent 26a3315 commit 5b63886
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions agents-api/agents_api/clients/litellm.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,9 @@ async def aembedding(
custom_api_key: None | str = None,
**settings,
) -> list[list[float]]:
if not custom_api_key:
model = f"openai/{model}" # FIXME: This is for litellm
# Temporarily commented out (causes errors when using voyage/voyage-3)
# if not custom_api_key:
# model = f"openai/{model}" # FIXME: This is for litellm

if isinstance(inputs, str):
input = [inputs]
Expand Down

0 comments on commit 5b63886

Please sign in to comment.