From 250fc3013f40c6cb2a52777dae3e4665c6e4eed8 Mon Sep 17 00:00:00 2001 From: Dmitry Paramonov Date: Mon, 6 May 2024 19:25:53 +0300 Subject: [PATCH] fix: Embed with custom model --- agents-api/agents_api/routers/sessions/session.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/agents-api/agents_api/routers/sessions/session.py b/agents-api/agents_api/routers/sessions/session.py index 02fd66791..e71d53871 100644 --- a/agents-api/agents_api/routers/sessions/session.py +++ b/agents-api/agents_api/routers/sessions/session.py @@ -19,7 +19,11 @@ from ...common.protocol.entries import Entry from ...common.protocol.sessions import SessionData from ...common.utils.template import render_template -from ...env import summarization_tokens_threshold +from ...env import ( + summarization_tokens_threshold, + docs_embedding_service_url, + docs_embedding_model_id, +) from ...model_registry import ( JULEP_MODELS, get_extra_settings, @@ -201,6 +205,8 @@ async def forward( ] ], join_inputs=False, + embedding_service_url=docs_embedding_service_url, + embedding_model_name=docs_embedding_model_id, ) entries: list[Entry] = []