From de638f15943f2d7e82f0d9a8ca1fc1df109a6f1d Mon Sep 17 00:00:00 2001 From: sgurunat Date: Mon, 11 Nov 2024 09:31:39 +0000 Subject: [PATCH 1/2] Add model parameter for CodeGenGateway in gateway.py file Signed-off-by: sgurunat --- comps/cores/mega/gateway.py | 1 + 1 file changed, 1 insertion(+) diff --git a/comps/cores/mega/gateway.py b/comps/cores/mega/gateway.py index 29962df14..b6704aa7e 100644 --- a/comps/cores/mega/gateway.py +++ b/comps/cores/mega/gateway.py @@ -274,6 +274,7 @@ async def handle_request(self, request: Request): presence_penalty=chat_request.presence_penalty if chat_request.presence_penalty else 0.0, repetition_penalty=chat_request.repetition_penalty if chat_request.repetition_penalty else 1.2, streaming=stream_opt, + model=chat_request.model if chat_request.model else None ) result_dict, runtime_graph = await self.megaservice.schedule( initial_inputs={"query": prompt}, llm_parameters=parameters From 2cfafa7769f9d0e2b0a32e7d28b162a2618119e9 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 11 Nov 2024 10:10:27 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- comps/cores/mega/gateway.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/comps/cores/mega/gateway.py b/comps/cores/mega/gateway.py index b6704aa7e..7d075eae0 100644 --- a/comps/cores/mega/gateway.py +++ b/comps/cores/mega/gateway.py @@ -274,7 +274,7 @@ async def handle_request(self, request: Request): presence_penalty=chat_request.presence_penalty if chat_request.presence_penalty else 0.0, repetition_penalty=chat_request.repetition_penalty if chat_request.repetition_penalty else 1.2, streaming=stream_opt, - model=chat_request.model if chat_request.model else None + model=chat_request.model if chat_request.model else None, ) result_dict, runtime_graph = await self.megaservice.schedule( initial_inputs={"query": prompt}, llm_parameters=parameters