From a1888b3757c3509780db706505110229bb1ffb39 Mon Sep 17 00:00:00 2001 From: "Timothy J. Baek" Date: Tue, 13 Aug 2024 11:21:17 +0100 Subject: [PATCH] refac --- backend/apps/ollama/main.py | 2 +- backend/utils/misc.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/apps/ollama/main.py b/backend/apps/ollama/main.py index d5ef82942..f479ad35c 100644 --- a/backend/apps/ollama/main.py +++ b/backend/apps/ollama/main.py @@ -43,8 +43,8 @@ from config import ( AppConfig, ) from utils.misc import ( - apply_model_params_to_body_ollama, calculate_sha256, + apply_model_params_to_body_ollama, apply_model_params_to_body_openai, apply_model_system_prompt_to_body, ) diff --git a/backend/utils/misc.py b/backend/utils/misc.py index 9de19d3f6..05830568b 100644 --- a/backend/utils/misc.py +++ b/backend/utils/misc.py @@ -179,6 +179,7 @@ def apply_model_params_to_body_ollama(params: dict, form_data: dict) -> dict: "use_mmap", "use_mlock", "num_thread", + "num_gpu", ] mappings = {i: lambda x: x for i in opts} form_data = apply_model_params_to_body(params, form_data, mappings)